reading_notes

Read: 08 - More CSS Layout:

Positioning elements

Building blocks:

CSS treats each HTML element as if it is in its own box. This box will either be a block-level box or an inline box. Block-level boxes start on a new line and act as the main building blocks of any layout, while inline boxes flow between surrounding text.

Controlling the Position of Elements:

Control Position of element

Creating Multi-Column Layouts with Floats:

  1. width: sets the width of the columns.
  2. float: positions the columns next to each other.
  3. margin: creates a gabs between columns.

Screen Sizes:

Different visitors to your site will have different sized screens that show different amounts of information, so your design needs to be able to work on a range of different sized screens.

Screen Resolution:

Resolution refers to the number of dots a screen shows per inch. *the higher the resolution, the smaller the text appears.

Page Sizes:

web designers often create pages of around 960-1000 pixels wide. *many designs let the user know that site is about 570- 600 pixels top.

Layout example

Fixed Width Layout:

Fixed Width Layout

Liquid Layouts:

Advantages:

Layout Grids:

Grids set consistent proportions and spaces between items which helps to create a professional looking design.

Grids Example

CSS Frameworks:

providing the code for common tasks, such as creating layout grids, styling forms, creating printer-friendly versions of pages and so on.

Advantages:

Multiple Style Sheets @import:

There are two ways to add multiple style sheets to a page:

  1. Your HTML page can link to one style sheet and that stylesheet can use the @import rule to import other style sheets. 2 In HTML you can use a separate <link> element for each style sheet.

Area Grid Layout