-
Notifications
You must be signed in to change notification settings - Fork 167
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Body wrapper customization. Fix #280 #281
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,6 +7,7 @@ | |
;; Maintainer: Jason R. Blevins <jblevins@xbeta.org> | ||
;; Created: May 24, 2007 | ||
;; Version: 2.4-dev | ||
;; Package-Version: 20171031.1725 | ||
;; Package-Requires: ((emacs "24") (cl-lib "0.5")) | ||
;; Keywords: Markdown, GitHub Flavored Markdown, itex | ||
;; URL: https://jblevins.org/projects/markdown-mode/ | ||
|
@@ -758,6 +759,14 @@ | |
;; * `markdown-xhtml-header-content' - additional content to include | ||
;; in the XHTML `<head>` block (default: `""`). | ||
;; | ||
;; * `markdown-xhtml-body-preamble' - additional content to include in the | ||
;; XHTML <body> block, before the output. This is useful if you'd like to | ||
;; wrap the Markdown output around extra elements (default: `""`')." | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Stray single quote (`) here. |
||
;; | ||
;; * `markdown-xhtml-body-epilogue' - additional content to include in the | ||
;; XHTML <body> block, after the output. This is useful if you'd like to | ||
;; wrap the Markdown output around extra elements (default: `""`'). | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Stray single quote (`) here also. |
||
;; | ||
;; * `markdown-xhtml-standalone-regexp' - a regular expression which | ||
;; `markdown-mode' uses to determine whether the output of | ||
;; `markdown-command' is a standalone XHTML document or an XHTML | ||
|
@@ -1360,6 +1369,18 @@ and `iso-latin-1'. Use `list-coding-systems' for more choices." | |
:group 'markdown | ||
:type 'string) | ||
|
||
(defcustom markdown-xhtml-body-preamble "" | ||
"Additional content to include in the XHTML <body> block, before the output. | ||
This is useful if you'd like to wrap the Markdown output around extra elements." | ||
:group 'markdown | ||
:type 'string) | ||
|
||
(defcustom markdown-xhtml-body-epilogue "" | ||
"Additional content to include in the XHTML <body> block, after the output. | ||
This is useful if you'd like to wrap the Markdown output around extra elements." | ||
:group 'markdown | ||
:type 'string) | ||
|
||
(defcustom markdown-xhtml-standalone-regexp | ||
"^\\(<\\?xml\\|<!DOCTYPE\\|<html\\)" | ||
"Regexp indicating whether `markdown-command' output is standalone XHTML." | ||
|
@@ -7770,7 +7791,13 @@ Standalone XHTML output is identified by an occurrence of | |
(insert markdown-xhtml-header-content)) | ||
(insert "\n</head>\n\n" | ||
"<body>\n\n") | ||
(when (> (length markdown-xhtml-body-preamble) 0) | ||
(insert markdown-xhtml-body-preamble)) | ||
(insert "\n") | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It might be better to put this newline inside the |
||
(goto-char (point-max)) | ||
(insert "\n") | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Same for this newline (see above). |
||
(when (> (length markdown-xhtml-body-epilogue) 0) | ||
(insert markdown-xhtml-body-epilogue)) | ||
(insert "\n" | ||
"</body>\n" | ||
"</html>\n")) | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove this
Package-Version
header.