wytxl2002 发表于 2006-1-27 10:53:00

postbing 发表于 2006-2-5 22:23:00

<P>不知楼主这几个数有什么特定的要求?</P>
<P>本人有二种方式供参考</P>
<P>1.如果这几个数要是成一定的比例的话你可采取获得当前标注的字高做一个参考再算出其它的几个数,</P>
<P>2.如果这几个数没有什么规律的话你可以把这几个数设成全局变量,这样只样第一次输入了这几个数,以后键入这个命令的时候先检测一下这个数值是否为空,</P>
<P>如果有什么不明白的请联系:</P>
<P>E_MAIL:POSTBING@163.COM</P>
<P>QQ:158042947</P>

xyp1964 发表于 2006-2-12 20:47:00

试试:(defun C:BUBBLE (/ cmo bmo ars cr ts sp ep ang dist ar cpl textw)
(setq cmo (getvar "CMDECHO")
bmo (getvar "BLIPMODE")
)
(setvar "CMDECHO" 0)
(setvar "BLIPMODE" 0)
(setq ars 500    ;(getdist "\n请指定箭头尺寸: "))
cr250    ;(getint "\n请指定指标圆球半径: "))
ts(- (* cr 2) 200);(getstring "\n请指定文字高度: "))
)
(while (setq sp (getpoint "\n请点取欲放置箭头的位置<退出>: "))
    (setq ep (getpoint sp "\n请放置指标圆球位置: ")
   ang (angle sp ep)
   dist (distance sp ep)
   ar (* 0.3 ars)
   cpl (polar sp ang (+ cr dist))
   textw (getstring "\n请指定指标圆球内的编号: ")
    )
    (command "line" sp ep "")
    (command "pline"
      sp
      "w"
      "0"
      ar
      (polar sp ang ars)
      ""
    )
    (command "circle" cpl cr)
    (command "text" "m" cpl ts 0 textw)
)
(setvar "CMDECHO" cmo)
(setvar "BLIPMODE" bmo)
(princ)
)

wytxl2002 发表于 2006-2-15 10:57:00

页: [1]
查看完整版本: 请各位网友帮忙!