diff options
author | Arun Isaac | 2022-02-22 12:20:47 +0530 |
---|---|---|
committer | Arun Isaac | 2022-02-22 12:24:31 +0530 |
commit | 76136f9e904e8eb17f494d20fa2969ef2d5eb1aa (patch) | |
tree | 67b85110566260b2cb8fd202f21bed06ccea7c58 | |
parent | 651d4a0781cbbc44c9eafb2dd59791db5695223f (diff) | |
download | skribilo-76136f9e904e8eb17f494d20fa2969ef2d5eb1aa.tar.gz skribilo-76136f9e904e8eb17f494d20fa2969ef2d5eb1aa.tar.lz skribilo-76136f9e904e8eb17f494d20fa2969ef2d5eb1aa.zip |
html: Include custom head outside <style> tag.
Prior to this commit, the custom head was included inside
<style>. That is a bug.
* src/guile/skribilo/engine/html.scm (&html-head): Include custom
head.
(&html-header-style): Do not include custom head.
-rw-r--r-- | src/guile/skribilo/engine/html.scm | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/src/guile/skribilo/engine/html.scm b/src/guile/skribilo/engine/html.scm index 5120631..7384baf 100644 --- a/src/guile/skribilo/engine/html.scm +++ b/src/guile/skribilo/engine/html.scm @@ -2,6 +2,7 @@ ;;; ;;; Copyright 2005, 2006, 2007, 2008, 2009, 2011, 2012, 2018, 2020 Ludovic Courtès <ludo@gnu.org> ;;; Copyright 2003, 2004 Manuel Serrano +;;; Copyright 2021 Arun Isaac <arunisaac@systemreboot.net> ;;; ;;; ;;; This file is part of Skribilo. @@ -631,7 +632,11 @@ (display "<head>\n") (display "<meta http-equiv=\"Content-Type\" content=\"text/html;") (format #t "charset=~A\">\n" (engine-custom (find-engine 'html) - 'charset))) + 'charset)) + (let ((head (engine-custom e 'head))) + (when head + (display head) + (newline)))) :after "</head>\n\n") ;*---------------------------------------------------------------------*/ @@ -796,8 +801,7 @@ (markup-writer '&html-header-style :before " <style type=\"text/css\">\n <!--\n" :action (lambda (n e) - (let ((hd (engine-custom e 'head)) - (icss (let ((ic (engine-custom e 'inline-css))) + (let ((icss (let ((ic (engine-custom e 'inline-css))) (if (string? ic) (list ic) ic)))) @@ -809,7 +813,6 @@ (display " span.sc { font-variant: small-caps }\n") (display " span.sf { font-family: sans-serif }\n") (display " span.skribetitle { font-family: sans-serif; font-weight: bolder; font-size: x-large; }\n") - (when hd (display (format #f " ~a\n" hd))) (when (pair? icss) (for-each (lambda (css) (let ((p (open-input-file css))) |