Qt Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Unsolved

    Unsolved Manual resizing of QGraphicsItem using mouse

    General and Desktop
    qgraphicsitem qgraphicsview qgraphicsscene mouse event resize
    1
    1
    827
    Loading More Posts
    • 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.
    • H
      hellozee last edited by

      I have extended both QGraphicsScene and QGraphicsView, and at the same time overwritten the QGraphicsScene mousePress, mouseMove and mouseRelease events.
      Now this events are handled by my transform tool class which is also responsible for drawing a bounding rectangle. Doing manual resizing seems like a trivial task, but I am unable to override the hover events of the bounding rectangle class even after doing setAcceptHoverEvents(true); inside the derived QGraphicsRectItem.

      Is my approach a correct one? If yes where am I most probably going wrong, if not what should be a better approach? Another thing which came to my mind is should install an eventfilter for doing such stuff?

      1 Reply Last reply Reply Quote 0
      • First post
        Last post