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

QToolBar bug

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: P3: Somewhat important P3: Somewhat important
    • 4.8.0
    • 4.6.2
    • Widgets: Main Window
    • None
    • WinXP SP3 32bit
    • fa74b4a710618f2c738030550ff7c6b668980324

      First we need MainWindow with ToolBar. Next, add several actions on it, for example 8. Then compile and run your app. Now we have MainWindow with ToolBar and 8 actions on it. Then minimize your window such, as ToolBar cannot display all actions. Expand ToolBar for watching all actions. Then, try to move ToolBar (while it expanded) out of you application. Some actions will be inaccessible, and button ">>", that expands ToolBar, hasn't any effect.

      Example:

      #include <QtGui/QApplication>
      #include <QMainWindow>
      #include <QToolBar>
      #include <QAction>
      #include <QList>
      
      int main(int argc, char *argv[])
      {
          QApplication a(argc, argv);
          QMainWindow *w = new QMainWindow();
          QToolBar *tb = w->addToolBar("tb");
          QAction *a1 = new QAction("act1", tb);
          QAction *a2 = new QAction("act2", tb);
          QAction *a3 = new QAction("act3", tb);
          QAction *a4 = new QAction("act4", tb);
          QAction *a5 = new QAction("act5", tb);
          QAction *a6 = new QAction("act6", tb);
          QAction *a7 = new QAction("act7", tb);
          QAction *a8 = new QAction("act8", tb);
          QList<QAction *> alist;
          alist << a1 << a2 << a3 << a4 << a5 << a6 << a7 << a8;
          tb->addActions(alist);
          w->show();
          return a.exec();
      }
      

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

            vfm Thierry Bastian (closed Nokia identity) (Inactive)
            dpblh Slava
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes