Macs in Chemistry

Insanely great science

ChemBioDraw 12

ChemBioDraw 12 Review

ChemBioDraw from CambridgeSoft or as it is probably still better known ChemDraw is a very established chemical drawing package that probably sets the standard for publication quality chemical drawing. The latest update offers a number of improvements but one issue remains.

ChemDraw was originally developed on a 128K Mac (chosen because of the 1984 Apple advert) and only ported to Windows in 1994. Whilst every effort was made to ensure parity between the platforms one issue has caused problems on the Mac platform over the years:- Object Linking and Embedding, and while OLE 1 was problematic, OLE 2 worked quite well, and was based on a system-supported model for software components that quickly became the standard on Windows for gluing together functionality from different vendors. In contrast this quote from Stewart Rubenstein (Former President and Chief Technology Officer CambridgeSoft Corp) perhaps sums up the situation.

"On the Macintosh, Apple had pioneered interapplication communication and application scripting with an object-based messaging model that was far ahead of the corresponding Windows technology, and a third party developed a means to use AppleEvents to implement object embedding, called EGO. This allowed users of Microsoft Word version 5 for Macintosh to edit embedded ChemDraw drawings and create true compound documents. Unfortunately, Apple chose not to support this, and Microsoft rewrote Word 6 so that EGO could not be any longer supported by the third-party extension. Instead, Apple went through a series of software extension which changed regularly and were thus poorly supported ... To this day, there is no well-supported compound document architecture for MacOS, and the model for software components still causes problems for standardized data access"

This together with the transition from Quickdraw to Quartz and the resulting change from PICT to PDF has caused issues with round-trip editing. Whilst the PICT file on the clipboard contains all the chemical information needed by ChemDraw to enable structures copied and pasted from Word Processing documents to be subsequently edited, this information is not available using PDF images. Thus a structure pasted into a Pages document as a PDF cannot be then copied back into ChemBioDraw and be edited. So while the new version of ChemBioDraw supports PDF and in particular the ability to print beautifully from within ChemBioDraw if you plan to copy the structures into Pages, Keynote, Word, Powerpoint etc. you need to switch off this option in the ChemBioDraw preferences.

I have no knowledge of how long PICT will be supported by Apple but it is apparent that it is a legacy technology and may not be there in the future. The issue seems to be compounded by the fact that whilst multiple formats can be copied to the clipboard Pages picks up the PDF format preferentially and thus compromises round-trip editing.

With that concern dealt with let's look at the ChemBioDraw update. One thing that I've already mentioned is that printing directly from ChemBioDraw is significantly improved in addition there is now the option of PDF in the "Save As" options. It might have been useful to have the ability to save as SVG, but you can convert the PDF to SVG online at Texterity. The improved printing is important because one of the major upgrades has been the quality and quantity of the biological templates. These are all stored as cdxml files in the BioDrawResources folder and it is relatively easy to add your own.

One rather nice new feature is the ability to be able to assign the center of rotation. By default, an object turns around its center when you rotate it. However, you can move the center of rotation so that the object rotates around an atom or some other location on the page. When you select an object a center of rotation indicator ("+") appears in the center of the object. While pressing the ALT key you can click and drag the indicator to another location. To reset the center of rotation to its default position, simply deselect the object.

Both the "Structure to Name" and "Name to Structure" have been improved with support for more complex ring systems and better error handling. The ChemNMR feature can now be supplemented with your own data.

Of particular interest to Mac Users are the changes to the scripting support. In the past using Applescript to control Chemdraw could be a pain. Commands needed to be defined by their menu positions, for example:-

 do menu item "SMILES" of menu "Paste Special" of menu "Edit"
Now the functions can be called directly:-

 do menu item "SMILES"
The following Applescript selects the structure, calculates the SMILES string and then pastes it into the document.

tell application "CS ChemBioDraw Ultra"
	do menu item "Select All"
	do menu item "SMILES"
	do menu item "Paste"
end tell
This is particularly useful because as extra funtionality gets added the menus can change, breaking applescripts. Just in case you might be wondering how many commands are available this scipt returns a count of 1141.
tell application "CS ChemBioDraw Ultra"
	set numberOfCommands to count of commands
	display dialog numberOfCommands
end tell
I've not tried this version of ChemBioDraw with Snow Leopard but from what I've heard there may be problems pasting strutures into word-processing documents, but since this version was developed prior to the release of Snow Leopard it is perhaps not surprising there are a few glitches. An update will no doubt appear on their web-site in due course.