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

The drop area for QToolBar gets triggered even when the toolbar is not on the window.

    XMLWordPrintable

Details

    • Linux/X11, Windows

    Description

      The drop area for QToolBar gets triggered even when the toolbar is outside the window. This issue occurs when moving the toolbar to the left or top (vertically)of the window, but not when moving it to the right or bottom (vertically).

      Expected behavior: drop Area shouldn't be enabled when the toolbar is outside of the window.

      To reproduce the issue run the code below:

      #include <QApplication> 
      #include <QMainWindow> 
      #include <QToolBar>
      int main(int argc, char *argv[]) {     
      qDebug() << "Qt version:" << QT_VERSION_STR;          
      QApplication app(argc, argv);          
      QMainWindow win;     
      win.resize(600, 400);     
      QToolBar *toolbar = new QToolBar("Main Toolbar", &win);     
      QAction *newAction = toolbar->addAction("New");     
      QAction *openAction = toolbar->addAction("Open");     
      win.addToolBar(Qt::TopToolBarArea, toolbar);          
      win.show();          
      return app.exec(); 
      }
       

      I have attached a video that demonstrates the behavior

      Attachments

        1. QTBUG-138183.zip
          2 kB
          Mehdi Belila
        2. ToolBardropArea.mp4
          5.82 MB
          Mehdi Belila
        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            morteza.jamshidi Morteza Jamshidi
            mahdi.belila Mehdi Belila
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes