Mercurial > hg > xemacs-beta
diff src/gtk-xemacs.c @ 744:8ae895c67ce7
[xemacs-hg @ 2002-02-04 15:44:37 by wmperry]
Enable generic toolbar support for X11. Added new toolbar-shadow-thickness specifier.
author | wmperry |
---|---|
date | Mon, 04 Feb 2002 15:44:52 +0000 |
parents | 0784d089fdc9 |
children | 2923009caf47 |
line wrap: on
line diff
--- a/src/gtk-xemacs.c Mon Feb 04 13:19:17 2002 +0000 +++ b/src/gtk-xemacs.c Mon Feb 04 15:44:52 2002 +0000 @@ -199,10 +199,24 @@ Fadd_spec_to_specifier (Vscrollbar_width, make_int (vsize), frame, Qnil, Qnil); Fadd_spec_to_specifier (Vscrollbar_height, make_int (hsize), frame, Qnil, Qnil); } -#else -#define smash_scrollbar_specifiers(x,y) #endif /* HAVE_SCROLLBARS */ +#ifdef HAVE_TOOLBARS +extern Lisp_Object Vtoolbar_shadow_thickness; + +static void +smash_toolbar_specifiers(struct frame *f, GtkStyle *style) +{ + Lisp_Object frame; + GtkStyleClass *klass = (GtkStyleClass *) style->klass; + + XSETFRAME (frame,f); + + Fadd_spec_to_specifier (Vtoolbar_shadow_thickness, make_int (klass->xthickness), + Qnil, list2 (Qgtk, Qdefault), Qprepend); +} +#endif /* HAVE_TOOLBARS */ + static void gtk_xemacs_realize (GtkWidget *widget) { @@ -224,7 +238,12 @@ #if 0 smash_face_fallbacks (x->f, new_style); #endif +#ifdef HAVE_SCROLLBARS smash_scrollbar_specifiers (x->f, new_style); +#endif +#ifdef HAVE_TOOLBARS + smash_toolbar_specifiers (x->f, new_style); +#endif } }