Drawing Suite
384
Text frames can be linked together so that the text flows from the text frame of one shape into the
text frame of another shape. To link text frames, use the next textframe and previous textframe
properties. The following example creates a text box (a rectangle with a text frame) and adds some
text to it. It then creates another text box and links the two text frames together so that the text flows
from the first text frame into the second one.
set myTB1 to make new text box at active document with properties {text ¬
orientation:horizontal, left position:72, top:72, width:144, ¬
height:36}
set content of text range of text frame of myTB1 to "This is some text. ¬
This is some more text. And this is the text that should flow into ¬
the next text box"
set myTB2 to make new text box at active document with properties {text ¬
orientation:horizontal, left position:72, top:144, width:72, ¬
height:36}
set next textframe of text frame of myTB1 to text frame of myTB2
Use the containing range property to return a text range object that represents the entire story that
flows between linked text frames. The following example checks the spelling in the text in the third
text box and any other text that's linked to it.
set myStory to (containing range of text frame of text box 3 ¬
of
active
document)
check spelling myStory
Properties
containing range
Returns a
text range
object that represents the entire story in a series of shapes with linked text
frames that the specified text frame belongs to. Read-only.
has text
True if the specified shape has text associated with it. Read-only.
margin bottom
Returns or sets the distance (in points) between the bottom of the text frame and the bottom of
the inscribed rectangle of the shape that contains the text. Read/write.
margin left
Returns or sets the distance (in points) between the left edge of the text frame and the left edge
of the inscribed rectangle of the shape that contains the text. Read/write.
margin right
Returns or sets the distance (in points) between the right edge of the text frame and the right
edge of the inscribed rectangle of the shape that contains the text. Read/write.
margin top
Returns or sets the distance (in points) between the top of the text frame and the top of the
inscribed rectangle of the shape that contains the text. Read/write.