CSS The Definitive Guide Chapter 6.  Text is the content, and fonts are used to display that content. By using text properties you can affect the position.

Slides:



Advertisements
Similar presentations
CSS Cascading Style Sheets. What is CSS? CSS stands for Cascading Style Sheets (the page—or sheet—helps you create a style that will cascade across all.
Advertisements

Web Engineering 1 Ishaq Khan Shinwari MCS City University Peshawar.
Lecture 5 Use Cases and Style Sheets
Cascading Style Sheets. CSS stands for Cascading Style Sheets and is a simple styling language which allows attaching style to HTML elements. CSS is a.
© 2004, Robert K. Moniot Chapter 6 CSS : Cascading Style Sheets.
Building a Website: Cascading Style Sheets (CSS) Fall 2013.
Chapter 8 Creating Style Sheets.
Session Objectives Setting the font family Setting the font size Working with Web fonts Setting font faces and sizes Setting font and text appearances.
Tutorial 2: Formatting Text. Objectives Session 2.1 – Learn the functions of the Common toolbar – Change the size of text – Discern which fonts to use.
文字 CSS 樣式. 文字的屬性 text-decoration none | underline | overline | line-through | blink text-transform none | capitalize | uppercase | lowercase line-height.
Tutorial 4 Formatting Text. XP New Perspectives on Blended HTML, XHTML, and CSS2 Objectives Create a spread heading Indent text Change the line spacing.
Week 7 Web Typography. 2 Understanding Type Design Principles.
Web-based Application Development Lecture 4 January 19, 2005 Anita Raja.
INTRODUCTORY Tutorial 3 Using CSS to Format Multiple Pages.
1 by Mary Anne Poatsy, Keith Mulbery, Lynn Hogan, Amy Rutledge, Cyndi Krebs, Eric Cameron, Rebecca Lawson Chapter 2 Document Presentation.
Text Properties, Line Box, CSS. Text Properties Properties related to the display of text. Text-align : left, right, center I like FSU!
Chapter Concepts Discuss Fonts Understand Fonts
Using Cascading Style Sheets CSS Structure. Goals Understand how contextual, class and ID selectors work Understand how contextual, class and ID selectors.
+ Text & Font Styles Unit 3 Lesson Different Font Categories Sans Serif – block style fonts Example - Rockwell Easy to read and good to use when.
Formatting Text (Plus More Selectors) Learning Web Design: Chapter 12.
Computer Applications I Unit 3 Study Guide 1 Introduction to Formatting, Alignment and Page Setup.
ULI101: XHTML Basics (Part III) Introduction to XHTML / Continued … Block-Level vs. Inline Elements (tags) Manipulating Text,  , Text Characteristics,,,,,,,,,,,,,,,
Using Cascading Style Sheets. Introduction to Styles and Properties  Cascading Style Sheets (CSS) are a standard set by the World Wide Web Consortium.
Chapter 7 Web Typography Principles of Web Design, 4 th Edition.
Principles of Web Design 6 th Edition Chapter 5 – Web Typography.
Cascading Style Sheet (CSS)
Tutorial #3 Cascading Style Sheets. Review: Last Class Image sizing Pathnames Project Default Path Relative Path Absolute Path Blackboard Homework Submission.
WORKING WITH CASCADING
New Perspectives on XML, 2nd Edition Tutorial 5 1 TUTORIAL 5 WORKING WITH CASCADING STYLE SHEETS.
XP New Perspectives on XML Tutorial 5 1 TUTORIAL 5 CSS Tutorial – Carey ISBN
INTRODUCTION TO HTML5 Styling Text. Change the Font Size  You can use the font-size property to change the font size for a document’s text.  Instead.
1 eVenzia Technologies Learning HTML, XHTML & CSS Chapter 2.
(CSS) More Details Instructor: Mr. Ahmed Al Astal ITGD4104 Department Requirement for senior student University of Palestine Faculty of IT.
Tutorial #3 Cascading Style Sheets. Tutorial #2 Review - Anchors Links to Site DMACC Internal Links Go to Top Mail To me Local.
INTRODUCTION TO TYPOGRAPHY WHAT IS TYPOGRAPHY? Typography: The study of all elements of type including the shape, size and spacing of the characters.
Introduction to CSS. What is CSS?  Cascading Style Sheets  Used for styling HTML  Also important in javascript and jquery for selectors  External.
Agenda Block-Level vs. Inline Elements (tags) Manipulating Text,  , Text Characteristics,,,,,,,,,,,,,,, Font Attributes: size, color, face Horizontal.
Basics of Web Design Chapter 6 More CSS Basics Key Concepts.
Cascading Style Sheets Robin Burke ECT 270. Outline Midterm The Layout Debate CSS properties Fonts Alignment Color CSS selection selectors pseudo-classes.
INTRODUCTORY Tutorial 3 Using CSS to Format Multiple Pages.
Cascading Style Sheets Eugenia Fernandez IUPUI. CSS Purpose CSS allow you to specify the style in which your XML elements are displayed. CSS were originally.
1 Web Development CSS (Cascading Style Sheet). 2 1.Setting rules for multiple elements To decrease the amount of typing for setting rules for multiple.
1 Working with Cascading Style Sheet (CSS). 2 Cascading Style Sheets (CSS)  a style defines the appearance of a document element. o E.g., font size,
CSS properties Basharat Mahmood, Department of Computer Science, CIIT, Islamabad, Pakistan 1.
Web Design (14) CSS Formatting Text. Formatting Text In Brackets, go to your ‘externalcss’ website and find the ‘formattingtext’ page. Use the ‘main’
CSS Text Text properties allow you to control the appearance of text. It is possible to change the color of a text, increase or decrease the space between.
CSU - DCE Introduction to CSS CSS Text - Fort Collins, CO Copyright © XTR Systems, LLC Cascading Style Sheets - Text Control Instructor: Joseph.
Tutorial 3 Designing a Web Page with CSS
CSCE Chapter 3 (Cascading Style Sheets) CSCE General Applications Programming Benito Mendoza 1 By Benito Mendoza Department of Computer.
Chapter 11 & 12 CSS Style Sheets: Intro. Why CSS? Separate presentation from content – more accessible Less work – can change appearance of whole site.
Blended HTML and CSS Fundamentals 3 rd EDITION Tutorial 3 Introducing Cascading Style Sheets.
Internet & World Wide Web How to Program, 5/e Copyright © Pearson, Inc All Rights Reserved.
1 CS428 Web Engineering Lecture 07 Font, Text & Background (CSS - II)
Formatting Text with HTML and CSS. Summary block-level elements. Character-level elements Logical and physical style Special elements: hr,address, quotation.
CONFIGURING COLOR AND TEXT WITH CSS Chapter 3. Cascading Style Sheets (CSS) Used to configure text, color, and page layout. Launched in 1996 Developed.
CS3220 Web and Internet Programming CSS Basics
Lesson ¾ Study Guide.
Using Cascading Style Sheets Module B: CSS Structure
Text Size and typeface of text Bold, italics, capitals, underlines
Cascading Style Sheets (Formatting)
IS333: MULTI-TIER APPLICATION DEVELOPMENT
TYPEFACE TERMINOLOGY SERIF SANS-SERIF MONOSPACE Explain: names for different types of typeface (point out differences) Click: serif Click: sans-serif.
CSS Style Sheets: Intro
Cascading Style Sheets Color and Font Properties
Cascading Style Sheets
Web Development & Design Foundations with H T M L 5
CS3220 Web and Internet Programming CSS Basics
CS3220 Web and Internet Programming CSS Basics
Lesson 5 Topic B – Basic Text & Fonts
Session IV Chapter 15 - How Work with Fonts and Printing
Presentation transcript:

CSS The Definitive Guide Chapter 6

 Text is the content, and fonts are used to display that content. By using text properties you can affect the position of text in relation to the rest of the line, superscript it, underline it and change the capitalization!

 Fonts are the different kinds of typefaces. Each font is a set of letters, numbers, and symbols with a unique visual appearance. All fonts belong to large collections, which describe their general look, such as serif, sans-serif, or monospace. Font collections are made up of families, such as Times and Helvetica. A font family in turn can be broken down into font faces, which are variations on the basic family, such as Times Roman, Times Bold, Helvetica Condensed, Bodoni Italic, and so on.

 Text simply describes a block of type, like this sentence or the heading of a chapter, regardless of the font in which it is set.

Indenting the first line of a paragraph on a web page is one of the most sought-after text formatting effects. P {text-indent: 3em;}

The opposite effect. The first line hangs out from the paragraph. Depends on the negative value as to how much. Indents apply only to the first line of an element.

Text-align Effects how the lines of text in an element are Aligned with respect to one another. Values = left, center, right, justify, inherit

Line-height A way to increase (or decrease) the vertical space between lines of text. Line-height controls the leading, which is the extra space between lines of text above and beyond the font’s size.

Every element in a line of text generates a content area, which is determined by the size of the font.

Vertical-align Applies only to inline elements and replaced elements such as images and form inputs. Not an inherited property Values: baseline, sub, super, top, text-top, middle, bottom, text-bottom,,

 Accepts a positive or negative length  Used to modify inter-word spacing  The default value of normal is the same as setting a value to zero (0) This length is added to the standard space between words.

 Modifies the space between characters or letters.  Default value is 0  Any length value you enter will increase or decrease the space between letters by that amount.

 Can increase the emphasis and effect of text you want to emphasize.

 The value of word-spacing may be influenced by the value of the property text- align.

 uppercase |lowercase ~ just as their name in implies and to all characters.  capitalization ~ Capitalizes on the first letter to each word.  none ~ default and leaves text alone  Different user agents have different ways of deciding where words begin and which letters are capitalized.

 None | underline | overline | line-through | blink | inherit  The value of none turns off any decoration  You can combine decorations in a single rule

 Text-decoration is not inherited  There is no way to turn off no way to turn off underlining, overlining or line-through generated by a parent element.

 At this time not all web browsers support text-shadows.  Obvious default is not to have a drop shadow for the text.  First two lengths determine offset distance of the shadow from the text and the third length defines the “blur radius”

Let’s look at some examples.

Do you remember that XHTML ignored whitespace between words and lines of text when writing code? It collapses any white space down to a single line.  Affects the user agent’s handling of space, newline, and tab characters within the document source.  Using this property you can affect how a browser treats the whitespace between words and lines of text.

 By being explicit you can set the default behavior with the following declaration: P {white-space: normal;}

 Setting the white-space to pre ~ whitespace is not ignored. p {white-space: pre;} The browser will pay attention to extra spaces and even carriage returns.

 Nowrap is the opposite value of the pre value  Prevents text from wrapping within an element except wherever you use a br element.

 You can use the whitespace to replace nowrap attribute on tables cells. td {white-space: nowrap;} The contents of this cell are not wrapped. neither are the contents for this cell. <

 The effect of these values is to allow authors to better control whitespace handling.  Pre-wrap and pre-line are opposites  Pre-wrap has whites spaces preserved where as pre-line whites spaces collapse and honors new lines.

 English reads from left to right, many languages read from right to left.  Values: ltr | rtl | inherit  The direction property affects the writing directions of text in block level elements.

 Create a Resource Page  A resource page should have links with definitions of resources you have used thus far on your individual web sites.  Please use text properties that were discussed in tonight.