View of /lisp/test/rev.l
Parent Directory
| Revision Log
Revision:
1.1.1.1 -
(
download)
(
annotate)
(vendor branch)
Thu Dec 28 08:54:19 2000 UTC (23 years, 11 months ago) by
ktanaka
Branch:
ktanaka, MAIN
CVS Tags:
SNAP-20030702, tmp, SNAP-20030624, SNAP-20030630, SNAP-20040518, HEAD
Changes since
1.1: +0 -0 lines
change to CVS wadalab font project
(defun hrev (prim)
(do ((l (car prim)(cdr l))(newpoints))
((atom l)
(do ((ll (cadr prim)(cdr ll))(newelements))
((atom ll)
`(,(nreverse newpoints),(nreverse newelements) .,(cddr prim)))
(cond ((eq 'outline (caar ll))
(lets ((points (cadar ll))
(len (length points))
(curve (assq 'curve (cddar ll)))
(curve (cond (curve (cdr curve)))))
(push `(outline ,(reverse points)
(curve .,(reverse (mapcar curve
#'(lambda (x) (- len 1 x))))))
newelements)))
(t (push (car ll) newelements)))))
(push `(,(difference 400 (caar l)).,(cdar l)) newpoints)))
(defun vrev (prim)
(do ((l (car prim)(cdr l))(newpoints))
((atom l)
(do ((ll (cadr prim)(cdr ll))(newelements))
((atom ll)
`(,(nreverse newpoints),(nreverse newelements) .,(cddr prim)))
(cond ((eq 'outline (caar ll))
(lets ((points (cadar ll))
(len (length points))
(curve (assq 'curve (cddar ll)))
(curve (cond (curve (cdr curve)))))
(push `(outline ,(reverse points)
(curve .,(reverse (mapcar curve
#'(lambda (x) (- len 1 x))))))
newelements)))
(t (push (car ll) newelements)))))
(push `(,(caar l) ,(difference 400 (cadar l)).,(cddar l)) newpoints)))