diff options
author | Craig Earls <enderw88@gmail.com> | 2014-09-04 22:31:34 -0700 |
---|---|---|
committer | Craig Earls <enderw88@gmail.com> | 2014-09-04 22:31:34 -0700 |
commit | d3d5c333f5a379a3fe3cbbf43a1098a44ed9b1be (patch) | |
tree | 5330fdced6aa0af1b704660a5935396c54a96304 /lisp/ledger-fontify.el | |
parent | 91fc39c68da0d7a1affefcbe591b17c185501134 (diff) | |
download | ledger-d3d5c333f5a379a3fe3cbbf43a1098a44ed9b1be.tar.gz ledger-d3d5c333f5a379a3fe3cbbf43a1098a44ed9b1be.tar.bz2 ledger-d3d5c333f5a379a3fe3cbbf43a1098a44ed9b1be.zip |
improved xact iteration so fontify-whole-buffer doesn't miss xact separated by more than a single empty line
Diffstat (limited to 'lisp/ledger-fontify.el')
-rw-r--r-- | lisp/ledger-fontify.el | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lisp/ledger-fontify.el b/lisp/ledger-fontify.el index 83c8753c..86fd35c5 100644 --- a/lisp/ledger-fontify.el +++ b/lisp/ledger-fontify.el @@ -40,14 +40,14 @@ (save-excursion (message "Ledger fontify whole buffer") (goto-char (point-min)) + (while (not (eobp)) - (cond ((looking-at ledger-xact-start-regex) + (cond ((looking-at ledger-xact-start-regex) (ledger-fontify-xact-at (point))) ((looking-at ledger-directive-start-regex) (ledger-fontify-directive-at (point)))) - - (forward-paragraph) - (forward-char)))) + (ledger-xact-next-xact-or-directive) ;; gets to beginning of next xact + ))) (defun ledger-fontify-activate () "add hook to fontify after buffer changes" |