View Single Post
I am using Omnigraffle Pro 5 and creating a complex image using AppleScript. This is drawing shapes to the front window which it identifies like this:

tell application "OmniGraffle Professional 5"
make new document
tell layout info of canvas of front window
set type to hierarchical
set direction to left to right
set rank separation to 0.2
end tell
tell canvas of front window
set columnAlignment to left

Is it possible instead to create a window with a name, like "myDiagramWindow" or such-like, and use that as the destination for commands instead of "front window"? This would get around an occasional problem I have found where if I choose the OmniGraffle application part-way through drawing the diagram it starts drawing into a new window, and I end up with two partial diagrams!