Next: GTK resources, Previous: Lucid Resources, Up: X Resources
If the Emacs installed at your site was built to use the X toolkit with the LessTif or Motif widgets, then the menu bar, the dialog boxes, the pop-up menus, and the file-selection box are separate widgets and have their own resources.
The resource names for the menu bar contain ‘pane.menubar’ (following, as always, the name of the Emacs invocation, or ‘Emacs’, which stands for all Emacs invocations). Specify them like this:
Emacs.pane.menubar.subwidget.resource: value
Each individual string in the menu bar is a subwidget; the subwidget's name is the same as the menu item string. For example, the word ‘File’ in the menu bar is part of a subwidget named ‘emacs.pane.menubar.File’. Most likely, you want to specify the same resources for the whole menu bar. To do this, use ‘*’ instead of a specific subwidget name. For example, to specify the font ‘8x16’ for the menu-bar items, write this:
Emacs.pane.menubar.*.fontList: 8x16
This also specifies the resource value for submenus.
Each item in a submenu in the menu bar also has its own name for X resources; for example, the ‘File’ submenu has an item named ‘Save (current buffer)’. A resource specification for a submenu item looks like this:
Emacs.pane.menubar.popup_*.menu.item.resource: value
For example, here's how to specify the font for the ‘Save (current buffer)’ item:
Emacs.pane.menubar.popup_*.File.Save (current buffer).fontList: 8x16
For an item in a second-level submenu, such as ‘Complete Word’ under ‘Spell Checking’ under ‘Tools’, the resource fits this template:
Emacs.pane.menubar.popup_*.popup_*.menu.resource: value
For example,
Emacs.pane.menubar.popup_*.popup_*.Spell Checking.Complete Word: value
(This should be one long line.)
It's impossible to specify a resource for all the menu-bar items without also specifying it for the submenus as well. So if you want the submenu items to look different from the menu bar itself, you must ask for that in two steps. First, specify the resource for all of them; then, override the value for submenus alone. Here is an example:
Emacs.pane.menubar.*.fontList: 8x16 Emacs.pane.menubar.popup_*.fontList: 8x16
For LessTif pop-up menus, use ‘menu*’ instead of ‘pane.menubar’. For example, to specify the font ‘8x16’ for the pop-up menu items, write this:
Emacs.menu*.fontList: 8x16
For LessTif dialog boxes, use ‘dialog’ instead of ‘menu’:
Emacs.dialog*.fontList: 8x16 Emacs.dialog*.foreground: hotpink
To specify resources for the LessTif file-selection box, use ‘fsb*’, like this:
Emacs.fsb*.fontList: 8x16
Here is a list of the specific resources for LessTif menu bars and pop-up menus:
armColor
fontList
marginBottom
marginHeight
marginLeft
marginRight
marginTop
marginWidth
borderWidth
shadowThickness
bottomShadowColor
topShadowColor