flex 常用元标签讲解
Flex
引入了元数据标签的概念,大多数人都使用过的
[Bindable]
标签便是其中的
meta tag
之一,它在代码中的作用就是向编译器提供如何编译程序的信息。实际上,这些标签并没有被编译到生成的
SWF
文件中,而只是告诉编译器如何生成
SWF
文件。
adobe
官网
http://livedocs.adobe.com/flex/3/html/help.html?content=metadata_3.html详细讲解了
16种
meta
的使用,简单如下表所示。
Tag
Description
[ArrayElementType]
Defines the allowed data type of each element of an Array.
[Bindable]
Identifies a property that you can use as the source of a data
binding expression.
[DefaultProperty]
Defines the name of the default property of the component when you
use the component in an MXML file.
[Deprecated]
Marks a class or class element as deprecated so that the compiler
can recognize it and issue a warning when the element is used in an
application.
[Effect]
Defines the MXML property name for the effect.
[Embed]
Imports JPEG, GIF, PNG, SVG, and SWF files at compile time. Also
imports image assets from SWC files.
[Event]
Defines the MXML property for an event and the data type of the
event object that a component emits.
[Exclude]
Omits the class element from the Flex Builder tag inspector. The
syntax is as follows:[Exclude(name="label",
kind="property")]
[ExcludeClass]
Omits the class from the Flex Builder tag inspector. This is
equivalent to the @private tag in ASDoc when applied to a class.
[IconFile]
Identifies the filename for the icon that represents the component
in the Insert bar of Adobe Flex Builder.
[Inspectable]
Defines an attribute exposed to component users in the attribute
hints and Tag inspector of Flex Builder. Also limits allowable values of the
property.
[InstanceType]
Specifies the allowed data type of a property of type
IDeferredInstance.
[NonCommittingChangeEvent]
Identifies an event as an interim trigger.
[RemoteClass]
Maps the ActionScript
相关文档:
flex中背景图片平铺
我们需要一个 degrafa 的组件
已经上传好了.
然后把下载的swc放到项目的libs中
在页面css种这样写就可以了
Application {
background-image: Embed("assets/images/the_image_goes_here.png");
background-r ......
用Accordion组件的时候发现,child展开之后再点击的时候没有相应.
然后习惯性的Google发现解决方法大致是自定义一个组件...
感觉为了一个小功能重写有点 杀鸡用牛刀的感觉.
于是仔细想了下,发现其实只需要指定header的itemRenderer即可:
上代码 headerRenderer="com.MyAccHeader"
MyAccHeader:
package com
{
......
Adobe Flash Builder 4 简体中文正式版 下载:
http://subject.csdn.net/adobedownload/index.html
使用相关的域,利用Adobe Livecycle Designer创建一个PDF模组,以XML节的名称(与PDF模组中的域的名称匹配)向PDF远程对象发送XML数据,然后您的Flex应用程序就会打开PDF, 或将PDF文件放入您的webserv ......
String userId = request.getParameter("userId");
System.out.println(userId);
response.setCharacterEncoding("UTF-8");
//response.getWriter().println("hello world -- 我爱你。。。");
String xml = "<user>" +
"<username>涛哥</username>" +
"</user>";
respon ......