| 
 
	精华活跃值 积分2082违规 印币 鲜花值 在线时间 小时 
 累计签到:281 天连续签到:4 天
 
 |  
 
| Sub CreateArtisticTextInCenter() 
 
 Dim s As Shape
 
 
 Dim i As Integer
 
 
 i = 1
 
 
 ' 遍历选中的形状
 
 For Each s In ActiveSelectionRange
 
 ' 获取形状的中心坐标
 
 Dim centerX As Double
 
 Dim centerY As Double
 
 
 centerX = s.centerX
 
 centerY = s.centerY
 
 
 ' 创建艺术字形状,并设置文本内容为数字
 
 Dim textShape As Shape
 
 Set textShape = ActiveLayer.CreateArtisticText(centerX, centerY, "a" & i & "a", CDRAmericanEnglish, cdrCharSetDefault, "NSimSun", 30, cdrTrue)
 
 'NSimSun为字体
 
 '30为字号
 
 
 textShape.centerX = s.centerX
 
 textShape.centerY = s.centerY
 
 
 i = i + 1
 
 
 Next s
 
 
 End Sub
 可以自己自定义输入前缀,后缀和字体和大小,上面代码是选中图形自动生成序号
 | 
 |