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).
Hintergrundfarbe gray186 | Schriftfarbe gray117 | |||||
Detail | : | Hintergrund gray186 | Detail | : | Schrift gray117 | |
Farbe | : | gray186 | Farbe | : | gray117 | |
Farbwert | : | #bababa | Farbwert | : | #757575 | |
HTML | : | gray186 | HTML | : | gray117 | |
HTML (Wert) | : | #bababa | HTML (Wert) | : | #757575 | |
CSS | : | gray186 | CSS | : | gray117 | |
CSS (Wert) | : | #bababa | CSS (Wert) | : | #757575 | |
CSS (kürzest) | : | #bababa | CSS (kürzest) | : | #757575 | |
CSS (RGB) | : | rgb(186,186,186) | CSS (RGB) | : | rgb(117,117,117) | |
CSS (%RGB) | : | rgb(72%,72%,72%) | CSS (%RGB) | : | rgb(45%,45%,45%) |
Verlauf Hintergrundfarbe gray186 nach Schriftfarbe gray117 | |||||||
#bababa | #b0b0b0 | #a6a6a6 | #9c9c9c | #929292 | #888888 | #7e7e7e | #757575 |
#bababa | #b0b0b0 | #a6a6a6 | #9c9c9c | #929292 | #888888 | #7e7e7e | #757575 |
Kombination von gray186 und gray117 | |||||||
Lorem ipsum dolor sit amet, consectetur adipiscing elit. 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. Suspendisse augue erat, auctor ut ultricies non, facilisis sed neque. | Die Ähnlichkeit von gray117 und gray186 beträgt 88.69%. Die Lesbarkeit dieser Farbkombination ergibt sich zu 11.31%. Auf Hintergrund gray186 ist gray117 ungeeignet. Die Unterschiede in der Helligkeit und Farbe sind nicht ausreichend. |
Hintergrundfarbe gray186 | Schriftfarbe gray117 | ||||||
Verlauf nach Weiß | Verlauf nach Schwarz | Verlauf nach Weiß | Verlauf nach Schwarz | ||||
#bababa | #bababa | #bababa | #bababa | #757575 | #757575 | #757575 | #757575 |
#c3c3c3 | #c3c3c3 | #9f9f9f | #9f9f9f | #888888 | #888888 | #646464 | #646464 |
#cdcdcd | #cdcdcd | #848484 | #848484 | #9c9c9c | #9c9c9c | #535353 | #535353 |
#d7d7d7 | #d7d7d7 | #6a6a6a | #6a6a6a | #b0b0b0 | #b0b0b0 | #424242 | #424242 |
#e1e1e1 | #e1e1e1 | #4f4f4f | #4f4f4f | #c3c3c3 | #c3c3c3 | #323232 | #323232 |
#ebebeb | #ebebeb | #353535 | #353535 | #d7d7d7 | #d7d7d7 | #212121 | #212121 |
#f5f5f5 | #f5f5f5 | #1a1a1a | #1a1a1a | #ebebeb | #ebebeb | #101010 | #101010 |
#ffffff | #ffffff | #000000 | #000000 | #ffffff | #ffffff | #000000 | #000000 |
Eine Überschrift der 4. Stufe erzeugen Sie mit HTML-Befehl <h4>. Diese kann man farblich gestalten.
Die Textfarbe soll sich von Farbe gray186 auf Farbe gray117 ändern, wenn man mit der Maus darauf zeigt. Bereiten wir zunächst eine Darstellung von <h4> in Farbe gray186 vor.
Hier ändern wir die Textfarbe von <h4> auf Farbe gray186. Zwar verändern wir die Hintergrundfarbe nicht, setzen jedoch die Schriftart auf monospace.
<style type="text/css"><!-- h4 { font-family:monospace; color:gray186; } //--> </style>Jetzt stellen wir ein, dass bei Hover die Textfarbe auf gray117 geändert wird.
<style type="text/css"><!-- h4: hover { color: gray117; } //--> </style>
Weiteres zum Thema h4 können Sie in Grundlegende Gestaltungselemente in HTML finden. Weiteres zum hier verwendeten Befehl <h4>.
Hier ändern wir die Textfarbe von <option> auf Farbe gray117 und die Hintergrundfarbe von <option> auf Farbe gray186. Als Schriftart setzen wir arial. Die Schriftgröße ändern wir auf 9pt.
<style type="text/css"><!-- option { color: gray117; background-color: gray186; font-size: 9pt; font-family: arial; } //--> </style>
Mehr zu option lesen Sie in Formulare in HTML. Möglichkeiten vom Tag <option>.