comparison lisp/whitespace.el @ 97311:2be7f5365285

Improve docstring.
author Vinicius Jose Latorre <viniciusjl@ig.com.br>
date Wed, 06 Aug 2008 03:35:04 +0000
parents 8b6a3348313d
children 4ec5decd0683
comparison
equal deleted inserted replaced
97310:92e6692c8467 97311:2be7f5365285
159 ;; M-x global-whitespace-mode RET 159 ;; M-x global-whitespace-mode RET
160 ;; 160 ;;
161 ;; There are also the following useful commands: 161 ;; There are also the following useful commands:
162 ;; 162 ;;
163 ;; `whitespace-newline-mode' 163 ;; `whitespace-newline-mode'
164 ;; Toggle newline minor mode visualization ("nl" on modeline). 164 ;; Toggle NEWLINE minor mode visualization ("nl" on modeline).
165 ;; 165 ;;
166 ;; `global-whitespace-newline-mode' 166 ;; `global-whitespace-newline-mode'
167 ;; Toggle newline global minor mode visualization ("NL" on modeline). 167 ;; Toggle NEWLINE global minor mode visualization ("NL" on modeline).
168 ;; 168 ;;
169 ;; `whitespace-report' 169 ;; `whitespace-report'
170 ;; Report some blank problems in buffer. 170 ;; Report some blank problems in buffer.
171 ;; 171 ;;
172 ;; `whitespace-report-region' 172 ;; `whitespace-report-region'
339 ;; 339 ;;
340 ;; Thanks to TimOCallaghan (EmacsWiki) for the idea about highlight 340 ;; Thanks to TimOCallaghan (EmacsWiki) for the idea about highlight
341 ;; "long" lines. See EightyColumnRule (EmacsWiki). 341 ;; "long" lines. See EightyColumnRule (EmacsWiki).
342 ;; 342 ;;
343 ;; Thanks to Yanghui Bian <yanghuibian@gmail.com> for indicating a new 343 ;; Thanks to Yanghui Bian <yanghuibian@gmail.com> for indicating a new
344 ;; newline character mapping. 344 ;; NEWLINE character mapping.
345 ;; 345 ;;
346 ;; Thanks to Pete Forman <pete.forman@westgeo.com> for indicating 346 ;; Thanks to Pete Forman <pete.forman@westgeo.com> for indicating
347 ;; whitespace-mode.el on XEmacs. 347 ;; whitespace-mode.el on XEmacs.
348 ;; 348 ;;
349 ;; Thanks to Miles Bader <miles@gnu.org> for handling display table via 349 ;; Thanks to Miles Bader <miles@gnu.org> for handling display table via
1010 "Toggle whitespace minor mode visualization (\"ws\" on modeline). 1010 "Toggle whitespace minor mode visualization (\"ws\" on modeline).
1011 1011
1012 If ARG is null, toggle whitespace visualization. 1012 If ARG is null, toggle whitespace visualization.
1013 If ARG is a number greater than zero, turn on visualization; 1013 If ARG is a number greater than zero, turn on visualization;
1014 otherwise, turn off visualization. 1014 otherwise, turn off visualization.
1015 Only useful with a windowing system." 1015 Only useful with a windowing system.
1016
1017 See also `whitespace-style', `whitespace-newline' and
1018 `whitespace-display-mappings'."
1016 :lighter " ws" 1019 :lighter " ws"
1017 :init-value nil 1020 :init-value nil
1018 :global nil 1021 :global nil
1019 :group 'whitespace 1022 :group 'whitespace
1020 (cond 1023 (cond
1027 (whitespace-turn-off)))) 1030 (whitespace-turn-off))))
1028 1031
1029 1032
1030 ;;;###autoload 1033 ;;;###autoload
1031 (define-minor-mode whitespace-newline-mode 1034 (define-minor-mode whitespace-newline-mode
1032 "Toggle newline minor mode visualization (\"nl\" on modeline). 1035 "Toggle NEWLINE minor mode visualization (\"nl\" on modeline).
1033 1036
1034 If ARG is null, toggle newline visualization. 1037 If ARG is null, toggle NEWLINE visualization.
1035 If ARG is a number greater than zero, turn on visualization; 1038 If ARG is a number greater than zero, turn on visualization;
1036 otherwise, turn off visualization. 1039 otherwise, turn off visualization.
1037 Only useful with a windowing system. 1040 Only useful with a windowing system.
1038 1041
1039 See also `whitespace-newline'." 1042 Use `whitespace-newline-mode' only for NEWLINE visualization
1043 exclusively. For other visualizations, including NEWLINE
1044 visualization together with (HARD) SPACEs and/or TABs, please,
1045 use `whitespace-mode'.
1046
1047 See also `whitespace-newline' and `whitespace-display-mappings'."
1040 :lighter " nl" 1048 :lighter " nl"
1041 :init-value nil 1049 :init-value nil
1042 :global nil 1050 :global nil
1043 :group 'whitespace 1051 :group 'whitespace
1044 (let ((whitespace-style '(newline-mark newline))) 1052 (let ((whitespace-style '(newline-mark newline)))
1056 "Toggle whitespace global minor mode visualization (\"WS\" on modeline). 1064 "Toggle whitespace global minor mode visualization (\"WS\" on modeline).
1057 1065
1058 If ARG is null, toggle whitespace visualization. 1066 If ARG is null, toggle whitespace visualization.
1059 If ARG is a number greater than zero, turn on visualization; 1067 If ARG is a number greater than zero, turn on visualization;
1060 otherwise, turn off visualization. 1068 otherwise, turn off visualization.
1061 Only useful with a windowing system." 1069 Only useful with a windowing system.
1070
1071 See also `whitespace-style', `whitespace-newline' and
1072 `whitespace-display-mappings'."
1062 :lighter " WS" 1073 :lighter " WS"
1063 :init-value nil 1074 :init-value nil
1064 :global t 1075 :global t
1065 :group 'whitespace 1076 :group 'whitespace
1066 (cond 1077 (cond
1105 (whitespace-turn-on))))) 1116 (whitespace-turn-on)))))
1106 1117
1107 1118
1108 ;;;###autoload 1119 ;;;###autoload
1109 (define-minor-mode global-whitespace-newline-mode 1120 (define-minor-mode global-whitespace-newline-mode
1110 "Toggle newline global minor mode visualization (\"NL\" on modeline). 1121 "Toggle NEWLINE global minor mode visualization (\"NL\" on modeline).
1111 1122
1112 If ARG is null, toggle newline visualization. 1123 If ARG is null, toggle NEWLINE visualization.
1113 If ARG is a number greater than zero, turn on visualization; 1124 If ARG is a number greater than zero, turn on visualization;
1114 otherwise, turn off visualization. 1125 otherwise, turn off visualization.
1115 Only useful with a windowing system. 1126 Only useful with a windowing system.
1116 1127
1117 See also `whitespace-newline'." 1128 Use `global-whitespace-newline-mode' only for NEWLINE
1129 visualization exclusively. For other visualizations, including
1130 NEWLINE visualization together with (HARD) SPACEs and/or TABs,
1131 please, use `global-whitespace-mode'.
1132
1133 See also `whitespace-newline' and `whitespace-display-mappings'."
1118 :lighter " NL" 1134 :lighter " NL"
1119 :init-value nil 1135 :init-value nil
1120 :global t 1136 :global t
1121 :group 'whitespace 1137 :group 'whitespace
1122 (let ((whitespace-style '(newline-mark newline))) 1138 (let ((whitespace-style '(newline-mark newline)))