Extensible Firmware Interface Specification
168 12/12/00 Version 1.02
#define EFI_BACKGROUND_BLACK 0x00
#define EFI_BACKGROUND_BLUE 0x10
#define EFI_BACKGROUND_GREEN 0x20
#define EFI_BACKGROUND_CYAN 0x30
#define EFI_BACKGROUND_RED 0x40
#define EFI_BACKGROUND_MAGENTA 0x50
#define EFI_BACKGROUND_BROWN 0x60
#define EFI_BACKGROUND_LIGHTGRAY 0x70
#define EFI_TEXT_ATTR(foreground,background) \
((foreground) | ((background) << 4))
Description
The SetAttribute() function sets the background and foreground colors for the
OutputString() and ClearScreen() functions.
The color mask can be set even when the device is in an invalid text mode.
Devices supporting a different number of text colors are required to emulate the above colors to the
best of the device’s capabilities.
Status Codes Returned
EFI_SUCCESS The requested mode information was returned.
EFI_DEVICE_ERROR The device had an error and could not complete the request.
EFI_UNSUPPORTED The attribute requested is not defined by this specification.