Screen Color and Typography

75
Screen color and typography January 22, 2007

Transcript of Screen Color and Typography

Page 1: Screen Color and Typography

Screen color and typography January 22, 2007

Page 2: Screen Color and Typography

Scope• Functions of color and typography• Color models• Hexadecimal system• Color technical standards• Typography concerns• Typeface issues• HTML and CSS• Graphic text• Remember the user

Page 3: Screen Color and Typography

Importance of color and typography• Build hierarchy, structure, organization • Create context• Enhance content• Draw attention• Provoke emotions• Convey meaning• Visual communication• Aid to metaphor, navigation, label, logo, graphics...

Page 4: Screen Color and Typography

Advantages of using color• Color can give a more polished and

professional look to a website.• Colors can evoke certain feelings and moods

in people browsing the site.

Page 5: Screen Color and Typography

The electromagnetic spectrum• Measure of photons, traveling at the

speed of light, carrying some type of energy

• Measured in terms of wavelength and frequency

Page 6: Screen Color and Typography

The electromagnetic spectrum

Page 7: Screen Color and Typography

Visible light

• Occurs in a small part of the EM spectrum, near the middle

• Wavelengths are 400nm to 700nm long

Page 8: Screen Color and Typography

Additive color model• Used by computers• When light energy is

added, a color appears brighter

• Different visible light wavelengths can be combined to create new colors

• Referred to as RGB (Red, Green, Blue)

Page 9: Screen Color and Typography

Subtractive color model• Used in the print media• When more color is

added, a color appears darker

• Ink or paint can be thought of a filter that filters out all colors except the color being perceived, which is reflected

• Referred to as CMYK (Cyan, Magenta, Yellow, Black)

Page 10: Screen Color and Typography

Primary colors• Technically, pure primary colors are spectral

colors which cannot be mixed from other colors• A small number of colors can be mixed to create

new colors• The additive color model uses Red, Green and

Blue (RGB) as additive primaries• The subtractive color model uses Cyan, Magenta,

Yellow and Black (CYMK) as subtractive primaries

Page 11: Screen Color and Typography

Some color terms• Hue – A specific location on the visible

spectrum

• Saturation – Specifies the amount (intensity) of a color

Page 12: Screen Color and Typography

Some color terms• Value (Brightness) – Specifies the

darkness/lightness of a color• Tint – Adding WHITE to a color• Shade – Adding BLACK to a color

Page 13: Screen Color and Typography

The color wheel• A common way to

map color is to use the color wheel

• All hues are depicted as an angle on the wheel (0° represents RED and 360° represents VIOLET)

Page 14: Screen Color and Typography

The color wheel• Saturation is represented as a percentage• Value is represented as a percentage• RED, YELLOW, and BLUE are the color

wheels primary colors

Page 15: Screen Color and Typography

Web color: screen display• Pixel (picture element):

x and y coordinates• Color depth (resolution):

– 1-bit 2 colors (black and white)– 8-bit 256 colors– 16-bit thousands of colors– 24-bit millions of colors (true color)

Page 16: Screen Color and Typography

Color• 8-bit color: 256 colors• "Web-safe color"

– Based on 8-bit color graphics– Most modern computers now capable of:

• 16-bit: over 60,000 colors• 24-bit: over 16 million (true color)

Page 17: Screen Color and Typography

Dithering

Page 18: Screen Color and Typography

Web color: browser• Dithering: illusion of missing colors

– Diminish harsh transition, sharpness

• Web (Browser)-safe color:– Based on 8-bit color screen display: 216 cross platform color

palette– “Reallysafe” colors: only 22 colors ☹– Strategy:

• Identify your audience’s technologies• Use “Reallysafe” palette• Use transparent backgrounds• Use Flash

Page 19: Screen Color and Typography

Color as a numeric constant• Digital color is normally represented as a

numeric constant in triplet format, representing RGB values

• In many graphic programs RGB values are represented as a percentage (0%-100%) or as an integer (0-255)

• On the web, color triplets are often represented using hexadecimal numbers

Page 20: Screen Color and Typography

Common hex values

RGB 0 51 102 153 204 255

PERC 0% 20% 40% 60% 80% 100%

HEX 00 33 66 99 CC FF

