von Thomas Salvador.
Farben werden in HTML entweder mit ihrem Namen oder mit ihrem Wert beschrieben.
Netscape führte seinerzeit die websicheren Farben ein. Neben diesen Farbwerten, die einem bestimmten Schema folgen, definierte man noch 120 Werte und ordnete ihnen Namen zu.
Hintergrundfarbe lightyellow | Schriftfarbwert #f5fffa | |||||
Detail | : | Hintergrund lightyellow | Detail | : | Schrift #f5fffa | |
Farbe | : | lightyellow | Farbwert | : | #f5fffa | |
Farbwert | : | #ffffe0 | Farbe | : | mintcream | |
HTML | : | lightyellow | HTML | : | #f5fffa | |
HTML (Wert) | : | #ffffe0 | HTML (Wert) | : | #f5fffa | |
CSS | : | lightyellow | CSS | : | #f5fffa | |
CSS (Wert) | : | #ffffe0 | CSS (Wert) | : | #f5fffa | |
CSS (kürzest) | : | #ffffe0 | CSS (kürzest) | : | #f5fffa | |
CSS (RGB) | : | rgb(255,255,224) | CSS (RGB) | : | rgb(245,255,250) | |
CSS (%RGB) | : | rgb(100%,100%,87%) | CSS (%RGB) | : | rgb(96%,100%,98%) |
Verlauf Hintergrundfarbe lightyellow nach Schriftfarbwert #f5fffa | |||||||
#ffffe0 | #fdffe3 | #fcffe7 | #faffeb | #f9ffee | #f7fff2 | #f6fff6 | #f5fffa |
#ffffe0 | #fdffe3 | #fcffe7 | #faffeb | #f9ffee | #f7fff2 | #f6fff6 | #f5fffa |
Kombination von lightyellow und #f5fffa | |||||||
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Suspendisse augue erat, auctor ut ultricies non, facilisis sed neque. Cras id velit ante. Aliquam dapibus, lorem sed bibendum consectetur, ligula enim dignissim ligula, a ultrices dolor augue ultrices magna. Cras vestibulum tristique erat, ac interdum justo cursus in. | #f5fffa eignet sich nicht als Schriftfarbe auf Hintergrund lightyellow, da sowohl Helligkeit als auch die Farben zu ähnlich sind. Die Ähnlichkeit der Farben #f5fffa und lightyellow ergibt sich zu 95.22%. Die Lesbarkeit dieser Kombination von Farben liegt damit bei 4.78%. |
Hintergrundfarbe lightyellow | Schriftfarbwert #f5fffa | ||||||
Verlauf nach Weiß | Verlauf nach Schwarz | Verlauf nach Weiß | Verlauf nach Schwarz | ||||
#ffffe0 | #ffffe0 | #ffffe0 | #ffffe0 | #f5fffa | #f5fffa | #f5fffa | #f5fffa |
#ffffe4 | #ffffe4 | #dadac0 | #dadac0 | #f6fffa | #f6fffa | #d2dad6 | #d2dad6 |
#ffffe8 | #ffffe8 | #b6b6a0 | #b6b6a0 | #f7fffb | #f7fffb | #afb6b2 | #afb6b2 |
#ffffed | #ffffed | #919180 | #919180 | #f9fffc | #f9fffc | #8c918e | #8c918e |
#fffff1 | #fffff1 | #6d6d60 | #6d6d60 | #fafffc | #fafffc | #696d6b | #696d6b |
#fffff6 | #fffff6 | #484840 | #484840 | #fcfffd | #fcfffd | #464847 | #464847 |
#fffffa | #fffffa | #242420 | #242420 | #fdfffe | #fdfffe | #232423 | #232423 |
#ffffff | #ffffff | #000000 | #000000 | #ffffff | #ffffff | #000000 | #000000 |
Die Rahmenfarbe soll sich von Farbe lightyellow auf Farbwert #f5fffa ändern, wenn man mit der Maus auf <q> zeigt. Wir bereiten zunächst eine Darstellung von <q> in Farbe lightyellow vor.
In diesem Beispiel umranden wir <q> mit einem 4 Pixel dicken, einfallenden Rahmen in Farbe lightyellow.
<style type="text/css"><!-- q { border:4px inset lightyellow; } //--> </style>Jetzt fordern wir, dass bei Berührung mit der Maus die Rahmenfarbe auf #f5fffa gesetzt wird.
<style type="text/css"><!-- q:hover { border-color:#f5fffa; } //--> </style>
Der hier gezeigte Befehl q ist in der HTML Referenz unter <q> zusammengestellt.