XML technologies / CSS / Advanced websites with CSS / CSS property reference / outline-style
(Excerpt from “CSS − Advanced websites with Cascading Stylesheets” by Rachel Andrew & Dan Shafer)
An element’s outline (outline) is similar to its border (border). However, it occupies no space in the CSS box model and therefore does not affect other elements’ positions. Also, outline does not create a rectangular box around the element, but follows the irregular edge of a paragraph. Unlike its border, the outline of a multiline inline element always extends from the start to the end of each line.
The property outline-style describes the outline’s shape.
Inherited: no
See also: border-style
Values
The same constants as for border-style (see the table CSS constants for different border styles), except hidden.
Default value: none
Compatibility
CSS version: 2
Works only in Internet Explorer 5 for Macintosh and Opera 7, and, contrary to the CSS2 specification, only as a rectangular outline.
Example
The following rule creates a grey, medium-width outline of style inset around activated hyperlinks:
a:active {
outline-style: inset;
outline-color: grey;
outline-width: medium;
}
Copyright © 2006 of the German translation, dpunkt.verlag GmbH
You may print the online version for your private use.
Otherwise, this chapter from “CSS − Anspruchsvolle Websites mit Cascading Stylesheets” is subject to the same conditions as the bound edition: the work, including all its parts, is protected by copyright. All rights reserved, including reproduction, translation, microfilming, and storage and processing in electronic systems.
dpunkt.verlag GmbH, Ringstraße 19, 69115 Heidelberg