Re: ImageView
- From: Emmanuel Gontcho <gontcho gmail com>
- To: Dov Grobgeld <dov grobgeld gmail com>, gtk-list gnome org
- Subject: Re: ImageView
- Date: Thu, 4 Nov 2010 11:20:56 +0100
Thank you,
I hesitated at the beginning using gtk-image-view, but now, I've got to.
2010/11/3 Dov Grobgeld
<dov grobgeld gmail com>
I solved the same problem by writing my own image viewer widget. See:
http://giv.sourceforge.net/gtk-image-viewer/It provides the functions:
void gtk_image_viewer_canv_coord_to_img_coord (GtkImageViewer * self, double cx,
double cy, double * imgx,
double * imgy);void gtk_image_viewer_img_coord_to_canv_coord (GtkImageViewer * self,
double imgx, double imgy,
double * canvx, double * canvy);
to convert between canvas (callback) and image coordinates, no matter what your zoom and scroll positions are.
That said, perhaps someone else can answer you regarding ImageView.
Regards,
Dov
Hello,
I am using ImageView 1.6 to make some manipulation over images. The
problem is I am using the signal "button-press-event" to cacth clicks
on the imageView, but I am unable to convert mouse coordinates to
image coordinate. I am unable to retrieve the exact coordinate of the
pixel clicked. What Can I do ?
--
Emmanuel Mbenga Gontcho
!!!!! Gem !!!!!
gontcho.wordpress.com
N'utilisez pas Windows 7. Pour savoir pourquoi :
http://windows7sins.org/
Don't use Windows 7. To know why :
http://windows7sins.org/
Membre de l'April - « promouvoir et défendre le logiciel libre » -
http://www.april.org
Rejoignez maintenant plus de 2 500 personnes, associations, entreprises et
collectivités qui soutiennent notre action
_______________________________________________
gtk-list mailing list
gtk-list gnome org
http://mail.gnome.org/mailman/listinfo/gtk-list
--
Emmanuel Mbenga Gontcho
!!!!! Gem !!!!!
gontcho.wordpress.comN'utilisez pas Windows 7. Pour savoir pourquoi :
http://windows7sins.org/
Don't use Windows 7. To know why :
http://windows7sins.org/Membre de l'April - « promouvoir et défendre le logiciel libre » -
http://www.april.org
Rejoignez maintenant plus de 2 500 personnes, associations, entreprises et
collectivités qui soutiennent notre action
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]