SlideShare uma empresa Scribd logo
1 de 37
What is @font-face?


• CSS2 rule
• Allows embedding of fonts through
  css

• Access hosted fonts instead of
  relying on user’s installed fonts
What’s the big deal?

• Rely on native browser rendering,
  the same as with web safe fonts

• Cufon/sifr great but css support is
  incomplete, plus relies on javascript

• It’s easy
• Print stylesheets work with @font-
  face
Can we use it?
colamovies.com
   28,766 Visitors
midlandsbiz.com
   10,253 Visitors
unmatchedstyle.com
     35,400 Visitors
With great power comes
  great responsibility


• @font-face makes knowledge of
  typography even more important

• great design has been done with
  only web-safe fonts
Not so fast!
So how do you do it?
@font-face {
    font-family: 'PTSansRegular';
    src: url('PT_Sans.eot');
    src: local('PT Sans Regular'), local('PTSans-Regular'),
         url('PT_Sans.woff') format('woff'),
         url('PT_Sans.ttf') format('truetype'),
         url('PT_Sans.svg#PTSans-Regular') format('svg');
}




p {

      font-family: "PTSansRegular", Helvetica, Arial, sans-serif;

}




           Based on: http://paulirish.com/2009/bulletproof-font-face-implementation-syntax/
So how do you do it?
@font-face {
    font-family: 'PTSansRegular';
    src: url('PT_Sans.eot');
    src: local('PT Sans Regular'), local('PTSans-Regular'),
         url('PT_Sans.woff') format('woff'),
         url('PT_Sans.ttf') format('truetype'),
         url('PT_Sans.svg#PTSans-Regular') format('svg');
}




p {

      font-family: "PTSansRegular", Helvetica, Arial, sans-serif;

}




           Based on: http://paulirish.com/2009/bulletproof-font-face-implementation-syntax/
So how do you do it?
@font-face {
    font-family: 'PTSansRegular';
    src: url('PT_Sans.eot');
    src: local('PT Sans Regular'), local('PTSans-Regular'),
         url('PT_Sans.woff') format('woff'),
         url('PT_Sans.ttf') format('truetype'),
         url('PT_Sans.svg#PTSans-Regular') format('svg');
}




p {

      font-family: "PTSansRegular", Helvetica, Arial, sans-serif;

}




           Based on: http://paulirish.com/2009/bulletproof-font-face-implementation-syntax/
So how do you do it?
@font-face {
    font-family: 'PTSansRegular';
    src: url('PT_Sans.eot');
    src: local('PT Sans Regular'), local('PTSans-Regular'),
         url('PT_Sans.woff') format('woff'),
         url('PT_Sans.ttf') format('truetype'),
         url('PT_Sans.svg#PTSans-Regular') format('svg');
}




p {

      font-family: "PTSansRegular", Helvetica, Arial, sans-serif;

}




           Based on: http://paulirish.com/2009/bulletproof-font-face-implementation-syntax/
So how do you do it?
@font-face {
    font-family: 'PTSansRegular';
    src: url('PT_Sans.eot');
    src: local('PT Sans Regular'), local('PTSans-Regular'),
         url('PT_Sans.woff') format('woff'),
         url('PT_Sans.ttf') format('truetype'),
         url('PT_Sans.svg#PTSans-Regular') format('svg');
}




p {

      font-family: "PTSansRegular", Helvetica, Arial, sans-serif;

}




           Based on: http://paulirish.com/2009/bulletproof-font-face-implementation-syntax/
So how do you do it?
@font-face {
    font-family: 'PTSansRegular';
    src: url('PT_Sans.eot');
    src: local('PT Sans Regular'), local('PTSans-Regular'),
         url('PT_Sans.woff') format('woff'),
         url('PT_Sans.ttf') format('truetype'),
         url('PT_Sans.svg#PTSans-Regular') format('svg');
}




p {

      font-family: "PTSansRegular", Helvetica, Arial, sans-serif;

}




           Based on: http://paulirish.com/2009/bulletproof-font-face-implementation-syntax/
Licensing

• Make sure you own a license for
  font

• Read the EULA from each foundry.
• Take precautions to secure the
  font from download

• Typekit fills a void
Browser Differences
      Firefox Mac          IE/FF XP with Cleartype




Firefox XP w/o Cleartype     IE6 w/o Cleartype
IE Jaggy Fix
p {

      filter: alpha(opacity=100);
      -ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=100)";

}
IE Jaggy Fix
p {

      filter: alpha(opacity=100);
      -ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=100)";

}
FOUT


• Flash of
  unstyled
  text

• Webkit
  hides font
Fighting the FOUT

• place css at top so it loads first
• use Paul Irish embed method
• use server side compression to
  serve files (zip/gzip)

• base64 encode ttf/otf fonts
• subset fonts to reduce file size
Without base64 encoding
Without base64 encoding
Without base64 encoding
Without base64 encoding
With base64 encoding
With base64 encoding
With base64 encoding
Fighting the FOUT

• place css at top so it loads first
• use Paul Irish embed method
• use server side compression to serve
  files

• base64 encode ttf/otf fonts
• subset fonts to reduce file size
Subset Fonts
fontsquirrel @font-face generator




 http://www.fontsquirrel.com/fontface/generator
Use correct font for styles
h1, strong {

       font-weight: normal;
       font-family: "PTSansBold", Helvetica, Arial, sans-serif;

}

em {

       font-style: normal;
       font-family: "PTSansItalic", Helvetica, Arial, sans-serif;

}




       • Webkit interprets correctly, other
          browsers not so much
My @font-face site: petridisc.com

       Resources & Tools
          fontsquirrel.com
           webfonts.info
            paulirish.com
             typekit.com
        webfontspecimen.com




 Get crackin’.

Mais conteúdo relacionado

Destaque

15 Talking Typefaces: What Your Font Choice Really Means
15 Talking Typefaces: What Your Font Choice Really Means15 Talking Typefaces: What Your Font Choice Really Means
15 Talking Typefaces: What Your Font Choice Really Means97th Floor
 
Newstyleguide 2013 forms_updated
Newstyleguide 2013 forms_updatedNewstyleguide 2013 forms_updated
Newstyleguide 2013 forms_updatedAlyssa Richards
 
6 Strategies for Presenting Data & Charts
6 Strategies for Presenting Data & Charts6 Strategies for Presenting Data & Charts
6 Strategies for Presenting Data & ChartsMGT OPEN
 
Creating Charts for Presentations
Creating Charts for PresentationsCreating Charts for Presentations
Creating Charts for PresentationsVisually
 
Types Of Charts
Types Of ChartsTypes Of Charts
Types Of Chartswmassie
 
The Things I Carry
The Things I Carry The Things I Carry
The Things I Carry Chiara Ojeda
 
The State of Financial Presentations 2014 Survey Results
The State of Financial Presentations 2014 Survey ResultsThe State of Financial Presentations 2014 Survey Results
The State of Financial Presentations 2014 Survey ResultsDave Paradi
 
5 Secrets to Better Presentation Charts and Graphs
5 Secrets to Better Presentation Charts and Graphs5 Secrets to Better Presentation Charts and Graphs
5 Secrets to Better Presentation Charts and GraphsMetamorph Training Pvt Ltd
 
120 Awesome Marketing Stats, Charts and Graphs
120 Awesome Marketing Stats, Charts and Graphs120 Awesome Marketing Stats, Charts and Graphs
120 Awesome Marketing Stats, Charts and GraphsHubSpot
 
How to Present Data in PowerPoint
How to Present Data in PowerPointHow to Present Data in PowerPoint
How to Present Data in PowerPointMatt Hunter
 
Visual Data Representation Techniques Combining Art and Design
Visual Data Representation Techniques Combining Art and DesignVisual Data Representation Techniques Combining Art and Design
Visual Data Representation Techniques Combining Art and DesignLogo Design Guru
 
7 tips to create visual presentations
7 tips to create visual presentations7 tips to create visual presentations
7 tips to create visual presentationsEmiland
 
How to Write Clickass Presentations that Convert
How to Write Clickass Presentations that ConvertHow to Write Clickass Presentations that Convert
How to Write Clickass Presentations that ConvertBarry Feldman
 
Zombie PowerPoint by @ericpesik
Zombie PowerPoint by @ericpesikZombie PowerPoint by @ericpesik
Zombie PowerPoint by @ericpesikEric Pesik
 
