yawdapaah Posted March 5, 2009 Posted March 5, 2009 hi all, i'm wondering if there is a way to edit match properties so that i can match x and y locations. yaw Quote
yawdapaah Posted March 5, 2009 Author Posted March 5, 2009 primarily, text. but it'd be cool to be able to do that with everything. Quote
Tiger Posted March 5, 2009 Posted March 5, 2009 I was gonne recommend the command CHANGE - but I can't find anything about matching coordinates. For objects of the same type (eg. MTexts) you can edit X- and Y-coordinates of them all in one go. you can even use the Pick Point tool to pick a point to move all the MTexts to that point. Blocks I'd assume you can do the same. Line and PLines and such I doubt - but I can't see way it would be needed for them. If this is somehting you do often, it might be a good idea to look into writing a Lisp for it. Quote
Lee Mac Posted March 5, 2009 Posted March 5, 2009 I think LISP would be able to accomplish this quite easily. - so, if I understand it correctly, you want to be able to select some text and have other text in the same place or lined up in x and y directions. Quote
yawdapaah Posted March 5, 2009 Author Posted March 5, 2009 I'm trying to do what Lee describes. I was hoping that match properties had some way of including other fields. Quote
Lee Mac Posted March 5, 2009 Posted March 5, 2009 I'm trying to do what Lee describes. I was hoping that match properties had some way of including other fields. Don't think so, but I'll see what I can do Quote
Lee Mac Posted March 5, 2009 Posted March 5, 2009 Ok, I think this will only work for single-line DTEXT at the moment, but give it a go (defun c:mcht (/ tEnt ss tpt objLst dir npt) (if (and (setq tEnt (car (entsel "\nSelect Text to Get Properties... "))) (member (cdadr (entget tEnt)) (list "TEXT" "MTEXT")) (setq ss (ssget (list (cons 0 "*TEXT"))))) (progn (setq tpt (cdr (assoc 10 (entget tent))) objLst (mapcar 'entget (vl-remove-if 'listp (mapcar 'cadr (ssnamex ss))))) (sssetfirst nil ss) (initget 1 "X Y") (setq dir (getkword "\nWhich Co-ord to Match? [X/Y]: ")) (cond ((eq dir "X") (foreach obj objLst (setq npt (subst (car tpt) (cadr (assoc 10 obj)) (cdr (assoc 10 obj)))) (entmod (subst (cons 10 npt) (assoc 10 obj) obj)))) ((eq dir "Y") (foreach obj objLst (setq npt (subst (cadr tpt) (caddr (assoc 10 obj)) (cdr (assoc 10 obj)))) (entmod (subst (cons 10 npt) (assoc 10 obj) obj))))) (sssetfirst nil nil)) (princ "\n<!> No Text Selected, or this Isn't Text <!>")) (princ)) Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.