From b0d62ccdd3795a0b879be700317b1053b58e5f8f Mon Sep 17 00:00:00 2001 From: Arun Isaac Date: Sun, 30 Mar 2025 03:06:37 +0100 Subject: Add pdf link type. * ennum-html.el (ennum-html-export-pdf): New function. (org-link-parameters): Add pdf. * ennum.el (ennum-setting): Add :pdf-width and :pdf-height settings. (ennum-publish-link): Add pdf link type. --- ennum.el | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'ennum.el') diff --git a/ennum.el b/ennum.el index 0dd31a9..250a336 100644 --- a/ennum.el +++ b/ennum.el @@ -654,7 +654,8 @@ result as a string." :blog-scheme :index-posts-per-page :image-width :image-link-width :locale-alist :other-files-directory - :store :tag-directory :image-thumbnail-width + :pdf-width :pdf-height :store + :tag-directory :image-thumbnail-width :required-metadata) (plist-get (org-combine-plists (list :atom-feed-number-of-posts 12 @@ -664,6 +665,11 @@ result as a string." :image-link-width 1024 :index-posts-per-page 12 :locale-alist '(("en" . "C")) + ;; These PDF dimensions preserve the √2 ratio + ;; of A series paper. + ;; https://en.wikipedia.org/wiki/Paper_size#A_series + :pdf-width 640 + :pdf-height 905 :store ".ennum" :tag-directory "tag" :image-thumbnail-width 320 @@ -743,7 +749,7 @@ recognized as a directory, it should end in a slash. See width)) (list (ennum-setting :image-width) (ennum-setting :image-link-width)))) - ('static + ((or 'pdf 'static) (list (ennum-publish-copy (ennum--file-join (ennum-setting :static-directory) -- cgit v1.2.3