A Quick Look plugin for Chemistry files, adapted from QLColorCode
Objective-C C JavaScript CSS
Pull request Compare This branch is 56 commits ahead, 11 commits behind n8gray:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
ChemLook.xcodeproj
English.lproj
.gitignore
ChemDoodleWeb.js
Common.h
Common.m
GeneratePreviewForURL.m
GenerateThumbnailForURL.m
Info.plist
LICENSE.txt
README.md
chemlook.html
main.c
script.js
style.css

README.md

ChemLook

ChemLook is a Quick Look plugin that renders chemistry files using Open Babel and ChemDoodle Web Components.

Installation

To install the plugin, just drag ChemLook.qlgenerator to /Library/QuickLook or ~/Library/QuickLook. You may need to create that folder if it doesn't already exist.

The Library in your home folder is now hidden by default. To go there, press Command-Shift-G or choose "Go to Folder" from the Go menu, and enter ~/Library.

The plugin is also installed by default with the related ChemSpotlight plugin, which indexes chemistry files using Open Babel and adds chemical metadata (molecular mass, formula, etc.) to the Finder.

Dependencies

ChemLook requires Open Babel 2.3+ to be installed. Instructions are available in the Open Babel documentation.

Troubleshooting

It sometimes take Quick Look a while to recognise the new plugin. Try logging out and in again, or alternatively type qlmanage -r into the Terminal and press Return.

Quick Look plugins have an order of precedence based on their location. Those in /Library/QuickLook will be overridden by those in ~/Library/QuickLook, which will be overridden by those embedded within specific apps. The ChemDoodle app contains an embedded Quick Look plugin which will override ChemLook for some file formats. If you prefer ChemLook, right-click on the ChemDoodle app, choose "Show Package Contents" and delete "ChemDoodle_QLPlugin.qlgenerator".

Credits

Thanks to Nate Gray for his QLColorCode plugin for colorizing source code. I used this as a model for communicating with WebKit and command line programs.

Thanks also to iChemLabs for their excellent JavaScript ChemDoodle Web Components. These are used to generate the interactive Quick Look HTML views.