nuget server logo nuget api documents
↑

API Docs / Microsoft.VisualBasic.MIME.Html / CssUnit

CssUnit

Full name Microsoft.VisualBasic.MIME.Html.CSS.CssUnit Assembly Microsoft.VisualBasic.MIME.Html Members 20

Represents the possible units of the CSS lengths

00 Remarks

http://www.w3.org/TR/CSS21/syndata.html#length-units

01 Syntax

Microsoft.VisualBasic.MIME.Html.CSS.CssUnit

02 Fields

NameOverloadsSummary
None 2 Unknown
Ems 2 em: the 'font-size' of the relevant font
Ex 2 ex: the 'x-height' of the relevant font
Pixels 2 px: pixel units — 1px is equal to 0.75pt.
Inches 2 in: inches — 1in is equal to 2.54cm.
Centimeters 2 cm: centimeters
Milimeters 2 mm: millimeters
Points 2 pt: points — the points used by CSS are equal to 1/72nd of 1in.
Picas 2 pc: picas — 1pc is equal to 12pt.
Percent 2 The format of a percentage value (denoted by <percentage> in this specification) is a <number> immediately followed by '%'.

03 Members

field None #
None

Unknown

field Ems #
Ems

em: the 'font-size' of the relevant font

field Ex #
Ex

ex: the 'x-height' of the relevant font

field Pixels #
Pixels

px: pixel units — 1px is equal to 0.75pt.

field Inches #
Inches

in: inches — 1in is equal to 2.54cm.

field Centimeters #
Centimeters

cm: centimeters

field Milimeters #
Milimeters

mm: millimeters

field Points #
Points

pt: points — the points used by CSS are equal to 1/72nd of 1in.

field Picas #
Picas

pc: picas — 1pc is equal to 12pt.

field Percent #
Percent

The format of a percentage value (denoted by <percentage> in this specification) is a <number> immediately followed by '%'.

Percentage values are always relative to another value, for example a length. Each property that allows percentages also defines the value to which the percentage refers. The value may be that of another property for the same element, a property for an ancestor element, or a value of the formatting context (e.g., the width of a containing block). When a percentage value is set for a property of the root element and the percentage is defined as referring to the inherited value of some property, the resultant value is the percentage times the initial value of that property.

Since child elements (generally) inherit the computed values of their parent, in the following example, the children of the P element will inherit a value of 12px for 'line-height', not the percentage value (120%):

 p { font-size: 10px }
 p { line-height: 120% }  /* 120% of 'font-size' */
field None overload 2 #
None
field Ems overload 2 #
Ems
field Ex overload 2 #
Ex
field Pixels overload 2 #
Pixels
field Inches overload 2 #
Inches
field Centimeters overload 2 #
Centimeters
field Milimeters overload 2 #
Milimeters
field Points overload 2 #
Points
field Picas overload 2 #
Picas
field Percent overload 2 #
Percent