If you’ve ever used the Express Tool BREAKLINE, you know how frustrating it is to get the darn thing to look correct. Here is a great lisp routine that makes the size of the break symbol proportional to the 2 points that you pick.
- BRKL <enter> to start
- pick 2 points for the overall length of the break line
- (notice that I made multiple break lines at different sizes using this routine and each break line is proportional to the 2 points picked)
;;;=========================================== ;;; Single Line Break Symbol Creator ;;;=========================================== ;;; ;| Created by C. Alan Butler 2003 Yet another Break symbol creator Uses PloyLine created on the current layer Ortho Mode is up to you to pre set or not Symbol is proportional to the length and doesn't break anything |; ; (defun c:brkl (/ p1 p2 p3 p4 p5 p6 dist ang usercmd) ; ; error function & Routine Exit (defun *error* (msg) (if (not (member msg '("console break" "Function cancelled" "quit / exit abort" "") ) ) (princ (strcat "\nError: " msg)) ) ; if (setvar "CMDECHO" usercmd) (setvar "osmode" useros) (princ) ) ; ;end error function (setq oldcmd (getvar "CMDECHO")) (setvar "CMDECHO" 0) (setq useros (getvar "osmode")) (setq usercmd (getvar "CMDECHO")) (setvar "CMDECHO" 0) (setvar "plinewid" 0) (if (and (setq p1 (getpoint "Starting point of line : ")) (setq p6 (getpoint p1 "\nSelect second point: ")) ) (progn (setq dist (distance p1 p6) ang (angle p1 p6) p2 (polar p1 ang (* 0.4167 dist)) p5 (polar p1 ang (* 0.5833 dist)) p3 (polar p2 (+ 1.25664 ang) (* 0.1667 dist)) p4 (polar p5 (+ 4.39824 ang) (* 0.1667 dist)) ) ;_ end of setq (setvar "osmode" 0) (command "pline" p1 p2 p3 p4 p5 p6 "") ; Draw the Z-Line ) ) (*error* "") (princ) ) (prompt "\nBreak Symbol Creator loaded. Type BRKL to run it." ) (princ)
That’s an old one. My new one will allow you the scale the size after picking the two points. Also allows you to flip the shape. I have included 9 styles. Find it at http://www.theswamp.org
Thank you Alan for this routine. I hope you don’t mind me posting it here. I try to give credit to whom ever created it. Though, some people don’t label their routines or say where they got them from.
I’m in love with this one!!!!
very useful!!!!
Thanks Greg!
hi, is this supported in autocad 2012? if so, how can i install it? thanks. newbie here…
Hello,
Thanks for dropping by. The feature that you are referring to is a custom tool that uses a computer programming language called “AutoLISP.” It is a fairly simple language that you can create by simply using the program called “notepad” that is on your computer. The overall jist is that you copy the code that you find on this blog and save it in a text file that you create with notepad. But instead of saving it as a .txt file you simply replace the “.txt” with a .lsp. Refer here to how to copy code from this blog:
https://autocadtips.wordpress.com/2011/06/22/how-to-copy-code-from-the-internet-and-this-blog/
https://autocadtips.wordpress.com/2011/05/01/copying-lisp-code-from-this-blog/
Also refer to this site for how to load the lisp file into autocad and also check out the cool tools that Lee has developed there:
http://www.lee-mac.com/runlisp.html