不是,我是新建图形,在原图中调用"Style-等线体(标准) V"字型,肯定能让字垂直排列。
我的源程序如下:请指正。
Sub main() Dim tsObj As AcadTextStyle Dim textobj As AcadText Dim textString As String Dim insPnt(0 To 2) As Double Dim agnPnt(0 To 2) As Double Dim Height As Double Set tsObj = ThisDrawing.TextStyles.Add("Style-等线体(标准) V") ThisDrawing.ActiveTextStyle = tsObj FontsName = "C:\AutoCAD 2002\Fonts\等线体(标准).shx" ThisDrawing.ActiveTextStyle.fontFile = FontsName FontsName = "C:\AutoCAD 2002\Fonts\等线体(标准)big.shx" ThisDrawing.ActiveTextStyle.BigFontFile = FontsName Height = 1.5 tsObj.Width = 1 textString = "中华人民共和国" 'textobj.StyleName = "Style-等线体(标准) V" insPnt(0) = 100: insPnt(1) = 50: insPnt(2) = 0 Set textobj = ThisDrawing.ModelSpace.AddText(textString, insPnt, Height) 'textobj.Alignment = acAlignmentAligned 'textobj.VerticalAlignment = acVerticalAlignmentTop 'textobj.TextAlignmentPoint = insPnt ThisDrawing.Application.Update '更新数据 ThisDrawing.Application.ZoomExtents '全窗口
End Sub |