Dimaligned help

Dimaligned help

javierperez
Participant Participant
475 Views
7 Replies
Message 1 of 8

Dimaligned help

javierperez
Participant
Participant

Hi all

I need a lisp command to use the dimaligned command with the text aligned with dimension line. I know i can do this in the dimstyle manager, but with the DA1 lisp it would be a time saver by not going into the dimstyle every time i need this.

I use this on certain situations and not on all dims. Can some please create a lisp for me to accomplish this (DA1).

Thanks to all who viewed this post.

sincerely

Javier   

 

0 Likes
Accepted solutions (2)
476 Views
7 Replies
Replies (7)
Message 2 of 8

devitg
Advisor
Advisor

do you mean some like it , it is ISO 25 dim style 

devitg_0-1646519963346.png

 

If not, please upload your sample DWG 

 

 

0 Likes
Message 3 of 8

javierperez
Participant
Participant

yes this would work,  but i intended for the text to be inside the dim line but the way you have is fine. I thick  your attachment  was created in acad arch, because it was the text has a bunch of weird characters  when i opened it in notepad.

Thank you for your response

0 Likes
Message 4 of 8

ВeekeeCZ
Consultant
Consultant
Accepted solution

Possibly like this. ACAD 2016+

 

(defun c:DA1 ( / dimtih dimtog)
  (setq dimtih (getvar 'dimtih))
  (setq dimtoh (getvar 'dimtoh))
  (setvar 'dimtih 0)
  (setvar 'dimtoh 0)
  (initcommandversion)
  (command-s "_.dimaligned")
  (setvar 'dimtih dimtih)
  (setvar 'dimtoh dimtoh)
  (princ)
  )

 

0 Likes
Message 5 of 8

devitg
Advisor
Advisor

@javierperez , when you says  "the text aligned with dimension line" I understood as I shown , but now you says       "the text to be inside the dim line" it is not the same . 

By the way , mine is from a plain ACAD 2019. 

 

 

0 Likes
Message 6 of 8

devitg
Advisor
Advisor

@ВeekeeCZ , please clear me  about dimtoh dimtih, it seem to be it is not possible to set the text INSIDE , and ALIGNED with the dimline. 

Maybe another DIMxxx variable shall be set properly to make make the text INSIDE and ALIGNED .

Thanks in advance  

 

 

devitg_0-1646653268401.png

 

0 Likes
Message 7 of 8

ВeekeeCZ
Consultant
Consultant

@devitg 

 

not sure what you trying to do.

1) if the text is forced to be inside the extension lines (dimtix=1), we only need dimtih. if is 0, it's aligned, if 1 it's horizontal. Dimtoh makes no difference.

2) if dimtix=0, that means the text flips to outside if there is not enough space inside. If the text is outside, the position is directed by dimtoh. If inside, still by dimtih and dimtoh makes no difference.

0 Likes
Message 8 of 8

javierperez
Participant
Participant
Accepted solution

Hi

Thank you very much, the program works perfectly as i  intended it to be. I am grateful for your help.

sincerely

Javier  

0 Likes