diff options
| author | Glenn Morris | 2008-12-02 03:32:41 +0000 |
|---|---|---|
| committer | Glenn Morris | 2008-12-02 03:32:41 +0000 |
| commit | 2da6792633e8f6282a291487862404d63e360348 (patch) | |
| tree | bf7f64d5187fa3d16cae1a510ea45540531dcba2 | |
| parent | 11ee272ded5e46e578b321264c2ef3b59d5ee138 (diff) | |
| download | emacs-2da6792633e8f6282a291487862404d63e360348.tar.gz emacs-2da6792633e8f6282a291487862404d63e360348.zip | |
Lennart Borgman <lennart.borgman at gmail.com>
(nxml-indent-line): Don't re-indent lines that already have the
correct indentation. (Bug#859)
| -rw-r--r-- | lisp/nxml/nxml-mode.el | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lisp/nxml/nxml-mode.el b/lisp/nxml/nxml-mode.el index 49dcaecaab5..a2b20b25f4a 100644 --- a/lisp/nxml/nxml-mode.el +++ b/lisp/nxml/nxml-mode.el | |||
| @@ -1370,7 +1370,8 @@ of the inserted start-tag or nil if none was inserted." | |||
| 1370 | "Indent current line as XML." | 1370 | "Indent current line as XML." |
| 1371 | (let ((indent (nxml-compute-indent)) | 1371 | (let ((indent (nxml-compute-indent)) |
| 1372 | (from-end (- (point-max) (point)))) | 1372 | (from-end (- (point-max) (point)))) |
| 1373 | (when indent | 1373 | (when (and indent |
| 1374 | (/= indent (current-indentation))) | ||
| 1374 | (beginning-of-line) | 1375 | (beginning-of-line) |
| 1375 | (let ((bol (point))) | 1376 | (let ((bol (point))) |
| 1376 | (skip-chars-forward " \t") | 1377 | (skip-chars-forward " \t") |