Code Red > AutoLISP (Vanilla / Visual)
type libraries
daron:
Kerry, could you help me set this up? I have no idea what pragma is and what should be in the *temp-symbols* list and the add defuns here? In what way should I add them?
(nameofdefun) or do I need to wrap each function in this whole thing or what?
JohnK:
Joe? Is that you?
smadsen:
Think Kerry meant adding defuns like this:
--- Code: ---(vl-load-com)
(setq *temp-symbols* '(kpsl_savesysvar kpsl_on_error kpsl_ptos
kpsl_dtr kpsl_rtd kpsl_deflection
kpsl_midpoint kpsl_getpoint kpsl_getint
kpsl_entsel c:testarcdim
)
)
(eval (list 'pragma
(list 'quote (list (cons 'unprotect-assign *temp-symbols*)))
)
)
;;;-----------------------------------------------------------------------------------
;;;-----------------------------------------------------------------------------------
;; add the defuns here < snip >
(defun kpsl_dtr (a)
(* (/ a 180.0) pi)
)
(defun kpsl_midpoint (p1 p2)
(princ "OK, so this is not Kerry's midpoint function")
(princ)
)
;;; etc....
;;;-----------------------------------------------------------------------------------
;;;-----------------------------------------------------------------------------------
(eval
(list 'pragma (list 'quote (list (cons 'protect-assign *temp-symbols*))))
)
(setq *temp-symbols* nil)
--- End code ---
daron:
Thanks, Stig. I think I understand now.
JohnK:
Man you guys got me confused. Where do you add that to. As a file in your suport file search path? In the acad doc lisp?
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version