[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.
Make Your Arrowheads Wiggle
Tip# 3922 By Leonid Nemirovsky On 25-Jun-2012
0
Rated By 0 users Downloaded : 426
Categories : Leaders
Software type : AutoCAD 2013
Rename File To : WGL.dwg, wgl.lsp
Add a tilde block to the tip of the leader's arrowhead.

Frequent tipster Leonid Nemirovsky shares a small LISP routine that adds a tilde to a leader arrowhead in AutoCAD.

"This LISP macro is extremely simple, but it works, and I use it often. The macro utilizes the QLeader command (using all current settings for LE) and inserts a tiny block that looks like a tilde ( ~ ) at the tip of the leader, and rotates it properly."

(defun c:wgl()
(setq scl (getvar "dimscale"))
(setq p1 (getpoint" Select Starting Point: "))
(setq p2 (getpoint p1 "Select second Point: "))
(setq p3 (getpoint p2 " Last Point: "))
(command"insert" "wgl" p1 scl scl p2)
(command"qleader" p1 p2 p3)
(princ)
)

Notes from Cadalyst Tip Reviewer Brian Benton:
This is a very simple routine. You will have to load the block (WGL.dwg) before running the LISP file (wgl.lsp). Once both the block and routine are loaded, type WGL on the Command line. This will run the QLeader command as usual, but will also insert a block at the tip of the leader's arrowhead.

 

Average Rating:
0


User comments
Comment by Cooper,Kent
Posted on 2012-06-25 16:08:34
Consider also making an arrowhead definition that includes that wiggle element, and assigning it to a Style. That way: you don't need to always have Qleader settings set for the same number of points; you can use it on regular Leaders and Multileaders as well as with Qleader; when you adjust the route of a Leader that part will always maintain the right relationship to the arrowhead part as its angle varies; when you grab the Leader's arrowhead-end grip and drag it to point to a different location, the wiggle part will move with it without the need to select the Block, too, and again it will rotate with it if appropriate; etc., etc.