[tex] fix error, move config to init.org

This commit is contained in:
contrapunctus 2021-02-22 14:26:57 +05:30
parent 94cf603750
commit 101d74779a
2 changed files with 43 additions and 36 deletions

View File

@ -1,35 +0,0 @@
(setq TeX-auto-save t
TeX-parse-self t
TeX-engine 'xetex
;; 2017-10-14T18:55:05+0530
TeX-view-program-selection '(((output-dvi has-no-display-manager)
"dvi2tty")
((output-dvi style-pstricks)
"dvips and gv")
(output-dvi "xdvi")
(output-pdf "Zathura")
(output-html "xdg-open")))
(add-hook 'tex-mode-hook 'TeX-source-correlate-mode)
;; 2017-10-19T09:19:34+0530 - these should be merged with
;; cp-forward-def/cp-backward-def in cp-lily...
(defun cp-backward-def ()
(interactive)
(push-mark)
(re-search-backward "\\\\scene" nil t)
(beginning-of-line)
(recenter))
(defun cp-forward-def ()
(interactive)
(push-mark)
(if (not (re-search-forward "\\\\scene" nil t 2))
(re-search-forward "\\end{document}" nil t))
(beginning-of-line)
(recenter))
(cp-set-keys
:keymap LaTeX-mode-map
:bindings
`((,(kbd "M-p") cp-backward-def)
(,(kbd "M-n") cp-forward-def)))

View File

@ -45,7 +45,12 @@ At first I decided to remap all Emacs, Boon, and Hydra bindings, but it turned o
"C-n" 'forward-char
"C-t" 'backward-char)
(bind-keys
("C-h" . backward-delete-char)) ;; see also ivy, company
("C-h" . backward-delete-char) ;; see also ivy, company
:map text-mode-map
;; Boon already binds xref-find-definitions to f
;; see also latex-mode
("M-." forward-sentence)
)
;; ;; The old C-n/C-p/M-n/M-p were not the most comfortable to begin with, so I take this opportunity to bind them to something consistent with Boon
(general-def minibuffer-local-map
"C-c" 'previous-line
@ -1296,6 +1301,43 @@ _u_: next word ^_l_: edit lines^ _s_: next whole symbol
#+END_SRC
** TODO LaTeX
1. [ ] merge personal commands with those in Lilypond mode
#+BEGIN_SRC emacs-lisp
(use-package auctex
:hook ((tex-mode . TeX-source-correlate-mode))
:bind (:map LaTeX-mode-map
("M-c" . cp-backward-def)
("M-r" . cp-forward-def)
("M-." forward-sentence))
:config
(setq TeX-auto-save t
TeX-parse-self t
TeX-engine 'xetex
;; 2017-10-14T18:55:05+0530
TeX-view-program-selection '(((output-dvi has-no-display-manager)
"dvi2tty")
((output-dvi style-pstricks)
"dvips and gv")
(output-dvi "xdvi")
(output-pdf "Zathura")
(output-html "xdg-open")))
;; 2017-10-19T09:19:34+0530 - these should be merged with
;; cp-forward-def/cp-backward-def in cp-lily...
(defun cp-backward-def ()
(interactive)
(push-mark)
(re-search-backward "\\\\scene" nil t)
(beginning-of-line)
(recenter))
(defun cp-forward-def ()
(interactive)
(push-mark)
(if (not (re-search-forward "\\\\scene" nil t 2))
(re-search-forward "\\end{document}" nil t))
(beginning-of-line)
(recenter)))
#+END_SRC
** Org
#+BEGIN_SRC emacs-lisp
(use-package org