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

Setvisible(false) on QTextBlock is not adjusting the scroll bars

    XMLWordPrintable

Details

    • Windows
    • fcba9fa861574f33e1d2e54d8c8d6da8062927cd (qt/qtbase/5.12)

    Description

      If user call setvisible(false) to some of the blocks (say 100 to 200), scroll bars are not adjusted automatically. 

      Steps to reproduce:

      1. Execute the attached project.
      2. Click the hide button, and then scroll down. 
      3. A Sudden jump is seen in scrollbar when we reach line 99. 

      Expected result: 

      The scrollbar should be adjusted so that there is smooth scrolling. 

      Note: Tried many things, but no help:

      1. ed->document()>markContentsDirty(0,ed>document()->characterCount());

      2. ed->viewport()>update(); // shows correctly but wheel does not scroll 

      3. static_cast<QPlainTextDocumentLayout *>(ed>document()>documentLayout())>requestUpdate();

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            allan.jensen Allan Sandfeld Jensen
            shmittal Shveta Mittal
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes