📄 samplecustomsprite.as
字号:
package org.kingda.book.display
{
import flash.display.Sprite;
public class SampleCustomSprite extends Sprite
{
public function SampleCustomSprite() {
//生成三个不同颜色的RectSprite矩形对象
var a:RectSprite = new RectSprite ("A", 0xCDE855);
var b:RectSprite = new RectSprite ("B", 0xF5F6D4);
var c:RectSprite = new RectSprite ("C", 0xA7C520);
//摆放位置
a.x = 100, a.y = 100;
b.x = 120, b.y = 120;
c.x = 140, c.y = 140;
//加入显示列表
addChild(a);
addChild(b);
addChild(c);
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -