From e634069a2bfc7b399881c30d5a53a42886e0461d Mon Sep 17 00:00:00 2001 From: Daniel Thwaites Date: Thu, 17 Nov 2022 19:04:28 +0000 Subject: [PATCH] Fix image clipping in Plymouth theme :bug: --- modules/plymouth/default.nix | 3 +++ modules/plymouth/theme.script | 3 +-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/modules/plymouth/default.nix b/modules/plymouth/default.nix index 556d4c03..80688bcc 100644 --- a/modules/plymouth/default.nix +++ b/modules/plymouth/default.nix @@ -9,8 +9,11 @@ let mkdir -p $themeDir # Convert in case the input image is not PNG + # A transparent border of 42% ensures that the image is not clipped when rotated ${pkgs.imagemagick}/bin/convert \ -background transparent \ + -bordercolor transparent \ + -border 42% \ ${config.stylix.targets.plymouth.logo} \ $themeDir/logo.png diff --git a/modules/plymouth/theme.script b/modules/plymouth/theme.script index c7549973..1faa4125 100644 --- a/modules/plymouth/theme.script +++ b/modules/plymouth/theme.script @@ -1,5 +1,6 @@ center_x = Window.GetWidth() / 2; center_y = Window.GetHeight() / 2; +baseline_y = Window.GetHeight() * 0.9; ### BACKGROUND ### @@ -18,8 +19,6 @@ logo.sprite.SetPosition( 1 ); -baseline_y = center_y + logo.image.GetHeight(); - logo.spinner_active = 1; logo.spinner_third = 0; logo.spinner_index = 0;