diff options
Diffstat (limited to 'lisp/ledger-mode.el')
-rw-r--r-- | lisp/ledger-mode.el | 23 |
1 files changed, 10 insertions, 13 deletions
diff --git a/lisp/ledger-mode.el b/lisp/ledger-mode.el index 18928fe0..73258da4 100644 --- a/lisp/ledger-mode.el +++ b/lisp/ledger-mode.el @@ -313,28 +313,25 @@ With a prefix argument, remove the effective date. " (ledger-schedule-check-available) ;;(ledger-post-setup) - (set (make-local-variable 'pcomplete-parse-arguments-function) - 'ledger-parse-arguments) - (set (make-local-variable 'pcomplete-command-completion-function) - 'ledger-complete-at-point) + (setq-local pcomplete-parse-arguments-function 'ledger-parse-arguments) + (setq-local pcomplete-command-completion-function 'ledger-complete-at-point) (add-hook 'completion-at-point-functions 'pcomplete-completions-at-point nil t) - (add-hook 'after-save-hook 'ledger-report-redo) - ;(ledger-fontify-whole-buffer) - ;(ledger-fontify-activate) + (add-hook 'after-save-hook 'ledger-report-redo) - ;(add-hook 'after-save-hook) (add-hook 'post-command-hook 'ledger-highlight-xact-under-point nil t) (add-hook 'before-revert-hook 'ledger-occur-remove-all-overlays nil t) (ledger-init-load-init-file) - (setq font-lock-defaults - '(nil t nil nil nil - (font-lock-fontify-buffer-function . ledger-fontify-whole-buffer) - (font-lock-fontify-region-function . ledger-fontify-buffer-part))) + ;; (setq font-lock-defaults + ;; `(,ledger-font-lock-keywords t nil nil nil + ;; (font-lock-fontify-buffer-function . ledger-fontify-whole-buffer) + ;; (font-lock-fontify-region-function . ledger-fontify-buffer-part))) + + (setq-local font-lock-defaults `(,ledger-font-lock-keywords nil t)) - (set (make-local-variable 'indent-region-function) 'ledger-post-align-postings)) + (setq-local indent-region-function 'ledger-post-align-postings)) (defun ledger-set-year (newyear) |