1 / 10

CSS3 Font Face

CSS3 Font Face. Utiliser des polices de caractère non standard. L’attribut media avant CSS3. <! doctype html> < head > < meta charset = " utf -8" > < title > Media Queries ! </ title > < link rel = " stylesheet " media=" screen " href = "screen.css" type = " text / css " />

Download Presentation

CSS3 Font Face

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. CSS3 Font Face Utiliser des polices de caractère non standard

  2. L’attribut media avant CSS3 • <!doctype html> • <head> • <metacharset="utf-8"> • <title>Media Queries !</title> • <linkrel="stylesheet"media="screen"href="screen.css"type="text/css"/> • <linkrel="stylesheet"media="print"href="print.css"type="text/css"/> • </head> • <body> ... </body>

  3. L’attribut media avant CSS3 • /* fichier: style.css */ • body { • color:red; • font-size:14px; • } • @media print { •   body { • font-size:18px; • color:black; • } • }

  4. Ce qui change avec CSS3 • Possibilité de ciblage étendues • Largeur et hauteur de l’appareil ou de la zone de visualisation • width/height , device-width/device-height • Orientation (portrait, paysage) • orientation, landscape / portrait • Résolution (en dpi par exemple) • resolution • Ratio de l’appareil (16/9 , 4/3 par exemple) • aspect-ratio

  5. Ce qui change avec CSS3 • Possibilité de mélanger plusieurs critères pour un seul bloc en utilisant des opérateurs logiques (et, ou, non, uniquement)Par exemple:@media screen and (max-width:640px){ /* ici du css */}

  6. Le problème du viewport sur mobile Affichage avec le viewport par défaut

  7. Le problème du viewport sur mobile • <!doctype html> • <head> • <metacharset="utf-8"> • <title>Media Queries !</title> • <metaname="viewport"content="initial-scale=1.0"> • </head> • <body> • ... • </body>

  8. les points de rupture • telephone • width < 768px • tablette • width >= 768 et =< 992 • ordi de bureau • width >= 992

  9. les points de rupture • @media screen and (max-width:768px){} • @media screen and(min-width: 768px) and (max-width: 992px){} • @media screen and (min-width: 992px){}

  10. Exemples de sites • http://3200tigres.wwf.fr/

More Related