;; *********************************************************************** ;; * QuickTools.lsp * ;; * * ;; * originally written by Chip Harper 07-19-2004 * ;; * Revised by Chip Harper 11-28-2006 to use an external data file * ;; * and added additional commands * ;; * * ;; * Email: chip@hot4cad.com * ;; * Homepage: http:www.hot4cad.com * ;; * * ;; * Creates a three or four letter short cut to place dimensions, text * ;; * and leaders on predetermined layers. Utility will verify/create * ;; * layers and linetype. Utility uses current dimension and text styles.* ;; * * ;; * This application was written for and tested on AutoCAD 2007 * ;; * It should work on older versions back to 2000 * ;; * * ;; * Permission to use, copy, modify, and distribute this software * ;; * for any purpose and without fee is hereby granted, provided * ;; * that the above copyright notice appears in all copies and * ;; * that both that copyright notice and the limited warranty and * ;; * restricted rights notice below appear in all supporting * ;; * documentation. * ;; * * ;; * G.L. "Chip" Harper provides this program "AS IS", with any and * ;; * all faults. Additionally disclaims any implied warranty of * ;; * merchantability or fitness for a particular use, and * ;; * does not warrant that the operation of the program will be * ;; * uninterrupted or error free. * ;; * * ;; * * ;; *********************************************************************** SETUP: Place the QUICKTOOLS files titled QUICKTOOLS.LSP, QUICKTOOLS_DATA.TXT and QUICKTOOLS_SETUP.TXT in your AutoCAD Customization folder. This folder needs to be listed in the AutoCAD Support Path. Load the QUICKTOOLS.LSP file like your other lisp files. *** Quick Tools Commands *** QTH Quick Tools Help QDL Dim Linear QDC Dim Continue QDA Dim Aligned QDB Dim Baseline QDAN Dim Angular QDAR Dim Arc QDCE Dim Center QDD Dim Diameter QDO Dim Ordinate QDR Dim Radius QLE Leader QTX Text QMT Mtext CUSTOMIZATION: Make your required changes to the file QUICKTOOLS_DATA.TXT. Here is how it is set up initially: (quote( ("Function" "Shortcut" "Layername" "Layercolor" "Linetype") ("Dim Linear" "QDL" "DIMS" 1 "CONTINUOUS") ("Dim Continue" "QDC" "DIMS" 1 "CONTINUOUS") ("Dim Aligned" "QDA" "DIMS" 1 "CONTINUOUS") ("Dim Baseline" "QDB" "DIMS" 1 "CONTINUOUS") ("Dim Angular" "QDAN" "DIMS" 1 "CONTINUOUS") ("Dim Arc" "QDAR" "DIMS" 1 "CONTINUOUS") ("Dim Center" "QDCE" "DIMS" 1 "CONTINUOUS") ("Dim Diameter" "QDD" "DIMS" 1 "CONTINUOUS") ("Dim Ordinate" "QDO" "DIMS" 1 "CONTINUOUS") ("Dim Radius" "QDR" "DIMS" 1 "CONTINUOUS") ("Leader" "QLE" "LEADERS" 2 "CONTINUOUS") ("Text" "QTX" "TEXT" 3 "CONTINUOUS") ("MText" "QMT" "MTEXT" 4 "CONTINUOUS") )) The first line is intended to show the user what the value represents. The first item is the specific AutoCAD command. The second item is the three or four letter short cut command. The third item is the layer name that will be used. The fourth item is the layer color. The fifth item is the linetype. You may change the order of the lines or any of the values, do not change the format, the way the data is laid out or the utility will cease to function. I suggest that you keep the orignal files and modify copies. That way if you break something you can go back and get a working copy. HOW IT WORKS: When you type in a shortcut command line "QLE" the utility will load the data file and look for the information saved for LEADERS. It will then check to see if the desired layer exists in the drawing. If the layer does exist it will make sure it is on and thawed. If the layer does not exist it will create it using the saved data. The utility then looks at the current layer and saves that name. It switches to the desired layer name and starts the LEADER command. The LEADER command runs as usual. When the command finishes the utility puts the previously saved layer back as current. The LEADER will be created on the desired layer, the color and linetype will be "Bylayer". If you have color or linetype overrides set up they will be reset upon completion of the command.