-
Notifications
You must be signed in to change notification settings - Fork 791
Expand file tree
/
Copy pathui.src
More file actions
296 lines (244 loc) · 10.4 KB
/
ui.src
File metadata and controls
296 lines (244 loc) · 10.4 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html lang="en">
<!-- $Id: ui.src,v 2.16 1998-04-30 23:25:13 ijacobs Exp $ -->
<HEAD>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<TITLE>User interface</TITLE>
</HEAD>
<BODY>
<H1 align="center">User interface</H1>
<H2><a name="cursor-props">Cursors:</a> the <span
class="propinst-cursor">'cursor'</span> property</H2>
<!-- #include src=properties/cursor.srb -->
<P>This property specifies the type of cursor to be displayed for the
pointing device. Values have the following meanings:
<dl>
<dt><strong>auto</strong>
<dd>The UA determines the cursor to display based on the current
context.
<dt><strong>crosshair</strong>
<dd>A simple crosshair (e.g., short line segments resembling a "+" sign).
<dt><strong>default</strong>
<dd>The platform-dependent default cursor. Often rendered as an arrow.
<dt><strong>pointer</strong>
<dd>The cursor is a pointer that indicates a link.
<dt><strong>move</strong>
<dd>Indicates something is to be moved.
<dt><strong>e-resize, ne-resize, nw-resize, n-resize, se-resize,
sw-resize, s-resize, w-resize</strong>
<dd>Indicate that some edge is to be moved. For example, the
'se-resize' cursor is used when the movement starts from the
south-east corner of the box.
<dt><strong>text</strong>
<dd>Indicates text that may be selected. Often rendered as an I-bar.
<dt><strong>wait</strong>
<dd>Indicates that the program is busy and the user should
wait. Often rendered as a watch or hourglass.
<dt><strong>help</strong>
<dd>Help is available for the object under the cursor. Often rendered
as a question mark or a balloon.
<dt><span class="value-inst-uri"><strong><uri></strong></span>
<dd>The user agent retrieves the cursor from the resource
designated by the URI. If the user agent cannot handle
the first cursor of a list of cursors, it should attempt
to handle the second, etc. If the user agent cannot handle
any user-defined cursor, it must use the generic cursor
at the end of the list.
</dl>
<div class="example"><P>
<PRE>
P { cursor : url(mything.cur), url(second.csr), text; }
</PRE>
</div>
<H2><a name="system-colors">User preferences for colors</a></H2>
<p>In addition to being able to assign pre-defined <a
href="syndata.html#color-units">color values</a> to text, backgrounds,
etc., CSS2 allows authors to specify colors in a manner that
integrates them into the user's graphic environment. Style rules that
take into account user preferences thus offer the following
advantages:
<ol>
<li>They produce pages that fit the user's defined look and feel.</li>
<li>They produce pages that may be more accessible as the current user
settings may be related to a disability.</li>
</ol>
<p>The set of values defined for system colors is intended to be
exhaustive. For systems that do not have a corresponding value, the
specified value should be mapped to the nearest system attribute, or
to a default color.</p>
<p>The following lists additional values for color-related CSS
attributes and their general meaning. Any color property (e.g., <span
class="propinst-color">'color'</span> or <span
class="propinst-background-color">'background-color'</span>) can take
one of the following names:</p>
<dl>
<dt><strong>active-border</strong>
<dd>Active window border.
<dt><strong>active-caption</strong>
<dd>Active window caption.
<dt><strong>app-workspace</strong>
<dd>Background color of multiple document interface.
<dt><strong>background</strong>
<dd>Desktop background.
<dt><strong>button-face</strong>
<dd>Face color for three-dimensional display elements.
<dt><strong>button-highlight</strong>
<dd>Dark shadow for three-dimensional display elements (for
edges facing away from the light source).
<dt><strong>button-shadow</strong>
<dd>Shadow color for three-dimensional display elements.
<dt><strong>button-text</strong>
<dd>Text on push buttons.
<dt><strong>caption-text</strong>
<dd>Text in caption, size box, and scrollbar arrow box.
<dt><strong>gray-text</strong>
<dd>Grayed (disabled) text. This color is set to #000 if
the current display driver does not support a solid gray color.
<dt><strong>highlight</strong>
<dd>Item(s) selected in a control.
<dt><strong>highlight-text</strong>
<dd>Text of item(s) selected in a control.
<dt><strong>inactive-border</strong>
<dd>Inactive window border.
<dt><strong>inactive-caption</strong>
<dd>Inactive window caption.
<dt><strong>inactive-caption-text</strong>
<dd>Color of text in an inactive caption.
<dt><strong>info-background</strong>
<dd>Background color for tooltip controls.
<dt><strong>info-text</strong>
<dd>Text color for tooltip controls.
<dt><strong>menu</strong>
<dd>Menu background.
<dt><strong>menu-text</strong>
<dd>Text in menus.
<dt><strong>scrollbar</strong>
<dd>Scroll bar gray area.
<dt><strong>three-d-dark-shadow</strong>
<dd>Dark shadow for three-dimensional display elements.
<dt><strong>three-d-face</strong>
<dd>Face color for three-dimensional display elements.
<dt><strong>three-d-highlight</strong>
<dd>Highlight color for three-dimensional display elements.
<dt><strong>three-d-light-shadow</strong>
<dd>Light color for three-dimensional display elements
(for edges facing the light source).
<dt><strong>three-d-shadow</strong>
<dd>Dark shadow for three-dimensional display elements.
<dt><strong>window</strong>
<dd>Window background.
<dt><strong>window-frame</strong>
<dd>Window frame.
<dt><strong>window-text</strong>
<dd>Text in windows.
</dl>
<div class="example"><P>
For example, to set the foreground and background colors of a paragraph
to the same foreground and background colors of the user's window,
write the following:
<PRE>
P { color: window-text; background-color: window }
</PRE>
</div>
<H2><a name="system-fonts">User preferences for fonts</a></H2>
<P>As for colors, authors may specify fonts in a way that makes use of
a user's system resources. Please consult the <span
class="propinst-font">'font'</span> property for details.
<h2><a name="dynamic-outlines">Dynamic outlines:</a> the <span
class="index-def" title="outline">'outline'</span> property</h2>
<P>At times, style sheet authors may want to create outlines around
visual objects such as buttons, active form fields, image maps, etc.,
to make them stand out. CSS2 outlines differ from <a
href="box.html#border-properties">borders</a> in the following
ways:</p>
<ol>
<li>Outlines do not take up space.
<li>Outlines may be non-rectangular.
</ol>
<P>The outline properties control the style of these dynamic outlines.
<!-- #include src=properties/outline.srb -->
<!-- #include src=properties/outline-width.srb -->
<!-- #include src=properties/outline-style.srb -->
<!-- #include src=properties/outline-color.srb -->
<p>The outline created with the outline properties is drawn "over" a
box, i.e., the outline is always on top, and doesn't influence the
position or size of the box, or of any other boxes. Therefore,
displaying or suppressing outlines does not cause reflow.
<p>The outline is drawn starting just outside the <a
href="box.html#border-edge">border edge</a>.
<p>Outlines may be non-rectangular. For example, if the element is
broken across several lines, the outline is the minimum outline that
encloses all the element's boxes. In contrast to <a
href="box.html#border-properties">borders</a>, the outline is not
open at the line box's end or start, but is always fully connected.
<p>The <span class="propinst-outline-width">'outline-width'</span>
property accepts the same values as <span
class="propinst-border-width">'border-width'</span>.
<P>The <span class="propinst-outline-style">'outline-style'</span>
property accepts the same values as <span
class="propinst-border-style">'border-style'</span>,
except that 'hidden' is not a legal outline style.
<p>The <span class="propinst-outline-color">'outline-color'</span>
accepts all colors, as well as the keyword <span class="index-def"
title="invert"><a class="value-def"
name="value-def-invert">'invert'</a></span>. 'Invert' is expected to
perform a color inversion on the pixels on the screen. This is a
common trick to ensure the focus border is visible, regardless of
color background.
<p>The <span class="propinst-outline">'outline'</span> property is a
shorthand property, and sets all three of <span
class="propinst-outline-style">'outline-style'</span>, <span
class="propinst-outline-width">'outline-width'</span>, and <span
class="propinst-outline-color">'outline-color'</span>.
<p class="note">Note that the outline is the same on all sides. In
contrast to borders, there is no 'outline-top' or 'outline-left'
property.
<p>This specification does not define how multiple overlapping
outlines are drawn, or how outlines are drawn for boxes that are
partially obscured behind other elements.
<div class="note"><P>
<em><strong>Note.</strong>
Since the focus outline does not affect formatting (i.e., no
space is left for it in the box model), it may well overlap
other elements on the page.
</em>
</div>
<div class="example"><P>
Here's an example of drawing a
thick outline around a BUTTON element:
<PRE>
BUTTON { outline-width : thick }
</PRE>
<P>Scripts may be used to dynamically change the width
of the outline, without provoking reflow.
</div>
<H3>Outlines and the focus</h3>
<P>Graphical user interfaces may use outlines to tell the user which
element on the page has the <span class="index-def"
title="focus"><dfn>focus</dfn></span>. The focus is the subject of user
interaction in a document (e.g., for entering text, selecting a
button, etc.). User agents supporting the <a
href="media.html#interactive-media-group">interactive media group</a>
must keep track of where the focus lies and must also represent the
focus. This may be done by using dynamic outlines in conjunction
with the :focus pseudo-class.
<div class="example">
<p>For example, to draw a thick black line around an element when it
has the focus, and a thick red line when it is active, the following
rules can be used:
<pre>
:focus { outline: thick solid black }
:active { outline: thick solid red }
</pre>
</div>
<H2>Magnification</H2>
<P>The CSS working group considers that the magnification of a
document or portions of a document should not be specified through
style sheets. User agents may support such magnification in different ways
(e.g., larger images, louder sounds, etc.)
<P>When magnifying a page, UAs should preserve the relationships
between positioned elements. For example, a comic strip may be
composed of images with overlaid text elements. When magnifying this
page, a user agent should keep the text within the comic strip balloon.
</BODY>
</html>