|
(defun GtUpT (x); P# f G# p$ `% S) x4 w
(setq pt (cdr (assoc 10 (entget x)))0 J+ w) d5 s: f/ I6 ?5 A
pt (mapcar '+ pt '(0 200))- X6 I/ e W( I, U: H, Z7 q7 m
)
" o9 G! d+ D* E- ~9 G7 K$ e4 a (ssget "f" (list pt (mapcar '+ pt '(400 0))) TxtEq) ; '(600 0)6 _; `& s( U3 h- j4 E4 C3 ]9 N
)0 I" C$ d3 S; m. ]' ]5 D. K7 ]
- N! t1 W- X$ r$ F7 M C;;; for Test only
' Y8 `0 _+ W0 R# y# l7 h# ?4 d4 V4 O$ M" x6 p' f& F& f
(defun C:Test ()4 j1 Z9 T- Z' ?" X. T D
;; 设定文字滤取条件
: |* C% x: [" ]( w% B4 D (setq TxtEq
$ a1 n9 q1 n- {0 z. M '(1 u1 q7 }# G% P9 @" K4 P
(0 . "TEXT")1 S8 y/ r, C/ Q, W$ P; l0 s( |& `' L, H; \
(8 . "451")9 n" f+ ?! j- O/ p7 N
(62 . 13)- t& o7 i% M7 I0 C% t
(50 . 0.0)7 B) `3 G) L9 W3 m) c9 |
(41 . 0.8)$ ]+ p* P+ S0 o3 C4 @9 k* K
(51 . 0.0)3 y9 `! x3 e; g: f* m3 w- }, d/ m
(7 . "Standard")
4 L" H; _* V8 D& _5 Z1 B" C (71 . 0)# S- @# ^, Y9 O3 Q0 j# s, A
(72 . 0)4 K8 C) p8 f0 r1 |
(73 . 0)
) t `. p2 j3 K( e )
( u' P8 [# V/ W: s7 j; v9 v) S5 {$ v Q2 y )1 a R+ \. m$ i7 a7 \5 d; N
5 ?% }" N- Q- O7 v6 {* G3 z (command "Zoom" "e")
" {1 D" X7 e9 A) r" ~ 5 P2 ?2 {+ _+ R2 Z$ a& W
(setq ss (ssget "x" TxtEq)
: x) x" B$ B5 Q ssa (ssadd)
6 _( c5 S, }0 g; Q3 n0 O ;; ssb (ssadd)
3 Y; n9 p# d ^, L: `1 W idx 0. h, P# }+ B; n; E, E6 T! o
) A5 C$ G2 {* L6 n
1 o6 }( P4 ]% B# s' c (while (setq ee (ssname ss idx))
U c* d% B7 M (if (gtUpT ee): \' E) R1 }& m5 |' r
(ssadd ee ssa)/ X4 j' m8 p+ M- T9 x
;; (ssadd ee ssb) l0 v9 ^6 I, |2 x5 H# G
)
' D) ] p' W, i5 p; F (setq idx (1+ idx))
G9 G& s- J; H! B ), q& B; n! F- z
(command "Erase" ssa "")
% x' p9 f: Q* ^, H5 @, O% { (princ)1 d8 G( o2 T! L$ ?7 m) p) J/ q0 [0 H* P8 l
) |
|