diff options
author | Craig Earls <enderw88@gmail.com> | 2013-02-01 10:19:47 -0700 |
---|---|---|
committer | Craig Earls <enderw88@gmail.com> | 2013-02-01 10:19:47 -0700 |
commit | 0675208a63837b0ce6802b5124bb90514f07b5e0 (patch) | |
tree | 38fbb5bd4c1a922b356529554d8ceae5bb3001aa /lisp/ldg-mode.el | |
parent | 844b614af7a74ac52b6a63406af2a49485d178da (diff) | |
download | fork-ledger-0675208a63837b0ce6802b5124bb90514f07b5e0.tar.gz fork-ledger-0675208a63837b0ce6802b5124bb90514f07b5e0.tar.bz2 fork-ledger-0675208a63837b0ce6802b5124bb90514f07b5e0.zip |
Add regional sort facility to ledger mode
C-c C-s now bound to ledger-sort-region. ledger-sort-region is smart and
find the beginning of the first xact within the region and the beginning of
the first xact AFTER the region so that it can keep posing structure intact
Diffstat (limited to 'lisp/ldg-mode.el')
-rw-r--r-- | lisp/ldg-mode.el | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lisp/ldg-mode.el b/lisp/ldg-mode.el index 6179747d..001ec8eb 100644 --- a/lisp/ldg-mode.el +++ b/lisp/ldg-mode.el @@ -69,7 +69,7 @@ customizable to ease retro-entry.") (define-key map [(control ?c) (control ?c)] 'ledger-toggle-current) (define-key map [(control ?c) (control ?e)] 'ledger-toggle-current-entry) (define-key map [(control ?c) (control ?r)] 'ledger-reconcile) - (define-key map [(control ?c) (control ?s)] 'ledger-sort-buffer) + (define-key map [(control ?c) (control ?s)] 'ledger-sort-region) (define-key map [(control ?c) (control ?t)] 'ledger-test-run) (define-key map [tab] 'pcomplete) (define-key map [(control ?i)] 'pcomplete) @@ -96,7 +96,8 @@ customizable to ease retro-entry.") (define-key map [menu-bar ldg-menu sm] '("Set Month" . ledger-set-month)) (define-key map [menu-bar ldg-menu sy] '("Set Year" . ledger-set-year)) (define-key map [menu-bar ldg-menu s1] '("--")) - (define-key map [menu-bar ldg-menu so] '("Sort Buffer or Region" . ledger-sort-buffer)) + (define-key map [menu-bar ldg-menu so1] '("Sort Buffer" . ledger-sort-buffer)) + (define-key map [menu-bar ldg-menu so2] '("Sort Region" . ledger-sort-region)) (define-key map [menu-bar ldg-menu s2] '("--")) (define-key map [menu-bar ldg-menu te] '("Toggle Current Posting" . ledger-toggle-current)) (define-key map [menu-bar ldg-menu tt] '("Toggle Current Transaction" . ledger-toggle-current-entry)) |