Commit graph

53 commits

Author SHA1 Message Date
Steve Purcell
b810862bf1 [emacs] define-derived-mode calls set-syntax-table automatically 2014-12-13 17:20:52 +00:00
Steve Purcell
b0ab334ddf [emacs] Add syntax table so that ";" comments are handled
This allows things like goto-address-prog-mode to correctly
highlight URLs inside comments.
2014-12-13 17:15:44 +00:00
Steve Purcell
68574f8f59 [emacs] Don't use setq-local, which only appeared in Emacs 24.4
/cc @enderw88
2014-12-09 21:13:57 +00:00
Steve Purcell
0fb064443d [emacs] Simplify and tidy up ledger-occur
Introducing a proper minor mode saves a lot of the hand-rolled fiddling
about, like managing the overlay lifecycle and the modeline.
2014-12-09 21:01:44 +00:00
Steve Purcell
233313fb17 [emacs] Fix byte compilation warnings 2014-12-09 19:38:00 +00:00
Steve Purcell
7579057bc0 [emacs] Set comment-start to ";" so that comment-dwim works 2014-12-09 16:29:45 +00:00
Steve Purcell
b623306591 [emacs] Use markers instead of raw positions to make cleaning work better
Sometimes cleaning a buffer would leave the end of the buffer uncleaned,
because the end position would be moved along the way. This commit makes
the corresponding code use markers instead, which track the changes in
the buffer, and therefore ensure that the entire buffer is acted upon.
2014-12-09 15:11:44 +00:00
Craig Earls
a5d4d780dc Make reconcile more robust to empty or bad account entries at the prompt. 2014-12-05 21:30:29 -07:00
Craig Earls
df88ee6189 Tweak ledger-clean-up to attempt to find the exact you were at when you ordered the clean. 2014-12-05 06:59:57 -07:00
Craig Earls
438aaf251c Fix effective date command. 2014-12-01 20:07:32 -07:00
Craig Earls
3988de14bb Cleaned up commodities and completion code. 2014-11-30 19:47:14 -07:00
Craig Earls
db7e4fd741 Fix minor navigation bugs. Prev and next act now properly handle directives and empty lines 2014-11-15 21:36:34 -07:00
Craig Earls
8a87fd1310 Fix navigate bug keeping prev-xact key binding from working. 2014-11-09 09:05:13 -07:00
Craig Earls
7846e7c17a All navigation functions moved to ledger-navigate.
Reduce several overlapping functions.
2014-09-13 18:20:03 -07:00
Craig Earls
84dc532b06 everything appears to work with no empty lines between xacts. 2014-09-13 17:11:40 -07:00
Craig Earls
bfc925f52f Minor refactoring and code cleanup 2014-09-10 07:16:32 -07:00
Craig Earls
ad87ab16e4 New fortification is working.
Code pruned.
2014-09-08 20:36:11 -07:00
Craig Earls
77e77f39dc Solved the fight between jit-lock. But for some reason it isn't calling it for all regions in the buffer. 2014-09-05 21:59:23 -07:00
Craig Earls
991d162fb0 jit-lock is now calling ledger-fontify-buffer-part, but font-lock-fontify-region is still being called and fighting with it. 2014-09-05 21:45:36 -07:00
Craig Earls
fec5ecb4f3 meh. Still chugging along. 2014-09-05 20:12:03 -07:00
Craig Earls
91fc39c68d not much progress here. 2014-09-04 20:41:51 -07:00
Craig Earls
dd3fd0e9de no message 2014-08-26 20:10:51 -07:00
Craig Earls
403ca4f1a5 Not working well, try something else on new-fontification-scheme-2 2014-08-26 18:33:41 -07:00
Craig Earls
4deaeb02c9 Set up fontification independent of font-lock.
Basic functionality in place.  need to test further and expand detail fortification.
2014-08-24 18:37:24 -07:00
Craig Earls
9c664ca3db make leder-mode-dump-configuration interactive 2014-07-13 09:30:20 -07:00
Craig Earls
4606bb293d ledger-redo added as after-save-hook 2014-07-12 21:50:28 -07:00
Craig Earls
19adbf0400 Code cleanup 2014-07-12 21:34:35 -07:00
Craig Earls
add716f776 ledger reconcile will recommend the account in the posting, even if point isn't in it. 2014-06-29 19:44:02 -07:00
Craig Earls
3a2eb94bef Fix bug 1052 ledger-mode mangles transactions with tabs. 2014-06-25 20:50:07 -07:00
thdox
d2db0f9102 Indent & untabify
M-x mark-whole-buffer
M-x indent-region
M-x mark-whole-buffer
M-x untabify
2014-05-17 16:52:06 +02:00
Jamie Nguyen
33ce4a76a1 Update old FSF address 2014-03-23 23:42:21 +00:00
Alexis Hildebrandt
2b9208e850 Bump copyright information to 2014 2014-02-02 12:36:22 +01:00
Steve Purcell
3b5f496536 ledger-mode: only modify completion-at-point-functions locally
Without this patch, the addition of pcomplete-completions-at-point
leaks into the global value of completion-at-point-functions.

See #227
2014-01-07 20:33:08 +00:00
Moritz Ulrich
8406adce0e ledger-read-date': Use ledger-minibuffer-history'. 2014-01-02 18:55:25 +01:00
Moritz Ulrich
26bc890d88 ledger-insert-effective-date': use ledger-read-date'.
Running `ledger-insert-effective-date' will now prompt for a date with
a pre-filled value of the `(ledger-year-and-month)' ("2014/01/"). Just
pressing RET without inserting the 'day'-portion will insert the date
of today.
2014-01-02 18:43:53 +01:00
Moritz Ulrich
3ff5fddafd Add `ledger-read-date' - Read date & default to today. 2014-01-02 18:24:54 +01:00
4ourbit
316b1b7cfe Plugging ledger pcomplete into completion-at-point.
Added documentation on how to use pcomplete transparently via completion-at-point.
2014-01-01 22:00:26 +01:00
4ourbit
383f17f114 Context-aware pcomplete rules.
Provide completions based on information retrieved with 'ledger-context-at-point'.
To support step-by-step completion of transactions some more patterns were added
to 'ledger-line-config'. The actual completion rules mostly reuse some of the
convenient input commands that are buried in ledger-mode. Using the standard
pcomplete termination string (" ") to allow a "context switch" at the end of each
completion step.
2013-12-31 03:16:57 +01:00
Moritz Ulrich
9f694169a8 ledger-mode: Introduce `ledger-default-date-format'.
Some elisp functions depend on a date-format supplied in ~/.ledgerrc. Change these by introducing a default ("%Y/%m/%d").

Signed-off-by: Moritz Ulrich <moritz@tarn-vedra.de>
2013-12-30 01:41:31 +01:00
Moritz Ulrich
7dd82f8bac Improve `ledger-insert-effective-date'.
The function now replaces already existing effective dates in the same
line.

With a prefix (C-u C-c C-t), remove the current effective date.

Signed-off-by: Moritz Ulrich <moritz@tarn-vedra.de>
2013-12-30 00:50:48 +01:00
Moritz Ulrich
6dbb36f525 ledger-mode: Add `ledger-remove-effective-date'.
Signed-off-by: Moritz Ulrich <moritz@tarn-vedra.de>
2013-12-30 00:22:43 +01:00
Steve Purcell
6eca277bbc ledger-mode: Remove duplication in ledger-set-{year,month} 2013-12-11 08:36:22 +00:00
Steve Purcell
75a2d9d31e ledger-mode: Add namespace prefix to highlight-overlay
make-variable-buffer-local is a top-level form: this commit moves that
call from ledger-mode to next to the variable's declaration.
2013-12-11 08:36:22 +00:00
Steve Purcell
aaf20ab07f ledger-mode: Use easymenu to remove boilerplate
Among other benefits, this lets us define the menu entries from top to
bottom, rather than in reverse.
2013-12-11 08:31:07 +00:00
Steve Purcell
c85643b04e ledger-mode: declare keymaps at the top level 2013-12-09 20:41:01 +00:00
Steve Purcell
a74053b010 ledger-mode: define and use a syntax table so that comments are handled properly
Specifically, functionality which uses syntax-ppss to detect comments
needs the syntax table to be aware of them. A prime example is
goto-address-prog-mode.

This commit adds a basic syntax table for this purpose.
2013-12-09 19:11:23 +00:00
Craig Earls
1db0b0892c Merge branch 'master' into ledger-mode-automatic-transactions 2013-11-06 08:48:54 -07:00
Steve Purcell
979b5b990a Fix provided feature to match file/package name
For `require` to work correctly, the provided feature name
must match the name of the file.
2013-11-03 21:34:55 +00:00
Craig Earls
8b84aff855 Merge branch 'master' into ledger-mode-automatic-transactions 2013-07-19 16:41:56 -07:00
Gergely Risko
87da7ba3ab Fix comment string 2013-07-09 16:41:55 +02:00