#Debian #gnome #ImageEditor I really want a simple image crop and resize tool that works with the clipboard. So often I see an image online that I'd like to forward but it is ridiculous in some way (a 2000x1000 PNG of 10 words of text with a dappled background, say. All 1MB of it).

Firing up GIMP is slow and complex. Pinta is better but painful to install, does not like large files (20MP+ camera photos) and crashes a lot, while gThumb only works on files.

Is there a better program?

@moz If you are willing to use the terminal, the command line makes this really easy. "sudo apt install imagemagick", if it isn't installed, and then use the convert tool. As in "convert image.png -resize 300 small-image.png"

The 300 scales it down so the long side is 300 pixels.

@knasman how do I do that from an image in the clipboard without using another program to turn it into a file, then put it back on the clipboard afterwards? The IM docs suggest that clipboard integration only works on windows.

@moz @knasman

Improved version; takes original from clipboard and places converted image into clipboard:

#!/usr/bin/sh
FILEPATH=/tmp/convert_and_copy_to_clipboard
wl-paste > $FILEPATH
convert -resize 20% $FILEPATH $FILEPATH.webp
wl-copy < $FILEPATH.webp

@moz on my Android phone I found #ImagePipe for that job, but nothing for the Linux desktop, yet.
https://f-droid.org/packages/de.kaffeemitkoffein.imagepipe
Imagepipe | F-Droid - Free and Open Source Android App Repository

removes exif data and modifies images to reduce size before sharing.

@moz

Can be done by installing `imagemagick` and `wl-clipboard` and using script below. `-resize` parameter and output file format can of course be set to whatever is preferred. This is for Ubuntu.

#!/usr/bin/sh
convert -resize 20% $1 $1.webp
wl-copy < $1.webp

Script may be integrated into some clipboard manager too.

@moz
Here is how I crop an image quickly using the program KolourPaint.

#Linux #LinuxMint #KolourPaint #Gimp
@x_tof