summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorElena ``of Valhalla'' Grandi <valhalla@trueelena.org>2024-08-12 09:41:48 +0200
committerElena ``of Valhalla'' Grandi <valhalla@trueelena.org>2024-08-12 09:41:48 +0200
commite71315525b97d594f75486ebaf23843e105d0b1a (patch)
tree783607267898cf7d90734a808574ab029fb8d0c6
parente45816b047a071a296cb4c73142db7225e4489bc (diff)
Screenshots with ImageMagick
-rw-r--r--source/desktop/desktop_environment/index.rst34
1 files changed, 34 insertions, 0 deletions
diff --git a/source/desktop/desktop_environment/index.rst b/source/desktop/desktop_environment/index.rst
index a200f5c..35bc84c 100644
--- a/source/desktop/desktop_environment/index.rst
+++ b/source/desktop/desktop_environment/index.rst
@@ -35,6 +35,38 @@ primary (which can be basted with a middle mouse click)::
xclip -o -selection clipboard | xclip -i
+Screenshots
+===========
+
+With ImageMagick
+----------------
+
+The default behaviour of import is to take a custom rectangular portion
+of the screen; just launch::
+
+ import $FILENAME
+
+and drag the cursor to select the area you are interested into.
+
+To get a screenshot of the full screen (the root window)::
+
+ import -window root $FILENAME
+
+To get a screenshot of one specific window::
+
+ import -window `xwininfo | awk '/.*Window id:.*/ {print $4}'` $FILENAME
+
+and then click on the window you are interested in; to also include the
+window borders the command is::
+
+ import -border -window `xwininfo | awk '/.*Window id:.*/ {print $4}'` \
+ $FILENAME
+
+To take a screenshot of a running screensaver, login remotely to the
+computer e.g. via ssh, with the same user that is running the X session,
+and then::
+
+ DISPLAY=:0 import -window root $FILENAME
XDG
===
@@ -61,6 +93,8 @@ See Also
* `The old version of this article on my old website
<https://www.trueelena.org/computers/howto/managing_x_from_the_command_line.html>`_
+* `Another article from my old website that has been added here
+ <https://www.trueelena.org/computers/howto/screenshots_with_imagemagick.html>`_
..
vim: set filetype=rst: