- UID
- 480477
- 积分
- 0
- 精华
- 贡献
-
- 威望
-
- 活跃度
-
- D豆
-
- 在线时间
- 小时
- 注册时间
- 2006-8-20
- 最后登录
- 1970-1-1
|
发表于 2008-6-15 16:29:55
|
显示全部楼层
不错,值得学习借鉴。。。
(Defun c:add ()
(setq gp (ssget))
(command "_layer" "s" gp ""))
(DEFUN C:dss() (COMMAND "osnap" "END,CEN,QUI,MID,QUA,PER,APP,INS,NOD,INT")
(princ))
(DEFUN C:dss1() (COMMAND "osmode" "175")(princ))
(defun c:oo()(Setvar"osmode"7095)(princ))
(Defun c:chh () (setq gp (ssget)) (command "change" gp "" "p" "la" "lvtry" ""))
(Defun c:ghh () (setq gp (ssget)) (command "change" gp "" "p" "la" "0" ""))
(Defun c:00 () (command "-layer" "s" "0" ""))
(Defun c:11 () (command "-layer" "off" "tk,tkk,t1" ""))
(Defun c:111 () (command "-layer" "off" "tk" ""))
;(Defun c:es () (command "erase" "p" ""))
(Defun c:ss2 () (command "offset" "200" pause))
(Defun c:ze () (command "zoom" "e"))
(Defun c:qd () (command "pline"))
(Defun c:ss1 () (command "offset" "100"))
(Defun c:ss4 () (command "offset" "400"))
(Defun c:ss2 () (command "offset" "200"))
(Defun c:ar () (command "array"))
;(Defun c:q () (command "'pan"))
(Defun c:CDC () (command "win_bat_modw"))
(Defun c:RR () (command "MIRROR"))
(Defun c:v () (command "Move"))
(Defun c:EX () (command "EXTEND"))
(Defun c:ds () (command "dist"))
(Defun c:H () (command "dimlinear"))
(Defun c:vq () (command "move" "p" "" pause pause "" ))
(Defun c:ey () (command "erase" "l"))
(Defun c:mi () (setq gp (ssget)) (command "mirror" gp "" pause pause "y"))
(Defun c:dq () (setq gp (ssget)) (command "change" gp "" "Properties" "lt" "dashdot" ""))
(Defun c:dA () (setq gp (ssget)) (command "change" gp "" "Properties" "lt" "dasH" ""))
(Defun c:dda () (setq gp (ssget)) (command "change" gp "" "Properties" "lt" "dasH"
"Properties" "s" ".65" ""))
(Defun c:ddaa () (setq gp (ssget)) (command "change" gp "" "Properties" "lt" "dasH"
"Properties" "s" ".4" ""))
(Defun c:ddq () (setq gp (ssget)) (command "change" gp "" "Properties" "lt" "dasHdot"
"Properties" "s" ".5" ""))
(Defun c:vd () (setq gp (ssget)) (command "change" gp "" "Properties" "s" ".15" ""))
(Defun c:gd1 () (command "change" {"p" "" "Properties" "s" ".3" ""))
(Defun c:gd () (setq gp (ssget)) (command "change" gp "" "Properties" "s" ".3" ""))
(Defun c:yd () (setq gp (ssget)) (command "change" gp "" "Properties" "s" ".5" ""))
(Defun c:vc () (setq gp (ssget)) (command "change" gp "" "Properties" "s" "3" ""))
(Defun c:rs ()
(setq gp (ssget))
(setq g (ssget))
(command "MATCHPROP" gp g ""))
(Defun c:EB ()
(command "ERASE" "L" ""))
(Defun c:za () (command "zoom" "a" ""))
(Defun c:us () (command "ucsicon" "n"))
(Defun c:rga () (command "regenauto" "of" ""))
;(Defun c:zw () (command "zoom" "w"))
(Defun c:zd () (command "zoom" "d"))
(Defun c:z1 () (command "'zoom" ".1x"))
(Defun c:zQ () (command "'zoom" ".001x"))
(Defun c:z2 () (command "'zoom" ".2x"))
(Defun c:vw () (command "move" "w"))
(Defun c:3 () (command "zoom" ".3xp"))
(Defun c:y1 () (command "zoom" ".01xp"))
(Defun c:x () (command "zoom" ".08xp"))
(Defun c:w () (command "zoom" ".25xp"))
(Defun c:ss5 () (command "offset" "50"))
(Defun c:1 () (command "zoom" ".1xp"))
(Defun c:VG () (command "UCS" "S" "ORG"))
(Defun c:VR () (command "UCS" "R" "ORG"))
(Defun c:dn1 (/ a)
(setq a (getstring "\nEnter dim of dimstyle to restore:"))
(command "dimstyle" "restore" dimn150))
(Defun c:dd1 (/ a)
(setq s1(ssget ))
(command "dimstyle" "restore" "dimn150" "DIM" "UP" S1 "" "DIM"
"EXIT" ""))
(Defun c:1d (/ a)
; (setq a (getstring "\nEnter dim of dimstyle to restore:"))
(command "dimstyle" "restore" dimn150))
(Defun c:2d (/ a)
; (setq a (getstring "\nEnter dim of dimstyle to restore:"))
(command "dimstyle" "restore" "dimn200"))
(Defun c:d2 ()
(setq s1(ssget ))
(command "dimstyle" "restore" "dimn200" "DIM" "UP" S1 "" "DIM" "EXIT" ""))
(Defun c:d15 ()
(setq s1(ssget ))
(command "dimstyle" "restore" "dimn150" "DIM" "UP" S1 "" "DIM" "EXIT" ""))
(Defun c:d5 ()
(setq s1(ssget ))
(command "dimstyle" "restore" "dimn50" "DIM" "UP" S1 "" "DIM" "EXIT" ""))
(Defun c:d25 ()
(setq s1(ssget ))
(command "dimstyle" "restore" "dimn25" "DIM" "UP" S1 "" "DIM" "EXIT" ""))
(Defun c:d22 ()
(setq s1(ssget ))
(command "dimstyle" "restore" "dimn20" "DIM" "UP" S1 "" "DIM" "EXIT" ""))
(Defun c:dJ ()
(setq s1(ssget ))
(command "dimstyle" "restore" "dimn25" "DIM" "UP" S1 "" "DIM" "EXIT" ""))
(Defun c:JD ()
(setq s1(ssget ))
(command "dimstyle" "restore" "dimn25A" "DIM" "UP" S1 "" "DIM" "EXIT" ""))
(Defun c:5da ()
(setq s1(ssget ))
(command "dimstyle" "restore" "dimn50a" "DIM" "UP" S1 "" "DIM" "EXIT" ""))
(Defun c:d0 ()
(setq s1(ssget ))
(command "dimstyle" "restore" "dimn" "DIM" "UP" S1 "" "DIM" "EXIT" ""))
(Defun c:d20 ()
(setq s1(ssget ))
(command "dimstyle" "restore" "DIMN200" "DIM" "UP" S1 "" "DIM" "EXIT" ""))
(Defun c:d2a ()
(setq s1(ssget ))
(command "dimstyle" "restore" "dimn250a" "DIM" "UP" S1 "" "DIM" "EXIT" ""))
(Defun c:5d ()
(setq s1(ssget ))
(command "dimstyle" "restore" "dimn50" "DIM" "UP" S1 "" "DIM" "EXIT" ""))
(Defun c:d20 ()
(setq s1(ssget ))
(command "dimstyle" "restore" "dimn200" "DIM" "UP" S1 "" "DIM" "EXIT" ""))
(Defun c:d15 ()
(setq s1(ssget ))
(command "dimstyle" "restore" "dimn150" "DIM" "UP" S1 "" "DIM" "EXIT" ""))
(Defun c:d11 ()
(setq s1(ssget ))
(command "change" s1 "" "Properties" "la" "pub_dim" "" "dimstyle" "restore" "dimn" "DIM" "UP" s1 "" "DIM" "EXIT" ""))
(Defun c:d1 ()
(setq s1(ssget ))
(command "dimstyle" "restore" "dimn" "DIM" "UP" S1 "" "DIM" "EXIT" ""))
(Defun c:1d ()
(setq s1(ssget ))
(command "change" s1 "" "Properties" "la" "pub_dim" "" "dimstyle" "restore" "dimn" "DIM" "UP" s1 "" "DIM" "EXIT" ""))
(Defun c:dmn ()
(setq s1(ssget ))
(command "change" s1 "" "Properties" "la" "pub_dim" "" "dimstyle" "restore" "DIMN" "DIM" "UP" s1 "" "DIM" "EXIT" ""))
(Defun c:nd ()
(setq s1(ssget ))
(command "change" s1 "" "Properties" "la" "axis" "" "dimstyle" "restore" "dimn" "DIM" "UP" s1 "" "DIM" "EXIT" ""))
(Defun c:d10 ()
(setq s1(ssget ))
(command "dimstyle" "restore" "dimn10" "DIM" "UP" S1 "" "DIM" "EXIT" ""))
;(Defun c:dY ()
; (setq s1(ssget ))
; (command "change" S1 "" "Properties" "la" "pub_dim" "" "dimstyle" ;"restore" "dimn1" "DIM" "UP" S1 "" "DIM" "EXIT" ""))
(Defun c:d00 () (command "dimstyle" "restore" "dimn1000"))
(Defun c:d3 () (command "dimstyle" "restore" "dimn500"))
(Defun c:hd () (setvar "snapang" 0))
(Defun c:vv () (command "move" "p"))
(Defun c:cf () (command "copy" "" "l" "@" "@"))
(Defun c:vx () (command "move" "p" "nea" "per"))
(Defun c:ff () (command "fillet" "r" "0" "fillet"))
(Defun c:f8 () (command "fillet" "r" "80" "fillet"))
(Defun c:ff3 () (command "fillet" "r" "3" "fillet"))
(Defun c:ff2 () (command "fillet" "r" "2" "fillet"))
(Defun c:ff9 () (command "fillet" "r" "9" "fillet"))
(Defun c:ff6 () (command "fillet" "r" "6" "fillet"))
(Defun c:6f () (command "fillet" "r" "6000" "fillet"))
(Defun c:9f () (command "fillet" "r" "9000" "fillet"))
(Defun c:f12 () (command "fillet" "r" "12000" "fillet"))
(Defun c:f13 () (command "fillet" "r" "13000" "fillet"))
(Defun c:ff12 () (command "fillet" "r" "12" "fillet"))
(Defun c:ff13 () (command "fillet" "r" "13" "fillet"))
;
;
(Defun c:f2 () (command "fillet" "r" "20" "fillet"))
(Defun c:f1 () (command "fillet" "r" "150" "fillet"))
(Defun c:sv () (command "setvar" "osmode" "1727"))
(Defun c:vs () (command "setvar" "osmode" "0"))
(Defun c:qq () (command "purge" "al" "" "n" "qsave"))
(Defun c:cs () (command "scale" "p" "" "int" "0.5" ""))
(Defun c:va (/ gp) (setq gp(ssget)) (command "move" gp "" "@"))
(Defun c:cq (/ gp) (setq gp(ssget)) (command "copy" gp "" "0,0,0" "@" ""))
(Defun c:cv (/ gp) (setq gp(ssget)) (command "change" gp "" "p" "la"))
(Defun c:a () (command "zoom" "p"))
(Defun c:vf () (command "ucsfollow" "1"))
(Defun c:t1 () (command "mirrtext" "1"))
(Defun c:qy () (command "blipmode" "off"))
(Defun c:f3 () (command "fillet" "r" "3000")
(command "fillet"))
(Defun c:f6 () (command "fillet" "r" "6000")
(command "fillet"))
(Defun c:f9 () (command "fillet" "r" "9000")
(command "fillet"))
(Defun c:r7 () (command "fillet" "r" "70")
(command "fillet"))
(Defun c:r5 () (command "fillet" "r" "50")
(command "fillet"))
(Defun c:f0 () (command "fillet" "r" "100")
(command "fillet"))
(Defun c:f22 () (command "fillet" "r" "120")
(command "fillet"))
(Defun c:rf ()
(setq a(getstring "\nEnter Current fillet radius:"))
(setq s1(ssget ))
(setq s2(ssget ))
(command "fillet" "r" a)
(command "fillet" s1 "" s2 "" ))
(Defun c:kb ()
(setq layr(getstring "\nEnter target layer name:"))
(setq a(ssget))
(command "copy" a "" "0,0" "0,0")
(command "change" a "" "p" "la" layr ""))
(Defun c:sz ()
(setq s1(ssget )))
(Defun c:cn (/ ent)
(setq ent(ssget ))
(command "copy" ent "m"))
(Defun c:sb (/ n)
(setq n(getstring "\nEnter name of VIEW and UCS to restore:"))
(command "ucs" "r" n)
(command "view" "r" n))
(Defun c:bs (/ n)
(setq n(getstring "\nEnter name of VIEW and UCS to restore:"))
(command "ucs" "s" n)
(command "view" "s" n))
(Defun c:am (/ os pt1)
(setq os(getvar "cmdecho"))
(setvar "cmdecho" 1)
(setq pt1(getpoint "nPick a point between the lines:"))
(command "dim" "angular" pause pause pt1 ^c ^c)
(setvar "cmdecho" os)
(textscr))
(Defun c:ga ()
(setvar "orthomode" 1)
(setq ang (getorient "\nAngle for ortho:\n"))
(setvar "snapang" ang))
(Defun c:rw (/ a)
(setq a (getstring "\nEnter angle of ucs to rotate:"))
(command "ucsfollow" "1")
(command "ucs" "z" a))
(Defun c:dr (/ a)
(setq a (getstring "\nEnter dim of dimstyle to restore:"))
(command "dimstyle" "restore" a)
(command "dim" "UP" "all")
)
(Defun c:du (/ a)
(setq a (getstring "\nEnter dim of dimstyle to restore:"))
(setq pt1 (getpoint "\nFirst corner:"))
(setq pt2 (getcorner pt1 "nSecond corner:"))
(command "dim" "UP" "c" pt1 pt2 "")
(command "dim" "e"))
(Defun c:dh ()
(setq e1(entget(car(entsel))))
(setq pt1(cdr(assoc 10 e1)))
(setq pt2(cdr(assoc 11 e1)))
(setvar "snapang" (angle pt1 pt2))
)
(Defun c:dl ()
(command "line" pause pause "")
(setq l(entget(car(entsel))))
(setq pt1(cdr(assoc 10 l)))
(setq pt2(cdr(assoc 11 l)))
(setvar "snapang" (angle pt1 pt2))
(command "erase" "l" "")
)
(Defun c:dh1 (/ a b)
(setq e1(entget(car(entsel))))
(setq e1(entget(car(entsel))))
(setq pt1(cdr(assoc 10 e1)))
(setq pt2(cdr(assoc 11 e1)))
(setq a (angle pt1 pt2))
(setq pt3(cdr(assoc 10 e2)))
(setq pt4(cdr(assoc 11 e2)))
(setq b (angle pt3 pt4))
(setvar "snapang" (- a b))
)
(Defun c:xd ()
(setq e1(entget(car(entsel))))
(setq pt1(cdr(assoc 10 e1)))
(setq pt2(cdr(assoc 11 e1)))
(setvar "snapang" (angle pt1 pt2))
)
(Defun c:cn (/ ent)
(setq ent (ssget ))
(command "copy" ent "m"))
(defun c:bb (/ bloc d a n)
(setq bloc (getstring"\nEnter name of block you want counted:"))
(setq d (cons 2 bloc))
(setq a (ssget "x" (list d)))
(if (/ = a nil)
(progn
(setq n (sslength a))
(prompt "There are")(prin1 n)(prompt "in the database \n")))
(if ( = a nil)
(prompt "There are none in the database \n")))
(Defun c:rz (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(setq a (getstring "\nEnter angle to rotate:"))
(command"rotate" s1 pt1 a))
(Defun c:cj ()
(setq e1 (entget (car (entsel))))
(setq pt1 (cdr (assoc 10 e1)))
(setq pt2 (cdr (assoc 11 e1)))
(setvar "snapang" (angle pt1 pt2))
)
(Defun c:jc ()
(setvar "snapang" 0)
)
(Defun c:hh ()
(setq s1(ssget ))
(command "dimtedit" s1 "C"))
(Defun c:hl ()
(setq s1(ssget ))
(command "dimtedit" s1 "l"))
(Defun c:ha ()
(setq s2(getstring "\nEnter angle to edit:"))
(setq s1(ssget ))
(command "dimtedit" s1 "a" s2))
(Defun c:vb ()
(setq s1(ssget ))
(command "ucsfollow" "1" "ucs" "ob" s1))
(Defun c:hr ()
(setq s1(ssget ))
(command "dimtedit" s1 "r"))
(Defun c:s2 (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 "0.2" ""))
(Defun c:2s (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 "2" ""))
(Defun c:s3 (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 "0.3" ""))
(Defun c:s13 (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 "1/3" ""))
(Defun c:3s (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 "3" ""))
(Defun c:s1 (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 2 ""))
(Defun c:s4 (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 "0.4" ""))
(Defun c:s14 (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 "1/4" ""))
(Defun c:4s (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 "4" ""))
(Defun c:s32 (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 "3/2" ""))
(Defun c:s54 (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 "1.25" ""))
(Defun c:s45 (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 "4/5" ""))
(Defun c:s23 (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 "2/3" ""))
(Defun c:s34 (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 "3/4" ""))
(Defun c:s43 (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 "4/3" ""))
(Defun c:qr (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 "1.6" ""))
(Defun c:s44 (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 "1/4" ""))
(Defun c:s56 (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 "5/6" ""))
(Defun c:s5 (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 "0.5" ""))
(Defun c:5s (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 "5" ""))
(Defun c:s6 (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 "0.6" ""))
(Defun c:6s (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 "6" ""))
(Defun c:s7 (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 0.7 ""))
(Defun c:s8 (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 0.8 ""))
(Defun c:ee (/ a b)
(setq s1(ssget ))
(command "measure" s1 "b" "A" "y" "500" ""))
(Defun c:w1 (/ a b)
(setq pt3 (getpoint "\nEnter New angle:"))
(setq pt2 (getpoint "\nEnter seccond point:"))
(setq pt (getpoint "\nEnter reference point:"))
(setq pt1 (getpoint "\nEnter base point:"))
(command "rotate" "p" "" pt1 "re" "" pt pt2 pt3))
(Defun c:EW1 (/ a b)
(setq pt3 (getpoint "\nEnter New angle:"))
(setq pt2 (getpoint "\nEnter seccond point:"))
(command "rotate" "p" "" "535744,296187" "re" "535744,296187" pt3 pt2))
(Defun c:EW (/ a b)
(setq p (ssget ))
(setq pt3 (getpoint "\nEnter New angle:"))
(setq pt2 (getpoint "\nEnter seccond point:"))
(command "rotate" "p" "" "535744,296187" "re" "535744,296187" pt3 pt2))
(Defun c:WW (/ a b)
(setq pt3 (getpoint "\nEnter New angle:"))
(setq pt2 (getpoint "\nEnter seccond point:"))
(command "rotate" "p" "" "535632,219811" "re" "535644,219811" pt3 pt2))
(Defun c:WW1 (/ a b)
(setq p (ssget ))
(setq pt3 (getpoint "\nEnter New angle:"))
(setq pt2 (getpoint "\nEnter seccond point:"))
(command "rotate" "p" "" "535632,219811" "re" "535644,219811" pt3 pt2))
(Defun c:WW3 (/ a b)
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "point" pt1))
(Defun c:WW2 (/ a b)
(setq p (ssget ))
(setq pt3 (getpoint "\nEnter New angle:"))
(setq pt2 (getpoint "\nEnter seccond point:"))
(command "rotate" "p" "" pt1 "re" pt1 pt3 pt2))
(Defun c:ba ()
(command "-layer" "s" "bh" "" "-bhatch" "p" "ANSI31" "700" "" ))
(Defun c:bba ()
(command "-layer" "s" "bh" "" "-bhatch" "p" "ANSI31" "500" "" ))
(Defun c:bC ()
(command "-layer" "s" "bh" "" "-bhatch" "p" "AN31C" "650" "" ))
(Defun c:bCc ()
(command "-layer" "s" "bh" "" "-bhatch" "p" "AN31C" "450" "" ))
(Defun c:Cb ()
(command "-layer" "s" "bh" "" "-bhatch" "p" "AN31C" "300" "" ))
(Defun c:bF ()
(command "-layer" "s" "bh" "" "-bhatch" "p" "AR-SAND" "20" "" ))
(Defun c:bV ()
(command "-layer" "s" "bh" "" "-bhatch" "p" "AR-CONC" "20" "" ))
(Defun c:bd ()
(command "-layer" "s" "bh" "" "-bhatch" "p" "SOLID" ))
(Defun c:RY ()
(setq p (ssget ))
(command "MIRROR" "p" "" pause pause "y"))
(Defun c:Rq ()
(setq p (ssget ))
(setq pt1 (getpoint "\nEnter basepoint:"))
(command "rotate" "p" "" "" pt1 "-90" ""))
(Defun c:C1 ()
(command "change" "LAST" "" "Properties" "la" "pub_dim" ""))
(Defun c:Cc1 ()
(command (load"dmtool.lsp")))
(Defun c:ss3 ()
(command "offset" "300" pause pause ""))
(Defun c:ss2 ()
(command "offset" "200" pause pause ""))
(Defun c:dY ()
(setq a (getstring "Dimension text <0.0000>:"))
(setq p (ssget ))
(command "dim" "n" a p "" "dim" "exit" ""))
(Defun c:ta ()
(command "-layer" "of" "tk" ""))
(Defun c:v4 (/ a b)
(setq p (ssget ))
(command "copy" "p" "" "0,0" "@0,400" "" ))
(Defun c:4v (/ a b)
(setq p (ssget ))
(command "copy" "p" "" "0,0" "@0,-400" "" ))
(Defun c:c4 (/ a b)
(setq p (ssget ))
(command "copy" "p" "" "0,0" "@400,0" "" ))
(Defun c:4c (/ a b)
(setq p (ssget ))
(command "copy" "p" "" "0,0" "@-400,0" "" ))
(Defun c:v8 (/ a b)
(setq p (ssget ))
(command "copy" "p" "" "0,0" "@0,800" "" ))
(Defun c:8v (/ a b)
(setq p (ssget ))
(command "copy" "p" "" "0,0" "@0,-800" "" ))
(Defun c:c8 (/ a b)
(setq p (ssget ))
(command "copy" "p" "" "0,0" "@800,0" "" ))
(Defun c:8c (/ a b)
(setq p (ssget ))
(command "copy" "p" "" "0,0" "@-800,0" "" ))
(Defun c:v2 (/ a b)
(setq p (ssget ))
(command "copy" "p" "" "0,0" "@0,200" "" ))
(Defun c:2v (/ a b)
(setq p (ssget ))
(command "copy" "p" "" "0,0" "@0,-200" "" ))
(Defun c:c2 (/ a b)
(setq p (ssget ))
(command "copy" "p" "" "0,0" "@200,0" "" ))
(Defun c:2c (/ a b)
(setq p (ssget ))
(command "copy" "p" "" "0,0" "@-200,0" "" ))
(Defun c:gs (/ a b)
(setq s1(ssget ))
(setq pt1 (getpoint "\nEnter the basepoint:"))
(command "scale" s1 "" pt1 0.8 ""))
(Defun c:rb ()
(command "MATCHPROP" PAUSE PAUSE l ""))
(load "brk.lsp" "")
(VMON)
(DEFUN C:AA () (COMMAND "AREA"))
;;(DEFUN C:Ar () (COMMAND "ARc"))
(DEFUN C:AL () (COMMAND "ARRAY" "L" "" "R"))
(DEFUN C:bl () (COMMAND "BLOCK"))
(DEFUN C:BB ()
(SETVAR "BLIPMODE" 1)
(setq sset1 (entsel))
(setq sset (car sset1))
(setq pt1 (getpoint "\n Select the point to break"))
(command "break" sset pt1 "@")
(SETVAR "BLIPMODE" 0)
(prin1)
)
(defun c:k () (command "copy"))
(defun c:y () (command "move"))
(defun c:chl () (command "ddchprop"))
(DEFUN C:yy () (COMMAND "CIRCLE"))
(DEFUN C:km (/ GP)(SETQ GP (SSGET)) (COMMAND "COPY" GP "" "M"))
(DEFUN C:DT () (COMMAND "DTEXT"))
(DEFUN C:E () (COMMAND "ERASE"))
(DEFUN C:Ep () (COMMAND "EXPLODE"))
(DEFUN C:Et () (COMMAND "EXTEND"))
(DEFUN C:F () (COMMAND "FILLET"))
(DEFUN C:I () (COMMAND "INSERT"))
(DEFUN C:L= () (COMMAND "LAYER" "ON"))
(DEFUN C:L- () (COMMAND "LAYER" "OFF"))
(DEFUN C:LF () (COMMAND "LAYER" "F"))
(DEFUN C:LTt () (COMMAND "LAYER" "T"))
(DEFUN C:LC () (COMMAND "LAYER" "C"))
(DEFUN C:d () (COMMAND "LINE"))
(DEFUN C:LTP () (COMMAND "LINETYPE"))
(DEFUN C:LI () (COMMAND "LIST"))
(DEFUN C:LTS () (COMMAND "LTSCALE"))
(DEFUN C:MU () (COMMAND "MEASURE"))
(DEFUN C:MI () (COMMAND "MIRROR"))
;(DEFUN C:M () (COMMAND "MOVE"))
(defun c:vv () (command "move"))
(DEFUN C:ML () (COMMAND "MOVE" "L" ""))
(DEFUN C:Mm () (COMMAND "MOVE" "W"))
(DEFUN C:O () (COMMAND "OFFSET"))
(DEFUN C:OO () (COMMAND "OSNAP" "CENT"))
(DEFUN C:OE () (COMMAND "OSNAP" "ENDP"))
(DEFUN C:OB () (COMMAND "OSNAP" "INSERT"))
(DEFUN C:OI () (COMMAND "OSNAP" "INTER"))
(DEFUN C:OM () (COMMAND "OSNAP" "MIDP"))
(DEFUN C:On () (COMMAND "OSNAP" "NEAR"))
(DEFUN C:Od () (COMMAND "OSNAP" "NODE"))
(DEFUN C:OP () (COMMAND "OSNAP" "PERP"))
(DEFUN C:PE () (COMMAND "PEDIT"))
(DEFUN C:PL () (COMMAND "PLINE"))
(DEFUN C:RG () (COMMAND "REGENauto" "of"))
;(DEFUN C:RR () (COMMAND "ROTATE"))
(DEFUN C:SA () (COMMAND "QSAVE"))
(DEFUN C:Sc () (COMMAND "SCALE"))
(DEFUN C:ST () (COMMAND "STRETCH"))
(DEFUN C:SN () (COMMAND "SNAP"))
(DEFUN C:sd () (COMMAND "SOLID"))
(DEFUN C:Ss1 () (COMMAND "STRETCH" "CROSS"))
(DEFUN C:T () (COMMAND "TRIM"))
(DEFUN C:U () (COMMAND "UNDO"))
(DEFUN C:VD () (COMMAND "VIEW" "D"))
(DEFUN C:VR () (COMMAND "VIEW" "R"))
(DEFUN C:VS () (COMMAND "VIEW" "S"))
(DEFUN C:VW () (COMMAND "VIEW" "W"))
(DEFUN C:VP () (COMMAND "VPOINT"))
(DEFUN C:ZA () (COMMAND "ZOOM" "A"))
(DEFUN C:ZZ () (COMMAND "ZOOM" "P"))
;(DEFUN C:ZW () (COMMAND "ZOOM" "W"))
(DEFUN C:ZD () (COMMAND "ZOOM" "D"))
(DEFUN C:ZC () (COMMAND "ZOOM" "C"))
(DEFUN C:ZE () (COMMAND "ZOOM" "E"))
(DEFUN C:ZL () (COMMAND "ZOOM" "L"))
(DEFUN C:zX () (COMMAND "PAN"))
(defun c:zq () (command "zoom" "p"))
(defun c:zZZ () (command "zoom" "c" pause "0.3x") (prin1) )
(defun c:xz () (command "zoom" ".51x")(prin1))
;;;********************************************************************
(defun c:cc (/ ss e n )
;; Version number. Reset this local if you make a change.
(setq cl_ver " 2.01")
(princ (strcat "\nChange layer, Version"cl_ver
", (c) 1994-1996 by Pro-Team (China) CO.,LTD. "))
(princ "\nSelect objects to be changed...\n")
(setq ss(ssget))
(if ss (progn
(setq e (car (entsel "pick an object on the desired layer:")))
(if e (progn
(setq e(entget e))
(setq n(cdr(assoc 8 e)))
(command "change" ss"" "prop" "layer" n "color" "bylayer" "p" "lt"
"bylayer" "")
))
))
)
;;;
(princ
"\n\tC:CHLayer loaded. Start command with CC.")
(princ)
;(LOAD "CC")
(defun c:r90 (/ gp) (setq gp (ssget)) (command "rotate" gp
"" pause "90"))
(defun c:r09 (/ gp) (setq gp (ssget)) (command "rotate" gp
"" pause "270"))
(defun c:rqa (/ gp) (setq gp (ssget)) (command "rotate" gp
"" pause "90"))
(defun c:rqb (/ gp) (setq gp (ssget)) (command "rotate" gp
"" pause "270"))
(defun c:r1 (/ gp) (setq gp (ssget)) (command "rotate" gp
"" pause "180"))
(defun c:1r (/ gp) (setq gp (ssget)) (command "rotate" gp
"" pause "-180"))
(defun c:r45 (/ gp) (setq gp (ssget)) (command "rotate" gp
"" pause "45"))
(defun c:r54 (/ gp) (setq gp (ssget)) (command "rotate" gp
"" pause "315"))
(defun c:ff1( / e n )
(setq e (car (entsel "\nPick an object on the desired layer:")))
(if e
(progn
(setq n (cdr (assoc 8 (entget e ))))
(command "layer" "f" n "")
)
(princ "\nError!")
)
)
(defun c:rw ( / rr f ed l j c r )
(setq f (car (entsel "Select a circle:")))
(setq ed (entget f ))
(setq j (cdr (assoc 0 ed )))
(if
( = "CIRCLE" j )
(progn (setq c (cdr (assoc 10 ed)))
(setq r (cdr (assoc 40 ed)))
(setq rr ( + r r ))
(command "donut" "0" rr c "" )
(setq l (getvar "clayer"))
(command "change" "l" "" "p" "la" l "" )
)
(progn (princ "Shit....."))
)
)
(defun c:ww ( / la rr f w l ww e ed j c r bk )
(setq w (getvar "offsetdist"))
(setq ww (+ w w ))
(princ "\nEnter width(")
(prin1 ww )
(princ "):")
(setq ww (getdist ))
(if (= ww nil) (progn (setq ww (+ w w ))))
(setq w (/ ww 2))
(setq rr 1)
(setq la (entsel))
(if (= la nil) (setq rr 0))
(while (= rr 1)
(setq f (car la))
(setq ed (entget f))
(setq j (cdr (assoc 0 ed)))
(command "offset" w la pause "" )
(if
( = "CIRCLE" j )
(progn (setq ed (entget (entlast)))
(setq c (cdr (assoc 10 ed)))
(setq r (cdr (assoc 40 ed)))
(setq bk1 (polar c 0 r))
(setq bk2 (polar c 1.57 r))
(command "break" bk1 bk2)
))
(if
( = "POLYLINE" j )
(progn (command "pedit" "l" "w" ww "" ))
(progn (command "pedit" "l" "" "w" ww "" ))
)
(if ( = "CIRCLE" j ) (command "pedit" "l" "c" ""))
(setq l (getvar "clayer"))
(command "change" "l" "" "p" "la" l "")
(setq la (entsel))
(if (= la nil) (setq rr 0))
(if (= la nil) (prin1 "shit! shit! shit......"))
)
)
(defun c:R9 () (command"rotate"pause "" "@" "90"))
(defun c:9R () (command"rotate"pause "" "@" "-90"))
(defun c:R0 () (command"rotate"pause "" "@" "180"))
(defun c:0R () (command"rotate"pause "" "@" "-180"))
(defun c:r6 () (command"rotate"pause "" "@" "60"))
(defun c:r0 () (command"rotate"pause "" "@" "180"))
(defun c:r45 () (command"rotate"pause "" "@" "45"))
(defun c:zd () (command"zoom" "d"))
(defun c:za () (command"zoom" "a"))
(defun c:zq () (command"zoom" "p"))
(defun c:ze () (command"zoom" "e"))
;(defun c:fd () (command"zoom" "2x"))
;(defun c:sx () (command"zoom" ".5x"))
(defun c:sa () (command"'_ddlmodes" ))
(defun c:eerR () (command"chval" ))
;(defun c:sd2 () (command"lengthen" "dy" ))
(defun c:UE () (command"UCS" "E" ))
(defun c:UP () (command"UCS" "P" ))
(defun c:arxx () (command"arx" "l" "E:/Program Files/Tangent/TArch7/asdehk/2002/asdehk.arx")) |
|