Hi all,
I've found a excellent lisp from Tharwat. I'd like to do a little modification, and I need some help.
I wish to control the text size, like circle diameter.
Can anybody help me, please?
Kind RegardsCode:(defun c:ncir (/ la ss) ;;; Tharwat 20. Nov. 2012 ;;; (if (and (setq *r* (cond ((getdist (strcat "\n Specify Diameter of Circle [Radius]" (if *r* (strcat "< " (rtos *r* 2 2) " > :") " :" ) ) ) ) (t *r*) ) ) (not (eq (setq la (getstring t "\n Enter Layer name :")) "")) (if (not (tblsearch "LAYER" la)) (progn (princ "\n Layer Name is not found !!") nil) t ) (setq ss (ssget '((0 . "*POLYLINE")))) ) ((lambda (x / e i) (while (setq e (ssname ss (setq x (1+ x)))) (setq i 0) (foreach dxf (entget e) (if (eq (car dxf) 10) (progn (entmakex (list '(0 . "CIRCLE") dxf (cons 40 *r*) (cons 8 la))) (entmakex (list '(0 . "TEXT") (cons 1 (itoa (setq i (1+ i)))) '(40 . 0.2) (cons 10 (trans (list (+ (cadr dxf) (* *r* 1.1)) (caddr dxf) 0.) 1 0)) (cons 8 la) ) ) ) ) ) ) ) -1 ) (princ) ) (princ) )


Reply With Quote
