内容简介:本节主要介绍了Flex DataGrid 伪合并单元格实现思路,需要的朋友可以参考下
<?xml version="1.0" encoding="utf-8"?> <s:MXDataGridItemRenderer xmlns:fx="http://ns.adobe.com/mxml/2009" xmlns:s="library://ns.adobe.com/flex/spark" xmlns:mx="library://ns.adobe.com/flex/mx" width="100%" height="100%" autoDrawBackground="false" creationComplete="mxitemrenderer1_creationCompleteHandler(event)" > <s:layout> <s:VerticalLayout verticalAlign="middle" horizontalAlign="center"/> </s:layout> <fx:Script> <![CDATA[ import mx.collections.ArrayCollection; import mx.controls.Text; import mx.events.FlexEvent; protected function mxitemrenderer1_creationCompleteHandler(event:FlexEvent):void { var txt1:String = lbl.text.split(",")[0]; var txt2:String = lbl.text.split(",")[1]; lbl1.text = txt1; lbl2.text = txt2; } ]]> </fx:Script> <fx:Declarations> <!-- 将非可视元素(例如服务、值对象)放在此处 --> </fx:Declarations> <s:Label id="lbl" text="{dataGridListData.label}" visible="false" height="0"/> <s:VGroup id="vp" width="100%" height="100%" gap="2" > <s:Label id="lbl1" color="0x000000" textAlign="center" verticalAlign="middle" width="100%"/> <mx:HRule width="100%" chromeColor="0x999999" alpha="0.3"/> <s:Label id="lbl2" color="0x000000" textAlign="center" verticalAlign="middle" width="100%"/> </s:VGroup> </s:MXDataGridItemRenderer>
以上就是本文的全部内容,希望对大家的学习有所帮助,也希望大家多多支持 码农网
猜你喜欢:- Flex DataGrid 伪合并单元格思路及代码
- 记一次用iview实现表格"合并"单元格的具体操作
- 分组字符合并SQL语句 按某字段合并字符串之一(简单合并)
- git 的合并原理(递归三路合并算法)
- git 合并策略
- 算法 - 合并若干有序文件
本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们。
Dive Into Python
Mark Pilgrim / Apress / 2004-11-5 / GBP 31.49
Python is a new and innovative scripting language. It is set to replace Perl as the programming language of choice for shell scripters, and for serious application developers who want a feature-rich, ......一起来看看 《Dive Into Python》 这本书的介绍吧!