Page 21: Screen Color and Typography

Hexadecimal values• Color codes in HTML are specified by the # sign

followed by six digits that consist of three hexadecimal numbers (two each for the amount of red, green, and blue in the color).

• There are 16 x 16 = 256 different amounts of each color that can be selected.

• 256 x 256 x 256 = 16.7 million colors possible

Page 22: Screen Color and Typography

Hexidecimal system• HTML and CSS • Every color is made up of a different value for

red, green, and blue components-ranging from 0 to 255

Page 23: Screen Color and Typography

Hexidecimal system• Six digit number, 3 bytes - RRGGBB

– Byte 1 - Red– Byte 2 - Green – Byte 3 - Blue

• Black - #000000• White - #FFFFFF• Red - #FF0000 • Green - #00FF00• Blue - #0000FF

Page 24: Screen Color and Typography

Color values# RED GREEN BLUE# 00 00 00 (0%)# FF FF FF (100%)

Samples:

#FF0000 #00FF00 #0000FF

(Red) (Green) (Blue)

#00FFFF #FFFF00 #FF00FF(Cyan) (Yellow) (Magenta)

Page 25: Screen Color and Typography

Choosing colors• How do you know what the hex codes are for the

colors you want to use? • Consult a chart of common colors • Choose the color desired and convert the RGB values

to hexadecimal– Image editors, such as Adobe Photoshop, will show the R, G,

and B values from 0 to 255– Convert these values to their hex equivalent using a scientific

calculator, chart or shareware

Page 26: Screen Color and Typography

Color symbolism• Use color to convey meaning:

– Black: power, stylish, timeless– White: purity, neutral, summer– Red: action, confidence, courage, vitality, love,

intensity– Green: life, nature, fertility, calming– Blue: Loyalty, truth, peace, depressing

Page 27: Screen Color and Typography

http://www.toydrum.com/

Page 28: Screen Color and Typography

http://www.rockcorps.org/

Page 29: Screen Color and Typography

http://www.jrgeoffrion.com/

Page 30: Screen Color and Typography

Typography for the webMaking text web-ready

Page 31: Screen Color and Typography

What is typography?• Dictionary.com: The art and technique of printing with

movable type. • Wikipedia: The art and technique of selecting and

arranging type styles, point sizes, line lengths, line leading, character spacing, and word spacing for typeset applications. These applications can be physical or digital.

• Web Style Guide: The balance and interplay of letterforms on the page, a verbal and visual equation that helps the reader understand the form and absorb the substance of the page content.

Page 32: Screen Color and Typography

History of web typography• Macintosh: Graphical User Interface (GUI),

bitmapped city-named fonts• Adobe: Postscript• Apple + Microsoft: Truetype• HTML: Problem with heading tag• CSS: Provide control over exact visual style

Page 33: Screen Color and Typography

Typefaces• Serif vs. sans-serif: sans-serif generally more

clear on the computer screen because of coarse screen resolution

• Examples of great web typefaces:– Arial– Verdana

Page 34: Screen Color and Typography

Type• Serif: stroke at the ends of a letter• Sans Serif: without serifs• Leading: vertical space between baselines• Kerning: horizontal space between letters

Page 35: Screen Color and Typography
Page 36: Screen Color and Typography

HTML and CSS• HTML: Uses font tags to define text attributes

– Bold– Italic– Font size– Color

• CSS: Requires less code– Increases consistency– Changes are easier– Saves time

Page 37: Screen Color and Typography

Graphic text• Pros

– Good for decorative text– More design options– Good for headlines

• Cons– Longer display time– Harder to edit– User cannot customize

Page 38: Screen Color and Typography

Google’s logo• Typography v.s. logo• Color v.s. logo

Page 39: Screen Color and Typography
Page 40: Screen Color and Typography
Page 41: Screen Color and Typography
Page 42: Screen Color and Typography
Page 43: Screen Color and Typography

10 steps to professional web type• Use one or two • Use left-justified type• Give text space (white space)• Avoid bold type for paragraph text• Avoid all capital text• Use headlines to chunk text• Use columns• Avoid overly large text• Only underline links• Use graphic text correctly

Page 44: Screen Color and Typography

Typography for the web• Legibility: good typography depends on visual

