Specification
Contents
Previous
Next
6.5 Colors
Note that in HTML 4.01, it is preferred to use CSS to specify colors, but with the
Transitional DTD, color attributes and the FONT tag are permitted. See
W3C's CSS1 Test Suite
to test common CSS functionality. See
Ian Hickson's Evil Tests
to test CSS etc. more thoroughly.
In the table below, the right two columns should be the same color.
Standard 16 Colors (sequence dates back to EGA graphics, but some names changed) :
Color Name and Value
| Background Color Using Name
| Background Color Using Value
|
Black, #000000
|
|
|
Navy, #000080
|
|
|
Green, #008000
|
|
|
Teal, #008080
|
|
|
Maroon, #800000
|
|
|
Purple, #800080
|
|
|
Olive, #808000
|
|
|
Silver, #C0C0C0
|
|
|
Gray, #808080
|
|
|
Blue, #0000FF
|
|
|
Lime, #00FF00
|
|
|
Aqua, #00FFFF
|
|
|
Red, #FF0000
|
|
|
Fuchsia, #FF00FF
|
|
|
Yellow, #FFFF00
|
|
|
White, #FFFFFF
|
|
|
Extended Colors
Wikipedia Colors
6.6 Lengths
In the tests below, the widths are all set on the column elements, which allows width to
be %MultiLength, which is allowed to be in pixels, percentage, or a relative width.
The two right column should appear about the same. The reference column is an attempt
to produce a table that looks like I think it should for the test column.
Test Description | Test Column | Reference Column
|
---|
Absolute lengths, cell widths totaling the same width as the table
|
|
|
Absolute lengths, cell widths totaling less than the table
|
|
|
Absolute lengths, cell widths totaling more than the table
|
|
|
Percentage widths, cell widths totaling 100%
|
|
|
Percentage widths, cell widths totaling less than 100%
|
|
|
Percentage widths, cell widths totaling more than 100%
|
|
|
Relative widths, simple test
|
|
|
Relative widths, 0* test
|
|
|
Relative widths, * test
|
|
|