MacPython / Omni Graffle / Pro TerminologyΒΆ
Legacy Wiki Page
This page was migrated from the old MoinMoin-based wiki. Information may be outdated or no longer applicable. For current documentation, see python.org.
(OmniGraffle Professional.app terminology, generated from /Applications/Graphisme/OmniGraffle Professional.app)
Standard SuiteΒΆ
Common classes and commands for most applications.
CommandsΒΆ
reference.get() β Get the data for an object.\
Result: Anything β the reply for the command
reference.save(β¦) β Save an object.\
[as=UnicodeText] β The file type in which to save the data.
[in_=Alias] β The file in which to save the object.
Result: None
reference.set(β¦) β Set an objectβs data.\
to=Anything β The new value.
Result: None
application.print_(β¦) β Print an object.\
[Alias] β The file(s) or document(s) to be printed.
Result: None
reference.duplicate(β¦) β Copy object(s) and put the copies at a new location.\
to=InsertionLoc β The location for the new object(s).
[with_properties=AERecord] β Properties to be set in the new duplicated object(s).
Result: None
reference.exists() β Verify if an object exists.\
Result: Boolean β the reply for the command
reference.delete() β Delete an object.\
Result: None
application.make(β¦) β Make a new object.\
[with_properties=AERecord] β The initial values for properties of the object.
new=Type β The class of the new object.
[with_data=Anything] β The initial data for the object.
[at=InsertionLoc] β The location at which to insert the object.
Result: ObjectSpecifier β the reply for the command
application.open(β¦) β Open an object.\
[Alias] β The file(s) to be opened.
Result: None
reference.close(β¦) β Close an object.\
[saving=k.yes | k.no | k.ask] β Specifies whether changes should be saved before closing.
[saving_in=Alias] β The file in which to save the object.
Result: None
reference.count(β¦) β Return the number of elements of a particular class within an object.\
[each=Type] β The class of objects to be counted.
Result: SInt32 β the reply for the command
reference.move(β¦) β Move object(s) to a new location.\
to=InsertionLoc β The new location for the object(s).
Result: None
reference.quit(β¦) β Quit an application.\
[saving=k.yes | k.no | k.ask] β Specifies whether changes should be saved before quitting.
Result: None
ClassesΒΆ
document β An /OmniGraffle document
Parent:
Properties:
modified (r/o) Boolean β Has the document been modified since the last save?
path UnicodeText β The documentβs path.
name UnicodeText β The documentβs name.
links_visible Boolean β Whether link indicators are visible
alignment_guides_enabled Boolean β Whether smart alignment guides are enabled
distance_guides_enabled Boolean β Whether smart distance guides are enabled
show_guides Boolean β Whether manually set guides are visible
page_breaks_visible Boolean β Whether page breaks are visible
magnets_visible Boolean β Whether magnets are visible\
Elements:
pages β name | index | relative | range | test\
item β A scriptable object.
Children:
color label section window layout_info point grid word page attribute_run layer character paragraph application document graphic text
Properties:
class_ (r/o) Type β The class of the object.
properties AERecord β All of the objectβs properties.\
window β An /OmniGraffle window
Parent:
Properties:
zoomed Boolean β Whether the window is currently zoomed.
miniaturized Boolean β Whether the window is currently miniaturized.
name UnicodeText β The full title of the window.
floating (r/o) Boolean β Whether the window floats.
modal (r/o) Boolean β Whether the window is the applicationβs current modal window.
miniaturizable (r/o) Boolean β Whether the window can be miniaturized.
visible Boolean β Whether the window is currently visible.
closeable (r/o) Boolean β Whether the window has a close box.
resizable (r/o) Boolean β Whether the window can be resized.
zoomable (r/o) Boolean β Whether the window can be zoomed.
id (r/o) SInt32 β The unique identifier of the window.
bounds QDRectangle β The bounding rectangle of the window.
titled (r/o) Boolean β Whether the window has a title bar.
index SInt32 β The index of the window in the back-to-front window ordering.
document (r/o) k.document β The document whose contents are being displayed in the window.
zoom ShortFloat β Current zoom setting for this window
page k.page β Current page this window is viewing
selection AEList β Selected graphics\
application β /OmniGraffle
Parent:
Properties:
version (r/o) UnicodeText β The version of the application.
frontmost (r/o) Boolean β Is this the frontmost (active) application?
name (r/o) UnicodeText β The name of the application.
self (r/o) k.graphic β Graphic clicked to start this script
professional (r/o) Boolean β Whether this application is /OmniGraffle or /OmniGraffle Professional
demo (r/o) Boolean β Is this the demo version of the application\
Elements:
color β A color.
Parent:
Text SuiteΒΆ
A set of basic classes for text processing.
ClassesΒΆ
text_attachment β Represents an inline text attachment. This class is used mainly for make commands.
Parent:
Properties:
file_name UnicodeText β The path to the file for the attachment\
text β Rich (styled) text
Parent:
Children:
Properties:
size SInt32 β The size in points of the first character.
underlined Boolean β Is the first character underlined?
baseline_offset ShortFloat β Number of pixels shifted above or below the normal baseline.
font UnicodeText β The name of the font of the first character.
superscript SInt32 β The superscript level of the text.
alignment k.justified | k.right | k.left | k.natural | k.center β Alignment of the text.
text UnicodeText β The actual text content.
color k.color β The color of the first character.\
Elements:
text_attachments β index | relative | range | test
characters β index | relative | range | test
attribute_runs β index | relative | range | test
words β index | relative | range | test
paragraphs β index | relative | range | test\
attribute_run β This subdivides the text into chunks that all have the same attributes.
Parent:
Properties:
size SInt32 β The size in points of the first character.
underlined Boolean β Is the first character underlined?
baseline_offset ShortFloat β Number of pixels shifted above or below the normal baseline.
font UnicodeText β The name of the font of the first character.
superscript SInt32 β The superscript level of the text.
alignment k.justified | k.right | k.left | k.natural | k.center β Alignment of the text.
text UnicodeText β The actual text content.
color k.color β The color of the first character.\
Elements:
text_attachments β index | relative | range | test
characters β index | relative | range | test
attribute_runs β index | relative | range | test
words β index | relative | range | test
paragraphs β index | relative | range | test\
character β This subdivides the text into characters.
Parent:
Properties:
size SInt32 β The size in points of the first character.
underlined Boolean β Is the first character underlined?
baseline_offset ShortFloat β Number of pixels shifted above or below the normal baseline.
font UnicodeText β The name of the font of the first character.
superscript SInt32 β The superscript level of the text.
alignment k.justified | k.right | k.left | k.natural | k.center β Alignment of the text.
text UnicodeText β The actual text content.
color k.color β The color of the first character.\
Elements:
text_attachments β index | relative | range | test
characters β index | relative | range | test
attribute_runs β index | relative | range | test
words β index | relative | range | test
paragraphs β index | relative | range | test\
word β This subdivides the text into words.
Parent:
Properties:
size SInt32 β The size in points of the first character.
underlined Boolean β Is the first character underlined?
baseline_offset ShortFloat β Number of pixels shifted above or below the normal baseline.
font UnicodeText β The name of the font of the first character.
superscript SInt32 β The superscript level of the text.
alignment k.justified | k.right | k.left | k.natural | k.center β Alignment of the text.
text UnicodeText β The actual text content.
color k.color β The color of the first character.\
Elements:
text_attachments β index | relative | range | test
characters β index | relative | range | test
attribute_runs β index | relative | range | test
words β index | relative | range | test
paragraphs β index | relative | range | test\
paragraph β This subdivides the text into paragraphs.
Parent:
Properties:
size SInt32 β The size in points of the first character.
underlined Boolean β Is the first character underlined?
baseline_offset ShortFloat β Number of pixels shifted above or below the normal baseline.
font UnicodeText β The name of the font of the first character.
superscript SInt32 β The superscript level of the text.
alignment k.justified | k.right | k.left | k.natural | k.center β Alignment of the text.
text UnicodeText β The actual text content.
color k.color β The color of the first character.\
Elements:
text_attachments β index | relative | range | test
characters β index | relative | range | test
attribute_runs β index | relative | range | test
words β index | relative | range | test
paragraphs β index | relative | range | test\
Extended Text SuiteΒΆ
Extended functionality for text.
CommandsΒΆ
reference.underline() β Underline some text\
Result: None
reference.unitalicize() β Unitalicize some text\
Result: None
reference.unbold() β Unbold some text\
Result: None
reference.ununderline() β Ununderline some text\
Result: None
reference.replace(β¦)\
[regexp=UnicodeText] β Regular expression to find
[string=UnicodeText] β String to find
replacement=UnicodeText β Replacement string
Result: None
reference.italicize() β Italicize some text\
Result: None
reference.bold() β Bold some text\
Result: None
/OmniFoundation ScriptingΒΆ
OmniFoundation scripting support.
CommandsΒΆ
reference.remove(β¦) β Remove the given object from the container.\
from_=k.item β The container from which to remove the object.
Result: None
reference.add(β¦) β Add the given object to the container.\
to=k.item β The container to which to add the object.
Result: None
/OmniGraffleΒΆ
Omni Graffle Script Suite
CommandsΒΆ
reference.slide(β¦) β Slide graphics by a vector amount\
by=k.point β The x and y amounts to shift the graphics
Result: None
reference.layout() β Layout some graphics, or a whole document using the documentβs Layout Info.\
Result: None
reference.assemble() β Group graphics\
Result: k.group β the reply for the command
reference.flip(β¦) β Flip graphics\
over=k.vertically | k.horizontally β Orientation to flip the graphic around
Result: None
reference.page_adjust() β Change the number of pages to fit the current graphics\
Result: None
reference.connect(β¦) β Draw a line between graphics\
[with_properties=AERecord] β The initial values for properties of the line.
to=Anything β Graphic or graphics to connect to.
Result: k.line β the reply for the command
ClassesΒΆ
polygon β A polygon graphic
Parent:
Properties:
point_list AEList β A list containing all the vertexes of the polygon\
Elements:
points β index | relative | range | test\
layer β A layer
Parent:
Properties:
locked Boolean β are the layerβs graphics locked?
prints Boolean β do the layerβs graphics print?
visible Boolean β are the layerβs graphics visible?
name UnicodeText β name of the layer\
Elements:
page β A page
Parent:
Properties:
page_size (r/o) k.point β Size of each page
row_alignment k.bottom | k.middle_ | k.top β Row alignment
grid k.grid β Settings for the grid
column_spacing ShortFloat β Spacing between graphics in a column
script_canvas_color k.color β Canvas background color
column_alignment k.right | k.left | k.center β Column alignment
horizontal_pages SInt32 β Horizontal pages
name UnicodeText β Name of this page
row_spacing ShortFloat β Spacing between graphics in a row
vertical_pages SInt32 β Vertical pages
layout_info k.layout_info β Settings for automatic layout
canvas_size k.point β Size of the canvas (page size multiplied by number of pages)\
Elements:
polygons β index | relative | range | test | id
shapes β name | index | relative | range | test | id
groups β index | relative | range | test | id
graphics β index | relative | range | test | id
solids β index | relative | range | test | id
lines β index | relative | range | test | id
layers β name | index | relative | range | test\
shape β A graphic with a shape
Parent:
Properties:
name UnicodeText β name of the shape (βRectangleβ, βCircleβ, et cetera)\
label β A line label
Parent:
Properties:
offset ShortFloat β Distance away from the line
fill_color k.color β Fill color
filled Boolean β Is this label filled?
orientation k.vertical | k.parallel | k.perpendicular | k.horizontal β Orientation of the text
text k.text β Label text
id (r/o) SInt32 β Unique identifier
position ShortFloat β Position along the line (0 is tail, 1 is head)\
point β A point
Parent:
Properties:
x (r/o) ShortFloat β x position
y (r/o) ShortFloat β y position\
record β A record with multiple text fields
layout_info β Automated layout for a page
Parent:
Properties:
type k.vertical_hierarchy | k.force_directed | k.horizontal_hierarchy β Type of layout to perform
adjusts_pages Boolean β Adjust number of pages automatically with hierarchical layout?
shape_force ShortFloat β Repulsive force of shapes in force-directed layout
edge_force ShortFloat β Repulsive force of canvas edge in force-directed layout
random_start Boolean β Start force-directed layout with shapes in random locations?
animates Boolean β Animate force-directed layout?
line_force ShortFloat β Attractive force of lines in force-directed layout\
line β A line
Parent:
Properties:
source k.graphic β Graphic that the tail of the line is connected to.
tail_magnet SInt32 β Which magnet of the source graphic the line attaches to
line_type k.curved | k.orthogonal | k.straight β Type of the line
point_list AEList β A list containing all the points of the line.
head_scale ShortFloat β Scale of line ending on the head of the line (1.0 being the normal size)
weight ShortFloat β Weighting to give this line during automatic layout.
head_magnet SInt32 β Which magnet of the destination graphic the line attaches to
destination k.graphic β Graphic that the head of the line is connected to.
head_type UnicodeText β Type of line ending on the head of the line
tail_scale ShortFloat β Scale of line ending on the tail of the line (1.0 being the normal size)
tail_type UnicodeText β Type of line ending on the tail of the line\
Elements:
solid β Any graphic which is solid instead of a line. Includes polygons and shapes.
Parent:
Children:
Properties:
text_placement k.bottom | k.middle_ | k.top β Placement of the text inside the solid
gradient_color k.color β For linear and radial fills, this is the ending color.
fill_color k.color β The fill color. For linear and radial gradient fills this is the starting color
autosizing k.vertically_only | k.clip | k.full | k.overflow β Autosizing behavior of the solid around the text
image_scale ShortFloat β For manual image fills, the scale of the image
fill k.linear_fill | k.no_fill | k.solid_fill | k.radial_fill β The type of fill for this solid
gradient_angle ShortFloat β Angle of a linear gradient fill.
image_sizing k.stretched | k.manual | k.tiled β How to size and display the image fill.
gradient_center k.point β Starting point of a radial gradient fill. (In a square from {-1,-1} to {1,1} so {0,0} is the center of the solid.)
text k.text β The text inside the solid
rotation ShortFloat β Rotation of the graphic in degrees
image_offset k.point β For manual image fills, the offset of the image in the solid
image UnicodeText β Set to a file name to load an image fill.
magnets AEList β List of magnet points. (In a square from {-1,-1} to {1,1}.\
graphic β A graphic
Parent:
Children:
Properties:
draws_shadow Boolean β Does this graphic draw its shadow?
id (r/o) SInt32 β Unique identifier
url UnicodeText β Web link for this graphic
origin k.point β Origin of the graphic (position of the upper-left corner of the bounding rectangle)
shadow_color k.color β Color of the shadow
stroke_join k.miter | k.bevel | k.round β Type of join between segments of the stroke
size k.point β Size of the graphic (width and height of the bounding rectangle)
thickness ShortFloat β Thickness of the stroke
page (r/o) k.page β Page that this graphic is on
stroke_color k.color β Color of the stroke
allows_connections Boolean β Does this graphic allow connections to it?
locked Boolean β Is this graphic locked?
group (r/o) k.group β Which group (if any) this graphic is in
draws_stroke Boolean β Does this graphic draw its stroke?
stroke_pattern SInt32 β Dash pattern of the stroke
aligns_edges_to_grid Boolean β When snapped to the grid does this graphic align its edges to the grid? (The alternative is to align its center to the grid.)
layer k.layer β Which layer this graphic is in
jump k.page β Destination page of jump action
script UnicodeText β Source of attached AppleScript
stroke_cap k.square | k.butt | k.round β Type of cap at ends of the stroke\
Elements:
lines β index | relative | range | test | id
incoming_lines β index | relative | range | test | id
outgoing_lines β index | relative | range | test | id\
group β A grouped set of graphics
grid β The grid of a page
Parent:
Properties:
major Boolean β Does the grid have βmajorβ lines?
visible Boolean β Is the grid visible?
draws_in_front Boolean β Does the grid draw in front of all shapes?
spacing ShortFloat β Number of pixels between minor grid lines
snaps Boolean β Do points snap to the grid?
script_major_grid_color k.color β Color of major lines
major_spacing SInt32 β The number of minor grid lines for each major line
script_grid_color k.color β Color of the grid\
section β One text area in a record
Parent:
Properties:
size SInt32 β The size in points of the first character.
underlined Boolean β Is the first character underlined?
baseline_offset ShortFloat β Number of pixels shifted above or below the normal baseline.
font UnicodeText β The name of the font of the first character.
superscript SInt32 β The superscript level of the text.
alignment k.justified | k.right | k.left | k.natural | k.center β Alignment of the text.
text UnicodeText β The actual text content.
color k.color β The color of the first character.\
Elements:
characters β index | relative | range | test
attribute_runs β index | relative | range | test
words β index | relative | range | test
paragraphs β index | relative | range | test\
outgoing_line β Outgoing line
Parent:
Properties:
source k.graphic β Graphic that the tail of the line is connected to.
tail_magnet SInt32 β Which magnet of the source graphic the line attaches to
line_type k.curved | k.orthogonal | k.straight β Type of the line
point_list AEList β A list containing all the points of the line.
head_scale ShortFloat β Scale of line ending on the head of the line (1.0 being the normal size)
weight ShortFloat β Weighting to give this line during automatic layout.
head_magnet SInt32 β Which magnet of the destination graphic the line attaches to
destination k.graphic β Graphic that the head of the line is connected to.
head_type UnicodeText β Type of line ending on the head of the line
tail_scale ShortFloat β Scale of line ending on the tail of the line (1.0 being the normal size)
tail_type UnicodeText β Type of line ending on the tail of the line\
Elements:
incoming_line β Incoming line
Parent:
Properties:
source k.graphic β Graphic that the tail of the line is connected to.
tail_magnet SInt32 β Which magnet of the source graphic the line attaches to
line_type k.curved | k.orthogonal | k.straight β Type of the line
point_list AEList β A list containing all the points of the line.
head_scale ShortFloat β Scale of line ending on the head of the line (1.0 being the normal size)
weight ShortFloat β Weighting to give this line during automatic layout.
head_magnet SInt32 β Which magnet of the destination graphic the line attaches to
destination k.graphic β Graphic that the head of the line is connected to.
head_type UnicodeText β Type of line ending on the head of the line
tail_scale ShortFloat β Scale of line ending on the tail of the line (1.0 being the normal size)
tail_type UnicodeText β Type of line ending on the tail of the line\
Elements: