DeviceScale appears to be an invalid configuration option
I have been having some trouble with setting up Plymouth with my theme, it appears that the 'DeviceScale=X'
parameter issued in /etc/plymouth/plymouthd.conf
and /usr/share/plymouth/plymouthd.defaults
has no effect, although the themes themselves do function. My issue is that the password prompt of the theme is far too small to see really. This is due to my laptop having a 4K UHD display.
I have tried inserting a line under #75
to the 'colorful_loop.script'
file as seen below (where #nn represents a given line number):
#75 prompt.image = Image.Text("Enter Password", 1, 1, 1); <- No changes.
#76 prompt.image = prompt.image.Scale(2, 2); <- New line inserted here.
#77 prompt.sprite = Sprite(prompt.image); <- No changes.
Once I had made the changes, both in the case of the 'colorful_loop.script'
file and in the case of setting DeviceScale=2
in the config files, I ran mkinitcpio -P
. This executed without any issues, but the changes did not seem to work. The prompt.image.Scale(...)
attempt simply made entry go off screen. Ideally I'd like to avoid manually repositioning/resizing the labels as this seems like the least optimal solution. Especially considering I expect that'd cause blurring if scaling is used.
Finally I tried another potential solution, but without much documentation, it is hard to know if this should work. According to: https://www.freedesktop.org/wiki/Software/Plymouth/Scripts/
I should be able to set a desired font for prompts/labels. The below is what I tried:
#75 prompt.image = Image.Text("Enter Password", 1, 1, 1, "DejaVuSans"); <- Attempted to set font, required format or lookup location for fonts unknown.
#76 prompt.sprite = Sprite(prompt.image); <- No changes.
Again, mkinitcpio -P
was run after every change and a reboot performed.
The 'ttf-dejavu'
package is installed, so the font should be accessible. To verify this and make sure it would be accessible prior to entering a passphrase on boot, I ran the following:
$ cd /boot
$ lsinitcpio initramfs-linux-ck.img | grep -i font
etc/fonts/
etc/fonts/conf.d/
etc/fonts/conf.d/60-latin.conf
etc/fonts//fonts.conf
usr/bin/loadfont
usr/bin/setfont
usr/bin/lib/libfontconfig.so.1
usr/share/fonts/
usr/share/fonts/TTF/
usr/share/fonts/TTF/DejaVuSans.ttf
Note the last entry, DejaVuSans.ttf
is included with the initramfs image due to being required by a previously setup GRUB theme which uses it. While searching, I couldn't find out if Plymouth supports TTF fonts or where it expects them to be placed.
Although my primary disk is encrypted, I can confirm Plymouth appears to be ignoring the DeviceScale
setting due to this extract in the log file:
$ cat /var/log/plymouth-debug.log | grep -ni devicescale
26:[ply-key-file.c:352] ply_key_file_get_value:key file does not have entry for key 'DeviceScale'
36:[ply-key-file.c:352] ply_key_file_get_value:key file does not have entry for key 'DeviceScale'
I have attached my Plymouth log with this issue.
Any assistance on the matter would be appreciated.
---- Notes ----
The Plymouth theme I am using: https://github.com/adi1090x/plymouth-themes/tree/master/pack_1/colorful_loop
Operation system: Arch Linux
Laptop: Dell XPS 15 9570
$ uname -a
output:
Linux arch 5.6.17-1-ck #1 SMP PREEMPT Mon, 08 Jun 2020 12:11:25 +0000 x86_64 GNU/Linux
My disk setup (unencrypted boot, encrypted LUKS with LVM partitioning):
* nvme0n1p1:
** /boot <- Unencrypted FAT32 partition with GRUB setup for UEFI booting.
* nvme0n1p2 (LUKS crypt with LVM setup):
** cryptvg-swap [SWAP]
** cryptvg-root /
** cryptvg-home /home
Kernel arguments:
$ cat /proc/cmdline
BOOT_IMAGE=/vmlinuz-linux-ck root=/dev/mapper/cryptvg-root rw cryptdevice=/dev/nvme0n1p2:cryptvg fbcon=scrollback:512k loglevel=3 splash quiet rd.udev_log_priority=3 vt.global_cursor_default=3 plymouth.debug
$ mkinitcpio -P
output to show loaded hooks:
==> Building image from preset: /etc/mkinitcpio.d/linux-ck.preset: 'default'
-> -k /boot/vmlinuz-linux-ck -c /etc/mkinitcpio.conf -g /boot/initramfs-linux-ck.img
==> Starting build: 5.6.17-1-ck
-> Running build hook: [base]
-> Running build hook: [udev]
-> Running build hook: [plymouth]
-> Running build hook: [plymouth-encrypt]
-> Running build hook: [autodetect]
-> Running build hook: [keyboard]
-> Running build hook: [keymap]
-> Running build hook: [modconf]
-> Running build hook: [block]
-> Running build hook: [lvm2]
-> Running build hook: [filesystems]
-> Running build hook: [fsck]
==> Generating module dependencies
==> Creating gzip-compressed initcpio image: /boot/initramfs-linux-ck.img
==> Image generation successful
==> Building image from preset: /etc/mkinitcpio.d/linux-ck.preset: 'fallback'
-> -k /boot/vmlinuz-linux-ck -c /etc/mkinitcpio.conf -g /boot/initramfs-linux-ck-fallback.img -S autodetect
==> Starting build: 5.6.17-1-ck
-> Running build hook: [base]
-> Running build hook: [udev]
-> Running build hook: [plymouth]
-> Running build hook: [plymouth-encrypt]
-> Running build hook: [keyboard]
-> Running build hook: [keymap]
-> Running build hook: [modconf]
-> Running build hook: [block]
-> Running build hook: [lvm2]
-> Running build hook: [filesystems]
-> Running build hook: [fsck]
==> Generating module dependencies
==> Creating gzip-compressed initcpio image: /boot/initramfs-linux-ck-fallback.img
==> Image generation successful
Link to the package page which is the installed version:
https://aur.archlinux.org/packages/plymouth/
My /etc/plymouth/plymouthd.conf
file (note the DeviceScale
string):
# Distribution defaults. Changes to this file will get overwritten during
# upgrades.
[Daemon]
Theme=colorful_loop
ShowDelay=0
DeviceTimeout=5
DevieScale=3