Results 1 to 5 of 5

Thread: QLabel with multiple layers

  1. #1
    Join Date
    Jun 2009
    Location
    India
    Posts
    143
    Thanks
    16
    Thanked 2 Times in 2 Posts
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default QLabel with multiple layers

    Hi all,

    I am passing the window id of my QLabel to a 3rd party library, this library will put the graphics data into Qlabel

    After once this is done, i need to draw circles on top of the graphics displayed in QLabel

    I could able to create a image and draw circles and able to set the pixmap of Qlabel, but it always goes below the graphics displayed on Qlabel..

    How do i overcome this problem..

  2. #2
    Join Date
    Nov 2010
    Posts
    315
    Thanked 53 Times in 51 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows Symbian S60 Maemo/MeeGo

    Default Re: QLabel with multiple layers


  3. #3
    Join Date
    Jun 2011
    Location
    Finland
    Posts
    164
    Thanks
    1
    Thanked 26 Times in 26 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Maemo/MeeGo

    Default Re: QLabel with multiple layers

    Hi,

    I don't know if I have understood you correctly, but:

    I assume that If you are passing a window id of your QLabel and not a pointer to a QLabel widget, the 3rd party library will not draw the graphics into QLabel, but on top of that QLabel with some transparency. In that case you can't do too much about it. Try playing with that 3rd party library to see how the graphics is drawn to your QLabel, try to place another QLabel on top of it and set some text. See if the text is drawn on top of that graphics.

  4. #4
    Join Date
    Jun 2009
    Location
    India
    Posts
    143
    Thanks
    16
    Thanked 2 Times in 2 Posts
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: QLabel with multiple layers

    Quote Originally Posted by Rachol View Post
    Hi,

    I don't know if I have understood you correctly, but:

    I assume that If you are passing a window id of your QLabel and not a pointer to a QLabel widget, the 3rd party library will not draw the graphics into QLabel, but on top of that QLabel with some transparency. In that case you can't do too much about it. Try playing with that 3rd party library to see how the graphics is drawn to your QLabel, try to place another QLabel on top of it and set some text. See if the text is drawn on top of that graphics.

    Hi Rachol,

    if i put another Qlabel above the Qlabel which i pass window id , the graphics is getting displayed on top of both the labels .....

    Expected the graphics will be put on the window id of the QLabel which i passed .....Couldn't able to grab hows its working...Any idea..

  5. #5
    Join Date
    Jun 2011
    Location
    Finland
    Posts
    164
    Thanks
    1
    Thanked 26 Times in 26 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Maemo/MeeGo

    Default Re: QLabel with multiple layers

    I am afraid you can't do much about it, if the 3rd party library is drawing a transparent, frameless top-level window on top of your widget's window.

Similar Threads

  1. Replies: 4
    Last Post: 29th July 2010, 05:07
  2. How does Qt implement layers?
    By FinderCheng in forum Qt Programming
    Replies: 1
    Last Post: 16th October 2009, 13:12
  3. Replies: 1
    Last Post: 29th September 2009, 19:44
  4. QGraphicsItems Layers
    By qtuser20 in forum Qt Programming
    Replies: 7
    Last Post: 24th July 2009, 00:21
  5. Application 3-tiers (multi layers)
    By estanisgeyer in forum Qt Programming
    Replies: 2
    Last Post: 13th February 2009, 17:28

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.