• 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
QuarkXPress Xtensions objects ignored as characters in line
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

QuarkXPress Xtensions objects ignored as characters in line


  • Subject: QuarkXPress Xtensions objects ignored as characters in line
  • From: Michael Turner <email@hidden>
  • Date: Thu, 25 Jan 2001 10:39:15 -0500

This is a little hard to explain. I have 2 different Xtensions to
QuarkXPress to allow mathematical equations inline with text: MathSetterXT &
PowerMath. Both Xtensions exhibit this behavior. When I attempt to grab the
end of a line to add a string, I look for the last character. The Xtensions
create objects which are apparently not considered characters, but which sit
in a line of text just like characters do. If one of these objects is the
last item in a line, my script fails, placing the marker before the object.
How do I address the end of the line regardless if the items are objects or
characters? I need the marker at the end of the story, not the end of
individual lines.

-Michael Turner

-- Sample script exhibiting behavior:
set addString to "<END OF LINE>"
tell application "QuarkXPress 4.1"
activate
tell document 1
set boxBounds to bounds of current box
make text box at the beginning of the current page with properties ,
{bounds:boxBounds, name:"FredTheBox"}
set selection to text of story 1 of text box "FredTheBox"
of current spread
paste
set selection to text of story 1 of text box "FredTheBox"
of current spread
set last character of story 1 of text box "FredTheBox"
of current spread to ,
last character of story 1 of text box "FredTheBox"
of current spread & addString
end tell
end tell
-- result with only characters in string:
(*
"Figure A<END OF LINE>" --< embedded into a new box, as requested.
*)
-- result with object at end of box:
(*
"Figure A(object)" --< missing new text "<END OF LINE>"
*)
-- it drops the object....
(*
if you add the line below before second "end tell":
return story 1 of text box "FredTheBox" of current spread
the material seems to be returned correctly
*)
-- But if there is any standard character after the object, the string is
added as expected.

----------------------------------------


  • Prev by Date: Saving Quark spreads as an EPS
  • Next by Date: Re: applescript-users digest, Vol 2 #273 - 15 msgs
  • Previous by thread: Re: Saving Quark spreads as an EPS
  • Next by thread: Re: applescript-users digest, Vol 2 #273 - 15 msgs
  • Index(es):
    • Date
    • Thread