Mercurial > hg > xemacs-beta
comparison lisp/objects.el @ 412:697ef44129c6 r21-2-14
Import from CVS: tag r21-2-14
author | cvs |
---|---|
date | Mon, 13 Aug 2007 11:20:41 +0200 |
parents | 501cfd01ee6d |
children |
comparison
equal
deleted
inserted
replaced
411:12e008d41344 | 412:697ef44129c6 |
---|---|
44 (defun make-font-specifier (spec-list) | 44 (defun make-font-specifier (spec-list) |
45 "Return a new `font' specifier object with the given specification list. | 45 "Return a new `font' specifier object with the given specification list. |
46 SPEC-LIST can be a list of specifications (each of which is a cons of a | 46 SPEC-LIST can be a list of specifications (each of which is a cons of a |
47 locale and a list of instantiators), a single instantiator, or a list | 47 locale and a list of instantiators), a single instantiator, or a list |
48 of instantiators. See `make-specifier' for more information about | 48 of instantiators. See `make-specifier' for more information about |
49 specifiers. | 49 specifiers." |
50 | |
51 Valid instantiators for font specifiers are: | |
52 | |
53 -- a string naming a font (e.g. under X this might be | |
54 \"-*-courier-medium-r-*-*-*-140-*-*-*-*-iso8859-*\" for a 14-point | |
55 upright medium-weight Courier font) | |
56 -- a font instance (use that instance directly if the device matches, | |
57 or use the string that generated it) | |
58 -- a vector of no elements (only on TTY's; this means to set no font | |
59 at all, thus using the \"natural\" font of the terminal's text) | |
60 -- a vector of one element (a face to inherit from) | |
61 " | |
62 (make-specifier-and-init 'font spec-list)) | 50 (make-specifier-and-init 'font spec-list)) |
63 | 51 |
64 (defun font-name (font &optional domain charset) | 52 (defun font-name (font &optional domain charset) |
65 "Return the name of the FONT in the specified DOMAIN, if any. | 53 "Return the name of the FONT in the specified DOMAIN, if any. |
66 FONT should be a font specifier object and DOMAIN is normally a window | 54 FONT should be a font specifier object and DOMAIN is normally a window |
137 (defun make-color-specifier (spec-list) | 125 (defun make-color-specifier (spec-list) |
138 "Return a new `color' specifier object with the given specification list. | 126 "Return a new `color' specifier object with the given specification list. |
139 SPEC-LIST can be a list of specifications (each of which is a cons of a | 127 SPEC-LIST can be a list of specifications (each of which is a cons of a |
140 locale and a list of instantiators), a single instantiator, or a list | 128 locale and a list of instantiators), a single instantiator, or a list |
141 of instantiators. See `make-specifier' for a detailed description of | 129 of instantiators. See `make-specifier' for a detailed description of |
142 how specifiers work. | 130 how specifiers work." |
143 | |
144 Valid instantiators for color specifiers are: | |
145 | |
146 -- a string naming a color (e.g. under X this might be \"lightseagreen2\" | |
147 or \"#F534B2\") | |
148 -- a color instance (use that instance directly if the device matches, | |
149 or use the string that generated it) | |
150 -- a vector of no elements (only on TTY's; this means to set no color | |
151 at all, thus using the \"natural\" color of the terminal's text) | |
152 -- a vector of one or two elements: a face to inherit from, and | |
153 optionally a symbol naming which property of that face to inherit, | |
154 either `foreground' or `background' (if omitted, defaults to the same | |
155 property that this color specifier is used for; if this specifier is | |
156 not part of a face, the instantiator would not be valid)." | |
157 (make-specifier-and-init 'color spec-list)) | 131 (make-specifier-and-init 'color spec-list)) |
158 | 132 |
159 (defun color-name (color &optional domain) | 133 (defun color-name (color &optional domain) |
160 "Return the name of the COLOR in the specified DOMAIN, if any. | 134 "Return the name of the COLOR in the specified DOMAIN, if any. |
161 COLOR should be a color specifier object and DOMAIN is normally a window | 135 COLOR should be a color specifier object and DOMAIN is normally a window |
170 and defaults to the selected window if omitted. This is equivalent | 144 and defaults to the selected window if omitted. This is equivalent |
171 to using `specifier-instance' and applying `color-instance-rgb-components' | 145 to using `specifier-instance' and applying `color-instance-rgb-components' |
172 to the result. See `make-specifier' for more information about specifiers." | 146 to the result. See `make-specifier' for more information about specifiers." |
173 (ws-object-property-1 'color-instance-rgb-components color domain)) | 147 (ws-object-property-1 'color-instance-rgb-components color domain)) |
174 | 148 |
175 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; face-boolean specifiers | |
176 | |
177 (defun make-face-boolean-specifier (spec-list) | |
178 "Return a new `face-boolean' specifier object with the given spec list. | |
179 SPEC-LIST can be a list of specifications (each of which is a cons of a | |
180 locale and a list of instantiators), a single instantiator, or a list | |
181 of instantiators. See `make-specifier' for a detailed description of | |
182 how specifiers work. | |
183 | |
184 Valid instantiators for face-boolean specifiers are | |
185 | |
186 -- t or nil | |
187 -- a vector of two or three elements: a face to inherit from, | |
188 optionally a symbol naming the property of that face to inherit from | |
189 (if omitted, defaults to the same property that this face-boolean | |
190 specifier is used for; if this specifier is not part of a face, | |
191 the instantiator would not be valid), and optionally a value which, | |
192 if non-nil, means to invert the sense of the inherited property." | |
193 (make-specifier-and-init 'color spec-list)) | |
194 | |
195 ;;; objects.el ends here. | 149 ;;; objects.el ends here. |