Css font properties
Upcoming SlideShare
Loading in...5
×
 

Css font properties

on

  • 717 views

 

Statistics

Views

Total Views
717
Views on SlideShare
717
Embed Views
0

Actions

Likes
0
Downloads
3
Comments
0

0 Embeds 0

No embeds

Accessibility

Categories

Upload Details

Uploaded via as Microsoft PowerPoint

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

Css font properties Css font properties Presentation Transcript

  • Unit III: Adding Stylesand Interactivity Using CSS and Javascript
  • CSS Font Properties• The CSS Font Properties allow you to specify the font characteristic such as fonts, font size, font style, etc.
  • Property Description Examplefont-family Specifies the font h1{font-family: family for text arial, verdana, sans- serif;} h2{font-family: garamond, serif;} h3{font-family: Courier, monospace;}font-size Specifies the font size h1{font-size: 25px;} of text h2{font-size: 13pt;} Value: pixel, point or h3{font-size: 115%} percentagefont-style Specifies the font style h1{font-style: for text oblique;} Value: h2{font-style: italic normal, oblique, or italic View slide
  • Property Description Examplefont-variant Specifies whether or h1{font-variant: not a text should be small-caps;} displayed in a small- h1{font-variant: caps font or normal normal;} fontfont-weight Specifies the weight h1{font-weight: of a font to normal bold;} or bold h1{font-weight: normal;}font Sets all the font h1{font: oblique properties in one bold 20px “Times declaration New Roman”, sans serif;} View slide
  • COMPUQUIZ1. Write the CSS code to set the font to Broadway.2. Write the CSS code to set the font size to 16pt.3. Write the CSS code to set the font style to italic.4. Write the CSS code to set the font to small caps.5. Write the CSS code to set the font to bold.6. Write the CSS code to set 1-5 in one declaration.
  • Answer• 1.body{font-family:broadway;}2. body{font-size: 16pt;}• 3.body{font-style: italic;}• 4. body{font-variant:small-caps;}• Body{font-weight: bold;}• Body{font : broadway 16pt italic small-caps bold;}