IES: CSS-deck 10 Flashcards
font-size
- property assigning values that specify the size of text
absolute size
Specified by assigning 1 of the following unit names to the font-size property:
* inches (in)
* Centimeters (cm)
* Millimeters (mm)
* Points (pt)
* Picas (pc)
CSS relative size
- Using relative size as opposed to absolute size provides for maximum flexibility
CSS relative size values: keywords
- “medium” is the browsers default font size: the rest are computed relative to this
- “xx-large”
- “x-large”
- “large”
- “small”
- “x-small”
- “xx-small”
Table with relative font-size keywords with possible/probable absolute values (pt)
- “medium” is the browsers default font size: the rest are computed relative to this (12 pt)
- “xx-large” (24 pt)
- “x-large” (17 pt)
- “large” (13.5 pt)
- “small” (10.5 pt)
- “x-small” (7.5 pt)
- “xx-small” (7 pt)
It is preferable to use \_\_\_\_\_
units or \_\_\_\_\_
values to specify sizes relative to the browser default font value.
It is preferable to use em units or percentage values to specify sizes relative to the \_\_\_\_\_
\_\_\_\_\_
\_\_\_\_\_
value.
“vw”
- a further refinement beyond using em units or percentage values.
- “viewport width”
- A value of one “vw” is 1% of the current viewport width
- Allows the text size to resize to suit the viewing device or browser window
The \_\_\_\_\_
or \_\_\_\_\_
of text can be adjusted using the font-weight property and \_\_\_\_\_
like “bold” and “normal”
The thickness or “weight”of text can be adjusted using the _____ property and keywords like “\_\_\_\_\_
” and “\_\_\_\_\_
”
These fonts are considered to be more readable for smaller texts.
Sans-serif fonts are considered to be more readable for what?
oblique
- keyword value for the CSS property font-style
- Requests the browser use a slanting variant of the current font
- A Roman font that has been skewed a certain number of degrees (8-12 degrees, usually)
- Effect may be overridden by the specification of “normal” to the element’s font-style
italic
- keyword value for the CSS property font-style
- Requests the browser use a slanting variant of the current font
- Drawn differently to create a more calligraphic, as well as slanted font version
- Effect may be overridden by the specification of “normal” to the element’s font-style
Small-caps
- a CSS font-variant property value
- Allows text characters to be displayed in a small capitals format using uppercase characters of two different sizes.
- Uppercase text will appear as large capital characters, but lowercase text will appear as smaller capitals
- Effect may be overridden by the specification of “normal” to the element’s font-variant
CSS shorthand appearance: font
font-style font-variant font-weight font-size font-family
Ex. (p {font: italic small-caps bold medium “Times”, serif;})
CSS shorthand rules: font
- font-size and font-family values are mandatory
- Font-Style, front-variant, and font-weight are optional
- The optional properties may appear in any order
- If the optional properties are omitted, a “normal” value will be automatically assumed
CSS rules: font
- Unless a font value is explicitly specified:
- “normal” is the font default value
- This value will override the current parent element value