Results 1 to 2 of 2

Thread: How to set braces in the same line method signature.

  1. #1
    Join Date
    Mar 2015
    Posts
    99
    Thanks
    50

    Default How to set braces in the same line method signature.

    Good evening!

    I'm using QtCreator 3.4.0 and i would like to place all open braces in the same line as the method signature ("K&R style"). I found in Google some threads about this, but they are all very old, two years or more and no one could told exactly what to do, even here i could not find an answer.
    I tried in "Tools->Options->C++->Edit" but there are no options for what i want to do!

    Example of what i want:
    Qt Code:
    1. void method( ) {
    2. if(...) {
    3. //...
    4. }
    5. }
    To copy to clipboard, switch view to plain text mode 

    How can i do that?

  2. #2
    Join Date
    Mar 2015
    Posts
    4
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    Unix/X11 Windows

    Default Re: How to set braces in the same line method signature.

    use a code formatter.
    Artistic Styler is pretty good
    install it and set Qt Designer up to use it
    http://doc.qt.io/qtcreator/creator-beautifier.html

Similar Threads

  1. Replies: 0
    Last Post: 3rd February 2014, 07:10
  2. RSA, Private and Public Key and Digital Signature
    By pvaz in forum Qt Programming
    Replies: 18
    Last Post: 8th April 2011, 03:24
  3. OpenSSL and RSA :: digital signature
    By josecarlosmissias in forum Qt Programming
    Replies: 5
    Last Post: 7th May 2010, 14:23
  4. Static function signature
    By jhearon in forum Qt Programming
    Replies: 1
    Last Post: 30th January 2008, 20:49

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.