因此,我看到了很多不同的层删除lisp例程,我对所有这些仍然是如此陌生,我不知道该去哪里。我试图实现的是能够键入命令,并具有预先确定的图层名称列表,选择这些图层,删除该图层上的所有对象,然后清除图形。
原因是我们在一个程序风格的项目中与一个架构师合作,所有层通常都是相同的。
我们也有一个lisp,我们运行它来清理所有的绘图。也许这是我可以补充的东西?让我知道你的想法。或者,如果您认为可以对当前的lisp进行修改,使其更好。
- (defun c:explodable () (load "explodable") (C:explodable) ) explodable
- (defun c:XRU () (load "XRU") (C:XRU) ) XRU
- (defun c:burstall () (load "burstall") (C:burstall) ) burstall
- (defun c:ibase () (load "ibase") (C:ibase) ) ibase
- (defun c:DeMask () (load "DeMask") (C:DeMask) ) DeMask
- (defun c:clean0 ()
- ; (getstring "\nClean0 Begin: tempoverrides set to 0")
- (setvar "tempoverrides" 0)
- ; (getstring "\nClean0 Begin: Pickstyle to 0")
- (setvar "pickstyle" 0)
- ; (getstring "\nClean0 Begin: UCS Reset to 0")
- (Command "ucsfollow" "0")
- ; (getstring "\nClean0 Begin: UCS set to World")
- (Command "ucs" "w")
- ; (getstring "\nClean0 Begin: INSBase subr")
- (c:ibase)
- ; (getstring "\nClean0 Begin: UCS Reset to 0")
- (Command "ucsfollow" "0")
- ; (getstring "\nClean0 Begin: UCS set to World")
- (Command "ucs" "w")
- ; (getstring "\nClean0 Begin: INSBase subr")
- (c:ibase)
- ; (getstring "\nClean0 Begin: PLAN")
- (Command "PLAN" "w")
- ; (getstring "\nClean0 Begin: angbase")
- (Command "angbase" "0")
- ; (getstring "\nClean0 Begin: snapang")
- (Command "snapang" "0")
- ; (getstring "\nClean0 Begin: ZoomExt")
- (c:ze)
- ; (getstring "\nClean0 Begin: s0")
- (c:s0)
- ; (getstring "\nClean0 Begin: Visretain Set to 1")
- (setvar "VISRETAIN" 1)
- ; (getstring "\nClean0 Begin: Unload all xrefs")
- (C:XRU)
- ; (getstring "\nClean0 Begin: Thaw All")
- (c:ta)
- ; (getstring "\nClean0 Begin: Turn all on")
- (c:ON)
- ; (getstring "\nClean0 Begin: Make objects explodable")
- (c:explodable)
- ; (getstring "\nClean0 Begin: Burstall")
- (c:burstall)
- ; (getstring "\nClean0 Begin: ConstraintInfer set to 0")
- (command "CONSTRAINTINFER" "0")
- ; (getstring "\nClean0 Begin: Thaw all")
- (c:ta)
- ; (getstring "\nClean0 Begin: Turn all on")
- (c:on)
- ; (getstring "\nClean0 Begin: Zoom Ext")
- (c:ze)
- ; (getstring "\nClean0 Begin: Set Elev to 0")
- (C:ELEV0)
- ; (getstring "\nClean0 Begin: Select All")
- (c:ai_selall)
- ; (getstring "\nAll M Text to without Mask")
- (c:DeMask)
- ; (getstring "\nClean0 Begin: Change all Selected to Color by Layer")
- (c:ccby)
- ; (getstring "\nClean0 Begin: Create a group of points")
- (setq ss (ssget "_x" '((0 . "point"))))
- ; (getstring "\nClean0 Begin: Erase a group of points")
- (Command "erase" "p" "")
- ; (getstring "\nClean0 Begin: Create a group of wipeouts")
- (setq ss (ssget "_x" '((0 . "wipeout"))))
- ; (getstring "\nClean0 Begin: Erase a group of wipeouts")
- (Command "erase" "p" "")
- ; (getstring "\nClean0 Begin: Superpurge")
- (c:purge3x)
- ; (getstring "\nClean0 Begin: ZoomExt")
- (c:ze)
- )
|