diff options
| author | Juanma Barranquero | 2014-03-04 16:07:59 +0100 |
|---|---|---|
| committer | Juanma Barranquero | 2014-03-04 16:07:59 +0100 |
| commit | f604dfdc367bf4c628c2c2b6b44ac00eed1f1589 (patch) | |
| tree | e3690f9c17b4cb4894628852939201dd2142eb91 | |
| parent | 5dc65319bc151182026cfa4af77c4fccdd710a25 (diff) | |
| download | emacs-f604dfdc367bf4c628c2c2b6b44ac00eed1f1589.tar.gz emacs-f604dfdc367bf4c628c2c2b6b44ac00eed1f1589.zip | |
lisp/hilit-chg.el (hilit-chg-unload-function): New function.
(highlight-changes-mode, highlight-changes-visible-mode): Fix typos.
(hilit-chg-map-changes): Prefer cardinal number to digit.
(hilit-chg-display-changes): Reflow docstring.
(highlight-changes-rotate-faces): Remove superfluous backslash.
| -rw-r--r-- | lisp/ChangeLog | 8 | ||||
| -rw-r--r-- | lisp/hilit-chg.el | 18 |
2 files changed, 20 insertions, 6 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 9d898acd13f..52d2728dad7 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,11 @@ | |||
| 1 | 2014-03-04 Juanma Barranquero <lekktu@gmail.com> | ||
| 2 | |||
| 3 | * hilit-chg.el (hilit-chg-unload-function): New function. | ||
| 4 | (highlight-changes-mode, highlight-changes-visible-mode): Fix typos. | ||
| 5 | (hilit-chg-map-changes): Prefer cardinal number to digit. | ||
| 6 | (hilit-chg-display-changes): Reflow docstring. | ||
| 7 | (highlight-changes-rotate-faces): Remove superfluous backslash. | ||
| 8 | |||
| 1 | 2014-03-04 Michael Albinus <michael.albinus@gmx.de> | 9 | 2014-03-04 Michael Albinus <michael.albinus@gmx.de> |
| 2 | 10 | ||
| 3 | * net/tramp-sh.el (tramp-sh-handle-vc-registered): Do not call | 11 | * net/tramp-sh.el (tramp-sh-handle-vc-registered): Do not call |
diff --git a/lisp/hilit-chg.el b/lisp/hilit-chg.el index eb930c5d8fa..0960aeed618 100644 --- a/lisp/hilit-chg.el +++ b/lisp/hilit-chg.el | |||
| @@ -333,7 +333,7 @@ enable the mode if ARG is omitted or nil. | |||
| 333 | 333 | ||
| 334 | When Highlight Changes is enabled, changes are marked with a text | 334 | When Highlight Changes is enabled, changes are marked with a text |
| 335 | property. Normally they are displayed in a distinctive face, but | 335 | property. Normally they are displayed in a distinctive face, but |
| 336 | command \\[highlight-changes-visible-mode] can be used to toggles | 336 | command \\[highlight-changes-visible-mode] can be used to toggle |
| 337 | this on and off. | 337 | this on and off. |
| 338 | 338 | ||
| 339 | Other functions for buffers in this mode include: | 339 | Other functions for buffers in this mode include: |
| @@ -379,7 +379,7 @@ in a distinctive face. | |||
| 379 | The default value can be customized with variable | 379 | The default value can be customized with variable |
| 380 | `highlight-changes-visibility-initial-state'. | 380 | `highlight-changes-visibility-initial-state'. |
| 381 | 381 | ||
| 382 | This command does not itself set highlight-changes mode." | 382 | This command does not itself set Highlight Changes mode." |
| 383 | 383 | ||
| 384 | t ;; init-value | 384 | t ;; init-value |
| 385 | nil ;; lighter | 385 | nil ;; lighter |
| @@ -455,7 +455,7 @@ Otherwise, this list will be constructed when needed from | |||
| 455 | "Call function FUNC for each region used by Highlight Changes mode. | 455 | "Call function FUNC for each region used by Highlight Changes mode. |
| 456 | If START-POSITION is nil, (point-min) is used. | 456 | If START-POSITION is nil, (point-min) is used. |
| 457 | If END-POSITION is nil, (point-max) is used. | 457 | If END-POSITION is nil, (point-max) is used. |
| 458 | FUNC is called with 3 params: PROPERTY START STOP." | 458 | FUNC is called with three params: PROPERTY START STOP." |
| 459 | (let ((start (or start-position (point-min))) | 459 | (let ((start (or start-position (point-min))) |
| 460 | (limit (or end-position (point-max))) | 460 | (limit (or end-position (point-max))) |
| 461 | prop end) | 461 | prop end) |
| @@ -470,8 +470,8 @@ FUNC is called with 3 params: PROPERTY START STOP." | |||
| 470 | (defun hilit-chg-display-changes (&optional beg end) | 470 | (defun hilit-chg-display-changes (&optional beg end) |
| 471 | "Display face information for Highlight Changes mode. | 471 | "Display face information for Highlight Changes mode. |
| 472 | 472 | ||
| 473 | An overlay from BEG to END containing a change face is added from the | 473 | An overlay from BEG to END containing a change face is added |
| 474 | information in the text property of type `hilit-chg'. | 474 | from the information in the text property of type `hilit-chg'. |
| 475 | 475 | ||
| 476 | This is the opposite of `hilit-chg-hide-changes'." | 476 | This is the opposite of `hilit-chg-hide-changes'." |
| 477 | (hilit-chg-map-changes 'hilit-chg-make-ov beg end)) | 477 | (hilit-chg-map-changes 'hilit-chg-make-ov beg end)) |
| @@ -731,7 +731,7 @@ You can automatically rotate colors when the buffer is saved by adding | |||
| 731 | this function to `write-file-functions' as a buffer-local value. To do | 731 | this function to `write-file-functions' as a buffer-local value. To do |
| 732 | this, eval the following in the buffer to be saved: | 732 | this, eval the following in the buffer to be saved: |
| 733 | 733 | ||
| 734 | \(add-hook 'write-file-functions 'highlight-changes-rotate-faces nil t)" | 734 | (add-hook 'write-file-functions 'highlight-changes-rotate-faces nil t)" |
| 735 | (interactive) | 735 | (interactive) |
| 736 | (when (and highlight-changes-mode highlight-changes-visible-mode) | 736 | (when (and highlight-changes-mode highlight-changes-visible-mode) |
| 737 | (let ((modified (buffer-modified-p)) | 737 | (let ((modified (buffer-modified-p)) |
| @@ -1022,6 +1022,12 @@ This is called when `global-highlight-changes-mode' is turned on." | |||
| 1022 | ;; | 1022 | ;; |
| 1023 | ;; ================== end of debug =============== | 1023 | ;; ================== end of debug =============== |
| 1024 | 1024 | ||
| 1025 | (defun hilit-chg-unload-function () | ||
| 1026 | "Unload the Highlight Changes library." | ||
| 1027 | (global-hi-lock-mode -1) | ||
| 1028 | ;; continue standard unloading | ||
| 1029 | nil) | ||
| 1030 | |||
| 1025 | (provide 'hilit-chg) | 1031 | (provide 'hilit-chg) |
| 1026 | 1032 | ||
| 1027 | ;;; hilit-chg.el ends here | 1033 | ;;; hilit-chg.el ends here |