bug-grub
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

GRUB graphical menu patch


From: Yutaka Saito
Subject: GRUB graphical menu patch
Date: Thu, 27 Sep 2001 12:01:00 +0900

Hi,

Though I'm afraid there have already been some similar patches ...
I've created a patch to realize a graphical menu on the GRUB.
Build GRUB 0.90 with this patch and add the line below in your menu.lst.

 graphmenu

Then, after boot, you'll see very simple graphical menu drawn with built-in
font. The key operation is: up-arrow key moves the active indicator up;
down-arrow key moves it down; escape key shows you the ordinary text-mode menu;
enter key executes scripts of the selected title.

You can use image file in BMP or PCX format for the wallpaper. Do like this.

 graphmenu --wallpaper=(hd0,0)/boot/grub/foo.bmp

You can put the file in any directory. Of course, you can specify a file
compressed by gzip.

There are some limitations about file format. BMP file must be in 8 bpp format
and not compressed. PCX file must be in 8 bpp format, though it's OK if it's
compressed or not.

Another feature is that you can use any shape of fonts by creating a
monochrome BMP file containing font pattern. I've attached a sample font
pattern file with this mail, which has been drawn with TrueType font "Epilog"
available from http://fonts.tom7.com/.

 graphmenu --wallpaper=(hd0,0)/boot/grub/foo.bmp \
             --font=(hd0,0)/boot/grub/font-epilog28.bmp.gz

Font patterns are separated by markers drawn at the bottom line. Create
favorite font pattern refering to the sample file. Although the height is
limited up to 127 dots and width of each font is up to 64 dots, I think it's
enough to draw title strings :-)

You can modify the position to draw title strings and their colors by adding
options. For example, if you want to change the font color of activated title
to red, do like this.

 graphmenu --wallpaper=(hd0,0)/boot/grub/foo.bmp \
           --font=(hd0,0)/boot/grub/font-epilog28.bmp.gz --highlight=0xff0000

The RGB order is in 0xRRGGBB. There are some options to change the preference,
and, to see them, do "help graphmenu". I'm sorry it's written in broken English
like this mail ;-)

Enjoy this patch!

---
Yutaka

Attachment: grub-0.90-ys-20010927a.patch.gz
Description: Binary data

Attachment: font-epilog28.bmp.gz
Description: Binary data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]