Page 1 of 1

Equivalent of XCDM balloons in Livecode

Posted: Sun Apr 27, 2014 1:36 pm
by legallou
I am moving 1991 Hypercard stack using XCDM balloons. By what you replace this function in Livecode ?

Re: Equivalent of XCDM balloons in Livecode

Posted: Sun Apr 27, 2014 2:57 pm
by dunbarx
Hi.

Balloons? I am an old-time HC guy, and still code today. What is the name of the XCMD?

Is it possible that the "toolTip" property in LC is what you had in mind?

Craig NEwman

Re: Equivalent of XCDM balloons in Livecode

Posted: Sun Apr 27, 2014 5:52 pm
by legallou
Thank a lot, the "toolTip" property is the equivalent of XCDM call « balloons » that was calling system 7 balloons.

Re: Equivalent of XCDM balloons in Livecode

Posted: Thu May 01, 2014 1:08 pm
by legallou
My stack is multi-language, do you know utility script and/or organisation recommendation to use toolTip multi-language ?

Re: Equivalent of XCDM balloons in Livecode

Posted: Thu May 01, 2014 2:10 pm
by Klaus
Hi legallou,
legallou wrote:My stack is multi-language, do you know utility script and/or organisation recommendation to use toolTip multi-language ?
not sure what you want exactly, but you can set tooltips via script.
So use "opencard" or whatever to "populate" your tooltips with the correct language:
...
set the tooltip of btn "the_important_button" to AnyStringHere
set the tooltip of btn "the_other_button2" to "Ce n'est pas un ballon!"
...

Best

Klaus

Re: Equivalent of XCDM balloons in Livecode

Posted: Thu May 01, 2014 3:13 pm
by legallou
Yes I test the command « set the toolTip ...»
set the toolTip of the target to empty -- Need to empty first
set the toolTip of the target to theText

I have done in 1995 a script that read a file with this structure and put in a personal Help field define in first line :

<Author>,card,menu1,, --------------------------------------
Click on one 'author name' of the scrolling field
to go to the 'author' window
<home>,card,menu1,, --------------------------------------------
click into the field 'home'
to
go to 'home' stack

I of course may use it again, but I was asking if in LiveCode, a standard method, script (more elegant) exist.

Re: Equivalent of XCDM balloons in Livecode

Posted: Thu May 01, 2014 4:26 pm
by Klaus
Hi legallou,
legallou wrote:...
I of course may use it again, but I was asking if in LiveCode, a standard method, script (more elegant) exist.
not sure I understand you correctly, but Livecode only provides the means, we have to supply the data in whatever form.
Of course you can use a data structure like this to populate tooltips, too!


Best

Klaus

Re: Equivalent of XCDM balloons in Livecode

Posted: Thu May 01, 2014 5:18 pm
by legallou
When I say « more elegant script » I was thinking not only a standard method that I missed in LiveCode documentation, but also any add-on that somebody may have developed.

Re: Equivalent of XCDM balloons in Livecode

Posted: Thu May 01, 2014 6:33 pm
by FourthWorld
To add to Klaus' note, the specific strings can be stored in custom property sets, perhaps a different prop set for each language, so you can do things like:

set the tooltip of btn 1 to the uUSEng["OKbtn"] of this stack
set the tooltip of btn 1 to the uChinese["OKbtn"] of this stack

Also, FWIW, you can control the delay of the tooltips by setting the toolTipDelay global property; setting it to 0 (zero) turns them off.