From c1527a0f74533dd131576fcfc7b23188ff1466ba Mon Sep 17 00:00:00 2001 From: Christopher James Lahey Date: Tue, 26 Dec 2000 22:34:30 +0000 Subject: Added a "draw_background" argument. Set the default for the 2000-12-26 Christopher James Lahey * gal/e-text/e-entry.c: Added a "draw_background" argument. Set the default for the "draw_background" argument to the contained EText to TRUE. * gal/e-text/e-text.c: Changed the default for the "draw_background" argument to FALSE. svn path=/trunk/; revision=7176 --- widgets/text/e-entry.c | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) (limited to 'widgets/text/e-entry.c') diff --git a/widgets/text/e-entry.c b/widgets/text/e-entry.c index 3bd36d7a0d..93c3ffd936 100644 --- a/widgets/text/e-entry.c +++ b/widgets/text/e-entry.c @@ -63,7 +63,8 @@ enum { ARG_BREAK_CHARACTERS, ARG_MAX_LINES, ARG_ALLOW_NEWLINES, - ARG_DRAW_BORDERS + ARG_DRAW_BORDERS, + ARG_DRAW_BACKGROUND, }; static void @@ -142,6 +143,7 @@ e_entry_init (GtkObject *object) "fill_clip_rectangle", TRUE, "anchor", GTK_ANCHOR_NW, "draw_borders", TRUE, + "draw_background", TRUE, NULL)); gtk_table_attach_defaults(gtk_table, GTK_WIDGET(e_entry->canvas), 0, 1, 0, 1); @@ -275,6 +277,12 @@ et_get_arg (GtkObject *o, GtkArg *arg, guint arg_id) "draw_borders", >K_VALUE_BOOL (*arg), NULL); break; + + case ARG_DRAW_BACKGROUND: + gtk_object_get (item, + "draw_background", >K_VALUE_BOOL (*arg), + NULL); + break; default: arg->type = GTK_TYPE_INVALID; @@ -407,7 +415,14 @@ et_set_arg (GtkObject *o, GtkArg *arg, guint arg_id) gtk_object_set (item, "draw_borders", GTK_VALUE_BOOL (*arg), NULL); if (need_queue) gtk_widget_queue_resize (GTK_WIDGET (ee)); + break; } + + case ARG_DRAW_BACKGROUND: + gtk_object_set (item, + "draw_background", GTK_VALUE_BOOL (*arg), + NULL); + break; } } @@ -480,6 +495,8 @@ e_entry_class_init (GtkObjectClass *object_class) GTK_TYPE_BOOL, GTK_ARG_READWRITE, ARG_ALLOW_NEWLINES); gtk_object_add_arg_type ("EEntry::draw_borders", GTK_TYPE_BOOL, GTK_ARG_READWRITE, ARG_DRAW_BORDERS); + gtk_object_add_arg_type ("EEntry::draw_background", + GTK_TYPE_BOOL, GTK_ARG_READWRITE, ARG_DRAW_BACKGROUND); } E_MAKE_TYPE(e_entry, "EEntry", EEntry, e_entry_class_init, e_entry_init, PARENT_TYPE); -- cgit v1.2.3