【黑羽翔天】重磅献礼!KToolTip发布beta版!






(欢迎转载 ^ ^,但请写上出处,和保留到本文的超链接,本文的链接是:
http://www.kingda.org/archives/kingda/2006/05/ktooltipbeta.html#more )
主要的代码在5月1日前就写的差不多了,但一直回来懒得写帮助和作例子。^ ^
今天看到aw在Blueidea的回帖,心中大惭,晚上吃完饭后,立马做到现在搞定。
目前发布版本是0.5Beta。

主要特色:
1.使用简单,管理大量tooltips方便。为从外部xml导入tooltips带来极大方便。适合大项目。
2.支持V2组件的Tooltip显示,尤其是特殊组件 TextArea,Combobox等
3.支持MovieClip的Tooltip显示,原有onRollOver功能正常保留.
4.四角落判断
5.极其容易更换Tooltip皮肤。

文件下载&使用手册如下:

下载地址:
点击下载
安装方法请参考:
http://www.kingda.org/archives/kingda/2006/04/flash.html#more

特色 Features:
支持V2组件和剪辑,不覆盖原有的onRollOver函数,皮肤更换简单,支持html格式 tooltip,低CPU耗用。
a. support UIComponent and MovieClip
b. preserve the origin onRollOver event.
c. very easy to customize Tooltip skin, even to a Flash beginner.
d. support html tooltips.
e. optimized for low CPU consuming.
Instructions:
1 When installed, Drag the KToolTip component from the component panel into the library of your fla file.
2 write “import org.kingda.tools.KToolTip;” at the first line of the frame. or at the first line of your class file.
3 if you want make a tooltip for a movieclip or UIComponent. just write
KToolTip.add(yourmovieclip, "your tooltip");
4 Test movie, you got it.
If you want to donate, click here.
 


帮助:
1 拖动KToolTip组件到库中
2 在fla文件第一幀写上 import org.kingda.tools.KToolTip; 如在类class中使用,在第一行写import org.kingda.tools.KToolTip;写一次即可。
3 對组件UIComponent或者MovieClip加Tooltip的話,只要写
KToolTip.add(组件或MovieClip名称,“ToolTip内容”);

 


如何定制皮肤
tootip_mc_skin.gif
a.根据图片提示创建一个 皮肤mc,设置好linkID.
b.要换皮肤时,打
KToolTip.setup (SkinMovieClipLinkageID, true, 100);
c. 搞定.
皮肤MC例子:
下载Tooltips皮肤MC例子


其他API § other APIs:
//参数: 皮肤MC的链接ID,是否显示Tooltip,Tooltip的Alpha值
KToolTip.setup (SkinMovieClipLinkageID:String, isEnable:Boolean, TooltipsAlpha:Number)

//参数: 要添加tooltip的MC引用,tooltip的字符串值,(支持html)
//修改tooltip也是用这个,会自动覆盖
KToolTip.add(targetMovieClip:MovieClip, toolTip:String)

//删除
KToolTip.remove(targetMovieClip:MovieClip)

//重置
KToolTip.reset()

//trace all tips in OutPut panel, and return an array of Objects, Array[i].mc_target:MovieClip, Array[i].mc_str:String
KToolTip.getAllTips()

www.kingda.org
e-mail:kingda1980@yahoo.com
note:
If you use KTooltip, a credit mc will show at the bottom of your swf about a few seconds.
If you want no_credit_mc version, please mail me : kingda1980@yahoo.com