Uploaded image for project: 'Qt Creator'
  1. Qt Creator
  2. QTCREATORBUG-21767

[Reg 4.7 -> 4.8] Qt Creator code completion for else block not configurable

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P2: Important
    • Resolution: Done
    • Affects Version/s: Qt Creator 4.8.0
    • Fix Version/s: Qt Creator 4.10.0-beta1
    • Component/s: C/C++/Obj-C++ Support
    • Labels:
    • Environment:
      Qt Creator 4.8.0
      Based on Qt 5.12.0 (GCC 5.3.1 20160406 (Red Hat 5.3.1-6), 64 bit)
      Ubuntu 16.04
      Clang Code Model active
    • Platform/s:
      Linux/X11, Windows
    • Commits:
      975173af11da200e94517db7085dea46d2592f26 (qt-creator/qt-creator/master)

      Description

      see https://forum.qt.io/topic/97813/how-to-configure-qt-creator-code-completion-configuration-for-else

      New bug in 4.8.0 C++ editor: Type a complete if block followed by else and <Enter>. For example:

      if (false)

      {

      }

      else

      Expected behavior: The cursor is placed on the next line, indented relative to the else declaration (ideally) or (less ideally) brackets added per configuration settings.

      Actual behavior: Brackets are added with the opening bracket on the same line as the else declaration and the closing bracket placed two lines below the else declaration. The cursor is placed on the next line below the opening bracket, indented relative to the else declaration.

        Attachments

          Issue Links

          For Gerrit Dashboard: QTCREATORBUG-21767
          # Subject Branch Project Status CR V

            Activity

              People

              Assignee:
              kosjar Nikolai Kosjar
              Reporter:
              jbarnesweb Jeff Barnes
              Votes:
              11 Vote for this issue
              Watchers:
              14 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Gerrit Reviews

                  There are no open Gerrit changes