;;;C:TXTLAYR appends "-TXT" to text's layer name. C:UNTXTLAYR removes "-TXT" from text's layer name. ;;; ;;;> Author: Henry C. Francis ;;;> 425 N. Ashe St. ;;;> Southern Pines, NC 28387 ;;;> http://paracadd.com ;;;> All rights reserved. ;;; ;;;> COPYRIGHT: 6-30-99 ;;;> EDITED: 02-07-2002 ;;; (DEFUN c:txtlayr () (SETQ txtss (SSGET "x" '((-4 . "")))) (SETQ txtsslen (SSLENGTH txtss)) (SETQ txtsscnt 0) (WHILE (< txtsscnt txtsslen) (SETQ texnt (ENTGET (SSNAME txtss txtsscnt))) (IF (WCMATCH (STRCASE (CDR (ASSOC 8 texnt))) (STRCASE "*txt")) nil (PROGN (SETQ texnt (SUBST (CONS 8 (STRCAT (CDR (ASSOC 8 texnt)) "-txt")) (ASSOC 8 texnt) texnt ) ;_ end of subst ) ;_ end of setq (ENTMOD texnt) ) ;_ end of progn ) ;_ end of if (SETQ txtsscnt (1+ txtsscnt)) ) ;_ end of while ) ;_ end of defun (DEFUN c:untxtlayr () (SETQ txtss (SSGET "x" '((-4 . "")))) (SETQ txtsslen (SSLENGTH txtss)) (SETQ txtsscnt 0) (WHILE (< txtsscnt txtsslen) (SETQ texnt (ENTGET (SSNAME txtss txtsscnt))) (IF (WCMATCH (STRCASE (CDR (ASSOC 8 texnt))) (STRCASE "*-txt")) (PROGN (SETQ texnt (SUBST (CONS 8 (SUBSTR (CDR (ASSOC 8 texnt)) 1 (- (STRLEN (CDR (ASSOC 8 texnt))) 4) ) ;_ end of substr ) ;_ end of cons (ASSOC 8 texnt) texnt ) ;_ end of subst ) ;_ end of setq (ENTMOD texnt) ) ;_ end of progn ) ;_ end of if (SETQ txtsscnt (1+ txtsscnt)) ) ;_ end of while ) ;_ end of defun ;|«Visual LISP© Format Options» (72 2 40 2 T "end of " 60 9 2 0 0 T T nil T) ***Don't add text below the comment!***|;