THE PRESENTATION DESIGN CRASH COURSE
THE PRESENTATION DESIGN CRASH COURSETHE PRESENTATION DESIGN CRASH COURSE
THE PRESENTATION DESIGN CRASH COURSEJoseph Gelman
 
7 Tips to Beautiful PowerPoint by @itseugenec
7 Tips to Beautiful PowerPoint by @itseugenec7 Tips to Beautiful PowerPoint by @itseugenec
7 Tips to Beautiful PowerPoint by @itseugenecEugene Cheng
 
SlideShare Experts - 7 Experts Reveal Their Presentation Design Secrets
SlideShare Experts - 7 Experts Reveal Their Presentation Design SecretsSlideShare Experts - 7 Experts Reveal Their Presentation Design Secrets
SlideShare Experts - 7 Experts Reveal Their Presentation Design SecretsEugene Cheng
 

Destaque (20)

15 Talking Typefaces: What Your Font Choice Really Means
15 Talking Typefaces: What Your Font Choice Really Means15 Talking Typefaces: What Your Font Choice Really Means
15 Talking Typefaces: What Your Font Choice Really Means
 
Newstyleguide 2013 forms_updated
Newstyleguide 2013 forms_updatedNewstyleguide 2013 forms_updated
Newstyleguide 2013 forms_updated
 
6 Strategies for Presenting Data & Charts
6 Strategies for Presenting Data & Charts6 Strategies for Presenting Data & Charts
6 Strategies for Presenting Data & Charts
 
Creating Charts for Presentations
Creating Charts for PresentationsCreating Charts for Presentations
Creating Charts for Presentations
 
PIE CHART
PIE CHARTPIE CHART
PIE CHART
 
Types Of Charts
Types Of ChartsTypes Of Charts
Types Of Charts
 
The Things I Carry
The Things I Carry The Things I Carry
The Things I Carry
 
Charts And Graphs
Charts And GraphsCharts And Graphs
Charts And Graphs
 
The State of Financial Presentations 2014 Survey Results
The State of Financial Presentations 2014 Survey ResultsThe State of Financial Presentations 2014 Survey Results
The State of Financial Presentations 2014 Survey Results
 
10 Ways to be a Marketing Genius Like Lady Gaga
10 Ways to be a Marketing Genius Like Lady Gaga10 Ways to be a Marketing Genius Like Lady Gaga
10 Ways to be a Marketing Genius Like Lady Gaga
 
5 Secrets to Better Presentation Charts and Graphs
5 Secrets to Better Presentation Charts and Graphs5 Secrets to Better Presentation Charts and Graphs
5 Secrets to Better Presentation Charts and Graphs
 
120 Awesome Marketing Stats, Charts and Graphs
120 Awesome Marketing Stats, Charts and Graphs120 Awesome Marketing Stats, Charts and Graphs
120 Awesome Marketing Stats, Charts and Graphs
 
How to Present Data in PowerPoint
How to Present Data in PowerPointHow to Present Data in PowerPoint
How to Present Data in PowerPoint
 
Visual Data Representation Techniques Combining Art and Design
Visual Data Representation Techniques Combining Art and DesignVisual Data Representation Techniques Combining Art and Design
Visual Data Representation Techniques Combining Art and Design
 
7 tips to create visual presentations
7 tips to create visual presentations7 tips to create visual presentations
7 tips to create visual presentations
 
How to Write Clickass Presentations that Convert
How to Write Clickass Presentations that ConvertHow to Write Clickass Presentations that Convert
How to Write Clickass Presentations that Convert
 
Zombie PowerPoint by @ericpesik
Zombie PowerPoint by @ericpesikZombie PowerPoint by @ericpesik
Zombie PowerPoint by @ericpesik
 
THE PRESENTATION DESIGN CRASH COURSE
THE PRESENTATION DESIGN CRASH COURSETHE PRESENTATION DESIGN CRASH COURSE
THE PRESENTATION DESIGN CRASH COURSE
 
7 Tips to Beautiful PowerPoint by @itseugenec
7 Tips to Beautiful PowerPoint by @itseugenec7 Tips to Beautiful PowerPoint by @itseugenec
7 Tips to Beautiful PowerPoint by @itseugenec
 
