MouseLeave and linked text question: 2nd try
mdswindell at charter.net
Sat Feb 19 10:31:30 EST 2005
I posted this yesterday but it may have got lost in the shuffle. I'm
really hoping someone might explain the following scenario to me...
what message (besides mouseMove) is sent to Revolution when the
hovering mouse moves off a chunk of linked text?
Begin forwarded message:
> From: Mark Swindell <mdswindell at charter.net>
> Date: February 18, 2005 12:48:26 PM PST
> To: How to use Revolution <use-revolution at lists.runrev.com>
> Subject: mouseLeave and linked text question
> Reply-To: How to use Revolution <use-revolution at lists.runrev.com>
> Can someone explain the following? In the script below, in the first
> if/then structure, the mouse moving away from a piece of linked text
> causes the backgroundColor of that linked text to reset to empty. But
> the mouse is only moving off the linked text, not out of the field.
> This makes me think a piece of linked text is a control which receives
> a mouseLeave message. Is this correct?
> But then with the repeat structure below that, only by the mouse
> actually leaving the field does the backgroundColor of all lines reset
> to empty. Which leads me to think that the linked text it was
> hovering over was not a control.
> How does this work?
> on mouseLeave
> -- unhighlight any currently highlighted text:
> if storedHilitedChunk is not empty then
> do "set the backgroundColor of" && \
> storedHilitedChunk && "to empty"
> put empty into storedHilitedChunk
> end if
> repeat with y = 1 to 3
> repeat with x = 1 to the number of lines of field y
> set the backgroundColor of line x of field y to empty
> end repeat
> end repeat
> pass mouseLeave
> end mouseLeave
More information about the Use-livecode