[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: buffer is modified after commit
From: |
Stefan Monnier |
Subject: |
Re: buffer is modified after commit |
Date: |
Wed, 13 Feb 2008 14:50:33 -0500 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.0.50 (gnu/linux) |
> Well, after digging in my .emacs for a while, and several false
> starts, I've finally been able to isolate the "buffer is modified
> after commit" bug that was driving me crazy. Or, at least, I can now
> repeat it at will.
> ;;;;; .emacs ;;;;;
> (global-highlight-changes 1)
> ;;;;;;;;;;;;;;;;;;
If you look at hilit-chg.el you'll see that it's messing up the
buffer-modified-p on a regular basis.
1 - buffer-modified-p is properly saved&restored in
highlight-changes-rotate-faces and in highlight-markup-buffers.
That's the good part.
2 - it's not properly saved&restored anywhere else, despite uses of things
like remove-text-properties. That's the source of your trouble.
3 - buffer-modified-p is incorrectly forcefully set to nil by the
special undo entries added in highlight-changes-rotate-faces.
That's correct if the buffer was not modified before undoing
this command, but is dangerous otherwise (will mark your buffer as
unmodified even though you haven't saved the changes).
-- Stefan
- buffer is modified after commit, Juanma Barranquero, 2008/02/05
- Re: buffer is modified after commit, Juanma Barranquero, 2008/02/13
- Re: buffer is modified after commit, martin rudalics, 2008/02/13
- Re: buffer is modified after commit,
Stefan Monnier <=
- Re: buffer is modified after commit, martin rudalics, 2008/02/13
- Re: buffer is modified after commit, Stefan Monnier, 2008/02/13
- Re: buffer is modified after commit, Juanma Barranquero, 2008/02/13
- Re: buffer is modified after commit, martin rudalics, 2008/02/14
- Re: buffer is modified after commit, Stefan Monnier, 2008/02/14
- Re: buffer is modified after commit, martin rudalics, 2008/02/14