From 074785cea106179cb3305637055ab0a009ca74f2 Mon Sep 17 00:00:00 2001 From: Peter Bengtsson Date: Tue, 8 Dec 2020 14:42:52 -0500 Subject: initial commit --- files/pt-pt/web/css/font-size/index.html | 83 ++++++++++++++++++++++++++++++++ 1 file changed, 83 insertions(+) create mode 100644 files/pt-pt/web/css/font-size/index.html (limited to 'files/pt-pt/web/css/font-size') diff --git a/files/pt-pt/web/css/font-size/index.html b/files/pt-pt/web/css/font-size/index.html new file mode 100644 index 0000000000..e3d0ca9fa8 --- /dev/null +++ b/files/pt-pt/web/css/font-size/index.html @@ -0,0 +1,83 @@ +--- +title: font-size +slug: Web/CSS/font-size +tags: + - Referencia_CSS +translation_of: Web/CSS/font-size +--- +

{{ CSSRef() }}

+ +

Resumo

+ +

The font-size property specifies the size of the font. The font size may, in turn, change the size of other things, since it is used to compute the value of em and ex length units.

+ + + +

Sintaxe

+ +

font-size: xx-small | x-small | small | medium | large | x-large | xx-large

+ +

font-size: smaller | larger

+ +

font-size: <length> | <percentage> | {{ Cssxref("inherit") }}

+ +

Valores

+ +
+
xx-small, x-small, small, medium, large, x-large, xx-large 
+
A set of absolute size keywords based on the user's default font size (which is medium). Similar to presentational HTML's <font size="1"> through <font size="7"> where the user's default font size is <font size="3">.
+
larger, smaller 
+
Larger or smaller than the parent element's font size, by roughly the ratio used to separate the absolute size keywords above.
+
<length> 
+
A positive length.
+
<percentage> 
+
A positive percentage of the parent element's font size.
+
+ +

It is best to avoid using values that are not relative to the user's default font size, such as <lengths> with units other than em or ex. However, if such values must be used, px are preferred over other units because their meaning does not vary depending on what the operating system thinks (generally incorrectly) the resolution of the monitor is.

+ +

Exemplos

+ +

View Live Examples

+ +
/* Set paragraph text to be very large. */
+p { font-size: xx-large }
+
+/* Set h1 (level 1 heading) text to be 2.5 times the size
+ * of the text around it. */
+h1 { font-size: 250% }
+
+/* Sets text enclosed within span tag to be 16px */
+span { font-size: 16px; }
+
+ +

Notas

+ +

em and ex units on the {{ Cssxref("font-size") }} property are relative to the parent element's font size (unlike all other properties, where they're relative to the font size on the element). This means em units and percentages do the same thing for {{ Cssxref("font-size") }}.

+ +

Especificações

+ + + +

== Compatibilidade com navegadores ==

+ +

Veja também

+ +

{{ Cssxref("font") }} {{ Cssxref("font-family") }}, {{ Cssxref("font-size") }}, {{ Cssxref("font-size-adjust") }}, {{ Cssxref("font-style") }}, {{ Cssxref("font-variant") }}, {{ Cssxref("font-weight") }}, {{ Cssxref("line-height") }}

+ +

Categorias

+ +

Interwiki Language Links

+ +

{{ languages( { "en": "en/CSS/font-size", "fr": "fr/CSS/font-size" } ) }}

-- cgit v1.2.3-54-g00ecf