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. Qt - QTabWidget strange behavior - probably bug...

Qt - QTabWidget strange behavior - probably bug...

Scheduled Pinned Locked Moved General and Desktop
1 Posts 1 Posters 1.7k 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.
  • P Offline
    P Offline
    Peppy
    wrote on last edited by
    #1

    Hi guys, I have one question - How to overcome this issue with tabs in tab bar? Look closely onto tab bar - the corner buttons, are not at it's position - one the left side, the tab bar should start at the end of button and on the right side, the tab bar should be as wide as window minus the width of the second button - and that button should be placed into the real corner, isn't it?

    Code:
    @
    QPushButton *menuButton = new QPushButton("...");
    menuButton->setFixedSize(26, 26);
    QPushButton *addButton = new QPushButton("+");
    addButton->setFixedSize(26, 26);

    m_tabWidget->setCornerWidget(menuButton, Qt::TopLeftCorner);
    m_tabWidget->setCornerWidget(addButton);
    m_tabWidget->addTab(new QTextEdit(this), QString("Commander 1"));
    m_tabWidget->addTab(new QTextEdit(this), QString("Commander 2"));
    m_tabWidget->addTab(new QTextEdit(this), QString("Commander 3"));
    m_tabWidget->addTab(new QTextEdit(this), QString("Commander 4"));
    

    @

    !http://i45.tinypic.com/2w2fvvl.png(QTabWidget corner buttons bug)!

    (I have pushed it as a bug.)
    Thanks, Peppy.

    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