Mercurial > emacs
annotate oldXMenu/ChgPane.c @ 101460:27ea311fecfa
2009-01-25 Carsten Dominik <dominik@science.uva.nl>
* org.texi (References): Add information about remote references.
(Built-in table editor): Document `C-c RET' in tables.
(Math symbols, Quoting LaTeX code): Mention that simple
LaTeX macros survive LaTeX export.
(Images in LaTeX export): Show how to create a reference to a
figure.
(Sectioning structure): Document that the LaTeX class can be
specified in a property.
(Text areas in HTML export): New section.
(External links): Add examples for text search and ID links.
(Built-in table editor): Remove the descriptio of `C-c
C-q', it not longer works.
(Literal examples): Document that a space must follow
the colon in short examples.
(Relative timer): Document `org-timer-stop'.
(Footnotes): New section.
(Footnote markup): Shorten section and refer to new Footnote
section.
(Literal examples): Add documentation for line
numbering in and references to code examples.
(CSS support): Fix the description of default CSS styles.
(Capturing column view): Document
"file:path/to/file.org" as an allowed value for the ID property of
a dynamic block copying column view.
author | Carsten Dominik <dominik@science.uva.nl> |
---|---|
date | Sun, 25 Jan 2009 15:54:29 +0000 |
parents | d4f6522bb9d2 |
children | e9f94688a064 5cc91198ffb2 |
rev | line source |
---|---|
76174
fec5e03aaf59
Remove FSF copyright since file does not differ significantly from X11
Glenn Morris <rgm@gnu.org>
parents:
75348
diff
changeset
|
1 /* Copyright Massachusetts Institute of Technology 1985 */ |
fec5e03aaf59
Remove FSF copyright since file does not differ significantly from X11
Glenn Morris <rgm@gnu.org>
parents:
75348
diff
changeset
|
2 |
25858 | 3 #include "copyright.h" |
4 | |
5 | |
6 /* | |
7 * XMenu: MIT Project Athena, X Window system menu package | |
8 * | |
9 * XMenuChangePane - Change the label of a menu pane. | |
10 * | |
11 * Author: Tony Della Fera, DEC | |
12 * December 19, 1985 | |
13 * | |
14 */ | |
15 | |
77868
d4f6522bb9d2
Quiet --with-x-toolkit=no compilation warnings: #include <config.h>.
Thien-Thi Nguyen <ttn@gnuvola.org>
parents:
76174
diff
changeset
|
16 #include <config.h> |
25858 | 17 #include "XMenuInt.h" |
18 | |
19 int | |
20 XMenuChangePane(menu, p_num, label) | |
21 register XMenu *menu; /* Menu object to be modified. */ | |
22 register int p_num; /* Pane number to be modified. */ | |
23 char *label; /* Selection label. */ | |
24 { | |
25 register XMPane *p_ptr; /* XMPane pointer. */ | |
26 | |
27 int label_length; /* Label length in characters. */ | |
28 int label_width; /* Label width in pixels. */ | |
29 | |
30 /* | |
31 * Check for NULL pointers! | |
32 */ | |
33 if (label == NULL) { | |
34 _XMErrorCode = XME_ARG_BOUNDS; | |
35 return(XM_FAILURE); | |
36 } | |
37 | |
38 /* | |
39 * Find the right pane. | |
40 */ | |
41 p_ptr = _XMGetPanePtr(menu, p_num); | |
42 if (p_ptr == NULL) return(XM_FAILURE); | |
43 | |
44 /* | |
45 * Determine label size. | |
46 */ | |
47 label_length = strlen(label); | |
48 label_width = XTextWidth(menu->p_fnt_info, label, label_length); | |
49 | |
50 /* | |
51 * Change the pane data. | |
52 */ | |
53 p_ptr->label = label; | |
54 p_ptr->label_width = label_width; | |
55 p_ptr->label_length = label_length; | |
56 | |
57 /* | |
58 * Schedule a recompute. | |
59 */ | |
60 menu->recompute = 1; | |
61 | |
62 /* | |
63 * Return the pane number just changed. | |
64 */ | |
65 _XMErrorCode = XME_NO_ERROR; | |
66 return(p_num); | |
67 } | |
52401 | 68 |
69 /* arch-tag: e267e9de-a3f0-4a0d-8c45-413afa176fd8 | |
70 (do not change this comment) */ |