1 Formatting: Is What You See What You Get? Gylphs and Fonts Document-Wide Style Changes Formatting List Items Formatting Different Tags Simultaneously.

Slides:



Advertisements
Similar presentations
HTML popo.
Advertisements

CSS Cascading Style Sheets. Objectives Using Inline Styles Working with Selectors Using Embedded Styles Using an External Style Sheet Applying a Style.
Computer Applications II.  A Style Sheet is a web page development tool that allows the developer to make global changes to a web page (or web site)
INTRODUCTION TO HYPERTEXT MARKUP LANGUAGE 1. Outline  Introduction  Markup Languages  Editing HTML  Common Tags  Headers  Text Styling  Linking.
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.
Stylin’ with CSS. 2 Topics What is CSS? Why CSS? CSS Examples.
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.
Week 7 Web Typography. 2 Understanding Type Design Principles.
1 CSS Styling with Fonts and Colors. 2 CSS Cascading Style Sheets and fonts CSS provides Style or Presentation options for our html pages CSS properties.
Cascading Style Sheets (CSS) Why do we need them? Separate structure from browser presentation There are many HTML presentation attributes –We want to.
Web-based Application Development Lecture 5 January 24, 2006 Anita Raja.
Using Cascading Style Sheets CSS Structure. Goals Understand how contextual, class and ID selectors work Understand how contextual, class and ID selectors.
1 Formatting: Is What You See What You Get? Inline Styles Physical Styles Logical Styles Special Characters Turning of Formatting Deprecated Font-Handling.
Cascading Style Sheets1. 2 n Style sheets are a means of controlling the way HTML tags are formatted n IE introduced style sheets in IE 3.0 release n.
Cascading Style Sheet (CSS) Instructor: Dr. Fang (Daisy) Tang
© 2007 D. J. Foreman CSS-1 Cascading Style Sheets Styles.
3.1 Cascading Style Sheets. Motto Fashions fade, style is eternal. —Yves Saint Laurent.
CSS The Definitive Guide Chapter 5.  You will understand why setting font properties will be among the most common uses of style sheets.  Font family.
Stylin’ with CSS. 2 Topics What is CSS? Why CSS? CSS Examples.
Formatting Text (Plus More Selectors) Learning Web Design: Chapter 12.
Web Design – Sec 4-6 and 4-7 Part or all of this lesson was adapted from the University of Washington’s “Web Design & Development I” Course materials.
XHTML and CSS Introduction to XHTML and CSS Bharti Patel 1 phones off (please)
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,
Using Cascading Style Sheets. Introduction to Styles and Properties  Cascading Style Sheets (CSS) are a standard set by the World Wide Web Consortium.
INTRODUCTION TO WEB DEVELOPMENT AND HTML Lecture 09: Cascade Style Sheets - Spring 2011.
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.
Cascading Style Sheets " Provide means to control and change presentation of HTML documents. " Allow the user to impose a standard style. " Three levels.
1 What is CSS?  CSS stands for Cascading Style Sheets  Styles define how to display HTML elements  Styles are normally stored in Style Sheets  Styles.
 A style sheet is a single page of formatting instructions that can control the appearance of many HTML pages at once.  If style sheets accomplished.
