[gtkmm] Hard question about drawingareas and OO-design



Hi all,

I'm (still) using gtk(mm) 1.2 and have some difficult problems (lead me to
the end
of my limited C++ knowledge):

I have a window with 2 objects/drawingareas of type ScribbleDrawingArea
(yes,
modified versions of the according example file) and another
object/drawingarea
of type ZoomedDrawingArea (nothing special; also derived from DrawingArea).
Now, you can paint in the 2 ScribbleDrawingAreas (let's name them sda1,
sda2)
and ZoomedDrawingArea (let's say zda1) shall display a zoomed portion of 
sda1 or sda2 respectively, depending on where the cursor is at the moment.
The theoretical process of zooming parts of a picture isn't the problem
(realized
by using PixBufs) but the following questions arise:

How do I pass the x and y coordinates of sda1 and sda2 (retrieved via
motion_notify_event_impl) to zda1? All three objects (sda1, sda2, zda1) are
part of a mywindow class, which 'draws' the GUI (in its constructor).

Is there a way to retrieve other windows'/drawingareas'
motion_notify_events?

Is there some way to handle this by using the windows' addresses (retrieved
via get_window())?

I hope someone can help me out...! Thanks in advance!
Bye,
Michael.

-- 
+++ GMX - Mail, Messaging & more  http://www.gmx.net +++
NEU: Mit GMX ins Internet. Rund um die Uhr für 1 ct/ Min. surfen!




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]