Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

Qt Creator: Code formatting and error checking



  • Is it possible to configure code block lines in Qt Creator?(like Visual Studio)
    I couldn't find any options about it.

    Plus, there is a little problem about syntax error checking. I assigned value to undeclared variable but no error messages were displayed.
    Is this Qt Creator's issue? I set up debugger correctly and other errors(ex. missing semicolon) are catched well.


  • Lifetime Qt Champion

    @JKrig said in Qt Creator: Code formatting and error checking:

    Plus, there is a little problem about syntax error checking. I assigned value to undeclared variable but no error messages were displayed

    It will be displayed as soon as you compile your application.

    "Is it possible to configure code block lines in Qt Creator?" - not sure what you mean but maybe Options/Text Editor/Display/Highlight blocks"?


  • Lifetime Qt Champion

    Hi @JKrig, welcome!

    Plus, there is a little problem about syntax error checking. I assigned value to undeclared variable but no error messages were displayed.

    If you enable the Clang Code Model under Help -> About Plugins, you'll get the warnings inline while editing code.

    Be aware to not enable the Clang Refactoring Plugin for now, it is experimental and has some issues.



  • @jsulm I checked 'Highlight Blocks' option but it wasn't what I want.
    I'm saying about this:
    0_1517632584511_codeblock_lines.png


Log in to reply