Commit | Line | Data |
---|---|---|
94249313 | 1 | @c This is part of the Emacs manual. |
488dd4c4 | 2 | @c Copyright (C) 1987,93,94,95,1997,2001,03 Free Software Foundation, Inc. |
94249313 | 3 | @c See file emacs.texi for copying conditions. |
b4e112e7 | 4 | @node X Resources, Antinews, Emacs Invocation, Top |
82f6e63d | 5 | @appendix X Options and Resources |
94249313 | 6 | |
82f6e63d | 7 | You can customize some X-related aspects of Emacs behavior using X |
8c1691d8 JR |
8 | resources, as is usual for programs that use X. On MS-Windows, you |
9 | can customize some of the same aspects using the system registry. | |
10214524 RS |
10 | @xref{MS-Windows Registry}. |
11 | ||
12 | When Emacs is built using an `X toolkit', such as Lucid or LessTif, | |
13 | you need to use X resources to customize the appearance of the | |
14 | widgets, including the menu-bar, scroll-bar, and dialog boxes. This | |
15 | is because the libraries that implement these don't provide for | |
16 | customization through Emacs. GTK+ widgets use a separate system of | |
17 | `GTK resources', which we will also describe. | |
405f4489 RS |
18 | |
19 | @menu | |
82f6e63d RS |
20 | * Resources:: Using X resources with Emacs (in general). |
21 | * Table of Resources:: Table of specific X resources that affect Emacs. | |
22 | * Face Resources:: X resources for customizing faces. | |
405f4489 RS |
23 | * Lucid Resources:: X resources for Lucid menus. |
24 | * LessTif Resources:: X resources for LessTif and Motif menus. | |
488dd4c4 | 25 | * GTK resources:: Resources for GTK widgets. |
405f4489 RS |
26 | @end menu |
27 | ||
113c2ede | 28 | @node Resources |
94249313 RS |
29 | @appendixsec X Resources |
30 | @cindex resources | |
4fc31427 RS |
31 | @cindex X resources |
32 | @cindex @file{~/.Xdefaults} file | |
33 | @cindex @file{~/.Xresources} file | |
94249313 | 34 | |
9b7e4229 RS |
35 | Programs running under the X Window System organize their user |
36 | options under a hierarchy of classes and resources. You can specify | |
37 | default values for these options in your X resources file, usually | |
02e740dc DL |
38 | named @file{~/.Xdefaults} or @file{~/.Xresources}. |
39 | If changes in @file{~/.Xdefaults} do not | |
9b7e4229 RS |
40 | take effect, it is because your X server stores its own list of |
41 | resources; to update them, use the shell command @command{xrdb}---for | |
42 | instance, @samp{xrdb ~/.Xdefaults}. | |
94249313 RS |
43 | |
44 | Each line in the file specifies a value for one option or for a | |
45 | collection of related options, for one program or for several programs | |
46 | (optionally even for all programs). | |
47 | ||
48 | @cindex Registry (MS-Windows) | |
94249313 RS |
49 | MS-Windows systems don't support @file{~/.Xdefaults} files, but |
50 | Emacs compiled for Windows looks for X resources in the Windows | |
eca274b1 RS |
51 | Registry, under the key @samp{HKEY_CURRENT_USER\SOFTWARE\GNU\Emacs} |
52 | and then under the key @samp{HKEY_LOCAL_MACHINE\SOFTWARE\GNU\Emacs}. | |
b15fa8b1 JR |
53 | The menu and scrollbars are native widgets on MS-Windows, so they are |
54 | only customizable via the system-wide settings in the Display Control | |
3eff9df2 RS |
55 | Panel. You can also set resources using the @samp{-xrm} command line |
56 | option (see below.) | |
94249313 RS |
57 | |
58 | Programs define named resources with particular meanings. They also | |
59 | define how to group resources into named classes. For instance, in | |
60 | Emacs, the @samp{internalBorder} resource controls the width of the | |
61 | internal border, and the @samp{borderWidth} resource controls the width | |
62 | of the external border. Both of these resources are part of the | |
63 | @samp{BorderWidth} class. Case distinctions are significant in these | |
64 | names. | |
65 | ||
10214524 RS |
66 | Every resource definition is associated with a specific program |
67 | name---the name of the executable file that you ran. For Emacs, that | |
68 | is normally @samp{emacs}. To specify a definition for all instances | |
69 | of Emacs, regardless of their names, use @samp{Emacs}. | |
70 | ||
94249313 RS |
71 | In @file{~/.Xdefaults}, you can specify a value for a single resource |
72 | on one line, like this: | |
73 | ||
74 | @example | |
75 | emacs.borderWidth: 2 | |
76 | @end example | |
77 | ||
78 | @noindent | |
79 | Or you can use a class name to specify the same value for all resources | |
80 | in that class. Here's an example: | |
81 | ||
82 | @example | |
83 | emacs.BorderWidth: 2 | |
84 | @end example | |
85 | ||
86 | If you specify a value for a class, it becomes the default for all | |
87 | resources in that class. You can specify values for individual | |
88 | resources as well; these override the class value, for those particular | |
89 | resources. Thus, this example specifies 2 as the default width for all | |
90 | borders, but overrides this value with 4 for the external border: | |
91 | ||
92 | @example | |
93 | emacs.BorderWidth: 2 | |
94 | emacs.borderWidth: 4 | |
95 | @end example | |
96 | ||
97 | The order in which the lines appear in the file does not matter. | |
98 | Also, command-line options always override the X resources file. | |
10214524 RS |
99 | Here is a list of X command-line options and their corresponding |
100 | resource names. | |
94249313 RS |
101 | |
102 | @table @samp | |
103 | @item -name @var{name} | |
104 | @opindex --name | |
105 | @itemx --name=@var{name} | |
106 | @cindex resource name, command-line argument | |
107 | Use @var{name} as the resource name (and the title) for the initial | |
108 | Emacs frame. This option does not affect subsequent frames, but Lisp | |
109 | programs can specify frame names when they create frames. | |
110 | ||
111 | If you don't specify this option, the default is to use the Emacs | |
112 | executable's name as the resource name. | |
113 | ||
114 | @item -xrm @var{resource-values} | |
115 | @opindex --xrm | |
116 | @itemx --xrm=@var{resource-values} | |
117 | @cindex resource values, command-line argument | |
118 | Specify X resource values for this Emacs job (see below). | |
119 | @end table | |
120 | ||
121 | For consistency, @samp{-name} also specifies the name to use for | |
122 | other resource values that do not belong to any particular frame. | |
123 | ||
124 | The resources that name Emacs invocations also belong to a class; its | |
125 | name is @samp{Emacs}. If you write @samp{Emacs} instead of | |
126 | @samp{emacs}, the resource applies to all frames in all Emacs jobs, | |
127 | regardless of frame titles and regardless of the name of the executable | |
128 | file. Here is an example: | |
129 | ||
130 | @example | |
131 | Emacs.BorderWidth: 2 | |
132 | Emacs.borderWidth: 4 | |
133 | @end example | |
134 | ||
135 | You can specify a string of additional resource values for Emacs to | |
136 | use with the command line option @samp{-xrm @var{resources}}. The text | |
137 | @var{resources} should have the same format that you would use inside a file | |
138 | of X resources. To include multiple resource specifications in | |
139 | @var{resources}, put a newline between them, just as you would in a file. | |
140 | You can also use @samp{#include "@var{filename}"} to include a file full | |
141 | of resource specifications. Resource values specified with @samp{-xrm} | |
142 | take precedence over all other resource specifications. | |
143 | ||
82f6e63d RS |
144 | One way to experiment with the effect of different resource settings |
145 | is to use the @code{editres} program. Select @samp{Get Tree} from the | |
146 | @samp{Commands} menu, then click on an Emacs frame. This will display | |
147 | a tree showing the structure of X toolkit widgets used in an Emacs | |
148 | frame. Select one of them, such as @samp{menubar}, then select | |
149 | @samp{Show Resource Box} from the @samp{Commands} menu. This displays | |
150 | a list of all the meaningful X resources and allows you to edit them. | |
151 | Changes take effect immediately if you click on the @samp{Apply} button. | |
f2daf7e9 | 152 | (See the @code{editres} man page for more details.) |
82f6e63d RS |
153 | |
154 | @node Table of Resources | |
155 | @appendixsec Table of X Resources for Emacs | |
156 | ||
157 | This table lists the resource names that designate options for | |
9b7e4229 RS |
158 | Emacs, not counting those for the appearance of the menu bar, each |
159 | with the class that it belongs to: | |
94249313 RS |
160 | |
161 | @table @asis | |
162 | @item @code{background} (class @code{Background}) | |
163 | Background color name. | |
164 | ||
165 | @item @code{bitmapIcon} (class @code{BitmapIcon}) | |
166 | Use a bitmap icon (a picture of a gnu) if @samp{on}, let the window | |
167 | manager choose an icon if @samp{off}. | |
168 | ||
169 | @item @code{borderColor} (class @code{BorderColor}) | |
170 | Color name for the external border. | |
171 | ||
172 | @item @code{borderWidth} (class @code{BorderWidth}) | |
173 | Width in pixels of the external border. | |
174 | ||
175 | @item @code{cursorColor} (class @code{Foreground}) | |
176 | Color name for text cursor (point). | |
177 | ||
ed0fb1f1 JD |
178 | @item @code{cursorBlink} (class @code{CursorBlink}) |
179 | Specifies whether to make the cursor blink. The default is @samp{on}. Use | |
180 | @samp{off} or @samp{false} to turn cursor blinking off. | |
181 | ||
94249313 RS |
182 | @item @code{font} (class @code{Font}) |
183 | Font name for text (or fontset name, @pxref{Fontsets}). | |
184 | ||
185 | @item @code{foreground} (class @code{Foreground}) | |
186 | Color name for text. | |
187 | ||
188 | @item @code{geometry} (class @code{Geometry}) | |
189 | Window size and position. Be careful not to specify this resource as | |
190 | @samp{emacs*geometry}, because that may affect individual menus as well | |
191 | as the Emacs frame itself. | |
192 | ||
193 | If this resource specifies a position, that position applies only to the | |
194 | initial Emacs frame (or, in the case of a resource for a specific frame | |
195 | name, only that frame). However, the size, if specified here, applies to | |
196 | all frames. | |
197 | ||
e1556251 | 198 | @item @code{fullscreen} (class @code{Fullscreen}) |
cf225974 EZ |
199 | The desired fullscreen size. The value can be one of @code{fullboth}, |
200 | @code{fullwidth} or @code{fullheight}, which correspond to | |
201 | the command-line options @samp{-fs}, @samp{-fw}, and @samp{-fh} | |
202 | (@pxref{Window Size X}). | |
e1556251 EZ |
203 | |
204 | Note that this applies to all frames created, not just the initial | |
205 | one. | |
206 | ||
94249313 RS |
207 | @item @code{iconName} (class @code{Title}) |
208 | Name to display in the icon. | |
209 | ||
210 | @item @code{internalBorder} (class @code{BorderWidth}) | |
211 | Width in pixels of the internal border. | |
212 | ||
213 | @item @code{lineSpacing} (class @code{LineSpacing}) | |
214 | @cindex line spacing | |
215 | @cindex leading | |
216 | Additional space (@dfn{leading}) between lines, in pixels. | |
217 | ||
218 | @item @code{menuBar} (class @code{MenuBar}) | |
d90a6f50 | 219 | @cindex menu bar |
9b7e4229 RS |
220 | Give frames menu bars if @samp{on}; don't have menu bars if |
221 | @samp{off}. @xref{Lucid Resources}, and @ref{LessTif Resources}, for | |
222 | how to control the appearance of the menu bar if you have one. | |
94249313 | 223 | |
94249313 RS |
224 | @item @code{minibuffer} (class @code{Minibuffer}) |
225 | If @samp{none}, don't make a minibuffer in this frame. | |
226 | It will use a separate minibuffer frame instead. | |
227 | ||
228 | @item @code{paneFont} (class @code{Font}) | |
229 | @cindex font for menus | |
230 | Font name for menu pane titles, in non-toolkit versions of Emacs. | |
231 | ||
232 | @item @code{pointerColor} (class @code{Foreground}) | |
233 | Color of the mouse cursor. | |
234 | ||
94249313 RS |
235 | @item @code{privateColormap} (class @code{PrivateColormap}) |
236 | If @samp{on}, use a private color map, in the case where the ``default | |
237 | visual'' of class PseudoColor and Emacs is using it. | |
94249313 RS |
238 | |
239 | @item @code{reverseVideo} (class @code{ReverseVideo}) | |
240 | Switch foreground and background default colors if @samp{on}, use colors as | |
241 | specified if @samp{off}. | |
242 | ||
243 | @item @code{screenGamma} (class @code{ScreenGamma}) | |
244 | @cindex gamma correction | |
245 | Gamma correction for colors, equivalent to the frame parameter | |
246 | @code{screen-gamma}. | |
247 | ||
02e740dc | 248 | @item @code{selectionFont} (class @code{SelectionFont}) |
94249313 RS |
249 | Font name for pop-up menu items, in non-toolkit versions of Emacs. (For |
250 | toolkit versions, see @ref{Lucid Resources}, also see @ref{LessTif | |
251 | Resources}.) | |
252 | ||
02e740dc DL |
253 | @item @code{selectionTimeout} (class @code{SelectionTimeout}) |
254 | Number of milliseconds to wait for a selection reply. | |
255 | If the selection owner doesn't reply in this time, we give up. | |
256 | A value of 0 means wait as long as necessary. | |
257 | ||
94249313 RS |
258 | @item @code{synchronous} (class @code{Synchronous}) |
259 | @cindex debugging X problems | |
260 | @cindex synchronous X mode | |
261 | Run Emacs in synchronous mode if @samp{on}. Synchronous mode is | |
262 | useful for debugging X problems. | |
263 | ||
264 | @item @code{title} (class @code{Title}) | |
265 | Name to display in the title bar of the initial Emacs frame. | |
266 | ||
4fc31427 | 267 | @item @code{toolBar} (class @code{ToolBar}) |
d90a6f50 | 268 | @cindex tool bar |
4fc31427 RS |
269 | Number of lines to reserve for the tool bar. A zero value suppresses |
270 | the tool bar. If the value is non-zero and | |
271 | @code{auto-resize-tool-bars} is non-@code{nil}, the tool bar's size | |
272 | will be changed automatically so that all tool bar items are visible. | |
273 | ||
d90a6f50 DL |
274 | @item @code{useXIM} (class @code{UseXIM}) |
275 | @cindex XIM | |
276 | @cindex X input methods | |
277 | @cindex input methods, X | |
278 | Turn off use of X input methods (XIM) if @samp{false} or @samp{off}. | |
279 | This is only relevant if your Emacs is actually built with XIM | |
280 | support. It is potentially useful to turn off XIM for efficiency, | |
281 | especially slow X client/server links. | |
282 | ||
94249313 RS |
283 | @item @code{verticalScrollBars} (class @code{ScrollBars}) |
284 | Give frames scroll bars if @samp{on}; don't have scroll bars if | |
285 | @samp{off}. | |
10214524 RS |
286 | |
287 | @item @code{visualClass} (class @code{VisualClass}) | |
288 | Specify the ``visual'' that X should use. This tells X how to handle | |
289 | colors. | |
290 | ||
291 | The value should start with one of @samp{TrueColor}, | |
292 | @samp{PseudoColor}, @samp{DirectColor}, @samp{StaticColor}, | |
293 | @samp{GrayScale}, and @samp{StaticGray}, followed by | |
294 | @samp{-@var{depth}}, where @var{depth} is the number of color planes. | |
295 | Most terminals only allow a few ``visuals,'' and the @samp{dpyinfo} | |
296 | program outputs information saying which ones. | |
94249313 RS |
297 | @end table |
298 | ||
82f6e63d RS |
299 | @node Face Resources |
300 | @appendixsec X Resources for Faces | |
301 | ||
302 | You can also use resources to customize the appearance of particular | |
303 | faces (@pxref{Faces}): | |
94249313 RS |
304 | |
305 | @table @code | |
306 | @item @var{face}.attributeFont | |
307 | Font for face @var{face}. | |
308 | @item @var{face}.attributeForeground | |
309 | Foreground color for face @var{face}. | |
310 | @item @var{face}.attributeBackground | |
311 | Background color for face @var{face}. | |
312 | @item @var{face}.attributeUnderline | |
313 | Underline flag for face @var{face}. Use @samp{on} or @samp{true} for | |
314 | yes. | |
315 | @item @var{face}.attributeFamily | |
316 | Font family for face @var{face}. | |
317 | @item @var{face}.attributeWidth | |
318 | Relative proportional width of the font to use for face @var{face}. | |
319 | It should be one of @code{ultra-condensed}, @code{extra-condensed}, | |
320 | @code{condensed}, @code{semi-condensed}, @code{normal}, | |
321 | @code{semi-expanded}, @code{expanded}, @code{extra-expanded}, or | |
322 | @code{ultra-expanded}. | |
323 | @item @var{face}.attributeHeight | |
324 | Height of the font to use for face @var{face}: either an integer | |
325 | specifying the height in units of 1/10@dmn{pt}, or a floating point | |
326 | number that specifies a scale factor to scale the underlying face's | |
327 | default font, or a function to be called with the default height which | |
328 | will return a new height. | |
329 | @item @var{face}.attributeWeight | |
330 | A weight to use for the face @var{face}. It must be one of | |
331 | @code{ultra-bold}, @code{extra-bold}, @code{bold}, | |
332 | @code{semi-bold}, @code{normal}, @code{semi-light}, @code{light}, | |
333 | @code{extra-light}, @code{ultra-light}. | |
334 | @item @var{face}.attributeSlant | |
335 | The slant to use for the font of face @var{face}. It must be one of | |
336 | @code{italic}, @code{oblique}, @code{normal}, | |
337 | @code{reverse-italic}, or @code{reverse-oblique}. | |
338 | @item @var{face}.attributeStrikeThrough | |
339 | Whether the face @var{face} should be drawn with a line striking | |
340 | through the characters. | |
341 | @item @var{face}.attributeOverline | |
342 | Whether the characters in the face @var{face} should be overlined. | |
343 | @item @var{face}.attributeBox | |
344 | Whether to draw a box around the characters in face @var{face}. | |
345 | @item @var{face}.attributeInverse | |
346 | Whether to display the characters in face @var{face} in inverse | |
347 | video. | |
348 | @item @var{face}.attributeStipple | |
349 | The name of a pixmap data file to use for the stipple pattern, or | |
350 | @code{false} to not use stipple for the face @var{face}. | |
351 | @item @var{face}.attributeBackgroundPixmap | |
352 | The background pixmap for the face @var{face}. Should be a name of a | |
353 | pixmap file or @code{false}. | |
354 | @item @var{face}.attributeBold | |
355 | Whether to draw the characters in the face @var{face} as bold. | |
356 | @item @var{face}.attributeItalic | |
357 | Whether to draw the characters in the face @var{face} as italic. | |
358 | @end table | |
359 | ||
360 | @node Lucid Resources | |
361 | @appendixsec Lucid Menu X Resources | |
362 | @cindex Menu X Resources (Lucid widgets) | |
363 | @cindex Lucid Widget X Resources | |
364 | ||
365 | If the Emacs installed at your site was built to use the X toolkit | |
366 | with the Lucid menu widgets, then the menu bar is a separate widget and | |
367 | has its own resources. The resource names contain @samp{pane.menubar} | |
368 | (following, as always, the name of the Emacs invocation, or @samp{Emacs}, | |
369 | which stands for all Emacs invocations). Specify them like this: | |
370 | ||
371 | @example | |
372 | Emacs.pane.menubar.@var{resource}: @var{value} | |
373 | @end example | |
374 | ||
375 | @noindent | |
376 | For example, to specify the font @samp{8x16} for the menu-bar items, | |
377 | write this: | |
378 | ||
379 | @example | |
380 | Emacs.pane.menubar.font: 8x16 | |
381 | @end example | |
382 | ||
383 | @noindent | |
384 | Resources for @emph{non-menubar} toolkit pop-up menus have | |
385 | @samp{menu*}, in like fashion. For example, to specify the font | |
386 | @samp{8x16} for the pop-up menu items, write this: | |
387 | ||
388 | @example | |
389 | Emacs.menu*.font: 8x16 | |
390 | @end example | |
391 | ||
392 | @noindent | |
393 | For dialog boxes, use @samp{dialog} instead of @samp{menu}: | |
394 | ||
395 | @example | |
396 | Emacs.dialog*.font: 8x16 | |
397 | @end example | |
398 | ||
0d0e15c3 JD |
399 | @noindent |
400 | The Lucid menus can display multilingual text in your locale. For more | |
401 | information about fontsets see the man page for XCreateFontSet. To enable | |
402 | multilingual menu text you specify a fontSet resource instead of the font | |
403 | resource. If both font and fontSet resources are specified, the fontSet | |
404 | resource is used. To specify | |
405 | @samp{-*-helvetica-medium-r-*--*-120-*-*-*-*-*-*,*} for both the popup and | |
406 | menu bar menus, write this: | |
407 | ||
408 | @example | |
409 | Emacs*fontSet: -*-helvetica-medium-r-*--*-120-*-*-*-*-*-*,* | |
410 | @end example | |
411 | ||
94249313 RS |
412 | @noindent |
413 | Experience shows that on some systems you may need to add | |
414 | @samp{shell.}@: before the @samp{pane.menubar} or @samp{menu*}. On | |
415 | some other systems, you must not add @samp{shell.}. | |
416 | ||
417 | Here is a list of the specific resources for menu bars and pop-up menus: | |
418 | ||
419 | @table @code | |
420 | @item font | |
421 | Font for menu item text. | |
0d0e15c3 JD |
422 | @item fontSet |
423 | Fontset for menu item text. | |
94249313 RS |
424 | @item foreground |
425 | Color of the foreground. | |
426 | @item background | |
427 | Color of the background. | |
428 | @item buttonForeground | |
429 | In the menu bar, the color of the foreground for a selected item. | |
430 | @item horizontalSpacing | |
431 | Horizontal spacing in pixels between items. Default is 3. | |
432 | @item verticalSpacing | |
f2daf7e9 | 433 | Vertical spacing in pixels between items. Default is 2. |
94249313 RS |
434 | @item arrowSpacing |
435 | Horizontal spacing between the arrow (which indicates a submenu) and | |
436 | the associated text. Default is 10. | |
437 | @item shadowThickness | |
f2daf7e9 LT |
438 | Thickness of shadow line around the widget. Default is 1. |
439 | ||
440 | Also determines the thickness of shadow lines around other objects, | |
441 | for instance 3D buttons and arrows. If you have the impression that | |
442 | the arrows in the menus do not stand out clearly enough or that the | |
443 | difference between ``in'' and ``out'' buttons is difficult to see, set | |
444 | this to 2. If you have no problems with visibility, the default | |
445 | probably looks better. The background color may also have some effect | |
446 | on the contrast. | |
94249313 | 447 | @item margin |
f2daf7e9 | 448 | The margin of the menu bar, in characters. Default is 1. |
94249313 RS |
449 | @end table |
450 | ||
451 | @node LessTif Resources | |
452 | @appendixsec LessTif Menu X Resources | |
453 | @cindex Menu X Resources (LessTif widgets) | |
454 | @cindex LessTif Widget X Resources | |
455 | ||
456 | If the Emacs installed at your site was built to use the X toolkit | |
457 | with the LessTif or Motif widgets, then the menu bar, the dialog | |
458 | boxes, the pop-up menus, and the file-selection box are separate | |
459 | widgets and have their own resources. | |
460 | ||
461 | The resource names for the menu bar contain @samp{pane.menubar} | |
462 | (following, as always, the name of the Emacs invocation, or | |
463 | @samp{Emacs}, which stands for all Emacs invocations). Specify them | |
464 | like this: | |
465 | ||
466 | @smallexample | |
467 | Emacs.pane.menubar.@var{subwidget}.@var{resource}: @var{value} | |
468 | @end smallexample | |
469 | ||
470 | Each individual string in the menu bar is a subwidget; the subwidget's | |
471 | name is the same as the menu item string. For example, the word | |
472 | @samp{File} in the menu bar is part of a subwidget named | |
473 | @samp{emacs.pane.menubar.File}. Most likely, you want to specify the | |
474 | same resources for the whole menu bar. To do this, use @samp{*} instead | |
475 | of a specific subwidget name. For example, to specify the font | |
476 | @samp{8x16} for the menu-bar items, write this: | |
477 | ||
478 | @smallexample | |
479 | Emacs.pane.menubar.*.fontList: 8x16 | |
480 | @end smallexample | |
481 | ||
482 | @noindent | |
483 | This also specifies the resource value for submenus. | |
484 | ||
485 | Each item in a submenu in the menu bar also has its own name for X | |
486 | resources; for example, the @samp{File} submenu has an item named | |
487 | @samp{Save (current buffer)}. A resource specification for a submenu | |
488 | item looks like this: | |
489 | ||
490 | @smallexample | |
491 | Emacs.pane.menubar.popup_*.@var{menu}.@var{item}.@var{resource}: @var{value} | |
492 | @end smallexample | |
493 | ||
494 | @noindent | |
495 | For example, here's how to specify the font for the @samp{Save (current | |
496 | buffer)} item: | |
497 | ||
498 | @smallexample | |
499 | Emacs.pane.menubar.popup_*.File.Save (current buffer).fontList: 8x16 | |
500 | @end smallexample | |
501 | ||
502 | @noindent | |
503 | For an item in a second-level submenu, such as @samp{Complete Word} | |
504 | under @samp{Spell Checking} under @samp{Tools}, the resource fits this | |
505 | template: | |
506 | ||
507 | @smallexample | |
508 | Emacs.pane.menubar.popup_*.popup_*.@var{menu}.@var{resource}: @var{value} | |
509 | @end smallexample | |
510 | ||
511 | @noindent | |
512 | For example, | |
513 | ||
514 | @smallexample | |
515 | Emacs.pane.menubar.popup_*.popup_*.Spell Checking.Complete Word: @var{value} | |
516 | @end smallexample | |
517 | ||
518 | @noindent | |
519 | (This should be one long line.) | |
177c0ea7 | 520 | |
94249313 RS |
521 | It's impossible to specify a resource for all the menu-bar items |
522 | without also specifying it for the submenus as well. So if you want the | |
523 | submenu items to look different from the menu bar itself, you must ask | |
524 | for that in two steps. First, specify the resource for all of them; | |
525 | then, override the value for submenus alone. Here is an example: | |
526 | ||
527 | @smallexample | |
528 | Emacs.pane.menubar.*.fontList: 8x16 | |
529 | Emacs.pane.menubar.popup_*.fontList: 8x16 | |
530 | @end smallexample | |
531 | ||
532 | @noindent | |
533 | For LessTif pop-up menus, use @samp{menu*} instead of | |
534 | @samp{pane.menubar}. For example, to specify the font @samp{8x16} for | |
535 | the pop-up menu items, write this: | |
536 | ||
537 | @smallexample | |
538 | Emacs.menu*.fontList: 8x16 | |
539 | @end smallexample | |
540 | ||
541 | @noindent | |
542 | For LessTif dialog boxes, use @samp{dialog} instead of @samp{menu}: | |
543 | ||
544 | @example | |
545 | Emacs.dialog*.fontList: 8x16 | |
546 | Emacs.dialog*.foreground: hotpink | |
547 | @end example | |
548 | ||
549 | To specify resources for the LessTif file-selection box, use | |
550 | @samp{fsb*}, like this: | |
551 | ||
552 | @example | |
553 | Emacs.fsb*.fontList: 8x16 | |
554 | @end example | |
555 | ||
556 | @iftex | |
557 | @medbreak | |
558 | @end iftex | |
559 | Here is a list of the specific resources for LessTif menu bars and | |
560 | pop-up menus: | |
561 | ||
562 | @table @code | |
563 | @item armColor | |
564 | The color to show in an armed button. | |
565 | @item fontList | |
566 | The font to use. | |
567 | @item marginBottom | |
568 | @itemx marginHeight | |
569 | @itemx marginLeft | |
570 | @itemx marginRight | |
571 | @itemx marginTop | |
572 | @itemx marginWidth | |
573 | Amount of space to leave around the item, within the border. | |
574 | @item borderWidth | |
575 | The width of the border around the menu item, on all sides. | |
576 | @item shadowThickness | |
577 | The width of the border shadow. | |
578 | @item bottomShadowColor | |
579 | The color for the border shadow, on the bottom and the right. | |
580 | @item topShadowColor | |
581 | The color for the border shadow, on the top and the left. | |
582 | @end table | |
488dd4c4 JD |
583 | |
584 | ||
585 | @node GTK resources | |
586 | @appendixsec GTK resources | |
587 | @cindex GTK resources and customization | |
588 | @cindex resource files for GTK | |
589 | @cindex @file{~/.gtkrc-2.0} file | |
590 | @cindex @file{~/.emacs.d/gtkrc} file | |
591 | ||
10214524 RS |
592 | If Emacs was built to use the GTK widget set, then the menu bar, |
593 | scroll bar and the dialogs are customized with the standard GTK | |
594 | customization file, @file{~/.gtkrc-2.0}, or with the Emacs specific | |
595 | file @file{~/.emacs.d/gtkrc}. We recommend that you use | |
596 | @file{~/.emacs.d/gtkrc} for customizations, since @file{~/.gtkrc-2.0} | |
597 | seems to be ignored when running GConf with GNOME. These files apply | |
598 | only to GTK widget features. To customize Emacs font, background, | |
599 | faces, etc., use the normal X resources (@pxref{Resources}). | |
488dd4c4 | 600 | |
9543c58c | 601 | Some GTK themes override these mechanisms, which means that using |
10214524 | 602 | these mechanisms will not work to customize them. |
583a618e | 603 | |
10214524 RS |
604 | In these files you first define a style and say what it means; then |
605 | you specify to apply the style to various widget types (@pxref{GTK | |
606 | widget names}). Here is an example of how to change the font for | |
607 | Emacs menus: | |
488dd4c4 JD |
608 | |
609 | @smallexample | |
10214524 | 610 | # @r{Define the style @samp{metafont}.} |
488dd4c4 JD |
611 | style "menufont" |
612 | @{ | |
613 | font_name = "helvetica bold 14" # This is a Pango font name | |
614 | @} | |
615 | ||
10214524 | 616 | # @r{Specify that widget type @samp{*emacs-menuitem*} uses @samp{metafont}.} |
488dd4c4 | 617 | widget "*emacs-menuitem*" style "menufont" |
583a618e JD |
618 | @end smallexample |
619 | ||
620 | Here is a more elaborate example, showing how to change the parts of | |
621 | the scroll bar: | |
9543c58c | 622 | |
583a618e JD |
623 | @smallexample |
624 | style "scroll" | |
625 | @{ | |
10214524 RS |
626 | fg[NORMAL] = "red"@ @ @ @ @ # @r{The arrow color.} |
627 | bg[NORMAL] = "yellow"@ @ # @r{The thumb and background around the arrow.} | |
628 | bg[ACTIVE] = "blue"@ @ @ @ # @r{The trough color.} | |
629 | bg[PRELIGHT] = "white"@ # @r{The thumb color when the mouse is over it.} | |
583a618e JD |
630 | @} |
631 | ||
632 | widget "*verticalScrollBar*" style "scroll" | |
488dd4c4 JD |
633 | @end smallexample |
634 | ||
2d21bf9e EZ |
635 | There are also parameters that affect GTK as a whole. For example, |
636 | the property @code{gtk-font-name} sets the default font for GTK. You | |
637 | must use Pango font names (@pxref{GTK styles}). A GTK resources file | |
638 | that just sets a default font looks like this: | |
488dd4c4 JD |
639 | |
640 | @smallexample | |
641 | gtk-font-name = "courier 12" | |
642 | @end smallexample | |
643 | ||
10214524 RS |
644 | The GTK resources file is fully described in the GTK API document. |
645 | This can be found in | |
646 | @file{@var{prefix}/share/gtk-doc/html/gtk/gtk-resource-files.html}, | |
647 | where @file{prefix} is the directory in which the GTK libraries were | |
648 | installed (usually @file{/usr} or @file{/usr/local}). You can also | |
649 | find the document online, at | |
488dd4c4 JD |
650 | @uref{http://developer.gnome.org/doc/API/2.0/gtk/gtk-Resource-Files.html}. |
651 | ||
488dd4c4 JD |
652 | @menu |
653 | * GTK widget names:: How widgets in GTK are named in general. | |
0e76e1ea | 654 | * GTK Names in Emacs:: GTK widget names in Emacs. |
488dd4c4 JD |
655 | * GTK styles:: What can be customized in a GTK widget. |
656 | @end menu | |
657 | ||
488dd4c4 JD |
658 | @node GTK widget names |
659 | @appendixsubsec GTK widget names | |
660 | @cindex GTK widget names | |
661 | ||
10214524 RS |
662 | A GTK widget is specified by its @dfn{widget class} and |
663 | @dfn{widget name}. The widget class is the type of the widget: for | |
664 | example, @code{GtkMenuBar}. The widget name is the name given to a | |
665 | specific widget. A widget always has a class, but need not have a | |
666 | name. | |
488dd4c4 | 667 | |
10214524 RS |
668 | @dfn{Absolute names} are sequences of widget names or widget |
669 | classes, corresponding to hierarchies of widgets embedded within | |
670 | other widgets. For example, if a @code{GtkWindow} named @code{top} | |
671 | contains a @code{GtkVBox} named @code{box}, which in turn contains | |
672 | a @code{GtkMenuBar} called @code{menubar}, the absolute class name | |
673 | of the menu-bar widget is @code{GtkWindow.GtkVBox.GtkMenuBar}, and | |
674 | its absolute widget name is @code{top.box.menubar}. | |
488dd4c4 JD |
675 | |
676 | When assigning a style to a widget, you can use the absolute class | |
677 | name or the absolute widget name. | |
10214524 RS |
678 | |
679 | There are two commands to specify changes for widgets: | |
680 | ||
681 | @table @asis | |
682 | @item @code{widget_class} | |
683 | specifies a style for widgets based on the absolute class name. | |
684 | ||
685 | @item @code{widget} | |
686 | specifies a style for widgets based on the absolute class name, | |
687 | or just the class. | |
688 | @end table | |
689 | ||
690 | @noindent | |
3eff9df2 RS |
691 | You must specify the class and the style in double-quotes, and put |
692 | these commands at the top level in the GTK customization file, like | |
10214524 | 693 | this: |
488dd4c4 JD |
694 | |
695 | @smallexample | |
696 | style "menufont" | |
697 | @{ | |
698 | font_name = "helvetica bold 14" | |
699 | @} | |
700 | ||
701 | widget "top.box.menubar" style "menufont" | |
702 | widget_class "GtkWindow.GtkVBox.GtkMenuBar" style "menufont" | |
703 | @end smallexample | |
704 | ||
10214524 RS |
705 | Matching of absolute names uses shell wildcard syntax: @samp{*} |
706 | matches zero or more characters and @samp{?} matches one character. | |
707 | This example assigns @code{base_style} to all widgets: | |
488dd4c4 JD |
708 | |
709 | @smallexample | |
710 | widget "*" style "base_style" | |
711 | @end smallexample | |
712 | ||
713 | Given the absolute class name @code{GtkWindow.GtkVBox.GtkMenuBar} | |
10214524 RS |
714 | and the corresponding absolute widget name @code{top.box.menubar}, all |
715 | these examples specify @code{my_style} for the menu bar: | |
488dd4c4 JD |
716 | |
717 | @smallexample | |
718 | widget_class "GtkWindow.GtkVBox.GtkMenuBar" style "my_style" | |
719 | widget_class "GtkWindow.*.GtkMenuBar" style "my_style" | |
720 | widget_class "*GtkMenuBar" style "my_style" | |
721 | widget "top.box.menubar" style "my_style" | |
722 | widget "*box*menubar" style "my_style" | |
723 | widget "*menubar" style "my_style" | |
724 | widget "*menu*" style "my_style" | |
725 | @end smallexample | |
726 | ||
10214524 RS |
727 | @node GTK Names in Emacs |
728 | @appendixsubsec GTK Widget Names in Emacs | |
488dd4c4 JD |
729 | @cindex GTK widget names |
730 | @cindex GTK widget classes | |
731 | ||
10214524 RS |
732 | In Emacs, the top level widget for a frame is a @code{GtkWindow} |
733 | that contains a @code{GtkVBox}. The @code{GtkVBox} contains the | |
734 | @code{GtkMenuBar} and a @code{GtkFixed} widget. The vertical scroll | |
735 | bars, @code{GtkVScrollbar}, are contained in the @code{GtkFixed} | |
736 | widget. The text you write in Emacs is drawn in the @code{GtkFixed} | |
737 | widget. | |
488dd4c4 JD |
738 | |
739 | Dialogs in Emacs are @code{GtkDialog} widgets. The file dialog is a | |
740 | @code{GtkFileSelection} widget. | |
741 | ||
742 | @noindent | |
743 | To set a style for the menu bar using the absolute class name, use: | |
744 | ||
745 | @smallexample | |
746 | widget_class "GtkWindow.GtkVBox.GtkMenuBar" style "my_style" | |
747 | @end smallexample | |
748 | ||
749 | @noindent | |
750 | For the scroll bar, the absolute class name is: | |
751 | ||
752 | @smallexample | |
177c0ea7 | 753 | widget_class |
488dd4c4 JD |
754 | "GtkWindow.GtkVBox.GtkFixed.GtkVScrollbar" |
755 | style "my_style" | |
756 | @end smallexample | |
757 | ||
758 | @noindent | |
759 | The names for the emacs widgets, and their classes, are: | |
760 | ||
761 | @multitable {@code{verticalScrollbar plus}} {@code{GtkFileSelection} and some} | |
762 | @item @code{emacs-filedialog} | |
763 | @tab @code{GtkFileSelection} | |
764 | @item @code{emacs-dialog} | |
765 | @tab @code{GtkDialog} | |
766 | @item @code{Emacs} | |
767 | @tab @code{GtkWindow} | |
768 | @item @code{pane} | |
769 | @tab @code{GtkVHbox} | |
770 | @item @code{emacs} | |
771 | @tab @code{GtkFixed} | |
a1f3b57e | 772 | @item @code{verticalScrollBar} |
488dd4c4 | 773 | @tab @code{GtkVScrollbar} |
1094ef26 JD |
774 | @item @code{emacs-toolbar} |
775 | @tab @code{GtkToolbar} | |
776 | @item @code{menubar} | |
777 | @tab @code{GtkMenuBar} | |
488dd4c4 JD |
778 | @item @code{emacs-menuitem} |
779 | @tab anything in menus | |
780 | @end multitable | |
781 | ||
782 | @noindent | |
783 | Thus, for Emacs you can write the two examples above as: | |
784 | ||
785 | @smallexample | |
786 | widget "Emacs.pane.menubar" style "my_style" | |
a1f3b57e | 787 | widget "Emacs.pane.emacs.verticalScrollBar" style "my_style" |
488dd4c4 JD |
788 | @end smallexample |
789 | ||
790 | GTK absolute names are quite strange when it comes to menus | |
177c0ea7 | 791 | and dialogs. The names do not start with @samp{Emacs}, as they are |
488dd4c4 JD |
792 | free-standing windows and not contained (in the GTK sense) by the |
793 | Emacs GtkWindow. To customize the dialogs and menus, use wildcards like this: | |
794 | ||
795 | @smallexample | |
796 | widget "*emacs-dialog*" style "my_dialog_style" | |
797 | widget "*emacs-filedialog* style "my_file_style" | |
798 | widget "*emacs-menuitem* style "my_menu_style" | |
799 | @end smallexample | |
800 | ||
10214524 RS |
801 | If you specify a customization in @file{~/.emacs.d/gtkrc}, then it |
802 | automatically applies only to Emacs, since other programs don't read | |
803 | that file. For example, the drop down menu in the file dialog can not | |
804 | be customized by any absolute widget name, only by an absolute class | |
3eff9df2 | 805 | name. This is because the widgets in the drop down menu do not |
10214524 RS |
806 | have names and the menu is not contained in the Emacs GtkWindow. To |
807 | have all menus in Emacs look the same, use this in | |
808 | @file{~/.emacs.d/gtkrc}: | |
488dd4c4 JD |
809 | |
810 | @smallexample | |
811 | widget_class "*Menu*" style "my_menu_style" | |
812 | @end smallexample | |
813 | ||
814 | @node GTK styles | |
815 | @appendixsubsec GTK styles | |
816 | @cindex GTK styles | |
817 | ||
818 | In a GTK style you specify the appearance widgets shall have. You | |
10214524 RS |
819 | can specify foreground and background color, background pixmap and |
820 | font. The edit widget (where you edit the text) in Emacs is a GTK | |
821 | widget, but trying to specify a style for the edit widget will have no | |
822 | effect. This is so that Emacs compiled for GTK is compatible with | |
823 | Emacs compiled for other X toolkits. The settings for foreground, | |
824 | background and font for the edit widget is taken from the X resources; | |
825 | @pxref{Resources}. Here is an example of two style declarations, | |
826 | @samp{default} and @samp{ruler}: | |
488dd4c4 JD |
827 | |
828 | @smallexample | |
488dd4c4 JD |
829 | pixmap_path "/usr/share/pixmaps:/usr/include/X11/pixmaps" |
830 | ||
831 | style "default" | |
832 | @{ | |
833 | font_name = "helvetica 12" | |
834 | ||
835 | bg[NORMAL] = @{ 0.83, 0.80, 0.73 @} | |
836 | bg[SELECTED] = @{ 0.0, 0.55, 0.55 @} | |
837 | bg[INSENSITIVE] = @{ 0.77, 0.77, 0.66 @} | |
838 | bg[ACTIVE] = @{ 0.0, 0.55, 0.55 @} | |
839 | bg[PRELIGHT] = @{ 0.0, 0.55, 0.55 @} | |
840 | ||
841 | fg[NORMAL] = "black" | |
842 | fg[SELECTED] = @{ 0.9, 0.9, 0.9 @} | |
843 | fg[ACTIVE] = "black" | |
844 | fg[PRELIGHT] = @{ 0.9, 0.9, 0.9 @} | |
845 | ||
846 | base[INSENSITIVE] = "#777766" | |
847 | text[INSENSITIVE] = @{ 0.60, 0.65, 0.57 @} | |
848 | ||
849 | bg_pixmap[NORMAL] = "background.xpm" | |
850 | bg_pixmap[INSENSITIVE] = "background.xpm" | |
851 | bg_pixmap[ACTIVE] = "background.xpm" | |
177c0ea7 | 852 | bg_pixmap[PRELIGHT] = "<none>" |
488dd4c4 JD |
853 | |
854 | @} | |
855 | ||
856 | style "ruler" = "default" | |
857 | @{ | |
858 | font_name = "helvetica 8" | |
859 | @} | |
860 | ||
861 | @end smallexample | |
862 | ||
10214524 | 863 | The style @samp{ruler} inherits from @samp{default}. This way you can build |
488dd4c4 JD |
864 | on existing styles. The syntax for fonts and colors is described below. |
865 | ||
10214524 RS |
866 | As this example shows, it is possible to specify several values for |
867 | foreground and background depending on the widget's @dfn{state}. The | |
868 | possible states are: | |
869 | ||
488dd4c4 JD |
870 | @table @code |
871 | @item NORMAL | |
872 | This is the default state for widgets. | |
873 | @item ACTIVE | |
874 | This is the state for a widget that is ready to do something. It is | |
177c0ea7 | 875 | also for the trough of a scroll bar, i.e. @code{bg[ACTIVE] = "red"} |
488dd4c4 JD |
876 | sets the scroll bar trough to red. Buttons that have been pressed but |
877 | not released yet (``armed'') are in this state. | |
878 | @item PRELIGHT | |
879 | This is the state when widgets that can be manipulated have the mouse | |
880 | pointer over them. For example when the mouse is over the thumb in the | |
881 | scroll bar or over a menu item. When the mouse is over a button that | |
882 | is not pressed, the button is in this state. | |
883 | @item SELECTED | |
884 | This is the state when some data has been selected by the user. It can | |
885 | be selected text or items selected in a list. | |
886 | There is no place in Emacs where this setting has any effect. | |
887 | @item INSENSITIVE | |
888 | This is the state for widgets that are visible, but they can not be | |
10214524 RS |
889 | manipulated in the usual way---for example, buttons that can't be |
890 | pressed, and disabled menu items. To display disabled menu items in | |
891 | yellow, use @code{fg[INSENSITIVE] = "yellow"}. | |
488dd4c4 JD |
892 | @end table |
893 | ||
10214524 | 894 | Here are the things that can go in a style declaration: |
488dd4c4 JD |
895 | |
896 | @table @code | |
897 | @item bg[@var{state}] = @var{color} | |
10214524 RS |
898 | This specifies the background color for the widget. Note that |
899 | editable text doesn't use @code{bg}; it uses @code{base} instead. | |
488dd4c4 JD |
900 | |
901 | @item base[@var{state}] = @var{color} | |
10214524 RS |
902 | This specifies the background color for editable text. In Emacs, this |
903 | color is used for the background of the text fields in the file | |
904 | dialog. | |
488dd4c4 JD |
905 | |
906 | @item bg_pixmap[@var{state}] = "@var{pixmap}" | |
10214524 RS |
907 | This specifies an image background (instead of a background color). |
908 | @var{pixmap} should be the image file name. GTK can use a number of | |
909 | image file formats, including XPM, XBM, GIF, JPEG and PNG. If you | |
910 | want a widget to use the same image as its parent, use | |
911 | @samp{<parent>}. If you don't want any image, use @samp{<none>}. | |
912 | @samp{<none>} is the way to cancel a background image inherited from a | |
913 | parent style. | |
914 | ||
915 | You can't specify the file by its absolute file name. GTK looks for | |
916 | the pixmap file in directories specified in @code{pixmap_path}. | |
917 | @code{pixmap_path} is a colon-separated list of directories within | |
918 | double quotes, specified at the top level in a @file{gtkrc} file | |
919 | (i.e. not inside a style definition; see example above): | |
488dd4c4 JD |
920 | |
921 | @smallexample | |
922 | pixmap_path "/usr/share/pixmaps:/usr/include/X11/pixmaps" | |
923 | @end smallexample | |
924 | ||
925 | @item fg[@var{state}] = @var{color} | |
10214524 RS |
926 | This specifies the foreground color for widgets to use. It is the |
927 | color of text in menus and buttons, and the color for the arrows in | |
928 | the scroll bar. For editable text, use @code{text}. | |
488dd4c4 JD |
929 | |
930 | @item text[@var{state}] = @var{color} | |
177c0ea7 | 931 | This is the color for editable text. In Emacs, this color is used for the |
488dd4c4 JD |
932 | text fields in the file dialog. |
933 | ||
934 | @item font_name = "@var{font}" | |
10214524 RS |
935 | This specifies the the font for text in the widget. @var{font} is a |
936 | Pango font name, for example @samp{Sans Italic 10}, @samp{Helvetica | |
937 | Bold 12}, @samp{Courier 14}, @samp{Times 18}. See below for exact | |
938 | syntax. The names are case insensitive. | |
488dd4c4 JD |
939 | @end table |
940 | ||
10214524 RS |
941 | There are three ways to specify a color: by name, in hexadecimal |
942 | form, and with an RGB triplet. | |
488dd4c4 JD |
943 | |
944 | @noindent | |
945 | A color name is written within double quotes, for example @code{"red"}. | |
946 | ||
947 | @noindent | |
10214524 RS |
948 | Hexadecimal form is the same as in X: |
949 | @code{#@var{rrrr}@var{gggg}@var{bbbb}}, where all three color specs | |
950 | must have the same number of hex digits (1, 2, 3 or 4). | |
488dd4c4 JD |
951 | |
952 | @noindent | |
10214524 RS |
953 | An RGB triplet looks like @code{@{ @var{r}, @var{g}, @var{b} @}}, |
954 | where @var{r}, @var{g} and @var{b} are either integers in the range | |
955 | 0-65535 or floats in the range 0.0-1.0. | |
488dd4c4 JD |
956 | |
957 | Pango font names have the form ``@var{family-list} @var{style-options} | |
958 | @var{size}''. | |
959 | @cindex Pango font name | |
960 | @noindent | |
961 | @var{family-list} is a comma separated list of font families optionally | |
962 | terminated by a comma. This way you can specify several families and the | |
963 | first one found will be used. @var{family} corresponds to the second part in | |
964 | an X font name, for example in | |
965 | ||
966 | @smallexample | |
967 | -adobe-times-medium-r-normal--12-120-75-75-p-64-iso10646-1 | |
968 | @end smallexample | |
969 | ||
970 | @noindent | |
971 | the family name is ``times''. | |
972 | ||
973 | @noindent | |
974 | @var{style-options} is a whitespace separated list of words where each word | |
975 | is a style, variant, weight, or stretch. The default value for all of | |
976 | these is @code{normal}. | |
977 | ||
978 | @noindent | |
979 | A `style' corresponds to the fourth part of an X font name. In X font | |
10214524 RS |
980 | names it is the character @samp{r}, @samp{i} or @samp{o}; in Pango |
981 | font names the corresponding values are @code{normal}, @code{italic}, | |
982 | or @code{oblique}. | |
488dd4c4 JD |
983 | |
984 | @noindent | |
985 | A `variant' is either @code{normal} or @code{small-caps}. | |
986 | Small caps is a font with the lower case characters replaced by | |
987 | smaller variants of the capital characters. | |
988 | ||
989 | @noindent | |
990 | Weight describes the ``boldness'' of a font. It corresponds to the third | |
991 | part of an X font name. It is one of @code{ultra-light}, @code{light}, | |
992 | @code{normal}, @code{bold}, @code{ultra-bold}, or @code{heavy}. | |
993 | ||
994 | @noindent | |
995 | Stretch gives the width of the font relative to other designs within a | |
996 | family. It corresponds to the fifth part of an X font name. It is one of | |
997 | @code{ultra-condensed}, @code{extra-condensed}, @code{condensed}, | |
998 | @code{semi-condensed}, @code{normal}, @code{semi-expanded}, | |
999 | @code{expanded}, @code{extra-expanded}, or @code{ultra-expanded}. | |
1000 | ||
1001 | @noindent | |
1002 | @var{size} is a decimal number that describes the font size in points. | |
ab5796a9 MB |
1003 | |
1004 | @ignore | |
1005 | arch-tag: 9b6ff773-48b6-41f6-b2f9-f114b8bdd97f | |
1006 | @end ignore |