- 积分
- 15190
- 明经币
- 个
- 注册时间
- 2003-9-13
- 在线时间
- 小时
- 威望
-
- 金钱
- 个
- 贡献
-
- 激情
-
|
发表于 2003-12-28 15:32:00
|
显示全部楼层
Sub textfont()
Dim typeface As String
Dim textbold As Boolean
Dim textitalic As Boolean
Dim textcharset As Long
Dim textpfamily As Long
ThisDrawing.ActiveTextStyle.GetFont typeface, _
textbold, textitalic, textcharset, textpfamily
MsgBox "当前字体为:" & typeface
typeface = "隶书" '在此设置字体!!!!!!!!!
ThisDrawing.ActiveTextStyle.SetFont typeface, _
textbold, textitalic, textcharset, textpfamily
ThisDrawing.Regen acActiveViewport
Dim textobj As AcadText
Dim textstring As String
Dim textheight As Double
Dim inspoint(0 To 2) As Double
textstring = "关章洋"
inspoint(0) = 10
inspoint(1) = 10
inspoint(2) = 0
textheight = 5
Set textobj = ThisDrawing.ModelSpace.AddText(textstring, inspoint, textheight)
ThisDrawing.Application.ZoomExtents
End Sub |
|