[cl-pdf-devel] Named destinations proposal and small amendments

Dmitri Ivanov divanov at aha.ru
Wed Oct 27 10:28:08 UTC 2004


Hello Eric,

|   I also moved to a single ADD-LINK function, but made it a generic
|   function dispatching on specializations of a DESTINATION class. I
|   think this is more extensible than dispatching by hand inside
|   ADD-LINK. Rough code follows.

Thanks, looks a bit more extensive :-)

| (defclass destination () ())
|
| (defclass explicit-destination (destination)
|   ((page :initarg :page
|          :type integer
|          :accessor destination-page)
|    (position :initarg :position
|              :initform "/Fit"
|              :accessor destination-position)))
|
| (defmethod write-object ((dest explicit-destination) &optional
| root-level)(declare (ignore root-level))
|   (write-object (vector (destination-page dest) (destination-position
| dest))))

But how do you handle destination possitions with arguments, e.g. "/XYZ" top
left zoom?
--
Sincerely,
Dmitri Ivanov
lisp.ystok.ru





More information about the cl-pdf-devel mailing list