From 8a40612b2ceba33194d26dd7d51a12f68f716832 Mon Sep 17 00:00:00 2001 From: Vladimir 'phcoder' Serbinenko Date: Tue, 15 Dec 2009 19:57:23 +0100 Subject: [PATCH] fix ofconsole palette --- term/ieee1275/ofconsole.c | 29 +++++++++++++++++++---------- 1 file changed, 19 insertions(+), 10 deletions(-) diff --git a/term/ieee1275/ofconsole.c b/term/ieee1275/ofconsole.c index c61e16eb7..4464ed13f 100644 --- a/term/ieee1275/ofconsole.c +++ b/term/ieee1275/ofconsole.c @@ -43,17 +43,26 @@ struct color int blue; }; -#define MAX 0xff -static struct color colors[8] = +static struct color colors[16] = { - { 0, 0, 0}, - { MAX, 0, 0}, - { 0, MAX, 0}, - { MAX, MAX, 0}, - { 0, 0, MAX}, - { MAX, 0, MAX}, - { 0, MAX, MAX}, - { MAX, MAX, MAX} + // {R, G, B} + {0x00, 0x00, 0x00}, + {0x00, 0x00, 0xA8}, // 1 = blue + {0x00, 0xA8, 0x00}, // 2 = green + {0x00, 0xA8, 0xA8}, // 3 = cyan + {0xA8, 0x00, 0x00}, // 4 = red + {0xA8, 0x00, 0xA8}, // 5 = magenta + {0xA8, 0x54, 0x00}, // 6 = brown + {0xA8, 0xA8, 0xA8}, // 7 = light gray + + {0x54, 0x54, 0x54}, // 8 = dark gray + {0x54, 0x54, 0xFE}, // 9 = bright blue + {0x54, 0xFE, 0x54}, // 10 = bright green + {0x54, 0xFE, 0xFE}, // 11 = bright cyan + {0xFE, 0x54, 0x54}, // 12 = bright red + {0xFE, 0x54, 0xFE}, // 13 = bright magenta + {0xFE, 0xFE, 0x54}, // 14 = yellow + {0xFE, 0xFE, 0xFE} // 15 = white }; static grub_uint8_t grub_ofconsole_normal_color = 0x7;