Slide 1

Slide 1 text

Controlling Web Typography ConvergeSE 2011

Slide 2

Slide 2 text

Howdy! A little bit about myself...

Slide 3

Slide 3 text

I work with 2 of my best friends in Texas.

Slide 4

Slide 4 text

I’m this kid’s father. He’s trying to figure out what’s going on with my neck.

Slide 5

Slide 5 text

I think about food all the time.

Slide 6

Slide 6 text

My wife had to put me on a font allowance.

Slide 7

Slide 7 text

As web typography improves, web designers want the same level of control print designers have.

Slide 8

Slide 8 text

But what does that mean?

Slide 9

Slide 9 text

I want to use all these...

Slide 10

Slide 10 text

Not just these.

Slide 11

Slide 11 text

And put all this...

Slide 12

Slide 12 text

Into this.

Slide 13

Slide 13 text

CSS & Web Safe Fonts What can be achieved with the basics?

Slide 14

Slide 14 text

CSS We Know .thing{ font-size: 1em; line-height: 1.5px; font-style: italic; font-weight: bold; text-decoration: none; direction: ltr; font-variant: small-caps; text-indent: .5em; text-transform: none; text-align: left; letter-spacing: .1em; word-spacing: .1em; } Let’s put this stuff to work...

Slide 15

Slide 15 text

CSS & web safe fonts What can be achieved with the basics The growing prominence of web fonts seems to have boosted web designers’ interest in typography. Visual interest can be achieved with these CSS properties & core typographic principals.

Slide 16

Slide 16 text

CSS & web safe fonts What can be achieved with the basics The growing prominence of web fonts seems to have boosted web designers’ interest in typography. Visual interest can be achieved with these CSS properties & core typographic principals. font-family: georgia, serif;

Slide 17

Slide 17 text

CSS & web safe fonts What can be achieved with the basics The growing prominence of web fonts seems to have boosted web designers’ interest in typography. Visual interest can be achieved with these CSS properties & core typographic principals. font-size: 60px;

Slide 18

Slide 18 text

CSS & WEB SAFE FONTS What can be achieved with the basics The growing prominence of web fonts seems to have boosted web designers’ interest in typography. Visual interest can be achieved with these CSS properties & core typographic principals. text-transform: uppercase;

Slide 19

Slide 19 text

CSS & WEB SAFE FONTS What can be achieved with the basics The growing prominence of web fonts seems to have boosted web designers’ interest in typography. Visual interest can be achieved with these CSS properties & core typographic principals. letter-spacing: 2px;

Slide 20

Slide 20 text

CSS & WEB SAFE FONTS What can be achieved with the basics The growing prominence of web fonts seems to have boosted web designers’ interest in typography. Visual interest can be achieved with these CSS properties & core typographic principals. color: #c44032;

Slide 21

Slide 21 text

CSS & WEB SAFE FONTS What can be achieved with the basics The growing prominence of web fonts seems to have boosted web designers’ interest in typography. Visual interest can be achieved with these CSS properties & core typographic principals. font-style: italic;

Slide 22

Slide 22 text

CSS & WEB SAFE FONTS What can be achieved with the basics The growing prominence of web fonts seems to have boosted web designers’ interest in typography. Visual interest can be achieved with these CSS properties & core typographic principals. text-align: center;

Slide 23

Slide 23 text

CSS & WEB SAFE FONTS What can be achieved with the basics The growing prominence of web fonts seems to have boosted web designers’ interest in typography. Visual interest can be achieved with these CSS properties & core typographic principals. line-height: 20px; /* to wrap things up */

Slide 24

Slide 24 text

CSS & web safe fonts What can be achieved with the basics The growing prominence of web fonts seems to have boosted web designers’ interest in typography. Visual interest can be achieved with these CSS properties & core typographic principals. Before...

Slide 25

Slide 25 text

CSS & WEB SAFE FONTS What can be achieved with the basics The growing prominence of web fonts seems to have boosted web designers’ interest in typography. Visual interest can be achieved with these CSS properties & core typographic principals. After.

Slide 26

Slide 26 text

Still, being web safe is limiting. #TypeNerdProblems #GimmeWebFonts

Slide 27

Slide 27 text

ALTERNATE GOTHIC No. 1 became part of our brand.

Slide 28

Slide 28 text

2009: Our First Usage of @font-face

Slide 29

Slide 29 text

Web Font Services Choices, Resources & Greater Acceptance

Slide 30

Slide 30 text

No content

Slide 31

Slide 31 text

No content

Slide 32

Slide 32 text

No content

Slide 33

Slide 33 text

No content

Slide 34

Slide 34 text

No content

Slide 35

Slide 35 text

No content

Slide 36

Slide 36 text

No content

Slide 37

Slide 37 text

No content

Slide 38

Slide 38 text

sprungmarker.de

Slide 39

Slide 39 text

Web Fonts on Our Own Stuff

Slide 40

Slide 40 text

Alternate Gothic & Proxima Nova

Slide 41

Slide 41 text

Prociono (pro-cho-no?) via The League of Movable Type

Slide 42

Slide 42 text

FF Meta Serif & Liquorstore

Slide 43

Slide 43 text

Gaining Control With CSS3 We’ve got web fonts, and we’re not afraid to use them!

Slide 44

Slide 44 text

text-shadow: -3px 2px 0px #514d46;

Slide 45

Slide 45 text

color: rgba(7, 206, 250, 0.5); text-shadow: 18px 0px 0 #AD0918;

Slide 46

Slide 46 text

