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. QTabBar: Drop-down menu instead of left/right-cursors
Forum Updated to NodeBB v4.3 + New Features

QTabBar: Drop-down menu instead of left/right-cursors

Scheduled Pinned Locked Moved Solved General and Desktop
3 Posts 2 Posters 558 Views 1 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.
  • qwasder85Q Offline
    qwasder85Q Offline
    qwasder85
    wrote on last edited by
    #1

    Hi, this is something I wish the QTabBar could do:
    When there are too many tabs to display on the available space, the QTabBar displays little "left" and "right" cursors on the right side of the TabBar pane. This concept is terrible when it comes to handling a lot of tabs.

    I would like to have it display a little drop-down arrow instead, that opens a QMenu with a list of all the tabs to scroll through.
    Unfortunately, I have no idea where to start with this. The QMenu itself is not an issue, but these cursor arrows are inaccessible to me when I inherit from QTabBar. There is a style hint "QStyle::SH_TabBar_PreferNoArrows", but that only disables the arrows altogether, from what I understand (I'm not at all experienced in QStyle).

    Does anyone have an idea or experience with something similar and can guide me in a direction?

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

      Hi,

      Do you have in mind something like what QTabWidget::cornerWidget proposes ?

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

      qwasder85Q 1 Reply Last reply
      1
      • SGaistS SGaist

        Hi,

        Do you have in mind something like what QTabWidget::cornerWidget proposes ?

        qwasder85Q Offline
        qwasder85Q Offline
        qwasder85
        wrote on last edited by qwasder85
        #3

        @SGaist Oh, wait. I have to check this real quick...

        So, this seems, in principle, the thing I was looking for. But I can't get it to show up, yet. That might be on my part though. I'll mark your post as the answer, thank you very much.

        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