Re: Re: ROOT Windows and Cursor :o)
| From: | Steph | Date: | Tue, 26 Mar 2002 18:26:13 +0000 |
| Subject: | Re: Re: ROOT Windows and Cursor :o) | ||
| References: | 1 2 | Groups: | php.gtk.general |
| Request: | Send a blank email to php-gtk-general+get-1649@lists.php.net to get a copy of this message | ||
Hi Nicholas,
You wouldn't quite do it like that in PHP-GTK.
The root window cursor presumably is the one you would find by doing
$gdkwindow = $mainwindow->window;
$gdkwindow->set_cursor($cursor);
where $cursor would be one of the integers describing the GDK cursor set in gdk/gdkcursors.h in the
GTK+ source. (even numbers, 0 through to 152 inclusive).
We don't have an external destruction function implemented.
The second part with the colour allocation is very different, and has been covered in the PHP-GTK
manual.
----- Original Message -----
From: "Andrei Zmievski" <andrei@ispi.net>
To: "Escuder Nicolas" <n.escuder@alineanet.com>
Cc: "PHP-GTK" <php-gtk-general@lists.php.net>
Sent: Tuesday, March 26, 2002 5:31 PM
Subject: [PHP-GTK] Re: ROOT Windows and Cursor :o)
> Questions like these are best asked on the user mailing list. I am
> copying the list on this.
>
> On Tue, 26 Mar 2002, Escuder Nicolas wrote:
> > Hello,
> >
> > i just want to know if this C code :
> >
> > type=GDK_LEFT_PTR
> > GdkCursor *cursor = gdk_cursor_new (type);
> > gdk_window_set_cursor (GDK_ROOT_PARENT (), cursor);
> > gdk_cursor_destroy (cursor);
> >
> > and this C code :
> >
> > gdk_color_parse ("#363047", &color);
> >
> > colormap = gdk_window_get_colormap (GDK_ROOT_PARENT ());
> > if (colormap != NULL) {
> > gdk_error_trap_push ();
> >
> > gdk_color_alloc (colormap, &color);
> > gdk_window_set_background (GDK_ROOT_PARENT (), &color);
> > gdk_window_clear (GDK_ROOT_PARENT ());
> >
> > gdk_flush ();
> > gdk_error_trap_pop ();
> > }
> >
> > can be done in php-gtk, because i search but i don't find ...
> > i'm sorry if this question is stupid if this exist but i don't find ....
> >
> > Thanks for answer
> >
> > see you
> >
> > Nicolas
>
>
>
> -Andrei
>
> "Freedom comes when you learn to let go.
> Creation comes when you learn to say no."
> -madonna
>
> --
> PHP-GTK General Mailing List (http://gtk.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>