diff --git a/custom/fic.el b/custom/fic.el
index 4c52321..1f18511 100644
--- a/custom/fic.el
+++ b/custom/fic.el
@@ -62,12 +62,12 @@
(if multichapter
(setq chaptertitles (y-or-n-p "Titled chapters?")))
(setq ffx (y-or-n-p "FFX fic?"))))
- (setq draftmode (y-or-n-p "Edit LaTeX file manually?"))
+ ;; (setq draftmode (y-or-n-p "Edit LaTeX file manually?"))
;; (org-format)
(save-buffer)
(goto-char (point-min))
(while (re-search-forward "\\[fn:\\([0-9]*\\):\\(.*\\)\\]" nil t)
- (replace-match "@@html:\\2@@@@latex:\\\\footnote{\\2}@@"))
+ (replace-match "@@html:@@@@latex:\\\\footnote{@@\\2@@html:@@@@latex:}@@"))
(let ((user-full-name "ovely")
(org-html-head "")
(org-export-with-author t)
@@ -144,6 +144,9 @@
(goto-char (point-min))
(while (re-search-forward "label{\\(.*\\)}\n“\\([A-Z]\\)\\([a-z]*\\)" nil t)
(replace-match "label{\\1}\n\\\\lettrine{“\\2}{\\3}"))
+ (goto-char (point-min))
+ (while (re-search-forward "label{\\(.*\\)}\n«~\\([A-Z]\\)\\([a-z]*\\)" nil t)
+ (replace-match "label{\\1}\n\\\\lettrine{«~\\2}{\\3}"))
(if ffx
(progn
(goto-char (point-min))
@@ -221,15 +224,16 @@
(replace-match "\\begin{document}\n\\pagestyle{plain}" nil t)))))
(goto-char (point-max))
(save-buffer)
- (unless draftmode
+ ;; (unless draftmode
(shell-command
(format "xelatex -interaction=batchmode %s"
(shell-quote-argument (buffer-file-name))))
(shell-command
(format "xelatex -interaction=batchmode %s"
- (shell-quote-argument (buffer-file-name)))))
+ (shell-quote-argument (buffer-file-name))))
+ ;; )
(kill-current-buffer))
- (unless draftmode
+ ;; (unless draftmode
(delete-file "FFXYevon.ttf")
(if (file-exists-p (concat (file-name-base) ".aux"))
(delete-file (concat (file-name-base) ".aux")))
@@ -241,5 +245,6 @@
(delete-file (concat (file-name-base) ".toc")))
(if (file-exists-p "texput.log")
(delete-file "texput.log"))
- (delete-file texfile))
+ (delete-file texfile)
+ ;; )
(message "Done")))
diff --git a/custom/org-format.el b/custom/org-format.el
index 02d4442..e152c79 100644
--- a/custom/org-format.el
+++ b/custom/org-format.el
@@ -119,6 +119,9 @@
(while (re-search-forward " :" nil t)
(replace-match " :"))
(goto-char (point-min))
+ (while (re-search-forward "#+TITLE :" nil t)
+ (replace-match "#+TITLE:"))
+ (goto-char (point-min))
(while (re-search-forward " !" nil t)
(replace-match "!"))
(goto-char (point-min))
diff --git a/snippets/org-mode/texindent b/snippets/org-mode/texindent
new file mode 100644
index 0000000..fb15bb6
--- /dev/null
+++ b/snippets/org-mode/texindent
@@ -0,0 +1,4 @@
+# name: latex-indent
+# key: texindent
+# --
+@@latex:\hspace{28pt}@@
\ No newline at end of file