[openbox] [PATCH] menu title
Clay Barnes
clay.barnes at gmail.com
Mon Feb 20 05:26:26 EST 2006
Henrik Enberg wrote:
>> About removing the menu title -
>>
>> Change the TRUE to FALSE in openbox/menuframe.c line 64, recompile, enjoy.
>>
Nice! I hope it gets into the next OB release! Perhaps a variant of
this could change the default (but still toggle-able) behavior of the
windows, not just the the menu...?
(Clay goes back to going through his months of back-logged mailing lists...)
> How about making it configurable? Put something like this in rc.xml to
> turn off the menu:
>
> <menu>
> <showTitle>no</showTitle>
> <file>menu.xml</file>
> </menu>
>
>
> Index: data/rc.xml.in
> ===================================================================
> RCS file: /cvs/cvsroot/openbox/data/rc.xml.in,v
> retrieving revision 1.21
> diff -u -b -r1.21 rc.xml.in
> Index: data/rc.xsd
> ===================================================================
> RCS file: /cvs/cvsroot/openbox/data/rc.xsd,v
> retrieving revision 1.23
> diff -u -b -r1.23 rc.xsd
> --- data/rc.xsd 25 Sep 2005 14:45:24 -0000 1.23
> +++ data/rc.xsd 18 Feb 2006 21:45:27 -0000
> @@ -190,6 +190,7 @@
> <xs:element name="xorStyle" type="ob:yesorno"/>
> <xs:element name="hideDelay" type="xs:integer"/>
> <xs:element name="desktopMenuIcons" type="ob:yesorno"/>
> + <xs:element name="showTitle" type="ob:yesorno"/>
> </xs:sequence>
> </xs:complexType>
> <!--
> Index: openbox/config.c
> ===================================================================
> RCS file: /cvs/cvsroot/openbox/openbox/config.c,v
> retrieving revision 1.92
> diff -u -b -r1.92 config.c
> --- openbox/config.c 25 Sep 2005 14:45:24 -0000 1.92
> +++ openbox/config.c 18 Feb 2006 21:45:27 -0000
> @@ -71,6 +71,7 @@
> gboolean config_menu_xorstyle;
> guint config_menu_hide_delay;
> gboolean config_menu_client_list_icons;
> +gboolean config_menu_show_title;
>
> GSList *config_menu_files;
>
> @@ -424,6 +425,8 @@
> config_menu_hide_delay = parse_int(doc, n);
> if ((n = parse_find_node("desktopMenuIcons", node)))
> config_menu_client_list_icons = parse_bool(doc, n);
> + if ((n = parse_find_node("showTitle", node)))
> + config_menu_show_title = parse_bool(doc, n);
> }
> }
>
> @@ -618,6 +621,7 @@
> config_menu_xorstyle = TRUE;
> config_menu_hide_delay = 250;
> config_menu_client_list_icons = TRUE;
> + config_menu_show_title = TRUE;
> config_menu_files = NULL;
>
> parse_register(i, "menu", parse_menu, NULL);
> Index: openbox/config.h
> ===================================================================
> RCS file: /cvs/cvsroot/openbox/openbox/config.h,v
> retrieving revision 1.57
> diff -u -b -r1.57 config.h
> --- openbox/config.h 25 Sep 2005 14:45:24 -0000 1.57
> +++ openbox/config.h 18 Feb 2006 21:45:27 -0000
> @@ -124,6 +124,8 @@
> extern guint config_menu_hide_delay;
> /*! show icons in client_list_menu */
> extern gboolean config_menu_client_list_icons;
> +/*! show title in menus? */
> +extern gboolean config_menu_show_title;
> /*! User-specified menu files */
> extern GSList *config_menu_files;
>
> Index: openbox/menuframe.c
> ===================================================================
> RCS file: /cvs/cvsroot/openbox/openbox/menuframe.c,v
> retrieving revision 1.52
> diff -u -b -r1.52 menuframe.c
> --- openbox/menuframe.c 14 Sep 2005 17:40:47 -0000 1.52
> +++ openbox/menuframe.c 18 Feb 2006 21:45:28 -0000
> @@ -61,7 +61,7 @@
> self->type = Window_Menu;
> self->menu = menu;
> self->selected = NULL;
> - self->show_title = TRUE;
> + self->show_title = config_menu_show_title;
> self->client = client;
>
> attr.event_mask = FRAME_EVENTMASK;
>
>
More information about the openbox
mailing list