request for script or stack

Timothy Miller gandalf at doctorTimothyMiller.com
Wed Jul 27 23:15:27 EDT 2005


Thanks a bunch, Sarah,

I haven't had time to study your script yet. I'm just leaving the 
office, I'll look more carefully tomorrow. But it looks like a big 
improvement on what I've been doing.

At first glance, it looks like it won't recognize when it's 
repeatedly cycling through the same page if there are multiple hits 
on the same page. If it doesn't, I'd like to add that feature, but 
it's a pain in the neck for me to script it. It might be a piece of 
cake for someone else.

If I put find whole in the message box, as in

find whole "Bush, Laura"

I wonder if Rev will consistently search whole as long as I keep 
hitting the return key. HyperCard wouldn't. Okay, it's a stupid 
question, I can find out by trial and error. I hope it does. I'll try 
it tomorrow.

Regarding the "find and replace" window, I have tried several times 
to stop a search with a command-period. It just plain won't stop. 
(Clicking on the glowing red close button at the upper left won't 
stop it either, even though the little X appears when the mouse is 
over it.)

I've noticed other situations in other stacks where command-period 
should stop a script, but it doesn't.

For instance, a command-period won't interrupt a script if an answer 
dialog box is on the screen. It seems like it should. I was getting 
ready to report this to Rev as a bug or an enhancement request. Maybe 
it normally does work that way. I thought it was a Rev feature, or 
maybe a Rev deficiency. Maybe it's another anomaly.

I don't think there's anything in my stacks that would intercept a 
command-period. I'll check again, but I haven't set the cantabort 
property to true in any of my stacks, or the allowInterrupts property 
to false.

I just checked several of my stacks and Rev's "find and replace" 
window. (Is it a stack? Is that why it's so slow?) allowinterrupts is 
true. It's true in all my other stacks, also. Most or all of my 
stacks act as if it is set to false. Meanwhile Rev won't recognize 
the cantAbort property if I try to get it in the msg box. Not sure 
why.

Life just seems to get complicateder and complicateder. All part of 
the fun, I guess.

Thanks again. I'll be interested to read any comments you might have. 
Other script ideas for easier finding are welcome, also.

Cheers,


Tim



>Hi Tim,
>
>>I'm sorry to whine, but I really miss my hyperCard command-F. The 
>>cursor was positioned in the message box to type my search term, 
>>between quotation marks, and away I went. Hit the return key for 
>>the next hit if I don't like the item I just found. Hit the return 
>>key as many times as I want.
>>
>>It worked about the same as typing
>>
>>find "confabulation"
>>
>>in Rev's message box. I think Rev is somewhat slower, but I can 
>>live with that. What I don't like is having to type the whole 
>>darned find command, including the quotation marks.
>
>Here is a script to do it:
>
>  go to cd "Single Line" of stack "Message Box"
>  put "find " & quote & quote into fld "Message Field" \
>    of cd "Single Line" of stack "Message Box"
>  put " select char 7 to 6 of fld " & quote & "Message Field" \
>    & quote & " of cd " & quote & "Single Line" & quote & " of stack " \
>    & quote & "Message Box" & quote into tCmd
>  send tCmd to me in 2 ticks
>
>It doesn't set the hilite in the correct button at the top of the 
>message box & it doesn't set the title, but it gets you to the 
>single line entry, puts in the find and selects between the quotes.
>
>The delay in selecting is required because the message box remembers 
>your last selectedChunk and puts that back, so I have to wait until 
>that has happened before over-riding it.
>
>On my web page <http://www.troz.net/Rev/>, you will find a plugin 
>called "FunKey" that allows you to allocate script snippets to 
>certain function keys. You may find that if you attach this script 
>to a function key, you have exactly what you want :-)
>
>>
>>Rev's command-F find window remains much slower than the Find 
>>command in the message box, even if both searches are restricted to 
>>the same stack and to field text only. I can't imagine why. I just 
>>tested it. I searched for "Gloria" in a fairly bulky stack that 
>>contains a lot of names. Typing find "gloria" in the message box 
>>found four instances almost instantly.
>>
>>Then I tried find "gloria" with Rev's command-F "Find and Replace" 
>>window. I clicked "field text" only, I chose "this stack" only, and 
>>I checked "obey dontsearch properties." It was at least 1000 times 
>>slower, maybe 5000 times slower, or more. And, in 2.6.1, it's still 
>>not possible to abort a search in this window once you start one. 
>>If you accidentally start the wrong search, you could grow a beard 
>>before it was done searching.
>It is just a script, so it can be stopped by Command-period, or 
>whatever you usually use to stop a script.
>
>Cheers,
>Sarah
>
>***************************
>Sarah Reichelt
>sarah at troz.net
>http://www.troz.net/Rev/
>***************************
>
>
>_______________________________________________
>use-revolution mailing list
>use-revolution at lists.runrev.com
>Please visit this url to subscribe, unsubscribe and manage your 
>subscription preferences:
>http://lists.runrev.com/mailman/listinfo/use-revolution




More information about the use-livecode mailing list