Re: panning in scrolledWindow/viewport
- From: Kees Kling <ckling upcmail nl>
- To: Ian Martin <martin_id vodafone co nz>, gtkmm <gtkmm-list gnome org>
- Subject: Re: panning in scrolledWindow/viewport
- Date: Tue, 09 Oct 2012 10:35:19 +0200
On 10/09/2012 09:50 AM, Ian Martin wrote:
On 08/10/12 00:04, Kees Kling wrote:
Hi all,
I'm working on a project to display images. These images are loaded
in a Gtk::DrawingArea. Most of the time these images are too big, so
I want to pan these images with the mouse. I tried a viewport and a
scrolled window to pack this drawingarea and do the panning in a
motion_notify_event by changing the values of the gtk::adjustment
object. It is working, but terrible slow. It must be possible to do
this faster, because when I load these images in the "Gimp" I can do
this type of panning in a rather smooth way.
So my questions are
Must I use a viewport or scrolledwindow object?
Is it correct to pan by changing the adjustment objects or is there a
better ( faster ) way?
Thanks
Kees Kling
_______________________________________________
gtkmm-list mailing list
gtkmm-list gnome org
https://mail.gnome.org/mailman/listinfo/gtkmm-list
Hi Kees,
Did you look at using a Gtk::Layout? It packs the Gtk::DrawingArea
into a viewport for you, and seemed to work better for me.
Ian.
Hi Ian,
thanks for your advise. Meanwhile I was still woring on the project and
found out that the scrolling wasn't the real botlleneck, but the way I
was rendering the image. I changed that and had a lot of speed
improvement, but I will try your method
Thanks
Kees
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]