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. QTreeView problems with horizontal scrollbar
Forum Updated to NodeBB v4.3 + New Features

QTreeView problems with horizontal scrollbar

Scheduled Pinned Locked Moved Solved General and Desktop
3 Posts 2 Posters 1.7k Views 2 Watching
  • 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.
  • ? Offline
    ? Offline
    A Former User
    wrote on last edited by
    #1

    Hello,
    I've inherited from QTreeView, but horizontal scrollbar is invisible even though the treeview is resized to smaller than content, but vertical scrollbar is working fine. I've set the property "setHeaderHidden()" to true. Does this effect the horizontal scroll bar.?

    Thanks for your time.

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

      Hi,

      No it should not. What other modifications did you do ?
      How are you setting up your model ?

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      0
      • ? Offline
        ? Offline
        A Former User
        wrote on last edited by
        #3

        I figured out what was missing, i din't override resizeEvent() & i set "setHeaderHidden()" to true which hides headers. So, i just override the resizeEvent() & called the slot "resizeColumnToContents(0)" as i've only one column and scroll bars are shown as needed (default behavior).
        Thanks guys & specially @SGaist

        1 Reply Last reply
        0

        • Login

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