HTML and CSS Reference
In-Depth Information
<option value="lighter">lighter</option>
Generic font faces
Because we cannot be sure which font will be available in the browser at any time, we
have limited the font face choices in Text Arranger to those that are defined as “generic”
in the CSS specification: serif , sans-serif , cursive , fantasy , and monospace .
Here is the markup we used to create the font face <select> box in HTML:
<select id="textFont">
<option value="serif">serif</option>
<option value="sans-serif">sans-serif</option>
<option value="cursive">cursive</option>
<option value="fantasy">fantasy</option>
<option value="monospace">monospace</option>
Font size and HTML5 range control
To specify the size of the font, we have implemented the new HTML5 range form
control. range is an <input> type that creates a slider on the HTML page to limit the
numerical input to that specified in the range. A range is created by specifying range as
the type of a form input control. range has four properties that can be set:
The minimum value in the range
The maximum value in the range
The number of units to step when the range slider is moved
The default value of the range
Here is the markup we used to specify the range in the Text Arranger HTML:
<input type="range" id="textSize"
If the browser does not support this range control, it will be rendered as a text box.
At the time of this writing, range did not render in Firefox.
Search WWH ::

Custom Search