Re: Images and Signals
- From: Jeff Franks <jcf tpg com au>
- To: JOSE PEDRO SERGIO ROMAO MACHADO <a15993 alunos det ua pt>
- Cc: gtk-app-devel-list gnome org
- Subject: Re: Images and Signals
- Date: Tue, 17 Feb 2004 15:35:48 +1100
JOSE PEDRO SERGIO ROMAO MACHADO wrote:
Hi there!
I'm trying to close a About window with an image clicked.
I've tryied several GtkImage signals but noone is emmited when I click
on the image.
I'm trying to do the same on Gimp's Help->About... window does, when
you click on the Gimp's logo image.
Does someone knows which signal must I use to respond to an Mouse
Click on the image???
Thanks in advance.
You need to use a GtkEventBox. Have a look at the eventbox example
application in the GTK+ examples source directory. Add a GtkEvenBox to
your dialog first and set it to catch "button_press_event" signals, like
the eventbox example does. Then add your GtkImage to the GtkEventBox.
Now when you click the image the dialog will close, if you connect up
the GtkEventBox "button_press_event" signal correctly.
Jeff Franks
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]