本帖最后由 ljpnb 于 2024-1-27 22:04 编辑
- ;;修改了一下
- (defun c:tt (/ s_dis str)
- (if (null (type c:cal))
- (cond
- ((findfile "GEOMCAL.CRX") (ARXLOAD "GEOMCAL.CRX"))
- ((findfile "GEOMCAL.ARX") (ARXLOAD "GEOMCAL.ARX"))
- )
- )
- (command ".STRETCH" (ssget) "")
- (command (setq BasicPoint (getpoint "\n指定基点:")))
- (if (= nil s_dis_all)
- (progn
- (setq s_dis_all (cal (getstring "\n输入拉伸距离<>:")))
- (command "non" s_dis_all)
- )
- (progn
- (setq str (getstring
- (strcat "\n输入拉伸距离<" (rtos s_dis_all 2 4) ">:")
- )
- )
- (if (= str "")
- (setq s_dis s_dis_all)
- (setq s_dis (cal str))
- )
- (command "non" s_dis)
- (setq s_dis_all s_dis)
- )
- )
- (princ)
- )
|