1 : /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 : /* ***** BEGIN LICENSE BLOCK *****
3 : * Version: MPL 1.1/GPL 2.0/LGPL 2.1
4 : *
5 : * The contents of this file are subject to the Mozilla Public License Version
6 : * 1.1 (the "License"); you may not use this file except in compliance with
7 : * the License. You may obtain a copy of the License at
8 : * http://www.mozilla.org/MPL/
9 : *
10 : * Software distributed under the License is distributed on an "AS IS" basis,
11 : * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
12 : * for the specific language governing rights and limitations under the
13 : * License.
14 : *
15 : * The Original Code is mozilla.org code.
16 : *
17 : * The Initial Developer of the Original Code is
18 : * Netscape Communications Corporation.
19 : * Portions created by the Initial Developer are Copyright (C) 1998
20 : * the Initial Developer. All Rights Reserved.
21 : *
22 : * Contributor(s):
23 : * Mats Palmgren <matspal@gmail.com>
24 : * Jonathon Jongsma <jonathon.jongsma@collabora.co.uk>, Collabora Ltd.
25 : *
26 : * Alternatively, the contents of this file may be used under the terms of
27 : * either of the GNU General Public License Version 2 or later (the "GPL"),
28 : * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
29 : * in which case the provisions of the GPL or the LGPL are applicable instead
30 : * of those above. If you wish to allow use of your version of this file only
31 : * under the terms of either the GPL or the LGPL, and not to allow others to
32 : * use your version of this file under the terms of the MPL, indicate your
33 : * decision by deleting the provisions above and replace them with the notice
34 : * and other provisions required by the GPL or the LGPL. If you do not delete
35 : * the provisions above, a recipient may use your version of this file under
36 : * the terms of any one of the MPL, the GPL or the LGPL.
37 : *
38 : * ***** END LICENSE BLOCK ***** */
39 :
40 : /* constants used in the style struct data provided by nsStyleContext */
41 :
42 : #ifndef nsStyleConsts_h___
43 : #define nsStyleConsts_h___
44 :
45 : #include "gfxRect.h"
46 : #include "nsFont.h"
47 :
48 : // XXX fold this into nsStyleContext and group by nsStyleXXX struct
49 :
50 : // Indices into border/padding/margin arrays
51 : #define NS_SIDE_TOP mozilla::css::eSideTop
52 : #define NS_SIDE_RIGHT mozilla::css::eSideRight
53 : #define NS_SIDE_BOTTOM mozilla::css::eSideBottom
54 : #define NS_SIDE_LEFT mozilla::css::eSideLeft
55 :
56 : #define NS_FOR_CSS_SIDES(var_) for (mozilla::css::Side var_ = NS_SIDE_TOP; var_ <= NS_SIDE_LEFT; var_++)
57 0 : static inline mozilla::css::Side operator++(mozilla::css::Side& side, int) {
58 0 : NS_PRECONDITION(side >= NS_SIDE_TOP &&
59 : side <= NS_SIDE_LEFT, "Out of range side");
60 0 : side = mozilla::css::Side(side + 1);
61 0 : return side;
62 : }
63 :
64 : #define NS_FOR_CSS_FULL_CORNERS(var_) for (PRInt32 var_ = 0; var_ < 4; ++var_)
65 :
66 : // Indices into "half corner" arrays (nsStyleCorners e.g.)
67 : #define NS_CORNER_TOP_LEFT_X 0
68 : #define NS_CORNER_TOP_LEFT_Y 1
69 : #define NS_CORNER_TOP_RIGHT_X 2
70 : #define NS_CORNER_TOP_RIGHT_Y 3
71 : #define NS_CORNER_BOTTOM_RIGHT_X 4
72 : #define NS_CORNER_BOTTOM_RIGHT_Y 5
73 : #define NS_CORNER_BOTTOM_LEFT_X 6
74 : #define NS_CORNER_BOTTOM_LEFT_Y 7
75 :
76 : #define NS_FOR_CSS_HALF_CORNERS(var_) for (PRInt32 var_ = 0; var_ < 8; ++var_)
77 :
78 : // The results of these conversion macros are exhaustively checked in
79 : // nsStyleCoord.cpp.
80 : // Arguments must not have side effects.
81 :
82 : #define NS_HALF_CORNER_IS_X(var_) (!((var_)%2))
83 : #define NS_HALF_TO_FULL_CORNER(var_) ((var_)/2)
84 : #define NS_FULL_TO_HALF_CORNER(var_, vert_) ((var_)*2 + !!(vert_))
85 :
86 : #define NS_SIDE_IS_VERTICAL(side_) ((side_) % 2)
87 : #define NS_SIDE_TO_FULL_CORNER(side_, second_) \
88 : (((side_) + !!(second_)) % 4)
89 : #define NS_SIDE_TO_HALF_CORNER(side_, second_, parallel_) \
90 : ((((side_) + !!(second_))*2 + ((side_) + !(parallel_))%2) % 8)
91 :
92 : // {margin,border-{width,style,color},padding}-{left,right}-{ltr,rtl}-source
93 : #define NS_BOXPROP_SOURCE_PHYSICAL 0
94 : #define NS_BOXPROP_SOURCE_LOGICAL 1
95 :
96 : // box-sizing
97 : #define NS_STYLE_BOX_SIZING_CONTENT 0
98 : #define NS_STYLE_BOX_SIZING_PADDING 1
99 : #define NS_STYLE_BOX_SIZING_BORDER 2
100 :
101 : // box-shadow
102 : #define NS_STYLE_BOX_SHADOW_INSET 0
103 :
104 : // float-edge
105 : #define NS_STYLE_FLOAT_EDGE_CONTENT 0
106 : #define NS_STYLE_FLOAT_EDGE_MARGIN 1
107 :
108 : // user-focus
109 : #define NS_STYLE_USER_FOCUS_NONE 0
110 : #define NS_STYLE_USER_FOCUS_IGNORE 1
111 : #define NS_STYLE_USER_FOCUS_NORMAL 2
112 : #define NS_STYLE_USER_FOCUS_SELECT_ALL 3
113 : #define NS_STYLE_USER_FOCUS_SELECT_BEFORE 4
114 : #define NS_STYLE_USER_FOCUS_SELECT_AFTER 5
115 : #define NS_STYLE_USER_FOCUS_SELECT_SAME 6
116 : #define NS_STYLE_USER_FOCUS_SELECT_MENU 7
117 :
118 : // user-select
119 : #define NS_STYLE_USER_SELECT_NONE 0
120 : #define NS_STYLE_USER_SELECT_TEXT 1
121 : #define NS_STYLE_USER_SELECT_ELEMENT 2
122 : #define NS_STYLE_USER_SELECT_ELEMENTS 3
123 : #define NS_STYLE_USER_SELECT_ALL 4
124 : #define NS_STYLE_USER_SELECT_TOGGLE 5
125 : #define NS_STYLE_USER_SELECT_TRI_STATE 6
126 : #define NS_STYLE_USER_SELECT_AUTO 7 // internal value - please use nsFrame::IsSelectable()
127 : #define NS_STYLE_USER_SELECT_MOZ_ALL 8 // force selection of all children, unless an ancestor has NONE set - bug 48096
128 : #define NS_STYLE_USER_SELECT_MOZ_NONE 9 // Like NONE, but doesn't change selection behavior for descendants whose user-select is not AUTO.
129 :
130 : // user-input
131 : #define NS_STYLE_USER_INPUT_NONE 0
132 : #define NS_STYLE_USER_INPUT_ENABLED 1
133 : #define NS_STYLE_USER_INPUT_DISABLED 2
134 : #define NS_STYLE_USER_INPUT_AUTO 3
135 :
136 : // user-modify
137 : #define NS_STYLE_USER_MODIFY_READ_ONLY 0
138 : #define NS_STYLE_USER_MODIFY_READ_WRITE 1
139 : #define NS_STYLE_USER_MODIFY_WRITE_ONLY 2
140 :
141 : // box-align
142 : #define NS_STYLE_BOX_ALIGN_STRETCH 0
143 : #define NS_STYLE_BOX_ALIGN_START 1
144 : #define NS_STYLE_BOX_ALIGN_CENTER 2
145 : #define NS_STYLE_BOX_ALIGN_BASELINE 3
146 : #define NS_STYLE_BOX_ALIGN_END 4
147 :
148 : // box-pack
149 : #define NS_STYLE_BOX_PACK_START 0
150 : #define NS_STYLE_BOX_PACK_CENTER 1
151 : #define NS_STYLE_BOX_PACK_END 2
152 : #define NS_STYLE_BOX_PACK_JUSTIFY 3
153 :
154 : // box-direction
155 : #define NS_STYLE_BOX_DIRECTION_NORMAL 0
156 : #define NS_STYLE_BOX_DIRECTION_REVERSE 1
157 :
158 : // box-orient
159 : #define NS_STYLE_BOX_ORIENT_HORIZONTAL 0
160 : #define NS_STYLE_BOX_ORIENT_VERTICAL 1
161 :
162 : // orient
163 : #define NS_STYLE_ORIENT_HORIZONTAL 0
164 : #define NS_STYLE_ORIENT_VERTICAL 1
165 :
166 : // stack-sizing
167 : #define NS_STYLE_STACK_SIZING_IGNORE 0
168 : #define NS_STYLE_STACK_SIZING_STRETCH_TO_FIT 1
169 :
170 : // Azimuth - See nsStyleAural
171 : #define NS_STYLE_AZIMUTH_LEFT_SIDE 0x00
172 : #define NS_STYLE_AZIMUTH_FAR_LEFT 0x01
173 : #define NS_STYLE_AZIMUTH_LEFT 0x02
174 : #define NS_STYLE_AZIMUTH_CENTER_LEFT 0x03
175 : #define NS_STYLE_AZIMUTH_CENTER 0x04
176 : #define NS_STYLE_AZIMUTH_CENTER_RIGHT 0x05
177 : #define NS_STYLE_AZIMUTH_RIGHT 0x06
178 : #define NS_STYLE_AZIMUTH_FAR_RIGHT 0x07
179 : #define NS_STYLE_AZIMUTH_RIGHT_SIDE 0x08
180 : #define NS_STYLE_AZIMUTH_BEHIND 0x80 // bits
181 : #define NS_STYLE_AZIMUTH_LEFTWARDS 0x10 // bits
182 : #define NS_STYLE_AZIMUTH_RIGHTWARDS 0x20 // bits
183 :
184 : // See nsStyleAural
185 : #define NS_STYLE_ELEVATION_BELOW 1
186 : #define NS_STYLE_ELEVATION_LEVEL 2
187 : #define NS_STYLE_ELEVATION_ABOVE 3
188 : #define NS_STYLE_ELEVATION_HIGHER 4
189 : #define NS_STYLE_ELEVATION_LOWER 5
190 :
191 : // See nsStyleAural
192 : #define NS_STYLE_PITCH_X_LOW 1
193 : #define NS_STYLE_PITCH_LOW 2
194 : #define NS_STYLE_PITCH_MEDIUM 3
195 : #define NS_STYLE_PITCH_HIGH 4
196 : #define NS_STYLE_PITCH_X_HIGH 5
197 :
198 : // See nsStyleAural
199 : #define NS_STYLE_SPEAK_NONE 0
200 : #define NS_STYLE_SPEAK_NORMAL 1
201 : #define NS_STYLE_SPEAK_SPELL_OUT 2
202 :
203 : // See nsStyleAural
204 : #define NS_STYLE_SPEAK_HEADER_ONCE 0
205 : #define NS_STYLE_SPEAK_HEADER_ALWAYS 1
206 :
207 : // See nsStyleAural
208 : #define NS_STYLE_SPEAK_NUMERAL_DIGITS 0
209 : #define NS_STYLE_SPEAK_NUMERAL_CONTINUOUS 1
210 :
211 : // See nsStyleAural
212 : #define NS_STYLE_SPEAK_PUNCTUATION_NONE 0
213 : #define NS_STYLE_SPEAK_PUNCTUATION_CODE 1
214 :
215 : // See nsStyleAural
216 : #define NS_STYLE_SPEECH_RATE_X_SLOW 0
217 : #define NS_STYLE_SPEECH_RATE_SLOW 1
218 : #define NS_STYLE_SPEECH_RATE_MEDIUM 2
219 : #define NS_STYLE_SPEECH_RATE_FAST 3
220 : #define NS_STYLE_SPEECH_RATE_X_FAST 4
221 : #define NS_STYLE_SPEECH_RATE_FASTER 10
222 : #define NS_STYLE_SPEECH_RATE_SLOWER 11
223 :
224 : // See nsStyleAural
225 : #define NS_STYLE_VOLUME_SILENT 0
226 : #define NS_STYLE_VOLUME_X_SOFT 1
227 : #define NS_STYLE_VOLUME_SOFT 2
228 : #define NS_STYLE_VOLUME_MEDIUM 3
229 : #define NS_STYLE_VOLUME_LOUD 4
230 : #define NS_STYLE_VOLUME_X_LOUD 5
231 :
232 : // See nsStyleColor
233 : #define NS_STYLE_COLOR_MOZ_USE_TEXT_COLOR 1
234 : #define NS_STYLE_COLOR_INHERIT_FROM_BODY 2 /* Can't come from CSS directly */
235 :
236 : // See nsStyleColor
237 : #define NS_COLOR_CURRENTCOLOR -1
238 : #define NS_COLOR_MOZ_DEFAULT_COLOR -2
239 : #define NS_COLOR_MOZ_DEFAULT_BACKGROUND_COLOR -3
240 : #define NS_COLOR_MOZ_HYPERLINKTEXT -4
241 : #define NS_COLOR_MOZ_VISITEDHYPERLINKTEXT -5
242 : #define NS_COLOR_MOZ_ACTIVEHYPERLINKTEXT -6
243 :
244 : // See nsStyleDisplay
245 : #define NS_STYLE_ANIMATION_DIRECTION_NORMAL 0
246 : #define NS_STYLE_ANIMATION_DIRECTION_ALTERNATE 1
247 :
248 : // See nsStyleDisplay
249 : #define NS_STYLE_ANIMATION_FILL_MODE_NONE 0
250 : #define NS_STYLE_ANIMATION_FILL_MODE_FORWARDS 1
251 : #define NS_STYLE_ANIMATION_FILL_MODE_BACKWARDS 2
252 : #define NS_STYLE_ANIMATION_FILL_MODE_BOTH 3
253 :
254 : // See nsStyleDisplay
255 : #define NS_STYLE_ANIMATION_ITERATION_COUNT_INFINITE 0
256 :
257 : // See nsStyleDisplay
258 : #define NS_STYLE_ANIMATION_PLAY_STATE_RUNNING 0
259 : #define NS_STYLE_ANIMATION_PLAY_STATE_PAUSED 1
260 :
261 : // See nsStyleBackground
262 : #define NS_STYLE_BG_ATTACHMENT_SCROLL 0
263 : #define NS_STYLE_BG_ATTACHMENT_FIXED 1
264 :
265 : // See nsStyleBackground
266 : // Code depends on these constants having the same values as BG_ORIGIN_*
267 : #define NS_STYLE_BG_CLIP_BORDER 0
268 : #define NS_STYLE_BG_CLIP_PADDING 1
269 : #define NS_STYLE_BG_CLIP_CONTENT 2
270 : // A magic value that we use for our "pretend that background-clip is
271 : // 'padding' when we have a solid border" optimization. This isn't
272 : // actually equal to NS_STYLE_BG_CLIP_PADDING because using that
273 : // causes antialiasing seams between the background and border. This
274 : // is a backend-only value.
275 : #define NS_STYLE_BG_CLIP_MOZ_ALMOST_PADDING 127
276 :
277 : // See nsStyleBackground
278 : #define NS_STYLE_BG_INLINE_POLICY_EACH_BOX 0
279 : #define NS_STYLE_BG_INLINE_POLICY_CONTINUOUS 1
280 : #define NS_STYLE_BG_INLINE_POLICY_BOUNDING_BOX 2
281 :
282 : // See nsStyleBackground
283 : // Code depends on these constants having the same values as BG_CLIP_*
284 : #define NS_STYLE_BG_ORIGIN_BORDER 0
285 : #define NS_STYLE_BG_ORIGIN_PADDING 1
286 : #define NS_STYLE_BG_ORIGIN_CONTENT 2
287 :
288 : // See nsStyleBackground
289 : // The parser code depends on |ing these values together.
290 : #define NS_STYLE_BG_POSITION_CENTER (1<<0)
291 : #define NS_STYLE_BG_POSITION_TOP (1<<1)
292 : #define NS_STYLE_BG_POSITION_BOTTOM (1<<2)
293 : #define NS_STYLE_BG_POSITION_LEFT (1<<3)
294 : #define NS_STYLE_BG_POSITION_RIGHT (1<<4)
295 :
296 : // See nsStyleBackground
297 : #define NS_STYLE_BG_REPEAT_NO_REPEAT 0x00
298 : #define NS_STYLE_BG_REPEAT_REPEAT_X 0x01
299 : #define NS_STYLE_BG_REPEAT_REPEAT_Y 0x02
300 : #define NS_STYLE_BG_REPEAT_REPEAT 0x03
301 :
302 : // See nsStyleBackground
303 : #define NS_STYLE_BG_SIZE_CONTAIN 0
304 : #define NS_STYLE_BG_SIZE_COVER 1
305 :
306 : // See nsStyleTable
307 : #define NS_STYLE_BORDER_COLLAPSE 0
308 : #define NS_STYLE_BORDER_SEPARATE 1
309 :
310 : // Possible enumerated specified values of border-*-width, used by nsCSSMargin
311 : #define NS_STYLE_BORDER_WIDTH_THIN 0
312 : #define NS_STYLE_BORDER_WIDTH_MEDIUM 1
313 : #define NS_STYLE_BORDER_WIDTH_THICK 2
314 : // XXX chopping block #define NS_STYLE_BORDER_WIDTH_LENGTH_VALUE 3
315 :
316 : // See nsStyleBorder mBorderStyle
317 : #define NS_STYLE_BORDER_STYLE_NONE 0
318 : #define NS_STYLE_BORDER_STYLE_GROOVE 1
319 : #define NS_STYLE_BORDER_STYLE_RIDGE 2
320 : #define NS_STYLE_BORDER_STYLE_DOTTED 3
321 : #define NS_STYLE_BORDER_STYLE_DASHED 4
322 : #define NS_STYLE_BORDER_STYLE_SOLID 5
323 : #define NS_STYLE_BORDER_STYLE_DOUBLE 6
324 : #define NS_STYLE_BORDER_STYLE_INSET 7
325 : #define NS_STYLE_BORDER_STYLE_OUTSET 8
326 : #define NS_STYLE_BORDER_STYLE_HIDDEN 9
327 : #define NS_STYLE_BORDER_STYLE_AUTO 10 // for outline-style only
328 :
329 : // See nsStyleBorder mBorderImage
330 : #define NS_STYLE_BORDER_IMAGE_REPEAT_STRETCH 0
331 : #define NS_STYLE_BORDER_IMAGE_REPEAT_REPEAT 1
332 : #define NS_STYLE_BORDER_IMAGE_REPEAT_ROUND 2
333 :
334 : #define NS_STYLE_BORDER_IMAGE_SLICE_NOFILL 0
335 : #define NS_STYLE_BORDER_IMAGE_SLICE_FILL 1
336 :
337 : // See nsStyleDisplay
338 : #define NS_STYLE_CLEAR_NONE 0
339 : #define NS_STYLE_CLEAR_LEFT 1
340 : #define NS_STYLE_CLEAR_RIGHT 2
341 : #define NS_STYLE_CLEAR_LEFT_AND_RIGHT 3
342 : #define NS_STYLE_CLEAR_LINE 4
343 : #define NS_STYLE_CLEAR_BLOCK 5
344 : #define NS_STYLE_CLEAR_COLUMN 6
345 : #define NS_STYLE_CLEAR_PAGE 7
346 : #define NS_STYLE_CLEAR_LAST_VALUE NS_STYLE_CLEAR_PAGE
347 :
348 : // See nsStyleContent
349 : #define NS_STYLE_CONTENT_OPEN_QUOTE 0
350 : #define NS_STYLE_CONTENT_CLOSE_QUOTE 1
351 : #define NS_STYLE_CONTENT_NO_OPEN_QUOTE 2
352 : #define NS_STYLE_CONTENT_NO_CLOSE_QUOTE 3
353 : #define NS_STYLE_CONTENT_ALT_CONTENT 4
354 :
355 : // See nsStyleColor
356 : #define NS_STYLE_CURSOR_AUTO 1
357 : #define NS_STYLE_CURSOR_CROSSHAIR 2
358 : #define NS_STYLE_CURSOR_DEFAULT 3 // ie: an arrow
359 : #define NS_STYLE_CURSOR_POINTER 4 // for links
360 : #define NS_STYLE_CURSOR_MOVE 5
361 : #define NS_STYLE_CURSOR_E_RESIZE 6
362 : #define NS_STYLE_CURSOR_NE_RESIZE 7
363 : #define NS_STYLE_CURSOR_NW_RESIZE 8
364 : #define NS_STYLE_CURSOR_N_RESIZE 9
365 : #define NS_STYLE_CURSOR_SE_RESIZE 10
366 : #define NS_STYLE_CURSOR_SW_RESIZE 11
367 : #define NS_STYLE_CURSOR_S_RESIZE 12
368 : #define NS_STYLE_CURSOR_W_RESIZE 13
369 : #define NS_STYLE_CURSOR_TEXT 14 // ie: i-beam
370 : #define NS_STYLE_CURSOR_WAIT 15
371 : #define NS_STYLE_CURSOR_HELP 16
372 : #define NS_STYLE_CURSOR_COPY 17 // CSS3
373 : #define NS_STYLE_CURSOR_ALIAS 18
374 : #define NS_STYLE_CURSOR_CONTEXT_MENU 19
375 : #define NS_STYLE_CURSOR_CELL 20
376 : #define NS_STYLE_CURSOR_GRAB 21
377 : #define NS_STYLE_CURSOR_GRABBING 22
378 : #define NS_STYLE_CURSOR_SPINNING 23
379 : #define NS_STYLE_CURSOR_MOZ_ZOOM_IN 24
380 : #define NS_STYLE_CURSOR_MOZ_ZOOM_OUT 25
381 : #define NS_STYLE_CURSOR_NOT_ALLOWED 26
382 : #define NS_STYLE_CURSOR_COL_RESIZE 27
383 : #define NS_STYLE_CURSOR_ROW_RESIZE 28
384 : #define NS_STYLE_CURSOR_NO_DROP 29
385 : #define NS_STYLE_CURSOR_VERTICAL_TEXT 30
386 : #define NS_STYLE_CURSOR_ALL_SCROLL 31
387 : #define NS_STYLE_CURSOR_NESW_RESIZE 32
388 : #define NS_STYLE_CURSOR_NWSE_RESIZE 33
389 : #define NS_STYLE_CURSOR_NS_RESIZE 34
390 : #define NS_STYLE_CURSOR_EW_RESIZE 35
391 : #define NS_STYLE_CURSOR_NONE 36
392 :
393 : // See nsStyleVisibility
394 : #define NS_STYLE_DIRECTION_LTR 0
395 : #define NS_STYLE_DIRECTION_RTL 1
396 : #define NS_STYLE_DIRECTION_INHERIT 2
397 :
398 : // See nsStyleDisplay
399 : #define NS_STYLE_DISPLAY_NONE 0
400 : #define NS_STYLE_DISPLAY_BLOCK 1
401 : #define NS_STYLE_DISPLAY_INLINE 2
402 : #define NS_STYLE_DISPLAY_INLINE_BLOCK 3
403 : #define NS_STYLE_DISPLAY_LIST_ITEM 4
404 : #define NS_STYLE_DISPLAY_TABLE 8
405 : #define NS_STYLE_DISPLAY_INLINE_TABLE 9
406 : #define NS_STYLE_DISPLAY_TABLE_ROW_GROUP 10
407 : #define NS_STYLE_DISPLAY_TABLE_COLUMN 11
408 : #define NS_STYLE_DISPLAY_TABLE_COLUMN_GROUP 12
409 : #define NS_STYLE_DISPLAY_TABLE_HEADER_GROUP 13
410 : #define NS_STYLE_DISPLAY_TABLE_FOOTER_GROUP 14
411 : #define NS_STYLE_DISPLAY_TABLE_ROW 15
412 : #define NS_STYLE_DISPLAY_TABLE_CELL 16
413 : #define NS_STYLE_DISPLAY_TABLE_CAPTION 17
414 : #define NS_STYLE_DISPLAY_BOX 18
415 : #define NS_STYLE_DISPLAY_INLINE_BOX 19
416 : #ifdef MOZ_XUL
417 : #define NS_STYLE_DISPLAY_GRID 20
418 : #define NS_STYLE_DISPLAY_INLINE_GRID 21
419 : #define NS_STYLE_DISPLAY_GRID_GROUP 22
420 : #define NS_STYLE_DISPLAY_GRID_LINE 23
421 : #define NS_STYLE_DISPLAY_STACK 24
422 : #define NS_STYLE_DISPLAY_INLINE_STACK 25
423 : #define NS_STYLE_DISPLAY_DECK 26
424 : #define NS_STYLE_DISPLAY_POPUP 27
425 : #define NS_STYLE_DISPLAY_GROUPBOX 28
426 : #endif
427 :
428 : // See nsStyleDisplay
429 : #define NS_STYLE_FLOAT_NONE 0
430 : #define NS_STYLE_FLOAT_LEFT 1
431 : #define NS_STYLE_FLOAT_RIGHT 2
432 :
433 : // See nsStyleFont
434 : // We should eventually stop using the NS_STYLE_* variants here.
435 : #define NS_STYLE_FONT_STYLE_NORMAL NS_FONT_STYLE_NORMAL
436 : #define NS_STYLE_FONT_STYLE_ITALIC NS_FONT_STYLE_ITALIC
437 : #define NS_STYLE_FONT_STYLE_OBLIQUE NS_FONT_STYLE_OBLIQUE
438 :
439 : // See nsStyleFont
440 : // We should eventually stop using the NS_STYLE_* variants here.
441 : #define NS_STYLE_FONT_VARIANT_NORMAL NS_FONT_VARIANT_NORMAL
442 : #define NS_STYLE_FONT_VARIANT_SMALL_CAPS NS_FONT_VARIANT_SMALL_CAPS
443 :
444 : // See nsStyleFont
445 : // We should eventually stop using the NS_STYLE_* variants here.
446 : #define NS_STYLE_FONT_WEIGHT_NORMAL NS_FONT_WEIGHT_NORMAL
447 : #define NS_STYLE_FONT_WEIGHT_BOLD NS_FONT_WEIGHT_BOLD
448 : // The constants below appear only in style sheets and not computed style.
449 : #define NS_STYLE_FONT_WEIGHT_BOLDER (-1)
450 : #define NS_STYLE_FONT_WEIGHT_LIGHTER (-2)
451 :
452 : // See nsStyleFont
453 : #define NS_STYLE_FONT_SIZE_XXSMALL 0
454 : #define NS_STYLE_FONT_SIZE_XSMALL 1
455 : #define NS_STYLE_FONT_SIZE_SMALL 2
456 : #define NS_STYLE_FONT_SIZE_MEDIUM 3
457 : #define NS_STYLE_FONT_SIZE_LARGE 4
458 : #define NS_STYLE_FONT_SIZE_XLARGE 5
459 : #define NS_STYLE_FONT_SIZE_XXLARGE 6
460 : #define NS_STYLE_FONT_SIZE_XXXLARGE 7 // Only used by <font size="7">. Not specifiable in CSS.
461 : #define NS_STYLE_FONT_SIZE_LARGER 8
462 : #define NS_STYLE_FONT_SIZE_SMALLER 9
463 :
464 : // See nsStyleFont
465 : // We should eventually stop using the NS_STYLE_* variants here.
466 : #define NS_STYLE_FONT_STRETCH_ULTRA_CONDENSED NS_FONT_STRETCH_ULTRA_CONDENSED
467 : #define NS_STYLE_FONT_STRETCH_EXTRA_CONDENSED NS_FONT_STRETCH_EXTRA_CONDENSED
468 : #define NS_STYLE_FONT_STRETCH_CONDENSED NS_FONT_STRETCH_CONDENSED
469 : #define NS_STYLE_FONT_STRETCH_SEMI_CONDENSED NS_FONT_STRETCH_SEMI_CONDENSED
470 : #define NS_STYLE_FONT_STRETCH_NORMAL NS_FONT_STRETCH_NORMAL
471 : #define NS_STYLE_FONT_STRETCH_SEMI_EXPANDED NS_FONT_STRETCH_SEMI_EXPANDED
472 : #define NS_STYLE_FONT_STRETCH_EXPANDED NS_FONT_STRETCH_EXPANDED
473 : #define NS_STYLE_FONT_STRETCH_EXTRA_EXPANDED NS_FONT_STRETCH_EXTRA_EXPANDED
474 : #define NS_STYLE_FONT_STRETCH_ULTRA_EXPANDED NS_FONT_STRETCH_ULTRA_EXPANDED
475 :
476 : // See nsStyleFont - system fonts
477 : #define NS_STYLE_FONT_CAPTION 1 // css2
478 : #define NS_STYLE_FONT_ICON 2
479 : #define NS_STYLE_FONT_MENU 3
480 : #define NS_STYLE_FONT_MESSAGE_BOX 4
481 : #define NS_STYLE_FONT_SMALL_CAPTION 5
482 : #define NS_STYLE_FONT_STATUS_BAR 6
483 : #define NS_STYLE_FONT_WINDOW 7 // css3
484 : #define NS_STYLE_FONT_DOCUMENT 8
485 : #define NS_STYLE_FONT_WORKSPACE 9
486 : #define NS_STYLE_FONT_DESKTOP 10
487 : #define NS_STYLE_FONT_INFO 11
488 : #define NS_STYLE_FONT_DIALOG 12
489 : #define NS_STYLE_FONT_BUTTON 13
490 : #define NS_STYLE_FONT_PULL_DOWN_MENU 14
491 : #define NS_STYLE_FONT_LIST 15
492 : #define NS_STYLE_FONT_FIELD 16
493 :
494 : // defaults per MathML spec
495 : #define NS_MATHML_DEFAULT_SCRIPT_SIZE_MULTIPLIER 0.71f
496 : #define NS_MATHML_DEFAULT_SCRIPT_MIN_SIZE_PT 8
497 :
498 : // See nsStylePosition::mWidth, mMinWidth, mMaxWidth
499 : #define NS_STYLE_WIDTH_MAX_CONTENT 0
500 : #define NS_STYLE_WIDTH_MIN_CONTENT 1
501 : #define NS_STYLE_WIDTH_FIT_CONTENT 2
502 : #define NS_STYLE_WIDTH_AVAILABLE 3
503 :
504 : // See nsStylePosition.mPosition
505 : #define NS_STYLE_POSITION_STATIC 0
506 : #define NS_STYLE_POSITION_RELATIVE 1
507 : #define NS_STYLE_POSITION_ABSOLUTE 2
508 : #define NS_STYLE_POSITION_FIXED 3
509 :
510 : // See nsStylePosition.mClip
511 : #define NS_STYLE_CLIP_AUTO 0x00
512 : #define NS_STYLE_CLIP_RECT 0x01
513 : #define NS_STYLE_CLIP_TYPE_MASK 0x0F
514 : #define NS_STYLE_CLIP_LEFT_AUTO 0x10
515 : #define NS_STYLE_CLIP_TOP_AUTO 0x20
516 : #define NS_STYLE_CLIP_RIGHT_AUTO 0x40
517 : #define NS_STYLE_CLIP_BOTTOM_AUTO 0x80
518 :
519 : // FRAME/FRAMESET/IFRAME specific values including backward compatibility. Boolean values with
520 : // the same meaning (e.g. 1 & yes) may need to be distinguished for correct mode processing
521 : #define NS_STYLE_FRAME_YES 0
522 : #define NS_STYLE_FRAME_NO 1
523 : #define NS_STYLE_FRAME_0 2
524 : #define NS_STYLE_FRAME_1 3
525 : #define NS_STYLE_FRAME_ON 4
526 : #define NS_STYLE_FRAME_OFF 5
527 : #define NS_STYLE_FRAME_AUTO 6
528 : #define NS_STYLE_FRAME_SCROLL 7
529 : #define NS_STYLE_FRAME_NOSCROLL 8
530 :
531 : // See nsStylePosition.mOverflow
532 : #define NS_STYLE_OVERFLOW_VISIBLE 0
533 : #define NS_STYLE_OVERFLOW_HIDDEN 1
534 : #define NS_STYLE_OVERFLOW_SCROLL 2
535 : #define NS_STYLE_OVERFLOW_AUTO 3
536 : #define NS_STYLE_OVERFLOW_CLIP 4
537 : #define NS_STYLE_OVERFLOW_SCROLLBARS_HORIZONTAL 5
538 : #define NS_STYLE_OVERFLOW_SCROLLBARS_VERTICAL 6
539 :
540 : // See nsStyleList
541 : #define NS_STYLE_LIST_STYLE_NONE 0
542 : #define NS_STYLE_LIST_STYLE_DISC 1
543 : #define NS_STYLE_LIST_STYLE_CIRCLE 2
544 : #define NS_STYLE_LIST_STYLE_SQUARE 3
545 : #define NS_STYLE_LIST_STYLE_DECIMAL 4
546 : #define NS_STYLE_LIST_STYLE_DECIMAL_LEADING_ZERO 5
547 : #define NS_STYLE_LIST_STYLE_LOWER_ROMAN 6
548 : #define NS_STYLE_LIST_STYLE_UPPER_ROMAN 7
549 : #define NS_STYLE_LIST_STYLE_LOWER_GREEK 8
550 : #define NS_STYLE_LIST_STYLE_LOWER_ALPHA 9
551 : #define NS_STYLE_LIST_STYLE_LOWER_LATIN 9 // == ALPHA
552 : #define NS_STYLE_LIST_STYLE_UPPER_ALPHA 10
553 : #define NS_STYLE_LIST_STYLE_UPPER_LATIN 10 // == ALPHA
554 : #define NS_STYLE_LIST_STYLE_HEBREW 11
555 : #define NS_STYLE_LIST_STYLE_ARMENIAN 12
556 : #define NS_STYLE_LIST_STYLE_GEORGIAN 13
557 : #define NS_STYLE_LIST_STYLE_CJK_IDEOGRAPHIC 14
558 : #define NS_STYLE_LIST_STYLE_HIRAGANA 15
559 : #define NS_STYLE_LIST_STYLE_KATAKANA 16
560 : #define NS_STYLE_LIST_STYLE_HIRAGANA_IROHA 17
561 : #define NS_STYLE_LIST_STYLE_KATAKANA_IROHA 18
562 : #define NS_STYLE_LIST_STYLE_MOZ_CJK_HEAVENLY_STEM 24
563 : #define NS_STYLE_LIST_STYLE_MOZ_CJK_EARTHLY_BRANCH 25
564 : #define NS_STYLE_LIST_STYLE_MOZ_TRAD_CHINESE_INFORMAL 26
565 : #define NS_STYLE_LIST_STYLE_MOZ_TRAD_CHINESE_FORMAL 27
566 : #define NS_STYLE_LIST_STYLE_MOZ_SIMP_CHINESE_INFORMAL 28
567 : #define NS_STYLE_LIST_STYLE_MOZ_SIMP_CHINESE_FORMAL 29
568 : #define NS_STYLE_LIST_STYLE_MOZ_JAPANESE_INFORMAL 30
569 : #define NS_STYLE_LIST_STYLE_MOZ_JAPANESE_FORMAL 31
570 : #define NS_STYLE_LIST_STYLE_MOZ_ARABIC_INDIC 32
571 : #define NS_STYLE_LIST_STYLE_MOZ_PERSIAN 33
572 : #define NS_STYLE_LIST_STYLE_MOZ_URDU 34
573 : #define NS_STYLE_LIST_STYLE_MOZ_DEVANAGARI 35
574 : #define NS_STYLE_LIST_STYLE_MOZ_GURMUKHI 36
575 : #define NS_STYLE_LIST_STYLE_MOZ_GUJARATI 37
576 : #define NS_STYLE_LIST_STYLE_MOZ_ORIYA 38
577 : #define NS_STYLE_LIST_STYLE_MOZ_KANNADA 39
578 : #define NS_STYLE_LIST_STYLE_MOZ_MALAYALAM 40
579 : #define NS_STYLE_LIST_STYLE_MOZ_BENGALI 41
580 : #define NS_STYLE_LIST_STYLE_MOZ_TAMIL 42
581 : #define NS_STYLE_LIST_STYLE_MOZ_TELUGU 43
582 : #define NS_STYLE_LIST_STYLE_MOZ_THAI 44
583 : #define NS_STYLE_LIST_STYLE_MOZ_LAO 45
584 : #define NS_STYLE_LIST_STYLE_MOZ_MYANMAR 46
585 : #define NS_STYLE_LIST_STYLE_MOZ_KHMER 47
586 : #define NS_STYLE_LIST_STYLE_MOZ_HANGUL 48
587 : #define NS_STYLE_LIST_STYLE_MOZ_HANGUL_CONSONANT 49
588 : #define NS_STYLE_LIST_STYLE_MOZ_ETHIOPIC_HALEHAME 50
589 : #define NS_STYLE_LIST_STYLE_MOZ_ETHIOPIC_NUMERIC 51
590 : #define NS_STYLE_LIST_STYLE_MOZ_ETHIOPIC_HALEHAME_AM 52
591 : #define NS_STYLE_LIST_STYLE_MOZ_ETHIOPIC_HALEHAME_TI_ER 53
592 : #define NS_STYLE_LIST_STYLE_MOZ_ETHIOPIC_HALEHAME_TI_ET 54
593 :
594 : // See nsStyleList
595 : #define NS_STYLE_LIST_STYLE_POSITION_INSIDE 0
596 : #define NS_STYLE_LIST_STYLE_POSITION_OUTSIDE 1
597 :
598 : // See nsStyleMargin
599 : #define NS_STYLE_MARGIN_SIZE_AUTO 0
600 :
601 : // See nsStyleVisibility
602 : #define NS_STYLE_POINTER_EVENTS_NONE 0
603 : #define NS_STYLE_POINTER_EVENTS_VISIBLEPAINTED 1
604 : #define NS_STYLE_POINTER_EVENTS_VISIBLEFILL 2
605 : #define NS_STYLE_POINTER_EVENTS_VISIBLESTROKE 3
606 : #define NS_STYLE_POINTER_EVENTS_VISIBLE 4
607 : #define NS_STYLE_POINTER_EVENTS_PAINTED 5
608 : #define NS_STYLE_POINTER_EVENTS_FILL 6
609 : #define NS_STYLE_POINTER_EVENTS_STROKE 7
610 : #define NS_STYLE_POINTER_EVENTS_ALL 8
611 : #define NS_STYLE_POINTER_EVENTS_AUTO 9
612 :
613 : // See nsStyleDisplay
614 : #define NS_STYLE_RESIZE_NONE 0
615 : #define NS_STYLE_RESIZE_BOTH 1
616 : #define NS_STYLE_RESIZE_HORIZONTAL 2
617 : #define NS_STYLE_RESIZE_VERTICAL 3
618 :
619 : // See nsStyleText
620 : #define NS_STYLE_TEXT_ALIGN_DEFAULT 0
621 : #define NS_STYLE_TEXT_ALIGN_LEFT 1
622 : #define NS_STYLE_TEXT_ALIGN_RIGHT 2
623 : #define NS_STYLE_TEXT_ALIGN_CENTER 3
624 : #define NS_STYLE_TEXT_ALIGN_JUSTIFY 4
625 : #define NS_STYLE_TEXT_ALIGN_CHAR 5 //align based on a certain character, for table cell
626 : #define NS_STYLE_TEXT_ALIGN_END 6
627 : #define NS_STYLE_TEXT_ALIGN_AUTO 7
628 : #define NS_STYLE_TEXT_ALIGN_MOZ_CENTER 8
629 : #define NS_STYLE_TEXT_ALIGN_MOZ_RIGHT 9
630 : #define NS_STYLE_TEXT_ALIGN_MOZ_LEFT 10
631 : // NS_STYLE_TEXT_ALIGN_MOZ_CENTER_OR_INHERIT is only used in data structs; it
632 : // is never present in stylesheets or computed data.
633 : #define NS_STYLE_TEXT_ALIGN_MOZ_CENTER_OR_INHERIT 11
634 : // Note: make sure that the largest NS_STYLE_TEXT_ALIGN_* value is smaller than
635 : // the smallest NS_STYLE_VERTICAL_ALIGN_* value below!
636 :
637 : // See nsStyleText
638 : #define NS_STYLE_TEXT_BLINK_NONE 0
639 : #define NS_STYLE_TEXT_BLINK_BLINK 1
640 :
641 : // See nsStyleText, nsStyleFont
642 : #define NS_STYLE_TEXT_DECORATION_LINE_NONE 0
643 : #define NS_STYLE_TEXT_DECORATION_LINE_UNDERLINE NS_FONT_DECORATION_UNDERLINE
644 : #define NS_STYLE_TEXT_DECORATION_LINE_OVERLINE NS_FONT_DECORATION_OVERLINE
645 : #define NS_STYLE_TEXT_DECORATION_LINE_LINE_THROUGH NS_FONT_DECORATION_LINE_THROUGH
646 : #define NS_STYLE_TEXT_DECORATION_LINE_BLINK 0x08
647 : #define NS_STYLE_TEXT_DECORATION_LINE_PREF_ANCHORS 0x10
648 : // OVERRIDE_ALL does not occur in stylesheets; it only comes from HTML
649 : // attribute mapping (and thus appears in computed data)
650 : #define NS_STYLE_TEXT_DECORATION_LINE_OVERRIDE_ALL 0x20
651 : #define NS_STYLE_TEXT_DECORATION_LINE_LINES_MASK (NS_STYLE_TEXT_DECORATION_LINE_UNDERLINE | NS_STYLE_TEXT_DECORATION_LINE_OVERLINE | NS_STYLE_TEXT_DECORATION_LINE_LINE_THROUGH)
652 :
653 : // See nsStyleText
654 : #define NS_STYLE_TEXT_DECORATION_STYLE_NONE 0 // not in CSS spec, mapped to -moz-none
655 : #define NS_STYLE_TEXT_DECORATION_STYLE_DOTTED 1
656 : #define NS_STYLE_TEXT_DECORATION_STYLE_DASHED 2
657 : #define NS_STYLE_TEXT_DECORATION_STYLE_SOLID 3
658 : #define NS_STYLE_TEXT_DECORATION_STYLE_DOUBLE 4
659 : #define NS_STYLE_TEXT_DECORATION_STYLE_WAVY 5
660 : #define NS_STYLE_TEXT_DECORATION_STYLE_MAX NS_STYLE_TEXT_DECORATION_STYLE_WAVY
661 :
662 : // See nsStyleTextOverflow
663 : #define NS_STYLE_TEXT_OVERFLOW_CLIP 0
664 : #define NS_STYLE_TEXT_OVERFLOW_ELLIPSIS 1
665 : #define NS_STYLE_TEXT_OVERFLOW_STRING 2
666 :
667 : // See nsStyleText
668 : #define NS_STYLE_TEXT_TRANSFORM_NONE 0
669 : #define NS_STYLE_TEXT_TRANSFORM_CAPITALIZE 1
670 : #define NS_STYLE_TEXT_TRANSFORM_LOWERCASE 2
671 : #define NS_STYLE_TEXT_TRANSFORM_UPPERCASE 3
672 :
673 : // See nsStyleDisplay
674 : #define NS_STYLE_TRANSITION_TIMING_FUNCTION_EASE 0
675 : #define NS_STYLE_TRANSITION_TIMING_FUNCTION_LINEAR 1
676 : #define NS_STYLE_TRANSITION_TIMING_FUNCTION_EASE_IN 2
677 : #define NS_STYLE_TRANSITION_TIMING_FUNCTION_EASE_OUT 3
678 : #define NS_STYLE_TRANSITION_TIMING_FUNCTION_EASE_IN_OUT 4
679 : #define NS_STYLE_TRANSITION_TIMING_FUNCTION_STEP_START 5
680 : #define NS_STYLE_TRANSITION_TIMING_FUNCTION_STEP_END 6
681 :
682 : // See nsStyleText
683 : // Note: these values pickup after the text-align values because there
684 : // are a few html cases where an object can have both types of
685 : // alignment applied with a single attribute
686 : #define NS_STYLE_VERTICAL_ALIGN_BASELINE 12
687 : #define NS_STYLE_VERTICAL_ALIGN_SUB 13
688 : #define NS_STYLE_VERTICAL_ALIGN_SUPER 14
689 : #define NS_STYLE_VERTICAL_ALIGN_TOP 15
690 : #define NS_STYLE_VERTICAL_ALIGN_TEXT_TOP 16
691 : #define NS_STYLE_VERTICAL_ALIGN_MIDDLE 17
692 : #define NS_STYLE_VERTICAL_ALIGN_TEXT_BOTTOM 18
693 : #define NS_STYLE_VERTICAL_ALIGN_BOTTOM 19
694 : #define NS_STYLE_VERTICAL_ALIGN_MIDDLE_WITH_BASELINE 20
695 :
696 : // See nsStyleVisibility
697 : #define NS_STYLE_VISIBILITY_HIDDEN 0
698 : #define NS_STYLE_VISIBILITY_VISIBLE 1
699 : #define NS_STYLE_VISIBILITY_COLLAPSE 2
700 :
701 : // See nsStyleText
702 : #define NS_STYLE_TABSIZE_INITIAL 8
703 :
704 : // See nsStyleText
705 : #define NS_STYLE_WHITESPACE_NORMAL 0
706 : #define NS_STYLE_WHITESPACE_PRE 1
707 : #define NS_STYLE_WHITESPACE_NOWRAP 2
708 : #define NS_STYLE_WHITESPACE_PRE_WRAP 3
709 : #define NS_STYLE_WHITESPACE_PRE_LINE 4
710 :
711 : // See nsStyleText
712 : #define NS_STYLE_WORDWRAP_NORMAL 0
713 : #define NS_STYLE_WORDWRAP_BREAK_WORD 1
714 :
715 : // See nsStyleText
716 : #define NS_STYLE_HYPHENS_NONE 0
717 : #define NS_STYLE_HYPHENS_MANUAL 1
718 : #define NS_STYLE_HYPHENS_AUTO 2
719 :
720 : // See nsStyleText
721 : #define NS_STYLE_TEXT_SIZE_ADJUST_NONE 0
722 : #define NS_STYLE_TEXT_SIZE_ADJUST_AUTO 1
723 :
724 : // See nsStyleText
725 : #define NS_STYLE_LINE_HEIGHT_BLOCK_HEIGHT 0
726 :
727 : // See nsStyleText
728 : #define NS_STYLE_UNICODE_BIDI_NORMAL 0x0
729 : #define NS_STYLE_UNICODE_BIDI_EMBED 0x1
730 : #define NS_STYLE_UNICODE_BIDI_ISOLATE 0x2
731 : #define NS_STYLE_UNICODE_BIDI_OVERRIDE 0x4
732 : #define NS_STYLE_UNICODE_BIDI_PLAINTEXT 0x8
733 :
734 : // See nsStyleTable (here for HTML 4.0 for now, should probably change to side flags)
735 : #define NS_STYLE_TABLE_FRAME_NONE 0
736 : #define NS_STYLE_TABLE_FRAME_ABOVE 1
737 : #define NS_STYLE_TABLE_FRAME_BELOW 2
738 : #define NS_STYLE_TABLE_FRAME_HSIDES 3
739 : #define NS_STYLE_TABLE_FRAME_VSIDES 4
740 : #define NS_STYLE_TABLE_FRAME_LEFT 5
741 : #define NS_STYLE_TABLE_FRAME_RIGHT 6
742 : #define NS_STYLE_TABLE_FRAME_BOX 7
743 : #define NS_STYLE_TABLE_FRAME_BORDER 8
744 :
745 : // See nsStyleTable
746 : #define NS_STYLE_TABLE_RULES_NONE 0
747 : #define NS_STYLE_TABLE_RULES_GROUPS 1
748 : #define NS_STYLE_TABLE_RULES_ROWS 2
749 : #define NS_STYLE_TABLE_RULES_COLS 3
750 : #define NS_STYLE_TABLE_RULES_ALL 4
751 :
752 : #define NS_STYLE_TABLE_COLS_NONE (-1)
753 : #define NS_STYLE_TABLE_COLS_ALL PRInt32(1 << 30)
754 :
755 : #define NS_STYLE_TABLE_LAYOUT_AUTO 0
756 : #define NS_STYLE_TABLE_LAYOUT_FIXED 1
757 :
758 : #define NS_STYLE_TABLE_EMPTY_CELLS_HIDE 0
759 : #define NS_STYLE_TABLE_EMPTY_CELLS_SHOW 1
760 : #define NS_STYLE_TABLE_EMPTY_CELLS_SHOW_BACKGROUND 2
761 :
762 : #define NS_STYLE_CAPTION_SIDE_TOP 0
763 : #define NS_STYLE_CAPTION_SIDE_RIGHT 1
764 : #define NS_STYLE_CAPTION_SIDE_BOTTOM 2
765 : #define NS_STYLE_CAPTION_SIDE_LEFT 3
766 : #define NS_STYLE_CAPTION_SIDE_TOP_OUTSIDE 4
767 : #define NS_STYLE_CAPTION_SIDE_BOTTOM_OUTSIDE 5
768 :
769 : // constants for cell "scope" attribute
770 : #define NS_STYLE_CELL_SCOPE_ROW 0
771 : #define NS_STYLE_CELL_SCOPE_COL 1
772 : #define NS_STYLE_CELL_SCOPE_ROWGROUP 2
773 : #define NS_STYLE_CELL_SCOPE_COLGROUP 3
774 :
775 : // See nsStylePage
776 : #define NS_STYLE_PAGE_MARKS_NONE 0x00
777 : #define NS_STYLE_PAGE_MARKS_CROP 0x01
778 : #define NS_STYLE_PAGE_MARKS_REGISTER 0x02
779 :
780 : // See nsStylePage
781 : #define NS_STYLE_PAGE_SIZE_AUTO 0
782 : #define NS_STYLE_PAGE_SIZE_PORTRAIT 1
783 : #define NS_STYLE_PAGE_SIZE_LANDSCAPE 2
784 :
785 : // See nsStyleBreaks
786 : #define NS_STYLE_PAGE_BREAK_AUTO 0
787 : #define NS_STYLE_PAGE_BREAK_ALWAYS 1
788 : #define NS_STYLE_PAGE_BREAK_AVOID 2
789 : #define NS_STYLE_PAGE_BREAK_LEFT 3
790 : #define NS_STYLE_PAGE_BREAK_RIGHT 4
791 :
792 : // See nsStyleColumn
793 : #define NS_STYLE_COLUMN_COUNT_AUTO 0
794 : #define NS_STYLE_COLUMN_COUNT_UNLIMITED (-1)
795 :
796 : #define NS_STYLE_COLUMN_FILL_AUTO 0
797 : #define NS_STYLE_COLUMN_FILL_BALANCE 1
798 :
799 : // See nsStyleUIReset
800 : #define NS_STYLE_IME_MODE_AUTO 0
801 : #define NS_STYLE_IME_MODE_NORMAL 1
802 : #define NS_STYLE_IME_MODE_ACTIVE 2
803 : #define NS_STYLE_IME_MODE_DISABLED 3
804 : #define NS_STYLE_IME_MODE_INACTIVE 4
805 :
806 : // See nsStyleGradient
807 : #define NS_STYLE_GRADIENT_SHAPE_LINEAR 0
808 : #define NS_STYLE_GRADIENT_SHAPE_ELLIPTICAL 1
809 : #define NS_STYLE_GRADIENT_SHAPE_CIRCULAR 2
810 :
811 : #define NS_STYLE_GRADIENT_SIZE_CLOSEST_SIDE 0
812 : #define NS_STYLE_GRADIENT_SIZE_CLOSEST_CORNER 1
813 : #define NS_STYLE_GRADIENT_SIZE_FARTHEST_SIDE 2
814 : #define NS_STYLE_GRADIENT_SIZE_FARTHEST_CORNER 3
815 :
816 : // See nsStyleSVG
817 :
818 : // dominant-baseline
819 : #define NS_STYLE_DOMINANT_BASELINE_AUTO 0
820 : #define NS_STYLE_DOMINANT_BASELINE_USE_SCRIPT 1
821 : #define NS_STYLE_DOMINANT_BASELINE_NO_CHANGE 2
822 : #define NS_STYLE_DOMINANT_BASELINE_RESET_SIZE 3
823 : #define NS_STYLE_DOMINANT_BASELINE_IDEOGRAPHIC 4
824 : #define NS_STYLE_DOMINANT_BASELINE_ALPHABETIC 5
825 : #define NS_STYLE_DOMINANT_BASELINE_HANGING 6
826 : #define NS_STYLE_DOMINANT_BASELINE_MATHEMATICAL 7
827 : #define NS_STYLE_DOMINANT_BASELINE_CENTRAL 8
828 : #define NS_STYLE_DOMINANT_BASELINE_MIDDLE 9
829 : #define NS_STYLE_DOMINANT_BASELINE_TEXT_AFTER_EDGE 10
830 : #define NS_STYLE_DOMINANT_BASELINE_TEXT_BEFORE_EDGE 11
831 :
832 : // fill-rule
833 : #define NS_STYLE_FILL_RULE_NONZERO 0
834 : #define NS_STYLE_FILL_RULE_EVENODD 1
835 :
836 : // image-rendering
837 : #define NS_STYLE_IMAGE_RENDERING_AUTO 0
838 : #define NS_STYLE_IMAGE_RENDERING_OPTIMIZESPEED 1
839 : #define NS_STYLE_IMAGE_RENDERING_OPTIMIZEQUALITY 2
840 : #define NS_STYLE_IMAGE_RENDERING_CRISPEDGES 3
841 :
842 : // shape-rendering
843 : #define NS_STYLE_SHAPE_RENDERING_AUTO 0
844 : #define NS_STYLE_SHAPE_RENDERING_OPTIMIZESPEED 1
845 : #define NS_STYLE_SHAPE_RENDERING_CRISPEDGES 2
846 : #define NS_STYLE_SHAPE_RENDERING_GEOMETRICPRECISION 3
847 :
848 : // stroke-linecap
849 : #define NS_STYLE_STROKE_LINECAP_BUTT 0
850 : #define NS_STYLE_STROKE_LINECAP_ROUND 1
851 : #define NS_STYLE_STROKE_LINECAP_SQUARE 2
852 :
853 : // stroke-linejoin
854 : #define NS_STYLE_STROKE_LINEJOIN_MITER 0
855 : #define NS_STYLE_STROKE_LINEJOIN_ROUND 1
856 : #define NS_STYLE_STROKE_LINEJOIN_BEVEL 2
857 :
858 : // text-anchor
859 : #define NS_STYLE_TEXT_ANCHOR_START 0
860 : #define NS_STYLE_TEXT_ANCHOR_MIDDLE 1
861 : #define NS_STYLE_TEXT_ANCHOR_END 2
862 :
863 : // text-rendering
864 : #define NS_STYLE_TEXT_RENDERING_AUTO 0
865 : #define NS_STYLE_TEXT_RENDERING_OPTIMIZESPEED 1
866 : #define NS_STYLE_TEXT_RENDERING_OPTIMIZELEGIBILITY 2
867 : #define NS_STYLE_TEXT_RENDERING_GEOMETRICPRECISION 3
868 :
869 : // color-interpolation and color-interpolation-filters
870 : #define NS_STYLE_COLOR_INTERPOLATION_AUTO 0
871 : #define NS_STYLE_COLOR_INTERPOLATION_SRGB 1
872 : #define NS_STYLE_COLOR_INTERPOLATION_LINEARRGB 2
873 :
874 : // 3d Transforms - Backface visibility
875 : #define NS_STYLE_BACKFACE_VISIBILITY_VISIBLE 1
876 : #define NS_STYLE_BACKFACE_VISIBILITY_HIDDEN 0
877 :
878 : #define NS_STYLE_TRANSFORM_STYLE_FLAT 0
879 : #define NS_STYLE_TRANSFORM_STYLE_PRESERVE_3D 1
880 :
881 : /*****************************************************************************
882 : * Constants for media features. *
883 : *****************************************************************************/
884 :
885 : // orientation
886 : #define NS_STYLE_ORIENTATION_PORTRAIT 0
887 : #define NS_STYLE_ORIENTATION_LANDSCAPE 1
888 :
889 : // scan
890 : #define NS_STYLE_SCAN_PROGRESSIVE 0
891 : #define NS_STYLE_SCAN_INTERLACE 1
892 :
893 : #endif /* nsStyleConsts_h___ */
|