chenall / grub4dos

外部命令和工具源码:https://github.com/chenall/grubutils 下载:
http://grub4dos.chenall.net
GNU General Public License v2.0
629 stars 132 forks source link

grub4efi: echo $[0x70] change background color not working in graphicsmode #390

Open steve6375 opened 1 year ago

steve6375 commented 1 year ago

in latest 2022-11-28 grub4efi bootx64.efi

in graphicsmode 3, command echo $[0x70]FRED works

but in graphicsmode -1 800 (for instance) echo $[0x70]FRED produces no text (black on black?) image

800x600 image

image image

yaya2007 commented 1 year ago

In text mode, the background color can be set for characters. In graphic mode, it is not allowed. This is to avoid interference caused by background color of characters.

The text mode has only 2 ^ 4=16 colors, while the graphic mode can have 2 ^ 24=16777216 colors, which is quite rich. It is unnecessary to set the background color of characters.

steve6375 commented 1 year ago

but it is necessary because it means batch file code and menus written for grub4dos will not work in grub4efi.

As in case above, a batch file which works OK in grub4dos and shows $[0x70] as grey background causes no text to be displayed when in grub4efi.

Is it not possible to support background colours and be compatible with grub4dos? Help text for 'echo help' says background colors are supported and does not say text mode only for uefi?