Learning CSS 5 | CSS Font, Font in Manipulating CSS

font css
Css time learning session is about css font, which is one of the css styles. CSS font used to display the font or font set on the website.

CSS Font Family

In CSS there are two types of CSS font family name, ie:
- Generic family: font family group with the same appearance (such as "serif" or "monoscope")
- Font family: Font family special / specific (like "Times New Roman" or "Arial")

Font family, an arrangement of the typeface to be used, Example usage:

p{font-family:"Times New Roman", Times, serif;}

CSS Font Style

Style here is the most widely used italics, which is actually also a normal and oblique style. Here syntak CSS font style:

p.normal {font-style:normal;}
p.italic {font-style:italic;}
p.oblique {font-style:oblique;}

CSS Font Size

In web designing, set the font size is important. By using this property, we make it easy to adjust font sizes vary within a single page of a website. Here we will learn also how to set the font size in the css. Remember to always use proper HTML tags, such as <h1> - <h6> for headings and paragraphs <p>. Font-size value can be absolute size, or relative.

body {font-size: 13px;} / / pixel units
body {font-size: 1.5em;} / / unit of em
body {font-size: 100%;} / / unit%

The example above can be applied in the browser firefox, safari and chrome but can not be used in applications internet explorer. Well, for that many web developers suggest using em rather than pixels. 1em is equal to 16 pixels. The size of the pixel is calculated using the formula into pixels/16 em = em. example:

h1 {font-size:2.5em;} /* 40px/16=2.5em */
h2 {font-size:1.875em;} /* 30px/16=1.875em */
p {font-size:0.875em;} /* 14px/16=0.875em */

CSS Font Variant

Font Variant example is making a big font of all, where there is text on text css transformation. Example syntak CSS Font Variant:

p.normal {font-variant: normal;} / / normal post
p.besar {font-variant: small-caps;} / / ALL CAPS

CSS Font Weight

Uses that are often found in weight font style, ie make bold. Here syntak to CSS font weight:

p.normal {font-weight: normal;} / / normal font
p.tebal {font-weight: bold;} / / Bolding

Alternatively, it could actually also use strong tag or <b> which functions the same: to make bold.

Okey, CSS tutorials learn about CSS font is enough. I am sure you will be more apparent in the study of learning css css and addiction.
Previous
Next Post »