[comp.sys.mac.hypercard] HyperCard tip

jgsmith@watson.bcm.tmc.edu (James G. Smith) (10/18/89)

I just got Danny Goodman's book for developers, and he specifically 
mentioned a bug about buttons which do something with hilited text.

Buttons which auto-hilite cannot work on selected text, because when you
click on the button, you de-select the text.  I've already noticed this
problem and got around it this way:

on mouseUp
  global selectionBox -- the global variable to store the selection in
  --use selectionBox to replace what you would have done to the selection
   .
end mouseUp

on mouseEnter
  global selectionBox
  put the selection into selectionBox
end mouseEnter

I hope this does not require further explanation.  Please e-mail any comments
(including "wow, that's great", or "Everyone knew that long ago"...I'm still
trying to get a feel for where I am in the HyperCard world.

*
(Jimmy G)
.