Using Cascading Style Sheet As you create more web pages, you may wish to impose a consistent look for all of your web pages or for group of related pages.
Introduction to Programming the WWW I CMSC Winter 2003 Lecture 3.
Just A Few More Fun Objectives 1 Having Some Fun With Java Script 2 Using Style Sheets.
Cascading Style Sheets Orientation Learning Web Design: Chapter 11.
Cascading Style Sheets Chapter Four. What are they? A set of style rules that tell the web browser how to present a web page or document. Cascading Style.
Tutorial 5 Formatting with CSS. Objectives Session 5.1 – Evaluate why CSS styles are used – Determine where to write styles – Create an element selector.
Tutorial #3 Cascading Style Sheets. Tutorial #2 Review - Anchors Links to Site DMACC Internal Links Go to Top Mail To me Local.
Introduction to CSS CSS Fonts - Fort Collins, CO Copyright © XTR Systems, LLC Cascading Style Sheets - Font Control Instructor: Joseph DiVerdi, Ph.D.,
Stylin’ with CSS Monday October 8 th and Tuesday October 9 th.
Files you will need ... Black Goose Bistro Summer Menu
Fonts The following CSS properties will be described: 1.Font-family 2.Font-style 3.Font-variant 4.Font-weight 5.Font-size 6.Font.
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.
3. Cascading Style Sheets (CSS) M. Udin Harun Al Rasyid, S.Kom, Ph.D Lab Jaringan Komputer.
HTML HyperText Markup Language ©Richard L. Goldman July 15, 2003.
HTML Basics Computers. What is an HTML file? *HTML is a format that tells a computer how to display a web page. The documents themselves are plain text.
Cascading Style Sheets CSS.  Standard defined by the W3C  CSS1 (released 1996) 50 properties  CSS2 (released 1998) 150 properties (positioning)  CSS3.
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.
XHTML Formatting font with a style declaration. Formatting Font HTML uses the font tag to change size and family of font But… the font tag is being deprecated.
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,
Formatting Text with HTML. Objectives: Students will be able to: Define the structure of the document with block elements Format numbered, bulleted, and.
Developing Web Applications with HTML and CSS “Selectors and Properties”
CSS Fonts. The Font properties allow you to change the font family, boldness, size, and the style of a text.
CSS Syntax. Syntax The CSS syntax is made up of three parts: a selector, a property and a value: selector {property: value}
Basic Webpage Design Formatting tags.
Class & ID Selectors, Font and List Properties. Id Selectors  # followed by Id-name (without space)  Can be used once on a page  Examples: #p1 { color:
Basic Webpage Design Cascading Style Sheet (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.
CSS Details Cascading Style Sheets. Lesson Overview  In this lesson, you will learn:  To use CSS properties for fonts  Evaluate whether to use pts,
CSS DHS Web Design. Location Between the & Start with – End with –
Internet & World Wide Web How to Program, 5/e 1. 2.
Lesson 5. XHTML Tags, Attributes and Structure XHTML Basic Structure head and body titles Paragraph headings comments Document Presentation Manipulating.
Cascading Style Sheets
Presentation transcript:

1 Formatting: Is What You See What You Get? Gylphs and Fonts Document-Wide Style Changes Formatting List Items Formatting Different Tags Simultaneously Command Lines Font Changes Inline Styles Physical Styles Logical Styles Special Characters Turning of Formatting Deprecated Font-Handling Techniques Review Questions Exercise

2 Objectives Effectively use font properties in Web page designs. Create document-level style tags Utilize physical and logical HTML elements in Web page design. Establish language rules for quotations Incorporate special character codes into HTML documents Identify the languages associated with the Latin-1 and Unicode character sets. Know how to override text formatting within an HTML document

3 Glyphs and Fonts Every browser recognizes a variety of symbols, letters, and numbers  Glyphs Arabic Numbers: 1, 2, 3... Lowercase letters: a, b, c... Your text is made up of glyphs. Formatting different glyphs  font properties typeface, size, style, weight, etc...

4 Glyphs and Fonts HTML lets you manupulate the followings font-family: serif | sans serif | cursive | fantasy | others font-size: pt | 1-100% | larger | smaller | xx-small through xx-large font-size-adjust: font-stretch: normal | wider | narrower | ultra-condenced through ultra-expanded font-style: normal | italic | oblique font-variant: normal | small-caps font-weight: normal | bold | bolder | lighter |

5 Glyphs and Fonts Each browser ultimately controls the default values; ie.font-size: 3 font-type size effects the number of characters displayed per inch! -The smaller the type size the more words fit on a line- BUT This type size is too small for comfortable reading!... Proportional spacing is a way of naturally fitting letters together so that they only take the requisite amount of space on the line (M, W / i, I). Monospaced font; each letter in a font is given equal space.

6 Document-Wide Style Changes W3C  promote international and handicap sensitive design  style sheets Style sheet is a set of design rules that apply to one ore more HTML documents - Use style sheets to maintain the same design elements Document-level style sheets; formatting rules effect from one to all of elements found within container. External style sheets; independently ASCII files, effect more than one HTML document. Document Style Changes Description: identifies formatting changes to elements that appear in the document’s container Type:Container Attributes: dir, lang, media, title, and type

7 Document-Wide Style Changes The conatiner can be placed only within the element. Place each tag to be defined properties on a separate line Put a left curly brace { after the tag name. List each property name, like font-family or font-weight, followed by a colon (: means a value for that property comes next) Type in the property value. Like sans-serif or bold Place a semicolon to mark the end of the value Close the property list with a right curly brace }, again on a line by itself All of this information could be presented on a single line like this if you don’t care about readibility and maintainability.

8 Document-Wide Style Changes h1 { font-family: sans-serif; font-size: 30 pt; font-weight: bold; } OR h1 {font-family: sans-serif;font-size: 30 pt;font-weight: bold;}

9 Document-Wide Style Changes type The style tag’s type attribute is needed to identify the style sheet rules used to create document-level style sheet. Formatting List Items ol li {list-style-type: upper-alpha;}  A, B, C, etc. ol li li li  third level list items a,b.. { Color:#0000FF; list-style-type: lower-alpha; }

10 Document-Wide Style Changes Formatting Different Tags Simultaneously More than one tag can be assigned new properties at the same time; h1, h2, h3, h4, h5, h6 { Color:# } h1 { font-size: 28 pt; text-align: center; font-family: sans-serif; }

11 Document-Wide Style Changes Document Level Style Sheets <!-- style sheet commands --> WHY in Comment Tags? This is done to prevent older browsers from accidentally displaying format changes as text!

12 Font Changes KISS (Keep It Simple, Sweetie) 3 different type face  Headings, Text, Specific Words P {font-family: “Times New Roman”} 5 generic family names: Cursive Fantasy Monospace Sans-serif Serif Font-family: serif | sans-serif | cursive | fantasy | monospace | [Arial, Courier,...]

13 Font Changes font-size: pt | 1-100% | larger | smaller | xx-small through xx-large xx-small xx-small x-small p {font-size:larger;} small p {font-size: 40%;} medium large x-large xx-large font-style: normal | italic | oblique normal P {font-style: italic;}

14 Font Changes font-weight: normal | bold| bolder | lighter | weight = 700 font-variant: normal | small-caps h4 {font-variant: small-caps;} font-stretch: normal | wider | narrower | ultra- condensed through ultra-expanded Ultra-condenced, extra-condensed, semi-condenced, normal, semi- expanded, expanded, extra-expanded, ultra-expanded h2 {font-stretch: ultra-expanded;}

15 Inline Styles Physical styles: describe the way the text is to look in a browser bold Darker typeface italic Slanted typeface superscript Halfline above text bottom subscript Halfline below text bottom teletype Monospaced typeface computer code Monospaced typeface keyboard Monospaced typeface big text Default is 3; 1-7 small text Default is 3; 1-7 underline text Line drawn under text strikethrough Line drawn through text strikethrough Line drawn through text

16 Inline Styles Logical styles: not only changes appearence of text, but also explain why the text was set off from the body of the page. abbreviation WWW, URL, or W3C acronym NASA, BASIC, or FBI ( ) address Atatürk Bulvarı No:167 long quote Longer than 40 words (cite) citation 1937 by Robert Frost emphasized text Enroll by june 30th deleted text Removed from page (cite, datetime) inserted text Added to page (cite, datetime) quote Less than 40 words (cite) sample output Printer output strongly emphasized text Warning!... variable values Last_name = ikinci definition Large black object

17 Special Characters Certain characters--such as the brackets ( ) and the ampersand (&)--have a special meaning within the HTML scripting

18 Some Examples

19

20

21 Turning Off Formatting preformatted text Description: identifies preformatted text that the browser is instructed not to alter. Attributes:.....width

22 Deprecated Font-Handling Techniques Font of Text Description: changes the color, typeface, or size of font. Attributes: color, face, size....

23