Vlastnost CSS font-stretch
Příklad
Rozšiřte text v prvcích <div>:
div
{
font-family: sans-serif, "Helvetica Neue", "Lucida Grande", Arial;
font-stretch: expanded;
}
Definice a použití
Tato font-stretch
vlastnost umožňuje text zúžit (zhuštěný) nebo rozšířit (rozbalit).
Poznámka: Některá písma poskytují další plochy; zhuštěné tváře a rozšířené tváře. U těchto písem můžete pomocí font-stretch
vlastnosti vybrat normální, zúžené nebo rozšířené písmo.
Poznámka: Tato vlastnost nemá žádný účinek, pokud vybrané písmo nenabízí zúžené nebo rozšířené plochy!
Výchozí hodnota: | normální |
---|---|
Zděděno: | Ano |
Animovatelné: | Ano. Přečtěte si o tématu Animable |
Verze: | CSS3 |
Syntaxe JavaScriptu: | objekt .style.fontStretch="expanded" |
Podpora prohlížeče
Čísla v tabulce určují první verzi prohlížeče, která plně podporuje vlastnost.
Property | |||||
---|---|---|---|---|---|
font-stretch | 48.0 | 9.0 | 9.0 | 11.0 | 35.0 |
Syntax
font-stretch: ultra-condensed|extra-condensed|condensed|semi-condensed|normal|semi-expanded|expanded|extra-expanded|ultra-expanded|initial|inherit;
Hodnoty vlastností
Value | Description |
---|---|
ultra-condensed | Makes the text as narrow as it gets |
extra-condensed | Makes the text narrower than condensed, but not as narrow as ultra-condensed |
condensed | Makes the text narrower than semi-condensed, but not as narrow as extra-condensed |
semi-condensed | Makes the text narrower than normal, but not as narrow as condensed |
normal | Default value. No font stretching |
semi-expanded | Makes the text wider than normal, but not as wide as expanded |
expanded | Makes the text wider than semi-expanded, but not as wide as extra-expanded |
extra-expanded | Makes the text wider than expanded, but not as wide as ultra-expanded |
ultra-expanded | Makes the text as wide as it gets |
initial | Sets this property to its default value. Read about initial |
inherit | Inherits this property from its parent element. Read about inherit |