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. QGraphicsItem::isBlockedByModalPanel crash, Qt 5.11.0

QGraphicsItem::isBlockedByModalPanel crash, Qt 5.11.0

Scheduled Pinned Locked Moved Unsolved General and Desktop
6 Posts 2 Posters 661 Views
  • 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
    plover
    wrote on last edited by
    #1
    This post is deleted!
    mrjjM 1 Reply Last reply
    0
    • P plover

      This post is deleted!

      mrjjM Offline
      mrjjM Offline
      mrjj
      Lifetime Qt Champion
      wrote on last edited by
      #2

      @plover
      Hi
      Could you try
      http://doc.qt.io/qt-5/qtwidgets-graphicsview-diagramscene-example.html
      and see if that works ?

      1 Reply Last reply
      1
      • P Offline
        P Offline
        plover
        wrote on last edited by
        #3

        @mrjj What exactly should I be testing for in that example?

        mrjjM 1 Reply Last reply
        0
        • P plover

          @mrjj What exactly should I be testing for in that example?

          mrjjM Offline
          mrjjM Offline
          mrjj
          Lifetime Qt Champion
          wrote on last edited by
          #4

          @plover
          You are testing if a bug in Qt somehow. ( Diagram will also crash)
          Or it just a normal bug in your code ( Diagram don't crash)

          So I imagine you just dragged some items around.

          1 Reply Last reply
          0
          • P Offline
            P Offline
            plover
            wrote on last edited by
            #5

            Ok, I can try that.
            I'll try to compile my code with different versions of qt5, see if it is limited to qt 5.11.0 .

            After a bit more studying this is what I've found.

            • QGraphicsItem is added to the scene on top of another item and immediately dragged after it is added (added with left button click and the left button is never released before dragging).
            • This happens about 25% of the time when the above action is taken.

            The lines from my code in the core are doing the following:

            /home/plover/workspace/libs/view/MyView.cpp:710

            void MyView::mouseMoveEvent( QMouseEvent *event )
            {
                m_mousePos = event->pos();
                QGraphicsView::mouseMoveEvent( event );   // Line 710
            }
            
            

            /home/plover/workspace/app/MyApplication.cpp:68

            bool MyApplication::notify( QObject *receiver, QEvent *e )
            {
                bool done = true;
                try
                {
                    done = QApplication::notify( receiver, e ); // Line 68
                }
                catch ( const std::exception& ex )
                {
                    std::cerr << "This should not happen \n";
                }
                catch ( ... )
                {
                    std::cerr << "SOMETHING REALLY, REALLY BAD HAPPENED!" ;
                }
            
                return done;
            }
            
            mrjjM 1 Reply Last reply
            0
            • P plover

              Ok, I can try that.
              I'll try to compile my code with different versions of qt5, see if it is limited to qt 5.11.0 .

              After a bit more studying this is what I've found.

              • QGraphicsItem is added to the scene on top of another item and immediately dragged after it is added (added with left button click and the left button is never released before dragging).
              • This happens about 25% of the time when the above action is taken.

              The lines from my code in the core are doing the following:

              /home/plover/workspace/libs/view/MyView.cpp:710

              void MyView::mouseMoveEvent( QMouseEvent *event )
              {
                  m_mousePos = event->pos();
                  QGraphicsView::mouseMoveEvent( event );   // Line 710
              }
              
              

              /home/plover/workspace/app/MyApplication.cpp:68

              bool MyApplication::notify( QObject *receiver, QEvent *e )
              {
                  bool done = true;
                  try
                  {
                      done = QApplication::notify( receiver, e ); // Line 68
                  }
                  catch ( const std::exception& ex )
                  {
                      std::cerr << "This should not happen \n";
                  }
                  catch ( ... )
                  {
                      std::cerr << "SOMETHING REALLY, REALLY BAD HAPPENED!" ;
                  }
              
                  return done;
              }
              
              mrjjM Offline
              mrjjM Offline
              mrjj
              Lifetime Qt Champion
              wrote on last edited by
              #6

              @plover said in QGraphicsItem::isBlockedByModalPanel crash, Qt 5.11.0:

              , see if it is limited to qt 5.11.0 .

              that's also a good plan.

              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