Text in imageSource

Jim Ault JimAultWins at yahoo.com
Thu Jan 26 04:44:48 EST 2006


On 1/26/06 1:23 AM, "Jim Ault" <JimAultWins at yahoo.com> wrote:

> My elapsed time is 3 ticks and the result is a midpoint  of having six
> variables each containing the same 'star.png' html string.  Should be easy
> to sort and combine these how you need it.
Update:
Actually, if I don't include the time it takes my example script to build
the 700+ lines, the filtering only takes ........

one tick!  ... that's right, Rev can do all that filtering and variable
assignment in less than 2 ticks.

Sorta makes you want to build some useful software that relies heavily on
the filter command, eh?

Jim Ault
Las Vegas
Mac OSX 10.4.2  Rev 2.6.1  G5 dual 2.0

--------------------original script below   ----------------
> <paste into a container, or remove the comments>
> 
> on testt
>   put the ticks into startt
>   --building the 700+ lines to work with below
>   repeat until the number of lines in wholeThang > 700
>     put cr&"<img src=" & quote & "Star.png" & quote & "><img src=" &quote &
> "Dash.png" & quote & \
>         "><img src=" & quote & "Dash.png" & quote & "></p>" after of
> wholeThang
>     put cr&"<img src=" & quote & "Star.png" & quote & "><img src=" &quote &
> "Star.png" & quote & \
>         "><img src=" & quote & "Dash.png" & quote & "></p>" after of
> wholeThang
>     put cr&"<img src=" & quote & "Star.png" & quote & "><img src=" &quote &
> "Star.png" & quote & \
>         "><img src=" & quote & "Star.png" & quote & "></p>" after of
> wholeThang
>     put cr&"<img src=" & quote & "Dash.png" & quote & "><img src=" &quote &
> "Dash.png" & quote & \
>         "><img src=" & quote & "Dash.png" & quote & "></p>" after of
> wholeThang
>   end repeat
>   
>   --parsing to get 6 groups then doing a count
>   put wholeThang into grp5
>   filter grp5 with "*star*star*star*star*star*"  -- 5
>   filter wholeThang without "*star*star*star*star*star*"
>   put wholeThang into grp4
>   filter grp4 with "*star*star*star*star*"  -- 4
>   filter wholeThang without "*star*star*star*star*"
>   put wholeThang into grp3
>   filter grp3 with "*star*star*star*"  -- 3
>   filter wholeThang without "*star*star*star*"
>   put wholeThang into grp2
>   filter grp2 with "*star*star*"  -- 2
>   filter wholeThang without "*star*star*"
>   put wholeThang into grp1
>   filter grp1 with "*star*"  -- 1
>   filter wholeThang without "*star*"
>   put wholeThang into grp0
>   
>   repeat with x = 0 to 5
>     do "get the number of lines in grp"&x
>     put ( it & " ["&x&"]" & cr) after output
>   end repeat
>   answer output &cr & (the ticks - startt) & " ticks elapsed"
>   breakpoint
> end testt






More information about the use-livecode mailing list