コード例 #1
0
ファイル: GoatText.cs プロジェクト: yangfancoming/GoatAutoCAD
        public void text1()
        {
            DBText dbText = new DBText();

            // 文字内容
            dbText.TextString = "我是单行文字~";
            // 文字高度
            dbText.Height = 100;
            // 插入点
            dbText.Position = Point3d.Origin;
            // 旋转角度
            dbText.Rotation = Math.PI * 0.1;
            // 是否在 X/Y 轴 镜像
            dbText.IsMirroredInX = false;
            dbText.IsMirroredInY = false;
            // 水平对齐模式
            dbText.HorizontalMode = TextHorizontalMode.TextCenter;
            // 垂直对齐模式
            dbText.VerticalMode = TextVerticalMode.TextTop;
            // 对齐点
            dbText.AlignmentPoint = dbText.Position;
            dbText.AddToCurrentSpace();
        }