I was trying to get a screenshot of my lightdm login screen after I'd added Openbox to Debian Jessie Xfce. The steps I used:
First, I installed ImageMagic. From a terminal in an Xfce session, I ran:
# apt-get install imagemagick
Next, I created the file ~/screenshot.sh, with the following inside:
chvt 7; sleep 5s; DISPLAY=:0 XAUTHORITY=/var/run/lightdm/root/:0 xwd -root -out ~/screenshot.xwd; convert ~/screenshot.xwd ~/screenshot.png; rm ~/screenshot.xwd
(In the above, chvt 7 is the number of the virtual console. It takes a screenshot 5 seconds after the script has been run and saves the screenshot to the home directory.)
Then, I made the script executable.
Then, to take the screenshot, I logged out of the system, pressed Ctrl+Alt+F1 at the login screen to go to console mode, logged in as the normal user, got root access, and ran the screenshot script:
# ./screenshot.sh
Once the script ran, it took me back to the login screen and after five seconds it took the screenshot and saved it in the /root directory with the filename screenshot.png. (I then copied screenshot.png to my home directory.)
To do this, I (somewhat loosely) followed the steps I found in this article: How To Take Screenshot Of Login Screen In Ubuntu 14.04
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment