AI Assistant
Notifications
Clear all

Carlson Text to Mtext

9 Posts
8 Users
0 Reactions
983 Views
snoop
(@snoop)
Posts: 1461
Member
Topic starter
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
 

How do I convert a couple of single lines of text into a mtext block?


 
Posted : June 21, 2012 12:41 pm
Pin Cushion
(@pin-cushion)
Posts: 475
Member
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
 

You need to load the LISP.

I will send you and email in about a half hour detailing how to get this done.


 
Posted : June 21, 2012 12:47 pm
Ben Purvis
(@ben-purvis)
Posts: 188
Member
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
 

I just create a new mtext window and copy and paste.

Maybe there's a few less clicks way to do it?


 
Posted : June 21, 2012 12:49 pm
foggyidea
(@foggyidea)
Posts: 3462
Member
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
 

Carlson Text to Mtext>Ben

How does that work, Ben?

do you export and then import text?


 
Posted : June 21, 2012 12:53 pm
sergeant-schultz
(@sergeant-schultz)
Posts: 957
Member
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
 

Lisp file

;;;----------------------------------------------------------------------------
;;;
;;; TXT2MTXT.LSP Version 1.0 9/30/96
;;;
;;;----------------------------------------------------------------------------
;;; DESCRIPTION
;;; Converts single line text to paragraph (mtext) text.
;;; Selected text is converted to paragraph text. The order that the text strings
;;; appear in the text paragraph is the same as the order that they are selected.
;;; The text style and layer of the paragraph text is the same as the FIRST text
;;; string selected.
;;;
;;; By Jay Garnett
;;; E-Mail [email protected]
;;; http://members.tripod.com/spotter10
;;;----------------------------------------------------------------------------

;;; Verifies that OBJ is single line text.
(defun CHK_TXT( OBJ )
(if (/=(cdr(assoc 0(entget OBJ)))"TEXT")
(progn(prompt"Object Selected was not TEXT!")(setq OBJ nil))
OBJ
)
)

;;; Main routine
(defun C:TXT2MTXT( / MT_LAY MT_STY OLD_LAY PARA TXT_OBJ U_CE WID)
(setq U_CE(getvar "cmdecho"))
(setvar "cmdecho" 0)
(while (not TXT_OBJ)
(setq TXT_OBJ(car(entsel "nSelect first TEXT string: ")))
(if TXT_OBJ(setq TXT_OBJ(Chk_Txt TXT_OBJ)))
)
(setq MT_STY(cdr(assoc 7(entget TXT_OBJ)))
MT_LAY(cdr(assoc 8(entget TXT_OBJ)))
MT_IPT(cdr(assoc 10(entget TXT_OBJ)))
;This sets the width of the MTEXT box to 75X the text height.
;This value may need to be adjusted to suit your needs.
WID(*(cdr(assoc 40(entget TXT_OBJ)))75)

PARA(strcat(cdr(assoc 1 (entget TXT_OBJ)))"P")
)
(while(setq TXT_OBJ(entsel "nSelect next TEXT string when finished selecting: "))
(setq TXT_OBJ(car TXT_OBJ))
(if(Chk_Txt TXT_OBJ)
(setq PARA(strcat PARA(cdr(assoc 1 (entget TXT_OBJ)))"P"))
(prompt "Object selected was not TEXT!")
)
)
(setq OLD_LAY(getvar "clayer"))
(setvar "clayer" MT_LAY)
(command "-MTEXT" "S" MT_STY MT_IPT "W" WID PARA "")
(setvar "clayer" OLD_LAY)
(prompt "nSelect insertion point for text paragraph: ")
(command ".move" "l" "" MT_IPT pause)
(setvar "cmdecho" U_CE)
(princ)
)


 
Posted : June 21, 2012 12:54 pm

cptdent
(@cptdent)
Posts: 2082
Member
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
 

Lisp file

Sure hope he has the Intellicad version. Won't work in the AutoCad Embedded version.


 
Posted : June 21, 2012 12:56 pm
Pin Cushion
(@pin-cushion)
Posts: 475
Member
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
 

I sent you everything you need and one very important LISP I could not live without... you have everything you need to get it done... except the know how 🙂

call me back if you need to, number is still the same. I will be around... just got back from Yankee Carolina.


 
Posted : June 21, 2012 1:20 pm
spledeus
(@spledeus)
Posts: 2757
Member
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
 

with a full cad component you use expresstools.


 
Posted : June 21, 2012 2:34 pm
Perry Williams
(@perry-williams)
Posts: 2183
Member
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
 

Carlson Text to Mtext>Ben

> How does that work, Ben?
>
> do you export and then import text?

you simply open each TEXT block, then select-copy then paste the contents into the MTEXT. Repeat as necessary.


 
Posted : June 21, 2012 5:42 pm