• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag
 

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: QuarkXPress: embedded text boxes
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: QuarkXPress: embedded text boxes


  • Subject: Re: QuarkXPress: embedded text boxes
  • From: Hans Haesler <email@hidden>
  • Date: Wed, 7 Feb 2001 07:06:49 +0100

On Tue, 06 Feb 2001, Michael Turner wrote:

>Has anyone attempted to extract the contents of embedded text boxes (in
>QuarkXPress)? I would like to extract the text of a selection regardless of
>if the text is in the original box of an anchored text. I extract the text
>fine from a selection but don't know how to grab the text of boxes that are
>anchored in the selection.

Michael,

here is a rough sketch of a quick idea for grabbing the text in anchored
boxes which are embedded in the selected text:

A new document is created, then a text box. The selection is copied
to this box. A repeat loop collects the stories from the text boxes,
except from the last one which is the container box.
The "|" separates the stories.
---
tell application "QuarkXPress 4.11"
make document at beginning
tell document 1
make text box at beginning
end tell
copy selection of document 2 to before paragraph 1 of text box 1 of
document 1
set aText to ""
tell document 1
repeat with i from 1 to (count of text boxes) - 1
try
set aText to aText & story 1 of text box i & "|"
on error
end try
end repeat
end tell
close document 1 saving no
aText
end tell
-->"one|two|"

Give this a try -- but, please, begin with a small selection...

And, yeah... how do I insert the resulting snippets in the main string?
I think that it can be done. But this would be another story...

Regards,

Hans

---
Hans Haesler | email@hidden


References: 
 >QuarkXPress: embedded text boxes (From: Michael Turner <email@hidden>)

  • Prev by Date: Re: scripting web sharing control panel
  • Next by Date: Re: scripting web sharing control panel
  • Previous by thread: Re: QuarkXPress: embedded text boxes
  • Next by thread: Automating the Mac OS Server Admin Software
  • Index(es):
    • Date
    • Thread