Jump to content

Rotating Text around base point based on azimuth of 3D polyline


cartographer

Recommended Posts

Hi guys & gals,

 

I came across a very repetitive problem. While working with a certain type of software data is output to *.dxf as set of 3D polylines and text. From the level of software I work with, I cannot configure any text formatting details. Hence an idea to ask You few questions.

 

1. Is there any way of rotating text based on azimuth of a 3Dpolyline which lies within 0.3m distance from the text base? Did someone ever came across LISP of this type ?

2.  is there any other (more effective) way than OVERKILL to get a rid of duplicated text ?

 

Thank you in advance !

Regards,

Adam, Geophysicist.

how it originally looks.png

how it should look.png

Link to comment
Share on other sites

Quote

1. Is there any way of rotating text based on azimuth of a 3Dpolyline which lies within 0.3m distance from the text base? Did someone ever came across LISP of this type ?

2.  is there any other (more effective) way than OVERKILL to get a rid of duplicated text ?

 

1. Yes the following will return the angle of the 3dpolyline at it's start point. Just paste to the command line, press return and select the 3dpolyline. The return is an angle in radians. It obviously gets more complicated if segment angles change.

 

 (angle '(0.0 0.0 0.0) (vlax-curve-getfirstderiv (car (entsel)) 0))

 

2. Yes there are other ways of deleting duplicate text. Make a list of all text, sort by insertion point coordinates then compare text string value. Whether it is more effective is subjective.

  • Like 1
Link to comment
Share on other sites

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...