Sorting a large field of data

Scott Rossi scott at tactilemedia.com
Sun Mar 9 22:55:24 EDT 2008


On 3/9/08 5:24 PM, "David Coker" <davidocoker at gmail.com> wrote:

>>>> without locking the screen....
> 
> I'm not I understand exactly *how* to lock the screen before doing my
> processing and maybe more importantly, what effect does that have on
> performance?

How:  in your code, script "lock screen"
See the docs under "lock screen" which provides an explanation of what and
why.

In general, you lock the screen do this to prevent Rev from updating the
display every time you change something that affects the screen display
(changing text, graphics, object positions, painting, drawing, etc), thereby
gaining small to significant performance boost.  As suggested in your case,
it is usually better practice to update the contents of a text field by
loading the field's contents into a variable, modifying the data in the
variable, and then dumping the variable back into the field.  Repeat loops,
replace actions, etc usually achieve faster performance by working with
variables, as opposed to directly manipulating text in objects.

One time actions like changing the color or size of one object will not see
any benefit from locking the screen, but changing the color/size of 10,000
objects could gain a significant increase in speed/performance.

Regards,

Scott Rossi
Creative Director
Tactile Media, Multimedia & Design





More information about the use-livecode mailing list