C++ function argument continuation indented too much



  • My C++ coding style involves putting each function argument on its on line:

    @
    int
    add(
    int a,
    int b)
    {
    return a + b;
    }
    @

    However, qt creator adds an extra level of indentation to the argument continuation lines:

    @
    int
    add(
    int a,
    int b)
    {
    return a + b;
    }
    @

    I cannot figure out how to tell qt creator to only use one level of indentation. Am I doing something wrong or is this a known issue. FYI, I am running qt creator 3.0.1 on linux.

    Thanks!


  • Moderators

    Hi,

    In Qt Creator, go to Tools -> Options -> C++ -> Code Style -> Edit... -> General -> "Align continuation lines" and play with the settings


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.