Categories

stylesheet

Дарья Миронова September 7, 2015
No votes yet.
Please wait...

Style sheet is a file or form that defines the layout of a document. When you fill in a style sheet, you specify such parameters as the page size, margins, and fonts. Style sheets are useful because you can use the same style sheet for many documents.

Typically, a style sheet is specified at the beginning of an electronic document, either by embedding it or linking to it. This style sheet applies to the entire document. As necessary, specific elements of the overall style sheet can be overridden by special coding that applies to a given section of the document.

A term extended from print publishing to online media, a style sheet is a definition of a document’s appearance in terms of such elements as:

  1. The default typeface, size, and color for headings and body text;
  2. How front matter (preface, figure list, title page, and so forth) should look;
  3. How all or individual sections should be laid out in terms of space (for example, two newspaper columns, one column with headings having hanging heads, and so forth);
  4. Line spacing, margin widths on all sides, spacing between headings, and so forth;
  5. How many heading levels should be included in any automatically generated Table of Contents;
  6. Any boilerplate content that is to be included on certain pages (for example, copyright statements).

Style sheets make it easy to specify the amount of white space between text lines, the amount lines are indented, the colors used for the text and the backgrounds, the font size and style, and a host of other details.

For example, the following short CSS style sheet (stored in the file "special.css"), sets the text color of a paragraph to green and surrounds it with a solid red border:

p.special {
  color : green;
  border: 1px solid red;
  }

Authors may link this style sheet to their source HTML document with the LINK element:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd""
  "http://www.w3.org/TR/html4/strict.dtd">
  <html>
  <head>
  <link href="special.css" rel="stylesheet" type="text/css">
  </head>
  <body>
  <p class="special">This paragraph should have special green text.
  </body>
Bookmark the permalink.

Submit a ticket

If you are still unable to find a sufficient tutorial regarding your issue please use the following link to submit a request to our technical support team. We'll provide you with our help and assistance within next 24 hours: Submit a ticket

Comments are closed.