Changes from Version 1 of documentation/RCSS/Text

Show
Ignore:
Author:
peterc (IP: 192.168.0.1)
Timestamp:
11/29/07 11:08:09 (10 years ago)
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • documentation/RCSS/Text

    v0 v1  
     1[[PageOutline(1-5, Contents)]] 
     2= Text = 
     3 
     4== Alignment: the 'text-align' property == 
     5 
     6''text-align'' 
     7|| ''Value:'' || left | right | center || 
     8|| ''Initial:'' || left || 
     9|| ''Applies to:'' || block-level elements || 
     10|| ''Inherited:'' || yes || 
     11|| ''Percentages:'' || N/A || 
     12 
     13This property affects how inline boxes within a line box are aligned. Values have the following meanings: 
     14 
     15 left:: 
     16   The row of inline boxes are aligned against the left edge of the line box. 
     17 right:: 
     18   The row of inline boxes are aligned against the right edge of the line box. 
     19 center:: 
     20   The row of inline boxes are aligned in the centre of the line box. 
     21 
     22Note that the 'justify' value is not yet supported in RCSS. 
     23 
     24== Decoration == 
     25 
     26=== Underlining: the 'text-decoration' property === 
     27 
     28''text-decoration'' 
     29|| ''Value:'' || none | underline || 
     30|| ''Initial:'' || none || 
     31|| ''Applies to:'' || all elements || 
     32|| ''Inherited:'' || yes || 
     33|| ''Percentages:'' || N/A || 
     34 
     35Values have the following meaning: 
     36 
     37 none:: 
     38   Any text generated by this element has no additional decoration. 
     39 underline:: 
     40   Any text generated by this element has an underline, with a thickness and position specified by the font. 
     41 
     42The colour of any decoration is the same as the font colour. Note that 'overline' and 'line-through' is not yet supported in RCSS. 
     43 
     44=== Text shadows: the 'text-shadow' property === 
     45 
     46Text can have a coloured shadow applied behind it. The shadow is defined by three variables: an offset along x, an offset along y, and a colour. 
     47 
     48''text-shadow-x'', ''text-shadow-y'' 
     49|| ''Value:'' || <length> || 
     50|| ''Initial:'' || 0px || 
     51|| ''Applies to:'' || all elements || 
     52|| ''Inherited:'' || yes || 
     53|| ''Percentages:'' || N/A || 
     54 
     55'text-shadow-x' and 'text-shadow-y' define the horizontal and vertical offset of the shadow from its text. If they are both '0' (the default), then no shadow will be rendered. 
     56 
     57''text-shadow-color'' 
     58|| ''Value:'' || <color> || 
     59|| ''Initial:'' || black || 
     60|| ''Applies to:'' || all elements || 
     61|| ''Inherited:'' || yes || 
     62|| ''Percentages:'' || N/A || 
     63 
     64''text-shadow''[[BR]] 
     65A shorthand for specifying all three shadow parameters at once. 
     66 
     67{{{ 
     68/* Specify a grey text shadow on primary headings. */ 
     69h1 
     70{ 
     71    text-shadow: 2px 2px grey; 
     72} 
     73}}} 
     74 
     75Note that in RCSS you can only specify a single text shadow, and shadow blurring is not yet supported. 
     76 
     77== Whitespace: the 'white-space' property == 
     78 
     79''white-space'' 
     80|| ''Value:'' || normal | pre | nowrap | pre-wrap | pre-line || 
     81|| ''Initial:'' || normal || 
     82|| ''Applies to:'' || block-level elements || 
     83|| ''Inherited:'' || yes || 
     84|| ''Percentages:'' || N/A || 
     85 
     86This property defines how whitespace (any spaces, end-lines, carriage-returns and tabs) are processed in sections of text. Values have the following meanings: 
     87 
     88 normal:: 
     89   Sequences of whitespace are collapsed down to single spaces. Lines are broken as necessary to fit line boxes. Line breaks in the source are ignored. 
     90 pre:: 
     91   Sequences of whitespace are preserved. Lines are only broken where line breaks are present in the source. 
     92 nowrap:: 
     93   Sequences of whitespace are collapsed. Lines are not broken. 
     94 pre-wrap:: 
     95   Sequences of whitespace are not collapsed. Lines are only broken where line breaks are present in the source. 
     96 pre-line:: 
     97   Sequences of whitespace are collapsed. Lines are broken to fit line boxes or where line breaks are present in the source.