I am attempting to make a radial menu expander in a corner of an QGLWidget scene by subclassing a QLabel, adding a pixmap, adding mousePressEvent and mouseReleaseEvent overrides and move(ing) the label to the corner of the widget (i.e. not adding into a layout). I do not want to add in as an object in my GL scene since the popup menus that will appear need to be generic and very user definable.

Qt Code:
  1. QPixmap pix( ":/files/add_button" );
  2. QLabel *menuWidget = new QLabel( glWidget );
  3. menuWidget->setAutoFillBackground( false ); // Should not be needed
  4. menuWidget->setPixmap( pix );
  5.  
  6. menuWidget->move( 100, 100 );
To copy to clipboard, switch view to plain text mode 

The add_button pixmap is a PNG with a transparent background.

The image displays in the proper place, but the background color of the image is black (incidently the same color as the qglClearColor) instead of clear. Secondly, when I click on the image and replace with a larger image, I can see the image change, but its size does not.

Any thoughts? Sorry no code to post, on a different system.