X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=.emacs;h=30f236cdb5f5e404fb5d5cc1ba6e7f5d1f0cd943;hb=e16f281abea7aba06e2e60dd6fef7faafd22c7d2;hp=3428d07c7c77394a6b5d086e72b6d380c7734cf0;hpb=bd0d87dc4339c584eca1a10a25f711597a08ca47;p=emacs.git diff --git a/.emacs b/.emacs index 3428d07..30f236c 100644 --- a/.emacs +++ b/.emacs @@ -135,6 +135,19 @@ (org-remove-empty-drawer-at "LOGBOOK" (point)))) (add-hook 'org-clock-out-hook 'bh/remove-empty-drawer-on-clock-out 'append) +; add ids on creation of nodes +(add-hook 'org-capture-prepare-finalize-hook 'org-id-get-create) +; create function to create headlines in file. This comes from +; http://stackoverflow.com/questions/13340616/assign-ids-to-every-entry-in-org-mode +(defun my/org-add-ids-to-headlines-in-file () + "Add ID properties to all headlines in the current file which +do not already have one." + (interactive) + (org-map-entries 'org-id-get-create)) +; if we wanted to do this to every buffer, do the following: +; (add-hook 'org-mode-hook +; (lambda () +; (add-hook 'before-save-hook 'my/org-add-ids-to-headlines-in-file nil 'local))) ; resolve clocks after 10 minutes of idle; use xprintidle @@ -210,7 +223,7 @@ Message can be specified either by a path pointing inside a Maildir, or by Message-ID." (interactive "MPath or Message-ID: ") (shell-command - (format "xterm -e \"%s %s\"" + (format "faf xterm -e \"%s %s\"" (substitute-in-file-name "$HOME/bin/mutt_open") message))) ;; add support for "mutt:ID" links @@ -583,7 +596,9 @@ Argument DESCRIPTION MIME description." (substitute-in-file-name "$HOME/bin/bibtex_to_paper") bibtexkey))) (org-add-link-type "papers" 'open-research-paper) - +; I pretty much always want hiearchical checkboxes +(setq org-hierachical-checkbox-statistics nil) + ;; stolen from ;; http://www-public.it-sudparis.eu/~berger_o/weblog/2012/03/23/how-to-manage-and-export-bibliographic-notesrefs-in-org-mode/ (defun my-rtcite-export-handler (path desc format) @@ -681,9 +696,7 @@ Argument DESCRIPTION MIME description." ;; Default packages included in /every/ tex file, latex, pdflatex or xelatex (setq org-latex-default-packages-alist - '(("" "fontspec" t) - ("" "xunicode" t) - )) + '()) (setq org-latex-packages-alist '(("" "graphicx" t) ("" "fontspec" t) @@ -694,6 +707,22 @@ Argument DESCRIPTION MIME description." ("" "longtable" nil) ("" "float" ))) +(defun org-create-formula--latex-header () + "Return LaTeX header appropriate for previewing a LaTeX snippet." + (let ((info (org-combine-plists (org-export--get-global-options + (org-export-get-backend 'latex)) + (org-export--get-inbuffer-options + (org-export-get-backend 'latex))))) + (org-latex-guess-babel-language + (org-latex-guess-inputenc + (org-splice-latex-header + org-format-latex-header + org-latex-default-packages-alist + nil t + (plist-get info :latex-header))) + info))) + + ; support ignoring headers in org mode export to latex ; from http://article.gmane.org/gmane.emacs.orgmode/67692 (defadvice org-latex-headline (around my-latex-skip-headlines