p.intro:first-letter{float:left; margin:0 3px 0 0; font-size:57px;}

Slide 47

Slide 47 text

Going Further Less Supported & More Adventurous

Slide 48

Slide 48 text

No content

Slide 49

Slide 49 text

This is beautiful. Now do it with selectable type. ;P Chandler Van De Water March 22, 2010

Slide 50

Slide 50 text

Google: CSS Background Text

Slide 51

Slide 51 text

.masked{ background: url(img/paint.png); -webkit-background-clip:text; -webkit-animation-name:masked-ani; } @-webkit-keyframes masked-ani{ 0% {background-position: left bottom;} 100% {background-position: right bottom;} }

Slide 52

Slide 52 text

No content

Slide 53

Slide 53 text

No content

Slide 54

Slide 54 text

.css:after{ content: "CSS Three"; -webkit-background-clip: text; background: url(crosshatch.png); }

Slide 55

Slide 55 text

But background-clip:text; degrades poorly.

Slide 56

Slide 56 text

-mask-image: url(css3/header-bkg-mask.png);

Slide 57

Slide 57 text

The Image Part Transparency knocks out the letters’ color fill

Slide 58

Slide 58 text

Lost World’s Fairs Putting This Stuff into Practice for IE9

Slide 59

Slide 59 text

No content

Slide 60

Slide 60 text

Meet my testing compy. It lives in a drawer.

Slide 61

Slide 61 text

Testing for the IE9 Platform Preview

Slide 62

Slide 62 text

No content

Slide 63

Slide 63 text

No content

Slide 64

Slide 64 text

No content

Slide 65

Slide 65 text

No content

Slide 66

Slide 66 text

But how to keep the markup manageable?

Slide 67

Slide 67 text

Injects around letters, words, or lines

Slide 68

Slide 68 text

Targeting Letters

Slide 69

Slide 69 text

The HTML

Onward & Upward

Slide 70

Slide 70 text

Add the JS

Onward & Upward

$(document).ready(function() { $("#txt_onward").lettering(); });

Slide 71

Slide 71 text

And you get...

O n w a r d & U p

Slide 72

Slide 72 text

#txt_onward .char1{top:13px;} #txt_onward .char2{top:12px;} #txt_onward .char3{top:11px;} #txt_onward .char4{top:10px;} #txt_onward .char5{top:9px;}

Slide 73

Slide 73 text

Targeting Words #left_teaser .word6{color:hsla(57, 100%, 39%, .8);} #left_teaser .word7{font-size:60px;} #left_teaser .word4, #left_teaser .word6{font:38px/.6 "chunk-1","chunk-2";}

Slide 74

Slide 74 text

Targeting Lines #txt_gillsorlungs .line1{font-size:18px; font-weight:700;} #txt_gillsorlungs .line2, #txt_gillsorlungs .line3{font-size:40px; color:#9ecc3b;} #txt_gillsorlungs .line4, #txt_gillsorlungs .line5{font-size:16px; font-style:italic;}

Slide 75

Slide 75 text

Lettering.js isn’t perfect. But maybe one day, enhanced CSS pseudo selectors could be.

Slide 76

Slide 76 text

Imagine this: h1:nth-letter(4); or h1:nth-char(4); targeting the 4th letter within an

tag h1:nth-word(3); targeting the third word within an

tag Further reading: http://twa.lt/f4L2zT

Slide 77

Slide 77 text

Web Fonts on Client Projects After Lost World’s Fairs, we became comfortable using web fonts on client gigs.

Slide 78

Slide 78 text

Fono Regular (thanks philsfonts.com)

Slide 79

Slide 79 text

Rooney & Proxima Nova

Slide 80

Slide 80 text

Web Fonts on My Blog! Taking Things as Far as I Can

Slide 81

Slide 81 text

transform: rotate(-8deg); /* w/ vendor prefixes */

Slide 82

Slide 82 text

text-shadow: #253e45 -1px 1px 0, #253e45 -2px 2px 0, #d45848 -3px 3px 0, #d45848 -4px 4px 0;

Slide 83

Slide 83 text

transform: scale(1) skewY(15deg); transform: scale(1) skewY(-15deg); /* w/ vendor prefixes */

Slide 84

Slide 84 text

Controlled Web Type & Responsive Can finely-tuned type be fluid, flexible, and responsive?

Slide 85

Slide 85 text

June 2010 Redesign

Slide 86

Slide 86 text

Thinking along the ‘touch’ theme you brought up, I’d be really interested to see how this design could be enhanced even further still using the responsive web design approach to building. Elliot Jay Stocks June 22, 2010

Slide 87

Slide 87 text

Ultimately, all the art-directed bits I had in place drove me to hold off, but I can’t help but think that If I change anything in the coming months, that’d be it. Trent Walton June 22, 2010

Slide 88

Slide 88 text

In Other Words...

Slide 89

Slide 89 text

Bazinga!

Slide 90

Slide 90 text

No content

Slide 91

Slide 91 text

No content

Slide 92

Slide 92 text

What’s Next? A quick glance at the future...

Slide 93

Slide 93 text

More support for background-clip:text; and mask-image & text

Slide 94

Slide 94 text

Layer Blends layer-blend:color-burn; :color-dodge; :multiply;

Slide 95

Slide 95 text

Gimme Specificity! h1:nth-letter(4); or h1:nth-char(4); To-The-Letter & Word CSS Selection h1:nth-word(3);

Slide 96

Slide 96 text

Questions?

Slide 97

Slide 97 text

Thanks! TrentWalton.com @TrentWalton