• 首页
  • 动态
  • 案例
  • 引擎社区
  • API
  • 文档
  • 示例
  • 引擎下载

大约有 267 项符合查询结果, 库内数据总量为 31,560 项。 (搜索耗时: 0.0041 秒)

81. laya.display.Graphics_API3.0 [ 76%]

...wCurves drawEllipse drawImage drawLine drawLines drawPath drawPie drawPoly drawRect drawTexture drawTextures drawTriangles fillBorderText fillText fillTexture getBounds loadImage removeCmd restore rotate save scale strokeText transform translate Constructors constructor new Graphics(): Graphics Defi...

来源: Laya3.0_api 发布时间: 20231115

82. 鼠标交互-自定义事件 [ 75%]

... Laya.Sprite, Event = Laya.Event; this.sp = new Sprite(); this.sp.graphics.drawRect(0, 0, 200, 200, "#D2691E"); this.sp.pivot(100, 100); this.sp.x = Laya.stage.width / 2; this.sp.y = Laya.stage.height / 2; this.sp.size(200, 200); Laya.stage.addChild(this.sp); this.sp.on(ROTATE, this, this.onRotate);...

来源: Laya2.0_示例 发布时间: 20251130

83. [LayaAirIDE2]富文本:HtmlDivElement是否支持垂直居中? [ 75%]

...n>"; Laya.stage.addChild(html); var sp = new Laya.Sprite(); sp.graphics.drawRect(0, 0, 300, 30, null, "#999999"); Laya.stage.addChild(sp); var sp2 = new Laya.Sprite(); sp2.graphics.drawRect(0, 30, 300, 30, null, "#999999"); Laya.stage.addChild(sp2); 2025-11-13 1 1 分享 微博 QZONE 微信 为...

来源: Laya_社区 发布时间: 20250906

84. Tween回调方法里如何带参数? [ 74%]

...例子我们看下 测试代码: var sp:Sprite=new Sprite(); sp.graphics.drawRect(0,0,100,100,"#FF0000"); Laya.stage.addChild(sp); Tween.to(sp,{x:300,y:300,alpha:0.5},1000,null,Handler.create(this,function():void { sp.destroy(); })); Complete事件你没写错,就是那么写的     2017-06-08...

来源: Laya_社区 发布时间: 20170608

85. 计时器-延迟执行 [ 74%]

...n(label) { var w = 300, h = 60; var button = new Sprite(); button.graphics.drawRect(0, 0, w, h, "#FF7F50"); button.size(w, h); button.graphics.fillText(label, w / 2, 17, "20px simHei", "#ffffff", "center"); return button; } function onDecreaseAlpha1(e) { //移除鼠标单击事件 button1.off(Event....

来源: Laya_示例 发布时间: 20251130

86. 新手引导在ios浏览器表现异常 [ 74%]

...   let sp = new Laya.Sprite();             sp.graphics.drawRect(0,0,Laya.stage.width,Laya.stage.height,"#FFFFFF");             Laya.stage.addChild(sp);              let guideView = new MazeGuideView();             guideView.zOrder = MazeC...

来源: Laya_社区 发布时间: 20200119

87. Sprite生成的mask对Sprite作用时显示不正确 [ 73%]

...let miniMap = new Laya.Sprite(); miniMap.autoSize = true; miniMap.graphics.drawRect(0,0,100,100, '#000000'); let mapMask = new Laya.Sprite(); mapMask.autoSize = true; mapMask.graphics.drawRect(0,0,miniMap.width,miniMap.height, '#ff0000'); miniMap.mask = mapMask; Laya.stage.addChild(miniMap) 2018-11-...

来源: Laya_社区 发布时间: 20181101

88. 多重遮罩显示异常 [ 73%]

...{ super(); this.init(); } init() { let bg = new Laya.Sprite(); bg.graphics.drawRect(0, 0, 500, 500, '#aaa'); this.addChild(bg); this.panel = new Laya.Panel(); this.panel.width = 500; this.panel.height = 500; this.panel.vScrollBarSkin = ''; this.panel.hScrollBarSkin = ''; this.addChild(this.panel); l...

来源: Laya_社区 发布时间: 20210427

89. 计时器-延迟执行 [ 73%]

...0; let button = new Sprite(); Laya.stage.addChild(button); button.graphics.drawRect(0, 0, w, h, "#FF7F50"); button.size(w, h); button.graphics.fillText(label, w / 2, 17, "20px simHei", "#ffffff", "center"); return button; } onDecreaseAlpha1(e) { const Event = Laya.Event; //移除鼠标单击事件 t...

来源: Laya2.0_示例 发布时间: 20251130

90. 如何给List添加一个自适应高度的背景颜色? [ 73%]

... 1 个回复 Monica - 知识达人 赞同来自: sfsmmc 用list.graphics.drawRect()绘制即可 2017-08-15 1 9 分享 微博 QZONE 微信 为什么被折叠? 0 个回复被折叠 该问题目前已经被锁定, 无法添加新回复 发起人 sfsmmc 相关问题 两个对象new了一个相同的对...

来源: Laya_社区 发布时间: 20170815