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

calling QGraphicsItem::childrenBoundingRect() crashs because of pure virtual method call

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Reported
    • Priority: P1: Critical
    • Resolution: Unresolved
    • Affects Version/s: 5.15.2
    • Fix Version/s: None
    • Component/s: Widgets: GraphicsView
    • Labels:
      None
    • Platform/s:
      Linux/X11

      Description

       QGraphicsItem sends events before it is finally constructed!

      Procedure to reproduce crash:

      1. Run QtCreator (from within QtCreator debugger to see call stack)
      2. Create a new (scratch) model
      3. Drag a "Boundary" element onto diagram
      4. Enlarge boundary
      5. Click into label field and enter some letters
      6. Without leaving the label field (do not click outside), drag another "Item" element into the boundary.
      7. QtCreator crashs!

      The call stack shows a __cxa_pure_virtual call after calling QGraphicsItem::childrenBoundingRect() from within qmt::ObjectItem::boundingRect(). If you look further up the call stack you find a call to the constructor QGraphicsRectItem::QGraphicsRectItem(QGraphicsItem*). In between you see some handling of a FocusIn event. It looks like this event is sent before the QGraphicsRectItem() is finally constructed and some methods are still pure virtual.

        Attachments

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

          Activity

            People

            Assignee:
            gilead Jochen Becher
            Reporter:
            gilead Jochen Becher
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Dates

              Created:
              Updated:

                Gerrit Reviews

                There are no open Gerrit changes