Results 1 to 6 of 6

Thread: Displaying bug with QGraphicsView in QGraphicsView

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Jul 2014
    Posts
    14
    Thanks
    4
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Displaying bug with QGraphicsView in QGraphicsView

    Hello,

    I want to display hierarchical statecharts with QGraphicsViews.
    So every State can contain substates which in turn can i have also substates and so on.
    Each state displays its substates in a QGraphicsView, so there are QGraphicsViews in QGraphicsView in QGraphicsView...
    Each State inherits from QGraphicsItem and contains a QGraphicsProxyWidget which contains a Widget with a QGraphicsView.

    I tested it with a top level state, that contains two substates.
    Now comes the strange part:
    The first inserted substate is displayed perfectly fine, but the second substate seems to be confused of who its parent is:
    The visibility of the 2nd substate depends on the position of the parent state and it can be dragged partly out of its QGraphicsView.
    The substates are added with the exact same piece of code.
    I made a short video to demonstrate the behavior:
    https://www.youtube.com/watch?v=obWVBnKueJc
    I am using qt 4.8.

    Is it a general problem to have a QGraphicsView inside a QGraphicsView?
    Does anybody have a clue why this happens for the second, third etc widget?

    Thanks in advance
    veio
    Last edited by veiovis; 27th July 2014 at 14:41.

Similar Threads

  1. Replies: 7
    Last Post: 1st December 2011, 16:24
  2. QGraphicsView transparent over another QGraphicsView
    By evergreen in forum Qt Programming
    Replies: 0
    Last Post: 30th May 2011, 10:22
  3. QGraphicsView: Save as PNG without displaying View?
    By SixDegrees in forum Qt Programming
    Replies: 0
    Last Post: 8th October 2010, 22:56
  4. QGraphicsView not displaying QGraphicsItems
    By person in forum Qt Programming
    Replies: 7
    Last Post: 11th September 2010, 02:20
  5. Replies: 16
    Last Post: 29th March 2010, 07:05

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.