guix/gnu/bootloader
Stefan 9cdb10d52e
gnu: grub: Allow a PNG image and replace "aspect-ratio" with "resolution".
* gnu/bootloaders/grub.scm (<grub-image>): Remove this record and replace it
by ...
(<grub-theme>)[image]: ... this field with the default from %background-image,
(<grub-theme>)[resolution]: ... this field with the defaults from 'width' and
'height' of 'grub-background-image'.
(<grub-theme>)[images]: Remove this field.
(svg->png): Rename to ...
(image->png): ... and use 'copy-file' instead of 'svg->png', if the suffix of
the image file is not ".svg".
(grub-background-image): Remove the arguments 'width' and 'height'.
(grub-theme-image): Add function.
(grub-theme-resolution): Add function.
(grub-theme-gfxmode): Add function.
(grub-image): Remove function.
(grub-image?): Remove function.
(grub-image-aspect-ratio): Remove function.
(grub-image-file): Remove function.
(grub-theme-images): Remove function.
(%default-theme): Remove variable.
(%background-image): Remove variable.

Using image formats different to SVG was not possible.

For a <grub-image> to be chosen, the 'aspect-ratio' of it had to be 4/3, as the
resolution of any image was defaulting to 1024 x 768.

There was no code to determine the proper boot-resolution to make any use of a
list of images with different aspect-ratios.

It seems to be a better solution to only define a single image with any format,
and use a given resolution only for the conversion from a SVG file. This also
makes the use of a special <grub-image> record unnecessary.

Moving the default values from '%background-image' and '%default-theme' into
<grub-theme> makes a customisation easier without (inherit) and allows to remove
the undocumented variables %background-image' and '%default-theme'.

Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
2020-05-19 09:09:21 +02:00
..
depthcharge.scm
extlinux.scm
grub.scm gnu: grub: Allow a PNG image and replace "aspect-ratio" with "resolution". 2020-05-19 09:09:21 +02:00
u-boot.scm