contrast between fonts, text blocks, headlines, space– Alignment: margins, unity, white space, visual

relief– Line length: columns, invisible tables – Typefaces: Georgia and Verdana for screen– Case: upper + lower– Emphasis: italics, bold…

Page 45: Screen Color and Typography

Typography for the web• Consistency: create harmonic structure,

predictable• Accessibility:

– Size: use relative units, offer text-only version– Color: contrast

Page 46: Screen Color and Typography

Remembering the user• Computer systems are going to vary from

user to user• Individuals have different visual issues, like

color blindness or aging eyes - their perception of your site will differ from many users

• Color and typography should reflect the purpose of your site.

• Colors and text provoke emotional responses.

Page 47: Screen Color and Typography

http://www.rsub.com/typographic/

Page 48: Screen Color and Typography

http://www.rsub.com/typographic/

Page 49: Screen Color and Typography

http://www.juxtinteractive.com/

Page 50: Screen Color and Typography

http://www.thetruth.com/index.cfm?seek=truth

Page 51: Screen Color and Typography

Color and typography in HTMLTaking your HTML further

Page 52: Screen Color and Typography

Color on the web• Font tag can also take a color attribute• Colors are specified two ways:

– well defined palette of colors with names– a hex string of red, green, blue values (#FF66CC)

• body tag can also take color attributes:– bgcolor the page background color– text color of normal text– link links on the page– vlink links that have been visited– alink color a link flashes when clicked

Page 53: Screen Color and Typography

HTML color attributes• BASEFONT and FONT tags have COLOR = (value)

attributes• The BODY tag has BGCOLOR, TEXT, LINK, VLINK,

and ALINK color attributes

Page 54: Screen Color and Typography

Predefined colors• There are 16 palette colors that can be

specified by their names:

White Cyan Silver Navy

Red Magenta Gray Lime

Green Yellow Maroon Olive

Blue Black Purple Teal

Page 55: Screen Color and Typography

Web color: HTML

Brown  #A52A2A  

BurlyWood  #DEB887  

CadetBlue  #5F9EA0  

Chartreuse  #7FFF00  

Chocolate  #D2691E  

Coral  #FF7F50  

CornflowerBlue  #6495ED  

Cornsilk  #FFF8DC  

Crimson  #DC143C  

Page 56: Screen Color and Typography

Spot color• Examples:

<P><FONT COLOR =“red”>Stop</FONT>

the presses.Throw <FONT COLOR = #FFFF00> caution

</FONT> to the wind.<FONT COLOR = #00FF00>GO</FONT> FOR IT!</P>

Page 57: Screen Color and Typography

Body tag attributes• <BODY BGCOLOR= #FFFFFF>• <BODY TEXT= “blue”>• <BODY LINK=“red”>• <BODY VLINK=#00FF00> Visited Links• <BODY ALINK=#0000FF> Active (As you click)• <BODY BACKGROUND=“logo.gif”> (Image)• <BODY BGCOLOR=“white” TEXT=“blue”

LINK= #FF00FF ALINK= #FFB5C5>

Page 58: Screen Color and Typography

Specifying colors• As shown in the examples, there are two

ways of specifying color values for the HTML attributes:

1. Specify in “ “ one of the predefined color names recognized by popular browsers

2. Specify the color by its hexadecimal number for red, green, and blue components

Page 59: Screen Color and Typography

Using fonts in web pages• By default most browsers render in Times• The font and size can be changed three ways:

– <font>…</font> changes font for one block

– <basefont> changes the font for whole page (*)

– style sheet code: best solution but complex

• Three standard fonts: Times, Arial, Courier• Font syntax makes it easy to fallback

Page 60: Screen Color and Typography

Font tags• Basic usage:

– <font> …stuff… </font>

– should always be used inside <p> tags

• Attributes:– face the name of the fonts to use

– size the size of the font

– color the color, as an RGB hexadecimal string

<p><font face="Arial" size=3>Hello!</font></p>

Page 61: Screen Color and Typography

Font face and size• Safe choices for face attribute include:

– Arial, Helvetica, sans-serif

– Times New Roman, Times, serif

– Courier New, Courier, mono

• For exotic fonts always provide a fallback:<font face="Futura, Arial Narrow, Arial, sans-serif”>

• Size of fonts specified several ways:– absolute: value between 1 and 7

– 1 smallest font size, 3 is the default

– relative: value from -7 … +7

Page 62: Screen Color and Typography

Alternative size tags• <big>…</big> use a large font• <small>…</small> use a small font• <sup>…</sup> superscript• <sub>…</sub> subscript

Page 63: Screen Color and Typography

BASEFONT tag• To set the default font values for a whole page• Unpaired tag which appears in head or body• Face, size, and color attributes

Example:– <basefont face="Arial" size="2" color="#001040">

• I have had inconsistent results with this tag• Replaced by CSS code in HTML5

Page 64: Screen Color and Typography

Example<body bgcolor="#FFFFFF" text="#000000">

<p>Lets <font color="#FF0000">play around</font> with some of the font tags</p>

<p>

<font face="Arial, Helvetica, sans-serif">

<font size="7">very big (7)</font><br>

<font size="6">not quite so big (6)</font><br>

<font size="5">big-ish (5)</font><br>

<font size="4">still quit large (4)</font><br>

<font size="3">normal</font> (3)<br>

<font size="2">smaller (2)</font><br>

<font size="1">itty-bitty sized (1)</font>

</font>

</p>

</body>

Page 65: Screen Color and Typography

Example

Page 66: Screen Color and Typography

BLOCKQUOTE tags• To make a piece of text appear indented use the

blockquote tags• Sits outside a normal paragraph• Useful for simple indenting

<p>Here is a quote by somebody famous:</p><blockquote> Gosh it's nice being so fabulously well known and having such great big piles of money</blockquote><p>Insightful don't you think?</p>

Page 67: Screen Color and Typography

PRE tags• To make the browser respect spaces and lines use

the PRE tags (preformatted text)• Easy layout but everything in typewriter font

<pre>This little block of pre-formatted text demonstrates how to make HTML

respectspaces and lines.Some HTML <b>formatting</b> tags <i>still</i> work correctlyin andlt;preandgt; blocks</pre>

Page 68: Screen Color and Typography

Example

Page 69: Screen Color and Typography

Adding lists to your HTMLProviding variety and utility

Page 70: Screen Color and Typography

Ordered and unordered listsUnordered lists•Sardine•Tuna•Salmon

<ul>

<li>Sardine</li>

<li>Tuna</li>

<li>Salmon</li>

</ul>

Ordered lists1. Sardine2. Tuna3. Salmon

<ol><li>Sardine</li><li>Tuna</li><li>Salmon</li></ol>

Page 71: Screen Color and Typography

List tags • The basic list is declared with <ol>…</ol> or <ul>…

</ul> tags• Items within list declared with <li>…</li>• Ordered list attributes

– type numbering style (1, a, A, i, I)

– start sets the initial list number

• Unordered list attribute– type point style (disc, square, circle)

• Lists can be nested easily

Page 72: Screen Color and Typography

Example<body bgcolor="#FFFFFF">

<h2 align="center"><i><font color="#000080">Plenty More Fish in the Sea</font></i></h2>

<hr>

<p>andnbsp;</p>

<p>There are a number of steps we recommend you take in order to prepare yourself

to find your perfect match.</p>

<ol>

<li>Take a good long look at yourself in the mirror</li>

<li>Ask yourself who would love a face like that</li>

<li>Admit you're lonely</li>

<li>Admit you need help</li>

<li>Give yourself a good scrub - the importance of personal hygene cannot be overestimated</li>

<li>Contact us</li>

<li>Sit back, relax and wait for <b>true love</b></li>

</ol>

<hr align="center" width="50%">

Page 73: Screen Color and Typography

Example

Page 74: Screen Color and Typography

Definition lists• For dictionary style definitions

– <dl>…</dl> starts and ends the list– <dt>…</dt> adds a term to the list– <dd>…</dd> provides a definition for a term

• Terms not indented, definitions indented

<dl>

<dt>Fish</dt>

<dd>vertebrate cold-blooded animal living in water</dd>

<dt>Fish Meal</dt>

<dd>ground dried fish used as fertiliser or feed</dd>

</dl>

Page 75: Screen Color and Typography

Example