SlideShare Experts - 7 Experts Reveal Their Presentation Design Secrets
SlideShare Experts - 7 Experts Reveal Their Presentation Design SecretsSlideShare Experts - 7 Experts Reveal Their Presentation Design Secrets
SlideShare Experts - 7 Experts Reveal Their Presentation Design Secrets
 

Semelhante a What the @font-face

Making drupal beautiful with web fonts
Making drupal beautiful with web fontsMaking drupal beautiful with web fonts
Making drupal beautiful with web fontsFour Kitchens
 
Web Fonts: Why Bother?
Web Fonts: Why Bother?Web Fonts: Why Bother?
Web Fonts: Why Bother?Greg Veen
 
Employing Custom Fonts
Employing Custom FontsEmploying Custom Fonts
Employing Custom FontsPaul Irish
 
Implementing @font-face
Implementing @font-faceImplementing @font-face
Implementing @font-faceAban Nesta
 
CSS @font-face : Personalized fonts
CSS @font-face : Personalized fontsCSS @font-face : Personalized fonts
CSS @font-face : Personalized fontsYves Van Goethem
 
Web Typography Tips
Web Typography TipsWeb Typography Tips
Web Typography TipsSara Cannon
 
The NEW Web Typography: Where the Sexy Is
The NEW Web Typography: Where the Sexy IsThe NEW Web Typography: Where the Sexy Is
The NEW Web Typography: Where the Sexy IsJason CranfordTeague
 
The New Web Typography
The New Web TypographyThe New Web Typography
The New Web TypographyForum One
 
New Web Typography
New Web TypographyNew Web Typography
New Web TypographyMonotype
 
How do speed up web pages? CSS & HTML Tricks
How do speed up web pages? CSS & HTML TricksHow do speed up web pages? CSS & HTML Tricks
How do speed up web pages? CSS & HTML TricksCompare Infobase Limited
 
Mix10 final snook_ds15
Mix10 final snook_ds15Mix10 final snook_ds15
Mix10 final snook_ds15Jonathan Snook
 
The Type We Want (MIX10)
The Type We Want (MIX10)The Type We Want (MIX10)
The Type We Want (MIX10)Jonathan Snook
 
Html5, css3, canvas, svg and webgl
Html5, css3, canvas, svg and webglHtml5, css3, canvas, svg and webgl
Html5, css3, canvas, svg and webglKilian Valkhof
 
[Worskhop Summits] CSS3 Workshop
[Worskhop Summits] CSS3 Workshop[Worskhop Summits] CSS3 Workshop
[Worskhop Summits] CSS3 WorkshopChristopher Schmitt
 
Typography for WordPress
Typography for WordPressTypography for WordPress
Typography for WordPressNile Flores
 
Why CSS Was Invented (Håkon Wium Lie)
Why CSS Was Invented (Håkon Wium Lie)Why CSS Was Invented (Håkon Wium Lie)
Why CSS Was Invented (Håkon Wium Lie)Future Insights
 

Semelhante a What the @font-face (20)

Making drupal beautiful with web fonts
Making drupal beautiful with web fontsMaking drupal beautiful with web fonts
Making drupal beautiful with web fonts
 
Web Fonts: Why Bother?
Web Fonts: Why Bother?Web Fonts: Why Bother?
Web Fonts: Why Bother?
 
Employing Custom Fonts
Employing Custom FontsEmploying Custom Fonts
Employing Custom Fonts
 
Implementing @font-face
Implementing @font-faceImplementing @font-face
Implementing @font-face
 
CSS @font-face : Personalized fonts
CSS @font-face : Personalized fontsCSS @font-face : Personalized fonts
CSS @font-face : Personalized fonts
 
The State of Web Type
The State of Web TypeThe State of Web Type
The State of Web Type
 
new fonts for the web
new fonts for the webnew fonts for the web
new fonts for the web
 
Web Typography Tips
Web Typography TipsWeb Typography Tips
Web Typography Tips
 
The NEW Web Typography: Where the Sexy Is
The NEW Web Typography: Where the Sexy IsThe NEW Web Typography: Where the Sexy Is
The NEW Web Typography: Where the Sexy Is
 
The New Web Typography
The New Web TypographyThe New Web Typography
The New Web Typography
 
New Web Typography
New Web TypographyNew Web Typography
New Web Typography
 
The Trouble With Type
The Trouble With TypeThe Trouble With Type
The Trouble With Type
 
