- (defun c:tt ()
- "按行统计圆数量"
- (xyp-Start)
- (xyp-Ctbl (/ 3 3.))
- (if (setq ss(ssget '((0 . "CIRCLE"))))
- (setq lst(xyp-Ss2List ss)
- lst (mapcar '(lambda (x) (cadr (xyp-DXF 10 x))) lst)
- lst (xyp-list-count lst)
- dx (+ (car (xyp-9pt ss 9)) 3)
- aa (mapcar '(lambda (x)
- (setq p1 (list dx (car x))
- p2 (xyp-Pt2X p1 5)
- s1 (xyp-Line p1 p2)
- s2 (xyp-Text 4 p2 (itoa (cadr x)))
- )
- )
- lst
- )
- )
- )
- (xyp-End)
- )
|