summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArun Isaac2020-12-31 13:07:28 +0530
committerArun Isaac2020-12-31 15:07:19 +0530
commitbcd0f5d31a549df5f670c0ca91cb6c61f19e57b3 (patch)
tree2b43a84a230d0a29d066d4d098be40f2ca2f8e76
parent5b430437143e471724c9e6576e01e76ce3c1ed1d (diff)
downloadksh-reports-bcd0f5d31a549df5f670c0ca91cb6c61f19e57b3.tar.gz
ksh-reports-bcd0f5d31a549df5f670c0ca91cb6c61f19e57b3.tar.lz
ksh-reports-bcd0f5d31a549df5f670c0ca91cb6c61f19e57b3.zip
Deprecate plural functions.
* ksh-report-header.el (make-report-header): Use ksh-forms-org-keyword, ksh-forms-org-latex-header. * ksh-forms-improved.el (org-keywords, org-latex-headers): Delete functions.
-rw-r--r--ksh-forms-improved.el3
-rw-r--r--ksh-report-header.el38
2 files changed, 19 insertions, 22 deletions
diff --git a/ksh-forms-improved.el b/ksh-forms-improved.el
index e46af85..31c5dfd 100644
--- a/ksh-forms-improved.el
+++ b/ksh-forms-improved.el
@@ -75,9 +75,6 @@
(defun ksh-forms-org-latex-header (header)
(ksh-forms-org-keyword (cons "LATEX_HEADER" header)))
-(setfun org-keywords (mapped 'mapc 'ksh-forms-org-keyword))
-(setfun org-latex-headers (mapped 'mapc 'ksh-forms-org-latex-header))
-
(defun forms-print ()
(interactive)
(find-file (org-to-pdf (funcall form-to-org))))
diff --git a/ksh-report-header.el b/ksh-report-header.el
index 1177662..0fc912a 100644
--- a/ksh-report-header.el
+++ b/ksh-report-header.el
@@ -4,22 +4,22 @@
(format "\\usepackage{%s}" package)))
(defun make-report-header (title)
- (org-keywords
- '(("TITLE" . "Kuzhanthai Sanjeevi Hospital")
- ("AUTHOR" . "Dr. Serene Isaac, MD, DGO, DNB")))
- (org-latex-headers
- (list (latex-use-package "fullpage")
- (latex-use-package "nopageno")
- (latex-use-package "datetime" "ddmmyyyy")
- "\\renewcommand{\\dateseparator}{-}"
- "\\setlength{\\parindent}{0cm}"
- (latex-use-package "titlesec" "tiny")
- (latex-use-package "wasysym")
- (latex-use-package "titling")
- ,(format "\\pretitle{\\hrule \\begin{center} {\\Large \\textbf{%s}} \\par \\small \\sc}" title)
- "\\posttitle{\\par 17, Jawahar Street, Ramavarmapuram, Nagercoil - 629001 \\par \\phone \\, 223374 \\end{center}}"
- "\\preauthor{}"
- "\\postauthor{\\par Obstetrician and Gynaecologist}"
- "\\predate{\\hfill \\textbf{Date: }}"
- "\\date{\\today}"
- "\\postdate{\\vspace{1em} \\hrule \\par}")))
+ (seq-do 'ksh-forms-org-keyword
+ '(("TITLE" . "Kuzhanthai Sanjeevi Hospital")
+ ("AUTHOR" . "Dr. Serene Isaac, MD, DGO, DNB")))
+ (seq-do 'ksh-forms-org-latex-header
+ (list (latex-use-package "fullpage")
+ (latex-use-package "nopageno")
+ (latex-use-package "datetime" "ddmmyyyy")
+ "\\renewcommand{\\dateseparator}{-}"
+ "\\setlength{\\parindent}{0cm}"
+ (latex-use-package "titlesec" "tiny")
+ (latex-use-package "wasysym")
+ (latex-use-package "titling")
+ ,(format "\\pretitle{\\hrule \\begin{center} {\\Large \\textbf{%s}} \\par \\small \\sc}" title)
+ "\\posttitle{\\par 17, Jawahar Street, Ramavarmapuram, Nagercoil - 629001 \\par \\phone \\, 223374 \\end{center}}"
+ "\\preauthor{}"
+ "\\postauthor{\\par Obstetrician and Gynaecologist}"
+ "\\predate{\\hfill \\textbf{Date: }}"
+ "\\date{\\today}"
+ "\\postdate{\\vspace{1em} \\hrule \\par}")))