Results 1 to 7 of 7

Thread: QGraphicsItem doesn't inherit QObject?

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Sep 2011
    Posts
    45
    Thanks
    17
    Qt products
    Qt3
    Platforms
    Unix/X11 Windows

    Default Re: QGraphicsItem doesn't inherit QObject?

    Thank you. I guess, it's only way for getting signals and doing the project in a right way.

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,368
    Thanks
    3
    Thanked 5,017 Times in 4,793 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: QGraphicsItem doesn't inherit QObject?

    No, it's not the only way. You can have a separate controller object that will emit signals on behalf of your items. Then you don't have to modify the item classes and they will remain to be light as you'll only have one object that emits signals for all your items.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  3. The following 2 users say thank you to wysota for this useful post:

    ajo (6th December 2012), DmitryNik (26th September 2011)

  4. #3
    Join Date
    Sep 2011
    Posts
    45
    Thanks
    17
    Qt products
    Qt3
    Platforms
    Unix/X11 Windows

    Default Re: QGraphicsItem doesn't inherit QObject?

    Oh, I didn't consider that at all. Thank you once again for helping. I need to try your advice.

Similar Threads

  1. destruction of QGraphicsItem
    By killkolor in forum Qt Programming
    Replies: 2
    Last Post: 5th December 2009, 10:31
  2. Inherit from QObject for data-classes?
    By niko in forum Qt Programming
    Replies: 7
    Last Post: 14th July 2007, 15:09

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
  •  
Qt is a trademark of The Qt Company.