Are user-defined cursors now supported under
both X & Windows32 using
wxCursor(filename,flags,hotSpotX,hotSpotY) ???
Thanks,
Bill
···
--
Bill Eldridge
Radio Free Asia
bill@rfa.org
Are user-defined cursors now supported under
both X & Windows32 using
wxCursor(filename,flags,hotSpotX,hotSpotY) ???
Thanks,
Bill
--
Bill Eldridge
Radio Free Asia
bill@rfa.org
Are user-defined cursors now supported under
both X & Windows32 usingwxCursor(filename,flags,hotSpotX,hotSpotY) ???
wxGTK doesn't have this contructor.
--
Robin Dunn
Software Craftsman
robin@AllDunn.com
http://wxpython.org Java give you jitters?
http://wxpros.com Relax with wxPython!
Is this something I should bring up with wxWindows dev?
It's kind of hard to have a uniform presentation across
platforms this way. (I want special cursors like a razor
blade when in edit mode, etc.)
Thanks,
Bill
Robin Dunn wrote:
>
> Are user-defined cursors now supported under
> both X & Windows32 using
>
> wxCursor(filename,flags,hotSpotX,hotSpotY) ???
>wxGTK doesn't have this contructor.
--
Robin Dunn
Software Craftsman
robin@AllDunn.com
http://wxpython.org Java give you jitters?
http://wxpros.com Relax with wxPython!_______________________________________________
wxPython-users mailing list wxPython-users@wxwindows.org
http://wxwindows.org/mailman/listinfo/wxpython-users
--
Bill Eldridge
Radio Free Asia
bill@rfa.org
It's certainly worth a quick note, but I bet it isn't supported in GTK
itself, and therefor not in wxGTK. IN fact, if you did a search in the
archives, it's probably been discussed.
-chris
Bill Eldridge wrote:
Is this something I should bring up with wxWindows dev?
It's kind of hard to have a uniform presentation across
platforms this way. (I want special cursors like a razor
blade when in edit mode, etc.)
> > Are user-defined cursors now supported under
> > both X & Windows32 using
> >
> > wxCursor(filename,flags,hotSpotX,hotSpotY) ???
> >
>
> wxGTK doesn't have this contructor.
--
Christopher Barker,
Ph.D.
cbarker@jps.net --- --- ---
http://www.jps.net/cbarker -----@@ -----@@ -----@@
------@@@ ------@@@ ------@@@
Water Resources Engineering ------ @ ------ @ ------ @
Coastal and Fluvial Hydrodynamics ------- --------- --------
------------------------------------------------------------------------
------------------------------------------------------------------------
Chris Barker writes:
It's certainly worth a quick note, but I bet it isn't supported in GTK
itself, and therefor not in wxGTK. IN fact, if you did a search in the
archives, it's probably been discussed.
GIMP started using different cursors for different tools, a while ago, so I
wouldn't say that it's impossoble to set the cursor when using GTK+....
Also, if you check the documentation for wxWindows' global wxSetCursor
function, it says: "Globally sets the cursor; only has an effect in Windows
and GTK."
This link shows it supported in GDK:
http://developer.gnome.org/doc/API/gdk/gdk-cursors.html
------------------------------------------------------
gdk_cursor_new_from_pixmap ()
GdkCursor* gdk_cursor_new_from_pixmap (GdkPixmap *source,
GdkPixmap *mask,
GdkColor *fg,
GdkColor *bg,
gint x,
gint y);
Creates a new cursor from a given pixmap and mask. Both the pixmap and
mask must have a depth of 1 (i.e. each pixel has
only 2 values - on or off). The standard cursor size is 16 by 16 pixels.
Example:
source = gdk_bitmap_create_from_data (NULL, cursor1_bits,
cursor1_width, cursor1_height);
mask = gdk_bitmap_create_from_data (NULL, cursor1mask_bits,
cursor1_width, cursor1_height);
cursor = gdk_cursor_new_from_pixmap (source, mask, &fg, &bg, 8, 8);
gdk_pixmap_unref (source);
gdk_pixmap_unref (mask);
gdk_window_set_cursor (widget->window, cursor);
source : the pixmap specifying the cursor.
mask : the pixmap specifying the mask, which must be the same size as
source.
source : the pixmap specifying the cursor.
mask : the pixmap specifying the mask, which must be the same size as
source.
fg : the foreground color, used for the bits in the source which are 1.
The color does not have to be allocated first.
bg : the background color, used for the bits in the source which are 0.
The color does not have to be allocated first.
x :the horizontal offset of the 'hotspot' of the cursor.
y :the vertical offset of the 'hotspot' of the cursor.
Returns :a new GdkCursor.
Joshua Rosen wrote:
Chris Barker writes:
> It's certainly worth a quick note, but I bet it isn't supported in GTK
> itself, and therefor not in wxGTK. IN fact, if you did a search in the
> archives, it's probably been discussed.GIMP started using different cursors for different tools, a while ago, so I
wouldn't say that it's impossoble to set the cursor when using GTK+....Also, if you check the documentation for wxWindows' global wxSetCursor
function, it says: "Globally sets the cursor; only has an effect in Windows
and GTK."
_______________________________________________
wxPython-users mailing list wxPython-users@wxwindows.org
http://wxwindows.org/mailman/listinfo/wxpython-users
--
Bill Eldridge
Radio Free Asia
bill@rfa.org