Introducing :CSS Cascading Style Sheets in 5 Lessons.

Slides:



Advertisements
Similar presentations
Web Engineering 1 Ishaq Khan Shinwari MCS City University Peshawar.
Advertisements

Cascading Style Sheets Basics. Why use Cascading Style Sheets? Allows you to set up a series of rules for all pages in a site. The series may be changed.
Part 3 Introduction to CSS. CSS Text Text Styles h1 {color: green} // rgb(0,255,0), #00ff00 h2{letter-spacing: 0.5cm} // 2px h3 {text-align: right} //
Measurement Many CSS properties (values within the declaration) require that you specify a unit of measurement, such as spacing between elements, border.
CSS – CASCADING STYLE SHEETS Making your XHTML webpage look good.
© 2007 D. J. Foreman CSS-1 Cascading Style Sheets Styles.
3.1 Cascading Style Sheets. Motto Fashions fade, style is eternal. —Yves Saint Laurent.
+ 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.
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,
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 CSS. CSS - Structure Declaration block Property: identifies what to change Value: how to change it Selector – example h1{ font-size:
 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.
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.
Cascading Style Sheets Robin Burke ECT 270. Outline Midterm The Layout Debate CSS properties Fonts Alignment Color CSS selection selectors pseudo-classes.
Cascading Style Sheets Objective: Create an external style sheet, embedded style sheet, and an inline style to change the look and feel of a web site.
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.
Cascading Style Sheets Robin Burke ECT 270. Outline CSS properties Fonts Alignment Color CSS selection selectors.
Internet & World Wide Web How to Program, 5/e 1. 2.
WebD Introduction to CSS By Manik Rastogi.
CSS.
Cascading Style Sheets
HTML WITH CSS.
CSS for Styling Text.
CS3220 Web and Internet Programming CSS Basics
Website Development Cascading Style Sheets
The Internet 10/11/11 Fonts and Colors
Cascading Style Sheets™ (CSS)
CSS Rule Selector Declaration Block Value Attribute Name body {
Cascading Style Sheet (CSS)
Chapter 6 Cascading Style Sheets™ (CSS)
Cascading Style Sheets
Chapter 3 Style Sheets: CSS
Using Cascading Style Sheets Module B: CSS Structure
CIIT-Human Computer Interaction-CSC456-Fall-2015-Mr
Cascading Style Sheets (Formatting)
3.5 Property Value Forms - There are 60 different properties in 7 categories: - Fonts - Lists - Alignment of text - Margins - Colors - Backgrounds - Borders.
Cascading Style Sheets
3 Configuring Color & Text With CSS.
Cascading Style Sheet (CSS)
CSS – Properties & Values
CS 174: Server-Side Web Programming February 7 Class Meeting
The Internet 10/13/11 The Box Model
Cascading Style Sheet (CSS)
Cascading Style Sheets
CMPE 280 Web UI Design and Development September 4 Class Meeting
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
CSS Styles Fonts and Colors.
Chapter 7 Web Typography
CMPE 280 Web UI Design and Development February 7 Class Meeting
CS3220 Web and Internet Programming CSS Basics
Lesson 5 Topic B – Basic Text & Fonts
Cascading Style Sheets
Cascading Style Sheets
Stylin’ with CSS.
Cascading Style Sheets
Cascading Style Sheets
Session IV Chapter 15 - How Work with Fonts and Printing
Cascading Style Sheets
Cascading Style Sheets
Cascading Style Sheets™ (CSS)
Cascading Style Sheets
CMPE 280 Web UI Design and Development September 5 Class Meeting
Presentation transcript:

Introducing :CSS Cascading Style Sheets in 5 Lessons

CSS: Mulder’s Stylesheets Tutorial Introduction Font Control Typography and Layout Color and Images Advanced Positioning Mulder’s Stylesheet Tutorials can be found on www.webmonkey.com or google search ‘mulder stylesheets’

Controlling Fonts with CSS

Font Properties font-family font-size font-weight font-style font-variant text-transform text-decoration font

Calling fonts by name font-family Why use multiple fonts? H2 { font-family: helvetica, impact, sans-serif } Why use multiple fonts? Multiple Spellings: List Both Different Font Names: List Both Always end with a generic font serif (probably Times) sans-serif (probably Arial or Helvetica) cursive (probably Comic Sans) fantasy (probably Ransom) monospace (probably Courier)

Font name tips If a font name contains more than one word use quotes BODY { font-family: "gill sans", serif } Use single quotes for inline <P STYLE="font-family: 'gill sans', serif"> Text goes here. </P> If you have multiple declarations try to make font-family the last one.

Controlling text size font-size P { font-size: 16pt } 3 ways to specify font size points, ems, pixels, and other units; keywords; and percentage values.

Points, ems, pixels, & other units Refers to the distance from top of a ‘d’ to bottom of a ‘p’ in any particular font Displays slightly larger on MAC than PC P { font-size: 20pt } Ems Related to the point size of it’s parent B { font-size: 1.5em } Pixels Great from design perspective Sometimes pages wont print properly

Other Units in is inches cm is centimeters mm is millimeters pc is picas ex is x-height

Keywords If you don’t like using units you can use keywords xx-small x-small small medium large x-large xx-large Interpreted differently by each browser P { font-size: large }

Percentage values interpreted as a percentage of parent unit B { font-size: 300% } Block Level vs. Inline elements. How would you create a html using css that displays a series of 20 i’s with each growing 5 pixels larger than the one behind it.

All manner of bold and italics font-style is used for italics H3 { font-style: italic } Options for values are italic, oblique, normal font-weight is used for bold P { font-weight: bold } Bold Normal 100…900 Lighter Bolder

Special Effects font-variant H2 { font-variant: small-caps } Text-transform B { text-transform: uppercase } uppercase lowercase capitalize none

Special Effects text-decoration B { text-decoration: underline } overline line-through (these words) blink None None is a magical value with mystical properties A:link { text-decoration: none } A:active { text-decoration: none } A:visited { text-decoration: none } You can also style that all links have a certain size, color etc…

Lesson 2 excersize A quick word on div vs span Recreate the html page given using embedded styles.