Commit c1796772 authored by Michael Natterer's avatar Michael Natterer 😴 Committed by Michael Natterer

plug-ins/common/flarefx.c changed preview cursors to GDK_CROSSHAIR.

2004-10-29  Michael Natterer  <mitch@gimp.org>

	* plug-ins/common/flarefx.c
	* plug-ins/common/nova.c: changed preview cursors to GDK_CROSSHAIR.

	* plug-ins/common/iwarp.c
	* plug-ins/gflare/gflare.c
	* plug-ins/ifscompose/ifscompose.c: added GDK_CROSSHAIR preview
	cursors. Not quite perfect for IfsCompose (actually needs tool-
	and constext-sensitive cursors) but definitely better than
	before. Fixes bug #90519.
parent ea0331c5
2004-10-29 Michael Natterer <mitch@gimp.org>
* plug-ins/common/flarefx.c
* plug-ins/common/nova.c: changed preview cursors to GDK_CROSSHAIR.
* plug-ins/common/iwarp.c
* plug-ins/gflare/gflare.c
* plug-ins/ifscompose/ifscompose.c: added GDK_CROSSHAIR preview
cursors. Not quite perfect for IfsCompose (actually needs tool-
and constext-sensitive cursors) but definitely better than
before. Fixes bug #90519.
2004-10-29 Sven Neumann <sven@gimp.org>
* tools/pdbgen/pdb/edit.pdb: mention gimp_drawable_fill() in the
......
......@@ -897,7 +897,7 @@ flare_center_preview_realize (GtkWidget *widget,
FlareCenter *center)
{
GdkDisplay *display = gtk_widget_get_display (widget);
GdkCursor *cursor = gdk_cursor_new_for_display (display, GDK_HAND2);
GdkCursor *cursor = gdk_cursor_new_for_display (display, GDK_CROSSHAIR);
gimp_preview_set_default_cursor (center->preview, cursor);
gdk_cursor_unref (cursor);
......
......@@ -111,6 +111,8 @@ static void iwarp_response (GtkWidget *widget,
gint response_id,
gpointer data);
static void iwarp_realize_callback (GtkWidget *widget);
static gint iwarp_motion_callback (GtkWidget *widget,
GdkEvent *event);
......@@ -1185,6 +1187,10 @@ iwarp_dialog (void)
GDK_BUTTON_RELEASE_MASK |
GDK_BUTTON1_MOTION_MASK |
GDK_POINTER_MOTION_HINT_MASK);
g_signal_connect (preview, "realize",
G_CALLBACK (iwarp_realize_callback),
NULL);
g_signal_connect (preview, "event",
G_CALLBACK (iwarp_motion_callback),
NULL);
......@@ -1516,6 +1522,16 @@ iwarp_response (GtkWidget *widget,
}
}
static void
iwarp_realize_callback (GtkWidget *widget)
{
GdkDisplay *display = gtk_widget_get_display (widget);
GdkCursor *cursor = gdk_cursor_new_for_display (display, GDK_CROSSHAIR);
gdk_window_set_cursor (widget->window, cursor);
gdk_cursor_unref (cursor);
}
static gint
iwarp_motion_callback (GtkWidget *widget,
GdkEvent *event)
......
......@@ -587,7 +587,7 @@ nova_center_preview_realize (GtkWidget *widget,
NovaCenter *center)
{
GdkDisplay *display = gtk_widget_get_display (widget);
GdkCursor *cursor = gdk_cursor_new_for_display (display, GDK_HAND2);
GdkCursor *cursor = gdk_cursor_new_for_display (display, GDK_CROSSHAIR);
gimp_preview_set_default_cursor (center->preview, cursor);
gdk_cursor_unref (cursor);
......
......@@ -659,6 +659,7 @@ static void calc_overlay (guchar *dest,
guchar *src2);
static void dlg_setup_gflare (void);
static void dlg_preview_realize (GtkWidget *widget);
static gboolean dlg_preview_handle_event (GtkWidget *widget,
GdkEvent *event);
static void dlg_preview_update (void);
......@@ -2340,9 +2341,14 @@ dlg_run (void)
dlg_preview_deinit_func, NULL);
gtk_widget_set_events (GTK_WIDGET (dlg->preview->widget), DLG_PREVIEW_MASK);
gtk_container_add (GTK_CONTAINER (frame), dlg->preview->widget);
g_signal_connect (dlg->preview->widget, "realize",
G_CALLBACK (dlg_preview_realize),
NULL);
g_signal_connect (dlg->preview->widget, "event",
G_CALLBACK (dlg_preview_handle_event),
NULL);
dlg_preview_calc_window ();
button = gtk_check_button_new_with_mnemonic (_("A_uto update preview"));
......@@ -2470,6 +2476,16 @@ ed_preview_calc_window (void)
}
}
static void
dlg_preview_realize (GtkWidget *widget)
{
GdkDisplay *display = gtk_widget_get_display (widget);
GdkCursor *cursor = gdk_cursor_new_for_display (display, GDK_CROSSHAIR);
gdk_window_set_cursor (widget->window, cursor);
gdk_cursor_unref (cursor);
}
static gboolean
dlg_preview_handle_event (GtkWidget *widget,
GdkEvent *event)
......
......@@ -223,6 +223,7 @@ static void design_area_create (GtkWidget *window, gint design_width,
/* functions for drawing design window */
static void update_values (void);
static void set_current_element (gint index);
static void design_area_realize (GtkWidget *widget);
static gint design_area_expose (GtkWidget *widget,
GdkEventExpose *event);
static gint design_area_button_press (GtkWidget *widget,
......@@ -1158,6 +1159,9 @@ design_area_create (GtkWidget *window,
ifsDesign->area = gtk_drawing_area_new ();
gtk_widget_set_size_request (ifsDesign->area, design_width, design_height);
g_signal_connect (ifsDesign->area, "realize",
G_CALLBACK (design_area_realize),
NULL);
g_signal_connect (ifsDesign->area, "expose_event",
G_CALLBACK (design_area_expose),
NULL);
......@@ -1558,6 +1562,16 @@ set_current_element (gint index)
update_values ();
}
static void
design_area_realize (GtkWidget *widget)
{
GdkDisplay *display = gtk_widget_get_display (widget);
GdkCursor *cursor = gdk_cursor_new_for_display (display, GDK_CROSSHAIR);
gdk_window_set_cursor (widget->window, cursor);
gdk_cursor_unref (cursor);
}
static gboolean
design_area_expose (GtkWidget *widget,
GdkEventExpose *event)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment