[Search tip detail and code files using keywords, tip number, author name, etc ]
 
    For tip to function correctly, you must ensure that the downloaded file name matches the file name
    displayed in the Rename File To field. Please rename downloaded files when necessary.
Create Custom Linetype
Tip# 3011 By Ron Perez On 03-Sep-2008
4.333335
Rated By 6 users Downloaded : 10858
Categories : Linear Objects, 2D Operations
Software type : AutoCAD 2008
Rename File To : MakeLT4/,MakeLT4/MakeLt.gif,MakeLT4/makelt.lsp
AutoLISP routine automates the steps needed to make a custom linetype with embedded characters.

Editor's Note: In July 2014, this tip was updated and the LISP file was replaced with a new version. Updates include:

  • Linetypes other than continuous can be used
  • Assembled linetype is shown on dialogue
  • Filter for layer names
  • Better error checking.

Editor's Note: In June 2014, this tip was updated and the LISP file was replaced with a new version. Updates include a dialogue box and an option to apply the linetype to selected layers. The zip file also contains an image that shows the dialogue.

Editor's Note: In June 2010, this tip was updated and the LISP file was replaced with a new version. Updates include:

  • User can specify text height
  • Gap that the text is placed in is more accurate, vertically and horizontally
  • Text in linetype uses the current textstyle (getvar 'textstyle)
  • Assembled linetype definition is printed to the Command line
  • Variables dashlen, txtgap, txthgt can be modified in code for user preference
  • The rountine checks for existing linetype and prompts user to redefine.
     

This month’s top tip by Ron Perez is Create Custom Linetype, which automates the steps needed to make a custom linetype with embedded characters. Load the LISP code and type MakeLT to start it. You will be asked to supply a string to be embedded in the linetype. Type in the characters and select Enter. A temporary linetype file definition is created and loaded into the current drawing. All you need to do now is relate it to a layer name, and it is ready to go. This is a nice timesaver for those who make custom linetypes, and it’s well deserving of this month’s top tip prize!

 

Average Rating:
4.333335


User comments
Comment by webmaster@cadalyst.com
Posted on 2008-09-03 00:25:07
Hot Tip Harry's Top Tip for September 2008.
Comment by S,MK
Posted on 2008-10-17 12:34:21
Good very simple to use.
Comment by McCaugherty,Dennis
Posted on 2009-04-21 11:25:51
This is great, and would be terreffic if it returned the assembled text line, in the text area, to facilitate adding it to the line definition file, ACAD.lin, if it's still called by that name.
Comment by sak,john
Posted on 2009-05-03 20:19:49
Good Thx!
Comment by JC,Prakash
Posted on 2019-10-11 02:25:53
Good macro for creating custom linetypes