易截截图软件、单文件、免安装、纯绿色、仅160KB

flex toolTip样式设置

需要3个文件。一个是样式类,一个样式文件,一个是mxml文件。
●MyToolTip.as
package{
 import mx.core.UITextField;
 import mx.skins.halo.ToolTipBorder;
 import mx.controls.ToolTip;
 public class MyToolTip extends ToolTipBorder {
  
  
  override protected function updateDisplayList(unscaledWidth:Number,
   unscaledHeight:Number):void{
    
    var toolTip:ToolTip = (this.parent as ToolTip);
    var textField:UITextField = toolTip.getChildAt(1) as UITextField;
    textField.htmlText = textField.text;
    
    
    var calHeight:Number = textField.height;
    calHeight += textField.y*2;
    calHeight += textField.getStyle("paddingTop");
    calHeight += textField.getStyle("paddingBottom");
    
    
    var calWidth:Number = textField.textWidth;
    calWidth += textField.x*2;
    calWidth += textField.getStyle("paddingLeft");
    calWidth += textField.getStyle("paddingRight");
    
    super.updateDisplayList(calWidth, calHeight);
   }
 }
}
●style.css
ToolTip{
    font-family:            verdana;
    font-size:              14px;
    color:                  #000000;
    background-color:       #FF00FF;
    background-alpha:       0.85;
    cornerRa


相关文档:

Flex List行背景色

 过去在对DataGrid设置行背景色时,感觉还是挺方便的,只要重写DataGrid的,如下
private var _rowColorFunction:Function;
public function set rowColorFunction(f:Function):void
{
this._rowColorFunction = f;
}
public function get rowColorFunction():Func ......

Flex creationPolicy策略

在Flex中,利用state进行状态和页面的迁移与变换,中间的AddChild IOverride有一个creationPolicy,这个属性有三种设置,分别如下:
AUTO:默认设置,只有在状态改变的时候,即时的生成新增组件;
ALL:在Application加载的时候,就加载了新增的组件,在状态改变的时候显示;
NONE:需要手动的调用该addChild Instance c ......

Flex easingFunction

<?xml version="1.0" encoding="utf-8"?>
<Application xmlns="http://www.adobe.com/2006/mxml"
backgroundGradientColors="[0x000000,0x000000]"
themeColor="#222222"
horizontalAlign="left"
paddingLeft="10" paddingRight="10"
creationComplete="genData();"
viewSourceURL="srcview/index.ht ......

Flex中如何去掉Tree控件默认文件夹图标、叶子节点图标

  .treeStyte{
    selectionColor: #417597;
    /* 去掉默认图标 */
    folderClosedIcon: ClassReference(null);
            folderOpenIcon: ClassReference(null);
   &nbs ......

flex faster and faster

本文介绍一下关于flex性能优化,以及flex生成的的swf大小优化.
1.关掉build automaticly
2.专心做一个项目,开起来一个flex builder
3.用flex builder而不用Eclipse插件,这样不用受其它的插件的影响。
至于后来和数据库的就先不说了,因为水平有限
as3一出来,flex也跟着火一把,目前学习flex的人也越来越多了,但是国内fl ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号