Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Auto scroll QScrollArea
QtWS25 Last Chance

Auto scroll QScrollArea

Scheduled Pinned Locked Moved Solved General and Desktop
3 Posts 2 Posters 891 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • ivanicyI Offline
    ivanicyI Offline
    ivanicy
    wrote on last edited by
    #1

    Hello!

    I have a QSCrollArea in which I put widgets dynamically. I have a tree in which I select them, how could I do autoscroll to the selected widget?

    This is the effect that I want:

    0_1536738323732_405e151e-ebd7-4c4b-ab52-6c247dbeb8e7-image.png

    0_1536738388073_bfa2773e-0fe4-4dd0-be25-75e0561463a0-image.png

    Thank you very much!

    1 Reply Last reply
    0
    • mrjjM Offline
      mrjjM Offline
      mrjj
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi
      There is
      http://doc.qt.io/qt-5/qscrollarea.html#ensureWidgetVisible
      That will scroll it so it's visible.

      ivanicyI 1 Reply Last reply
      4
      • mrjjM mrjj

        Hi
        There is
        http://doc.qt.io/qt-5/qscrollarea.html#ensureWidgetVisible
        That will scroll it so it's visible.

        ivanicyI Offline
        ivanicyI Offline
        ivanicy
        wrote on last edited by
        #3

        @mrjj Thank you very much!!

        1 Reply Last reply
        1

        • Login

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved