Re: OSX script problem
Re: OSX script problem
- Subject: Re: OSX script problem
- From: Hans Haesler <email@hidden>
- Date: Fri, 10 Dec 2004 22:23:49 +0100
On Fri, 10 Dec 2004, Monica Gorman wrote:
>Thank You very much. Quark 6.5 worked great. Our script ran the 1st time
>correctly. Problem Solved.
Monica,
you're welcome. :-)
"Problem Solved". You're sure? And what about speed?
Some scripts which ran fine using QXP 4.11 or 5.x will
take much more time when run with QXP 6.x.
But there is hope. Make sure to select the Content tool
when adressing text boxes. And when the user has selected
a box to start with, get a reference to this box, set
selection to null and address the box using the stored
reference.
When the script is creating boxes, then it might be
necessary to set selection to null _each_ time after a box
is created. Else the selected boxes are refreshed and this
slows down execution enormously.
Whenever possible I convert the handlers into script
objects and call them with 'do script'. Getting values
inside is quite easy: define them as global. But getting
them out is tricky. And there are cases when you need to
define variables inside of the script object as global.
Although they are defined and initialized as property.
There are cases when script objects aren't enough to get
some speed. Then you must minimize the window and open
it again when the script has finished.
There are plenty of examples using these techniques in
the optimized Script Menu scripts. You'll find them here:
<http://www.fachhefte.ch> / Click the link "AppleScripts",
then open the folders "mac_os_x_e" and "min_qxp_6_1" and
select the file "Quark_6.x_scripts_e.sit". This Stuffit
archive is 420KB.
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