(defun (setf xwin-border-width) (width win) (setf (xlib:drawable-border-width win) width))
then how to call the above function? Actually, I really don’t understand what “(setf xwin-border-width)” means instead of function time?
Yours faithfully!
This defines the function setf. You can call it using (setf (xwin-border-width *some-window*) width).
setf
(setf (xwin-border-width *some-window*) width)
You can find the documentation for setfuseful: http://www.lispworks.com/documentation/lw50/CLHS/Body/m_setf_.htm
Hyperspec also has a section on generic links: http://www.lispworks.com/documentation/lw50/CLHS/Body/05_a.htm
defun (setf f), , , setf f.
(setf f)
(defun foo (lst) (car lst)) (defun (setf foo) (val lst) (setf (car lst) val))
foo . , (setf f), , f.
setf to foo :
foo
? (let ((z (list 1 2 3))) (setf (foo z) 168) z) (168 2 3)
foo, `(setf foo), .
6 ANSI Common Lisp .