Flash 8 支持的HTML标签和用法
来源:互联网 发布:米格29知乎 编辑:程序博客网 时间:2024/06/14 21:40
(1)Flash 8 支持的HTML标签
1、 超链接标签
属性:
href—— 链接地址
target——目标窗口,可取值为_blank,_parent,_self,_top
例:
my_txt.htmlText=”开明教育”
2、 粗体标签
|例:
my_txt.htmlText=”粗体”
3、
换行标签
例:
my_txt.htmlText=”第一行
第二行”
4、 字体标签
属性:
color——字体颜色,格式#RRGGBB
face——字体,可以是单个字体或字体列表,字体名称
size——字体大小,单位像素,数字
例:
my_txt.htmlText=”用HTML字体标签的效果”
5、 斜体标签
例:
my_txt.htmlText=”这里是斜体”
6、
例:
my_txt.htmlText=”Sports:
”
注意,文本属性要选中“多行”。
不支持
- 和
- , 你可以把它们放在动态或输入框文本区内来格式化文字.
Flash播放器版本7和后续版本也支持标签. 你可以在文本区嵌入图片(JPEG,GIF,PNG)和SWF文件.
Flash播放器自动把文字环绕在图片周围, 就像浏览器显示HTML页面时把文字环绕在图片周围那样.
Adobe Flash Player supports a subset of standard HTML tags such as
and
- , which you can use to style text in any dynamic or input text field. Text fields in Flash Player 7 and later also support the tag, which lets you embed image files (JPEG, GIF, PNG), SWF files, and movie clips in a text field. Flash Player automatically wraps text around images embedded in text fields in much the same way that a web browser wraps text around embedded images in an HTML page.
HTML tags supported by Adobe Flash CS3 Professional
The following HTML tags are supported by Adobe Flash CS3 Professional. Optional tag attributes appear in brackets.引用内容
Anchor:
Bold:
Font: < font [color="#xxxxxx"] [face="Type Face"] [size="Type Size"]>
Italic:
Paragraph:Underline:
Break:
Image: The tag lets you embed external image files (JPEG, GIF, PNG), SWF files, and movie clips inside text fields and TextArea component instances.
List Item: ordered and unordered lists (
- and
- tags) are not recognized by Flash Player, so they do not modify how your list is rendered. All list items use bullets.
Span: The tag is available only for use with CSS text styles.
TextFormat: The tag lets you use a subset of paragraph formatting properties of the TextFormat class within HTML text fields, including line leading, indentation, margins, and tab stops. You can combine tags with the built-in HTML tags.引用内容
Additionally, Flash Player supports HTML entities:< < (less than)
> > (greater than)
& & (ampersand)
” ” (double quotes)
' ‘ (apostrophe, single quote)程序代码
如何使用Flash MX 2004所支持的HTML标签:
第一步:新建一个FLASH文档,在舞台上插入一个动态文本框,并命名为 my_txt 。
第二步:在第一帧加入AS代码:
my_txt.html = true; //指定该文本字段为HTML文本字段。
my_txt.htmlText=”闪吧“;
//引用HTML的超链接标签。
Flash MX 2004所支持的HTML标签:
超链接标签
属性:href: 链接地址
target: 目标窗口 可取值为_blank,_parent,_self,_top。
例:
my_txt.htmlText=”闪吧“;
粗体标签
例:
my_txt.htmlText=” 闪吧“;
换行标签
例:
my_txt.htmlText=”闪吧
“;
字体标签
属性:color:字体颜色,格式#RRGGBB。
face:字体,可以是单个字体或字体列表。
size:字体大小
- 标签
7、
段落标记
属性:
align——对其方式,可取值left、right、center
class——应用一个css样式类
例:
my_txt.htmlText=”
右对齐
左对齐
”
注意,文本属性要选中“多行”。本例假设css类title和body已存在。
8、 标签
说明:对位于该标签内所有文本应用css样式,只有在定义了css对象后有效。
属性:class——应用一个css样式类。
例:
my_txt.htmlText=”应用CSS样式类
注意,本例假设css类body已存在。
9、 下划线标签
例:
my_txt.htmlText=”添加下划线
两个特殊的标签:
10、 图像标签
说明:这个标签的功能不仅仅是在文本框中插入图片,还可以插入SWF和MovieClip。
属性:
src—— 要加载的JPG或SWF的URL,或是MC的链接ID,这个属性是必要的,其他属性则可选。
注意:Flash不支持progressive格式的JPG。
id——指定嵌入了JPG,SWF或MovieClip的电影剪辑的名称。
width——图片/动画宽度。
height——图片/动画高度。
align——对其方式,可取值:left,right,默认为left。
hspace——文本环绕图时水平方向上与图片的空隙。
vspace——文本环绕图时垂直方向上与图片的空隙。
11、 文本格式标签
说明:这个标签可以让你直接应用一些TextFormat对象的属性到文本中。
属性:
blcokIndent: 段落缩进大小,单位像素。
indent: 段落首行缩进大小,单位像素。
leading: 文本行间距,单位像素。
leftmargin: 文本左边距,单位像素。
rightmargin: 文本右边距,单位像素。
tabstops: 表格划分,单位像素。
注意:关于属性tabstops:它的值是一个数组,用来表示表格的列划分情况。
在文本中用转义字符\t将输出位置移动到下一个制表位。
例:
tabField=”姓名\t性别\t年龄\t
”;
tabRecord1=”唐家齐\t男\t21\t
”;
tabRecord2=”张晓明\t女\t18\t
”;
txt=”” + tabField + tabRecord1 + tabRecord2 + “”;
(2)在 Flash 8 如何使用HTML标签
第一步:新建 Flash 文档,在舞台上创建一个动态文本框,设定实例名称为my_txt 。
第二步:在第一帧加入AS代码:
my_txt.html = true; //指定该文本字段为HTML文本字段。
my_txt.htmlText= “开明教育“; //引用HTML的超链接标签。
Flash CS3里可用的HTML标签和注意事项
Adobe Flash播放器支持一组标准HTML标签, 例如
和
- Flash 8 支持的HTML标签和用法
- Flash 8 支持的HTML标签和用法
- Flash MX 2004 支持的HTML标签
- Flash CS3里可用的HTML标签和注意事项
- html标签的用法
- onmouseover支持的html标签
- TextView支持的Html标签
- HTML基本标签和用法
- Html类支持的HTML标签
- Html类支持的HTML标签
- Html的object标签的相关属性和用法
- html的marquee标签用法
- HTML meta标签的用法
- html标签meta的用法
- html标签meta的用法
- Html标签中Alt和title的用法
- 【html】html 的基本标签的用法
- HTML标签中li的用法 IE6,7,8和FF没有问题
- ScrollView中若嵌套有滑动的控件(如:WebView,ListView或GridView),另外该界面中还有其它的控件时,界面不显示最上面控件的问题。
- Android Memory Management, OutOfMemoryError
- mapreduce编程过程
- 如何在一个iframe中给父窗体的另一个iframe中的div设值
- 为什么只能跑7天?
- Flash 8 支持的HTML标签和用法
- “房地产软文”有人看吗?
- 邻居的甘榜鸡蛋
- 关于C++ const 的全面总结
- linux做的小练习分享一下哈~
- 写好软文的一些思路
- C++常用开发工具
- sharepont2010 审批母版页
- 选择排序和插入排序