Macs in Chemistry

Insanely great science

 

Preview Tips

PDF seems to have become the standard for online distribution of publications, this is despite many obvious limitations. In particular from the point of view of chemists, any chemical structures no longer contain any chemical information. This means that for instance you can’t do a sub-structure search of PDF documents. Whilst Adobe Reader is the usual cross-platform viewer Apple provide there own PDF viewer called Preview. Preview employs Apple's implementation of Adobe's PDF specification, and uses of Apple's Cocoa graphical user interface, Quartz graphics layer, and QuickTime image codec. Originally developed for the NEXT operating system it has been improved and updated regularly by Apple.

There are now a number of applications for reference management but Preview can be used as the reader for references and here are a number of features that you might find useful.

Control click on the toolbar and you get a drop-down menu that includes “Customize toolbar”, you can now drag often used options to the toolbar. The annotate tool is available only when viewing PDFs by default, but if you open an image you can add the annotate tool so it is available for images also.

By default you can have a red rectangle or oval, however if you double click on the shape a dialog box opens allowing you to change colour, line thickness and make it a dashed line. If you insert a “Note” annotation and then double click on the annotation you can change the colour and the associated icon.

These annotations can be saved with the file and can thus be shared with colleagues. Disappointingly they are not indexed by Spotlight and so can’t be used for searching. It is also possible to add links within the document, these can either be links to other pages within the document or links to external URLs. The links only become active when you uncheck the “Edit link annotations”.

You can also add markup annotations to PDFs, either from the “Tools” menu or you can add an icon to the toolbar as described above. Note they are only available when you have highlighted some text. With text selected the options are “highlight”, “strikethrough” and “underline”. To remove them you have to display the annotations in the sidebar and select the desired annotation and then delete.

If you want to save a certain page for reference or are half way through a long publication and want a break, you can bookmark the page by pressing Command-D or by choosing Add Bookmark from the Bookmarks menu, the link will then be added to the Bookmarks menu. These Bookmarks are not saved with the PDF file and won’t work if you move the file. Interestingly you can also bookmark images that you use often so you don't need to locate them first.

If you open a PDF and then select “Inspector” from the “Tools” menu a floating windows opens offering a number of extra options. The first tab gives information about the document, the second allows you to add Spotlight keywords to allow improved searching. The fourth tab gives a selection of “crop and rotation” options, you can apply these manipulations to individual pages or all pages. This is very useful if a PDF includes a table that needs to be rotated. All changes can be saved with the document.

If you have two or more PDFs open it is possible to combine pages from different PDF files by simply dragging and dropping pages from the sidebar, you can also change the order of pages by dragging the pages in the sidebar. This can be useful if supplementary material is provided with a publication, simply add the supplementary information to the original document (use print to PDF if the information is provided in other file formats).

Preview can also be used as an image viewer and can open a wide variety of file formats (AI - Adobe Illustrator Artwork files, BMP – Windows Bitmap files, DNG – Digital Negative files, EPS – Encapsulated PostScript files, FPX – FlashPix files, GIF – Graphics Interchange Format files, HDR – High Dynamic Range Image files, JPEG 2000 – JPEG 2000 files, JPEG – Joint Photographic Experts Group files, OpenEXR – OpenEXR files, PS – Adobe PostScript files (after an automatic conversion to PDF), PSD – Adobe Photoshop files. PICT – QuickDraw image files, PNG – Portable Network Graphics files, PNTG – MacPaint Bitmap Graphic files, QTIF – QuickTime image files, RAD – Radience Scene Description files, RAW – Raw image files, SGI – Silicon Graphics Image files, TGA – TARGA image files, TIF, TIFF – Tagged Image File Format files, XBM – X BitMap files). One useful option in the preferences is to “Open all images in one window”. All the selected images are then visible in a single window and you can browse through them as a slideshow, or you can select all images (Command-A) and then one of the options in the Print dialog box is to print multiple images per page.

Alternatively you can select a subset by pressing the command button when selecting images. Images are usually in alphabetical order (PDF in page number order) but the drop-down menu at the bottom of the sidebar allows you to change the order.

Another feature worth exploring are the Automator actions available, if you open Automator and select PDFs or Photos (these were previously under Preview in Tiger) you can see the ready made actions that are available.

In Applescripts section there is an automator workflow to combine pdfs. this was written for Mac OS 10.4 but should still work in 10.5. Whilst as I’ve mentioned it is possible to drag and drop pages to combine PDFs, the automator workflow would certainly be preferable if you were seeking to combine a large number of PDFs.