当前位置: 首页 > news >正文

搜索引擎优化方法有哪些windows优化大师值得买吗

搜索引擎优化方法有哪些,windows优化大师值得买吗,wordpress移除评论字段,网站建设 工商注册ArkTS卡片开放了自定义绘制的能力,在卡片上可以通过Canvas组件创建一块画布,然后通过CanvasRenderingContext2D对象在画布上进行自定义图形的绘制,如下示例代码实现了在画布的中心绘制了一个笑脸。 Entry Component struct Card { private c…

ArkTS卡片开放了自定义绘制的能力,在卡片上可以通过Canvas组件创建一块画布,然后通过CanvasRenderingContext2D对象在画布上进行自定义图形的绘制,如下示例代码实现了在画布的中心绘制了一个笑脸。

@Entry
@Component
struct Card {
private canvasWidth: number = 0;
private canvasHeight: number = 0;
// 初始化CanvasRenderingContext2D和RenderingContextSettings
private settings: RenderingContextSettings = new RenderingContextSettings(true);
private context: CanvasRenderingContext2D = new CanvasRenderingContext2D(this.settings);build() {
Column() {
Row() {
Canvas(this.context)
.margin('5%')
.width('90%')
.height('90%')
.onReady(() => {
console.info('[ArkTSCard] onReady for canvas draw content');
// 在onReady回调中获取画布的实际宽和高
this.canvasWidth = this.context.width;
this.canvasHeight = this.context.height;
// 绘制画布的背景
this.context.fillStyle = 'rgba(203, 154, 126, 1.00)';
this.context.fillRect(0, 0, this.canvasWidth, this.canvasHeight);
// 在画布的中心绘制一个红色的圆
this.context.beginPath();
let radius = this.context.width / 3
let circleX = this.context.width / 2
let circleY = this.context.height / 2
this.context.moveTo(circleX - radius, circleY);
this.context.arc(circleX, circleY, radius, 2 * Math.PI, 0, true);
this.context.closePath();
this.context.fillStyle = 'red';
this.context.fill();
// 绘制笑脸的左眼
let leftR = radius / 4
let leftX = circleX - (radius / 2)
let leftY = circleY - (radius / 3.5)
this.context.beginPath();
this.context.arc(leftX, leftY, leftR, 0, Math.PI, true);
this.context.strokeStyle = '#ffff00'
this.context.lineWidth = 10
this.context.stroke()
// 绘制笑脸的右眼
let rightR = radius / 4
let rightX = circleX + (radius / 2)
let rightY = circleY - (radius / 3.5)
this.context.beginPath();
this.context.arc(rightX, rightY, rightR, 0, Math.PI, true);
this.context.strokeStyle = '#ffff00'
this.context.lineWidth = 10
this.context.stroke()
// 绘制笑脸的嘴巴
let mouthR = radius / 2.5
let mouthX = circleX
let mouthY = circleY + (radius / 3)
this.context.beginPath();
this.context.arc(mouthX, mouthY, mouthR, Math.PI, 0, true);
this.context.strokeStyle = '#ffff00'
this.context.lineWidth = 10
this.context.stroke()
})
}
}.height('100%').width('100%')
}
}

 

http://www.shuangfujiaoyu.com/news/50146.html

相关文章:

  • 网站开发jquery做网站用什么编程软件
  • 有哪些做文创产品的网站宁波企业seo推广
  • 深圳 企业网站建设西安做网站
  • 在网站上做网络课堂软件多少钱百度客服中心电话
  • 社区类网站有哪些外链推广软件
  • 化学药品购买网站app软件开发
  • 分享惠网站怎么做外贸营销网站制作公司
  • 简洁大气企业网站欣赏微信营销成功案例8个
  • 新手做网站起步教程海外网站推广优化专员
  • wix做的网站在国内访问不了电商运营推广
  • 青岛海诚互联做网站好吗广东广州重大新闻
  • 网站数据库转移广州现在有什么病毒感染
  • 做网站找什么公司工作宁德市有几个区几个县
  • 韩国男女真人做视频网站优化网站关键词优化
  • 音乐网站建设目标百度竞价排名正确解释
  • 临湘网站建设百度下载软件
  • 怎样建设网站内容店铺推广软文300字
  • 泉山区城乡建设局网站百度网址安全检测
  • 江门网站建设设计app拉新推广平台有哪些
  • 网站强制使用极速模式优化疫情防控 这些措施你应该知道
  • 天津网站建设服务好百度搜索关键词排名靠前
  • 中药网站模板seo分析网站
  • 大连做网站报价湖南网站托管
  • 学设计网站成都网站优化公司
  • php开发一个企业网站价格seo内容优化是什么意思
  • 怎么设置网站的关键字百度关键词搜索引擎排名优化
  • 机关网站建设管理工作自查报告网络营销策略概念
  • 选择邯郸做网站企业宣传网站
  • win7 做网站服务器网络平台怎么创建
  • vs2010做网站前台青岛网站设计公司哪家好