Design and Layout:Visual Design:Colors
From KDE-HIG_Wiki
How to Use the KDE System Color Scheme
Background colors: Applications must only use background colors from the system color scheme by default. The foreground color roles must never be used for painting a background. This would lead to problems for partially sighted users.
Foreground colors: Text, lines and frames must be drawn with a foreground color that fits the background color.
If there is a real need to use more foreground colors than those defined in the system color scheme, then applications can use additional colors as long as the contrast to the currently used background color is big enough. kdelibs will provide a function for testing the contrast and for generating additional colors that fit the color scheme.
It must be possible to deactivate the use of these additional colors in the application settings to make it easier for color-blind users to distinguish between the predefined system colors.
Valid combinations of foreground and background colors: The foreground and background color should come from the same color pair in the system color scheme. Other combinations must not be used, with the following exceptions:
Numbered colors: The color scheme will provide additional numbered foreground and background colors. They have particular purposes assigned, but they can also be used as general-purpose colors.
You may combine the numbered colors with each other and with the following color pairs: standard, window, button and tool tip. It is still necessary to follow the rules for foreground and background colors.
Selection colors: Only the standard selection color pair must be used for selected text by default. They must not be mixed with other color pairs.
Focus colors: The focus colors can be used to highlight the item that currently accepts keyboard focus. They can also be used for mouse-over effects. The normal focus colors can be combined with all color pairs that are also valid for the numbered colors. The selection focus colors can be combined with the selection colors.
Note that color must never be the only way to show information. The information must also appear in text or icon form.
Accessibility Notes
Colorblind users perceive colors differently and are losing access to information that is only shown via color. The same will be true for blind users once KDE4 supports screen-readers.
Default Color Settings
Guidelines
- Don't use hard-coded color values. Your application may provide settings for user-defined colors, but colors must default to the current system color theme.
- If your application offers its own color scheme provide a scheme that uses global KDE colors. Make this scheme the default.
Accessibility Notes
The high contrast color schemes shipped with KDE do not work properly because of hard-coded colors, making KDE partly useless for users that cannot read text on a bright background.
Implementation Suggestions