How do speed up web pages? CSS & HTML Tricks
How do speed up web pages? CSS & HTML TricksHow do speed up web pages? CSS & HTML Tricks
How do speed up web pages? CSS & HTML Tricks
 
Mix10 final snook_ds15
Mix10 final snook_ds15Mix10 final snook_ds15
Mix10 final snook_ds15
 
The Type We Want (MIX10)
The Type We Want (MIX10)The Type We Want (MIX10)
The Type We Want (MIX10)
 
Html5, css3, canvas, svg and webgl
Html5, css3, canvas, svg and webglHtml5, css3, canvas, svg and webgl
Html5, css3, canvas, svg and webgl
 
[Worskhop Summits] CSS3 Workshop
[Worskhop Summits] CSS3 Workshop[Worskhop Summits] CSS3 Workshop
[Worskhop Summits] CSS3 Workshop
 
Typography for WordPress
Typography for WordPressTypography for WordPress
Typography for WordPress
 
[heweb11] CSS3 Makeover
[heweb11] CSS3 Makeover[heweb11] CSS3 Makeover
[heweb11] CSS3 Makeover
 
Why CSS Was Invented (Håkon Wium Lie)
Why CSS Was Invented (Håkon Wium Lie)Why CSS Was Invented (Håkon Wium Lie)
Why CSS Was Invented (Håkon Wium Lie)
 

Último

DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDropbox
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vázquez
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Zilliz
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processorsdebabhi2
 
CNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In PakistanCNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In Pakistandanishmna97
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MIND CTI
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxRustici Software
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 
Cyberprint. Dark Pink Apt Group [EN].pdf
Cyberprint. Dark Pink Apt Group [EN].pdfCyberprint. Dark Pink Apt Group [EN].pdf
Cyberprint. Dark Pink Apt Group [EN].pdfOverkill Security
 
Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024The Digital Insurer
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobeapidays
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyKhushali Kathiriya
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingEdi Saputra
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Victor Rentea
 
AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024The Digital Insurer
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Jeffrey Haguewood
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoffsammart93
 
Spring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUKSpring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUKJago de Vreede
 

Último (20)

DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
CNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In PakistanCNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In Pakistan
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Cyberprint. Dark Pink Apt Group [EN].pdf
Cyberprint. Dark Pink Apt Group [EN].pdfCyberprint. Dark Pink Apt Group [EN].pdf
Cyberprint. Dark Pink Apt Group [EN].pdf
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
 
AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Spring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUKSpring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUK
 

