man wml::des::typography (Fonctions bibliothèques) - Typography
NAME
wml::des::typography - Typography
SYNOPSIS
#use wml::des::typography [face_shortcuts]
# paragraph whitespace <ps [height]> (<ds [height]>) <pi [width]> (<ein [width]>)
# paragraph text rendering <big X> <sc [complete]>...</sc> <csc>...</csc> <spaced [interchar=N] [interline=N]>...</spaced> <verbcode>...</verbcode>
# headlines <headline [name]>...</headline> (<ue [name]>...</ue>) <subheadline [name]>...</subheadline> (<zwue [name]>...</zwue>)
# unsorted lists <tul [ps=N] [pi=N]> <tli [pshape=dash|box] [pcolor=#rrggbb]>...</tli> ... </tul>
DESCRIPTION
This include file provides tags for more typographically strong layouting then HTML per default provides. The following tags are provided:
- Typographical Paragraph Skip
-
CB<ps [height]CB>
This is the typographical way to insert a
blank line between two paragraphs. It is not as high as the one generated by
HTML's CW<p> tag. Default is 4 pixels for height. Optically and
functionally CW<ps> is between CW<br> and CW<p>.
In german this is called Durchschuss, so you can also use the alterntive name
CW<ds> for this tag.
...The last line of the previous paragraph. <ps> The new line of the following paragraph...
- Typographical Paragraph Indention
-
CB<pi [width]CB>
This is the typographical way to glue
paragraphs which should become one optical block. A complete blank line
between them would be ugly and without any inserts the reader cannot
distinguish between the two paragraphs. The typographical solution here is to
indent the second paragraph by width pixels. The default is 40 pixels.
Optically CW<pi> also includes the effect of CW<ps>. In
german this is called `Einrückung', so you can also use the alterntive name
CW<ein> for this tag.
Example:
...The last line of the previous paragraph. <pi>The new line of the following paragraph...
- Big Paragraph Starting Letter
-
CB<big XCB>
This is the typographical way to mark the
beginning of a more important paragraph by rendering the first letter of the
first word of this paragraph in huge font. Optically this letter then is
approximately three times bigger then the normal text font. Additionally the
alt attribute of the used CW<img> tag is set to the letter, so
text-based browsers correctly show the first word. Because
such a paragraph should also be introduced by more whitespace, one
usually uses the standard CW<p> tag in front of CW<big> to
achieve the correct optical effect.
Example:
...The last line of the previous paragraph. <p> <big T>he new line of the following paragraph...
- Small Caps Text
- CB<sc [complete]CB>...CB</sc> This container tag renders its body with small caps, i.e. all lower case letters are changed to upper case while lowered optically via font size. In german typography this is also known as `Kapitälchen'. Optionally when adding the attribute complete, all words are forced to begin with an upper case letter, too. If you have support for i18n (internationalization) you may also convert case of non-ASCII characters. See your local documentation locale(7) for details or ask your system administrator.
- Spaced Text
- CB<spaced [interchar=N] [interline=N]CB>...CB</spaced> This container tag renders its body as spaced text, i.e. text with spaces between the lines and characters. In typpgraphy this is usually used to emphasize the text by the use of whitespace. Per default interchar and interline are 0, i.e. no spacing. The spacing is achieved by inserting as much CW entities as interchar specifies and 1pt-images of height 14+interline every fifth word. In german typography this is also known as `Gesperrt'.
- Headline
-
CB<headline [name]CB>...CB</headline>
This container tag creates a typographically better headline as
the standard HTML CW<h1> does, i.e. it renders the text in Helvetica
and used better whitespaces around it. Actually it does not create any
whitespace above it, but the correct one below it. This way you can create the
leading whitespace your own (which is usually different according to the
context) but get nice trailing whitespace (which has to be choosen carefully
to make the headline and the following paragraph one unit). In german this is
called `Überschrift' hence the alias CW<ue>.
Example:
...The last line of the previous paragraph. <p> <ue>The headline</ue> The new line of the following paragraph...
- Sub-Headline
-
CB<subheadline [name]CB>...CB</subheadline>
This container tag creates a typographically better
sub-headline as the standard HTML CW<h2> does, i.e. it renders the
text in Helvetica and used better whitespaces around it. Actually it does not
create any whitespace above it, but the correct one below it. This way you can
create the leading whitespace your own (which is usually different according
to the context) but get nice trailing whitespace (which has to be choosen
carefully to make the headline and the following paragraph one unit). In
german this is called `Zwischenüberschrift' hence the alias CW<zwue>.
Example:
...The last line of the previous paragraph. <p> <zwue>The headline</zwue> The new line of the following paragraph...
- Verbatim Code
- CB<verbcode>...CB</verbcode> This container tag renders its body mostly verbatim, i.e. treats it like plain (source) code. Internally this just is an indented CW<verbatim> container from wml::fmt::verbatim(3) which itself is an enhanced CW<pre> container.
- Unnumbered Lists
- CB<tul [ps=N] [pi=N]CB>...CB</tul> This container tag displays unnumbered lists in a more typographically strong layout, rendered via HTML tables for indentation. CB<tli [pshape=box|dash] [pcolor=#rrggbb]CB>...CB</tli> Items are prefixed by a box or a dash, depending on the pshape attribute, and its color may be defined.
AUTHOR
Ralf S. Engelschall rse@engelschall.com www.engelschall.com
REQUIRES
Internal: P1, P2, P3, P8
SEEALSO
HTML CW<font> and CW<br> tags.