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

QGraphicsScene behaviour broken

    XMLWordPrintable

Details

    • Bug
    • Resolution: Invalid
    • Not Evaluated
    • None
    • 5.9.6
    • Widgets: GraphicsView
    • None
    • Windows

    Description

      Something drastic changed with the behaviour of QGraphicsScene/QGraphicsView from Qt4.8.6 to Qt5.9.6 (the version we are currently at and want to upgrade to). If you run the following code snippet 

      QRectF innerBounds(0, 0, 0.01, 0.01);
      QGraphicsEllipseItem innerCircle(innerBounds);
      innerCircle.setBrush(Qt::red);
      QGraphicsScene scene;
      scene.addItem(&innerCircle);
      QGraphicsView view(&scene);
      view.fitInView(&innerCircle);
      QVBoxLayout layout;
      layout.addWidget(&view);
      QDialog dialog;
      dialog.setLayout(&layout);
      dialog.exec();

      In Qt4.8.6 you get

      but in Qt5.9.6 you get

      Since we are doing such a big jump in our upgrade it is difficult to find what has changed.

      Attachments

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

        Activity

          People

            bibr Andreas Aardal Hanssen
            jan-georg Jan-Georg van der Wath
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes