Feature Request - Add border to screenshots

Screenshots benefit a lot from having a border around them. Without a border on the image, when I paste it in my notes, it has no clear edge and it’s difficult or impossible to differentiate the screenshot from the rest of the page.

Because of this, every time I take a screenshot I have to open it in Gradia so that I can add the border to it. I would much prefer, and am therefore requesting, that Spectacle does this automatically.

See the difference?

Well, I would not like my screenshots to automatically have a border, because there’s more use cases than pasting them into documents, but having this as an option in Spectacle’s edit mode would be a good addition. Until then, even though it’s a little bit fiddly to click the corner, you can use Spectacle’s rectangle tool with a stroke and no filling to add a border before saving, without having to resort to a second tool.

2 Likes

I see a difference in yours, because you made a screenshot of a white area and it’s on a white background…

I’d say a drop shadow would be nice for that, but not as a default… so hooking in imagemagik would do the trick.

I’m sure adding a border wouldn’t be much harder.

Here’s a one-liner for you:

magick screenshot.png \( +clone -background black -shadow 80x5+5+5 \) +swap -background none -layers merge +repage screenshot_with_shadow.png

So you grab your screenshot, and then open your terminal and go to that folder, rename your image ‘screenshot.png’.

It generates a second image, so here’s the difference (and easier than opening with another application).

I wonder how easy it would be to add a ‘shadow’ tool to Spectacle with options to tweak the numbers?

Anyway, you can add that one-liner as an alias or abbreviation and save yourself a few minutes on the job.

Yes, that is an option and I have tried that, but it’s not a true border because I can’t accurately place the square truly on the border. It’s more like a square that is as close to the border as I could get with my mouse. Besides, it’s actually easier to click “Export” and pick Gradia and have the border automatically there.

The border option is included in kSnip (Linux) and Sharex (Windows). It feels to me like a missing feature of Spectacle that is in other similar products.

you don’t have this option checked?

Yes, I have that checked but it doesn’t do anything to screenshots where you select a region. I believe that only applies to a full window screenshot.

I just realized that you interpreted my request as a change to the default behavior across the board for everyone. I didn’t mean that. I meant for it to be an option for each user to turn on, just like any preference. The user can check the box and save their preferences to persist through all of their future sessions.

Personally, I would turn it on so that all of my screenshots would include it without extra steps, but many other people would leave it off and would continue having the same experience they currently have.

that’s correct, a region is just what is captured within the rectangle, so you want an option for an artificial border—defined in spectacle—to be put upon ALL captures.

you can sort of do that with annotations, but it’s a rather manual process.

Window border and shadows don’t work for crops.

However, THIS works… I can press a shortcut for a rectangle screenshot with a shadow.

#!/bin/bash

# Spectacle default save directory
outdir="$HOME/Pictures/Spectacle"
mkdir -p "$outdir"

# Timestamped filename for the shadowed screenshot
outfile="$outdir/screen_$(date +%Y%m%d_%H%M%S)_sh.png"

spectacle --region --background --nonotify --output "$outdir/tmp_screenshot.png"

magick "$outdir/tmp_screenshot.png" \
    \( +clone -background black -shadow 80x5+5+5 \) \
    +swap -background none -layers merge +repage \
    "$outfile"

rm "$outdir/tmp_screenshot.png"

You can edit the outdir… if it’s not there, it gets created.

The original and shadow versions are both saved.

So if you want to try this, copy that script to the clipboard, then:

cd ~/.local/bin

touch scr-sh # up to you, I like 'screenshot-shadow'
chmod +x scr-sh
kate scr-sh

You must then paste the script and quit (save).

So then the script should work from krunner, and you can bind it to a keyboard shortcut.

Let’s give it a quick test:

And with that, it’s too late for bed already, goodnight.
screenshot_20260330_005830_shadow

also, it’s true of plasma 5 (maybe 6 as well) that if you choose Active window you get the theme shadow effect along with the window

where as with the Window Under Cursor option, you do not.