4

I opened 128 .png files in Preview, hoping to use it to create a PDF out of them, as I believe was possible in earlier versions using the New from clipboard trick, but apparently, on Yosemite, not any more.

Now I want to close the newly created documents, but it'll require me to click Don't Save 128 times.

Is there any way around this?

  • Well, quitting the application via Activity Monitor or Terminal (killall Preview) should do it, but it might be that all the windows reopen when it's next started. Maybe there's a hidden option to influence that behaviour but I'm not sure. Also you don't need to click it, with luck, the "Don't Save" option is highlighted and pressing Space will suffice (I think you need to enable that in System Preferences), so holding Cmd-W and Space for some time might close them all. – oarfish Dec 27 '14 at 18:04
  • force quit preview. – Ruskes Dec 27 '14 at 19:57
3

I'd Force-Quit it using the Apple Menu dialog, and then clear the saved state files from the storage so that Preview doesn't try to reopen those documents next time it starts.

From Finder:

  • Cmd ⌘ N
  • Cmd ⌘ Shift ⇧ G
  • Copy/paste ~/Library/Saved Application State

Delete the folder com.apple.Preview.savedState and you're set for the next start of Preview to be clean.

4

As of Yosemite, at least, there's a much easier way. Just choose Quit from the File menu.

Preview will ask you if you want to review changes. If you say no, you're done!

  • 2
    That's very much dependent on having 'ask to keep changes when closing documents' set in system prefs > general – Tetsujin Aug 14 '15 at 6:38
-1

Similar to what Chris and Tetsujin collectively said:

  1. Open System Preferences (Apple Menu, System Preferences...)
  2. Click "General"
  3. Make sure "Ask to keep changes when closing documents" and "Close windows when quitting an app" are both checked
  4. Go back to Preview, click the "Preview" menu, and click "Quit Preview"

You must log in to answer this question.