How to make proper OS X (yosemite) screenshots

For my blogposts I often need screenshots with the following requirements:

  • use Yosemite (right now I have beta3 installed)
  • include the shadow of the main window
  • have menus oder drop-downs open


These requirements - except the last! - can be fulfilled by the standard on-board screenshot capabilities of OS X (e.g. described here). 


So far, I have not found a tool, that can help me here - there are tools (e.g. Voila) that can screenshot the menu (only the menu) but then you have issues in stitching this together with another "background"-screenshot, because selected windows have other background colours etc.

Dear reader: this workflow is pretty time-consuming - please leave a note if you know a tool that can do proper screenshots or know a way, how to make this faster - thank you!



My workflow for flawless screenshots

Here is my workflow that gives flawless screenshots - although its a bit of work:

1. open a clean white background (e.g. textedit)

2. get your app in front that you want to screenshot

3. SHIFT-COMMAND-4 and find out the X, Y coordinates as well as hight and width of the window you want to screenshot (they are depicted in your cursor) - remember them

4. open a terminal window and make a screenshot with the following command line:

screencapture -T 10 -P -R551,325,1095,647 screenshot.png


  • -T 10 means you have 10 seconds time to "prepare" your app (open a menu etc)
  • -R means the region that should be captured the coordinates <x,y,w,h> are the ones you found out before
  • -P means that it will open in preview so you can check the output

Save this one as PNG.

5. make another screenshot from the whole window that includes the shadow with SHIFT-COMMAND-4 and SPACE. This is only needed if you want the shadow in the screenshot. Make sure, your app has the focus before, otherwise the shadow and the background colours will look differently.

6. Open both screenshots in Photoshop or a similar tool that supports layers and align the image with the expanded menu over the one with the border:

The one with the menu will have a small 1px gray border - so its 2px bigger in width and height.

Save as PNG and you are done:

Finetuning 1: Get nice round corners

Now, if you look closely you see that the corners are rounded and the screenshot with the commandline and the white from the TextEdit background is visible:

I marked the pixels in question in red so you can see ;)

I marked the pixels in question in red so you can see ;)

To get rid of this:

  1. Select Layer 0 (which is the screenshot with the shadow)
  2. COMMAND-click on it - you have selected the content of the layer now
  3. SHIFT-COMMAND-I (for inverting the selection)
  4. Select the Layer 1 (which is the one with the menus)
  5. Press "delete" to delete all content (which is in our case the white corners)



Finetuning 2: Using the WindowID instead of the -Rx,y,w,h

Another tip, that makes life a bit easier is that you can use the WindowID of the window instead of the rectangle-values. For this, you can download the small tool GetWindowID from GitHub, extract it, call "make" in a command window in the directory and you can get the WindowID when called with:


screencapture -l$(./GetWindowID "<program>" "<window>") screenshot.png


Note: This might require you to install the developer tools - which are free and its done in 2 minutes.






Posted on September 19, 2014 and filed under productivity.