• 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: Quark 6.5 Insert text into insertion point Broken?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Quark 6.5 Insert text into insertion point Broken?


  • Subject: Re: Quark 6.5 Insert text into insertion point Broken?
  • From: Jason Bourque <email@hidden>
  • Date: Wed, 16 Feb 2005 16:04:24 -0500

Thanks! That did the trick.

Jason Bourque


On 2/16/05 10:01 AM, "Hans Haesler" <email@hidden> wrote:

> On Wed, 16 Feb 2005, Jason Bourque wrote:
>
>> This puts the special character at the beginning of the text box not where
>> the insertion point is. I don't have any thing selected. Thanks for the
>> help.
>
> If you don't have anything selected then your script generates
> an error message.
>
> If you select the target box (manually or by script) _and_ if you
> use 'contents' (instead of 'text') then it works as expected.
>
> Please make a new project, make a text box, type some text and place
> the insertion point somewhere in the middle of the line. Unselect
> the box and select the item tool (just to make it harder :-).
>
> Then run this script:
> ---
> tell document 1 of application "QuarkXPress 6.5"
>   set vTargetBox to text box 1
> end tell
>
> set vSpecialCharList to ¬
>   {"° = Degrees", "Ý = Cross", "\" = Inch Mark", "¢= Cents"}
>
> tell application (path to frontmost application as text)
>   try
>     set vSpecialCharacter to character 1 of item 1 of (choose from list ¬
>       vSpecialCharList default items (item 1 of vSpecialCharList) ¬
>         without multiple selections allowed) as string
>   on error
>     return
>   end try
> end tell
>
> tell document 1 of application "QuarkXPress 6.5"
>   activate
>     set selected of vTargetBox to true
>     set tool mode to contents mode
>     set contents of selection to vSpecialCharacter
> end tell
> ---
> Please note that you must select the box before the tool mode is set.
> In other words, the script would fail with grouped boxes ...
>
> Regards,
> Hans
>
> ---
> Hans Haesler <email@hidden>
>
>
>  _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Applescript-users mailing list      (email@hidden)
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >Re: Quark 6.5 Insert text into insertion point Broken? (From: Hans Haesler <email@hidden>)

  • Prev by Date: Re: do shell script without blocking?
  • Next by Date: Re: do shell script
  • Previous by thread: Re: Quark 6.5 Insert text into insertion point Broken?
  • Next by thread: Frontmost App
  • Index(es):
    • Date
    • Thread