XML technologies / CSS / Advanced websites with CSS / CSS property reference / list-style-position
(Excerpt from “CSS − Advanced websites with Cascading Stylesheets” by Rachel Andrew & Dan Shafer)
The property list-style-position positions list markers either outside or inside the list contents. The following figure illustrates both options.
Figure: Positioning list markers with list-style-position.
Inherited: Yes
See also: list-style
Values
inside or outside
Default value: outside
Compatibility
CSS version: 1
Works in all CSS-capable browsers except Netscape 4. Internet Explorer 4 for Macintosh has display problems with inside.
Example
The following rule places list markers for ordered and unordered lists of the class kompakt inside the text block and removes the left indentation automatically applied to lists:
ul.kompakt, ol.kompakt{
list-style-position: inside;
margin-left: 0;
}
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