How to draw a line between objects or letters?
DunbarX at aol.com
DunbarX at aol.com
Fri Jun 5 16:50:04 EDT 2009
William.
Nothing is too difficult. I think I know what you need now.
You have two fields with text, and a button with the following script;
on mouseUp
if there is a graphic "tLine" then delete graphic "tLine"
set cursor to cross
wait until the mouseClick
put the clickLoc into tLoc1
click at the clickLoc
put the clickChar into tChar1
wait until the mouseClick
put the clickLoc into tLoc2
click at the clickLoc
put the clickChar into tChar2
if tChar1 = tChar2 then
create graphic
set the name of the last graphic to "tLine"
set style of graphic tLine to "line"
set points of graphic tLine to tLoc1 & return & tLoc2
else
answer "UH OH, try again"
end if
end mouseUp
Craig Newman
**************
We found the real ‘Hotel California’ and the ‘
Seinfeld’ diner. What will you find? Explore WhereItsAt.com.
(http://www.whereitsat.com/#/music/all-spots/355/47.796964/-66.374711/2/Youve-Found-Where-Its-
At?ncid=emlcntnew00000007)
More information about the use-livecode
mailing list