Visual LISP, AutoLISP and General Customization

Visual LISP, AutoLISP and General Customization

Distinguished Contributor
Posts: 104
Registered: ‎10-21-2005
Message 1 of 4 (233 Views)


233 Views, 3 Replies
01-27-2006 08:18 AM
Many people have seen the background mask feature introduced in 2005. For many, this is finally the answer to the endless list of problems with wipeouts. MTEXT now has the capabilities of being masked. Now you will not here:
-Oops I left the wipeout frames one
-Why is the wipeout plotting?
-Why isn’t the wipeout plotting?
-Why is part of the wipeout plotting
-Why is the display order changing on me?
As long as all new drawings are created using MTEXT everything is great in the 2005 and 2006 world. The problem lies with older drawings or exploded MTEXT. Many people like myself want to be able to convert all DTEXT in a drawing to all MTEXT. The express tools can do this but only one DTEXT at a time. This can be quite time consuming to do. And it has trouble with twist screen. Anyone familiar with LISP knows that such a routine could be written. I have been trying to build the perfect LISP's with the help of many LISP'ers that hang around here and came up with these 3 routines:

1) One that convert the DTEXT to MTEXT (t2mm.lsp). However, does not keep the text in the exact position, especially with right aligned text.

2) One that adjusts the width of the MTEXT to the actual limits of the text string (mtw.lsp). This is used so you do not have a mask where there is no text or no mask where there is text. This only works by adjusting the width not the heighth.

3) And one that allows you to easy mass manipulate the background mask offset factor (mtb.lsp). No problems with this one other than it could be written to avoid hitting space 3 times to take the default settings.

I have attached these 3 routines for all to use. I am posting this in hope that there are some new routines out there that address MTEXT usage in AutoCAD 2005 or newer. After all there is no need to recreate the wheel if it already exists.

I know a lot of LISPers out there get a little T.O.'ed when everyday AutoCAD people want free LISP. I have been suggested on many occasions to figure out how to do it myself. In response to all that have said that, I have been looking into LISP and thanks the AutoCAD Developers Guide, I can finally read some LISP and understand the structure. I just lack experience and knowledge that most professional LISP'ers contain. As far as the ideas and structure are concerned I can come up with some great ideas.

If anyone has any new developments on the issue your help would be greatly appreciated. Please review or test the LISP routines I have posted to avoid cluttering this topic with unneeded comments. And thanks to all you LISP’ers out there who are willing to lend a helping hand.
*C Witt
Message 2 of 4 (233 Views)

Re: DTEXT to MTEXT LISP Routines

01-27-2006 08:30 AM in reply to: tclark0506
#1 & #2 have been around since the advent of 2005 (posted numerous times
on these boards).. (reinventing the wheel indeed).
*Adam Wuellner
Message 3 of 4 (233 Views)

Re: DTEXT to MTEXT LISP Routines

01-27-2006 01:30 PM in reply to: tclark0506
C Witt wrote:
> (reinventing the wheel indeed).

Still a kind gesture.
New Member
Posts: 1
Registered: ‎04-14-2009
Message 4 of 4 (233 Views)

Re: DTEXT to MTEXT LISP Routines

04-14-2009 07:35 AM in reply to: tclark0506
Here are the steps I came up with for converting old DTEXT to MTEXT. Select Similar is your friend…
Select all text your DTEXT. You can use select similar.
Select Similar, Make all your DTEXT the same LEFT justification, by using the right click JUSTIFY, this will keep its original location.
Select Similar, Use the t2mm.lisp to convert it to MTEXT
Select Similar, Change the justification to Middle Center with the right click JUSTIFY.
Select Similar, Under the Properties change the DEFINED WIDTH to “0” and turn on BACKGROUND MASKING

It seems pretty quick for me.

Good Luck.
Post to the Community

Have questions about Autodesk products? Ask the community.

New Post
Are You Going To Be @ AU 2014? Feel free to drop by our AU topic post and share your plans, plug a class that you're teaching, or simply check out who else from the community might be in attendance. Ohh and don't forgot to stop by the Autodesk Help | Learn | Collaborate booths in the Exhibit Hall and meet our community team if you get a chance!