I take a lot of Mac screenshots, whether it be for our website or to illustrate instructions I'm sending to a friend or customer. Techniques to make my Mac screenshots easy/attractive/compact/effective are valuable to me, so I want to collect them up in a blog post (and encourage people to teach me more tips in the comments!)
If you're new to taking screenshots on the Mac, here are the instructions from Apple to get you warmed up.
For this tip, we're focusing specifically on Window screenshots and how to screenshot only the window without the extra shadow/transparent border around the window.
This also works for Command + Control + Shift + 4 to copy your window screenshot to the clipboard.
Often I need to take a screenshot to replace an existing asset on our website; in those cases, I usually want to make the window the same size as in the previous screenshot to ensure a smooth replacement. I made a short AppleScript to resize a window given the app name, desired width, and desired height, designed to run on the command line using Terminal.
on run argv
set theApp to item 1 of argv
set appWidth to item 2 of argv
set appHeight to item 3 of argv
tell application "System Events" to tell process theApp
tell window 1
set size to {appWidth, appHeight}
end tell
end tell
end run
(Credit to this AskDifferent thread for the reliable resize code)
Script Editor
using Spotlight.resize
in your Home folder. (Or, obviously, you can save it wherever you like.)When you're ready to resize a window, in Terminal run:
osascript ~/resize.scpt "the app" width height
for example osascript ~/resize.scpt "Google Chrome" 500 500
would resize a Chrome window to 500 by 500. The quotes are only needed if the app name has a space in it.
Do you have a good tip about how to take better screenshots on Mac? If so, we'd love to learn it! Share your tip in the comments below.
View CommentsSan Francisco / Phoenix, USA
© 2024 Decipher Media, LLC. · Privacy