Community
AutoCAD Forum
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

simple text lisp

4 REPLIES 4
Reply
Message 1 of 5
darryl.m.bowen
346 Views, 4 Replies

simple text lisp

What I need.

Text font - simplex.shx

Text style - SBCTXT (or name of text)

Text height - 1.725

Text width - 1.0

Text Layer - 4 (cyan) (will need to be created)

Text justification - L,C,R

 

will need it to creat the layer, text style, etc.  

4 REPLIES 4
Message 2 of 5
skintsubby
in reply to: darryl.m.bowen

"What I need" ???

 

I think you mean "Could someone help me... Where do I start creating a lisp?"

 

Or maybe post your code that you have already started and we can see where you are going wrong?

 

Or you could try Re-phrasing your need, more into question, and posting it in the lisp newsgroup >>Here<

 

Message 3 of 5
darryl.m.bowen
in reply to: skintsubby

Yes you are correct in the way I should have asked, and I am sorry about that.

 

Here is what I have.  it will work if I create the layer first.  It will not create the text style either.

 

(DEFUN C:2TXTL()(COMMAND "_LAYER" "SET" "01_TEXT" "" "")(COMMAND "_DTEXT" "S" "STANDARD" PAUSE "2.0" "0"  )(COMMAND "_LAYER" "SET" "0" "" ""))

Message 4 of 5

oh and it only will work with the default standard text style.  for some reason I can not het the font to change to simplex.shx

Message 5 of 5
BeKirra
in reply to: darryl.m.bowen

1) To create a layer you use "make" in the layer command, not "set".

2) Instead of using "textstyle", to create a text style using "style" command.

"textstyle" is a system variable and it allows the user to "set" a layer.

 

And logically, you first create a new layer then a new text style and finally you write a piece of text.

Optional: at the end of you code you may reset the previous active layer/text style to the current which is what you have done in your code.

 

Here is a sample of using "style":

Command: -STYLE
Enter name of text style or [?] <STANDARD>: ABC

New style.
Specify full font name or font filename (TTF or SHX) <txt>: iso3098i.shx
Specify height of text or [Annotative] <0.0000>: 12.5
Specify width factor <1.0000>:

Specify obliquing angle <0.0>:
Display text backwards? [Yes/No] <No>:
Display text upside-down? [Yes/No] <No>:
Vertical? [Yes/No] <No>:

"ABC" is now the current text style.

 

HTH

Please mark "Accept as Solution" and "Like" if my reply resolves the issue and it will help when others need helps.
= ♫ = ♪ = ♫ = ♪ = ♫ = ♪ = ♫ = ♪ = ♫ = ♪ = ♫ = ♪ = ♫ = ♪ = ♫ = ♪ = ♫ = ♪ = ♫ = ♪ = ♫ = ♪ = ♫ = ♪ = ♫ = ♪ = ♫ = ♪ = ♫ = ♪ = ♫ =
A circle is the locus of a cursor, starting and ending at the same point on a plane in model space or in layout such that its distance from a given coordinates (X,Y) is always constant.
X² + Y² = C²

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report

”Boost