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 dimgray | Schriftfarbwert #fffaf0 | |||||
Detail | : | Hintergrund dimgray | Detail | : | Schrift #fffaf0 | |
Farbe | : | dimgray | Farbwert | : | #fffaf0 | |
Farbwert | : | #696969 | Farbe | : | floralwhite | |
HTML | : | dimgray | HTML | : | #fffaf0 | |
HTML (Wert) | : | #696969 | HTML (Wert) | : | #fffaf0 | |
CSS | : | dimgray | CSS | : | #fffaf0 | |
CSS (Wert) | : | #696969 | CSS (Wert) | : | #fffaf0 | |
CSS (kürzest) | : | #696969 | CSS (kürzest) | : | #fffaf0 | |
CSS (RGB) | : | rgb(105,105,105) | CSS (RGB) | : | rgb(255,250,240) | |
CSS (%RGB) | : | rgb(41%,41%,41%) | CSS (%RGB) | : | rgb(100%,98%,94%) |
Verlauf Hintergrundfarbe dimgray nach Schriftfarbwert #fffaf0 | |||||||
#696969 | #7e7d7c | #93928f | #a9a7a2 | #bebbb6 | #d4d0c9 | #e9e5dc | #fffaf0 |
#696969 | #7e7d7c | #93928f | #a9a7a2 | #bebbb6 | #d4d0c9 | #e9e5dc | #fffaf0 |
Kombination von dimgray und #fffaf0 | |||||||
Cras vestibulum tristique erat, ac interdum justo cursus in. 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. Suspendisse augue erat, auctor ut ultricies non, facilisis sed neque. | #fffaf0 ist nicht als Schriftfarbe auf Hintergrund dimgray geeignet, weil sich die Farben zu ähnlich sind. Die Ähnlichkeit von #fffaf0 und dimgray ergibt sich zu 74.87%. Die Lesbarkeit dieser Kombination bewerte ich mit 25.13%. |
Hintergrundfarbe dimgray | Schriftfarbwert #fffaf0 | ||||||
Verlauf nach Weiß | Verlauf nach Schwarz | Verlauf nach Weiß | Verlauf nach Schwarz | ||||
#696969 | #696969 | #696969 | #696969 | #fffaf0 | #fffaf0 | #fffaf0 | #fffaf0 |
#7e7e7e | #7e7e7e | #5a5a5a | #5a5a5a | #fffaf2 | #fffaf2 | #dad6cd | #dad6cd |
#939393 | #939393 | #4b4b4b | #4b4b4b | #fffbf4 | #fffbf4 | #b6b2ab | #b6b2ab |
#a9a9a9 | #a9a9a9 | #3c3c3c | #3c3c3c | #fffcf6 | #fffcf6 | #918e89 | #918e89 |
#bebebe | #bebebe | #2d2d2d | #2d2d2d | #fffcf8 | #fffcf8 | #6d6b66 | #6d6b66 |
#d4d4d4 | #d4d4d4 | #1e1e1e | #1e1e1e | #fffdfa | #fffdfa | #484744 | #484744 |
#e9e9e9 | #e9e9e9 | #0f0f0f | #0f0f0f | #fffefc | #fffefc | #242322 | #242322 |
#ffffff | #ffffff | #000000 | #000000 | #ffffff | #ffffff | #000000 | #000000 |
Hier ändern wir die Textfarbe von <del> auf Farbwert #fffaf0. Die Schriftart ändern wir auf monospace und verringern die Schriftgröße auf 84%. Wir unterstreichen den Inhalt von <del> mit Hilfe eines doppelten Rahmens mit 2 Punkte Dicke in Farbe dimgray. In HTML ist das nicht möglich. Daher verwenden wir hier CSS.
<style type="text/css"><!-- del { color: #fffaf0; border-bottom-color: dimgray; border-bottom-width: 2pt; font-family: monospace; border-bottom-style: double; font-size: 84%; } //--> </style>
Die Idee ist, unterschiedliche Formatierungen für Inhalt und Unterstreichung zu haben.
Weiteres zum hier verwendeten Befehl del ist in der HTML Referenz unter <del> ausführlich gezeigt.
Wir ändern bei diesem Beispiel die Textfarbe von <kbd> auf Farbwert #fffaf0 und die Hintergrundfarbe von <kbd> auf Farbe dimgray. Als Schriftart setzen wir monospace. Die Schriftgröße ändern wir auf 13px.
<style type="text/css"><!-- kbd { font-size:13px; color:#fffaf0; background-color:dimgray; font-family:monospace; } //--> </style>
Weiteres zu kbd erfahren Sie in Text in HTML. Weiteres zum HTML-Tag kbd lesen Sie in der HTML Referenz unter <kbd>.