comparison lisp/hilit-chg.el @ 93624:cb11f55e7732

(highlight-changes-visibility-initial-state, hilit-chg-update, highlight-changes-mode-turn-on): Fix typos in docstrings.
author Juanma Barranquero <lekktu@gmail.com>
date Thu, 03 Apr 2008 23:50:37 +0000
parents dfdeba5ae4fd
children 49c6cb8751f6
comparison
equal deleted inserted replaced
93623:0d8f85920a66 93624:cb11f55e7732
245 245
246 (define-obsolete-variable-alias 'highlight-changes-initial-state 246 (define-obsolete-variable-alias 'highlight-changes-initial-state
247 'highlight-changes-visibility-initial-state) 247 'highlight-changes-visibility-initial-state)
248 248
249 (defcustom highlight-changes-visibility-initial-state t 249 (defcustom highlight-changes-visibility-initial-state t
250 "Controls whether changes are initially be visible in Highlight Changes mode. 250 "Controls whether changes are initially visible in Highlight Changes mode.
251 251
252 This controls the initial value of highlght-changes-visibile-mode. 252 This controls the initial value of `highlight-changes-visible-mode'.
253 When a buffer is in Highlight Changes mode the function 253 When a buffer is in Highlight Changes mode the function
254 highlght-changes-visibile-mode is used to toggle the mode on or off." 254 `highlight-changes-visible-mode' is used to toggle the mode on or off."
255 :type 'boolean 255 :type 'boolean
256 :group 'highlight-changes) 256 :group 'highlight-changes)
257 257
258 ;; highlight-changes-global-initial-state has been removed 258 ;; highlight-changes-global-initial-state has been removed
259 259
465 (const :tag "Derive from highlight-changes-colors" nil) 465 (const :tag "Derive from highlight-changes-colors" nil)
466 ) 466 )
467 :group 'highlight-changes) 467 :group 'highlight-changes)
468 468
469 469
470 (defun hilit-chg-map-changes (func &optional start-position end-position) 470 (defun hilit-chg-map-changes (func &optional start-position end-position)
471 "Call function FUNC for each region used by Highlight Changes mode. 471 "Call function FUNC for each region used by Highlight Changes mode.
472 If START-POSITION is nil, (point-min) is used. 472 If START-POSITION is nil, (point-min) is used.
473 If END-POSITION is nil, (point-max) is used. 473 If END-POSITION is nil, (point-max) is used.
474 FUNC is called with 3 params: PROPERTY START STOP." 474 FUNC is called with 3 params: PROPERTY START STOP."
475 (let ((start (or start-position (point-min))) 475 (let ((start (or start-position (point-min)))
616 (put-text-property beg end 'hilit-chg type)) 616 (put-text-property beg end 'hilit-chg type))
617 (if (or highlight-changes-visible-mode no-property-change) 617 (if (or highlight-changes-visible-mode no-property-change)
618 (hilit-chg-make-ov type beg end))))))) 618 (hilit-chg-make-ov type beg end)))))))
619 619
620 (defun hilit-chg-update () 620 (defun hilit-chg-update ()
621 "Update a buffer's highlight changes when visibiility changed." 621 "Update a buffer's highlight changes when visibility changed."
622 (if highlight-changes-visible-mode 622 (if highlight-changes-visible-mode
623 ;; changes are visible 623 ;; changes are visible
624 (progn 624 (progn
625 (setq hilit-chg-string highlight-changes-visible-string) 625 (setq hilit-chg-string highlight-changes-visible-string)
626 (or buffer-read-only 626 (or buffer-read-only
1004 (define-obsolete-function-alias 1004 (define-obsolete-function-alias
1005 'global-highlight-changes 1005 'global-highlight-changes
1006 'global-highlight-changes-mode "22.1") 1006 'global-highlight-changes-mode "22.1")
1007 1007
1008 (defun highlight-changes-mode-turn-on () 1008 (defun highlight-changes-mode-turn-on ()
1009 "See if highlight-changes-mode should be turned on for this buffer. 1009 "See if Highlight Changes mode should be turned on for this buffer.
1010 This is called when global-highlight-changes-mode is turned on." 1010 This is called when `global-highlight-changes-mode' is turned on."
1011 (or highlight-changes-mode ; do nothing if already on 1011 (or highlight-changes-mode ; do nothing if already on
1012 (if 1012 (if
1013 (cond 1013 (cond
1014 ((null highlight-changes-global-modes) 1014 ((null highlight-changes-global-modes)
1015 nil) 1015 nil)