Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-27354

QTextEdit: Wrong cursor placement in lines consisting of spaces and a soft line break

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P2: Important
    • Resolution: Done
    • Affects Version/s: 4.8.2
    • Fix Version/s: 4.8.x, 5.0.1
    • Component/s: GUI: Text handling
    • Labels:
      None
    • Environment:
      Qt 4.8.2. Seen on Windows 7 (VC), Mac 10.7 (gcc and clang) and Linux 2.6 (gcc)
    • Commits:
      99288633373ecc8ba808cf0ecf18f4a81d62ac84, 248ccb2889aec76cb99c25998534c97b48b98c4a

      Description

      In a line in QTextEdit that consists of spaces and ends with a soft line break (Shift+Return) the cursor sticks at the 2nd or 3rd col position. It does not move right even if more spaces are typed. When a character (e.g. 'a') is typed, the cursor jumps to the correct position and the problem is gone. If the character is deleted the issue comes back.

      Reproduction: Open the Qt textedit demo and place the cursor into an empty line. Press Shift+Return to create a new line using a soft line break. Go up one line and type some spaces. Note that the cursor stops moving after 2 or 3 spaces.

      This worked fine in Qt 4.7.1

        Attachments

        For Gerrit Dashboard: QTBUG-27354
        # Subject Branch Project Status CR V

          Activity

            People

            Assignee:
            esabraha Eskil Abrahamsen Blomfeldt
            Reporter:
            knellek Martin Knelleken
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Gerrit Reviews

                There are no open Gerrit changes