[Sugar-devel] Turtle Art in GNOME 3
walter.bender at gmail.com
Tue Apr 12 10:48:42 EDT 2011
On Tue, Apr 12, 2011 at 8:06 AM, Gonzalo Odiard <gonzalo at laptop.org> wrote:
> I don't know very well how resolve it, but I think the problem is with
> changes in GTK3.
Looks like gtk drawable is disappearing altogether...
But there is some more immediate problem that I have yet to narrow
down... somehow the scrollable window in which I put my drawable
region is not being initialized properly from Sugar (but is from
GNOME). Stay tuned.
> On Mon, Apr 11, 2011 at 9:33 PM, Walter Bender <walter.bender at gmail.com>
>> For some reason, when I try to access the window of my drawable area,
>> it is coming back as None. I wonder if this is something that has
>> somehow changed in GNOME 3.
>> A DrawingArea is created using the constructor:
>> drawing_area = gtk.DrawingArea()
>> A DrawingArea is initially created with a size of (0, 0) so you should
>> use the following method to make the drawing_area visible by setting
>> its width and height to useful values greater than zero:
>> drawing_area.set_size_request(width, height)
>> To draw on a DrawingArea you must retrieve the wrapped gtk.gdk.Window
>> using the window attribute of the DrawingArea as follows:
>> drawable = drawing_area.window
>> But drawable (which I call area in my code) is None.
>> I'll keep poking around.
>> Walter Bender
>> Sugar Labs
>> Sugar-devel mailing list
>> Sugar-devel at lists.sugarlabs.org
More information about the Sugar-devel