Jump to content

Recommended Posts

Posted
6 hours ago, pmadhwal7 said:

one problem found lsp was somewhere working and somewhere not.

 

As mentioned above

 

The lisp will flip any "unreadable" leader MText (i.e. text with a rotation angle >90 <270) through 180 to make it readable.

 

If the MText has a rotation of 90 degrees or less, or 270 degrees or greater; it will be ignored. If you require something that flips all MText regardless of the current rotation angle let me know

Posted (edited)
1 hour ago, dlanorh said:

 

As mentioned above

 

The lisp will flip any "unreadable" leader MText (i.e. text with a rotation angle >90 <270) through 180 to make it readable.

 

If the MText has a rotation of 90 degrees or less, or 270 degrees or greater; it will be ignored. If you require something that flips all MText regardless of the current rotation angle let me know

YES SIR I WANT.... ALSO IF POSSIBLE IT WILL AUTOMATICALLY CHANGE TEXT JUSTIFICATION  LIKE UR CURRENT LSP DOING, AND ALSO WORK IN DTEXT TOO

Edited by pmadhwal7
Posted
6 hours ago, dlanorh said:

 

Post an example drawing (2012). This is probably something simple I'm overlooking, as it works on my system.

 

Attached is a documented version if it helps, and my test drawing (2012). I have updated the lisp by inserting a debug "alert" for null selection set (nothing selected) as well as a prompt.

 

When prompted for the text entities select everything by crossing, and only three items should be highlighted, everything else should be ignored.

 

 

RT-TEST.dwg 58 kB · 2 downloads rt.lsp 2.56 kB · 2 downloads

 

That's it!

The RT.lsp program you posted above works on the drawing you posted and my drawings as well!

I'll compare it to the earlier version to see if I can find what kept it from working.

Thank you for your kind assistance and your programming skills.

Cheers!

 

Steve

Posted

dlanorh,

Found the only difference between programs.

The version you attached has

(setq obj (vlax-ename->vla-object (ssname ss (setq cnt (1- cnt))))

in the cond section, whereas the original version you posted had

(setq obj (vlax-ename->vla-object ent)

When I copied that line into the version I already had, that version started working as well.

That made the difference.

Thanks again.

 

Steve

 

 

 

 

Posted
2 hours ago, StevJ said:

dlanorh,

Found the only difference between programs.

The version you attached has


(setq obj (vlax-ename->vla-object (ssname ss (setq cnt (1- cnt))))

in the cond section, whereas the original version you posted had


(setq obj (vlax-ename->vla-object ent)

When I copied that line into the version I already had, that version started working as well.

That made the difference.

Thanks again.

 

Steve

 

 

I mentioned that a couple of posts ago. I was editing another lisp in my editor and did a replace "(ssname ss (setq cnt (1- cnt)))" with "ent". Unfortunately I hit the "replace all in all open documents" button rather than the "replace all" button. :cry: :oops:  I posted the two lisps soon after. I didn't notice until you raised the issue of it not working.

 

I have a snippet/lisp somewhere where I have calculated the correction neccessary for the  centre point for MText after shrink wrapping the text box. Once I find it I can incorporate the two together.

Posted
7 hours ago, dlanorh said:

I have a snippet/lisp somewhere where I have calculated the correction neccessary for the  centre point for MText after shrink wrapping the text box. Once I find it I can incorporate the two together.

 

That would be interesting.

 

Steve

Posted
On 8/13/2019 at 4:22 PM, dlanorh said:

 

As mentioned above

 

The lisp will flip any "unreadable" leader MText (i.e. text with a rotation angle >90 <270) through 180 to make it readable.

 

If the MText has a rotation of 90 degrees or less, or 270 degrees or greater; it will be ignored. If you require something that flips all MText regardless of the current rotation angle let me know

sir,

i am still waiting for ur lsp

Posted

Attached  are two lisp

flipmt - flips mtext

flipt - flips text (it doesn't change the alignment point as there are no equivalent alignment points for 5 of the 14 different alignments)

flipmt.lsp flipt.lsp

  • Like 1
Posted
11 hours ago, dlanorh said:

Attached  are two lisp

 

Those are some handy routines and I have an immediate use for them.

Thanks for posting.

 

Steve

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...