IN THIS CHAPTER
Changing the Cursor
User Interface Colors
User Interface Fonts
In Part III of this book you learned how to use CSS to style and format almost every part of an HTML document. However, there are several additional, user agent-related elements you can affect with CSS. This chapter shows you how to use styles on user interface elements—the mouse pointer, system colors, and system fonts.
cursor property enables you to specify what cursor type should be displayed when the cursor is over a specific element. This property is used like any other property, with a familiar format:
cursor property supports the values listed in Table 39.1.
uri value takes the following familiar form:
This value is unique in that it supports several values and can be followed by a default value if none of the
uri resources can be found or used. For example, the following property definition defines two external pointer files that should be used, and a fallback default of
crosshair if those two resources cannot be used for some reason:
cursor: url("angle.cur"), url("simple.cur"), crosshair;
Many general graphic editing programs and several specific programs can be used to create custom cursors. Try searching Google for "create cursor file."
Table 39.1. Values for the Cursor Property
The user agent displays an appropriate cursor for the current context.
The cursor is ...