Scripting Tip

James Spahr jsp at designframe.com
Sun Jan 26 13:39:01 PST 2003


I finally discovered the way to create shapes and specify the layer 
they should be created in.

tell front document of application "OmniGraffle"
	set shp to make new shape at end of (graphics of layer "Layer 2") with 
properties ¬
		{aligns edges to grid:true, origin:{12, 12}, size:{90, 90}, 
name:"Circle"} ¬
	set shpid to the id of shp
end tell

Perhaps this will help someone, since changing the layer afterwards in 
not an option, nor is assigning the shape a layer in the properties 
list. (I also tried GUI scripting it, with no luck)

James.



More information about the OmniGraffle-Users mailing list