grub2|loopback: fix theme issues for submenus

also enables greater flexibility for users to override more aspects of
theme separate from menu entries, and similarly the initial config details
separate from the menu entries. (with the recent change to merge user files
with the defaults rather than replace them, users can pick which of these
individual components they wish to customise.

identical to change as sent in to Kali and accepted by Raphaël.

Gbp-Dch: Short
This commit is contained in:
Lyndon Brown 2020-03-27 21:33:59 +00:00
parent 96ade65e65
commit 82f0acb091
3 changed files with 34 additions and 28 deletions

View File

@ -0,0 +1,16 @@
set default=0
loadfont $prefix/dejavu-bold-16.pf2
loadfont $prefix/dejavu-bold-14.pf2
loadfont $prefix/unicode.pf2
set gfxmode=auto
insmod all_video
insmod gfxterm
insmod png
source /boot/grub/theme.cfg
terminal_output gfxterm
insmod play
play 960 440 1 0 4 440 1

View File

@ -1,31 +1,4 @@
set default=0
loadfont $prefix/dejavu-bold-16.pf2
loadfont $prefix/dejavu-bold-14.pf2
loadfont $prefix/unicode.pf2
set gfxmode=auto
insmod all_video
insmod gfxterm
insmod png
set color_normal=light-gray/black
set color_highlight=white/dark-gray
if [ -e /isolinux/splash.png ]; then
# binary_syslinux modifies the theme file to point to the correct
# background picture
set theme=/boot/grub/live-theme/theme.txt
elif [ -e /boot/grub/splash.png ]; then
set theme=/boot/grub/live-theme/theme.txt
else
set menu_color_normal=cyan/blue
set menu_color_highlight=white/blue
fi
terminal_output gfxterm
insmod play
play 960 440 1 0 4 440 1
source /boot/grub/config.cfg
# Live boot
@LINUX_LIVE@
@ -51,6 +24,8 @@ source /boot/grub/install_start.cfg
submenu 'Advanced install options...' --hotkey=a {
source /boot/grub/theme.cfg
source /boot/grub/install.cfg
}
@ -59,6 +34,8 @@ fi
if @ENABLE_MEMTEST@; then
submenu 'Advanced options...' {
source /boot/grub/theme.cfg
# Memtest (if any)
source /boot/grub/memtest.cfg

View File

@ -0,0 +1,13 @@
set color_normal=light-gray/black
set color_highlight=white/dark-gray
if [ -e /isolinux/splash.png ]; then
# binary_syslinux modifies the theme file to point to the correct
# background picture
set theme=/boot/grub/live-theme/theme.txt
elif [ -e /boot/grub/splash.png ]; then
set theme=/boot/grub/live-theme/theme.txt
else
set menu_color_normal=cyan/blue
set menu_color_highlight=white/blue
fi