[pygtk] Simple question on reusing stock item
finlay at moeraki.com
Mon Feb 9 19:04:24 WST 2009
Alessandro Dentella wrote:
> i'd like to use stock item in menu entries with modified labels to better
> suit context.
> * MenuItem doesn't allow to use images (reasonable)
> * ImageMenuItem doesn't appearently allow to change label (really???)
> I think I could go with IconFactory but it seems to me it's more complex
> than what is should be and I wandered if there is a simple way I was not
> able to work out.
A MenuItem is a Container so you can add anything to it. In your case
create an empty MenuItem and add an HBox containing an Image and a Label.
More information about the pygtk