What the @font-face

  • 1.
  • 2.
  • 3.
  • 4. What is @font-face? • CSS2 rule • Allows embedding of fonts through css • Access hosted fonts instead of relying on user’s installed fonts
  • 5. What’s the big deal? • Rely on native browser rendering, the same as with web safe fonts • Cufon/sifr great but css support is incomplete, plus relies on javascript • It’s easy • Print stylesheets work with @font- face
  • 7. colamovies.com 28,766 Visitors
  • 8. midlandsbiz.com 10,253 Visitors
  • 9. unmatchedstyle.com 35,400 Visitors
  • 10. With great power comes great responsibility • @font-face makes knowledge of typography even more important • great design has been done with only web-safe fonts
  • 11.
  • 12.
  • 13.
  • 15. So how do you do it? @font-face { font-family: 'PTSansRegular'; src: url('PT_Sans.eot'); src: local('PT Sans Regular'), local('PTSans-Regular'), url('PT_Sans.woff') format('woff'), url('PT_Sans.ttf') format('truetype'), url('PT_Sans.svg#PTSans-Regular') format('svg'); } p { font-family: "PTSansRegular", Helvetica, Arial, sans-serif; } Based on: http://paulirish.com/2009/bulletproof-font-face-implementation-syntax/
  • 16. So how do you do it? @font-face { font-family: 'PTSansRegular'; src: url('PT_Sans.eot'); src: local('PT Sans Regular'), local('PTSans-Regular'), url('PT_Sans.woff') format('woff'), url('PT_Sans.ttf') format('truetype'), url('PT_Sans.svg#PTSans-Regular') format('svg'); } p { font-family: "PTSansRegular", Helvetica, Arial, sans-serif; } Based on: http://paulirish.com/2009/bulletproof-font-face-implementation-syntax/
  • 17. So how do you do it? @font-face { font-family: 'PTSansRegular'; src: url('PT_Sans.eot'); src: local('PT Sans Regular'), local('PTSans-Regular'), url('PT_Sans.woff') format('woff'), url('PT_Sans.ttf') format('truetype'), url('PT_Sans.svg#PTSans-Regular') format('svg'); } p { font-family: "PTSansRegular", Helvetica, Arial, sans-serif; } Based on: http://paulirish.com/2009/bulletproof-font-face-implementation-syntax/
  • 18. So how do you do it? @font-face { font-family: 'PTSansRegular'; src: url('PT_Sans.eot'); src: local('PT Sans Regular'), local('PTSans-Regular'), url('PT_Sans.woff') format('woff'), url('PT_Sans.ttf') format('truetype'), url('PT_Sans.svg#PTSans-Regular') format('svg'); } p { font-family: "PTSansRegular", Helvetica, Arial, sans-serif; } Based on: http://paulirish.com/2009/bulletproof-font-face-implementation-syntax/
  • 19. So how do you do it? @font-face { font-family: 'PTSansRegular'; src: url('PT_Sans.eot'); src: local('PT Sans Regular'), local('PTSans-Regular'), url('PT_Sans.woff') format('woff'), url('PT_Sans.ttf') format('truetype'), url('PT_Sans.svg#PTSans-Regular') format('svg'); } p { font-family: "PTSansRegular", Helvetica, Arial, sans-serif; } Based on: http://paulirish.com/2009/bulletproof-font-face-implementation-syntax/
  • 20. So how do you do it? @font-face { font-family: 'PTSansRegular'; src: url('PT_Sans.eot'); src: local('PT Sans Regular'), local('PTSans-Regular'), url('PT_Sans.woff') format('woff'), url('PT_Sans.ttf') format('truetype'), url('PT_Sans.svg#PTSans-Regular') format('svg'); } p { font-family: "PTSansRegular", Helvetica, Arial, sans-serif; } Based on: http://paulirish.com/2009/bulletproof-font-face-implementation-syntax/
  • 21. Licensing • Make sure you own a license for font • Read the EULA from each foundry. • Take precautions to secure the font from download • Typekit fills a void
  • 22. Browser Differences Firefox Mac IE/FF XP with Cleartype Firefox XP w/o Cleartype IE6 w/o Cleartype
  • 23. IE Jaggy Fix p { filter: alpha(opacity=100); -ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=100)"; }
  • 24. IE Jaggy Fix p { filter: alpha(opacity=100); -ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=100)"; }
  • 25. FOUT • Flash of unstyled text • Webkit hides font
  • 26. Fighting the FOUT • place css at top so it loads first • use Paul Irish embed method • use server side compression to serve files (zip/gzip) • base64 encode ttf/otf fonts • subset fonts to reduce file size
  • 34. Fighting the FOUT • place css at top so it loads first • use Paul Irish embed method • use server side compression to serve files • base64 encode ttf/otf fonts • subset fonts to reduce file size
  • 35. Subset Fonts fontsquirrel @font-face generator http://www.fontsquirrel.com/fontface/generator
  • 36. Use correct font for styles h1, strong { font-weight: normal; font-family: "PTSansBold", Helvetica, Arial, sans-serif; } em { font-style: normal; font-family: "PTSansItalic", Helvetica, Arial, sans-serif; } • Webkit interprets correctly, other browsers not so much
  • 37. My @font-face site: petridisc.com Resources & Tools fontsquirrel.com webfonts.info paulirish.com typekit.com webfontspecimen.com Get crackin’.

Notas do Editor

  1. CSS2 finished in 1998
  2. <font> - let you figure that one out images - hard to maintain, not as accessible, potentially large web fonts - limited # of fonts, but the way it’s done today, in conjunction with cufon
  3. FF3 released 6/08, FF 3.5 released 6/09, matter of months will be smaller. Chrome is growing, but new installs will support. Seems to have slower uptake. Is it a client site or personal? Who is the audience? Will your client understand if things don’t look exactly the same everywhere?
  4. colamovies jan 2010. Important to look at your stats.
  5. colamovies jan 2010. Important to look at your stats.
  6. colamovies jan 2010. Important to look at your stats.