Author Topic: text rejustification on mirror...  (Read 1930 times)

0 Members and 1 Guest are viewing this topic.

Andrea

  • Water Moccasin
  • Posts: 2372
text rejustification on mirror...
« on: December 07, 2006, 10:22:00 AM »
Good morning all..

I have this little basic LISP who redefine text justification when mirror is done.
but I don't like it.....

and would be glad to see if any of you have a routine similar...or something else doing this.
(see picture)


Code: [Select]
(defun MIRR2 ()

(initget "Gd Dg")
  (setq opt1 (getkword "Mirroir de GD ou DG <Droite Gauche>: "))
  (if (eq opt1 nil)(setq opt1 "Dg"))
 
(setq mobjets (ssget))

(setq mob (sslength mobjets))

(setq val1 (- mob 1))

(repeat mob
 (setq a1 (entget (ssname mobjets val1)));;détail de l'entité
 (setq a2 (cdr (assoc 0 a1)))

(if (eq a2 "TEXT")
(progn
 (setq spt_ins (cdr (assoc 10 a1))) ;;Insertion point
(if (eq opt1 "Dg") (command "_justifytext" (cdr (assoc -1 a1)) "" "_R"))
(if (eq opt1 "Gd") (command "_justifytext" (cdr (assoc -1 a1)) "" "_L")) 
(setq val1 (- val1 1))
)
(setq val1 (- val1 1)))
)

(setq Mp1 (getpoint "Spécifiez le premier point de la ligne de symétrie:")
      Mp2 (getpoint Mp1 "Spécifiez le deuxième point de la ligne de symétrie:"))
(command "_mirror" mobjets "" Mp1 Mp2 "_Y")

)
Keep smile...

sinc

  • Guest
Re: text rejustification on mirror...
« Reply #1 on: December 07, 2006, 05:45:31 PM »
Good morning all..

I have this little basic LISP who redefine text justification when mirror is done.
but I don't like it.....

and would be glad to see if any of you have a routine similar...or something else doing this.


Is there some reason you aren't just using a standard QLeader?