You are not logged in.
Pages: 1
Topic closed
It's being surprisingly difficult to understand what's needed in order to have a login screen that does not contain the default noise PNG as background.
Apparently now the default theme is a gresource so common css overwrite don't seem to make it.
How did you folks solved this problem?
Apologies if already discussed, it's just that the problem is NOT the GNOME Desktop Background, and NOT the lock screen, just ONLY the gdm background screen during login.
Other tricks seem to not work neither:
sudo -u gdm dbus-launch gsettings set org.gnome.desktop.screensaver picture-uri '/new/picture.png'
Thanks for any sort of help with this and Best Regards
Last edited by WebReflection (2015-05-06 19:00:05)
Offline
Have you tried the suggestions which are in the wiki.
Offline
I finally got this to work. The wiki needs updating as of now it only states that gnome shell theme is now in a binary format, but not how to extract and repack it afterwards...
Anyway this is how i got it to work.
Use this script to extract gnome-shell-theme inside your choosen working directory
extractgst.sh
#! /bin/sh
#change workdir to suit your system
workdir=/home/merlin/temp/GS/test
gst=/usr/share/gnome-shell/gnome-shell-theme.gresource
mkdir theme
for r in `gresource list $gst`; do
gresource extract $gst $r >$workdir${r/#\/org\/gnome\/shell/}
done
Once you've run the script you should have the theme extracted to the theme folder which was created inside your workdir.
Now you can proceed to add a background image to this folder and edit gnome-shell.css by following the wiki page.
You must now create the file gnome-shell-theme.gresource.xml inside the theme directory. Simply copy paste the xml code below into gnome-shell-theme.gresource.xml, making sure to change the line that refers to your background image. On my system the background image is named login-background.jpg
<?xml version="1.0" encoding="UTF-8"?>
<gresources>
<gresource prefix="/org/gnome/shell/theme">
<file>calendar-arrow-left.svg</file>
<file>calendar-arrow-right.svg</file>
<file>calendar-today.svg</file>
<file>checkbox-focused.svg</file>
<file>checkbox-off-focused.svg</file>
<file>checkbox-off.svg</file>
<file>checkbox.svg</file>
<file>close-window.svg</file>
<file>close.svg</file>
<file>corner-ripple-ltr.png</file>
<file>corner-ripple-rtl.png</file>
<file>dash-placeholder.svg</file>
<file>filter-selected-ltr.svg</file>
<file>filter-selected-rtl.svg</file>
<file>gnome-shell.css</file>
<file>gnome-shell-high-contrast.css</file>
<file>logged-in-indicator.svg</file>
<file>login-background.jpg</file>
<file>more-results.svg</file>
<file>no-events.svg</file>
<file>no-notifications.svg</file>
<file>noise-texture.png</file>
<file>page-indicator-active.svg</file>
<file>page-indicator-inactive.svg</file>
<file>page-indicator-checked.svg</file>
<file>page-indicator-hover.svg</file>
<file>process-working.svg</file>
<file>running-indicator.svg</file>
<file>source-button-border.svg</file>
<file>summary-counter.svg</file>
<file>toggle-off-us.svg</file>
<file>toggle-off-intl.svg</file>
<file>toggle-on-us.svg</file>
<file>toggle-on-intl.svg</file>
<file>ws-switch-arrow-up.png</file>
<file>ws-switch-arrow-down.png</file>
</gresource>
</gresources>
now the only thing left to do is to run
cd ./theme
glib-compile-resources gnome-shell-theme.gresource.xml
It will create a gresource file that you can swap in /usr/share/gnome-shell.
Good luck and hopefully I will save many some headache. Took me quite a while to get the whole thing working
Last edited by atrotet (2015-05-06 04:49:36)
Offline
@mychris I'm the one that edited the Wiki in first place because of misleading info ... is very outdated, and I'm not sure how to clean it up with these info.
@atrotet THANKS A LOT!!!! So to make life easier for everyone else too, I've created a bash script that automates the entire procedure. Let's calls it login-background.sh
#!/usr/bin/sh
if [ "$IMAGE" = "" ]; then
IMAGE=$(
dbus-launch gsettings get org.gnome.desktop.screensaver picture-uri |
sed -e "s/'//g" |
sed -e "s/^file:\/\///g"
)
fi
if [ ! -f $IMAGE ]; then
echo "unknown IMAGE $IMAGE"
exit 1
fi
echo ''
echo 'using the following image as login background:'
echo $IMAGE
echo ''
if [ -d ~/tmp ]; then
CREATED_TMP="0"
else
mkdir -p ~/tmp
CREATED_TMP="1"
fi
WORKDIR=~/tmp/gdm-login-background
GST=/usr/share/gnome-shell/gnome-shell-theme.gresource
GSTRES=$(basename $GST)
mkdir -p $WORKDIR
cd $WORKDIR
mkdir theme
for r in `gresource list $GST`; do
gresource extract $GST $r >$WORKDIR$(echo $r | sed -e 's/^\/org\/gnome\/shell\//\//g')
done
cd theme
cp "$IMAGE" ./
echo "
#lockDialogGroup {
background: #2e3436 url(resource:///org/gnome/shell/theme/$(basename $IMAGE));
background-size: cover;
background-repeat: no-repeat;
}" >>gnome-shell.css
echo '<?xml version="1.0" encoding="UTF-8"?>
<gresources>
<gresource prefix="/org/gnome/shell/theme">' >"${GSTRES}.xml"
for r in `ls *.*`; do
echo " <file>$r</file>" >>"${GSTRES}.xml"
done
echo ' </gresource>
</gresources>' >>"${GSTRES}.xml"
glib-compile-resources "${GSTRES}.xml"
sudo mv "/usr/share/gnome-shell/$GSTRES" "/usr/share/gnome-shell/${GSTRES}.backup"
sudo mv "$GSTRES" /usr/share/gnome-shell/
rm -r $WORKDIR
if [ "$CREATED_TMP" = "1" ]; then
rm -r ~/tmp
fi
What does it do ?
It's quite simple, it accepts a generic IMAGE env variable
IMAGE=/usr/local/images/whatever.png sh login-background.sh
If not specified, it uses the default image used by GNOME 3.16 as locked out/screensaver
if not found, it gets out.
The rest is about doing what you suggested using sed, which is present by default in Arch, overwriting the CSS instead of replacing it (although not sure this is the best way but it ust works), creating a .backup file for he previous resource and moving the generated one over, cleaning up after everything is done.
It worked like a charm, so thank you very much for this!!!! I own you one
Last edited by WebReflection (2015-05-06 18:47:12)
Offline
Side note: in case anyone would like to take the shortcut, I'm maintaining my own OS flavor which is Arch Linux and GNOME and the main helper/installer is a file called
archibold
If you want the most simplified way to update the gdm login background and whatever else archibold has to offer this is the procedure:
curl -L -O http://archibold.io/sh/archibold
chmod +x archibold
sudo mv archibold /usr/bin/
# to know all options
archibold
# in case your lock screen is what you want as login background
archibold login-background
# in case you want a different image as background
# archibold login-background /usr/dir/different/image.png
Please ignore the resplash option if you are not on archibold created distro, and feel free to use other shortcuts to maintain your arch linux distro.
The reference site is archibold.io, already posted somewhere in this forum befoore :-)
Cheers
Offline
It worked like a charm, so thank you very much for this!!!! I own you one
Hey no worries, I am glad after 9 years of using arch I finally get to help someone ...
I saw your post after litteraly spending a full day researching on resources file and how to work with them. Documentation is a bit lacking on the matter. I had just finished rebooting after installing my login background ahah.
And also I want to point out that you can achieve this using different methods as explained in this thread. I did try (and fail) to rebuild gnome-shell-theme from git as it seems the 3.16 branch was missing files. It did help me by providing me a template xml file though.
I believe the unpack/repack method is a better way to tweak the theme anyways...
Last edited by atrotet (2015-05-07 14:34:21)
Offline
Thanks @WebReflection for the script. Worked like a charm! (though, I tweaked it to allow spaces in the name and to use cli parameters, instead of env).
And thanks to @atrotet for explaining how to do it!
Offline
@atrotet
I cant seem to run your script
It gives me following error
test.sh: line 9: /home/test/theme/calendar-arrow-left.svg: No such file or directory
test.sh: line 9: /home/test/theme/calendar-arrow-right.svg: No such file or directory
test.sh: line 9: /home/test/theme/calendar-today.svg: No such file or directory
test.sh: line 9: /home/test/theme/checkbox-focused.svg: No such file or directory
test.sh: line 9: /home/test/theme/checkbox-off-focused.svg: No such file or directory
test.sh: line 9: /home/test/theme/checkbox-off.svg: No such file or directory
test.sh: line 9: /home/test/theme/checkbox.svg: No such file or directory
test.sh: line 9: /home/test/theme/close-window.svg: No such file or directory
test.sh: line 9: /home/test/theme/close.svg: No such file or directory
test.sh: line 9: /home/test/theme/corner-ripple-ltr.png: No such file or directory
test.sh: line 9: /home/test/theme/corner-ripple-rtl.png: No such file or directory
test.sh: line 9: /home/test/theme/dash-placeholder.svg: No such file or directory
test.sh: line 9: /home/test/theme/filter-selected-ltr.svg: No such file or directory
test.sh: line 9: /home/test/theme/filter-selected-rtl.svg: No such file or directory
test.sh: line 9: /home/test/theme/gnome-shell-high-contrast.css: No such file or directory
test.sh: line 9: /home/test/theme/gnome-shell.css: No such file or directory
test.sh: line 9: /home/test/theme/logged-in-indicator.svg: No such file or directory
test.sh: line 9: /home/test/theme/more-results.svg: No such file or directory
test.sh: line 9: /home/test/theme/no-events.svg: No such file or directory
test.sh: line 9: /home/test/theme/no-notifications.svg: No such file or directory
test.sh: line 9: /home/test/theme/noise-texture.png: No such file or directory
test.sh: line 9: /home/test/theme/page-indicator-active.svg: No such file or directory
test.sh: line 9: /home/test/theme/page-indicator-checked.svg: No such file or directory
test.sh: line 9: /home/test/theme/page-indicator-hover.svg: No such file or directory
test.sh: line 9: /home/test/theme/page-indicator-inactive.svg: No such file or directory
test.sh: line 9: /home/test/theme/process-working.svg: No such file or directory
test.sh: line 9: /home/test/theme/running-indicator.svg: No such file or directory
test.sh: line 9: /home/test/theme/source-button-border.svg: No such file or directory
test.sh: line 9: /home/test/theme/summary-counter.svg: No such file or directory
test.sh: line 9: /home/test/theme/toggle-off-intl.svg: No such file or directory
test.sh: line 9: /home/test/theme/toggle-off-us.svg: No such file or directory
test.sh: line 9: /home/test/theme/toggle-on-intl.svg: No such file or directory
test.sh: line 9: /home/test/theme/toggle-on-us.svg: No such file or directory
test.sh: line 9: /home/test/theme/ws-switch-arrow-down.png: No such file or directory
test.sh: line 9: /home/test/theme/ws-switch-arrow-up.png: No such file or directory
Offline
@atrotet
I cant seem to run your script
It gives me following error
test.sh: line 9: /home/test/theme/calendar-arrow-left.svg: No such file or directory
test.sh: line 9: /home/test/theme/calendar-arrow-right.svg: No such file or directory
test.sh: line 9: /home/test/theme/calendar-today.svg: No such file or directory
...
It was a few weeks back but I remember running into some self inflicted issues when initially attempting to use the shell script WebReflection compiled. Here are three things I did to alleviate the self infliction I was causing:
1. Make sure you grabbed the whole script, it should be 68 lines
2. Make sure you read the entire 68 lines to confirm you're comfortable running this in sudo
3. Use sudo since we're making changes to root level files to do this
Oh, and if you f'd up your ability to log in with GDM you'll need to do some fixing up.
1. Goto command line e.g. "Ctrl+Alt+F3"
2. Rename /usr/share/gnome-shell to /usr/share/gnome-shell.bak
3. re-install gnome (this will re-create the gnome-shell folder with defaults
Not sure if you were running into any of this, hope it helps you or someone else.
-blu
Offline
Hello all,
This worked, however now there's an additional bar on the top that has a different blur/edits compared to the real image.
I would like it to look the same way as it's logged on (my theme has a transparent top bar).
Is there a setting that I can change so that this works?
This is my CSS that relates to the top bar:
Thanks in advance.
Sorry for the necro.
Last edited by Jaden71 (2015-09-10 02:51:54)
Offline
Sorry to necro, but just to pre-empt others having the same problem and finding this as the first entry on google as I did: if you get an odd "wrapping" behavior for your image on the login screen, replace the section
echo "
#lockDialogGroup {
background: #2e3436 url(resource:///org/gnome/shell/theme/$(basename $IMAGE));
background-size: cover;
background-repeat: no-repeat;
}" >>gnome-shell.css
in WebReflection's script with
echo "
#lockDialogGroup {
background: #2e3436 url(resource:///org/gnome/shell/theme/$(basename $IMAGE));
background-size: cover;
background-repeat: no-repeat;
border:solid transparent 1px;
}" >>gnome-shell.css
Offline
The method described in the wiki https://wiki.archlinux.org/index.php/GD … ound_image does not work in gnome 3.20.1. does not change the wallpaper and dialog boxes and leave perched
Offline
I'm going to go ahead and close this topic now.
https://wiki.archlinux.org/index.php/Fo … bumping.22
Closing.
Sakura:-
Mobo: MSI MAG X570S TORPEDO MAX // Processor: AMD Ryzen 9 5950X @4.9GHz // GFX: AMD Radeon RX 5700 XT // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 6x 1TB SSD, 2x 120GB SSD, 1x 275GB M2 SSD
Making lemonade from lemons since 2015.
Offline
Pages: 1
Topic closed