Re: Want draw graphic on root



eexpress <eexp01 gmail com> writes:

i write a very simple gtk2-perl script, want draw on root window. i
test a lot of methods, but still can not get expose event
handler.

I'm not sure if expose events are available for non-widget windows.
They might disappear down the invalidate-region/process-updates stuff.
Does anyone know for sure?

But you can just draw anyway if it's an animated something.  Or for a
background image draw to a pixmap the size of the root, put it in with
->set_back_pixmap(), and $window->clear to show it.

(For X there's some conventions for preserving colormap entries when a
program sets the root background, but gtk doesn't have much good for
that, and it only affects pseudocolor screens.)


-- 
The sigfile movie review series:
"Snakes on a Plane" -- a modern dress retelling of the panic aboard a
ship of King Eumenes II's fleet when attacked by Hannibal with jars of
poisonous snakes.



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