You are not logged in.
Pages: 1
I manage to lock my screen with i3lock when I type ctrl-alt-del. I made a script named i3locker, that has those lines:
#!/bin/bash
/usr/local/share/i3locker/scrot /usr/local/share/i3locker/screenshot.png -B 2 -i /usr/local/share/i3locker/icon/lock.png
xset dpms force off
sleep 1s
i3lock -i /usr/local/share/i3locker/screenshot.png
xset s activate
It's the fastest script I found. I'm using the scrot fork of darddan and I use this icon . The speed is great and I was curious to know if my script could get improvement. I use before i3lock-next,i3lock-fancy, but found those script not as fast. Let me know what you find.
Last edited by cuicui-369 (2018-04-12 11:12:01)
Offline
I made some modification mostly because my laptop is not enough fast to perform the task. My laptop has a core i5-4300U processor, 8GB of DDR3L/1600 memory, and a 256GB SSD. It take a bit too long to get the picture of the desktop (screenshot) display again after having been blur.
my /usr/local/bin/i3locker has the following lines:
#!/bin/bash
/usr/local/share/i3locker/scrot /usr/local/share/i3locker/screenshot.png -B 2 -i /usr/local/share/i3locker/icon/lock.png
#convert /usr/local/share/i3locker/screenshot.png -colors 255 /usr/local/share/i3locker/screenshot.png
feh -F /usr/local/share/i3locker/screenshot.png &
xset dpms force suspend
i3lock -n -i /usr/local/share/i3locker/screenshot.png
sleep 0.05 ; killall feh
This script require imagemagick, scrot (from my previous post, but not mandatory), feh and i3lock.
I'm looking forward to know if on a i7 this script will run faster or what.
Last edited by cuicui-369 (2018-04-12 22:25:06)
Offline
Pages: 1