Aloha all,

The attached patch opens up a slot to insert material between the header
and body of a texinfo file.  The Org manual uses this space to define
several macros that are used extensively through the rest of the
document.

Please feel free to improve/change if need be.

All the best,
Tom

>From 2934d2e43eb354038d80b9e26f6f74dcffd4fa51 Mon Sep 17 00:00:00 2001
From: Thomas Dye <t...@tsdye.com>
Date: Tue, 27 Nov 2012 19:11:03 -1000
Subject: [PATCH] * contrib/lisp/org-e-texinfo.el: Added TEXINFO_POST_HEADER
 slot

---
 contrib/lisp/org-e-texinfo.el | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/contrib/lisp/org-e-texinfo.el b/contrib/lisp/org-e-texinfo.el
index d006c07..6f5959c 100644
--- a/contrib/lisp/org-e-texinfo.el
+++ b/contrib/lisp/org-e-texinfo.el
@@ -126,6 +126,7 @@
   ((:texinfo-filename "TEXINFO_FILENAME" nil org-e-texinfo-filename t)
    (:texinfo-class "TEXINFO_CLASS" nil org-e-texinfo-default-class t)
    (:texinfo-header "TEXINFO_HEADER" nil nil newline)
+   (:texinfo-post-header "TEXINFO_POST_HEADER" nil nil newline)
    (:subtitle "SUBTITLE" nil nil newline)
    (:subauthor "SUBAUTHOR" nil nil newline)
    (:texinfo-dircat "TEXINFO_DIR_CATEGORY" nil nil t)
@@ -651,6 +652,7 @@ holding export options."
 			     (org-export-output-file-name ".info"))))
 	 (author (org-export-data (plist-get info :author) info))
 	 (texinfo-header (plist-get info :texinfo-header))
+	 (texinfo-post-header (plist-get info :texinfo-post-header))
 	 (subtitle (plist-get info :subtitle))
 	 (subauthor (plist-get info :subauthor))
 	 (class (plist-get info :texinfo-class))
@@ -685,6 +687,12 @@ holding export options."
      "@finalout\n"
      "\n\n"
 
+     ;; Additional Header Options set by `#+TEXINFO_POST_HEADER
+     (if texinfo-post-header
+	 (concat "\n"
+		 texinfo-post-header
+		 "\n"))
+     
      ;; Copying
      "@copying\n"
      ;; Only export the content of the headline, do not need the
-- 
1.8.0


-- 
T.S. Dye & Colleagues, Archaeologists
735 Bishop St, Suite 315, Honolulu, HI 96813
Tel: 808-529-0866, Fax: 808-529-0884
http://www.tsdye.com

Reply via email to