Centralize lookup and caching of cursor GC's here.
Sun Mar 3 14:26:33 2002 Owen Taylor <otaylor@redhat.com> * gtk/gtkstyle.[ch] (_gtk_get_insertion_cursor_gc): Centralize lookup and caching of cursor GC's here. * gtk/gtkentry.[ch] gtk/gtktextview.[ch] gtk/gtktextdisplay.c gtk/gtklabel.c: Move to using _gtk_get_insertion_cursor_gc(). * gtk/gtkentry.c (gtk_entry_expose): Draw cursors under the text, not over the text. * gtk/gtkwidget.c (gtk_widget_class_init): add a secondary-cursor-color property. * gtk/gtkwidget.c (gtk_widget_class_init): Decrease the default aspect ratio to 1/25 (0.04). * tests/testgtkrc (bell_duration): Comment out cursor color setting.
This commit is contained in:
@ -1078,11 +1078,17 @@ gtk_widget_class_init (GtkWidgetClass *klass)
|
||||
_("Color with which to draw insertion cursor"),
|
||||
GDK_TYPE_COLOR,
|
||||
G_PARAM_READABLE));
|
||||
gtk_widget_class_install_style_property (klass,
|
||||
g_param_spec_boxed ("secondary-cursor-color",
|
||||
_("Secondary cursor color"),
|
||||
_("Color with which to draw the secondary insertion cursor when editing mixed right-to-left and left-to-right text."),
|
||||
GDK_TYPE_COLOR,
|
||||
G_PARAM_READABLE));
|
||||
gtk_widget_class_install_style_property (klass,
|
||||
g_param_spec_float ("cursor-aspect-ratio",
|
||||
_("Cursor line aspect ratio"),
|
||||
_("Aspect ratio with which to draw insertion cursor"),
|
||||
0.0, 1.0, 0.033,
|
||||
0.0, 1.0, 0.04,
|
||||
G_PARAM_READABLE));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user