von Thomas Salvador.
Graustufen gehören zu den unbunten Farben und zeichnen sich dadurch aus, dass ihre Farbwerte für Rot, Grün und Blau gleich sind.
Graustufen enthalten natürlich alle 16 Graustufen und insbesondere die unbunten Grundfarben Schwarz und Weiß.
Um 256 Graustufen in HTML bzw. CSS zu erzeugen, wählen wir Farbwerte rr, gg und bb mit Werten von 0 bis 255 (d.h. hexadezimal 00 bis ff).
Hintergrundfarbwert #9f9f9f | Schriftfarbwert #a6a6a6 | |||||
Detail | : | Hintergrund #9f9f9f | Detail | : | Schrift #a6a6a6 | |
Farbwert | : | #9f9f9f | Farbwert | : | #a6a6a6 | |
Farbe | : | gray159 | Farbe | : | gray166 | |
HTML | : | #9f9f9f | HTML | : | #a6a6a6 | |
HTML (Wert) | : | #9f9f9f | HTML (Wert) | : | #a6a6a6 | |
CSS | : | #9f9f9f | CSS | : | #a6a6a6 | |
CSS (Wert) | : | #9f9f9f | CSS (Wert) | : | #a6a6a6 | |
CSS (kürzest) | : | #9f9f9f | CSS (kürzest) | : | #a6a6a6 | |
CSS (RGB) | : | rgb(159,159,159) | CSS (RGB) | : | rgb(166,166,166) | |
CSS (%RGB) | : | rgb(62%,62%,62%) | CSS (%RGB) | : | rgb(65%,65%,65%) |
Verlauf Hintergrundfarbwert #9f9f9f nach Schriftfarbwert #a6a6a6 | |||||||
#9f9f9f | #a0a0a0 | #a1a1a1 | #a2a2a2 | #a3a3a3 | #a4a4a4 | #a5a5a5 | #a6a6a6 |
#9f9f9f | #a0a0a0 | #a1a1a1 | #a2a2a2 | #a3a3a3 | #a4a4a4 | #a5a5a5 | #a6a6a6 |
Kombination von #9f9f9f und #a6a6a6 | |||||||
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras vestibulum tristique erat, ac interdum justo cursus in. Cras id velit ante. Suspendisse augue erat, auctor ut ultricies non, facilisis sed neque. Aliquam dapibus, lorem sed bibendum consectetur, ligula enim dignissim ligula, a ultrices dolor augue ultrices magna. | Die Ähnlichkeit von #a6a6a6 und #9f9f9f beträgt 94.82%. Die Lesbarkeit dieser Kombination von Farben liegt damit bei 5.18%. Auf Hintergrund #9f9f9f ist #a6a6a6 ungeeignet. Weder der Helligkeitsunterschied noch der Farbunterschied sind gross genug. |
Hintergrundfarbwert #9f9f9f | Schriftfarbwert #a6a6a6 | ||||||
Verlauf nach Weiß | Verlauf nach Schwarz | Verlauf nach Weiß | Verlauf nach Schwarz | ||||
#9f9f9f | #9f9f9f | #9f9f9f | #9f9f9f | #a6a6a6 | #a6a6a6 | #a6a6a6 | #a6a6a6 |
#acacac | #acacac | #888888 | #888888 | #b2b2b2 | #b2b2b2 | #8e8e8e | #8e8e8e |
#bababa | #bababa | #717171 | #717171 | #bfbfbf | #bfbfbf | #767676 | #767676 |
#c8c8c8 | #c8c8c8 | #5a5a5a | #5a5a5a | #cccccc | #cccccc | #5e5e5e | #5e5e5e |
#d5d5d5 | #d5d5d5 | #444444 | #444444 | #d8d8d8 | #d8d8d8 | #474747 | #474747 |
#e3e3e3 | #e3e3e3 | #2d2d2d | #2d2d2d | #e5e5e5 | #e5e5e5 | #2f2f2f | #2f2f2f |
#f1f1f1 | #f1f1f1 | #161616 | #161616 | #f2f2f2 | #f2f2f2 | #171717 | #171717 |
#ffffff | #ffffff | #000000 | #000000 | #ffffff | #ffffff | #000000 | #000000 |
Die Textfarbe soll sich von Farbwert #9f9f9f auf Farbwert #a6a6a6 ändern, wenn man mit der Maus darauf zeigt. Bereiten wir zunächst die Formatierung von <address> in Farbwert #9f9f9f vor.
In diesem Beispiel legen wir Farbwert #9f9f9f als Textfarbe von <address> fest:
<style type="text/css"><!-- address { color:#9f9f9f; } //--> </style>Jetzt stellen wir ein, dass sich bei Mausberührung die Textfarbe zu #a6a6a6 ändert.
<style type="text/css"><!-- address:hover { color:#a6a6a6; } //--> </style>
Weiteres zum Thema address erfahren Sie in Blockorientierte Elemente in HTML. Möglichkeiten vom HTML-Befehl address erfahren Sie in der HTML Referenz unter <address>.