diff options
| author | Miles Bader | 2006-02-04 01:01:38 +0000 |
|---|---|---|
| committer | Miles Bader | 2006-02-04 01:01:38 +0000 |
| commit | 307f5c57467e8e967f795d47ec885bf19fd5317f (patch) | |
| tree | 937b5ce4db7094b06d5c1cf58413ca49b860e5db | |
| parent | 50d4fbde0cd35834e2fc9f0adc4c189657ba7170 (diff) | |
| parent | 6203370b5e51fe55a4132fe8ccc868c35ad8c67f (diff) | |
| download | emacs-307f5c57467e8e967f795d47ec885bf19fd5317f.tar.gz emacs-307f5c57467e8e967f795d47ec885bf19fd5317f.zip | |
Revision: emacs@sv.gnu.org/emacs--unicode--0--patch-11
Merge from emacs--devo--0
Patches applied:
* emacs--devo--0 (patch 34-42)
- Update from CVS
- Merge from gnus--rel--5.10
* gnus--rel--5.10 (patch 14-17)
- Update from CVS
- Merge from emacs--devo--0
75 files changed, 2284 insertions, 1186 deletions
diff --git a/INSTALL.CVS b/INSTALL.CVS index fa5b8e4958c..ce3fa9f2627 100644 --- a/INSTALL.CVS +++ b/INSTALL.CVS | |||
| @@ -25,18 +25,17 @@ procedure: | |||
| 25 | (If you want to install the Emacs binary, type "make install" instead | 25 | (If you want to install the Emacs binary, type "make install" instead |
| 26 | of "make" in the last command.) | 26 | of "make" in the last command.) |
| 27 | 27 | ||
| 28 | Occasionally the files "lisp/loaddefs.el" or lisp/mh-e/mh-loaddefs.el | 28 | Occasionally the file "lisp/loaddefs.el" will need be updated to |
| 29 | will need be updated to reflect new autoloaded functions. If you see | 29 | reflect new autoloaded functions. If you see errors about undefined |
| 30 | errors about undefined lisp functions during compilation, that may be | 30 | lisp functions during compilation, that may be the reason. Another |
| 31 | the reason. Another symptom may be an error saying that "loaddefs.el" | 31 | symptom may be an error saying that "loaddefs.el" could not be found; |
| 32 | could not be found; this is due to a change in the way loaddefs.el was | 32 | this is due to a change in the way loaddefs.el was handled in CVS, and |
| 33 | handled in CVS, and should only happen once, for users that are | 33 | should only happen once, for users that are updating old CVS trees. |
| 34 | updating old CVS trees. | ||
| 35 | 34 | ||
| 36 | To update loaddefs.el and mh-loaddefs.el, do: | 35 | To update loaddefs.el, do: |
| 37 | 36 | ||
| 38 | $ cd lisp | 37 | $ cd lisp |
| 39 | $ make autoloads mh-autoloads EMACS=../src/emacs | 38 | $ make autoloads EMACS=../src/emacs |
| 40 | 39 | ||
| 41 | If either of the above partial procedures fails, try "make bootstrap". | 40 | If either of the above partial procedures fails, try "make bootstrap". |
| 42 | 41 | ||
diff --git a/etc/ChangeLog b/etc/ChangeLog index 7d975861e63..5411a0cf626 100644 --- a/etc/ChangeLog +++ b/etc/ChangeLog | |||
| @@ -1,3 +1,15 @@ | |||
| 1 | 2006-02-03 Bill Wohler <wohler@newt.com> | ||
| 2 | |||
| 3 | Release MH-E version 7.91. | ||
| 4 | |||
| 5 | * NEWS, MH-E-NEWS: Update for MH-E release 7.91. | ||
| 6 | |||
| 7 | 2006-02-02 Bill Wohler <wohler@newt.com> | ||
| 8 | |||
| 9 | Release MH-E version 7.90. | ||
| 10 | |||
| 11 | * NEWS, MH-E-NEWS: Update for MH-E release 7.90. | ||
| 12 | |||
| 1 | 2006-01-29 Michael Olson <mwolson@gnu.org> | 13 | 2006-01-29 Michael Olson <mwolson@gnu.org> |
| 2 | 14 | ||
| 3 | * NEWS: Add entry for ERC. | 15 | * NEWS: Add entry for ERC. |
diff --git a/etc/MH-E-NEWS b/etc/MH-E-NEWS index ba13b8aca15..8dc89e3cbcf 100644 --- a/etc/MH-E-NEWS +++ b/etc/MH-E-NEWS | |||
| @@ -1,11 +1,420 @@ | |||
| 1 | * COPYRIGHT | 1 | * COPYRIGHT |
| 2 | 2 | ||
| 3 | Copyright (C) 2003, 2004, 2005 Free Software Foundation, Inc. | 3 | Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | Copying and distribution of this file, with or without modification, | 5 | Copying and distribution of this file, with or without modification, |
| 6 | are permitted in any medium without royalty provided the copyright | 6 | are permitted in any medium without royalty provided the copyright |
| 7 | notice and this notice are preserved. | 7 | notice and this notice are preserved. |
| 8 | 8 | ||
| 9 | * Changes in MH-E 7.91 | ||
| 10 | |||
| 11 | Version 7.91 is the second 8.0 beta release and fixes several bugs | ||
| 12 | that were uncovered in wider testing. | ||
| 13 | |||
| 14 | * Changes in MH-E 7.90 | ||
| 15 | |||
| 16 | Version 7.90 is the first 8.0 beta release and is a release that has | ||
| 17 | finally broken away from some unfortunate legacy decisions in favor of | ||
| 18 | something that will be easier to use and support. Many bugs were fixed | ||
| 19 | and many features were added, including making the pick search | ||
| 20 | equivalent to the other types of searches. | ||
| 21 | |||
| 22 | The rewrite of the manual accelerated dramatically in recent months | ||
| 23 | and drove the changes in this release. In order to make the | ||
| 24 | manual--and hence the software--better, clearer, more consistent, more | ||
| 25 | predictable, and easier to understand, many variables and functions | ||
| 26 | were renamed. The changes to the user-visible variables are listed | ||
| 27 | here. It is our hope that you, dear MH-E user, will embrace the | ||
| 28 | changes for the better and forgive us from making so many incompatible | ||
| 29 | changes. | ||
| 30 | |||
| 31 | If you use undocumented functionality, be sure to read the ChangeLog | ||
| 32 | for changes that might affect you. | ||
| 33 | |||
| 34 | ** New Features in MH-E 7.90 | ||
| 35 | |||
| 36 | *** Entry Points Have Moved | ||
| 37 | |||
| 38 | Emacs 21 users must now add `(require 'mh-autoloads)' because the | ||
| 39 | entry points (such as `mh-rmail' and `mh-smail') have moved to | ||
| 40 | different files which have made the autoloads that come with Emacs | ||
| 41 | inaccurate. This change was necessary because the code was reorganized | ||
| 42 | to remove circular dependencies, to make the code more stable and | ||
| 43 | maintainable, and to reduce the time to load MH-E. | ||
| 44 | |||
| 45 | *** MH-E No Longer Calls install-mh | ||
| 46 | |||
| 47 | The new variant detection code makes use of `mhparam' which assumes | ||
| 48 | that your MH environment has already been set up. The code to call | ||
| 49 | `install-mh', which could no longer be run anyway, was removed. | ||
| 50 | |||
| 51 | *** Use run-hook-with-args | ||
| 52 | |||
| 53 | We use normal hooks whenever possible and do not use | ||
| 54 | `run-hook-with-args' (with one documented exception) (closes SF | ||
| 55 | #643702). | ||
| 56 | |||
| 57 | *** Merge mh-index.el and mh-pick.el | ||
| 58 | |||
| 59 | We merged `mh-index.el' and `mh-pick.el' into a new file | ||
| 60 | `mh-search.el'. As part of this process, the old `F s' behavior of | ||
| 61 | adding messages to the search sequence has been removed. The `F i' | ||
| 62 | keybinding was then renamed to `F s' (`mh-search'). The mode of the | ||
| 63 | search-pattern buffer was renamed from MH-Pick to MH-Search. Within | ||
| 64 | the MH-Search buffer, the command `C-c C-p' (`mh-pick-do-search') now | ||
| 65 | runs pick on the given folder recursively and displays the results in | ||
| 66 | a search folder like the other search methods (closes SF #829207). | ||
| 67 | |||
| 68 | *** Improve Security of mh-fetch-x-image-url | ||
| 69 | |||
| 70 | The default has been changed to "Never Fetch." Those of you who like | ||
| 71 | the value of "Ask Before Fetching" will have to customize this option | ||
| 72 | (closes SF #831278). | ||
| 73 | |||
| 74 | *** Remove Emacs 20 Support | ||
| 75 | |||
| 76 | As it turns out, we had already added some code that didn't work on | ||
| 77 | Emacs 20. However, now we've formalized it and removed code that was | ||
| 78 | present solely for Emacs 20 support (closes SF #1359240). | ||
| 79 | |||
| 80 | *** Derive mh-letter-mode from mail-mode | ||
| 81 | |||
| 82 | MH-Letter mode is now derived from `mail-mode'. We were able to delete | ||
| 83 | a lot of code. In return, there are a few `mail-mode' commands that | ||
| 84 | are available that may or may not be useful and the `mail-mode-hook' | ||
| 85 | is run (closes SF #1385571). | ||
| 86 | |||
| 87 | *** Add Choices to mh-to-field-choices | ||
| 88 | |||
| 89 | In MH-Letter mode, you can use the "C-c C-f (mh-to-field)" prefix to | ||
| 90 | go to and insert fields. The fields "Reply-To:", "Mail-Reply-To:", | ||
| 91 | "Mail-Followup-To:" can now be created via the "C-r", "C-a" (for | ||
| 92 | author), and "C-l" keys respectively. The key for the "From:" field | ||
| 93 | has been renamed from "C-r" to "C-m" for consistency with `mail-mode' | ||
| 94 | (closes SF #1400139). | ||
| 95 | |||
| 96 | *** MH-Folder Keymap Changes | ||
| 97 | |||
| 98 | The function `mh-ps-print-toggle-mime' was never implemented and the | ||
| 99 | functionality in `mh-ps-print-msg-show' was better afforded by | ||
| 100 | `mh-ps-print-msg' and `mh-ps-print-msg-file'. | ||
| 101 | |||
| 102 | Key 7.4.85 7.4.90 | ||
| 103 | |||
| 104 | F i mh-index-search - | ||
| 105 | F s mh-search-folder mh-search | ||
| 106 | P A mh-ps-print-toggle-mime - | ||
| 107 | P M mh-ps-print-toggle-mime - | ||
| 108 | P s mh-ps-print-msg-show - | ||
| 109 | |||
| 110 | *** MH-Letter Keymap Changes | ||
| 111 | |||
| 112 | The change where `mh-letter-mode' derives from `mail-mode' adds a few | ||
| 113 | keybindings. Some are interesting; experiment! Most of the changes | ||
| 114 | have to do with the renaming of the functions with "mhn" in them to | ||
| 115 | "mh" because nmh doesn't use `mhn'. The names were also made | ||
| 116 | consistent with the the family of "mml" functions. | ||
| 117 | |||
| 118 | Key 7.4.85 7.4.90 | ||
| 119 | |||
| 120 | C-c C-e mh-edit-mhn mh-mh-to-mime | ||
| 121 | C-c C-f C-a - mh-to-field | ||
| 122 | C-c C-f C-l - mh-to-field | ||
| 123 | C-c C-f RET - mh-to-field | ||
| 124 | C-c C-f a - mh-to-field | ||
| 125 | C-c C-f l - mh-to-field | ||
| 126 | C-c C-f m - mh-to-field | ||
| 127 | C-c RET C-g mh-mhn-compose-anon-ftp mh-mh-compose-anon-ftp | ||
| 128 | C-c RET C-t mh-mhn-compose-external-compressed-tar | ||
| 129 | mh-mh-compose-external-compressed-tar | ||
| 130 | C-c RET C-u mh-revert-mhn-edit mh-mh-to-mime-undo | ||
| 131 | C-c RET C-x mh-mhn-compose-external-type mh-mh-compose-external-type | ||
| 132 | C-c RET g mh-mhn-compose-anon-ftp mh-mh-compose-anon-ftp | ||
| 133 | C-c RET t mh-mhn-compose-external-compressed-tar | ||
| 134 | mh-mh-compose-external-compressed-tar | ||
| 135 | C-c RET u mh-revert-mhn-edit mh-mh-to-mime-undo | ||
| 136 | C-c RET x mh-mhn-compose-external-type mh-mh-compose-external-type | ||
| 137 | |||
| 138 | *** MH-Search Keymap Changes | ||
| 139 | |||
| 140 | These are the changes associated with the new search mode. The command | ||
| 141 | `C-c C-c' (`mh-index-do-search') now performs the standard indexed | ||
| 142 | search, while `C-c C-p' (`mh-pick-do-search') runs pick as before, | ||
| 143 | only better! | ||
| 144 | |||
| 145 | Key 7.4.85 7.4.90 | ||
| 146 | |||
| 147 | C-c C-c mh-do-search mh-index-do-search | ||
| 148 | C-c TAB mh-index-do-search - | ||
| 149 | |||
| 150 | ** New Variables in MH-E 7.90 | ||
| 151 | |||
| 152 | *** mh-after-commands-processed-hook | ||
| 153 | |||
| 154 | Hook run by `x' (`mh-execute-commands') after performing outstanding | ||
| 155 | refile and delete requests. | ||
| 156 | |||
| 157 | *** mh-before-commands-processed-hook | ||
| 158 | |||
| 159 | Renamed from `mh-folder-updated-hook'. It wasn't clear whether | ||
| 160 | `mh-folder-updated-hook' was run before or after the commands were | ||
| 161 | executed. We now provide both with clear names. | ||
| 162 | |||
| 163 | *** mh-highlight-citation-style | ||
| 164 | |||
| 165 | Renamed from `mh-highlight-citation-p' since it wasn't a boolean. The | ||
| 166 | new name is also more descriptive. | ||
| 167 | |||
| 168 | *** mh-insert-signature-hook | ||
| 169 | |||
| 170 | Renamed from `mh-letter-insert-signature-hook' since most of the other | ||
| 171 | hooks do not carry the mode in the prefix and because the new name is | ||
| 172 | equally clear. | ||
| 173 | |||
| 174 | *** mh-kill-folder-suppress-prompt-hooks | ||
| 175 | |||
| 176 | Renamed from `mh-kill-folder-suppress-prompt-hook'. By convention, | ||
| 177 | abnormal hooks, which this is, either have a -function or -hooks | ||
| 178 | suffix. | ||
| 179 | |||
| 180 | *** mh-mhl-format-file | ||
| 181 | |||
| 182 | Renamed from `mhl-formfile' to put it in the MH-E namespace and to be | ||
| 183 | consistent with other similar options. | ||
| 184 | |||
| 185 | *** mh-mh-to-mime-hook | ||
| 186 | |||
| 187 | Renamed from `mh-edit-mhn-hook'. We have a family of `mh-mml-to-mime' | ||
| 188 | functions and variables; the older mhn functions and variables were | ||
| 189 | renamed to have a consistent `mh-mh-to-mime' prefix. | ||
| 190 | |||
| 191 | *** mh-new-messages-folders | ||
| 192 | |||
| 193 | Renamed from `mh-index-new-messages-folders' for clarity. | ||
| 194 | |||
| 195 | *** mh-path | ||
| 196 | |||
| 197 | Additional list of directories to search for MH. | ||
| 198 | |||
| 199 | *** mh-redist-full-contents-flag | ||
| 200 | |||
| 201 | On means the `dist' command needs entire letter for redistribution. | ||
| 202 | This was previously a variable. It's now an option. | ||
| 203 | |||
| 204 | *** mh-search-mode-hook | ||
| 205 | |||
| 206 | Renamed from `mh-pick-mode-hook' as part of the | ||
| 207 | `mh-index.el'/`mh-pick.el' merge into `mh-search.el'. | ||
| 208 | |||
| 209 | *** mh-search-program | ||
| 210 | |||
| 211 | Renamed from `mh-index-program' as part of the | ||
| 212 | `mh-index.el'/`mh-pick.el' merge into `mh-search.el'. | ||
| 213 | |||
| 214 | *** mh-sortm-args | ||
| 215 | |||
| 216 | Additional arguments for `sortm'. This was previously an internal | ||
| 217 | variable. It's now an user-customizable option. | ||
| 218 | |||
| 219 | *** mh-speed-update-interval | ||
| 220 | |||
| 221 | Renamed from `mh-speed-flists-interval' for clarity. | ||
| 222 | |||
| 223 | *** mh-ticked-messages-folders | ||
| 224 | |||
| 225 | Renamed from `mh-index-ticked-messages-folders' for clarity. | ||
| 226 | |||
| 227 | *** mh-xemacs-tool-bar-position | ||
| 228 | |||
| 229 | Renamed from `mh-xemacs-toolbar-position' per GNU Emacs naming conventions. | ||
| 230 | |||
| 231 | *** mh-xemacs-use-tool-bar-flag | ||
| 232 | |||
| 233 | Renamed from `mh-xemacs-use-toolbar-flag' per GNU Emacs naming conventions. | ||
| 234 | |||
| 235 | *** mh-yank-behavior | ||
| 236 | |||
| 237 | Renamed from `mh-yank-from-start-of-msg' for clarity. | ||
| 238 | |||
| 239 | ** Variables Deleted in MH-E 7.90 | ||
| 240 | |||
| 241 | *** mail-citation-hook | ||
| 242 | |||
| 243 | This is already defined in `sendmail.el'. | ||
| 244 | |||
| 245 | *** mh-edit-mhn-hook | ||
| 246 | |||
| 247 | Renamed to `mh-mh-to-mime-hook'. | ||
| 248 | |||
| 249 | *** mh-folder-updated-hook | ||
| 250 | |||
| 251 | Renamed to `mh-before-commands-processed-hook'. | ||
| 252 | |||
| 253 | *** mh-highlight-citation-p | ||
| 254 | |||
| 255 | Renamed to `mh-highlight-citation-style'. | ||
| 256 | |||
| 257 | *** mh-index-new-messages-folders | ||
| 258 | |||
| 259 | Renamed to `mh-new-messages-folders'. | ||
| 260 | |||
| 261 | *** mh-index-program | ||
| 262 | |||
| 263 | Renamed to `mh-search-program'. | ||
| 264 | |||
| 265 | *** mh-index-ticked-messages-folders | ||
| 266 | |||
| 267 | Renamed to `mh-ticked-messages-folders'. | ||
| 268 | |||
| 269 | *** mh-kill-folder-suppress-prompt-hook | ||
| 270 | |||
| 271 | Renamed to `mh-kill-folder-suppress-prompt-hooks'. | ||
| 272 | |||
| 273 | *** mh-letter-insert-signature-hook | ||
| 274 | |||
| 275 | Renamed to `mh-insert-signature-hook'. | ||
| 276 | |||
| 277 | *** mhl-formfile | ||
| 278 | |||
| 279 | Renamed to `mh-mhl-format-file'. | ||
| 280 | |||
| 281 | *** mh-pick-mode-hook | ||
| 282 | |||
| 283 | Renamed to `mh-search-mode-hook'. | ||
| 284 | |||
| 285 | *** mh-speed-flists-interval | ||
| 286 | |||
| 287 | Renamed to `mh-speed-update-interval'. | ||
| 288 | |||
| 289 | *** mh-speed-run-flists-flag | ||
| 290 | |||
| 291 | Deleted since setting `mh-speed-flists-interval' to 0 accomplishes the | ||
| 292 | same thing. | ||
| 293 | |||
| 294 | *** mh-xemacs-toolbar-position | ||
| 295 | |||
| 296 | Renamed to `mh-xemacs-tool-bar-position'. | ||
| 297 | |||
| 298 | *** mh-xemacs-use-toolbar-flag | ||
| 299 | |||
| 300 | Renamed to `mh-xemacs-use-tool-bar-flag'. | ||
| 301 | |||
| 302 | *** mh-yank-from-start-of-msg | ||
| 303 | |||
| 304 | Renamed to `mh-yank-behavior'. | ||
| 305 | |||
| 306 | ** Bug Fixes in MH-E 7.90 | ||
| 307 | |||
| 308 | *** Error Message When Trying to Send Using MH-E | ||
| 309 | |||
| 310 | This behavior is no longer observed (closes SF #1002103). | ||
| 311 | |||
| 312 | *** "Args out of range" Error in Displaying Message | ||
| 313 | |||
| 314 | This behavior is no longer observed (closes SF #1227504). | ||
| 315 | |||
| 316 | *** Front-and-back Truncation in mailto: Rendering | ||
| 317 | |||
| 318 | This behavior is no longer observed (closes SF #1227510). | ||
| 319 | |||
| 320 | *** Completions Offered by mh-refile-message Are Not Sorted | ||
| 321 | |||
| 322 | This behavior is no longer observed (closes SF #698734). | ||
| 323 | |||
| 324 | *** Add Message-ID to Outgoing Messages | ||
| 325 | |||
| 326 | If you replied to a message in your `+outbox', an `In-Reply-To:' | ||
| 327 | header field was created that broke threading at the recipient's end. | ||
| 328 | We now add a `Message-ID:' to outgoing messages which fixes this | ||
| 329 | (closes SF #725425). | ||
| 330 | |||
| 331 | *** Speedbar Creating New Folders Instead of Visiting Existing | ||
| 332 | |||
| 333 | This was actually fixed in 7.4.3 (closes SF #792300). | ||
| 334 | |||
| 335 | *** Args Out of Range | ||
| 336 | |||
| 337 | This compilation error was actually fixed in 7.4.3 (closes SF | ||
| 338 | #806577). | ||
| 339 | |||
| 340 | *** Initialization Fails If ~/Mail Exists | ||
| 341 | |||
| 342 | MH-E no longer calls `install-mh' so this issue has gone away (closes | ||
| 343 | SF #835192). | ||
| 344 | |||
| 345 | *** RETURN Causes Infinite Loop in mh-letter | ||
| 346 | |||
| 347 | This behavior is no longer observed (closes SF #887346). | ||
| 348 | |||
| 349 | *** Missing Headers When Replying to All | ||
| 350 | |||
| 351 | User needed to edit `replgroupcomps' (closes SF #918194). | ||
| 352 | |||
| 353 | *** mh-find-path Doesn't Use mhparam | ||
| 354 | |||
| 355 | MH-E no longer peeks into the MH profile `~/.mh_profile' directly. It | ||
| 356 | uses `mhparam' instead (closes SF #1016027). | ||
| 357 | |||
| 358 | *** mh-index-previous-folder Does Not Work Correctly | ||
| 359 | |||
| 360 | If your cursor was on an item below a folder heading and you used | ||
| 361 | `M-TAB' (`mh-index-previous-folder'), you would move to the previous | ||
| 362 | folder heading. This has been fixed (closes SF #1126188). | ||
| 363 | |||
| 364 | *** XEmacs Compile Fails | ||
| 365 | |||
| 366 | Compiling produced a "Symbol's value as variable is void: require" | ||
| 367 | error on all files. This has been fixed. As a bonus, warnings have | ||
| 368 | been reduced from hundreds to just a few (closes SF #1127595). | ||
| 369 | |||
| 370 | *** buffer-offer-save Permanent Local | ||
| 371 | |||
| 372 | There was a movement to make `buffer-offer-save' a permanent local | ||
| 373 | which would have meant that we could not set it in `mh-letter-mode'. | ||
| 374 | However, this movement was fraught with issues and was postponed | ||
| 375 | (closes SF #1184756). | ||
| 376 | |||
| 377 | *** Better Handling of Empty cur Sequence | ||
| 378 | |||
| 379 | If you refiled a message into a folder and then used `F r' | ||
| 380 | (`mh-rescan-folder') in that folder, your cursor would be taken to the | ||
| 381 | first message. The cursor now stays where it was (closes SF #1207247). | ||
| 382 | |||
| 383 | *** Name of the Draft File in mh-comp.el | ||
| 384 | |||
| 385 | MH is documented to use the draft file. If you use a draft file for | ||
| 386 | something else (like Sylpheed), then use draft folders (closes SF | ||
| 387 | #1231483). | ||
| 388 | |||
| 389 | *** Use Standard Default Notation in Prompts | ||
| 390 | |||
| 391 | Emacs changed their defaults in prompts from "Prompt: [value]" to | ||
| 392 | "Prompt (default value): ". All MH-E prompts have been updated to | ||
| 393 | comply with the new standard (closes SF #1275933). | ||
| 394 | |||
| 395 | *** Msg Display Broken After Displaying Msg with Inline Image | ||
| 396 | |||
| 397 | Messages with inline images no longer trim certain message header | ||
| 398 | fields (closes SF #1306141). | ||
| 399 | |||
| 400 | *** mh-visit-folder Munges font-lock-keywords | ||
| 401 | |||
| 402 | MH-E broke highlighting in Gnus buffers. This was actually a problem | ||
| 403 | in CVS Emacs 22 and has been fixed there (closes SF #1393879). | ||
| 404 | |||
| 405 | *** Illegal Filename Chars for W32 Filesystems | ||
| 406 | |||
| 407 | Windows users who view `X-Image-URL:' images could not cache the | ||
| 408 | images since the cached image file names had illegal characters. This | ||
| 409 | has been fixed (closes SF #1396499). | ||
| 410 | |||
| 411 | *** mh-send Doesn't Handle mml Insertions Via mail-user-agent | ||
| 412 | |||
| 413 | Can now forward messages in Gnus if MH-E is your `mail-user-agent' | ||
| 414 | (closes SF #1399307). | ||
| 415 | |||
| 416 | |||
| 417 | |||
| 9 | * Changes in MH-E 7.85 | 418 | * Changes in MH-E 7.85 |
| 10 | 419 | ||
| 11 | Version 7.85 heralds a migration of the CVS repository from | 420 | Version 7.85 heralds a migration of the CVS repository from |
| @@ -409,7 +818,7 @@ that you comment them out. The MH detection code has been completely | |||
| 409 | rewritten and it is very likely that you no longer to set them and | 818 | rewritten and it is very likely that you no longer to set them and |
| 410 | their setting may confuse other MH-E settings. | 819 | their setting may confuse other MH-E settings. |
| 411 | 820 | ||
| 412 | ** Variables Deleted in MH-E | 821 | ** Variables Deleted in MH-E 7.4.80 |
| 413 | 822 | ||
| 414 | Variables that have been removed from MH-E that have not been | 823 | Variables that have been removed from MH-E that have not been |
| 415 | discussed elsewhere are listed here. | 824 | discussed elsewhere are listed here. |
| @@ -1,5 +1,5 @@ | |||
| 1 | GNU Emacs NEWS -- history of user-visible changes. 2003-05-21 | 1 | GNU Emacs NEWS -- history of user-visible changes. 2003-05-21 |
| 2 | Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005 | 2 | Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006 |
| 3 | Free Software Foundation, Inc. | 3 | Free Software Foundation, Inc. |
| 4 | See the end for copying conditions. | 4 | See the end for copying conditions. |
| 5 | 5 | ||
| @@ -3053,7 +3053,7 @@ See the file GNUS-NEWS or the node "Oort Gnus" in the Gnus manual for details. | |||
| 3053 | --- | 3053 | --- |
| 3054 | ** MH-E changes. | 3054 | ** MH-E changes. |
| 3055 | 3055 | ||
| 3056 | Upgraded to MH-E version 7.85. There have been major changes since | 3056 | Upgraded to MH-E version 7.91. There have been major changes since |
| 3057 | version 5.0.2; see MH-E-NEWS for details. | 3057 | version 5.0.2; see MH-E-NEWS for details. |
| 3058 | 3058 | ||
| 3059 | ** Calendar changes: | 3059 | ** Calendar changes: |
| @@ -123,6 +123,11 @@ to the FSF. | |||
| 123 | 123 | ||
| 124 | * Other features we would like: | 124 | * Other features we would like: |
| 125 | 125 | ||
| 126 | ** Create a category of errors called `user-error' for errors which are | ||
| 127 | typically due to pilot errors and should thus be in debug-ignored-errors. | ||
| 128 | |||
| 129 | ** Give Tar mode all the features of Archive mode. | ||
| 130 | |||
| 126 | ** Create a category of errors called `process-error' | 131 | ** Create a category of errors called `process-error' |
| 127 | for some or all errors associated with using subprocesses. | 132 | for some or all errors associated with using subprocesses. |
| 128 | 133 | ||
| @@ -420,6 +425,9 @@ when the body only calls primitives. | |||
| 420 | "japanese". Currently, most Japanese users are using external | 425 | "japanese". Currently, most Japanese users are using external |
| 421 | packages (e.g. tamago, anthy) or an input method via XIM. | 426 | packages (e.g. tamago, anthy) or an input method via XIM. |
| 422 | 427 | ||
| 428 | ** Let LEIM handle the Mode_switch key like XIM does (i.e. a toggle like C-\ | ||
| 429 | but which can also be used as a modifier). | ||
| 430 | |||
| 423 | ** Provide the toolbar on ttys. This could map a bit like tmm-menubar | 431 | ** Provide the toolbar on ttys. This could map a bit like tmm-menubar |
| 424 | for the menubar and buttons could look a bit like those used by customize. | 432 | for the menubar and buttons could look a bit like those used by customize. |
| 425 | 433 | ||
diff --git a/lisp/.arch-inventory b/lisp/.arch-inventory index 9bd88350a95..5341c2d8fec 100644 --- a/lisp/.arch-inventory +++ b/lisp/.arch-inventory | |||
| @@ -1,7 +1,4 @@ | |||
| 1 | # Auto-generated lisp files, which ignore | 1 | # Auto-generated lisp files, which ignore |
| 2 | precious ^(loaddefs|finder-inf|cus-load)\.el$ | 2 | precious ^(loaddefs|finder-inf|cus-load)\.el$ |
| 3 | 3 | ||
| 4 | # Something generated during a windows build?!? | ||
| 5 | precious ^(Makefile\.unix)$ | ||
| 6 | |||
| 7 | # arch-tag: fc62dc9f-3a91-455b-b8e7-d49df66beee0 | 4 | # arch-tag: fc62dc9f-3a91-455b-b8e7-d49df66beee0 |
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 34c179df334..0b6eae823e0 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,7 +1,120 @@ | |||
| 1 | 2006-02-03 Werner Lemberg <wl@gnu.org> | ||
| 2 | |||
| 3 | * textmodes/nroff-mode.el (nroff-font-lock-keywords): Don't be | ||
| 4 | greedy to find the closing bracket in \*[...] and similar | ||
| 5 | expressions. This is a first rough fix -- many additional | ||
| 6 | refinements are necessary to make nroff mode really usable with | ||
| 7 | groff. | ||
| 8 | |||
| 9 | 2006-02-03 Jens Petersen <petersen@redhat.com> (tiny change) | ||
| 10 | |||
| 11 | * international/mule-cmds.el (set-locale-environment): Add | ||
| 12 | "/usr/share/X11/locale/locale.alias" to search list for xorg-x11 | ||
| 13 | libX11. | ||
| 14 | |||
| 15 | 2006-02-03 Joe Wells <jbw@macs.hw.ac.uk> (tiny change) | ||
| 16 | |||
| 17 | * arc-mode.el (archive-maybe-copy): Fix the way directories in the | ||
| 18 | archive are created in archive-tmpdir. | ||
| 19 | |||
| 20 | 2006-02-02 John Paul Wallington <jpw@pobox.com> | ||
| 21 | |||
| 22 | * ibuffer.el (ibuffer-compressed-file-name-regexp): New defcustom. | ||
| 23 | (ibuffer-fontification-alist): Use it. | ||
| 24 | (ibuffer-mode-map): Bind `ibuffer-mark-compressed-file-buffers' | ||
| 25 | to "* z" and the Ibuffer Mark menu. | ||
| 26 | |||
| 27 | * ibuf-ext.el (ibuffer-mark-compressed-file-buffers): New command. | ||
| 28 | |||
| 29 | 2006-02-02 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 30 | |||
| 31 | * textmodes/table.el (*table--cell-describe-mode) | ||
| 32 | (*table--cell-describe-bindings): Undo last change since | ||
| 33 | print-help-return-message is not obsoleted by anything at all. | ||
| 34 | |||
| 35 | 2006-02-02 Luc Teirlinck <teirllm@auburn.edu> | ||
| 36 | |||
| 37 | * emulation/cua-base.el (cua-mode): Doc fix. | ||
| 38 | |||
| 39 | 2006-02-02 Juanma Barranquero <lekktu@gmail.com> | ||
| 40 | |||
| 41 | * dframe.el (dframe-handle-make-frame-visible) | ||
| 42 | (dframe-handle-iconify-frame, dframe-get-focus) | ||
| 43 | (dframe-select-attached-frame, dframe-power-click) | ||
| 44 | (dframe-frame-mode): Fix typos in docstrings. | ||
| 45 | |||
| 46 | * ezimage.el (ezimage-mail, ezimage-object-out-of-date) | ||
| 47 | (ezimage-insert-image-button-maybe, ezimage-insert-over-text): | ||
| 48 | Fix typos in docstrings. | ||
| 49 | |||
| 50 | * hi-lock.el (hi-lock-mode, hi-lock-line-face-buffer) | ||
| 51 | (hi-lock-face-buffer, hi-lock-font-lock-hook) | ||
| 52 | (hi-lock-archaic-interface-message-used) | ||
| 53 | (hi-lock-file-patterns-range): Fix typos in docstrings. | ||
| 54 | |||
| 55 | * savehist.el (savehist-loaded, savehist-load, savehist-install) | ||
| 56 | (savehist-autosave, savehist-trim-history): Fix typos in docstrings. | ||
| 57 | |||
| 58 | * mail/mailclient.el (mailclient-place-body-on-clipboard-flag): | ||
| 59 | Fix typo in docstring. | ||
| 60 | |||
| 61 | * net/newsticker.el (newsticker--decode-iso8601-date) | ||
| 62 | (newsticker--set-customvar, newsticker--buffer-insert-item) | ||
| 63 | (newsticker--do-run-auto-mark-filter) | ||
| 64 | (newsticker--parse-generic-feed): Doc fixes. | ||
| 65 | (newsticker--retrieval-timer-list, newsticker-url-list) | ||
| 66 | (newsticker-hide-immortal-items-in-echo-area) | ||
| 67 | (newsticker-hide-obsolete-items-in-echo-area) | ||
| 68 | (newsticker-new-item-face, newsticker--enclosure) | ||
| 69 | (newsticker-buffer-update, newsticker-w3m-show-inline-images) | ||
| 70 | (newsticker--parse-atom-0.3, newsticker--parse-rss-1.0) | ||
| 71 | (newsticker--parse-generic-feed, newsticker--cache-contains) | ||
| 72 | (newsticker--stat-num-items, newsticker-download-enclosures): | ||
| 73 | Fix typos in docstrings. | ||
| 74 | |||
| 75 | * net/rcirc.el (rcirc-debug): Doc fix. | ||
| 76 | (rcirc-fill-column, rcirc-receive-message-hooks) | ||
| 77 | (rcirc-browse-url-map, rcirc-read-only-flag, rcirc-prompt) | ||
| 78 | (rcirc-mode, rcirc-generate-new-buffer-name) | ||
| 79 | (rcirc-startup-channels, rcirc-ignore-update-automatic) | ||
| 80 | (rcirc-cmd-ignore, rcirc-browse-url, rcirc-url-regexp): | ||
| 81 | Fix typos in docstrings. | ||
| 82 | (rcirc-print): "?\ " -> "?\s". | ||
| 83 | (rcirc-cmd-join): Improve argument/docstring consistency. | ||
| 84 | |||
| 85 | 2006-02-01 Mark A. Hershberger <mah@everybody.org> | ||
| 86 | |||
| 87 | * xml.el (xml-parse-region): Move save-excursion and set-buffer up | ||
| 88 | before narrow-to-region. | ||
| 89 | |||
| 90 | 2006-02-01 Richard M. Stallman <rms@gnu.org> | ||
| 91 | |||
| 92 | * simple.el (move-beginning-of-line): Scan properly for invis change. | ||
| 93 | |||
| 94 | * replace.el (multi-occur-in-matching-buffers): Fix prev change. | ||
| 95 | |||
| 96 | 2006-02-01 Michael Albinus <michael.albinus@gmx.de> | ||
| 97 | |||
| 98 | * net/tramp.el (tramp-convert-file-attributes): Set file's gid | ||
| 99 | change bit only when id-format is 'integer. Reported by Matt | ||
| 100 | Hodges <M.P.Hodges@rl.ac.uk>. | ||
| 101 | |||
| 102 | 2006-02-01 Juanma Barranquero <lekktu@gmail.com> | ||
| 103 | |||
| 104 | * hilit-chg.el (highlight-changes-initial-state) | ||
| 105 | (highlight-changes-global-initial-state): Doc fixes. | ||
| 106 | (highlight-changes-global-modes, global-highlight-changes): | ||
| 107 | Fix typos in docstrings. | ||
| 108 | |||
| 109 | 2006-02-01 Kim F. Storm <storm@cua.dk> | ||
| 110 | |||
| 111 | * emulation/cua-base.el (cua-mode): Mention that CUA enables | ||
| 112 | transient-mark-mode in doc string. | ||
| 113 | |||
| 1 | 2006-01-31 Richard M. Stallman <rms@gnu.org> | 114 | 2006-01-31 Richard M. Stallman <rms@gnu.org> |
| 2 | 115 | ||
| 3 | * replace.el (multi-occur): Doc fix. | 116 | * replace.el (multi-occur): Doc fix. |
| 4 | (multi-occur-in-matching-buffers): Renamed from | 117 | (multi-occur-in-matching-buffers): Rename from |
| 5 | multi-occur-by-filename-regexp. Prefix arg says match | 118 | multi-occur-by-filename-regexp. Prefix arg says match |
| 6 | buffer names instead of file names. | 119 | buffer names instead of file names. |
| 7 | 120 | ||
diff --git a/lisp/arc-mode.el b/lisp/arc-mode.el index 4aabfdea310..4eff3b65635 100644 --- a/lisp/arc-mode.el +++ b/lisp/arc-mode.el | |||
| @@ -822,17 +822,13 @@ using `make-temp-file', and the generated name is returned." | |||
| 822 | (archive-name | 822 | (archive-name |
| 823 | (or (and archive-subfile-mode (aref archive-subfile-mode 0)) | 823 | (or (and archive-subfile-mode (aref archive-subfile-mode 0)) |
| 824 | archive))) | 824 | archive))) |
| 825 | (make-directory archive-tmpdir t) | ||
| 826 | ;; If ARCHIVE includes leading directories, make sure they | ||
| 827 | ;; exist under archive-tmpdir. | ||
| 828 | (let ((arch-dir (file-name-directory archive))) | ||
| 829 | (if arch-dir | ||
| 830 | (make-directory (concat | ||
| 831 | (file-name-as-directory archive-tmpdir) | ||
| 832 | arch-dir) | ||
| 833 | t))) | ||
| 834 | (setq archive-local-name | 825 | (setq archive-local-name |
| 835 | (archive-unique-fname archive-name archive-tmpdir)) | 826 | (archive-unique-fname archive-name archive-tmpdir)) |
| 827 | ;; Maked sure all the leading directories in | ||
| 828 | ;; archive-local-name exist under archive-tmpdir, so that | ||
| 829 | ;; the directory structure recorded in the archive is | ||
| 830 | ;; reconstructed in the temporary directory. | ||
| 831 | (make-directory (file-name-directory archive-local-name) t) | ||
| 836 | (save-restriction | 832 | (save-restriction |
| 837 | (widen) | 833 | (widen) |
| 838 | (write-region start (point-max) archive-local-name nil 'nomessage)) | 834 | (write-region start (point-max) archive-local-name nil 'nomessage)) |
diff --git a/lisp/dframe.el b/lisp/dframe.el index 56bbdc36c01..e15b57af605 100644 --- a/lisp/dframe.el +++ b/lisp/dframe.el | |||
| @@ -1,6 +1,7 @@ | |||
| 1 | ;;; dframe --- dedicate frame support modes | 1 | ;;; dframe --- dedicate frame support modes |
| 2 | 2 | ||
| 3 | ;;; Copyright (C) 1996, 97, 98, 99, 2000, 01, 02, 03, 04, 05 Free Software Foundation | 3 | ;;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, |
| 4 | ;; 2005 Free Software Foundation | ||
| 4 | 5 | ||
| 5 | ;; Author: Eric M. Ludlam <zappo@gnu.org> | 6 | ;; Author: Eric M. Ludlam <zappo@gnu.org> |
| 6 | ;; Keywords: file, tags, tools | 7 | ;; Keywords: file, tags, tools |
| @@ -299,7 +300,7 @@ This frame is either resurrected, hidden, killed, etc based on | |||
| 299 | the value. | 300 | the value. |
| 300 | CACHE-VAR is a variable used to cache a cached frame. | 301 | CACHE-VAR is a variable used to cache a cached frame. |
| 301 | BUFFER-VAR is a variable used to cache the buffer being used in dframe. | 302 | BUFFER-VAR is a variable used to cache the buffer being used in dframe. |
| 302 | This buffer will have `dframe-mode' run on it. | 303 | This buffer will have `dframe-frame-mode' run on it. |
| 303 | FRAME-NAME is the name of the frame to create. | 304 | FRAME-NAME is the name of the frame to create. |
| 304 | LOCAL-MODE-FN is the function used to call this one. | 305 | LOCAL-MODE-FN is the function used to call this one. |
| 305 | PARAMETERS are frame parameters to apply to this dframe. | 306 | PARAMETERS are frame parameters to apply to this dframe. |
| @@ -606,7 +607,7 @@ The function must take an EVENT.") | |||
| 606 | 607 | ||
| 607 | (defun dframe-handle-make-frame-visible (e) | 608 | (defun dframe-handle-make-frame-visible (e) |
| 608 | "Handle a `make-frame-visible' event. | 609 | "Handle a `make-frame-visible' event. |
| 609 | Should enables auto-updating if the last state was also enabled. | 610 | Should enable auto-updating if the last state was also enabled. |
| 610 | Argument E is the event making the frame visible." | 611 | Argument E is the event making the frame visible." |
| 611 | (interactive "e") | 612 | (interactive "e") |
| 612 | (let ((f last-event-frame)) | 613 | (let ((f last-event-frame)) |
| @@ -617,7 +618,7 @@ Argument E is the event making the frame visible." | |||
| 617 | 618 | ||
| 618 | (defun dframe-handle-iconify-frame (e) | 619 | (defun dframe-handle-iconify-frame (e) |
| 619 | "Handle a `iconify-frame' event. | 620 | "Handle a `iconify-frame' event. |
| 620 | Should disables auto-updating if the last state was also enabled. | 621 | Should disable auto-updating if the last state was also enabled. |
| 621 | Argument E is the event iconifying the frame." | 622 | Argument E is the event iconifying the frame." |
| 622 | (interactive "e") | 623 | (interactive "e") |
| 623 | (let ((f last-event-frame)) | 624 | (let ((f last-event-frame)) |
| @@ -652,7 +653,7 @@ If the selected frame is not in the symbol FRAME-VAR, then FRAME-VAR | |||
| 652 | frame is selected. If the FRAME-VAR is active, then select the | 653 | frame is selected. If the FRAME-VAR is active, then select the |
| 653 | attached frame. If FRAME-VAR is nil, ACTIVATOR is called to | 654 | attached frame. If FRAME-VAR is nil, ACTIVATOR is called to |
| 654 | created it. HOOK is an optional argument of hooks to run when | 655 | created it. HOOK is an optional argument of hooks to run when |
| 655 | selecting FRAME." | 656 | selecting FRAME-VAR." |
| 656 | (interactive) | 657 | (interactive) |
| 657 | (if (eq (selected-frame) (symbol-value frame-var)) | 658 | (if (eq (selected-frame) (symbol-value frame-var)) |
| 658 | (if (frame-live-p dframe-attached-frame) | 659 | (if (frame-live-p dframe-attached-frame) |
| @@ -696,10 +697,10 @@ If optional arg FRAME is nil just return `dframe-attached-frame'." | |||
| 696 | dframe-attached-frame)) | 697 | dframe-attached-frame)) |
| 697 | 698 | ||
| 698 | (defun dframe-select-attached-frame (&optional frame) | 699 | (defun dframe-select-attached-frame (&optional frame) |
| 699 | "Switch to the frame the dframe controlled frame FRAME was started from. If | 700 | "Switch to the frame the dframe controlled frame FRAME was started from. |
| 700 | optional arg FRAME is nil assume the attached frame is already selected and | 701 | If optional arg FRAME is nil assume the attached frame is already selected |
| 701 | just run the hooks `dframe-after-select-attached-frame-hook'. Return the | 702 | and just run the hooks `dframe-after-select-attached-frame-hook'. Return |
| 702 | attached frame." | 703 | the attached frame." |
| 703 | (let ((frame (dframe-attached-frame frame))) | 704 | (let ((frame (dframe-attached-frame frame))) |
| 704 | (if frame (select-frame frame)) | 705 | (if frame (select-frame frame)) |
| 705 | (prog1 frame | 706 | (prog1 frame |
| @@ -957,7 +958,7 @@ This should be bound to mouse event E." | |||
| 957 | (funcall dframe-mouse-position-function))) | 958 | (funcall dframe-mouse-position-function))) |
| 958 | 959 | ||
| 959 | (defun dframe-power-click (e) | 960 | (defun dframe-power-click (e) |
| 960 | "Activate any `dframe' mouse click as a power click. | 961 | "Activate any dframe mouse click as a power click. |
| 961 | A power click will dispose of cached data (if available) or bring a buffer | 962 | A power click will dispose of cached data (if available) or bring a buffer |
| 962 | up into a different window. | 963 | up into a different window. |
| 963 | This should be bound to mouse event E." | 964 | This should be bound to mouse event E." |
diff --git a/lisp/emacs-lisp/unsafep.el b/lisp/emacs-lisp/unsafep.el index 4b1312d58d7..27e079b1dcd 100644 --- a/lisp/emacs-lisp/unsafep.el +++ b/lisp/emacs-lisp/unsafep.el | |||
| @@ -79,11 +79,13 @@ | |||
| 79 | ;; passed a circular list to `assoc', Emacs would crash. Historically, | 79 | ;; passed a circular list to `assoc', Emacs would crash. Historically, |
| 80 | ;; problems of this kind have been few and short-lived. | 80 | ;; problems of this kind have been few and short-lived. |
| 81 | 81 | ||
| 82 | ;;; Code: | ||
| 83 | |||
| 82 | (provide 'unsafep) | 84 | (provide 'unsafep) |
| 83 | (require 'byte-opt) ;Set up the `side-effect-free' properties | 85 | (require 'byte-opt) ;Set up the `side-effect-free' properties |
| 84 | 86 | ||
| 85 | (defcustom safe-functions nil | 87 | (defcustom safe-functions nil |
| 86 | "t to disable `unsafep', or a list of assumed-safe functions." | 88 | "A list of assumed-safe functions, or t to disable `unsafep'." |
| 87 | :group 'lisp | 89 | :group 'lisp |
| 88 | :type '(choice (const :tag "No" nil) (const :tag "Yes" t) hook)) | 90 | :type '(choice (const :tag "No" nil) (const :tag "Yes" t) hook)) |
| 89 | 91 | ||
| @@ -210,7 +212,7 @@ of symbols with local bindings." | |||
| 210 | 212 | ||
| 211 | 213 | ||
| 212 | (defun unsafep-function (fun) | 214 | (defun unsafep-function (fun) |
| 213 | "Return nil if FUN is a safe function | 215 | "Return nil iff FUN is a safe function. |
| 214 | \(either a safe lambda or a symbol that names a safe function). Otherwise | 216 | \(either a safe lambda or a symbol that names a safe function). Otherwise |
| 215 | result is a reason code." | 217 | result is a reason code." |
| 216 | (cond | 218 | (cond |
| @@ -233,7 +235,8 @@ for the first unsafe form." | |||
| 233 | (if reason (throw 'unsafep-progn reason)))))) | 235 | (if reason (throw 'unsafep-progn reason)))))) |
| 234 | 236 | ||
| 235 | (defun unsafep-let (clause) | 237 | (defun unsafep-let (clause) |
| 236 | "CLAUSE is a let-binding, either SYM or (SYM) or (SYM VAL). Checks VAL | 238 | "Check the safety of a let binding. |
| 239 | CLAUSE is a let-binding, either SYM or (SYM) or (SYM VAL). Checks VAL | ||
| 237 | and throws a reason to `unsafep' if unsafe. Returns SYM." | 240 | and throws a reason to `unsafep' if unsafe. Returns SYM." |
| 238 | (let (reason sym) | 241 | (let (reason sym) |
| 239 | (if (atom clause) | 242 | (if (atom clause) |
| @@ -245,7 +248,7 @@ and throws a reason to `unsafep' if unsafe. Returns SYM." | |||
| 245 | sym)) | 248 | sym)) |
| 246 | 249 | ||
| 247 | (defun unsafep-variable (sym global-okay) | 250 | (defun unsafep-variable (sym global-okay) |
| 248 | "Returns nil if SYM is safe as a let-binding sym | 251 | "Return nil if SYM is safe as a let-binding sym |
| 249 | \(because it already has a temporary binding or is a non-risky buffer-local | 252 | \(because it already has a temporary binding or is a non-risky buffer-local |
| 250 | variable), otherwise a reason why it is unsafe. Failing to be locally bound | 253 | variable), otherwise a reason why it is unsafe. Failing to be locally bound |
| 251 | is okay if GLOBAL-OKAY is non-nil." | 254 | is okay if GLOBAL-OKAY is non-nil." |
| @@ -259,5 +262,5 @@ is okay if GLOBAL-OKAY is non-nil." | |||
| 259 | (local-variable-p sym))) | 262 | (local-variable-p sym))) |
| 260 | `(global-variable ,sym)))) | 263 | `(global-variable ,sym)))) |
| 261 | 264 | ||
| 262 | ;;; arch-tag: 6216f98b-eb8f-467a-9c33-7a7644f50658 | 265 | ;; arch-tag: 6216f98b-eb8f-467a-9c33-7a7644f50658 |
| 263 | ;; unsafep.el ends here. | 266 | ;;; unsafep.el ends here |
diff --git a/lisp/emulation/cua-base.el b/lisp/emulation/cua-base.el index fd5249fed1a..11ba0ea37ae 100644 --- a/lisp/emulation/cua-base.el +++ b/lisp/emulation/cua-base.el | |||
| @@ -1393,7 +1393,12 @@ options: | |||
| 1393 | 1393 | ||
| 1394 | You can customize `cua-enable-cua-keys' to completely disable the | 1394 | You can customize `cua-enable-cua-keys' to completely disable the |
| 1395 | CUA bindings, or `cua-prefix-override-inhibit-delay' to change | 1395 | CUA bindings, or `cua-prefix-override-inhibit-delay' to change |
| 1396 | the prefix fallback behavior." | 1396 | the prefix fallback behavior. |
| 1397 | |||
| 1398 | CUA mode manages Transient Mark mode internally. Trying to disable | ||
| 1399 | Transient Mark mode while CUA mode is enabled does not work; if you | ||
| 1400 | only want to highlight the region when it is selected using a | ||
| 1401 | shifted movement key, set `cua-highlight-region-shift-only'." | ||
| 1397 | :global t | 1402 | :global t |
| 1398 | :group 'cua | 1403 | :group 'cua |
| 1399 | :set-after '(cua-enable-modeline-indications cua-rectangle-modifier-key) | 1404 | :set-after '(cua-enable-modeline-indications cua-rectangle-modifier-key) |
diff --git a/lisp/erc/ChangeLog b/lisp/erc/ChangeLog index 98022b601e6..c77b091bdb4 100644 --- a/lisp/erc/ChangeLog +++ b/lisp/erc/ChangeLog | |||
| @@ -1,3 +1,8 @@ | |||
| 1 | 2006-02-03 Zhang Wei <id.brep@gmail.com> (tiny change) | ||
| 2 | |||
| 3 | * erc.el (erc-version-string): Don't hard-code Emacs version. | ||
| 4 | (erc-version): Use emacs-version. | ||
| 5 | |||
| 1 | 2006-01-30 Simon Josefsson <jas@extundo.com> | 6 | 2006-01-30 Simon Josefsson <jas@extundo.com> |
| 2 | 7 | ||
| 3 | * erc.el (erc-open-ssl-stream): Use tls.el. | 8 | * erc.el (erc-open-ssl-stream): Use tls.el. |
diff --git a/lisp/erc/erc.el b/lisp/erc/erc.el index 3c6baf1fdb4..cc9dc8bf1b9 100644 --- a/lisp/erc/erc.el +++ b/lisp/erc/erc.el | |||
| @@ -66,7 +66,7 @@ | |||
| 66 | 66 | ||
| 67 | ;;; Code: | 67 | ;;; Code: |
| 68 | 68 | ||
| 69 | (defconst erc-version-string "Version 5.1 (Emacs 22)" | 69 | (defconst erc-version-string "Version 5.1" |
| 70 | "ERC version. This is used by function `erc-version'.") | 70 | "ERC version. This is used by function `erc-version'.") |
| 71 | 71 | ||
| 72 | (eval-when-compile (require 'cl)) | 72 | (eval-when-compile (require 'cl)) |
| @@ -5774,7 +5774,7 @@ P may be an integer or a service name." | |||
| 5774 | If optional argument HERE is non-nil, insert version number at point." | 5774 | If optional argument HERE is non-nil, insert version number at point." |
| 5775 | (interactive "P") | 5775 | (interactive "P") |
| 5776 | (let ((version-string | 5776 | (let ((version-string |
| 5777 | (format "ERC %s" erc-version-string))) | 5777 | (format "ERC %s (GNU Emacs %s)" erc-version-string emacs-version))) |
| 5778 | (if here | 5778 | (if here |
| 5779 | (insert version-string) | 5779 | (insert version-string) |
| 5780 | (if (interactive-p) | 5780 | (if (interactive-p) |
diff --git a/lisp/ezimage.el b/lisp/ezimage.el index a00703d5471..a689adc25cd 100644 --- a/lisp/ezimage.el +++ b/lisp/ezimage.el | |||
| @@ -78,7 +78,7 @@ IMAGESPEC is the image data, and DOCSTRING is documentation for the image." | |||
| 78 | 78 | ||
| 79 | ) | 79 | ) |
| 80 | (if (not (fboundp 'make-glyph)) | 80 | (if (not (fboundp 'make-glyph)) |
| 81 | 81 | ||
| 82 | (defmacro defezimage (variable imagespec docstring) | 82 | (defmacro defezimage (variable imagespec docstring) |
| 83 | "Don't bother loading up an image... | 83 | "Don't bother loading up an image... |
| 84 | Argument VARIABLE is the variable to define. | 84 | Argument VARIABLE is the variable to define. |
| @@ -194,7 +194,7 @@ IMAGESPEC is the image data, and DOCSTRING is documentation for the image." | |||
| 194 | 194 | ||
| 195 | (defezimage ezimage-mail | 195 | (defezimage ezimage-mail |
| 196 | ((:type xpm :file "ezimage/mail.xpm" :ascent center)) | 196 | ((:type xpm :file "ezimage/mail.xpm" :ascent center)) |
| 197 | "Image if an envelope.") | 197 | "Image of an envelope.") |
| 198 | 198 | ||
| 199 | (defezimage ezimage-checkout | 199 | (defezimage ezimage-checkout |
| 200 | ((:type xpm :file "ezimage/checkmark.xpm" :ascent center)) | 200 | ((:type xpm :file "ezimage/checkmark.xpm" :ascent center)) |
| @@ -206,7 +206,7 @@ IMAGESPEC is the image data, and DOCSTRING is documentation for the image." | |||
| 206 | 206 | ||
| 207 | (defezimage ezimage-object-out-of-date | 207 | (defezimage ezimage-object-out-of-date |
| 208 | ((:type xpm :file "ezimage/bitsbang.xpm" :ascent center)) | 208 | ((:type xpm :file "ezimage/bitsbang.xpm" :ascent center)) |
| 209 | "Image representing bits with a ! in it. (an out of data object file.)") | 209 | "Image representing bits with a ! in it. (An out of data object file.)") |
| 210 | 210 | ||
| 211 | (defezimage ezimage-label | 211 | (defezimage ezimage-label |
| 212 | ((:type xpm :file "ezimage/label.xpm" :ascent center)) | 212 | ((:type xpm :file "ezimage/label.xpm" :ascent center)) |
| @@ -264,7 +264,7 @@ IMAGESPEC is the image data, and DOCSTRING is documentation for the image." | |||
| 264 | "Insert an image button based on text starting at START for LENGTH chars. | 264 | "Insert an image button based on text starting at START for LENGTH chars. |
| 265 | If buttontext is unknown, just insert that text. | 265 | If buttontext is unknown, just insert that text. |
| 266 | If we have an image associated with it, use that image. | 266 | If we have an image associated with it, use that image. |
| 267 | Optional argument STRING is a st ring upon which to add text properties." | 267 | Optional argument STRING is a string upon which to add text properties." |
| 268 | (when ezimage-use-images | 268 | (when ezimage-use-images |
| 269 | (let* ((bt (buffer-substring start (+ length start))) | 269 | (let* ((bt (buffer-substring start (+ length start))) |
| 270 | (a (assoc bt ezimage-expand-image-button-alist))) | 270 | (a (assoc bt ezimage-expand-image-button-alist))) |
| @@ -293,7 +293,7 @@ Return STRING with properties applied." | |||
| 293 | 293 | ||
| 294 | (defun ezimage-insert-over-text (image start end &optional string) | 294 | (defun ezimage-insert-over-text (image start end &optional string) |
| 295 | "Place IMAGE over the text between START and END. | 295 | "Place IMAGE over the text between START and END. |
| 296 | Assumes the image is part of a gui and can be clicked on. | 296 | Assumes the image is part of a GUI and can be clicked on. |
| 297 | Optional argument STRING is a string upon which to add text properties." | 297 | Optional argument STRING is a string upon which to add text properties." |
| 298 | (when ezimage-use-images | 298 | (when ezimage-use-images |
| 299 | (if (featurep 'xemacs) | 299 | (if (featurep 'xemacs) |
diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog index 87a3f1918d6..1edd84bea48 100644 --- a/lisp/gnus/ChangeLog +++ b/lisp/gnus/ChangeLog | |||
| @@ -1,3 +1,24 @@ | |||
| 1 | 2006-02-03 Reiner Steib <Reiner.Steib@gmx.de> | ||
| 2 | |||
| 3 | * gnus-util.el (gnus-error): Describe `args'. | ||
| 4 | |||
| 5 | 2006-02-03 Andreas Seltenreich <uwi7@stud.uni-karlsruhe.de> | ||
| 6 | |||
| 7 | * nnweb.el (nnweb-request-group): Avoid growing overview files. | ||
| 8 | |||
| 9 | 2006-02-03 Katsumi Yamaoka <yamaoka@jpl.org> | ||
| 10 | |||
| 11 | * rfc2231.el (rfc2231-parse-string): Add missing semicolons to | ||
| 12 | segmented lines of parameter value to cope with Thunderbird 1.5 | ||
| 13 | bug (cf. https://bugzilla.mozilla.org/show_bug.cgi?id=323318). | ||
| 14 | Suggested by ARISAWA Akihiro <ari@mbf.ocn.ne.jp>. | ||
| 15 | (rfc2231-encode-string): Don't make lines exceeding 76 column. | ||
| 16 | |||
| 17 | 2006-02-01 Max Froumentin <max@lapin-bleu.net> (tiny change) | ||
| 18 | |||
| 19 | * mml.el (mml-generate-mime-1): Correct the order of inline signed | ||
| 20 | parts. | ||
| 21 | |||
| 1 | 2006-01-31 Andreas Seltenreich <uwi7@stud.uni-karlsruhe.de> | 22 | 2006-01-31 Andreas Seltenreich <uwi7@stud.uni-karlsruhe.de> |
| 2 | 23 | ||
| 3 | * nnweb.el (nnweb-group-alist): Use defvar instead of defvoo, | 24 | * nnweb.el (nnweb-group-alist): Use defvar instead of defvoo, |
diff --git a/lisp/gnus/gnus-util.el b/lisp/gnus/gnus-util.el index f7fb279f20f..c71b9630db2 100644 --- a/lisp/gnus/gnus-util.el +++ b/lisp/gnus/gnus-util.el | |||
| @@ -497,7 +497,8 @@ inside loops." | |||
| 497 | (apply 'format args))) | 497 | (apply 'format args))) |
| 498 | 498 | ||
| 499 | (defun gnus-error (level &rest args) | 499 | (defun gnus-error (level &rest args) |
| 500 | "Beep an error if LEVEL is equal to or less than `gnus-verbose'." | 500 | "Beep an error if LEVEL is equal to or less than `gnus-verbose'. |
| 501 | ARGS are passed to `message'." | ||
| 501 | (when (<= (floor level) gnus-verbose) | 502 | (when (<= (floor level) gnus-verbose) |
| 502 | (apply 'message args) | 503 | (apply 'message args) |
| 503 | (ding) | 504 | (ding) |
diff --git a/lisp/gnus/mml.el b/lisp/gnus/mml.el index 7d7ea9e20a1..8993f641786 100644 --- a/lisp/gnus/mml.el +++ b/lisp/gnus/mml.el | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | ;;; mml.el --- A package for parsing and validating MML documents | 1 | ;;; mml.el --- A package for parsing and validating MML documents |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, | 3 | ;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, |
| 4 | ;; 2005 Free Software Foundation, Inc. | 4 | ;; 2005, 2006 Free Software Foundation, Inc. |
| 5 | 5 | ||
| 6 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> | 6 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> |
| 7 | ;; This file is part of GNU Emacs. | 7 | ;; This file is part of GNU Emacs. |
| @@ -577,7 +577,8 @@ If MML is non-nil, return the buffer up till the correspondent mml tag." | |||
| 577 | ;; Skip `multipart' and attributes. | 577 | ;; Skip `multipart' and attributes. |
| 578 | (when (and (consp part) (consp (cdr part))) | 578 | (when (and (consp part) (consp (cdr part))) |
| 579 | (insert "\n--" mml-boundary "\n") | 579 | (insert "\n--" mml-boundary "\n") |
| 580 | (mml-generate-mime-1 part)))) | 580 | (mml-generate-mime-1 part) |
| 581 | (goto-char (point-max))))) | ||
| 581 | (insert "\n--" mml-boundary "--\n"))))) | 582 | (insert "\n--" mml-boundary "--\n"))))) |
| 582 | (t | 583 | (t |
| 583 | (error "Invalid element: %S" cont))) | 584 | (error "Invalid element: %S" cont))) |
diff --git a/lisp/gnus/nnweb.el b/lisp/gnus/nnweb.el index 4723a694182..bf49aba7f08 100644 --- a/lisp/gnus/nnweb.el +++ b/lisp/gnus/nnweb.el | |||
| @@ -133,7 +133,8 @@ Valid types include `google', `dejanews', and `gmane'.") | |||
| 133 | (deffoo nnweb-request-group (group &optional server dont-check) | 133 | (deffoo nnweb-request-group (group &optional server dont-check) |
| 134 | (nnweb-possibly-change-server group server) | 134 | (nnweb-possibly-change-server group server) |
| 135 | (unless (or nnweb-ephemeral-p | 135 | (unless (or nnweb-ephemeral-p |
| 136 | dont-check) | 136 | dont-check |
| 137 | nnweb-articles) | ||
| 137 | (nnweb-read-overview group)) | 138 | (nnweb-read-overview group)) |
| 138 | (cond | 139 | (cond |
| 139 | ((not nnweb-articles) | 140 | ((not nnweb-articles) |
diff --git a/lisp/gnus/rfc2231.el b/lisp/gnus/rfc2231.el index df9a5b7bd82..fb2d070328e 100644 --- a/lisp/gnus/rfc2231.el +++ b/lisp/gnus/rfc2231.el | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | ;;; rfc2231.el --- Functions for decoding rfc2231 headers | 1 | ;;; rfc2231.el --- Functions for decoding rfc2231 headers |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1998, 1999, 2000, 2002, 2003, 2004, | 3 | ;; Copyright (C) 1998, 1999, 2000, 2002, 2003, 2004, 2005, |
| 4 | ;; 2005 Free Software Foundation, Inc. | 4 | ;; 2006 Free Software Foundation, Inc. |
| 5 | 5 | ||
| 6 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> | 6 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> |
| 7 | ;; This file is part of GNU Emacs. | 7 | ;; This file is part of GNU Emacs. |
| @@ -53,6 +53,10 @@ The list will be on the form | |||
| 53 | display-name mailbox c display-string parameters | 53 | display-name mailbox c display-string parameters |
| 54 | attribute value type subtype number encoded | 54 | attribute value type subtype number encoded |
| 55 | prev-attribute prev-encoded) | 55 | prev-attribute prev-encoded) |
| 56 | ;; Some mailer (e.g. Thunderbird 1.5) doesn't terminate each | ||
| 57 | ;; line with semicolon when folding a long parameter value. | ||
| 58 | (while (string-match "\\([^\t\n\r ;]\\)[\t ]*\r?\n[\t ]+" string) | ||
| 59 | (setq string (replace-match "\\1;\n " nil nil string))) | ||
| 56 | (ietf-drums-init (mail-header-remove-whitespace | 60 | (ietf-drums-init (mail-header-remove-whitespace |
| 57 | (mail-header-remove-comments string))) | 61 | (mail-header-remove-comments string))) |
| 58 | (let ((table (copy-syntax-table ietf-drums-syntax-table))) | 62 | (let ((table (copy-syntax-table ietf-drums-syntax-table))) |
| @@ -191,6 +195,7 @@ These look like \"us-ascii'en-us'This%20is%20%2A%2A%2Afun%2A%2A%2A\"." | |||
| 191 | (special (ietf-drums-token-to-list "*'%\n\t")) | 195 | (special (ietf-drums-token-to-list "*'%\n\t")) |
| 192 | (ascii (ietf-drums-token-to-list ietf-drums-text-token)) | 196 | (ascii (ietf-drums-token-to-list ietf-drums-text-token)) |
| 193 | (num -1) | 197 | (num -1) |
| 198 | (limit (- 74 (length param))) | ||
| 194 | spacep encodep charsetp charset broken) | 199 | spacep encodep charsetp charset broken) |
| 195 | (with-temp-buffer | 200 | (with-temp-buffer |
| 196 | (insert value) | 201 | (insert value) |
| @@ -209,24 +214,30 @@ These look like \"us-ascii'en-us'This%20is%20%2A%2A%2Afun%2A%2A%2A\"." | |||
| 209 | (when charsetp | 214 | (when charsetp |
| 210 | (setq charset (mm-encode-body))) | 215 | (setq charset (mm-encode-body))) |
| 211 | (cond | 216 | (cond |
| 212 | ((or encodep charsetp) | 217 | ((or encodep charsetp |
| 218 | (progn | ||
| 219 | (end-of-line) | ||
| 220 | (> (current-column) (if spacep (- limit 2) limit)))) | ||
| 221 | (setq limit (- limit 6)) | ||
| 213 | (goto-char (point-min)) | 222 | (goto-char (point-min)) |
| 223 | (insert (symbol-name (or charset 'us-ascii)) "''") | ||
| 214 | (while (not (eobp)) | 224 | (while (not (eobp)) |
| 215 | (when (> (current-column) 60) | ||
| 216 | (insert ";\n") | ||
| 217 | (setq broken t)) | ||
| 218 | (if (or (not (memq (following-char) ascii)) | 225 | (if (or (not (memq (following-char) ascii)) |
| 219 | (memq (following-char) control) | 226 | (memq (following-char) control) |
| 220 | (memq (following-char) tspecial) | 227 | (memq (following-char) tspecial) |
| 221 | (memq (following-char) special) | 228 | (memq (following-char) special) |
| 222 | (eq (following-char) ? )) | 229 | (eq (following-char) ? )) |
| 223 | (progn | 230 | (progn |
| 231 | (when (>= (current-column) (1- limit)) | ||
| 232 | (insert ";\n") | ||
| 233 | (setq broken t)) | ||
| 224 | (insert "%" (format "%02x" (following-char))) | 234 | (insert "%" (format "%02x" (following-char))) |
| 225 | (delete-char 1)) | 235 | (delete-char 1)) |
| 236 | (when (> (current-column) limit) | ||
| 237 | (insert ";\n") | ||
| 238 | (setq broken t)) | ||
| 226 | (forward-char 1))) | 239 | (forward-char 1))) |
| 227 | (goto-char (point-min)) | 240 | (goto-char (point-min)) |
| 228 | (insert (symbol-name (or charset 'us-ascii)) "''") | ||
| 229 | (goto-char (point-min)) | ||
| 230 | (if (not broken) | 241 | (if (not broken) |
| 231 | (insert param "*=") | 242 | (insert param "*=") |
| 232 | (while (not (eobp)) | 243 | (while (not (eobp)) |
| @@ -235,12 +246,12 @@ These look like \"us-ascii'en-us'This%20is%20%2A%2A%2Afun%2A%2A%2A\"." | |||
| 235 | (forward-line 1)))) | 246 | (forward-line 1)))) |
| 236 | (spacep | 247 | (spacep |
| 237 | (goto-char (point-min)) | 248 | (goto-char (point-min)) |
| 238 | (insert param "=\"") | 249 | (insert "\n " param "=\"") |
| 239 | (goto-char (point-max)) | 250 | (goto-char (point-max)) |
| 240 | (insert "\"")) | 251 | (insert "\"")) |
| 241 | (t | 252 | (t |
| 242 | (goto-char (point-min)) | 253 | (goto-char (point-min)) |
| 243 | (insert param "="))) | 254 | (insert "\n " param "="))) |
| 244 | (buffer-string)))) | 255 | (buffer-string)))) |
| 245 | 256 | ||
| 246 | (provide 'rfc2231) | 257 | (provide 'rfc2231) |
diff --git a/lisp/hi-lock.el b/lisp/hi-lock.el index 956ae3a6798..f028bd1f464 100644 --- a/lisp/hi-lock.el +++ b/lisp/hi-lock.el | |||
| @@ -91,7 +91,7 @@ | |||
| 91 | 91 | ||
| 92 | (defcustom hi-lock-file-patterns-range 10000 | 92 | (defcustom hi-lock-file-patterns-range 10000 |
| 93 | "Limit of search in a buffer for hi-lock patterns. | 93 | "Limit of search in a buffer for hi-lock patterns. |
| 94 | When a file is visited and hi-lock mode is on patterns starting | 94 | When a file is visited and hi-lock mode is on, patterns starting |
| 95 | up to this limit are added to font-lock's patterns. See documentation | 95 | up to this limit are added to font-lock's patterns. See documentation |
| 96 | of functions `hi-lock-mode' and `hi-lock-find-patterns'." | 96 | of functions `hi-lock-mode' and `hi-lock-find-patterns'." |
| 97 | :type 'integer | 97 | :type 'integer |
| @@ -200,7 +200,7 @@ calls." | |||
| 200 | 200 | ||
| 201 | (defvar hi-lock-archaic-interface-message-used nil | 201 | (defvar hi-lock-archaic-interface-message-used nil |
| 202 | "True if user alerted that `global-hi-lock-mode' is now the global switch. | 202 | "True if user alerted that `global-hi-lock-mode' is now the global switch. |
| 203 | Earlier versions of hi-lock used `hi-lock-mode' as the global switch, | 203 | Earlier versions of hi-lock used `hi-lock-mode' as the global switch; |
| 204 | the message is issued if it appears that `hi-lock-mode' is used assuming | 204 | the message is issued if it appears that `hi-lock-mode' is used assuming |
| 205 | that older functionality. This variable avoids multiple reminders.") | 205 | that older functionality. This variable avoids multiple reminders.") |
| 206 | 206 | ||
| @@ -283,10 +283,10 @@ called interactively, are: | |||
| 283 | Remove highlighting on matches of REGEXP in current buffer. | 283 | Remove highlighting on matches of REGEXP in current buffer. |
| 284 | 284 | ||
| 285 | \\[hi-lock-write-interactive-patterns] | 285 | \\[hi-lock-write-interactive-patterns] |
| 286 | Write active REGEXPs into buffer as comments (if possible). They will | 286 | Write active REGEXPs into buffer as comments (if possible). They will |
| 287 | be read the next time file is loaded or when the \\[hi-lock-find-patterns] command | 287 | be read the next time file is loaded or when the \\[hi-lock-find-patterns] command |
| 288 | is issued. The inserted regexps are in the form of font lock keywords. | 288 | is issued. The inserted regexps are in the form of font lock keywords. |
| 289 | (See `font-lock-keywords') They may be edited and re-loaded with \\[hi-lock-find-patterns], | 289 | (See `font-lock-keywords'.) They may be edited and re-loaded with \\[hi-lock-find-patterns], |
| 290 | any valid `font-lock-keywords' form is acceptable. | 290 | any valid `font-lock-keywords' form is acceptable. |
| 291 | 291 | ||
| 292 | \\[hi-lock-find-patterns] | 292 | \\[hi-lock-find-patterns] |
| @@ -295,12 +295,12 @@ called interactively, are: | |||
| 295 | When hi-lock is started and if the mode is not excluded, the | 295 | When hi-lock is started and if the mode is not excluded, the |
| 296 | beginning of the buffer is searched for lines of the form: | 296 | beginning of the buffer is searched for lines of the form: |
| 297 | Hi-lock: FOO | 297 | Hi-lock: FOO |
| 298 | where FOO is a list of patterns. These are added to the font lock keywords | 298 | where FOO is a list of patterns. These are added to the font lock |
| 299 | already present. The patterns must start before position (number | 299 | keywords already present. The patterns must start before position |
| 300 | of characters into buffer) `hi-lock-file-patterns-range'. Patterns | 300 | \(number of characters into buffer) `hi-lock-file-patterns-range'. |
| 301 | will be read until | 301 | Patterns will be read until |
| 302 | Hi-lock: end | 302 | Hi-lock: end |
| 303 | is found. A mode is excluded if it's in the list `hi-lock-exclude-modes'." | 303 | is found. A mode is excluded if it's in the list `hi-lock-exclude-modes'." |
| 304 | :group 'hi-lock | 304 | :group 'hi-lock |
| 305 | :lighter (:eval (if (or hi-lock-interactive-patterns | 305 | :lighter (:eval (if (or hi-lock-interactive-patterns |
| 306 | hi-lock-file-patterns) | 306 | hi-lock-file-patterns) |
| @@ -365,7 +365,7 @@ versions before 22 use the following in your .emacs file: | |||
| 365 | Interactively, prompt for REGEXP then FACE. Buffer-local history | 365 | Interactively, prompt for REGEXP then FACE. Buffer-local history |
| 366 | list maintained for regexps, global history maintained for faces. | 366 | list maintained for regexps, global history maintained for faces. |
| 367 | \\<minibuffer-local-map>Use \\[next-history-element] and \\[previous-history-element] to retrieve next or previous history item. | 367 | \\<minibuffer-local-map>Use \\[next-history-element] and \\[previous-history-element] to retrieve next or previous history item. |
| 368 | \(See info node `Minibuffer History')" | 368 | \(See info node `Minibuffer History'.)" |
| 369 | (interactive | 369 | (interactive |
| 370 | (list | 370 | (list |
| 371 | (hi-lock-regexp-okay | 371 | (hi-lock-regexp-okay |
| @@ -390,7 +390,7 @@ list maintained for regexps, global history maintained for faces. | |||
| 390 | Interactively, prompt for REGEXP then FACE. Buffer-local history | 390 | Interactively, prompt for REGEXP then FACE. Buffer-local history |
| 391 | list maintained for regexps, global history maintained for faces. | 391 | list maintained for regexps, global history maintained for faces. |
| 392 | \\<minibuffer-local-map>Use \\[next-history-element] and \\[previous-history-element] to retrieve next or previous history item. | 392 | \\<minibuffer-local-map>Use \\[next-history-element] and \\[previous-history-element] to retrieve next or previous history item. |
| 393 | \(See info node `Minibuffer History')" | 393 | \(See info node `Minibuffer History'.)" |
| 394 | (interactive | 394 | (interactive |
| 395 | (list | 395 | (list |
| 396 | (hi-lock-regexp-okay | 396 | (hi-lock-regexp-okay |
| @@ -595,7 +595,7 @@ not suitable." | |||
| 595 | (message "Hi-lock added %d patterns." (length all-patterns)))))) | 595 | (message "Hi-lock added %d patterns." (length all-patterns)))))) |
| 596 | 596 | ||
| 597 | (defun hi-lock-font-lock-hook () | 597 | (defun hi-lock-font-lock-hook () |
| 598 | "Add hi lock patterns to font-lock's." | 598 | "Add hi-lock patterns to font-lock's." |
| 599 | (if font-lock-mode | 599 | (if font-lock-mode |
| 600 | (progn | 600 | (progn |
| 601 | (font-lock-add-keywords nil hi-lock-file-patterns t) | 601 | (font-lock-add-keywords nil hi-lock-file-patterns t) |
diff --git a/lisp/hilit-chg.el b/lisp/hilit-chg.el index 7011ff37dd3..55eafb5c617 100644 --- a/lisp/hilit-chg.el +++ b/lisp/hilit-chg.el | |||
| @@ -261,15 +261,15 @@ colors then use this, if you want fancier faces then set | |||
| 261 | ;; active or passive mode? | 261 | ;; active or passive mode? |
| 262 | ;; | 262 | ;; |
| 263 | (defcustom highlight-changes-initial-state 'active | 263 | (defcustom highlight-changes-initial-state 'active |
| 264 | "*What state (active or passive) `highlight-changes' should start in. | 264 | "*What state (active or passive) Highlight Changes mode should start in. |
| 265 | This is used when `highlight-changes' is called with no argument. | 265 | This is used when `highlight-changes-mode' is called with no argument. |
| 266 | This variable must be set to one of the symbols `active' or `passive'." | 266 | This variable must be set to one of the symbols `active' or `passive'." |
| 267 | :type '(choice (const :tag "Active" active) | 267 | :type '(choice (const :tag "Active" active) |
| 268 | (const :tag "Passive" passive)) | 268 | (const :tag "Passive" passive)) |
| 269 | :group 'highlight-changes) | 269 | :group 'highlight-changes) |
| 270 | 270 | ||
| 271 | (defcustom highlight-changes-global-initial-state 'passive | 271 | (defcustom highlight-changes-global-initial-state 'passive |
| 272 | "*What state `global-highlight-changes' should start in. | 272 | "*What state global Highlight Changes mode should start in. |
| 273 | This is used if `global-highlight-changes' is called with no argument. | 273 | This is used if `global-highlight-changes' is called with no argument. |
| 274 | This variable must be set to either `active' or `passive'." | 274 | This variable must be set to either `active' or `passive'." |
| 275 | :type '(choice (const :tag "Active" active) | 275 | :type '(choice (const :tag "Active" active) |
| @@ -309,7 +309,7 @@ its name does not begin with ` ' or `*'. | |||
| 309 | A value of nil means no buffers are suitable for `global-highlight-changes' | 309 | A value of nil means no buffers are suitable for `global-highlight-changes' |
| 310 | \(effectively disabling the mode). | 310 | \(effectively disabling the mode). |
| 311 | 311 | ||
| 312 | Examples: | 312 | Example: |
| 313 | (c-mode c++-mode) | 313 | (c-mode c++-mode) |
| 314 | means that Highlight Changes mode is turned on for buffers in C and C++ | 314 | means that Highlight Changes mode is turned on for buffers in C and C++ |
| 315 | modes only." | 315 | modes only." |
| @@ -366,7 +366,7 @@ remove it from existing buffers." | |||
| 366 | (copy-face 'highlight-changes new-name) | 366 | (copy-face 'highlight-changes new-name) |
| 367 | (copy-face old-name new-name) | 367 | (copy-face old-name new-name) |
| 368 | )) | 368 | )) |
| 369 | (setq new-list (append (list new-name) new-list)) | 369 | (setq new-list (append (list new-name) new-list)) |
| 370 | (setq n (1- n)) | 370 | (setq n (1- n)) |
| 371 | (setq p (cdr p))) | 371 | (setq p (cdr p))) |
| 372 | (if (equal new-list (widget-value w)) | 372 | (if (equal new-list (widget-value w)) |
| @@ -419,7 +419,7 @@ Otherwise, this list will be constructed when needed from | |||
| 419 | 419 | ||
| 420 | ;;; Functions... | 420 | ;;; Functions... |
| 421 | 421 | ||
| 422 | (defun hilit-chg-map-changes (func &optional start-position end-position) | 422 | (defun hilit-chg-map-changes (func &optional start-position end-position) |
| 423 | "Call function FUNC for each region used by Highlight Changes mode." | 423 | "Call function FUNC for each region used by Highlight Changes mode." |
| 424 | ;; if start-position is nil, (point-min) is used | 424 | ;; if start-position is nil, (point-min) is used |
| 425 | ;; if end-position is nil, (point-max) is used | 425 | ;; if end-position is nil, (point-max) is used |
| @@ -1048,7 +1048,7 @@ changes are made, so \\[highlight-changes-next-change] and | |||
| 1048 | When called interactively: | 1048 | When called interactively: |
| 1049 | - if no prefix, toggle global Highlight Changes mode on or off | 1049 | - if no prefix, toggle global Highlight Changes mode on or off |
| 1050 | - if called with a positive prefix (or just C-u) turn it on in active mode | 1050 | - if called with a positive prefix (or just C-u) turn it on in active mode |
| 1051 | - if called with a zero prefix turn it on in passive mode | 1051 | - if called with a zero prefix turn it on in passive mode |
| 1052 | - if called with a negative prefix turn it off | 1052 | - if called with a negative prefix turn it off |
| 1053 | 1053 | ||
| 1054 | When called from a program: | 1054 | When called from a program: |
diff --git a/lisp/ibuf-ext.el b/lisp/ibuf-ext.el index 2de72547887..e5820d066e2 100644 --- a/lisp/ibuf-ext.el +++ b/lisp/ibuf-ext.el | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | ;;; ibuf-ext.el --- extensions for ibuffer | 1 | ;;; ibuf-ext.el --- extensions for ibuffer |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 2000, 2001, 2002, 2003, 2004, | 3 | ;; Copyright (C) 2000, 2001, 2002, 2003, 2004, |
| 4 | ;; 2005 Free Software Foundation, Inc. | 4 | ;; 2005, 2006 Free Software Foundation, Inc. |
| 5 | 5 | ||
| 6 | ;; Author: Colin Walters <walters@verbum.org> | 6 | ;; Author: Colin Walters <walters@verbum.org> |
| 7 | ;; Maintainer: John Paul Wallington <jpw@gnu.org> | 7 | ;; Maintainer: John Paul Wallington <jpw@gnu.org> |
| @@ -1449,6 +1449,17 @@ You can then feed the file name(s) to other commands with \\[yank]." | |||
| 1449 | (memq major-mode ibuffer-help-buffer-modes))))) | 1449 | (memq major-mode ibuffer-help-buffer-modes))))) |
| 1450 | 1450 | ||
| 1451 | ;;;###autoload | 1451 | ;;;###autoload |
| 1452 | (defun ibuffer-mark-compressed-file-buffers () | ||
| 1453 | "Mark buffers whose associated file is compressed." | ||
| 1454 | (interactive) | ||
| 1455 | (ibuffer-mark-on-buffer | ||
| 1456 | #'(lambda (buf) | ||
| 1457 | (with-current-buffer buf | ||
| 1458 | (and buffer-file-name | ||
| 1459 | (string-match ibuffer-compressed-file-name-regexp | ||
| 1460 | buffer-file-name)))))) | ||
| 1461 | |||
| 1462 | ;;;###autoload | ||
| 1452 | (defun ibuffer-mark-old-buffers () | 1463 | (defun ibuffer-mark-old-buffers () |
| 1453 | "Mark buffers which have not been viewed in `ibuffer-old-time' days." | 1464 | "Mark buffers which have not been viewed in `ibuffer-old-time' days." |
| 1454 | (interactive) | 1465 | (interactive) |
diff --git a/lisp/ibuffer.el b/lisp/ibuffer.el index 9406cf0a1b8..179c7b334bd 100644 --- a/lisp/ibuffer.el +++ b/lisp/ibuffer.el | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | ;;; ibuffer.el --- operate on buffers like dired | 1 | ;;; ibuffer.el --- operate on buffers like dired |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 2000, 2001, 2002, 2003, 2004, | 3 | ;; Copyright (C) 2000, 2001, 2002, 2003, 2004, |
| 4 | ;; 2005 Free Software Foundation, Inc. | 4 | ;; 2005, 2006 Free Software Foundation, Inc. |
| 5 | 5 | ||
| 6 | ;; Author: Colin Walters <walters@verbum.org> | 6 | ;; Author: Colin Walters <walters@verbum.org> |
| 7 | ;; Maintainer: John Paul Wallington <jpw@gnu.org> | 7 | ;; Maintainer: John Paul Wallington <jpw@gnu.org> |
| @@ -142,12 +142,16 @@ elisp byte-compiler." | |||
| 142 | 142 | ||
| 143 | (defcustom ibuffer-fontification-alist | 143 | (defcustom ibuffer-fontification-alist |
| 144 | `((10 buffer-read-only font-lock-constant-face) | 144 | `((10 buffer-read-only font-lock-constant-face) |
| 145 | (15 (string-match "^*" (buffer-name)) font-lock-keyword-face) | 145 | (15 (and buffer-file-name |
| 146 | (20 (and (string-match "^ " (buffer-name)) | 146 | (string-match ibuffer-compressed-file-name-regexp |
| 147 | buffer-file-name)) | ||
| 148 | font-lock-doc-face) | ||
| 149 | (20 (string-match "^*" (buffer-name)) font-lock-keyword-face) | ||
| 150 | (25 (and (string-match "^ " (buffer-name)) | ||
| 147 | (null buffer-file-name)) | 151 | (null buffer-file-name)) |
| 148 | italic) | 152 | italic) |
| 149 | (25 (memq major-mode ibuffer-help-buffer-modes) font-lock-comment-face) | 153 | (30 (memq major-mode ibuffer-help-buffer-modes) font-lock-comment-face) |
| 150 | (30 (eq major-mode 'dired-mode) font-lock-function-name-face)) | 154 | (35 (eq major-mode 'dired-mode) font-lock-function-name-face)) |
| 151 | "An alist describing how to fontify buffers. | 155 | "An alist describing how to fontify buffers. |
| 152 | Each element should be of the form (PRIORITY FORM FACE), where | 156 | Each element should be of the form (PRIORITY FORM FACE), where |
| 153 | PRIORITY is an integer, FORM is an arbitrary form to evaluate in the | 157 | PRIORITY is an integer, FORM is an arbitrary form to evaluate in the |
| @@ -320,6 +324,14 @@ directory, like `default-directory'." | |||
| 320 | :type '(repeat function) | 324 | :type '(repeat function) |
| 321 | :group 'ibuffer) | 325 | :group 'ibuffer) |
| 322 | 326 | ||
| 327 | (defcustom ibuffer-compressed-file-name-regexp | ||
| 328 | (concat "\\.\\(" | ||
| 329 | (regexp-opt '("arj" "bgz" "bz2" "gz" "lzh" "taz" "tgz" "zip" "z")) | ||
| 330 | "\\)$") | ||
| 331 | "Regexp to match compressed file names." | ||
| 332 | :type 'regexp | ||
| 333 | :group 'ibuffer) | ||
| 334 | |||
| 323 | (defcustom ibuffer-hook nil | 335 | (defcustom ibuffer-hook nil |
| 324 | "Hook run when `ibuffer' is called." | 336 | "Hook run when `ibuffer' is called." |
| 325 | :type 'hook | 337 | :type 'hook |
| @@ -403,6 +415,7 @@ directory, like `default-directory'." | |||
| 403 | (define-key map (kbd "* /") 'ibuffer-mark-dired-buffers) | 415 | (define-key map (kbd "* /") 'ibuffer-mark-dired-buffers) |
| 404 | (define-key map (kbd "* e") 'ibuffer-mark-dissociated-buffers) | 416 | (define-key map (kbd "* e") 'ibuffer-mark-dissociated-buffers) |
| 405 | (define-key map (kbd "* h") 'ibuffer-mark-help-buffers) | 417 | (define-key map (kbd "* h") 'ibuffer-mark-help-buffers) |
| 418 | (define-key map (kbd "* z") 'ibuffer-mark-compressed-file-buffers) | ||
| 406 | (define-key map (kbd ".") 'ibuffer-mark-old-buffers) | 419 | (define-key map (kbd ".") 'ibuffer-mark-old-buffers) |
| 407 | 420 | ||
| 408 | (define-key map (kbd "d") 'ibuffer-mark-for-delete) | 421 | (define-key map (kbd "d") 'ibuffer-mark-for-delete) |
| @@ -718,6 +731,9 @@ directory, like `default-directory'." | |||
| 718 | (define-key-after map [menu-bar mark mark-help-buffers] | 731 | (define-key-after map [menu-bar mark mark-help-buffers] |
| 719 | '(menu-item "Mark help buffers" ibuffer-mark-help-buffers | 732 | '(menu-item "Mark help buffers" ibuffer-mark-help-buffers |
| 720 | :help "Mark buffers in help-mode")) | 733 | :help "Mark buffers in help-mode")) |
| 734 | (define-key-after map [menu-bar mark mark-compressed-file-buffers] | ||
| 735 | '(menu-item "Mark compressed file buffers" ibuffer-mark-compressed-file-buffers | ||
| 736 | :help "Mark buffers which have a file that is compressed")) | ||
| 721 | (define-key-after map [menu-bar mark mark-old-buffers] | 737 | (define-key-after map [menu-bar mark mark-old-buffers] |
| 722 | '(menu-item "Mark old buffers" ibuffer-mark-old-buffers | 738 | '(menu-item "Mark old buffers" ibuffer-mark-old-buffers |
| 723 | :help "Mark buffers which have not been viewed recently")) | 739 | :help "Mark buffers which have not been viewed recently")) |
diff --git a/lisp/international/mule-cmds.el b/lisp/international/mule-cmds.el index 4b643fbc698..dcf46878aa2 100644 --- a/lisp/international/mule-cmds.el +++ b/lisp/international/mule-cmds.el | |||
| @@ -2384,7 +2384,8 @@ See also `locale-charset-language-names', `locale-language-names', | |||
| 2384 | ;; to a system without X. | 2384 | ;; to a system without X. |
| 2385 | (setq locale-translation-file-name | 2385 | (setq locale-translation-file-name |
| 2386 | (let ((files | 2386 | (let ((files |
| 2387 | '("/usr/lib/X11/locale/locale.alias" ; e.g. X11R6.4 | 2387 | '("/usr/share/X11/locale/locale.alias" ; e.g. X11R7 |
| 2388 | "/usr/lib/X11/locale/locale.alias" ; e.g. X11R6.4 | ||
| 2388 | "/usr/X11R6/lib/X11/locale/locale.alias" ; XFree86, e.g. RedHat 4.2 | 2389 | "/usr/X11R6/lib/X11/locale/locale.alias" ; XFree86, e.g. RedHat 4.2 |
| 2389 | "/usr/openwin/lib/locale/locale.alias" ; e.g. Solaris 2.6 | 2390 | "/usr/openwin/lib/locale/locale.alias" ; e.g. Solaris 2.6 |
| 2390 | ;; | 2391 | ;; |
diff --git a/lisp/mail/mailclient.el b/lisp/mail/mailclient.el index eb12d97f576..45afbd782d9 100644 --- a/lisp/mail/mailclient.el +++ b/lisp/mail/mailclient.el | |||
| @@ -24,21 +24,21 @@ | |||
| 24 | 24 | ||
| 25 | ;;; Commentary: | 25 | ;;; Commentary: |
| 26 | 26 | ||
| 27 | ;; This package allows to hand over a buffer to be sent off | 27 | ;; This package allows to hand over a buffer to be sent off |
| 28 | ;; via the system's designated e-mail client. | 28 | ;; via the system's designated e-mail client. |
| 29 | ;; Note that the e-mail client will display the contents of the buffer | 29 | ;; Note that the e-mail client will display the contents of the buffer |
| 30 | ;; again for editing. | 30 | ;; again for editing. |
| 31 | ;; The e-mail client is taken to be whoever handles a mailto: URL | 31 | ;; The e-mail client is taken to be whoever handles a mailto: URL |
| 32 | ;; via `browse-url'. | 32 | ;; via `browse-url'. |
| 33 | ;; Mailto: URLs are composed according to RFC2368. | 33 | ;; Mailto: URLs are composed according to RFC2368. |
| 34 | 34 | ||
| 35 | ;; MIME bodies are not supported - we rather expect the mail client | 35 | ;; MIME bodies are not supported - we rather expect the mail client |
| 36 | ;; to encode the body and add, for example, a digital signature. | 36 | ;; to encode the body and add, for example, a digital signature. |
| 37 | ;; The mailto URL RFC calls for "short text messages that are | 37 | ;; The mailto URL RFC calls for "short text messages that are |
| 38 | ;; actually the content of automatic processing." | 38 | ;; actually the content of automatic processing." |
| 39 | ;; So mailclient.el is ideal for situations where an e-mail is | 39 | ;; So mailclient.el is ideal for situations where an e-mail is |
| 40 | ;; generated automatically, and the user can edit it in the | 40 | ;; generated automatically, and the user can edit it in the |
| 41 | ;; mail client (e.g. bug-reports). | 41 | ;; mail client (e.g. bug-reports). |
| 42 | 42 | ||
| 43 | ;; To activate: | 43 | ;; To activate: |
| 44 | ;; (setq send-mail-function 'mailclient-send-it) ; if you use `mail' | 44 | ;; (setq send-mail-function 'mailclient-send-it) ; if you use `mail' |
| @@ -49,11 +49,11 @@ | |||
| 49 | (require 'sendmail) ;; for mail-sendmail-undelimit-header | 49 | (require 'sendmail) ;; for mail-sendmail-undelimit-header |
| 50 | (require 'mail-utils) ;; for mail-fetch-field | 50 | (require 'mail-utils) ;; for mail-fetch-field |
| 51 | 51 | ||
| 52 | (defcustom mailclient-place-body-on-clipboard-flag | 52 | (defcustom mailclient-place-body-on-clipboard-flag |
| 53 | (fboundp 'w32-set-clipboard-data) | 53 | (fboundp 'w32-set-clipboard-data) |
| 54 | "If non-nil, put the e-mail body on the clipboard in mailclient. | 54 | "If non-nil, put the e-mail body on the clipboard in mailclient. |
| 55 | This is useful on systems where only short mailto:// URLs are | 55 | This is useful on systems where only short mailto:// URLs are |
| 56 | supported. Defaults to non-nil on Windows, nil otherwise." | 56 | supported. Defaults to non-nil on Windows, nil otherwise." |
| 57 | :type 'boolean | 57 | :type 'boolean |
| 58 | :group 'mail) | 58 | :group 'mail) |
| 59 | 59 | ||
| @@ -64,7 +64,7 @@ supported. Defaults to non-nil on Windows, nil otherwise." | |||
| 64 | (lambda (char) | 64 | (lambda (char) |
| 65 | (cond | 65 | (cond |
| 66 | ((eq char ?\x20) "%20") ;; space | 66 | ((eq char ?\x20) "%20") ;; space |
| 67 | ((eq char ?\n) "%0D%0A") ;; newline | 67 | ((eq char ?\n) "%0D%0A") ;; newline |
| 68 | ((string-match "[-a-zA-Z0-9_:/.@]" (char-to-string char)) | 68 | ((string-match "[-a-zA-Z0-9_:/.@]" (char-to-string char)) |
| 69 | (char-to-string char)) ;; printable | 69 | (char-to-string char)) ;; printable |
| 70 | (t ;; everything else | 70 | (t ;; everything else |
| @@ -75,33 +75,33 @@ supported. Defaults to non-nil on Windows, nil otherwise." | |||
| 75 | (defvar mailclient-delim-static "?") | 75 | (defvar mailclient-delim-static "?") |
| 76 | (defun mailclient-url-delim () | 76 | (defun mailclient-url-delim () |
| 77 | (let ((current mailclient-delim-static)) | 77 | (let ((current mailclient-delim-static)) |
| 78 | (setq mailclient-delim-static "&") | 78 | (setq mailclient-delim-static "&") |
| 79 | current)) | 79 | current)) |
| 80 | 80 | ||
| 81 | (defun mailclient-gather-addresses (str &optional drop-first-name) | 81 | (defun mailclient-gather-addresses (str &optional drop-first-name) |
| 82 | (let ((field (mail-fetch-field str nil t))) | 82 | (let ((field (mail-fetch-field str nil t))) |
| 83 | (if field | 83 | (if field |
| 84 | (save-excursion | 84 | (save-excursion |
| 85 | (let ((first t) | 85 | (let ((first t) |
| 86 | (result "")) | 86 | (result "")) |
| 87 | (mapc | 87 | (mapc |
| 88 | (lambda (recp) | 88 | (lambda (recp) |
| 89 | (setq result | 89 | (setq result |
| 90 | (concat | 90 | (concat |
| 91 | result | 91 | result |
| 92 | (if (and drop-first-name | 92 | (if (and drop-first-name |
| 93 | first) | 93 | first) |
| 94 | "" | 94 | "" |
| 95 | (concat (mailclient-url-delim) str "=")) | 95 | (concat (mailclient-url-delim) str "=")) |
| 96 | (mailclient-encode-string-as-url | 96 | (mailclient-encode-string-as-url |
| 97 | recp))) | 97 | recp))) |
| 98 | (setq first nil)) | 98 | (setq first nil)) |
| 99 | (split-string | 99 | (split-string |
| 100 | (mail-strip-quoted-names field) "\, *")) | 100 | (mail-strip-quoted-names field) "\, *")) |
| 101 | result))))) | 101 | result))))) |
| 102 | 102 | ||
| 103 | ;;;###autoload | 103 | ;;;###autoload |
| 104 | (defun mailclient-send-it () | 104 | (defun mailclient-send-it () |
| 105 | "Pass current buffer on to the system's mail client. | 105 | "Pass current buffer on to the system's mail client. |
| 106 | Suitable value for `send-mail-function'. | 106 | Suitable value for `send-mail-function'. |
| 107 | The mail client is taken to be the handler of mailto URLs." | 107 | The mail client is taken to be the handler of mailto URLs." |
| @@ -122,19 +122,19 @@ The mail client is taken to be the handler of mailto URLs." | |||
| 122 | (while (and (re-search-forward "\n\n\n*" delimline t) | 122 | (while (and (re-search-forward "\n\n\n*" delimline t) |
| 123 | (< (point) delimline)) | 123 | (< (point) delimline)) |
| 124 | (replace-match "\n")) | 124 | (replace-match "\n")) |
| 125 | (let ((case-fold-search t)) | 125 | (let ((case-fold-search t)) |
| 126 | ;; initialize limiter | 126 | ;; initialize limiter |
| 127 | (setq mailclient-delim-static "?") | 127 | (setq mailclient-delim-static "?") |
| 128 | ;; construct and call up mailto URL | 128 | ;; construct and call up mailto URL |
| 129 | (browse-url | 129 | (browse-url |
| 130 | (concat | 130 | (concat |
| 131 | (save-excursion | 131 | (save-excursion |
| 132 | (narrow-to-region (point-min) delimline) | 132 | (narrow-to-region (point-min) delimline) |
| 133 | (concat | 133 | (concat |
| 134 | "mailto:" | 134 | "mailto:" |
| 135 | ;; some of the headers according to RFC822 | 135 | ;; some of the headers according to RFC822 |
| 136 | (mailclient-gather-addresses "To" | 136 | (mailclient-gather-addresses "To" |
| 137 | 'drop-first-name) | 137 | 'drop-first-name) |
| 138 | (mailclient-gather-addresses "cc" ) | 138 | (mailclient-gather-addresses "cc" ) |
| 139 | (mailclient-gather-addresses "bcc" ) | 139 | (mailclient-gather-addresses "bcc" ) |
| 140 | (mailclient-gather-addresses "Resent-To" ) | 140 | (mailclient-gather-addresses "Resent-To" ) |
| @@ -151,16 +151,16 @@ The mail client is taken to be the handler of mailto URLs." | |||
| 151 | (if subj ;; if non-blank | 151 | (if subj ;; if non-blank |
| 152 | ;; the mail client will deal with | 152 | ;; the mail client will deal with |
| 153 | ;; warning the user etc. | 153 | ;; warning the user etc. |
| 154 | (concat (mailclient-url-delim) "subject=" | 154 | (concat (mailclient-url-delim) "subject=" |
| 155 | (mailclient-encode-string-as-url subj)) | 155 | (mailclient-encode-string-as-url subj)) |
| 156 | "")))) | 156 | "")))) |
| 157 | ;; body | 157 | ;; body |
| 158 | (concat | 158 | (concat |
| 159 | (mailclient-url-delim) "body=" | 159 | (mailclient-url-delim) "body=" |
| 160 | (mailclient-encode-string-as-url | 160 | (mailclient-encode-string-as-url |
| 161 | (if mailclient-place-body-on-clipboard-flag | 161 | (if mailclient-place-body-on-clipboard-flag |
| 162 | (progn | 162 | (progn |
| 163 | (clipboard-kill-ring-save | 163 | (clipboard-kill-ring-save |
| 164 | (+ 1 delimline) (point-max)) | 164 | (+ 1 delimline) (point-max)) |
| 165 | (concat | 165 | (concat |
| 166 | "*** E-Mail body has been placed on clipboard, " | 166 | "*** E-Mail body has been placed on clipboard, " |
diff --git a/lisp/mh-e/ChangeLog b/lisp/mh-e/ChangeLog index dc465888f44..8d8b64c75fb 100644 --- a/lisp/mh-e/ChangeLog +++ b/lisp/mh-e/ChangeLog | |||
| @@ -1,10 +1,168 @@ | |||
| 1 | 2006-02-03 Bill Wohler <wohler@newt.com> | ||
| 2 | |||
| 3 | * mh-e.el (Version, mh-version): Add +cvs to version. | ||
| 4 | |||
| 5 | 2006-02-03 Bill Wohler <wohler@newt.com> | ||
| 6 | |||
| 7 | Release MH-E version 7.91. | ||
| 8 | |||
| 9 | * mh-e.el (Version, mh-version): Update for release 7.91. | ||
| 10 | |||
| 11 | 2006-02-03 Bill Wohler <wohler@newt.com> | ||
| 12 | |||
| 13 | * mh-utils.el (mh-image-load-path, mh-image-load-path-called-flag) | ||
| 14 | (mh-image-load-path): Checkdoc fix. Docstring edits. Reduce scope | ||
| 15 | of local variable mh-library-name. | ||
| 16 | |||
| 17 | * mh-e.el (mh-folder-msg-number, mh-folder-refiled, mh-folder-to) | ||
| 18 | (mh-show-cc, mh-show-date, mh-show-header): Replace (min-colors | ||
| 19 | 88) with (min-colors 64) in face specifications so that MH-E still | ||
| 20 | looks good on systems with fewer colors (such as Eric Ding's). | ||
| 21 | |||
| 22 | 2006-02-03 Peter Galbraith <psg@debian.org> | ||
| 23 | |||
| 24 | * mh-utils.el (mh-image-load-path): New variable to optionally | ||
| 25 | hold the directory where MH-E images are stored. If nil, then | ||
| 26 | the function `mh-image-load-path' will find it. This variable | ||
| 27 | will be used for Debian packaging. | ||
| 28 | (mh-image-load-path function): Use variable `mh-image-load-path' | ||
| 29 | if non-nil and exists. | ||
| 30 | |||
| 31 | 2006-02-03 Mark D. Baushke <mdb@gnu.org> | ||
| 32 | |||
| 33 | * mh-tool-bar.el: Add conditional require of 'tool-bar or 'toolbar | ||
| 34 | for gnu-emacs or xemacs to avoid void-variable tool-bar-map lisp | ||
| 35 | errors if describe-bindings is called before tool-bar-mode is used. | ||
| 36 | |||
| 37 | 2006-02-03 Peter S Galbraith <psg@debian.org> | ||
| 38 | |||
| 39 | * mh-compat.el (mh-url-unreserved-chars): Fix typo from | ||
| 40 | `mh-url-unresrved-chars'. | ||
| 41 | |||
| 42 | 2006-02-02 Bill Wohler <wohler@newt.com> | ||
| 43 | |||
| 44 | * mh-e.el (Version, mh-version): Add +cvs to version. | ||
| 45 | |||
| 46 | 2006-02-02 Bill Wohler <wohler@newt.com> | ||
| 47 | |||
| 48 | Release MH-E version 7.90. | ||
| 49 | |||
| 50 | * mh-e.el (Version, mh-version): Update for release 7.90. | ||
| 51 | |||
| 52 | 2006-02-01 Bill Wohler <wohler@newt.com> | ||
| 53 | |||
| 54 | * mh-search.el (which-func-mode): Shush compiler on Emacs 21 too. | ||
| 55 | |||
| 56 | * mh-alias.el (mh-alias-gecos-name): Use | ||
| 57 | mh-replace-regexp-in-string instead of replace-regexp-in-string. | ||
| 58 | (crm, multi-prompt): Use mh-require instead of require. | ||
| 59 | (mh-goto-address-find-address-at-point): Use | ||
| 60 | mh-line-beginning-position and mh-line-end-position instead of | ||
| 61 | line-beginning-position and line-end-position. Use | ||
| 62 | mh-match-string-no-properties instead of | ||
| 63 | match-string-no-properties. | ||
| 64 | |||
| 65 | * mh-comp.el (mh-modify-header-field): Use | ||
| 66 | mh-line-beginning-position and mh-line-end-position instead of | ||
| 67 | line-beginning-position and line-end-position. | ||
| 68 | |||
| 69 | * mh-compat.el (mailabbrev): Use mh-require instead of require. | ||
| 70 | (mh-assoc-string, mh-display-completion-list, mh-face-foreground) | ||
| 71 | (mh-face-background): Make docstring consistent. | ||
| 72 | (mh-require, mh-cancel-timer, mh-display-color-cells) | ||
| 73 | (mh-line-beginning-position, mh-line-end-position) | ||
| 74 | (mh-match-string-no-properties, mh-replace-regexp-in-string) | ||
| 75 | (mh-view-mode-enter): Move definition here from mh-xemacs.el and | ||
| 76 | add mh- prefix since compatibility functions should have our | ||
| 77 | package prefix (mh-) by Emacs convention and to avoid messing up | ||
| 78 | checks for the same functions in other packages. | ||
| 79 | |||
| 80 | * mh-e.el (mh-compiling-flag): Move mh-xemacs-compiling-flag here | ||
| 81 | from mh-xemacs.el and rename. | ||
| 82 | (mh-xargs): Use mh-line-beginning-position and | ||
| 83 | mh-line-end-position instead of line-beginning-position and | ||
| 84 | line-end-position. | ||
| 85 | (mh-defface-compat): Use mh-display-color-cells instead of | ||
| 86 | display-color-cells. | ||
| 87 | |||
| 88 | * mh-folder.el (which-func): Use mh-require instead of require. | ||
| 89 | |||
| 90 | * mh-funcs.el (mh-list-folders): Use mh-view-mode-enter instead of | ||
| 91 | view-mode-enter. | ||
| 92 | |||
| 93 | * mh-gnus.el (gnus-util, mm-bodies, mm-decode, mm-view, mml): Use | ||
| 94 | mh-require instead of require. | ||
| 95 | |||
| 96 | * mh-letter.el (mh-letter-header-end, mh-letter-mode) | ||
| 97 | (mh-letter-next-header-field): Use mh-line-beginning-position and | ||
| 98 | mh-line-end-position instead of line-beginning-position and | ||
| 99 | line-end-position. | ||
| 100 | |||
| 101 | * mh-limit.el (mh-subject-to-sequence-unthreaded): Use | ||
| 102 | mh-match-string-no-properties instead of | ||
| 103 | match-string-no-properties. | ||
| 104 | (mh-narrow-to-header-field): Use mh-line-beginning-position and | ||
| 105 | mh-line-end-position instead of line-beginning-position and | ||
| 106 | line-end-position. | ||
| 107 | |||
| 108 | * mh-mime.el (mh-mime-inline-part, mh-mm-display-part) | ||
| 109 | (mh-mh-quote-unescaped-sharp, mh-mh-directive-present-p): Use | ||
| 110 | mh-line-beginning-position and mh-line-end-position instead of | ||
| 111 | line-beginning-position and line-end-position. | ||
| 112 | |||
| 113 | * mh-search.el (which-func): Use mh-require instead of require. | ||
| 114 | (mh-make-pick-template, mh-index-visit-folder) | ||
| 115 | (mh-pick-parse-search-buffer, mh-swish-next-result) | ||
| 116 | (mh-mairix-next-result, mh-namazu-next-result) | ||
| 117 | (mh-pick-next-result, mh-grep-next-result) | ||
| 118 | (mh-index-create-imenu-index, mh-index-match-checksum) | ||
| 119 | (mh-md5sum-parser, mh-openssl-parser, mh-index-update-maps): Use | ||
| 120 | mh-line-beginning-position and mh-line-end-position instead of | ||
| 121 | line-beginning-position and line-end-position. | ||
| 122 | |||
| 123 | * mh-seq.el (mh-list-sequences): Use mh-view-mode-enter instead of | ||
| 124 | view-mode-enter. | ||
| 125 | (mh-folder-size-flist, mh-parse-flist-output-line) | ||
| 126 | (mh-add-sequence-notation): Use mh-line-beginning-position and | ||
| 127 | mh-line-end-position instead of line-beginning-position and | ||
| 128 | line-end-position. | ||
| 129 | |||
| 130 | * mh-show.el (mh-show-addr): Use mh-require instead of require. | ||
| 131 | |||
| 132 | * mh-speed.el (mh-folder-speedbar-menu-items, mh-speed-toggle) | ||
| 133 | (mh-speed-view, mh-folder-speedbar-buttons) | ||
| 134 | (mh-speed-highlight, mh-speed-goto-folder) | ||
| 135 | (mh-speed-add-buttons, mh-speed-parse-flists-output) | ||
| 136 | (mh-speed-invalidate-map, mh-speedbar-change-expand-button-char) | ||
| 137 | (mh-speed-add-folder): Use mh-line-beginning-position and | ||
| 138 | mh-line-end-position instead of line-beginning-position and | ||
| 139 | line-end-position. | ||
| 140 | (mh-speed-flists): Use mh-cancel-timer instead of cancel-timer. | ||
| 141 | |||
| 142 | * mh-thread.el (mh-thread-find-children) | ||
| 143 | (mh-thread-parse-scan-line, mh-thread-generate): Use | ||
| 144 | mh-line-beginning-position and mh-line-end-position instead of | ||
| 145 | line-beginning-position and line-end-position. | ||
| 146 | |||
| 147 | * mh-utils.el (mh-colors-available-p): Use mh-display-color-cells | ||
| 148 | instead of display-color-cells. | ||
| 149 | (mh-folder-list): Use mh-replace-regexp-in-string instead of | ||
| 150 | replace-regexp-in-string. | ||
| 151 | (mh-sub-folders-actual, mh-letter-toggle-header-field-display): | ||
| 152 | Use mh-line-beginning-position and mh-line-end-position instead of | ||
| 153 | line-beginning-position and line-end-position. | ||
| 154 | |||
| 155 | * mh-comp.el (mh-send-sub): Don't find components file in current | ||
| 156 | directory--this seems to have been a side-effect of commenting out | ||
| 157 | the use of an old mh-etc variable. Improve error message. | ||
| 158 | |||
| 1 | 2006-01-31 Bill Wohler <wohler@newt.com> | 159 | 2006-01-31 Bill Wohler <wohler@newt.com> |
| 2 | 160 | ||
| 3 | * mh-acros.el (mh-defun-compat, mh-defmacro-compat): Add name | 161 | * mh-acros.el (mh-defun-compat, mh-defmacro-compat): Add name |
| 4 | argument since compatibility functions should have our package | 162 | argument since compatibility functions should have our package |
| 5 | prefix (mh-) by Emacs convention and to avoid messing up checks | 163 | prefix (mh-) by Emacs convention and to avoid messing up checks |
| 6 | for the same functions in other packages. Use explicit argument | 164 | for the same functions in other packages. Use explicit argument |
| 7 | instead of forming name by adding mh-e prefix so that one can grep | 165 | instead of forming name by adding mh- prefix so that one can grep |
| 8 | and find the definition. | 166 | and find the definition. |
| 9 | 167 | ||
| 10 | * mh-alias.el (mh-alias-local-users, mh-alias-reload) | 168 | * mh-alias.el (mh-alias-local-users, mh-alias-reload) |
diff --git a/lisp/mh-e/mh-alias.el b/lisp/mh-e/mh-alias.el index 23af886c320..9dc2871241f 100644 --- a/lisp/mh-e/mh-alias.el +++ b/lisp/mh-e/mh-alias.el | |||
| @@ -125,10 +125,10 @@ COMMA-SEPARATOR is non-nil." | |||
| 125 | (setq res (match-string 1 res))) | 125 | (setq res (match-string 1 res))) |
| 126 | ;; Replace "&" with capitalized username | 126 | ;; Replace "&" with capitalized username |
| 127 | (if (string-match "&" res) | 127 | (if (string-match "&" res) |
| 128 | (setq res (replace-regexp-in-string "&" (capitalize username) res))) | 128 | (setq res (mh-replace-regexp-in-string "&" (capitalize username) res))) |
| 129 | ;; Remove " character | 129 | ;; Remove " character |
| 130 | (if (string-match "\"" res) | 130 | (if (string-match "\"" res) |
| 131 | (setq res (replace-regexp-in-string "\"" "" res))) | 131 | (setq res (mh-replace-regexp-in-string "\"" "" res))) |
| 132 | ;; If empty string, use username instead | 132 | ;; If empty string, use username instead |
| 133 | (if (string-equal "" res) | 133 | (if (string-equal "" res) |
| 134 | (setq res username)) | 134 | (setq res username)) |
| @@ -258,8 +258,8 @@ Blind aliases or users from /etc/passwd are not expanded." | |||
| 258 | (t | 258 | (t |
| 259 | (mh-alias-ali alias)))) | 259 | (mh-alias-ali alias)))) |
| 260 | 260 | ||
| 261 | (require 'crm nil t) ; completing-read-multiple | 261 | (mh-require 'crm nil t) ; completing-read-multiple |
| 262 | (require 'multi-prompt nil t) | 262 | (mh-require 'multi-prompt nil t) |
| 263 | 263 | ||
| 264 | ;;;###mh-autoload | 264 | ;;;###mh-autoload |
| 265 | (defun mh-read-address (prompt) | 265 | (defun mh-read-address (prompt) |
| @@ -606,12 +606,12 @@ filing messages." | |||
| 606 | 606 | ||
| 607 | Then search backwards to beginning of line for the start of an | 607 | Then search backwards to beginning of line for the start of an |
| 608 | e-mail address. If no e-mail address found, return nil." | 608 | e-mail address. If no e-mail address found, return nil." |
| 609 | (re-search-backward "[^-_A-z0-9.@]" (line-beginning-position) 'lim) | 609 | (re-search-backward "[^-_A-z0-9.@]" (mh-line-beginning-position) 'lim) |
| 610 | (if (or (looking-at mh-address-mail-regexp) ; already at start | 610 | (if (or (looking-at mh-address-mail-regexp) ; already at start |
| 611 | (and (re-search-forward mh-address-mail-regexp | 611 | (and (re-search-forward mh-address-mail-regexp |
| 612 | (line-end-position) 'lim) | 612 | (mh-line-end-position) 'lim) |
| 613 | (goto-char (match-beginning 0)))) | 613 | (goto-char (match-beginning 0)))) |
| 614 | (match-string-no-properties 0))) | 614 | (mh-match-string-no-properties 0))) |
| 615 | 615 | ||
| 616 | (defun mh-alias-apropos (regexp) | 616 | (defun mh-alias-apropos (regexp) |
| 617 | "Show all aliases or addresses that match a regular expression REGEXP." | 617 | "Show all aliases or addresses that match a regular expression REGEXP." |
diff --git a/lisp/mh-e/mh-comp.el b/lisp/mh-e/mh-comp.el index 5a0907bf612..5d2730f4afa 100644 --- a/lisp/mh-e/mh-comp.el +++ b/lisp/mh-e/mh-comp.el | |||
| @@ -759,18 +759,9 @@ CONFIG is the window configuration before sending mail." | |||
| 759 | (setq components | 759 | (setq components |
| 760 | (expand-file-name mh-comp-formfile mh-lib))) | 760 | (expand-file-name mh-comp-formfile mh-lib))) |
| 761 | components) | 761 | components) |
| 762 | ((file-exists-p | ||
| 763 | (setq components | ||
| 764 | (expand-file-name mh-comp-formfile | ||
| 765 | ;; What is this mh-etc ?? -sm | ||
| 766 | ;; This is dead code, so | ||
| 767 | ;; remove it. | ||
| 768 | ;(and (boundp 'mh-etc) mh-etc) | ||
| 769 | ))) | ||
| 770 | components) | ||
| 771 | (t | 762 | (t |
| 772 | (error "Can't find components file \"%s\"" | 763 | (error "Can't find %s in %s or %s" |
| 773 | components)))) | 764 | mh-comp-formfile mh-user-path mh-lib)))) |
| 774 | nil))) | 765 | nil))) |
| 775 | (mh-insert-fields "To:" to "Subject:" subject "Cc:" cc) | 766 | (mh-insert-fields "To:" to "Subject:" subject "Cc:" cc) |
| 776 | (goto-char (point-max)) | 767 | (goto-char (point-max)) |
| @@ -1040,7 +1031,7 @@ discarded." | |||
| 1040 | (cond ((and overwrite-flag | 1031 | (cond ((and overwrite-flag |
| 1041 | (mh-goto-header-field (concat field ":"))) | 1032 | (mh-goto-header-field (concat field ":"))) |
| 1042 | (insert " " value) | 1033 | (insert " " value) |
| 1043 | (delete-region (point) (line-end-position))) | 1034 | (delete-region (point) (mh-line-end-position))) |
| 1044 | ((and (not overwrite-flag) | 1035 | ((and (not overwrite-flag) |
| 1045 | (mh-regexp-in-field-p (concat "\\b" value "\\b") field)) | 1036 | (mh-regexp-in-field-p (concat "\\b" value "\\b") field)) |
| 1046 | ;; Already there, do nothing. | 1037 | ;; Already there, do nothing. |
diff --git a/lisp/mh-e/mh-compat.el b/lisp/mh-e/mh-compat.el index c60ae20d811..1d7f1c90e79 100644 --- a/lisp/mh-e/mh-compat.el +++ b/lisp/mh-e/mh-compat.el | |||
| @@ -37,31 +37,60 @@ | |||
| 37 | ;; macros we can retire. | 37 | ;; macros we can retire. |
| 38 | 38 | ||
| 39 | ;; Please use mh-gnus.el when providing compatibility with different | 39 | ;; Please use mh-gnus.el when providing compatibility with different |
| 40 | ;; versions of Gnus and mh-xemacs.el for compatibility with XEmacs. | 40 | ;; versions of Gnus. |
| 41 | 41 | ||
| 42 | ;; Items are listed alphabetically. | 42 | ;; Items are listed alphabetically (except for mh-require which is |
| 43 | ;; needed by a lesser character). | ||
| 44 | |||
| 45 | (require 'mh-acros) | ||
| 46 | |||
| 47 | (mh-do-in-gnu-emacs | ||
| 48 | (defalias 'mh-require 'require)) | ||
| 49 | |||
| 50 | (mh-do-in-xemacs | ||
| 51 | (defun mh-require (feature &optional filename noerror) | ||
| 52 | "If feature FEATURE is not loaded, load it from FILENAME. | ||
| 53 | If FEATURE is not a member of the list `features', then the feature | ||
| 54 | is not loaded; so load the file FILENAME. | ||
| 55 | If FILENAME is omitted, the printname of FEATURE is used as the file name. | ||
| 56 | If the optional third argument NOERROR is non-nil, | ||
| 57 | then return nil if the file is not found instead of signaling an error. | ||
| 58 | |||
| 59 | Simulate NOERROR argument in XEmacs which lacks it." | ||
| 60 | (if (not (featurep feature)) | ||
| 61 | (if filename | ||
| 62 | (load filename noerror t) | ||
| 63 | (load (format "%s" feature) noerror t))))) | ||
| 43 | 64 | ||
| 44 | (mh-defun-compat mh-assoc-string assoc-string (key list case-fold) | 65 | (mh-defun-compat mh-assoc-string assoc-string (key list case-fold) |
| 45 | "Like `assoc' but specifically for strings. | 66 | "Like `assoc' but specifically for strings. |
| 46 | Case is ignored if CASE-FOLD is non-nil. | 67 | Case is ignored if CASE-FOLD is non-nil. |
| 47 | This function added by MH-E for Emacs versions that lack | 68 | This function is used by Emacs versions that lack `assoc-string', |
| 48 | `assoc-string', introduced in Emacs 22." | 69 | introduced in Emacs 22." |
| 49 | (if case-fold | 70 | (if case-fold |
| 50 | (assoc-ignore-case key list) | 71 | (assoc-ignore-case key list) |
| 51 | (assoc key list))) | 72 | (assoc key list))) |
| 52 | 73 | ||
| 53 | (require 'mailabbrev nil t) | 74 | ;; For XEmacs. |
| 54 | (mh-defun-compat mh-mail-abbrev-make-syntax-table | 75 | (defalias 'mh-cancel-timer |
| 55 | mail-abbrev-make-syntax-table () | 76 | (if (fboundp 'cancel-timer) |
| 56 | "Emacs 21 and XEmacs don't have this function." | 77 | 'cancel-timer |
| 57 | nil) | 78 | 'delete-itimer)) |
| 79 | |||
| 80 | (mh-defun-compat mh-display-color-cells display-color-cells (&optional display) | ||
| 81 | "Return the number of color cells supported by DISPLAY. | ||
| 82 | This function is used by XEmacs to always return 0 when compiling | ||
| 83 | to avoid compiling errors. Otherwise uses `device-color-cells'." | ||
| 84 | (if mh-compiling-flag | ||
| 85 | 0 | ||
| 86 | (device-color-cells display))) | ||
| 58 | 87 | ||
| 59 | (defmacro mh-display-completion-list (completions &optional common-substring) | 88 | (defmacro mh-display-completion-list (completions &optional common-substring) |
| 60 | "Display the list of COMPLETIONS. | 89 | "Display the list of COMPLETIONS. |
| 61 | See documentation for `display-completion-list' for a description of the | 90 | See documentation for `display-completion-list' for a description of the |
| 62 | arguments COMPLETIONS and perhaps COMMON-SUBSTRING. | 91 | arguments COMPLETIONS and perhaps COMMON-SUBSTRING. |
| 63 | This macro added by MH-E for Emacs versions that lack a | 92 | This macro is used by Emacs versions that lack a COMMON-SUBSTRING |
| 64 | COMMON-SUBSTRING argument, introduced in Emacs 22." | 93 | argument, introduced in Emacs 22." |
| 65 | (if (< emacs-major-version 22) | 94 | (if (< emacs-major-version 22) |
| 66 | `(display-completion-list ,completions) | 95 | `(display-completion-list ,completions) |
| 67 | `(display-completion-list ,completions ,common-substring))) | 96 | `(display-completion-list ,completions ,common-substring))) |
| @@ -70,8 +99,8 @@ COMMON-SUBSTRING argument, introduced in Emacs 22." | |||
| 70 | "Return the foreground color name of FACE, or nil if unspecified. | 99 | "Return the foreground color name of FACE, or nil if unspecified. |
| 71 | See documentation for `face-foreground' for a description of the | 100 | See documentation for `face-foreground' for a description of the |
| 72 | arguments FACE, FRAME, and perhaps INHERIT. | 101 | arguments FACE, FRAME, and perhaps INHERIT. |
| 73 | This macro added by MH-E for Emacs versions that lack an INHERIT | 102 | This macro is used by Emacs versions that lack an INHERIT argument, |
| 74 | argument, introduced in Emacs 22." | 103 | introduced in Emacs 22." |
| 75 | (if (< emacs-major-version 22) | 104 | (if (< emacs-major-version 22) |
| 76 | `(face-foreground ,face ,frame) | 105 | `(face-foreground ,face ,frame) |
| 77 | `(face-foreground ,face ,frame ,inherit))) | 106 | `(face-foreground ,face ,frame ,inherit))) |
| @@ -80,15 +109,51 @@ argument, introduced in Emacs 22." | |||
| 80 | "Return the background color name of face, or nil if unspecified. | 109 | "Return the background color name of face, or nil if unspecified. |
| 81 | See documentation for `back-foreground' for a description of the | 110 | See documentation for `back-foreground' for a description of the |
| 82 | arguments FACE, FRAME, and INHERIT. | 111 | arguments FACE, FRAME, and INHERIT. |
| 83 | This macro added by MH-E for Emacs versions that lack an INHERIT | 112 | This macro is used by Emacs versions that lack an INHERIT argument, |
| 84 | argument, introduced in Emacs 22." | 113 | introduced in Emacs 22." |
| 85 | (if (< emacs-major-version 22) | 114 | (if (< emacs-major-version 22) |
| 86 | `(face-background ,face ,frame) | 115 | `(face-background ,face ,frame) |
| 87 | `(face-background ,face ,frame ,inherit))) | 116 | `(face-background ,face ,frame ,inherit))) |
| 88 | 117 | ||
| 118 | ;; For XEmacs. | ||
| 119 | (defalias 'mh-line-beginning-position | ||
| 120 | (if (fboundp 'line-beginning-position) | ||
| 121 | 'line-beginning-position | ||
| 122 | 'point-at-bol)) | ||
| 123 | |||
| 124 | ;; For XEmacs. | ||
| 125 | (defalias 'mh-line-end-position | ||
| 126 | (if (fboundp 'line-end-position) | ||
| 127 | 'line-end-position | ||
| 128 | 'point-at-eol)) | ||
| 129 | |||
| 130 | (mh-require 'mailabbrev nil t) | ||
| 131 | (mh-defun-compat mh-mail-abbrev-make-syntax-table | ||
| 132 | mail-abbrev-make-syntax-table () | ||
| 133 | "Emacs 21 and XEmacs don't have `mail-abbrev-make-syntax-table'. | ||
| 134 | This function does nothing on those systems." | ||
| 135 | nil) | ||
| 136 | |||
| 137 | (mh-defun-compat mh-match-string-no-properties | ||
| 138 | match-string-no-properties (num &optional string) | ||
| 139 | "Return string of text matched by last search, without text properties. | ||
| 140 | This function is used by XEmacs that lacks `match-string-no-properties'. | ||
| 141 | The function `buffer-substring-no-properties' is used instead. | ||
| 142 | The argument STRING is ignored." | ||
| 143 | (buffer-substring-no-properties | ||
| 144 | (match-beginning num) (match-end num))) | ||
| 145 | |||
| 146 | (mh-defun-compat mh-replace-regexp-in-string replace-regexp-in-string | ||
| 147 | (rep string &optional fixedcase literal subexp start) | ||
| 148 | "Replace REGEXP with REP everywhere in STRING and return result. | ||
| 149 | This function is used by XEmacs that lacks `replace-regexp-in-string'. | ||
| 150 | The function `replace-in-string' is used instead. | ||
| 151 | The arguments FIXEDCASE, LITERAL, SUBEXP, and START are ignored." | ||
| 152 | (replace-in-string string regexp rep)) | ||
| 153 | |||
| 89 | ;; Copy of constant from url-util.el in Emacs 22; needed by Emacs 21. | 154 | ;; Copy of constant from url-util.el in Emacs 22; needed by Emacs 21. |
| 90 | (if (not (boundp 'url-unreserved-chars)) | 155 | (if (not (boundp 'url-unreserved-chars)) |
| 91 | (defconst mh-url-unresrved-chars | 156 | (defconst mh-url-unreserved-chars |
| 92 | '( | 157 | '( |
| 93 | ?a ?b ?c ?d ?e ?f ?g ?h ?i ?j ?k ?l ?m ?n ?o ?p ?q ?r ?s ?t ?u ?v ?w ?x ?y ?z | 158 | ?a ?b ?c ?d ?e ?f ?g ?h ?i ?j ?k ?l ?m ?n ?o ?p ?q ?r ?s ?t ?u ?v ?w ?x ?y ?z |
| 94 | ?A ?B ?C ?D ?E ?F ?G ?H ?I ?J ?K ?L ?M ?N ?O ?P ?Q ?R ?S ?T ?U ?V ?W ?X ?Y ?Z | 159 | ?A ?B ?C ?D ?E ?F ?G ?H ?I ?J ?K ?L ?M ?N ?O ?P ?Q ?R ?S ?T ?U ?V ?W ?X ?Y ?Z |
| @@ -111,6 +176,17 @@ This is a copy of `url-hexify-string' from url-util.el in Emacs | |||
| 111 | (char-to-string char))) | 176 | (char-to-string char))) |
| 112 | str "")) | 177 | str "")) |
| 113 | 178 | ||
| 179 | (mh-defun-compat mh-view-mode-enter | ||
| 180 | view-mode-enter (&optional return-to exit-action) | ||
| 181 | "Enter View mode. | ||
| 182 | This function is used by XEmacs that lacks `view-mode-enter'. | ||
| 183 | The function `view-mode' is used instead. | ||
| 184 | The arguments RETURN-TO and EXIT-ACTION are ignored." | ||
| 185 | ;; Shush compiler. | ||
| 186 | (if return-to nil) | ||
| 187 | (if exit-action nil) | ||
| 188 | (view-mode 1)) | ||
| 189 | |||
| 114 | (defmacro mh-write-file-functions () | 190 | (defmacro mh-write-file-functions () |
| 115 | "Return `write-file-functions' if it exists. | 191 | "Return `write-file-functions' if it exists. |
| 116 | Otherwise return `local-write-file-hooks'. | 192 | Otherwise return `local-write-file-hooks'. |
diff --git a/lisp/mh-e/mh-e.el b/lisp/mh-e/mh-e.el index 5b738933590..9be827a8071 100644 --- a/lisp/mh-e/mh-e.el +++ b/lisp/mh-e/mh-e.el | |||
| @@ -6,7 +6,7 @@ | |||
| 6 | 6 | ||
| 7 | ;; Author: Bill Wohler <wohler@newt.com> | 7 | ;; Author: Bill Wohler <wohler@newt.com> |
| 8 | ;; Maintainer: Bill Wohler <wohler@newt.com> | 8 | ;; Maintainer: Bill Wohler <wohler@newt.com> |
| 9 | ;; Version: 7.85+cvs | 9 | ;; Version: 7.91+cvs |
| 10 | ;; Keywords: mail | 10 | ;; Keywords: mail |
| 11 | 11 | ||
| 12 | ;; This file is part of GNU Emacs. | 12 | ;; This file is part of GNU Emacs. |
| @@ -101,7 +101,13 @@ | |||
| 101 | 101 | ||
| 102 | (eval-and-compile | 102 | (eval-and-compile |
| 103 | (defvar mh-xemacs-flag (featurep 'xemacs) | 103 | (defvar mh-xemacs-flag (featurep 'xemacs) |
| 104 | "Non-nil means the current Emacs is XEmacs.")) | 104 | "Non-nil means the current Emacs is XEmacs.") |
| 105 | (defvar mh-compiling-flag nil | ||
| 106 | "Non-nil means we're compiling.")) | ||
| 107 | |||
| 108 | (eval-when (compile) | ||
| 109 | (setq mh-compiling-flag t)) | ||
| 110 | |||
| 105 | (mh-do-in-xemacs | 111 | (mh-do-in-xemacs |
| 106 | (require 'mh-xemacs)) | 112 | (require 'mh-xemacs)) |
| 107 | 113 | ||
| @@ -115,7 +121,7 @@ | |||
| 115 | ;; Try to keep variables local to a single file. Provide accessors if | 121 | ;; Try to keep variables local to a single file. Provide accessors if |
| 116 | ;; variables are shared. Use this section as a last resort. | 122 | ;; variables are shared. Use this section as a last resort. |
| 117 | 123 | ||
| 118 | (defconst mh-version "7.85+sans-entropy" "Version number of MH-E.") | 124 | (defconst mh-version "7.91+cvs" "Version number of MH-E.") |
| 119 | 125 | ||
| 120 | ;; Variants | 126 | ;; Variants |
| 121 | 127 | ||
| @@ -464,7 +470,8 @@ all the strings have been used." | |||
| 464 | (let ((arg-list (reverse args)) | 470 | (let ((arg-list (reverse args)) |
| 465 | (count 0)) | 471 | (count 0)) |
| 466 | (while (and (not (eobp)) (< count mh-index-max-cmdline-args)) | 472 | (while (and (not (eobp)) (< count mh-index-max-cmdline-args)) |
| 467 | (push (buffer-substring-no-properties (point) (line-end-position)) | 473 | (push (buffer-substring-no-properties (point) |
| 474 | (mh-line-end-position)) | ||
| 468 | arg-list) | 475 | arg-list) |
| 469 | (incf count) | 476 | (incf count) |
| 470 | (forward-line)) | 477 | (forward-line)) |
| @@ -2970,7 +2977,7 @@ entirely if the display does not support the number of specified | |||
| 2970 | colors." | 2977 | colors." |
| 2971 | (if mh-min-colors-defined-flag | 2978 | (if mh-min-colors-defined-flag |
| 2972 | spec | 2979 | spec |
| 2973 | (let ((cells (display-color-cells)) | 2980 | (let ((cells (mh-display-color-cells)) |
| 2974 | new-spec) | 2981 | new-spec) |
| 2975 | ;; Remove entries with min-colors, or delete them if we have fewer colors | 2982 | ;; Remove entries with min-colors, or delete them if we have fewer colors |
| 2976 | ;; than they specify. | 2983 | ;; than they specify. |
| @@ -3030,9 +3037,9 @@ colors." | |||
| 3030 | 3037 | ||
| 3031 | (defface mh-folder-msg-number | 3038 | (defface mh-folder-msg-number |
| 3032 | (mh-defface-compat | 3039 | (mh-defface-compat |
| 3033 | '((((class color) (min-colors 88) (background light)) | 3040 | '((((class color) (min-colors 64) (background light)) |
| 3034 | (:foreground "snow4")) | 3041 | (:foreground "snow4")) |
| 3035 | (((class color) (min-colors 88) (background dark)) | 3042 | (((class color) (min-colors 64) (background dark)) |
| 3036 | (:foreground "snow3")) | 3043 | (:foreground "snow3")) |
| 3037 | (((class color)) | 3044 | (((class color)) |
| 3038 | (:foreground "cyan")))) | 3045 | (:foreground "cyan")))) |
| @@ -3043,9 +3050,9 @@ colors." | |||
| 3043 | 3050 | ||
| 3044 | (defface mh-folder-refiled | 3051 | (defface mh-folder-refiled |
| 3045 | (mh-defface-compat | 3052 | (mh-defface-compat |
| 3046 | '((((class color) (min-colors 88) (background light)) | 3053 | '((((class color) (min-colors 64) (background light)) |
| 3047 | (:foreground "DarkGoldenrod")) | 3054 | (:foreground "DarkGoldenrod")) |
| 3048 | (((class color) (min-colors 88) (background dark)) | 3055 | (((class color) (min-colors 64) (background dark)) |
| 3049 | (:foreground "LightGoldenrod")) | 3056 | (:foreground "LightGoldenrod")) |
| 3050 | (((class color)) | 3057 | (((class color)) |
| 3051 | (:foreground "yellow" :weight light)) | 3058 | (:foreground "yellow" :weight light)) |
| @@ -3099,9 +3106,9 @@ format `mh-scan-format-nmh' and the regular expression | |||
| 3099 | 3106 | ||
| 3100 | (defface mh-folder-to | 3107 | (defface mh-folder-to |
| 3101 | (mh-defface-compat | 3108 | (mh-defface-compat |
| 3102 | '((((class color) (min-colors 88) (background light)) | 3109 | '((((class color) (min-colors 64) (background light)) |
| 3103 | (:foreground "RosyBrown")) | 3110 | (:foreground "RosyBrown")) |
| 3104 | (((class color) (min-colors 88) (background dark)) | 3111 | (((class color) (min-colors 64) (background dark)) |
| 3105 | (:foreground "LightSalmon")) | 3112 | (:foreground "LightSalmon")) |
| 3106 | (((class color)) | 3113 | (((class color)) |
| 3107 | (:foreground "green")) | 3114 | (:foreground "green")) |
| @@ -3139,9 +3146,9 @@ format `mh-scan-format-nmh' and the regular expression | |||
| 3139 | 3146 | ||
| 3140 | (defface mh-show-cc | 3147 | (defface mh-show-cc |
| 3141 | (mh-defface-compat | 3148 | (mh-defface-compat |
| 3142 | '((((class color) (min-colors 88) (background light)) | 3149 | '((((class color) (min-colors 64) (background light)) |
| 3143 | (:foreground "DarkGoldenrod")) | 3150 | (:foreground "DarkGoldenrod")) |
| 3144 | (((class color) (min-colors 88) (background dark)) | 3151 | (((class color) (min-colors 64) (background dark)) |
| 3145 | (:foreground "LightGoldenrod")) | 3152 | (:foreground "LightGoldenrod")) |
| 3146 | (((class color)) | 3153 | (((class color)) |
| 3147 | (:foreground "yellow" :weight light)) | 3154 | (:foreground "yellow" :weight light)) |
| @@ -3157,9 +3164,9 @@ format `mh-scan-format-nmh' and the regular expression | |||
| 3157 | 3164 | ||
| 3158 | (defface mh-show-date | 3165 | (defface mh-show-date |
| 3159 | (mh-defface-compat | 3166 | (mh-defface-compat |
| 3160 | '((((class color) (min-colors 88) (background light)) | 3167 | '((((class color) (min-colors 64) (background light)) |
| 3161 | (:foreground "ForestGreen")) | 3168 | (:foreground "ForestGreen")) |
| 3162 | (((class color) (min-colors 88) (background dark)) | 3169 | (((class color) (min-colors 64) (background dark)) |
| 3163 | (:foreground "PaleGreen")) | 3170 | (:foreground "PaleGreen")) |
| 3164 | (((class color)) | 3171 | (((class color)) |
| 3165 | (:foreground "green")) | 3172 | (:foreground "green")) |
| @@ -3186,9 +3193,9 @@ format `mh-scan-format-nmh' and the regular expression | |||
| 3186 | 3193 | ||
| 3187 | (defface mh-show-header | 3194 | (defface mh-show-header |
| 3188 | (mh-defface-compat | 3195 | (mh-defface-compat |
| 3189 | '((((class color) (min-colors 88) (background light)) | 3196 | '((((class color) (min-colors 64) (background light)) |
| 3190 | (:foreground "RosyBrown")) | 3197 | (:foreground "RosyBrown")) |
| 3191 | (((class color) (min-colors 88) (background dark)) | 3198 | (((class color) (min-colors 64) (background dark)) |
| 3192 | (:foreground "LightSalmon")) | 3199 | (:foreground "LightSalmon")) |
| 3193 | (((class color)) | 3200 | (((class color)) |
| 3194 | (:foreground "green")) | 3201 | (:foreground "green")) |
diff --git a/lisp/mh-e/mh-folder.el b/lisp/mh-e/mh-folder.el index 5339363df19..59526986d35 100644 --- a/lisp/mh-e/mh-folder.el +++ b/lisp/mh-e/mh-folder.el | |||
| @@ -516,7 +516,7 @@ font-lock is done highlighting.") | |||
| 516 | (cons (current-buffer) nil))))) | 516 | (cons (current-buffer) nil))))) |
| 517 | 517 | ||
| 518 | ;; Register mh-folder-mode as supporting which-function-mode... | 518 | ;; Register mh-folder-mode as supporting which-function-mode... |
| 519 | (require 'which-func nil t) | 519 | (mh-require 'which-func nil t) |
| 520 | (when (boundp 'which-func-modes) | 520 | (when (boundp 'which-func-modes) |
| 521 | (add-to-list 'which-func-modes 'mh-folder-mode)) | 521 | (add-to-list 'which-func-modes 'mh-folder-mode)) |
| 522 | 522 | ||
diff --git a/lisp/mh-e/mh-funcs.el b/lisp/mh-e/mh-funcs.el index 0565ed42e6b..f7abb4cb389 100644 --- a/lisp/mh-e/mh-funcs.el +++ b/lisp/mh-e/mh-funcs.el | |||
| @@ -154,7 +154,7 @@ Display the results only if something went wrong." | |||
| 154 | "-recurse" | 154 | "-recurse" |
| 155 | "-norecurse")) | 155 | "-norecurse")) |
| 156 | (goto-char (point-min)) | 156 | (goto-char (point-min)) |
| 157 | (view-mode-enter) | 157 | (mh-view-mode-enter) |
| 158 | (setq view-exit-action 'kill-buffer) | 158 | (setq view-exit-action 'kill-buffer) |
| 159 | (message "Listing folders...done"))))) | 159 | (message "Listing folders...done"))))) |
| 160 | 160 | ||
diff --git a/lisp/mh-e/mh-gnus.el b/lisp/mh-e/mh-gnus.el index 8944db89f70..970f98556e2 100644 --- a/lisp/mh-e/mh-gnus.el +++ b/lisp/mh-e/mh-gnus.el | |||
| @@ -32,11 +32,11 @@ | |||
| 32 | 32 | ||
| 33 | (require 'mh-e) | 33 | (require 'mh-e) |
| 34 | 34 | ||
| 35 | (require 'gnus-util nil t) | 35 | (mh-require 'gnus-util nil t) |
| 36 | (require 'mm-bodies nil t) | 36 | (mh-require 'mm-bodies nil t) |
| 37 | (require 'mm-decode nil t) | 37 | (mh-require 'mm-decode nil t) |
| 38 | (require 'mm-view nil t) | 38 | (mh-require 'mm-view nil t) |
| 39 | (require 'mml nil t) | 39 | (mh-require 'mml nil t) |
| 40 | 40 | ||
| 41 | ;; Copy of function from gnus-util.el. | 41 | ;; Copy of function from gnus-util.el. |
| 42 | (mh-defun-compat mh-gnus-local-map-property gnus-local-map-property (map) | 42 | (mh-defun-compat mh-gnus-local-map-property gnus-local-map-property (map) |
diff --git a/lisp/mh-e/mh-letter.el b/lisp/mh-e/mh-letter.el index a5a7af24e91..c6af5c323a9 100644 --- a/lisp/mh-e/mh-letter.el +++ b/lisp/mh-e/mh-letter.el | |||
| @@ -267,7 +267,7 @@ searching for `mh-mail-header-separator' in the buffer." | |||
| 267 | (goto-char (point-min)) | 267 | (goto-char (point-min)) |
| 268 | (cond ((equal mh-mail-header-separator "") (point-min)) | 268 | (cond ((equal mh-mail-header-separator "") (point-min)) |
| 269 | ((search-forward (format "\n%s\n" mh-mail-header-separator) nil t) | 269 | ((search-forward (format "\n%s\n" mh-mail-header-separator) nil t) |
| 270 | (line-beginning-position 0)) | 270 | (mh-line-beginning-position 0)) |
| 271 | (t (point-min))))) | 271 | (t (point-min))))) |
| 272 | 272 | ||
| 273 | 273 | ||
| @@ -319,7 +319,7 @@ order). | |||
| 319 | (set (make-local-variable 'mh-mail-header-separator) | 319 | (set (make-local-variable 'mh-mail-header-separator) |
| 320 | (save-excursion | 320 | (save-excursion |
| 321 | (goto-char (mh-mail-header-end)) | 321 | (goto-char (mh-mail-header-end)) |
| 322 | (buffer-substring-no-properties (point) (line-end-position)))) | 322 | (buffer-substring-no-properties (point) (mh-line-end-position)))) |
| 323 | (make-local-variable 'mail-header-separator) | 323 | (make-local-variable 'mail-header-separator) |
| 324 | (setq mail-header-separator mh-mail-header-separator) ;override sendmail.el | 324 | (setq mail-header-separator mh-mail-header-separator) ;override sendmail.el |
| 325 | (mh-set-help mh-letter-mode-help-messages) | 325 | (mh-set-help mh-letter-mode-help-messages) |
| @@ -828,7 +828,7 @@ body." | |||
| 828 | ((< (point) (progn | 828 | ((< (point) (progn |
| 829 | (beginning-of-line) | 829 | (beginning-of-line) |
| 830 | (re-search-forward mh-letter-header-field-regexp | 830 | (re-search-forward mh-letter-header-field-regexp |
| 831 | (line-end-position) t) | 831 | (mh-line-end-position) t) |
| 832 | (point))) | 832 | (point))) |
| 833 | (beginning-of-line)) | 833 | (beginning-of-line)) |
| 834 | (t (end-of-line))) | 834 | (t (end-of-line))) |
diff --git a/lisp/mh-e/mh-limit.el b/lisp/mh-e/mh-limit.el index 68ec25a9470..7a90b890cad 100644 --- a/lisp/mh-e/mh-limit.el +++ b/lisp/mh-e/mh-limit.el | |||
| @@ -211,7 +211,7 @@ Return number of messages put in the sequence: | |||
| 211 | (string-equal "" (match-string 3))) | 211 | (string-equal "" (match-string 3))) |
| 212 | (progn (message "No subject line") | 212 | (progn (message "No subject line") |
| 213 | nil) | 213 | nil) |
| 214 | (let ((subject (match-string-no-properties 3)) | 214 | (let ((subject (mh-match-string-no-properties 3)) |
| 215 | (list)) | 215 | (list)) |
| 216 | (if (> (length subject) mh-limit-max-subject-size) | 216 | (if (> (length subject) mh-limit-max-subject-size) |
| 217 | (setq subject (substring subject 0 mh-limit-max-subject-size))) | 217 | (setq subject (substring subject 0 mh-limit-max-subject-size))) |
| @@ -219,7 +219,7 @@ Return number of messages put in the sequence: | |||
| 219 | (if all | 219 | (if all |
| 220 | (goto-char (point-min))) | 220 | (goto-char (point-min))) |
| 221 | (while (re-search-forward mh-scan-subject-regexp nil t) | 221 | (while (re-search-forward mh-scan-subject-regexp nil t) |
| 222 | (let ((this-subject (match-string-no-properties 3))) | 222 | (let ((this-subject (mh-match-string-no-properties 3))) |
| 223 | (if (> (length this-subject) mh-limit-max-subject-size) | 223 | (if (> (length this-subject) mh-limit-max-subject-size) |
| 224 | (setq this-subject (substring this-subject | 224 | (setq this-subject (substring this-subject |
| 225 | 0 mh-limit-max-subject-size))) | 225 | 0 mh-limit-max-subject-size))) |
| @@ -310,7 +310,7 @@ The MH command pick is used to do the match." | |||
| 310 | (while (not (eobp)) | 310 | (while (not (eobp)) |
| 311 | (let ((num (ignore-errors | 311 | (let ((num (ignore-errors |
| 312 | (string-to-number | 312 | (string-to-number |
| 313 | (buffer-substring (point) (line-end-position)))))) | 313 | (buffer-substring (point) (mh-line-end-position)))))) |
| 314 | (when num (push num msg-list)) | 314 | (when num (push num msg-list)) |
| 315 | (forward-line)))) | 315 | (forward-line)))) |
| 316 | (if (null msg-list) | 316 | (if (null msg-list) |
diff --git a/lisp/mh-e/mh-mime.el b/lisp/mh-e/mh-mime.el index 776f0c067a8..787f5c371fe 100644 --- a/lisp/mh-e/mh-mime.el +++ b/lisp/mh-e/mh-mime.el | |||
| @@ -302,14 +302,14 @@ the attachment labeled with that number." | |||
| 302 | start end) | 302 | start end) |
| 303 | (cond ((and data (not inserted-flag) (not displayed-flag)) | 303 | (cond ((and data (not inserted-flag) (not displayed-flag)) |
| 304 | (let ((contents (mm-get-part data))) | 304 | (let ((contents (mm-get-part data))) |
| 305 | (add-text-properties (line-beginning-position) (line-end-position) | 305 | (add-text-properties (mh-line-beginning-position) |
| 306 | '(mh-mime-inserted t)) | 306 | (mh-line-end-position) '(mh-mime-inserted t)) |
| 307 | (setq start (point-marker)) | 307 | (setq start (point-marker)) |
| 308 | (forward-line 1) | 308 | (forward-line 1) |
| 309 | (mm-insert-inline data contents) | 309 | (mm-insert-inline data contents) |
| 310 | (setq end (point-marker)) | 310 | (setq end (point-marker)) |
| 311 | (add-text-properties | 311 | (add-text-properties |
| 312 | start (progn (goto-char start) (line-end-position)) | 312 | start (progn (goto-char start) (mh-line-end-position)) |
| 313 | `(mh-region (,start . ,end))))) | 313 | `(mh-region (,start . ,end))))) |
| 314 | ((and data (or inserted-flag displayed-flag)) | 314 | ((and data (or inserted-flag displayed-flag)) |
| 315 | (mh-press-button) | 315 | (mh-press-button) |
| @@ -746,7 +746,8 @@ buttons for alternative parts that are usually suppressed." | |||
| 746 | (mh-insert-mime-button handle id (mm-handle-displayed-p handle)) | 746 | (mh-insert-mime-button handle id (mm-handle-displayed-p handle)) |
| 747 | (goto-char point) | 747 | (goto-char point) |
| 748 | (when region | 748 | (when region |
| 749 | (add-text-properties (line-beginning-position) (line-end-position) | 749 | (add-text-properties (mh-line-beginning-position) |
| 750 | (mh-line-end-position) | ||
| 750 | `(mh-region ,region))))))) | 751 | `(mh-region ,region))))))) |
| 751 | 752 | ||
| 752 | (defun mh-mime-part-index (handle) | 753 | (defun mh-mime-part-index (handle) |
| @@ -1500,9 +1501,9 @@ This function will quote all such characters." | |||
| 1500 | (goto-char (point-min)) | 1501 | (goto-char (point-min)) |
| 1501 | (while (re-search-forward "^#" nil t) | 1502 | (while (re-search-forward "^#" nil t) |
| 1502 | (beginning-of-line) | 1503 | (beginning-of-line) |
| 1503 | (unless (mh-mh-directive-present-p (point) (line-end-position)) | 1504 | (unless (mh-mh-directive-present-p (point) (mh-line-end-position)) |
| 1504 | (insert "#")) | 1505 | (insert "#")) |
| 1505 | (goto-char (line-end-position))))) | 1506 | (goto-char (mh-line-end-position))))) |
| 1506 | 1507 | ||
| 1507 | ;;;###mh-autoload | 1508 | ;;;###mh-autoload |
| 1508 | (defun mh-mh-to-mime-undo (noconfirm) | 1509 | (defun mh-mh-to-mime-undo (noconfirm) |
| @@ -1672,7 +1673,8 @@ buffer, while END defaults to the the end of the buffer." | |||
| 1672 | (block 'search-for-mh-directive | 1673 | (block 'search-for-mh-directive |
| 1673 | (goto-char begin) | 1674 | (goto-char begin) |
| 1674 | (while (re-search-forward "^#" end t) | 1675 | (while (re-search-forward "^#" end t) |
| 1675 | (let ((s (buffer-substring-no-properties (point) (line-end-position)))) | 1676 | (let ((s (buffer-substring-no-properties |
| 1677 | (point) (mh-line-end-position)))) | ||
| 1676 | (cond ((equal s "")) | 1678 | (cond ((equal s "")) |
| 1677 | ((string-match "^forw[ \t\n]+" s) | 1679 | ((string-match "^forw[ \t\n]+" s) |
| 1678 | (return-from 'search-for-mh-directive t)) | 1680 | (return-from 'search-for-mh-directive t)) |
diff --git a/lisp/mh-e/mh-search.el b/lisp/mh-e/mh-search.el index 9fc9355a065..f1292dd8e1e 100644 --- a/lisp/mh-e/mh-search.el +++ b/lisp/mh-e/mh-search.el | |||
| @@ -51,7 +51,6 @@ | |||
| 51 | 51 | ||
| 52 | (require 'gnus-util) | 52 | (require 'gnus-util) |
| 53 | (require 'imenu) | 53 | (require 'imenu) |
| 54 | (require 'which-func nil t) | ||
| 55 | 54 | ||
| 56 | (defvar mh-searcher nil | 55 | (defvar mh-searcher nil |
| 57 | "Cached value of chosen search program.") | 56 | "Cached value of chosen search program.") |
| @@ -358,12 +357,13 @@ configuration and is used when the search folder is dismissed." | |||
| 358 | (goto-char (point-min)) | 357 | (goto-char (point-min)) |
| 359 | (dotimes (i 5) | 358 | (dotimes (i 5) |
| 360 | (add-text-properties (point) (1+ (point)) '(front-sticky t)) | 359 | (add-text-properties (point) (1+ (point)) '(front-sticky t)) |
| 361 | (add-text-properties (- (line-end-position) 2) (1- (line-end-position)) | 360 | (add-text-properties (- (mh-line-end-position) 2) |
| 361 | (1- (mh-line-end-position)) | ||
| 362 | '(rear-nonsticky t)) | 362 | '(rear-nonsticky t)) |
| 363 | (add-text-properties (point) (1- (line-end-position)) '(read-only t)) | 363 | (add-text-properties (point) (1- (mh-line-end-position)) '(read-only t)) |
| 364 | (forward-line)) | 364 | (forward-line)) |
| 365 | (add-text-properties (point) (1+ (point)) '(front-sticky t)) | 365 | (add-text-properties (point) (1+ (point)) '(front-sticky t)) |
| 366 | (add-text-properties (point) (1- (line-end-position)) '(read-only t)) | 366 | (add-text-properties (point) (1- (mh-line-end-position)) '(read-only t)) |
| 367 | (goto-char (point-max))) | 367 | (goto-char (point-max))) |
| 368 | 368 | ||
| 369 | ;; Sequence Searches | 369 | ;; Sequence Searches |
| @@ -526,9 +526,10 @@ group of results." | |||
| 526 | (cond ((and (bolp) (eolp)) | 526 | (cond ((and (bolp) (eolp)) |
| 527 | (ignore-errors (forward-line -1)) | 527 | (ignore-errors (forward-line -1)) |
| 528 | (setq msg (mh-get-msg-num t))) | 528 | (setq msg (mh-get-msg-num t))) |
| 529 | ((equal (char-after (line-beginning-position)) ?+) | 529 | ((equal (char-after (mh-line-beginning-position)) ?+) |
| 530 | (setq folder (buffer-substring-no-properties | 530 | (setq folder (buffer-substring-no-properties |
| 531 | (line-beginning-position) (line-end-position)))) | 531 | (mh-line-beginning-position) |
| 532 | (mh-line-end-position)))) | ||
| 532 | (t (setq msg (mh-get-msg-num t))))) | 533 | (t (setq msg (mh-get-msg-num t))))) |
| 533 | (when (not folder) | 534 | (when (not folder) |
| 534 | (setq folder (car (gethash (gethash msg mh-index-msg-checksum-map) | 535 | (setq folder (car (gethash (gethash msg mh-index-msg-checksum-map) |
| @@ -655,13 +656,13 @@ The cdr of the element is the pattern to search." | |||
| 655 | start begin) | 656 | start begin) |
| 656 | (goto-char (point-min)) | 657 | (goto-char (point-min)) |
| 657 | (while (not (eobp)) | 658 | (while (not (eobp)) |
| 658 | (if (search-forward "--------" (line-end-position) t) | 659 | (if (search-forward "--------" (mh-line-end-position) t) |
| 659 | (setq in-body-flag t) | 660 | (setq in-body-flag t) |
| 660 | (beginning-of-line) | 661 | (beginning-of-line) |
| 661 | (setq begin (point)) | 662 | (setq begin (point)) |
| 662 | (setq start (if in-body-flag | 663 | (setq start (if in-body-flag |
| 663 | (point) | 664 | (point) |
| 664 | (search-forward ":" (line-end-position) t) | 665 | (search-forward ":" (mh-line-end-position) t) |
| 665 | (point))) | 666 | (point))) |
| 666 | (push (cons (and (not in-body-flag) | 667 | (push (cons (and (not in-body-flag) |
| 667 | (intern (downcase | 668 | (intern (downcase |
| @@ -669,7 +670,7 @@ The cdr of the element is the pattern to search." | |||
| 669 | begin (1- start))))) | 670 | begin (1- start))))) |
| 670 | (mh-index-parse-search-regexp | 671 | (mh-index-parse-search-regexp |
| 671 | (buffer-substring-no-properties | 672 | (buffer-substring-no-properties |
| 672 | start (line-end-position)))) | 673 | start (mh-line-end-position)))) |
| 673 | pattern-list)) | 674 | pattern-list)) |
| 674 | (forward-line)) | 675 | (forward-line)) |
| 675 | pattern-list))) | 676 | pattern-list))) |
| @@ -979,8 +980,8 @@ is used to search." | |||
| 979 | (return nil)) | 980 | (return nil)) |
| 980 | (when (equal (char-after (point)) ?#) | 981 | (when (equal (char-after (point)) ?#) |
| 981 | (return 'error)) | 982 | (return 'error)) |
| 982 | (let* ((start (search-forward " " (line-end-position) t)) | 983 | (let* ((start (search-forward " " (mh-line-end-position) t)) |
| 983 | (end (search-forward " " (line-end-position) t))) | 984 | (end (search-forward " " (mh-line-end-position) t))) |
| 984 | (unless (and start end) | 985 | (unless (and start end) |
| 985 | (return 'error)) | 986 | (return 'error)) |
| 986 | (setq end (1- end)) | 987 | (setq end (1- end)) |
| @@ -1058,7 +1059,7 @@ SEARCH-REGEXP-LIST is used to search." | |||
| 1058 | (return 'error)) | 1059 | (return 'error)) |
| 1059 | (let ((start (point)) | 1060 | (let ((start (point)) |
| 1060 | end msg-start) | 1061 | end msg-start) |
| 1061 | (setq end (line-end-position)) | 1062 | (setq end (mh-line-end-position)) |
| 1062 | (unless (search-forward mh-mairix-folder end t) | 1063 | (unless (search-forward mh-mairix-folder end t) |
| 1063 | (return 'error)) | 1064 | (return 'error)) |
| 1064 | (goto-char (match-beginning 0)) | 1065 | (goto-char (match-beginning 0)) |
| @@ -1191,7 +1192,7 @@ is used to search." | |||
| 1191 | (block nil | 1192 | (block nil |
| 1192 | (when (eobp) (return nil)) | 1193 | (when (eobp) (return nil)) |
| 1193 | (let ((file-name (buffer-substring-no-properties | 1194 | (let ((file-name (buffer-substring-no-properties |
| 1194 | (point) (line-end-position)))) | 1195 | (point) (mh-line-end-position)))) |
| 1195 | (unless (equal (string-match mh-namazu-folder file-name) 0) | 1196 | (unless (equal (string-match mh-namazu-folder file-name) 0) |
| 1196 | (return 'error)) | 1197 | (return 'error)) |
| 1197 | (unless (file-exists-p file-name) | 1198 | (unless (file-exists-p file-name) |
| @@ -1239,17 +1240,17 @@ is used to search." | |||
| 1239 | (prog1 | 1240 | (prog1 |
| 1240 | (block nil | 1241 | (block nil |
| 1241 | (when (eobp) (return nil)) | 1242 | (when (eobp) (return nil)) |
| 1242 | (when (search-forward-regexp "^\+" (line-end-position) t) | 1243 | (when (search-forward-regexp "^\+" (mh-line-end-position) t) |
| 1243 | (setq mh-index-pick-folder | 1244 | (setq mh-index-pick-folder |
| 1244 | (buffer-substring-no-properties (line-beginning-position) | 1245 | (buffer-substring-no-properties (mh-line-beginning-position) |
| 1245 | (line-end-position))) | 1246 | (mh-line-end-position))) |
| 1246 | (return 'error)) | 1247 | (return 'error)) |
| 1247 | (unless (search-forward-regexp "^[1-9][0-9]*$" (line-end-position) t) | 1248 | (unless (search-forward-regexp "^[1-9][0-9]*$" (mh-line-end-position) t) |
| 1248 | (return 'error)) | 1249 | (return 'error)) |
| 1249 | (list mh-index-pick-folder | 1250 | (list mh-index-pick-folder |
| 1250 | (string-to-number | 1251 | (string-to-number |
| 1251 | (buffer-substring-no-properties (line-beginning-position) | 1252 | (buffer-substring-no-properties (mh-line-beginning-position) |
| 1252 | (line-end-position))) | 1253 | (mh-line-end-position))) |
| 1253 | nil)) | 1254 | nil)) |
| 1254 | (forward-line))) | 1255 | (forward-line))) |
| 1255 | 1256 | ||
| @@ -1326,8 +1327,8 @@ record is invalid return 'error." | |||
| 1326 | (block nil | 1327 | (block nil |
| 1327 | (when (eobp) | 1328 | (when (eobp) |
| 1328 | (return nil)) | 1329 | (return nil)) |
| 1329 | (let ((eol-pos (line-end-position)) | 1330 | (let ((eol-pos (mh-line-end-position)) |
| 1330 | (bol-pos (line-beginning-position)) | 1331 | (bol-pos (mh-line-beginning-position)) |
| 1331 | folder-start msg-end) | 1332 | folder-start msg-end) |
| 1332 | (goto-char bol-pos) | 1333 | (goto-char bol-pos) |
| 1333 | (unless (search-forward mh-user-path eol-pos t) | 1334 | (unless (search-forward mh-user-path eol-pos t) |
| @@ -1408,8 +1409,12 @@ being the list of messages originally from that folder." | |||
| 1408 | (when cur-msg (mh-goto-msg cur-msg t t)) | 1409 | (when cur-msg (mh-goto-msg cur-msg t t)) |
| 1409 | (set-buffer-modified-p old-buffer-modified-flag))) | 1410 | (set-buffer-modified-p old-buffer-modified-flag))) |
| 1410 | 1411 | ||
| 1412 | (mh-require 'which-func nil t) | ||
| 1413 | |||
| 1411 | ;; Shush compiler. | 1414 | ;; Shush compiler. |
| 1412 | (eval-when-compile (mh-do-in-xemacs (defvar which-func-mode))) | 1415 | (eval-when-compile |
| 1416 | (if (or mh-xemacs-flag (< emacs-major-version 22)) | ||
| 1417 | (defvar which-func-mode))) | ||
| 1413 | 1418 | ||
| 1414 | ;;;###mh-autoload | 1419 | ;;;###mh-autoload |
| 1415 | (defun mh-index-create-imenu-index () | 1420 | (defun mh-index-create-imenu-index () |
| @@ -1423,7 +1428,7 @@ being the list of messages originally from that folder." | |||
| 1423 | (save-excursion | 1428 | (save-excursion |
| 1424 | (beginning-of-line) | 1429 | (beginning-of-line) |
| 1425 | (push (cons (buffer-substring-no-properties | 1430 | (push (cons (buffer-substring-no-properties |
| 1426 | (point) (line-end-position)) | 1431 | (point) (mh-line-end-position)) |
| 1427 | (set-marker (make-marker) (point))) | 1432 | (set-marker (make-marker) (point))) |
| 1428 | alist))) | 1433 | alist))) |
| 1429 | (setq imenu--index-alist (nreverse alist))))) | 1434 | (setq imenu--index-alist (nreverse alist))))) |
| @@ -1696,7 +1701,8 @@ folder, is removed from `mh-index-data'." | |||
| 1696 | (mh-exec-cmd-output mh-scan-prog nil "-width" "80" | 1701 | (mh-exec-cmd-output mh-scan-prog nil "-width" "80" |
| 1697 | "-format" "%{x-mhe-checksum}\n" folder msg) | 1702 | "-format" "%{x-mhe-checksum}\n" folder msg) |
| 1698 | (goto-char (point-min)) | 1703 | (goto-char (point-min)) |
| 1699 | (string-equal (buffer-substring-no-properties (point) (line-end-position)) | 1704 | (string-equal (buffer-substring-no-properties |
| 1705 | (point) (mh-line-end-position)) | ||
| 1700 | checksum))) | 1706 | checksum))) |
| 1701 | 1707 | ||
| 1702 | 1708 | ||
| @@ -1805,8 +1811,8 @@ PROC is used to convert the value to actual data." | |||
| 1805 | 1811 | ||
| 1806 | (defun mh-md5sum-parser () | 1812 | (defun mh-md5sum-parser () |
| 1807 | "Parse md5sum output." | 1813 | "Parse md5sum output." |
| 1808 | (let ((begin (line-beginning-position)) | 1814 | (let ((begin (mh-line-beginning-position)) |
| 1809 | (end (line-end-position)) | 1815 | (end (mh-line-end-position)) |
| 1810 | first-space last-slash) | 1816 | first-space last-slash) |
| 1811 | (setq first-space (search-forward " " end t)) | 1817 | (setq first-space (search-forward " " end t)) |
| 1812 | (goto-char end) | 1818 | (goto-char end) |
| @@ -1819,8 +1825,8 @@ PROC is used to convert the value to actual data." | |||
| 1819 | 1825 | ||
| 1820 | (defun mh-openssl-parser () | 1826 | (defun mh-openssl-parser () |
| 1821 | "Parse openssl output." | 1827 | "Parse openssl output." |
| 1822 | (let ((begin (line-beginning-position)) | 1828 | (let ((begin (mh-line-beginning-position)) |
| 1823 | (end (line-end-position)) | 1829 | (end (mh-line-end-position)) |
| 1824 | last-space last-slash) | 1830 | last-space last-slash) |
| 1825 | (goto-char end) | 1831 | (goto-char end) |
| 1826 | (setq last-space (search-backward " " begin t)) | 1832 | (setq last-space (search-backward " " begin t)) |
| @@ -1854,7 +1860,7 @@ origin-index) map is updated too." | |||
| 1854 | (let (msg checksum) | 1860 | (let (msg checksum) |
| 1855 | (while (not (eobp)) | 1861 | (while (not (eobp)) |
| 1856 | (setq msg (buffer-substring-no-properties | 1862 | (setq msg (buffer-substring-no-properties |
| 1857 | (point) (line-end-position))) | 1863 | (point) (mh-line-end-position))) |
| 1858 | (forward-line) | 1864 | (forward-line) |
| 1859 | (save-excursion | 1865 | (save-excursion |
| 1860 | (cond ((not (string-match "^[0-9]*$" msg))) | 1866 | (cond ((not (string-match "^[0-9]*$" msg))) |
| @@ -1865,7 +1871,7 @@ origin-index) map is updated too." | |||
| 1865 | (t | 1871 | (t |
| 1866 | ;; update maps | 1872 | ;; update maps |
| 1867 | (setq checksum (buffer-substring-no-properties | 1873 | (setq checksum (buffer-substring-no-properties |
| 1868 | (point) (line-end-position))) | 1874 | (point) (mh-line-end-position))) |
| 1869 | (let ((msg (string-to-number msg))) | 1875 | (let ((msg (string-to-number msg))) |
| 1870 | (set-buffer folder) | 1876 | (set-buffer folder) |
| 1871 | (mh-index-update-single-msg msg checksum origin-map))))) | 1877 | (mh-index-update-single-msg msg checksum origin-map))))) |
diff --git a/lisp/mh-e/mh-seq.el b/lisp/mh-e/mh-seq.el index cf2027392bd..a5732d00bc6 100644 --- a/lisp/mh-e/mh-seq.el +++ b/lisp/mh-e/mh-seq.el | |||
| @@ -175,7 +175,7 @@ The list appears in a buffer named \"*MH-E Sequences*\"." | |||
| 175 | (insert "\n")) | 175 | (insert "\n")) |
| 176 | (setq seq-list (cdr seq-list))) | 176 | (setq seq-list (cdr seq-list))) |
| 177 | (goto-char (point-min)) | 177 | (goto-char (point-min)) |
| 178 | (view-mode-enter) | 178 | (mh-view-mode-enter) |
| 179 | (setq view-exit-action 'kill-buffer) | 179 | (setq view-exit-action 'kill-buffer) |
| 180 | (message "Listing sequences...done"))))) | 180 | (message "Listing sequences...done"))))) |
| 181 | 181 | ||
| @@ -749,7 +749,7 @@ completion is over." | |||
| 749 | (goto-char (point-min)) | 749 | (goto-char (point-min)) |
| 750 | (multiple-value-bind (folder unseen total) | 750 | (multiple-value-bind (folder unseen total) |
| 751 | (mh-parse-flist-output-line | 751 | (mh-parse-flist-output-line |
| 752 | (buffer-substring (point) (line-end-position))) | 752 | (buffer-substring (point) (mh-line-end-position))) |
| 753 | (values total unseen folder)))) | 753 | (values total unseen folder)))) |
| 754 | 754 | ||
| 755 | (defun mh-folder-size-folder (folder) | 755 | (defun mh-folder-size-folder (folder) |
| @@ -777,7 +777,7 @@ folders whose names end with a '+' character." | |||
| 777 | (when (search-backward " out of " (point-min) t) | 777 | (when (search-backward " out of " (point-min) t) |
| 778 | (setq total (string-to-number | 778 | (setq total (string-to-number |
| 779 | (buffer-substring-no-properties | 779 | (buffer-substring-no-properties |
| 780 | (match-end 0) (line-end-position)))) | 780 | (match-end 0) (mh-line-end-position)))) |
| 781 | (when (search-backward " in sequence " (point-min) t) | 781 | (when (search-backward " in sequence " (point-min) t) |
| 782 | (setq p (point)) | 782 | (setq p (point)) |
| 783 | (when (search-backward " has " (point-min) t) | 783 | (when (search-backward " has " (point-min) t) |
| @@ -955,7 +955,7 @@ font-lock is turned on." | |||
| 955 | ;; the case of user sequences. | 955 | ;; the case of user sequences. |
| 956 | (mh-notate nil nil mh-cmd-note) | 956 | (mh-notate nil nil mh-cmd-note) |
| 957 | (when font-lock-mode | 957 | (when font-lock-mode |
| 958 | (font-lock-fontify-region (point) (line-end-position)))) | 958 | (font-lock-fontify-region (point) (mh-line-end-position)))) |
| 959 | (forward-char (+ mh-cmd-note mh-scan-field-destination-offset)) | 959 | (forward-char (+ mh-cmd-note mh-scan-field-destination-offset)) |
| 960 | (let ((stack (gethash msg mh-sequence-notation-history))) | 960 | (let ((stack (gethash msg mh-sequence-notation-history))) |
| 961 | (setf (gethash msg mh-sequence-notation-history) | 961 | (setf (gethash msg mh-sequence-notation-history) |
diff --git a/lisp/mh-e/mh-show.el b/lisp/mh-e/mh-show.el index f8728edb3e4..ab636ae8ab6 100644 --- a/lisp/mh-e/mh-show.el +++ b/lisp/mh-e/mh-show.el | |||
| @@ -878,7 +878,7 @@ See also `mh-folder-mode'. | |||
| 878 | (defun mh-show-addr () | 878 | (defun mh-show-addr () |
| 879 | "Use `goto-address'." | 879 | "Use `goto-address'." |
| 880 | (when mh-show-use-goto-addr-flag | 880 | (when mh-show-use-goto-addr-flag |
| 881 | (require 'goto-addr nil t) | 881 | (mh-require 'goto-addr nil t) |
| 882 | (if (fboundp 'goto-address) | 882 | (if (fboundp 'goto-address) |
| 883 | (goto-address)))) | 883 | (goto-address)))) |
| 884 | 884 | ||
diff --git a/lisp/mh-e/mh-speed.el b/lisp/mh-e/mh-speed.el index 00cfd5ef961..ebf34abbd4c 100644 --- a/lisp/mh-e/mh-speed.el +++ b/lisp/mh-e/mh-speed.el | |||
| @@ -69,13 +69,13 @@ | |||
| 69 | ["Visit Folder" mh-speed-view | 69 | ["Visit Folder" mh-speed-view |
| 70 | (save-excursion | 70 | (save-excursion |
| 71 | (set-buffer speedbar-buffer) | 71 | (set-buffer speedbar-buffer) |
| 72 | (get-text-property (line-beginning-position) 'mh-folder))] | 72 | (get-text-property (mh-line-beginning-position) 'mh-folder))] |
| 73 | ["Expand Nested Folders" mh-speed-expand-folder | 73 | ["Expand Nested Folders" mh-speed-expand-folder |
| 74 | (and (get-text-property (line-beginning-position) 'mh-children-p) | 74 | (and (get-text-property (mh-line-beginning-position) 'mh-children-p) |
| 75 | (not (get-text-property (line-beginning-position) 'mh-expanded)))] | 75 | (not (get-text-property (mh-line-beginning-position) 'mh-expanded)))] |
| 76 | ["Contract Nested Folders" mh-speed-contract-folder | 76 | ["Contract Nested Folders" mh-speed-contract-folder |
| 77 | (and (get-text-property (line-beginning-position) 'mh-children-p) | 77 | (and (get-text-property (mh-line-beginning-position) 'mh-children-p) |
| 78 | (get-text-property (line-beginning-position) 'mh-expanded))] | 78 | (get-text-property (mh-line-beginning-position) 'mh-expanded))] |
| 79 | ["Refresh Speedbar" mh-speed-refresh t]) | 79 | ["Refresh Speedbar" mh-speed-refresh t]) |
| 80 | "Extra menu items for speedbar.") | 80 | "Extra menu items for speedbar.") |
| 81 | 81 | ||
| @@ -157,7 +157,7 @@ The optional ARGS from speedbar are ignored." | |||
| 157 | (forward-line -1) | 157 | (forward-line -1) |
| 158 | (speedbar-change-expand-button-char ?+) | 158 | (speedbar-change-expand-button-char ?+) |
| 159 | (add-text-properties | 159 | (add-text-properties |
| 160 | (line-beginning-position) (1+ (line-beginning-position)) | 160 | (mh-line-beginning-position) (1+ (line-beginning-position)) |
| 161 | '(mh-expanded nil))) | 161 | '(mh-expanded nil))) |
| 162 | (t | 162 | (t |
| 163 | (forward-line) | 163 | (forward-line) |
| @@ -165,7 +165,7 @@ The optional ARGS from speedbar are ignored." | |||
| 165 | (goto-char point) | 165 | (goto-char point) |
| 166 | (speedbar-change-expand-button-char ?-) | 166 | (speedbar-change-expand-button-char ?-) |
| 167 | (add-text-properties | 167 | (add-text-properties |
| 168 | (line-beginning-position) (1+ (line-beginning-position)) | 168 | (mh-line-beginning-position) (1+ (line-beginning-position)) |
| 169 | `(mh-expanded t))))))) | 169 | `(mh-expanded t))))))) |
| 170 | 170 | ||
| 171 | (defun mh-speed-view (&rest args) | 171 | (defun mh-speed-view (&rest args) |
| @@ -173,7 +173,7 @@ The optional ARGS from speedbar are ignored." | |||
| 173 | The optional ARGS from speedbar are ignored." | 173 | The optional ARGS from speedbar are ignored." |
| 174 | (interactive) | 174 | (interactive) |
| 175 | (declare (ignore args)) | 175 | (declare (ignore args)) |
| 176 | (let* ((folder (get-text-property (line-beginning-position) 'mh-folder)) | 176 | (let* ((folder (get-text-property (mh-line-beginning-position) 'mh-folder)) |
| 177 | (range (and (stringp folder) | 177 | (range (and (stringp folder) |
| 178 | (mh-read-range "Scan" folder t nil nil | 178 | (mh-read-range "Scan" folder t nil nil |
| 179 | mh-interpret-number-as-range-flag)))) | 179 | mh-interpret-number-as-range-flag)))) |
| @@ -199,9 +199,9 @@ created." | |||
| 199 | (forward-line -1) | 199 | (forward-line -1) |
| 200 | (setf (gethash nil mh-speed-folder-map) | 200 | (setf (gethash nil mh-speed-folder-map) |
| 201 | (set-marker (or (gethash nil mh-speed-folder-map) (make-marker)) | 201 | (set-marker (or (gethash nil mh-speed-folder-map) (make-marker)) |
| 202 | (1+ (line-beginning-position)))) | 202 | (1+ (mh-line-beginning-position)))) |
| 203 | (add-text-properties | 203 | (add-text-properties |
| 204 | (line-beginning-position) (1+ (line-beginning-position)) | 204 | (mh-line-beginning-position) (1+ (line-beginning-position)) |
| 205 | `(mh-folder nil mh-expanded nil mh-children-p t mh-level 0)) | 205 | `(mh-folder nil mh-expanded nil mh-children-p t mh-level 0)) |
| 206 | (mh-speed-stealth-update t) | 206 | (mh-speed-stealth-update t) |
| 207 | (when (> mh-speed-update-interval 0) | 207 | (when (> mh-speed-update-interval 0) |
| @@ -268,12 +268,12 @@ The update is always carried out if FORCE is non-nil." | |||
| 268 | (speedbar-with-writable | 268 | (speedbar-with-writable |
| 269 | (goto-char (gethash folder mh-speed-folder-map (point))) | 269 | (goto-char (gethash folder mh-speed-folder-map (point))) |
| 270 | (beginning-of-line) | 270 | (beginning-of-line) |
| 271 | (if (re-search-forward "([1-9][0-9]*/[0-9]+)" (line-end-position) t) | 271 | (if (re-search-forward "([1-9][0-9]*/[0-9]+)" (mh-line-end-position) t) |
| 272 | (setq face (mh-speed-bold-face face)) | 272 | (setq face (mh-speed-bold-face face)) |
| 273 | (setq face (mh-speed-normal-face face))) | 273 | (setq face (mh-speed-normal-face face))) |
| 274 | (beginning-of-line) | 274 | (beginning-of-line) |
| 275 | (when (re-search-forward "\\[.\\] " (line-end-position) t) | 275 | (when (re-search-forward "\\[.\\] " (mh-line-end-position) t) |
| 276 | (put-text-property (point) (line-end-position) 'face face))))) | 276 | (put-text-property (point) (mh-line-end-position) 'face face))))) |
| 277 | 277 | ||
| 278 | (defun mh-speed-normal-face (face) | 278 | (defun mh-speed-normal-face (face) |
| 279 | "Return normal face for given FACE." | 279 | "Return normal face for given FACE." |
| @@ -313,7 +313,7 @@ The function will expand out parent folders of FOLDER if needed." | |||
| 313 | (while suffix-list | 313 | (while suffix-list |
| 314 | ;; We always need atleast one toggle. We need two if the directory list | 314 | ;; We always need atleast one toggle. We need two if the directory list |
| 315 | ;; is stale since a folder was added. | 315 | ;; is stale since a folder was added. |
| 316 | (when (equal prefix (get-text-property (line-beginning-position) | 316 | (when (equal prefix (get-text-property (mh-line-beginning-position) |
| 317 | 'mh-folder)) | 317 | 'mh-folder)) |
| 318 | (mh-speed-toggle) | 318 | (mh-speed-toggle) |
| 319 | (unless (get-text-property (point) 'mh-expanded) | 319 | (unless (get-text-property (point) 'mh-expanded) |
| @@ -368,9 +368,9 @@ uses." | |||
| 368 | (setf (gethash folder-name mh-speed-folder-map) | 368 | (setf (gethash folder-name mh-speed-folder-map) |
| 369 | (set-marker (or (gethash folder-name mh-speed-folder-map) | 369 | (set-marker (or (gethash folder-name mh-speed-folder-map) |
| 370 | (make-marker)) | 370 | (make-marker)) |
| 371 | (1+ (line-beginning-position)))) | 371 | (1+ (mh-line-beginning-position)))) |
| 372 | (add-text-properties | 372 | (add-text-properties |
| 373 | (line-beginning-position) (1+ (line-beginning-position)) | 373 | (mh-line-beginning-position) (1+ (mh-line-beginning-position)) |
| 374 | `(mh-folder ,folder-name | 374 | `(mh-folder ,folder-name |
| 375 | mh-expanded nil | 375 | mh-expanded nil |
| 376 | mh-children-p ,(not (not (cdr f))) | 376 | mh-children-p ,(not (not (cdr f))) |
| @@ -400,7 +400,7 @@ flists is run only for that one folder." | |||
| 400 | (interactive (list t)) | 400 | (interactive (list t)) |
| 401 | (when force | 401 | (when force |
| 402 | (when mh-speed-flists-timer | 402 | (when mh-speed-flists-timer |
| 403 | (cancel-timer mh-speed-flists-timer) | 403 | (mh-cancel-timer mh-speed-flists-timer) |
| 404 | (setq mh-speed-flists-timer nil)) | 404 | (setq mh-speed-flists-timer nil)) |
| 405 | (when (and (processp mh-speed-flists-process) | 405 | (when (and (processp mh-speed-flists-process) |
| 406 | (not (eq (process-status mh-speed-flists-process) 'exit))) | 406 | (not (eq (process-status mh-speed-flists-process) 'exit))) |
| @@ -471,25 +471,25 @@ be handled next." | |||
| 471 | face) | 471 | face) |
| 472 | (when pos | 472 | (when pos |
| 473 | (goto-char pos) | 473 | (goto-char pos) |
| 474 | (goto-char (line-beginning-position)) | 474 | (goto-char (mh-line-beginning-position)) |
| 475 | (cond | 475 | (cond |
| 476 | ((null (get-text-property (point) 'mh-count)) | 476 | ((null (get-text-property (point) 'mh-count)) |
| 477 | (goto-char (line-end-position)) | 477 | (goto-char (mh-line-end-position)) |
| 478 | (setq face (get-text-property (1- (point)) 'face)) | 478 | (setq face (get-text-property (1- (point)) 'face)) |
| 479 | (insert (format " (%s/%s)" unseen total)) | 479 | (insert (format " (%s/%s)" unseen total)) |
| 480 | (mh-speed-highlight 'unknown face) | 480 | (mh-speed-highlight 'unknown face) |
| 481 | (goto-char (line-beginning-position)) | 481 | (goto-char (mh-line-beginning-position)) |
| 482 | (add-text-properties (point) (1+ (point)) | 482 | (add-text-properties (point) (1+ (point)) |
| 483 | `(mh-count (,unseen . ,total)))) | 483 | `(mh-count (,unseen . ,total)))) |
| 484 | ((not (equal (get-text-property (point) 'mh-count) | 484 | ((not (equal (get-text-property (point) 'mh-count) |
| 485 | (cons unseen total))) | 485 | (cons unseen total))) |
| 486 | (goto-char (line-end-position)) | 486 | (goto-char (mh-line-end-position)) |
| 487 | (setq face (get-text-property (1- (point)) 'face)) | 487 | (setq face (get-text-property (1- (point)) 'face)) |
| 488 | (re-search-backward " " (line-beginning-position) t) | 488 | (re-search-backward " " (mh-line-beginning-position) t) |
| 489 | (delete-region (point) (line-end-position)) | 489 | (delete-region (point) (mh-line-end-position)) |
| 490 | (insert (format " (%s/%s)" unseen total)) | 490 | (insert (format " (%s/%s)" unseen total)) |
| 491 | (mh-speed-highlight 'unknown face) | 491 | (mh-speed-highlight 'unknown face) |
| 492 | (goto-char (line-beginning-position)) | 492 | (goto-char (mh-line-beginning-position)) |
| 493 | (add-text-properties | 493 | (add-text-properties |
| 494 | (point) (1+ (point)) | 494 | (point) (1+ (point)) |
| 495 | `(mh-count (,unseen . ,total)))))))))))) | 495 | `(mh-count (,unseen . ,total)))))))))))) |
| @@ -519,15 +519,15 @@ be handled next." | |||
| 519 | (caar parent-kids))) | 519 | (caar parent-kids))) |
| 520 | (setq parent-change ? )))) | 520 | (setq parent-change ? )))) |
| 521 | (goto-char parent-position) | 521 | (goto-char parent-position) |
| 522 | (when (equal (get-text-property (line-beginning-position) 'mh-folder) | 522 | (when (equal (get-text-property (mh-line-beginning-position) 'mh-folder) |
| 523 | parent) | 523 | parent) |
| 524 | (when (get-text-property (line-beginning-position) 'mh-expanded) | 524 | (when (get-text-property (mh-line-beginning-position) 'mh-expanded) |
| 525 | (mh-speed-toggle)) | 525 | (mh-speed-toggle)) |
| 526 | (when parent-change | 526 | (when parent-change |
| 527 | (speedbar-with-writable | 527 | (speedbar-with-writable |
| 528 | (mh-speedbar-change-expand-button-char parent-change) | 528 | (mh-speedbar-change-expand-button-char parent-change) |
| 529 | (add-text-properties | 529 | (add-text-properties |
| 530 | (line-beginning-position) (1+ (line-beginning-position)) | 530 | (mh-line-beginning-position) (1+ (mh-line-beginning-position)) |
| 531 | `(mh-children-p ,(equal parent-change ?+))))) | 531 | `(mh-children-p ,(equal parent-change ?+))))) |
| 532 | (mh-speed-highlight mh-speed-last-selected-folder 'mh-speedbar-folder) | 532 | (mh-speed-highlight mh-speed-last-selected-folder 'mh-speedbar-folder) |
| 533 | (setq mh-speed-last-selected-folder nil) | 533 | (setq mh-speed-last-selected-folder nil) |
| @@ -541,7 +541,7 @@ be handled next." | |||
| 541 | "Change the expansion button character to CHAR for the current line." | 541 | "Change the expansion button character to CHAR for the current line." |
| 542 | (save-excursion | 542 | (save-excursion |
| 543 | (beginning-of-line) | 543 | (beginning-of-line) |
| 544 | (if (re-search-forward "\\[.\\]" (line-end-position) t) | 544 | (if (re-search-forward "\\[.\\]" (mh-line-end-position) t) |
| 545 | (speedbar-with-writable | 545 | (speedbar-with-writable |
| 546 | (backward-char 2) | 546 | (backward-char 2) |
| 547 | (delete-char 1) | 547 | (delete-char 1) |
| @@ -573,9 +573,9 @@ The function invalidates the latest ancestor that is present." | |||
| 573 | (speedbar-with-writable | 573 | (speedbar-with-writable |
| 574 | (mh-speedbar-change-expand-button-char ?+) | 574 | (mh-speedbar-change-expand-button-char ?+) |
| 575 | (add-text-properties | 575 | (add-text-properties |
| 576 | (line-beginning-position) (1+ (line-beginning-position)) | 576 | (mh-line-beginning-position) (1+ (mh-line-beginning-position)) |
| 577 | `(mh-children-p t))) | 577 | `(mh-children-p t))) |
| 578 | (when (get-text-property (line-beginning-position) 'mh-expanded) | 578 | (when (get-text-property (mh-line-beginning-position) 'mh-expanded) |
| 579 | (mh-speed-toggle)) | 579 | (mh-speed-toggle)) |
| 580 | (setq mh-speed-refresh-flag t)))) | 580 | (setq mh-speed-refresh-flag t)))) |
| 581 | 581 | ||
diff --git a/lisp/mh-e/mh-thread.el b/lisp/mh-e/mh-thread.el index fa9719985a9..0686b10ac26 100644 --- a/lisp/mh-e/mh-thread.el +++ b/lisp/mh-e/mh-thread.el | |||
| @@ -296,7 +296,7 @@ at the end." | |||
| 296 | (while (not (eobp)) | 296 | (while (not (eobp)) |
| 297 | (forward-char address-start-offset) | 297 | (forward-char address-start-offset) |
| 298 | (unless (equal (string-match spaces (buffer-substring-no-properties | 298 | (unless (equal (string-match spaces (buffer-substring-no-properties |
| 299 | (point) (line-end-position))) | 299 | (point) (mh-line-end-position))) |
| 300 | 0) | 300 | 0) |
| 301 | (beginning-of-line) | 301 | (beginning-of-line) |
| 302 | (backward-char) | 302 | (backward-char) |
| @@ -456,9 +456,9 @@ are the same containers." | |||
| 456 | If optional argument STRING is given then that is assumed to be | 456 | If optional argument STRING is given then that is assumed to be |
| 457 | the scan line. Otherwise uses the line at point as the scan line | 457 | the scan line. Otherwise uses the line at point as the scan line |
| 458 | to parse." | 458 | to parse." |
| 459 | (let* ((string (or string | 459 | (let* ((string (or string (buffer-substring-no-properties |
| 460 | (buffer-substring-no-properties (line-beginning-position) | 460 | (mh-line-beginning-position) |
| 461 | (line-end-position)))) | 461 | (mh-line-end-position)))) |
| 462 | (address-start (+ mh-cmd-note mh-scan-field-from-start-offset)) | 462 | (address-start (+ mh-cmd-note mh-scan-field-from-start-offset)) |
| 463 | (body-start (+ mh-cmd-note mh-scan-field-from-end-offset)) | 463 | (body-start (+ mh-cmd-note mh-scan-field-from-end-offset)) |
| 464 | (first-string (substring string 0 address-start))) | 464 | (first-string (substring string 0 address-start))) |
| @@ -599,18 +599,20 @@ Only information about messages in MSG-LIST are added to the tree." | |||
| 599 | (while (not (eobp)) | 599 | (while (not (eobp)) |
| 600 | (block process-message | 600 | (block process-message |
| 601 | (let* ((index-line | 601 | (let* ((index-line |
| 602 | (prog1 (buffer-substring (point) (line-end-position)) | 602 | (prog1 (buffer-substring (point) (mh-line-end-position)) |
| 603 | (forward-line))) | 603 | (forward-line))) |
| 604 | (index (string-to-number index-line)) | 604 | (index (string-to-number index-line)) |
| 605 | (id (prog1 (buffer-substring (point) (line-end-position)) | 605 | (id (prog1 (buffer-substring (point) (mh-line-end-position)) |
| 606 | (forward-line))) | 606 | (forward-line))) |
| 607 | (refs (prog1 (buffer-substring (point) (line-end-position)) | 607 | (refs (prog1 |
| 608 | (buffer-substring (point) (mh-line-end-position)) | ||
| 608 | (forward-line))) | 609 | (forward-line))) |
| 609 | (in-reply-to (prog1 (buffer-substring (point) | 610 | (in-reply-to (prog1 (buffer-substring (point) |
| 610 | (line-end-position)) | 611 | (mh-line-end-position)) |
| 611 | (forward-line))) | 612 | (forward-line))) |
| 612 | (subject (prog1 | 613 | (subject (prog1 |
| 613 | (buffer-substring (point) (line-end-position)) | 614 | (buffer-substring |
| 615 | (point) (mh-line-end-position)) | ||
| 614 | (forward-line))) | 616 | (forward-line))) |
| 615 | (subject-re-p nil)) | 617 | (subject-re-p nil)) |
| 616 | (unless (gethash index mh-thread-scan-line-map) | 618 | (unless (gethash index mh-thread-scan-line-map) |
diff --git a/lisp/mh-e/mh-tool-bar.el b/lisp/mh-e/mh-tool-bar.el index ebf07a77672..20b239189fa 100644 --- a/lisp/mh-e/mh-tool-bar.el +++ b/lisp/mh-e/mh-tool-bar.el | |||
| @@ -31,6 +31,10 @@ | |||
| 31 | ;;; Code: | 31 | ;;; Code: |
| 32 | 32 | ||
| 33 | (require 'mh-e) | 33 | (require 'mh-e) |
| 34 | (mh-do-in-gnu-emacs | ||
| 35 | (require 'tool-bar)) | ||
| 36 | (mh-do-in-xemacs | ||
| 37 | (require 'toolbar)) | ||
| 34 | 38 | ||
| 35 | ;;; Tool Bar Commands | 39 | ;;; Tool Bar Commands |
| 36 | 40 | ||
diff --git a/lisp/mh-e/mh-utils.el b/lisp/mh-e/mh-utils.el index b34ff8ee5b6..42f11376262 100644 --- a/lisp/mh-e/mh-utils.el +++ b/lisp/mh-e/mh-utils.el | |||
| @@ -68,7 +68,7 @@ used in lieu of `search' in the CL package." | |||
| 68 | (defun mh-colors-available-p () | 68 | (defun mh-colors-available-p () |
| 69 | "Check if colors are available in the Emacs being used." | 69 | "Check if colors are available in the Emacs being used." |
| 70 | (or mh-xemacs-flag | 70 | (or mh-xemacs-flag |
| 71 | (let ((color-cells (display-color-cells))) | 71 | (let ((color-cells (mh-display-color-cells))) |
| 72 | (and (numberp color-cells) (>= color-cells 8))))) | 72 | (and (numberp color-cells) (>= color-cells 8))))) |
| 73 | 73 | ||
| 74 | ;;;###mh-autoload | 74 | ;;;###mh-autoload |
| @@ -81,30 +81,49 @@ used in lieu of `search' in the CL package." | |||
| 81 | "Delete the next LINES lines." | 81 | "Delete the next LINES lines." |
| 82 | (delete-region (point) (progn (forward-line lines) (point)))) | 82 | (delete-region (point) (progn (forward-line lines) (point)))) |
| 83 | 83 | ||
| 84 | (defvar mh-image-load-path-called-flag nil) | 84 | (defvar mh-image-load-path nil |
| 85 | "Directory where images for MH-E are found. | ||
| 86 | If nil, then the function `mh-image-load-path' will search for | ||
| 87 | the images in \"../../etc/images\" relative to the files in | ||
| 88 | \"lisp/mh-e\".") | ||
| 89 | |||
| 90 | (defvar mh-image-load-path-called-flag nil | ||
| 91 | "Non-nil means that the function `mh-image-load-path' has been called. | ||
| 92 | This variable is used by that function to avoid doing the work repeatedly.") | ||
| 85 | 93 | ||
| 86 | ;;;###mh-autoload | 94 | ;;;###mh-autoload |
| 87 | (defun mh-image-load-path () | 95 | (defun mh-image-load-path () |
| 88 | "Ensure that the MH-E images are accessible by `find-image'. | 96 | "Ensure that the MH-E images are accessible by `find-image'. |
| 89 | Images for MH-E are found in ../../etc/images relative to the | 97 | |
| 90 | files in \"lisp/mh-e\". If `image-load-path' exists (since Emacs | 98 | Images for MH-E are found in \"../../etc/images\" relative to the |
| 91 | 22), then the images directory is added to it if isn't already | 99 | files in \"lisp/mh-e\". This function saves the actual location |
| 92 | there. Otherwise, the images directory is added to the | 100 | found in the variable `mh-image-load-path'. If the images on your |
| 93 | `load-path' if it isn't already there." | 101 | system are actually located elsewhere, then set the variable |
| 102 | `mh-image-load-path' before starting MH-E. | ||
| 103 | |||
| 104 | If `image-load-path' exists (since Emacs 22), then the contents | ||
| 105 | of the variable `mh-image-load-path' is added to it if isn't | ||
| 106 | already there. Otherwise, the contents of the variable | ||
| 107 | `mh-image-load-path' is added to the `load-path' if it isn't | ||
| 108 | already there. | ||
| 109 | |||
| 110 | See also variable `mh-image-load-path-called-flag'." | ||
| 94 | (unless mh-image-load-path-called-flag | 111 | (unless mh-image-load-path-called-flag |
| 95 | (let (mh-library-name mh-image-load-path) | 112 | (if (or (not mh-image-load-path) |
| 96 | ;; First, find mh-e in the load-path. | 113 | (not (file-exists-p mh-image-load-path))) |
| 97 | (setq mh-library-name (locate-library "mh-e")) | 114 | (let (mh-library-name) |
| 98 | (if (not mh-library-name) | 115 | ;; First, find mh-e in the load-path. |
| 99 | (error "Can not find MH-E in load-path")) | 116 | (setq mh-library-name (locate-library "mh-e")) |
| 100 | (setq mh-image-load-path | 117 | (if (not mh-library-name) |
| 101 | (expand-file-name (concat (file-name-directory mh-library-name) | 118 | (error "Can not find MH-E in load-path")) |
| 102 | "../../etc/images"))) | 119 | (setq mh-image-load-path |
| 103 | (if (not (file-exists-p mh-image-load-path)) | 120 | (expand-file-name (concat (file-name-directory mh-library-name) |
| 104 | (error "Can not find image directory %s" mh-image-load-path)) | 121 | "../../etc/images"))))) |
| 105 | (if (boundp 'image-load-path) | 122 | (if (not (file-exists-p mh-image-load-path)) |
| 106 | (add-to-list 'image-load-path mh-image-load-path) | 123 | (error "Can not find image directory %s" mh-image-load-path)) |
| 107 | (add-to-list 'load-path mh-image-load-path))) | 124 | (if (boundp 'image-load-path) |
| 125 | (add-to-list 'image-load-path mh-image-load-path) | ||
| 126 | (add-to-list 'load-path mh-image-load-path)) | ||
| 108 | (setq mh-image-load-path-called-flag t))) | 127 | (setq mh-image-load-path-called-flag t))) |
| 109 | 128 | ||
| 110 | ;;;###mh-autoload | 129 | ;;;###mh-autoload |
| @@ -502,8 +521,8 @@ not be returned." | |||
| 502 | ;; top-level folders; otherwise mh-sub-folders returns all the | 521 | ;; top-level folders; otherwise mh-sub-folders returns all the |
| 503 | ;; files in / if given an empty string or +. | 522 | ;; files in / if given an empty string or +. |
| 504 | (when folder | 523 | (when folder |
| 505 | (setq folder (replace-regexp-in-string "^\+" "" folder)) | 524 | (setq folder (mh-replace-regexp-in-string "^\+" "" folder)) |
| 506 | (setq folder (replace-regexp-in-string "/*$" "/" folder)) | 525 | (setq folder (mh-replace-regexp-in-string "/*$" "/" folder)) |
| 507 | (if (equal folder "") | 526 | (if (equal folder "") |
| 508 | (setq folder nil))) | 527 | (setq folder nil))) |
| 509 | (loop for f in (mh-sub-folders folder) do | 528 | (loop for f in (mh-sub-folders folder) do |
| @@ -553,9 +572,10 @@ directories that aren't usually mail folders are hidden." | |||
| 553 | (apply #'call-process arg-list) | 572 | (apply #'call-process arg-list) |
| 554 | (goto-char (point-min)) | 573 | (goto-char (point-min)) |
| 555 | (while (not (and (eolp) (bolp))) | 574 | (while (not (and (eolp) (bolp))) |
| 556 | (goto-char (line-end-position)) | 575 | (goto-char (mh-line-end-position)) |
| 557 | (let ((start-pos (line-beginning-position)) | 576 | (let ((start-pos (mh-line-beginning-position)) |
| 558 | (has-pos (search-backward " has " (line-beginning-position) t))) | 577 | (has-pos (search-backward " has " |
| 578 | (mh-line-beginning-position) t))) | ||
| 559 | (when (integerp has-pos) | 579 | (when (integerp has-pos) |
| 560 | (while (equal (char-after has-pos) ? ) | 580 | (while (equal (char-after has-pos) ? ) |
| 561 | (decf has-pos)) | 581 | (decf has-pos)) |
| @@ -570,7 +590,7 @@ directories that aren't usually mail folders are hidden." | |||
| 570 | (setq name (substring name 0 (1- (length name))))) | 590 | (setq name (substring name 0 (1- (length name))))) |
| 571 | (push | 591 | (push |
| 572 | (cons name | 592 | (cons name |
| 573 | (search-forward "(others)" (line-end-position) t)) | 593 | (search-forward "(others)" (mh-line-end-position) t)) |
| 574 | results)))) | 594 | results)))) |
| 575 | (forward-line 1)))) | 595 | (forward-line 1)))) |
| 576 | (setq results (nreverse results)) | 596 | (setq results (nreverse results)) |
| @@ -927,10 +947,12 @@ is hidden, if positive then the field is displayed." | |||
| 927 | (unwind-protect | 947 | (unwind-protect |
| 928 | (cond ((or (and (not arg) | 948 | (cond ((or (and (not arg) |
| 929 | (text-property-any begin end 'invisible 'vanish)) | 949 | (text-property-any begin end 'invisible 'vanish)) |
| 930 | (and (numberp arg) (>= arg 0)) | 950 | (and (numberp arg) |
| 931 | (and (eq arg 'long) (> (line-beginning-position 5) end))) | 951 | (>= arg 0)) |
| 952 | (and (eq arg 'long) | ||
| 953 | (> (mh-line-beginning-position 5) end))) | ||
| 932 | (remove-text-properties begin end '(invisible nil)) | 954 | (remove-text-properties begin end '(invisible nil)) |
| 933 | (search-forward ":" (line-end-position) t) | 955 | (search-forward ":" (mh-line-end-position) t) |
| 934 | (mh-letter-skip-leading-whitespace-in-header-field)) | 956 | (mh-letter-skip-leading-whitespace-in-header-field)) |
| 935 | ;; XXX Redesign to make usable by user. Perhaps use a positive | 957 | ;; XXX Redesign to make usable by user. Perhaps use a positive |
| 936 | ;; numeric prefix to make that many lines visible. | 958 | ;; numeric prefix to make that many lines visible. |
diff --git a/lisp/net/newsticker.el b/lisp/net/newsticker.el index 1854e7adda0..c07faa4ca63 100644 --- a/lisp/net/newsticker.el +++ b/lisp/net/newsticker.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; newsticker.el --- A Newsticker for Emacs. | 1 | ;;; newsticker.el --- A Newsticker for Emacs. |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 2003, 2004, 2005 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 2003, 2004, 2005 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; This file is part of GNU Emacs. | 5 | ;; This file is part of GNU Emacs. |
| 6 | 6 | ||
| @@ -397,7 +397,7 @@ | |||
| 397 | 397 | ||
| 398 | (defvar newsticker--retrieval-timer-list nil | 398 | (defvar newsticker--retrieval-timer-list nil |
| 399 | "List of timers for news retrieval. | 399 | "List of timers for news retrieval. |
| 400 | This is an alist, each element consisting of (feed-name . timer)") | 400 | This is an alist, each element consisting of (feed-name . timer).") |
| 401 | 401 | ||
| 402 | (defvar newsticker--display-timer nil | 402 | (defvar newsticker--display-timer nil |
| 403 | "Timer for newsticker display.") | 403 | "Timer for newsticker display.") |
| @@ -485,8 +485,8 @@ This list is fed into defcustom via `newsticker--splicer'.") | |||
| 485 | (defun newsticker--set-customvar (symbol value) | 485 | (defun newsticker--set-customvar (symbol value) |
| 486 | "Set newsticker-variable SYMBOL value to VALUE. | 486 | "Set newsticker-variable SYMBOL value to VALUE. |
| 487 | 487 | ||
| 488 | Calls all necessary actions which are necessary in order to make | 488 | Calls all actions which are necessary in order to make the new |
| 489 | the new value effective. Changing `newsticker-url-list', for example, | 489 | value effective. Changing `newsticker-url-list', for example, |
| 490 | will re-start the retrieval-timers." | 490 | will re-start the retrieval-timers." |
| 491 | (unless (condition-case nil | 491 | (unless (condition-case nil |
| 492 | (eq (symbol-value symbol) value) | 492 | (eq (symbol-value symbol) value) |
| @@ -586,7 +586,7 @@ specify as `newsticker-wget-name'. | |||
| 586 | 586 | ||
| 587 | The START-TIME can be either a string, or nil. If it is a string it | 587 | The START-TIME can be either a string, or nil. If it is a string it |
| 588 | specifies a fixed time at which this feed shall be retrieved for the | 588 | specifies a fixed time at which this feed shall be retrieved for the |
| 589 | first time. (Examples: \"11:00pm\", \"23:00\"). If it is nil (or | 589 | first time. (Examples: \"11:00pm\", \"23:00\".) If it is nil (or |
| 590 | unspecified), this feed will be retrieved immediately after calling | 590 | unspecified), this feed will be retrieved immediately after calling |
| 591 | `newsticker-start'. | 591 | `newsticker-start'. |
| 592 | 592 | ||
| @@ -940,7 +940,7 @@ or, if you use htmlr | |||
| 940 | (:family "helvetica" :bold t)) | 940 | (:family "helvetica" :bold t)) |
| 941 | (((class color) (background light)) | 941 | (((class color) (background light)) |
| 942 | (:family "helvetica" :bold t))) | 942 | (:family "helvetica" :bold t))) |
| 943 | "Face for old news items." | 943 | "Face for news items." |
| 944 | :group 'newsticker-faces) | 944 | :group 'newsticker-faces) |
| 945 | 945 | ||
| 946 | (defface newsticker-old-item-face | 946 | (defface newsticker-old-item-face |
| @@ -1041,7 +1041,7 @@ at all. If you change `newsticker-scroll-smoothly' you should also change | |||
| 1041 | t | 1041 | t |
| 1042 | "Decides whether to show immortal/non-expiring news items in the ticker. | 1042 | "Decides whether to show immortal/non-expiring news items in the ticker. |
| 1043 | If t the echo area will not show immortal items. See also | 1043 | If t the echo area will not show immortal items. See also |
| 1044 | `newsticker-hide-old-items-in-echo-area." | 1044 | `newsticker-hide-old-items-in-echo-area'." |
| 1045 | :type 'boolean | 1045 | :type 'boolean |
| 1046 | :set 'newsticker--set-customvar | 1046 | :set 'newsticker--set-customvar |
| 1047 | :group 'newsticker-ticker) | 1047 | :group 'newsticker-ticker) |
| @@ -1059,7 +1059,7 @@ been added between the last two retrievals." | |||
| 1059 | t | 1059 | t |
| 1060 | "Decides whether to show obsolete items items in the ticker. | 1060 | "Decides whether to show obsolete items items in the ticker. |
| 1061 | If t the echo area will not show obsolete items. See also | 1061 | If t the echo area will not show obsolete items. See also |
| 1062 | `newsticker-hide-old-items-in-echo-area." | 1062 | `newsticker-hide-old-items-in-echo-area'." |
| 1063 | :type 'boolean | 1063 | :type 'boolean |
| 1064 | :set 'newsticker--set-customvar | 1064 | :set 'newsticker--set-customvar |
| 1065 | :group 'newsticker-ticker) | 1065 | :group 'newsticker-ticker) |
| @@ -2376,7 +2376,7 @@ static char * visit_xpm[] = { | |||
| 2376 | guid | 2376 | guid |
| 2377 | (car (xml-node-children guid))))) | 2377 | (car (xml-node-children guid))))) |
| 2378 | (defsubst newsticker--enclosure (item) | 2378 | (defsubst newsticker--enclosure (item) |
| 2379 | "Return enclosure element of ITEM in the form \(...FIXME...\)or nil." | 2379 | "Return enclosure element of ITEM in the form \(...FIXME...\) or nil." |
| 2380 | (let ((enclosure (assoc 'enclosure (newsticker--extra item)))) | 2380 | (let ((enclosure (assoc 'enclosure (newsticker--extra item)))) |
| 2381 | (if enclosure | 2381 | (if enclosure |
| 2382 | (xml-node-attributes enclosure)))) | 2382 | (xml-node-attributes enclosure)))) |
| @@ -2490,7 +2490,7 @@ if newsticker has been running." | |||
| 2490 | 2490 | ||
| 2491 | (defun newsticker-buffer-update (&optional force) | 2491 | (defun newsticker-buffer-update (&optional force) |
| 2492 | "Update the *newsticker* buffer. | 2492 | "Update the *newsticker* buffer. |
| 2493 | Unless FORCE is t this is donly only if necessary, i.e. when the | 2493 | Unless FORCE is t this is done only if necessary, i.e. when the |
| 2494 | *newsticker* buffer is not up-to-date." | 2494 | *newsticker* buffer is not up-to-date." |
| 2495 | (interactive) | 2495 | (interactive) |
| 2496 | ;; bring cache data into proper order.... | 2496 | ;; bring cache data into proper order.... |
| @@ -2584,7 +2584,7 @@ If URL is nil it is searched at point." | |||
| 2584 | "Show inline images in visible text ranges. | 2584 | "Show inline images in visible text ranges. |
| 2585 | In-line images in invisible text ranges are hidden. This function | 2585 | In-line images in invisible text ranges are hidden. This function |
| 2586 | calls `w3m-toggle-inline-image'. It works only if | 2586 | calls `w3m-toggle-inline-image'. It works only if |
| 2587 | `newsticker-html-renderer' is set to `w3m-region'" | 2587 | `newsticker-html-renderer' is set to `w3m-region'." |
| 2588 | (interactive) | 2588 | (interactive) |
| 2589 | (if (eq newsticker-html-renderer 'w3m-region) | 2589 | (if (eq newsticker-html-renderer 'w3m-region) |
| 2590 | (let ((inhibit-read-only t)) | 2590 | (let ((inhibit-read-only t)) |
| @@ -3290,7 +3290,7 @@ Argument EVENT tells what has happened to the process." | |||
| 3290 | (newsticker--cache-replace-age newsticker--cache | 3290 | (newsticker--cache-replace-age newsticker--cache |
| 3291 | name-symbol | 3291 | name-symbol |
| 3292 | 'feed 'obsolete-old) | 3292 | 'feed 'obsolete-old) |
| 3293 | 3293 | ||
| 3294 | ;; check Atom/RSS version and call corresponding parser | 3294 | ;; check Atom/RSS version and call corresponding parser |
| 3295 | (condition-case error-data | 3295 | (condition-case error-data |
| 3296 | (if (cond | 3296 | (if (cond |
| @@ -3405,7 +3405,7 @@ Argument EVENT tells what has happened to the process." | |||
| 3405 | (defun newsticker--parse-atom-0.3 (name time topnode) | 3405 | (defun newsticker--parse-atom-0.3 (name time topnode) |
| 3406 | "Parse Atom 0.3 data. | 3406 | "Parse Atom 0.3 data. |
| 3407 | Return value as well as arguments NAME, TIME, and TOPNODE are the | 3407 | Return value as well as arguments NAME, TIME, and TOPNODE are the |
| 3408 | same as in `newsticker--parse-generic-rss'." | 3408 | same as in `newsticker--parse-atom-1.0'." |
| 3409 | (newsticker--debug-msg "Parsing Atom 0.3 feed %s" name) | 3409 | (newsticker--debug-msg "Parsing Atom 0.3 feed %s" name) |
| 3410 | (let (new-feed new-item) | 3410 | (let (new-feed new-item) |
| 3411 | (setq new-feed (newsticker--parse-generic-feed | 3411 | (setq new-feed (newsticker--parse-generic-feed |
| @@ -3613,8 +3613,8 @@ For the RSS 0.92 specification see http://backend.userland.com/rss092." | |||
| 3613 | 3613 | ||
| 3614 | (defun newsticker--parse-rss-1.0 (name time topnode) | 3614 | (defun newsticker--parse-rss-1.0 (name time topnode) |
| 3615 | "Parse RSS 1.0 data. | 3615 | "Parse RSS 1.0 data. |
| 3616 | Return value as well as arguments NAME, TIME, and | 3616 | Return value as well as arguments NAME, TIME, and TOPNODE are the |
| 3617 | TOPNODE are the same as in `newsticker--parse-atom-1.0'. | 3617 | same as in `newsticker--parse-atom-1.0'. |
| 3618 | 3618 | ||
| 3619 | For the RSS 1.0 specification see http://web.resource.org/rss/1.0/spec." | 3619 | For the RSS 1.0 specification see http://web.resource.org/rss/1.0/spec." |
| 3620 | (newsticker--debug-msg "Parsing RSS 1.0 feed %s" name) | 3620 | (newsticker--debug-msg "Parsing RSS 1.0 feed %s" name) |
| @@ -3724,9 +3724,7 @@ For the RSS 2.0 specification see http://blogs.law.harvard.edu/tech/rss." | |||
| 3724 | extra-elements) | 3724 | extra-elements) |
| 3725 | "Parse generic news feed data. | 3725 | "Parse generic news feed data. |
| 3726 | Argument NAME gives the name of a news feed. TIME gives the | 3726 | Argument NAME gives the name of a news feed. TIME gives the |
| 3727 | system time at which the data have been retrieved. CHANNELNODE | 3727 | system time at which the data have been retrieved. |
| 3728 | is the node in the feed data which contains the description, link | ||
| 3729 | etc. of the feed itself. | ||
| 3730 | 3728 | ||
| 3731 | The arguments TITLE, DESC, LINK, and EXTRA-ELEMENTS give the feed's title, | 3729 | The arguments TITLE, DESC, LINK, and EXTRA-ELEMENTS give the feed's title, |
| 3732 | description, link, and extra elements resp." | 3730 | description, link, and extra elements resp." |
| @@ -3966,7 +3964,7 @@ This function calls `message' with arguments STRING and ARGS, if | |||
| 3966 | 3964 | ||
| 3967 | (defun newsticker--decode-iso8601-date (iso8601-string) | 3965 | (defun newsticker--decode-iso8601-date (iso8601-string) |
| 3968 | "Return ISO8601-STRING in format like `decode-time'. | 3966 | "Return ISO8601-STRING in format like `decode-time'. |
| 3969 | Converts from ISO-8601 to Emacs representation. If ISO8601-STRING | 3967 | Converts from ISO-8601 to Emacs representation. |
| 3970 | Examples: | 3968 | Examples: |
| 3971 | 2004-09-17T05:09:49+00:00 | 3969 | 2004-09-17T05:09:49+00:00 |
| 3972 | 2004-09-17T05:09+00:00 | 3970 | 2004-09-17T05:09+00:00 |
| @@ -4300,10 +4298,9 @@ Keeps order of feeds as given in `newsticker-url-list' and | |||
| 4300 | 4298 | ||
| 4301 | (defun newsticker--buffer-insert-item (item &optional feed-name-symbol) | 4299 | (defun newsticker--buffer-insert-item (item &optional feed-name-symbol) |
| 4302 | "Insert a news item in the current buffer. | 4300 | "Insert a news item in the current buffer. |
| 4303 | Insert the string PREFIX and a formatted representation of the | 4301 | Insert a formatted representation of the ITEM. The optional parameter |
| 4304 | ITEM. The optional parameter FEED-NAME-SYMBOL determines how the | 4302 | FEED-NAME-SYMBOL determines how the item is formatted and whether the |
| 4305 | item is formatted and whether the item-retrieval time is added as | 4303 | item-retrieval time is added as well." |
| 4306 | well." | ||
| 4307 | ;; insert headline | 4304 | ;; insert headline |
| 4308 | (if (eq (newsticker--age item) 'feed) | 4305 | (if (eq (newsticker--age item) 'feed) |
| 4309 | (newsticker--buffer-do-insert-text item 'feed feed-name-symbol) | 4306 | (newsticker--buffer-do-insert-text item 'feed feed-name-symbol) |
| @@ -4831,11 +4828,11 @@ backwards." | |||
| 4831 | (goto-char pos)) | 4828 | (goto-char pos)) |
| 4832 | pos)) | 4829 | pos)) |
| 4833 | 4830 | ||
| 4834 | (defun newsticker--buffer-hideshow (mark-age onoff ) | 4831 | (defun newsticker--buffer-hideshow (mark-age onoff) |
| 4835 | "Hide or show items of type MARK-AGE. | 4832 | "Hide or show items of type MARK-AGE. |
| 4836 | If ONOFF is nil the item is hidden, otherwise it is shown." | 4833 | If ONOFF is nil the item is hidden, otherwise it is shown." |
| 4837 | (if onoff | 4834 | (if onoff |
| 4838 | (remove-from-invisibility-spec mark-age ) | 4835 | (remove-from-invisibility-spec mark-age) |
| 4839 | (add-to-invisibility-spec mark-age))) | 4836 | (add-to-invisibility-spec mark-age))) |
| 4840 | 4837 | ||
| 4841 | (defun newsticker--buffer-beginning-of-item () | 4838 | (defun newsticker--buffer-beginning-of-item () |
| @@ -5026,7 +5023,7 @@ GUID. In general all properties must match in order to return a | |||
| 5026 | certain item, except for the following cases. | 5023 | certain item, except for the following cases. |
| 5027 | 5024 | ||
| 5028 | If AGE equals 'feed the TITLE, DESCription and LINK do not | 5025 | If AGE equals 'feed the TITLE, DESCription and LINK do not |
| 5029 | matter. If DESC is nil it is ignored as well. If | 5026 | matter. If DESC is nil it is ignored as well. If |
| 5030 | `newsticker-desc-comp-max' is non-nil, only the first | 5027 | `newsticker-desc-comp-max' is non-nil, only the first |
| 5031 | `newsticker-desc-comp-max' characters of DESC are taken into | 5028 | `newsticker-desc-comp-max' characters of DESC are taken into |
| 5032 | account. | 5029 | account. |
| @@ -5252,7 +5249,7 @@ FEED is a symbol!" | |||
| 5252 | ;; ====================================================================== | 5249 | ;; ====================================================================== |
| 5253 | (defun newsticker--stat-num-items (feed &optional age) | 5250 | (defun newsticker--stat-num-items (feed &optional age) |
| 5254 | "Return number of items in the given FEED which have the given AGE. | 5251 | "Return number of items in the given FEED which have the given AGE. |
| 5255 | If AGE is nil, the total number items is returned." | 5252 | If AGE is nil, the total number of items is returned." |
| 5256 | (let ((items (cdr (newsticker--cache-get-feed feed))) | 5253 | (let ((items (cdr (newsticker--cache-get-feed feed))) |
| 5257 | (num 0)) | 5254 | (num 0)) |
| 5258 | (while items | 5255 | (while items |
| @@ -5329,7 +5326,8 @@ for an entry that matches FEED and ITEM." | |||
| 5329 | newsticker-auto-mark-filter-list))) | 5326 | newsticker-auto-mark-filter-list))) |
| 5330 | 5327 | ||
| 5331 | (defun newsticker--do-run-auto-mark-filter (item list) | 5328 | (defun newsticker--do-run-auto-mark-filter (item list) |
| 5332 | "Actually compare ITEM AGE LIST against `newsticker-auto-mark-filter-list'." | 5329 | "Actually compare ITEM against the pattern-LIST |
| 5330 | \(from `newsticker-auto-mark-filter-list')." | ||
| 5333 | (mapc (lambda (pattern) | 5331 | (mapc (lambda (pattern) |
| 5334 | (let ((age (nth 0 pattern)) | 5332 | (let ((age (nth 0 pattern)) |
| 5335 | (place (nth 1 pattern)) | 5333 | (place (nth 1 pattern)) |
| @@ -5384,8 +5382,8 @@ in the description=contents of ITEM to the directory | |||
| 5384 | (defun newsticker-download-enclosures (feed item) | 5382 | (defun newsticker-download-enclosures (feed item) |
| 5385 | "In all FEEDs download the enclosed object of the news ITEM. | 5383 | "In all FEEDs download the enclosed object of the news ITEM. |
| 5386 | The object is saved to the directory \"~/tmp/newsticker/FEED/TITLE\", which | 5384 | The object is saved to the directory \"~/tmp/newsticker/FEED/TITLE\", which |
| 5387 | is created if it does not exist. TITLE is the title of the news | 5385 | is created if it does not exist. TITLE is the title of the news |
| 5388 | item. Argument FEED is ignored. | 5386 | item. Argument FEED is ignored. |
| 5389 | This function is suited for adding it to `newsticker-new-item-functions'." | 5387 | This function is suited for adding it to `newsticker-new-item-functions'." |
| 5390 | (let ((title (newsticker--title item)) | 5388 | (let ((title (newsticker--title item)) |
| 5391 | (enclosure (newsticker--enclosure item))) | 5389 | (enclosure (newsticker--enclosure item))) |
diff --git a/lisp/net/rcirc.el b/lisp/net/rcirc.el index ca007554267..2e512ae4e19 100644 --- a/lisp/net/rcirc.el +++ b/lisp/net/rcirc.el | |||
| @@ -92,7 +92,7 @@ Each element looks like (SERVER-REGEXP . CHANNEL-LIST)." | |||
| 92 | 92 | ||
| 93 | (defcustom rcirc-fill-column nil | 93 | (defcustom rcirc-fill-column nil |
| 94 | "*Column beyond which automatic line-wrapping should happen. | 94 | "*Column beyond which automatic line-wrapping should happen. |
| 95 | If nil, use value of `fill-column'. If frame-width, use the | 95 | If nil, use value of `fill-column'. If 'frame-width, use the |
| 96 | maximum frame width." | 96 | maximum frame width." |
| 97 | :type '(choice (const :tag "Value of `fill-column'") | 97 | :type '(choice (const :tag "Value of `fill-column'") |
| 98 | (const :tag "Full frame width" frame-width) | 98 | (const :tag "Full frame width" frame-width) |
| @@ -128,7 +128,7 @@ Used as the first arg to `format-time-string'." | |||
| 128 | :group 'rcirc) | 128 | :group 'rcirc) |
| 129 | 129 | ||
| 130 | (defcustom rcirc-read-only-flag t | 130 | (defcustom rcirc-read-only-flag t |
| 131 | "*Non-nil means make text in irc buffers read-only." | 131 | "*Non-nil means make text in IRC buffers read-only." |
| 132 | :type 'boolean | 132 | :type 'boolean |
| 133 | :group 'rcirc) | 133 | :group 'rcirc) |
| 134 | 134 | ||
| @@ -167,7 +167,7 @@ See also `rcirc-authinfo-file-name'." | |||
| 167 | :group 'rcirc) | 167 | :group 'rcirc) |
| 168 | 168 | ||
| 169 | (defcustom rcirc-prompt "> " | 169 | (defcustom rcirc-prompt "> " |
| 170 | "Prompt string to use in irc buffers. | 170 | "Prompt string to use in IRC buffers. |
| 171 | 171 | ||
| 172 | The following replacements are made: | 172 | The following replacements are made: |
| 173 | %n is your nick. | 173 | %n is your nick. |
| @@ -354,7 +354,7 @@ last ping." | |||
| 354 | "If non-nil, write information to `rcirc-debug-buffer'.") | 354 | "If non-nil, write information to `rcirc-debug-buffer'.") |
| 355 | (defun rcirc-debug (process text) | 355 | (defun rcirc-debug (process text) |
| 356 | "Add an entry to the debug log including PROCESS and TEXT. | 356 | "Add an entry to the debug log including PROCESS and TEXT. |
| 357 | Debug text is written to `rcirc-debug-buffer' if `rcirc-debug-p' | 357 | Debug text is written to `rcirc-debug-buffer' if `rcirc-debug-flag' |
| 358 | is non-nil." | 358 | is non-nil." |
| 359 | (when rcirc-debug-flag | 359 | (when rcirc-debug-flag |
| 360 | (save-excursion | 360 | (save-excursion |
| @@ -401,8 +401,8 @@ Functions are called with PROCESS and SENTINEL arguments.") | |||
| 401 | ps)) | 401 | ps)) |
| 402 | 402 | ||
| 403 | (defvar rcirc-receive-message-hooks nil | 403 | (defvar rcirc-receive-message-hooks nil |
| 404 | "Hook functions run when a message is recieved from server. | 404 | "Hook functions run when a message is received from server. |
| 405 | Function is called with PROCESS COMMAND SENDER ARGS and LINE.") | 405 | Function is called with PROCESS, COMMAND, SENDER, ARGS and LINE.") |
| 406 | (defun rcirc-filter (process output) | 406 | (defun rcirc-filter (process output) |
| 407 | "Called when PROCESS receives OUTPUT." | 407 | "Called when PROCESS receives OUTPUT." |
| 408 | (rcirc-debug process output) | 408 | (rcirc-debug process output) |
| @@ -587,7 +587,7 @@ If buffer is nil, return the target of the current buffer." | |||
| 587 | (define-key global-map (kbd "C-c C-SPC") 'rcirc-next-active-buffer) | 587 | (define-key global-map (kbd "C-c C-SPC") 'rcirc-next-active-buffer) |
| 588 | 588 | ||
| 589 | (defvar rcirc-browse-url-map (make-sparse-keymap) | 589 | (defvar rcirc-browse-url-map (make-sparse-keymap) |
| 590 | "Keymap used ror browsing URLs in `rcirc-mode'.") | 590 | "Keymap used for browsing URLs in `rcirc-mode'.") |
| 591 | 591 | ||
| 592 | (define-key rcirc-browse-url-map (kbd "RET") 'rcirc-browse-url-at-point) | 592 | (define-key rcirc-browse-url-map (kbd "RET") 'rcirc-browse-url-at-point) |
| 593 | (define-key rcirc-browse-url-map (kbd "<mouse-2>") 'rcirc-browse-url-at-mouse) | 593 | (define-key rcirc-browse-url-map (kbd "<mouse-2>") 'rcirc-browse-url-at-mouse) |
| @@ -599,7 +599,7 @@ If buffer is nil, return the target of the current buffer." | |||
| 599 | "Hook run when setting up rcirc buffer.") | 599 | "Hook run when setting up rcirc buffer.") |
| 600 | 600 | ||
| 601 | (defun rcirc-mode (process target) | 601 | (defun rcirc-mode (process target) |
| 602 | "Major mode for irc channel buffers. | 602 | "Major mode for IRC channel buffers. |
| 603 | 603 | ||
| 604 | \\{rcirc-mode-map}" | 604 | \\{rcirc-mode-map}" |
| 605 | (kill-all-local-variables) | 605 | (kill-all-local-variables) |
| @@ -722,7 +722,7 @@ If ALL is non-nil, update prompts in all IRC buffers." | |||
| 722 | 722 | ||
| 723 | (defun rcirc-generate-new-buffer-name (process target) | 723 | (defun rcirc-generate-new-buffer-name (process target) |
| 724 | "Return a buffer name based on PROCESS and TARGET. | 724 | "Return a buffer name based on PROCESS and TARGET. |
| 725 | This is used for the initial name given to irc buffers." | 725 | This is used for the initial name given to IRC buffers." |
| 726 | (if target | 726 | (if target |
| 727 | (concat target "@" (process-name process)) | 727 | (concat target "@" (process-name process)) |
| 728 | (concat "*" (process-name process) "*"))) | 728 | (concat "*" (process-name process) "*"))) |
| @@ -985,7 +985,7 @@ record activity." | |||
| 985 | 1)) ; [ | 985 | 1)) ; [ |
| 986 | (t 3)) ; *** | 986 | (t 3)) ; *** |
| 987 | 1) | 987 | 1) |
| 988 | ? ))) | 988 | ?\s))) |
| 989 | (fill-column (cond ((eq rcirc-fill-column 'frame-width) | 989 | (fill-column (cond ((eq rcirc-fill-column 'frame-width) |
| 990 | (1- (frame-width))) | 990 | (1- (frame-width))) |
| 991 | (rcirc-fill-column | 991 | (rcirc-fill-column |
| @@ -1046,7 +1046,7 @@ record activity." | |||
| 1046 | process sender response target text))))) | 1046 | process sender response target text))))) |
| 1047 | 1047 | ||
| 1048 | (defun rcirc-startup-channels (server) | 1048 | (defun rcirc-startup-channels (server) |
| 1049 | "Return the list of startup channels for server." | 1049 | "Return the list of startup channels for SERVER." |
| 1050 | (let (channels) | 1050 | (let (channels) |
| 1051 | (dolist (i rcirc-startup-channels-alist) | 1051 | (dolist (i rcirc-startup-channels-alist) |
| 1052 | (if (string-match (car i) server) | 1052 | (if (string-match (car i) server) |
| @@ -1127,8 +1127,8 @@ record activity." | |||
| 1127 | (sort nicks (lambda (x y) (time-less-p (cdr y) (cdr x)))))))) | 1127 | (sort nicks (lambda (x y) (time-less-p (cdr y) (cdr x)))))))) |
| 1128 | 1128 | ||
| 1129 | (defun rcirc-ignore-update-automatic (nick) | 1129 | (defun rcirc-ignore-update-automatic (nick) |
| 1130 | "Remove NICK from `rcirc-ignore-list' | 1130 | "Remove NICK from `rcirc-ignore-list' |
| 1131 | if NICK is also on `rcirc-ignore-list-automatic'." | 1131 | if NICK is also on `rcirc-ignore-list-automatic'." |
| 1132 | (when (member nick rcirc-ignore-list-automatic) | 1132 | (when (member nick rcirc-ignore-list-automatic) |
| 1133 | (setq rcirc-ignore-list-automatic | 1133 | (setq rcirc-ignore-list-automatic |
| 1134 | (delete nick rcirc-ignore-list-automatic) | 1134 | (delete nick rcirc-ignore-list-automatic) |
| @@ -1375,14 +1375,14 @@ Also, clear the overlay arrow if the current buffer is now hidden." | |||
| 1375 | (when (not existing-buffer) | 1375 | (when (not existing-buffer) |
| 1376 | (rcirc-cmd-whois nick)))) | 1376 | (rcirc-cmd-whois nick)))) |
| 1377 | 1377 | ||
| 1378 | (defun-rcirc-command join (args) | 1378 | (defun-rcirc-command join (channel) |
| 1379 | "Join CHANNEL." | 1379 | "Join CHANNEL." |
| 1380 | (interactive "sJoin channel: ") | 1380 | (interactive "sJoin channel: ") |
| 1381 | (let* ((channel (car (split-string args))) | 1381 | (let ((buffer (rcirc-get-buffer-create process |
| 1382 | (buffer (rcirc-get-buffer-create process channel))) | 1382 | (car (split-string channel))))) |
| 1383 | (when (not (eq (selected-window) (minibuffer-window))) | 1383 | (when (not (eq (selected-window) (minibuffer-window))) |
| 1384 | (funcall rcirc-switch-to-buffer-function buffer)) | 1384 | (funcall rcirc-switch-to-buffer-function buffer)) |
| 1385 | (rcirc-send-string process (concat "JOIN " args)))) | 1385 | (rcirc-send-string process (concat "JOIN " channel)))) |
| 1386 | 1386 | ||
| 1387 | (defun-rcirc-command part (channel) | 1387 | (defun-rcirc-command part (channel) |
| 1388 | "Part CHANNEL." | 1388 | "Part CHANNEL." |
| @@ -1486,10 +1486,10 @@ With a prefix arg, prompt for new topic." | |||
| 1486 | "Manage the ignore list. | 1486 | "Manage the ignore list. |
| 1487 | Ignore NICK, unignore NICK if already ignored, or list ignored | 1487 | Ignore NICK, unignore NICK if already ignored, or list ignored |
| 1488 | nicks when no NICK is given. When listing ignored nicks, the | 1488 | nicks when no NICK is given. When listing ignored nicks, the |
| 1489 | ones added to the list automatically are marked with an asterix." | 1489 | ones added to the list automatically are marked with an asterisk." |
| 1490 | (interactive "sToggle ignoring of nick: ") | 1490 | (interactive "sToggle ignoring of nick: ") |
| 1491 | (if (string= "" nick) | 1491 | (if (string= "" nick) |
| 1492 | (rcirc-print process (rcirc-nick process) "NOTICE" target | 1492 | (rcirc-print process (rcirc-nick process) "NOTICE" target |
| 1493 | (mapconcat | 1493 | (mapconcat |
| 1494 | (lambda (nick) | 1494 | (lambda (nick) |
| 1495 | (concat nick | 1495 | (concat nick |
| @@ -1511,19 +1511,19 @@ ones added to the list automatically are marked with an asterix." | |||
| 1511 | (propertize (or string "") 'face face 'rear-nonsticky t)) | 1511 | (propertize (or string "") 'face face 'rear-nonsticky t)) |
| 1512 | 1512 | ||
| 1513 | (defvar rcirc-url-regexp | 1513 | (defvar rcirc-url-regexp |
| 1514 | (rx word-boundary | 1514 | (rx word-boundary |
| 1515 | (or "www." | 1515 | (or "www." |
| 1516 | (and (or "http" "https" "ftp" "file" "gopher" "news" "telnet" "wais" | 1516 | (and (or "http" "https" "ftp" "file" "gopher" "news" "telnet" "wais" |
| 1517 | "mailto") | 1517 | "mailto") |
| 1518 | "://" | 1518 | "://" |
| 1519 | (1+ (char "a-zA-Z0-9_.")) | 1519 | (1+ (char "a-zA-Z0-9_.")) |
| 1520 | (optional ":" (1+ (char "0-9"))))) | 1520 | (optional ":" (1+ (char "0-9"))))) |
| 1521 | (1+ (char "-a-zA-Z0-9_=!?#$\@~`%&*+|\\/:;.,")) | 1521 | (1+ (char "-a-zA-Z0-9_=!?#$\@~`%&*+|\\/:;.,")) |
| 1522 | (char "-a-zA-Z0-9_=!?#$\@~`%&*+|\\/:;")) | 1522 | (char "-a-zA-Z0-9_=!?#$\@~`%&*+|\\/:;")) |
| 1523 | "Regexp matching URL's. Set to nil to disable URL features in rcirc.") | 1523 | "Regexp matching URLs. Set to nil to disable URL features in rcirc.") |
| 1524 | 1524 | ||
| 1525 | (defun rcirc-browse-url (&optional arg) | 1525 | (defun rcirc-browse-url (&optional arg) |
| 1526 | "Prompt for url to browse based on urls in buffer." | 1526 | "Prompt for URL to browse based on URLs in buffer." |
| 1527 | (interactive) | 1527 | (interactive) |
| 1528 | (let ((completions (mapcar (lambda (x) (cons x nil)) rcirc-urls)) | 1528 | (let ((completions (mapcar (lambda (x) (cons x nil)) rcirc-urls)) |
| 1529 | (initial-input (car rcirc-urls)) | 1529 | (initial-input (car rcirc-urls)) |
| @@ -1559,13 +1559,13 @@ FUNCTION takes 3 arguments, MATCH-START, MATCH-END, and STRING." | |||
| 1559 | "Return TEXT with properties added based on various patterns." | 1559 | "Return TEXT with properties added based on various patterns." |
| 1560 | ;; ^B | 1560 | ;; ^B |
| 1561 | (setq text | 1561 | (setq text |
| 1562 | (rcirc-map-regexp | 1562 | (rcirc-map-regexp |
| 1563 | (lambda (start end string) | 1563 | (lambda (start end string) |
| 1564 | (let ((orig-face (get-text-property start 'face string))) | 1564 | (let ((orig-face (get-text-property start 'face string))) |
| 1565 | (add-text-properties | 1565 | (add-text-properties |
| 1566 | start end | 1566 | start end |
| 1567 | (list 'face (if (listp orig-face) | 1567 | (list 'face (if (listp orig-face) |
| 1568 | (append orig-face | 1568 | (append orig-face |
| 1569 | (list 'bold)) | 1569 | (list 'bold)) |
| 1570 | (list orig-face 'bold)) | 1570 | (list orig-face 'bold)) |
| 1571 | 'rear-nonsticky t) | 1571 | 'rear-nonsticky t) |
| @@ -1573,7 +1573,7 @@ FUNCTION takes 3 arguments, MATCH-START, MATCH-END, and STRING." | |||
| 1573 | ".*?" | 1573 | ".*?" |
| 1574 | text)) | 1574 | text)) |
| 1575 | ;; TODO: deal with ^_ and ^C colors sequences | 1575 | ;; TODO: deal with ^_ and ^C colors sequences |
| 1576 | (while (string-match "\\(.*\\)[]\\(.*\\)" text) | 1576 | (while (string-match "\\(.*\\)[]\\(.*\\)" text) |
| 1577 | (setq text (concat (match-string 1 text) | 1577 | (setq text (concat (match-string 1 text) |
| 1578 | (match-string 2 text)))) | 1578 | (match-string 2 text)))) |
| 1579 | ;; my nick | 1579 | ;; my nick |
| @@ -1596,7 +1596,7 @@ FUNCTION takes 3 arguments, MATCH-START, MATCH-END, and STRING." | |||
| 1596 | (let ((orig-face (get-text-property start 'face string))) | 1596 | (let ((orig-face (get-text-property start 'face string))) |
| 1597 | (add-text-properties start end | 1597 | (add-text-properties start end |
| 1598 | (list 'face (if (listp orig-face) | 1598 | (list 'face (if (listp orig-face) |
| 1599 | (append orig-face | 1599 | (append orig-face |
| 1600 | (list 'bold)) | 1600 | (list 'bold)) |
| 1601 | (list orig-face 'bold)) | 1601 | (list orig-face 'bold)) |
| 1602 | 'rear-nonsticky t | 1602 | 'rear-nonsticky t |
| @@ -1991,7 +1991,7 @@ Passwords are read from `rcirc-authinfo-file-name' (which see)." | |||
| 1991 | '((((min-colors 88) (background dark)) (:foreground "cyan1")) | 1991 | '((((min-colors 88) (background dark)) (:foreground "cyan1")) |
| 1992 | (((background dark)) (:foreground "cyan")) | 1992 | (((background dark)) (:foreground "cyan")) |
| 1993 | (t (:foreground "dark blue"))) | 1993 | (t (:foreground "dark blue"))) |
| 1994 | "The face to use to highlight prompts." | 1994 | "The face used to highlight prompts." |
| 1995 | :group 'rcirc-faces) | 1995 | :group 'rcirc-faces) |
| 1996 | 1996 | ||
| 1997 | (defface rcirc-mode-line-nick | 1997 | (defface rcirc-mode-line-nick |
diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index 10a5dd9eedf..5ff8a0832bc 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el | |||
| @@ -6766,13 +6766,14 @@ If `tramp-discard-garbage' is nil, just erase buffer." | |||
| 6766 | "Convert file-attributes ATTR generated by perl script or ls. | 6766 | "Convert file-attributes ATTR generated by perl script or ls. |
| 6767 | Convert file mode bits to string and set virtual device number. | 6767 | Convert file mode bits to string and set virtual device number. |
| 6768 | Return ATTR." | 6768 | Return ATTR." |
| 6769 | ;; Convert file mode bits to string. | ||
| 6769 | (unless (stringp (nth 8 attr)) | 6770 | (unless (stringp (nth 8 attr)) |
| 6770 | ;; Convert file mode bits to string. | ||
| 6771 | (setcar (nthcdr 8 attr) (tramp-file-mode-from-int (nth 8 attr)))) | 6771 | (setcar (nthcdr 8 attr) (tramp-file-mode-from-int (nth 8 attr)))) |
| 6772 | ;; Set file's gid change bit. | 6772 | ;; Set file's gid change bit. Possible only when id-format is 'integer. |
| 6773 | (setcar (nthcdr 9 attr) | 6773 | (when (numberp (nth 3 attr)) |
| 6774 | (not (= (nth 3 attr) | 6774 | (setcar (nthcdr 9 attr) |
| 6775 | (tramp-get-remote-gid multi-method method user host)))) | 6775 | (not (= (nth 3 attr) |
| 6776 | (tramp-get-remote-gid multi-method method user host))))) | ||
| 6776 | ;; Set virtual device number. | 6777 | ;; Set virtual device number. |
| 6777 | (setcar (nthcdr 11 attr) | 6778 | (setcar (nthcdr 11 attr) |
| 6778 | (tramp-get-device multi-method method user host)) | 6779 | (tramp-get-device multi-method method user host)) |
diff --git a/lisp/newcomment.el b/lisp/newcomment.el index 9995b4b9156..5fa9ac09b0b 100644 --- a/lisp/newcomment.el +++ b/lisp/newcomment.el | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | ;;; newcomment.el --- (un)comment regions of buffers | 1 | ;;; newcomment.el --- (un)comment regions of buffers |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1999, 2000, 2002, 2003, 2004, | 3 | ;; Copyright (C) 1999, 2000, 2002, 2003, 2004, |
| 4 | ;; 2005 Free Software Foundation, Inc. | 4 | ;; 2005, 2006 Free Software Foundation, Inc. |
| 5 | 5 | ||
| 6 | ;; Author: code extracted from Emacs-20's simple.el | 6 | ;; Author: code extracted from Emacs-20's simple.el |
| 7 | ;; Maintainer: Stefan Monnier <monnier@iro.umontreal.ca> | 7 | ;; Maintainer: Stefan Monnier <monnier@iro.umontreal.ca> |
| @@ -96,7 +96,7 @@ Major modes should set this variable.") | |||
| 96 | 96 | ||
| 97 | ;;;###autoload | 97 | ;;;###autoload |
| 98 | (defcustom comment-column 32 | 98 | (defcustom comment-column 32 |
| 99 | "*Column to indent right-margin comments to. | 99 | "Column to indent right-margin comments to. |
| 100 | Each mode establishes a different default value for this variable; you | 100 | Each mode establishes a different default value for this variable; you |
| 101 | can set the value for a particular mode using that mode's hook. | 101 | can set the value for a particular mode using that mode's hook. |
| 102 | Comments might be indented to a value smaller than this in order | 102 | Comments might be indented to a value smaller than this in order |
| @@ -200,7 +200,7 @@ INDENT specifies that the `comment-start' markers should not be put at the | |||
| 200 | 200 | ||
| 201 | ;;;###autoload | 201 | ;;;###autoload |
| 202 | (defcustom comment-style 'plain | 202 | (defcustom comment-style 'plain |
| 203 | "*Style to be used for `comment-region'. | 203 | "Style to be used for `comment-region'. |
| 204 | See `comment-styles' for a list of available styles." | 204 | See `comment-styles' for a list of available styles." |
| 205 | :type (if (boundp 'comment-styles) | 205 | :type (if (boundp 'comment-styles) |
| 206 | `(choice ,@(mapcar (lambda (s) `(const ,(car s))) comment-styles)) | 206 | `(choice ,@(mapcar (lambda (s) `(const ,(car s))) comment-styles)) |
| @@ -220,7 +220,7 @@ makes the comment easier to read. Default is 1. nil means 0." | |||
| 220 | 220 | ||
| 221 | ;;;###autoload | 221 | ;;;###autoload |
| 222 | (defcustom comment-multi-line nil | 222 | (defcustom comment-multi-line nil |
| 223 | "*Non-nil means `comment-indent-new-line' continues comments. | 223 | "Non-nil means `comment-indent-new-line' continues comments. |
| 224 | That is, it inserts no new terminator or starter. | 224 | That is, it inserts no new terminator or starter. |
| 225 | This affects `auto-fill-mode', which is the main reason to | 225 | This affects `auto-fill-mode', which is the main reason to |
| 226 | customize this variable. | 226 | customize this variable. |
| @@ -1081,7 +1081,8 @@ If the region is active and `transient-mark-mode' is on, call | |||
| 1081 | case it calls `uncomment-region'). | 1081 | case it calls `uncomment-region'). |
| 1082 | Else, if the current line is empty, insert a comment and indent it. | 1082 | Else, if the current line is empty, insert a comment and indent it. |
| 1083 | Else if a prefix ARG is specified, call `comment-kill'. | 1083 | Else if a prefix ARG is specified, call `comment-kill'. |
| 1084 | Else, call `comment-indent'." | 1084 | Else, call `comment-indent'. |
| 1085 | You can configure `comment-style' to change the way regions are commented." | ||
| 1085 | (interactive "*P") | 1086 | (interactive "*P") |
| 1086 | (comment-normalize-vars) | 1087 | (comment-normalize-vars) |
| 1087 | (if (and mark-active transient-mark-mode) | 1088 | (if (and mark-active transient-mark-mode) |
diff --git a/lisp/replace.el b/lisp/replace.el index 8a17104c599..92b4be7fd7b 100644 --- a/lisp/replace.el +++ b/lisp/replace.el | |||
| @@ -1004,7 +1004,7 @@ See also `multi-occur'." | |||
| 1004 | (let* ((default (car regexp-history)) | 1004 | (let* ((default (car regexp-history)) |
| 1005 | (input | 1005 | (input |
| 1006 | (read-from-minibuffer | 1006 | (read-from-minibuffer |
| 1007 | (if allbufs | 1007 | (if current-prefix-arg |
| 1008 | "List lines in buffers whose names match regexp: " | 1008 | "List lines in buffers whose names match regexp: " |
| 1009 | "List lines in buffers whose filenames match regexp: ") | 1009 | "List lines in buffers whose filenames match regexp: ") |
| 1010 | nil | 1010 | nil |
| @@ -1016,7 +1016,7 @@ See also `multi-occur'." | |||
| 1016 | input)) | 1016 | input)) |
| 1017 | (occur-read-primary-args))) | 1017 | (occur-read-primary-args))) |
| 1018 | (when bufregexp | 1018 | (when bufregexp |
| 1019 | (occur-1 regexp nlines | 1019 | (occur-1 regexp nil |
| 1020 | (delq nil | 1020 | (delq nil |
| 1021 | (mapcar (lambda (buf) | 1021 | (mapcar (lambda (buf) |
| 1022 | (when (if allbufs | 1022 | (when (if allbufs |
diff --git a/lisp/savehist.el b/lisp/savehist.el index ef75369c761..6c6d936af6a 100644 --- a/lisp/savehist.el +++ b/lisp/savehist.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; savehist.el --- Save minibuffer history. | 1 | ;;; savehist.el --- Save minibuffer history. |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1997,2005 Free Software Foundation | 3 | ;; Copyright (C) 1997, 2005 Free Software Foundation |
| 4 | 4 | ||
| 5 | ;; Author: Hrvoje Niksic <hniksic@xemacs.org> | 5 | ;; Author: Hrvoje Niksic <hniksic@xemacs.org> |
| 6 | ;; Keywords: minibuffer | 6 | ;; Keywords: minibuffer |
| @@ -171,7 +171,7 @@ buffer text.") | |||
| 171 | 171 | ||
| 172 | (defvar savehist-loaded nil | 172 | (defvar savehist-loaded nil |
| 173 | "Whether the history has already been loaded. | 173 | "Whether the history has already been loaded. |
| 174 | This prevents toggling savehist-mode from destroying existing | 174 | This prevents toggling `savehist-mode' from destroying existing |
| 175 | minibuffer history.") | 175 | minibuffer history.") |
| 176 | 176 | ||
| 177 | (when (featurep 'xemacs) | 177 | (when (featurep 'xemacs) |
| @@ -226,9 +226,9 @@ which is probably undesirable." | |||
| 226 | Don't call this from new code, use (savehist-mode 1) instead. | 226 | Don't call this from new code, use (savehist-mode 1) instead. |
| 227 | 227 | ||
| 228 | This function loads the variables stored in `savehist-file' and turns on | 228 | This function loads the variables stored in `savehist-file' and turns on |
| 229 | savehist-mode. If savehist-file is in the old format that doesn't record | 229 | `savehist-mode'. If `savehist-file' is in the old format that doesn't |
| 230 | the value of `savehist-minibuffer-history-variables', that value is | 230 | record the value of `savehist-minibuffer-history-variables', that value |
| 231 | deducted from the contents of the file." | 231 | is deducted from the contents of the file." |
| 232 | (savehist-mode 1) | 232 | (savehist-mode 1) |
| 233 | ;; Old versions of savehist distributed with XEmacs didn't save | 233 | ;; Old versions of savehist distributed with XEmacs didn't save |
| 234 | ;; savehist-minibuffer-history-variables. If that variable is nil | 234 | ;; savehist-minibuffer-history-variables. If that variable is nil |
| @@ -250,8 +250,8 @@ deducted from the contents of the file." | |||
| 250 | (defun savehist-install () | 250 | (defun savehist-install () |
| 251 | "Hook savehist into Emacs. | 251 | "Hook savehist into Emacs. |
| 252 | Normally invoked by calling `savehist-mode' to set the minor mode. | 252 | Normally invoked by calling `savehist-mode' to set the minor mode. |
| 253 | Installs `savehist-autosave' in `kill-emacs-hook' and on a timer. To | 253 | Installs `savehist-autosave' in `kill-emacs-hook' and on a timer. |
| 254 | undo this, call `savehist-uninstall'." | 254 | To undo this, call `savehist-uninstall'." |
| 255 | (add-hook 'minibuffer-setup-hook 'savehist-minibuffer-hook) | 255 | (add-hook 'minibuffer-setup-hook 'savehist-minibuffer-hook) |
| 256 | (add-hook 'kill-emacs-hook 'savehist-autosave) | 256 | (add-hook 'kill-emacs-hook 'savehist-autosave) |
| 257 | ;; Install an invocation of savehist-autosave on a timer. This | 257 | ;; Install an invocation of savehist-autosave on a timer. This |
| @@ -333,14 +333,14 @@ If AUTO-SAVE is non-nil, compare the saved contents to the one last saved, | |||
| 333 | 333 | ||
| 334 | (defun savehist-autosave () | 334 | (defun savehist-autosave () |
| 335 | "Save the minibuffer history if it has been modified since the last save. | 335 | "Save the minibuffer history if it has been modified since the last save. |
| 336 | Does nothing if savehist-mode is off." | 336 | Does nothing if `savehist-mode' is off." |
| 337 | (when savehist-mode | 337 | (when savehist-mode |
| 338 | (savehist-save t))) | 338 | (savehist-save t))) |
| 339 | 339 | ||
| 340 | (defun savehist-trim-history (value) | 340 | (defun savehist-trim-history (value) |
| 341 | "Retain only the first history-length items in VALUE. | 341 | "Retain only the first `history-length' items in VALUE. |
| 342 | Only used under XEmacs, which doesn't (yet) implement automatic | 342 | Only used under XEmacs, which doesn't (yet) implement automatic |
| 343 | trimming of history lists to history-length items." | 343 | trimming of history lists to `history-length' items." |
| 344 | (if (and (featurep 'xemacs) | 344 | (if (and (featurep 'xemacs) |
| 345 | (natnump history-length) | 345 | (natnump history-length) |
| 346 | (> (length value) history-length)) | 346 | (> (length value) history-length)) |
diff --git a/lisp/simple.el b/lisp/simple.el index 429428f0350..67225f07f94 100644 --- a/lisp/simple.el +++ b/lisp/simple.el | |||
| @@ -3743,7 +3743,7 @@ To ignore intangibility, bind `inhibit-point-motion-hooks' to t." | |||
| 3743 | ;; Move to beginning-of-line, ignoring fields and invisibles. | 3743 | ;; Move to beginning-of-line, ignoring fields and invisibles. |
| 3744 | (skip-chars-backward "^\n") | 3744 | (skip-chars-backward "^\n") |
| 3745 | (while (and (not (bobp)) (line-move-invisible-p (1- (point)))) | 3745 | (while (and (not (bobp)) (line-move-invisible-p (1- (point)))) |
| 3746 | (goto-char (previous-char-property-change (1- (point)))) | 3746 | (goto-char (previous-char-property-change (point))) |
| 3747 | (skip-chars-backward "^\n")) | 3747 | (skip-chars-backward "^\n")) |
| 3748 | 3748 | ||
| 3749 | ;; Take care of fields. | 3749 | ;; Take care of fields. |
diff --git a/lisp/textmodes/nroff-mode.el b/lisp/textmodes/nroff-mode.el index 7fd2db1deb6..ababc041099 100644 --- a/lisp/textmodes/nroff-mode.el +++ b/lisp/textmodes/nroff-mode.el | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | ;;; nroff-mode.el --- GNU Emacs major mode for editing nroff source | 1 | ;;; nroff-mode.el --- GNU Emacs major mode for editing nroff source |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1985, 1986, 1994, 1995, 1997, 2001, 2002, 2003, | 3 | ;; Copyright (C) 1985, 1986, 1994, 1995, 1997, 2001, 2002, 2003, |
| 4 | ;; 2004, 2005 Free Software Foundation, Inc. | 4 | ;; 2004, 2005, 2006 Free Software Foundation, Inc. |
| 5 | 5 | ||
| 6 | ;; Maintainer: FSF | 6 | ;; Maintainer: FSF |
| 7 | ;; Keywords: wp | 7 | ;; Keywords: wp |
| @@ -86,14 +86,14 @@ | |||
| 86 | ;; variants). This won't currently do groff's \A'foo' and | 86 | ;; variants). This won't currently do groff's \A'foo' and |
| 87 | ;; the like properly. One might expect it to highlight an escape's | 87 | ;; the like properly. One might expect it to highlight an escape's |
| 88 | ;; arguments in common cases, like \f. | 88 | ;; arguments in common cases, like \f. |
| 89 | (concat "\\\\" ; backslash | 89 | (concat "\\\\" ; backslash |
| 90 | "\\(" ; followed by various possibilities | 90 | "\\(" ; followed by various possibilities |
| 91 | (mapconcat 'identity | 91 | (mapconcat 'identity |
| 92 | '("[f*n]*\\[.+]" ; some groff extensions | 92 | '("[f*n]*\\[.+?]" ; some groff extensions |
| 93 | "(.." ; two chars after ( | 93 | "(.." ; two chars after ( |
| 94 | "[^(\"]" ; single char escape | 94 | "[^(\"]" ; single char escape |
| 95 | ) "\\|") | 95 | ) "\\|") |
| 96 | "\\)") | 96 | "\\)") |
| 97 | ) | 97 | ) |
| 98 | "Font-lock highlighting control in `nroff-mode'." | 98 | "Font-lock highlighting control in `nroff-mode'." |
| 99 | :group 'nroff | 99 | :group 'nroff |
diff --git a/lisp/textmodes/table.el b/lisp/textmodes/table.el index db8d2c94c46..6c9463fe11e 100644 --- a/lisp/textmodes/table.el +++ b/lisp/textmodes/table.el | |||
| @@ -4076,7 +4076,7 @@ fit in the cell width the word is folded into the next line. The | |||
| 4076 | folded location is marked by a continuation character which is | 4076 | folded location is marked by a continuation character which is |
| 4077 | specified in the variable `table-word-continuation-char'. | 4077 | specified in the variable `table-word-continuation-char'. |
| 4078 | ") | 4078 | ") |
| 4079 | (help-print-return-message)))) | 4079 | (print-help-return-message)))) |
| 4080 | 4080 | ||
| 4081 | (defun *table--cell-describe-bindings () | 4081 | (defun *table--cell-describe-bindings () |
| 4082 | "Table cell version of `describe-bindings'." | 4082 | "Table cell version of `describe-bindings'." |
| @@ -4094,7 +4094,7 @@ key binding | |||
| 4094 | (key-description (car binding)) | 4094 | (key-description (car binding)) |
| 4095 | (cdr binding)))) | 4095 | (cdr binding)))) |
| 4096 | table-cell-bindings) | 4096 | table-cell-bindings) |
| 4097 | (help-print-return-message)))) | 4097 | (print-help-return-message)))) |
| 4098 | 4098 | ||
| 4099 | (defun *table--cell-dabbrev-expand (arg) | 4099 | (defun *table--cell-dabbrev-expand (arg) |
| 4100 | "Table cell version of `dabbrev-expand'." | 4100 | "Table cell version of `dabbrev-expand'." |
diff --git a/lisp/xml.el b/lisp/xml.el index 5b83f4d3479..c97c8052148 100644 --- a/lisp/xml.el +++ b/lisp/xml.el | |||
| @@ -188,62 +188,62 @@ If PARSE-NS is non-nil, then QNAMES are expanded." | |||
| 188 | (defvar xml-att-def-re) | 188 | (defvar xml-att-def-re) |
| 189 | (let* ((start-chars (concat "[:alpha:]:_")) | 189 | (let* ((start-chars (concat "[:alpha:]:_")) |
| 190 | (name-chars (concat "-[:digit:]." start-chars)) | 190 | (name-chars (concat "-[:digit:]." start-chars)) |
| 191 | ;;[3] S ::= (#x20 | #x9 | #xD | #xA)+ | 191 | ;;[3] S ::= (#x20 | #x9 | #xD | #xA)+ |
| 192 | (whitespace "[ \t\n\r]")) | 192 | (whitespace "[ \t\n\r]")) |
| 193 | ;;[4] NameStartChar ::= ":" | [A-Z] | "_" | [a-z] | [#xC0-#xD6] | 193 | ;;[4] NameStartChar ::= ":" | [A-Z] | "_" | [a-z] | [#xC0-#xD6] |
| 194 | ;; | [#xD8-#xF6] | [#xF8-#x2FF] | [#x370-#x37D] | [#x37F-#x1FFF] | 194 | ;; | [#xD8-#xF6] | [#xF8-#x2FF] | [#x370-#x37D] | [#x37F-#x1FFF] |
| 195 | ;; | [#x200C-#x200D] | [#x2070-#x218F] | [#x2C00-#x2FEF] | [#x3001-#xD7FF] | 195 | ;; | [#x200C-#x200D] | [#x2070-#x218F] | [#x2C00-#x2FEF] | [#x3001-#xD7FF] |
| 196 | ;; | [#xF900-#xFDCF] | [#xFDF0-#xFFFD] | [#x10000-#xEFFFF] | 196 | ;; | [#xF900-#xFDCF] | [#xFDF0-#xFFFD] | [#x10000-#xEFFFF] |
| 197 | (defvar xml-name-start-char-re (concat "[" start-chars "]")) | 197 | (defvar xml-name-start-char-re (concat "[" start-chars "]")) |
| 198 | ;;[4a] NameChar ::= NameStartChar | "-" | "." | [0-9] | #xB7 | [#x0300-#x036F] | [#x203F-#x2040] | 198 | ;;[4a] NameChar ::= NameStartChar | "-" | "." | [0-9] | #xB7 | [#x0300-#x036F] | [#x203F-#x2040] |
| 199 | (defvar xml-name-char-re (concat "[" name-chars "]")) | 199 | (defvar xml-name-char-re (concat "[" name-chars "]")) |
| 200 | ;;[5] Name ::= NameStartChar (NameChar)* | 200 | ;;[5] Name ::= NameStartChar (NameChar)* |
| 201 | (defvar xml-name-re (concat xml-name-start-char-re xml-name-char-re "*")) | 201 | (defvar xml-name-re (concat xml-name-start-char-re xml-name-char-re "*")) |
| 202 | ;;[6] Names ::= Name (#x20 Name)* | 202 | ;;[6] Names ::= Name (#x20 Name)* |
| 203 | (defvar xml-names-re (concat xml-name-re "\\(?: " xml-name-re "\\)*")) | 203 | (defvar xml-names-re (concat xml-name-re "\\(?: " xml-name-re "\\)*")) |
| 204 | ;;[7] Nmtoken ::= (NameChar)+ | 204 | ;;[7] Nmtoken ::= (NameChar)+ |
| 205 | (defvar xml-nmtoken-re (concat xml-name-char-re "+")) | 205 | (defvar xml-nmtoken-re (concat xml-name-char-re "+")) |
| 206 | ;;[8] Nmtokens ::= Nmtoken (#x20 Nmtoken)* | 206 | ;;[8] Nmtokens ::= Nmtoken (#x20 Nmtoken)* |
| 207 | (defvar xml-nmtokens-re (concat xml-nmtoken-re "\\(?: " xml-name-re "\\)*")) | 207 | (defvar xml-nmtokens-re (concat xml-nmtoken-re "\\(?: " xml-name-re "\\)*")) |
| 208 | ;;[66] CharRef ::= '&#' [0-9]+ ';' | '&#x' [0-9a-fA-F]+ ';' | 208 | ;;[66] CharRef ::= '&#' [0-9]+ ';' | '&#x' [0-9a-fA-F]+ ';' |
| 209 | (defvar xml-char-ref-re "\\(?:&#[0-9]+;\\|&#x[0-9a-fA-F]+;\\)") | 209 | (defvar xml-char-ref-re "\\(?:&#[0-9]+;\\|&#x[0-9a-fA-F]+;\\)") |
| 210 | ;;[68] EntityRef ::= '&' Name ';' | 210 | ;;[68] EntityRef ::= '&' Name ';' |
| 211 | (defvar xml-entity-ref (concat "&" xml-name-re ";")) | 211 | (defvar xml-entity-ref (concat "&" xml-name-re ";")) |
| 212 | ;;[69] PEReference ::= '%' Name ';' | 212 | ;;[69] PEReference ::= '%' Name ';' |
| 213 | (defvar xml-pe-reference-re (concat "%" xml-name-re ";")) | 213 | (defvar xml-pe-reference-re (concat "%" xml-name-re ";")) |
| 214 | ;;[67] Reference ::= EntityRef | CharRef | 214 | ;;[67] Reference ::= EntityRef | CharRef |
| 215 | (defvar xml-reference-re (concat "\\(?:" xml-entity-ref "\\|" xml-char-ref-re "\\)")) | 215 | (defvar xml-reference-re (concat "\\(?:" xml-entity-ref "\\|" xml-char-ref-re "\\)")) |
| 216 | ;;[10] AttValue ::= '"' ([^<&"] | Reference)* '"' | "'" ([^<&'] | Reference)* "'" | 216 | ;;[10] AttValue ::= '"' ([^<&"] | Reference)* '"' | "'" ([^<&'] | Reference)* "'" |
| 217 | (defvar xml-att-value-re (concat "\\(?:\"\\(?:[^&\"]\\|" xml-reference-re "\\)*\"\\|" | 217 | (defvar xml-att-value-re (concat "\\(?:\"\\(?:[^&\"]\\|" xml-reference-re "\\)*\"\\|" |
| 218 | "'\\(?:[^&']\\|" xml-reference-re "\\)*'\\)")) | 218 | "'\\(?:[^&']\\|" xml-reference-re "\\)*'\\)")) |
| 219 | ;;[56] TokenizedType ::= 'ID' [VC: ID] [VC: One ID per Element Type] [VC: ID Attribute Default] | 219 | ;;[56] TokenizedType ::= 'ID' [VC: ID] [VC: One ID per Element Type] [VC: ID Attribute Default] |
| 220 | ;; | 'IDREF' [VC: IDREF] | 220 | ;; | 'IDREF' [VC: IDREF] |
| 221 | ;; | 'IDREFS' [VC: IDREF] | 221 | ;; | 'IDREFS' [VC: IDREF] |
| 222 | ;; | 'ENTITY' [VC: Entity Name] | 222 | ;; | 'ENTITY' [VC: Entity Name] |
| 223 | ;; | 'ENTITIES' [VC: Entity Name] | 223 | ;; | 'ENTITIES' [VC: Entity Name] |
| 224 | ;; | 'NMTOKEN' [VC: Name Token] | 224 | ;; | 'NMTOKEN' [VC: Name Token] |
| 225 | ;; | 'NMTOKENS' [VC: Name Token] | 225 | ;; | 'NMTOKENS' [VC: Name Token] |
| 226 | (defvar xml-tokenized-type-re "\\(?:ID\\|IDREF\\|IDREFS\\|ENTITY\\|ENTITIES\\|NMTOKEN\\|NMTOKENS\\)") | 226 | (defvar xml-tokenized-type-re "\\(?:ID\\|IDREF\\|IDREFS\\|ENTITY\\|ENTITIES\\|NMTOKEN\\|NMTOKENS\\)") |
| 227 | ;;[58] NotationType ::= 'NOTATION' S '(' S? Name (S? '|' S? Name)* S? ')' | 227 | ;;[58] NotationType ::= 'NOTATION' S '(' S? Name (S? '|' S? Name)* S? ')' |
| 228 | (defvar xml-notation-type-re (concat "\\(?:NOTATION" whitespace "(" whitespace "*" xml-name-re | 228 | (defvar xml-notation-type-re (concat "\\(?:NOTATION" whitespace "(" whitespace "*" xml-name-re |
| 229 | "\\(?:" whitespace "*|" whitespace "*" xml-name-re "\\)*" whitespace "*)\\)")) | 229 | "\\(?:" whitespace "*|" whitespace "*" xml-name-re "\\)*" whitespace "*)\\)")) |
| 230 | ;;[59] Enumeration ::= '(' S? Nmtoken (S? '|' S? Nmtoken)* S? ')' [VC: Enumeration] [VC: No Duplicate Tokens] | 230 | ;;[59] Enumeration ::= '(' S? Nmtoken (S? '|' S? Nmtoken)* S? ')' [VC: Enumeration] [VC: No Duplicate Tokens] |
| 231 | (defvar xml-enumeration-re (concat "\\(?:(" whitespace "*" xml-nmtoken-re | 231 | (defvar xml-enumeration-re (concat "\\(?:(" whitespace "*" xml-nmtoken-re |
| 232 | "\\(?:" whitespace "*|" whitespace "*" xml-nmtoken-re "\\)*" | 232 | "\\(?:" whitespace "*|" whitespace "*" xml-nmtoken-re "\\)*" |
| 233 | whitespace ")\\)")) | 233 | whitespace ")\\)")) |
| 234 | ;;[57] EnumeratedType ::= NotationType | Enumeration | 234 | ;;[57] EnumeratedType ::= NotationType | Enumeration |
| 235 | (defvar xml-enumerated-type-re (concat "\\(?:" xml-notation-type-re "\\|" xml-enumeration-re "\\)")) | 235 | (defvar xml-enumerated-type-re (concat "\\(?:" xml-notation-type-re "\\|" xml-enumeration-re "\\)")) |
| 236 | ;;[54] AttType ::= StringType | TokenizedType | EnumeratedType | 236 | ;;[54] AttType ::= StringType | TokenizedType | EnumeratedType |
| 237 | ;;[55] StringType ::= 'CDATA' | 237 | ;;[55] StringType ::= 'CDATA' |
| 238 | (defvar xml-att-type-re (concat "\\(?:CDATA\\|" xml-tokenized-type-re "\\|" xml-notation-type-re"\\|" xml-enumerated-type-re "\\)")) | 238 | (defvar xml-att-type-re (concat "\\(?:CDATA\\|" xml-tokenized-type-re "\\|" xml-notation-type-re"\\|" xml-enumerated-type-re "\\)")) |
| 239 | ;;[60] DefaultDecl ::= '#REQUIRED' | '#IMPLIED' | (('#FIXED' S)? AttValue) | 239 | ;;[60] DefaultDecl ::= '#REQUIRED' | '#IMPLIED' | (('#FIXED' S)? AttValue) |
| 240 | (defvar xml-default-decl-re (concat "\\(?:#REQUIRED\\|#IMPLIED\\|\\(?:#FIXED" whitespace "\\)*" xml-att-value-re "\\)")) | 240 | (defvar xml-default-decl-re (concat "\\(?:#REQUIRED\\|#IMPLIED\\|\\(?:#FIXED" whitespace "\\)*" xml-att-value-re "\\)")) |
| 241 | ;;[53] AttDef ::= S Name S AttType S DefaultDecl | 241 | ;;[53] AttDef ::= S Name S AttType S DefaultDecl |
| 242 | (defvar xml-att-def-re (concat "\\(?:" whitespace "*" xml-name-re | 242 | (defvar xml-att-def-re (concat "\\(?:" whitespace "*" xml-name-re |
| 243 | whitespace "*" xml-att-type-re | 243 | whitespace "*" xml-att-type-re |
| 244 | whitespace "*" xml-default-decl-re "\\)")) | 244 | whitespace "*" xml-default-decl-re "\\)")) |
| 245 | ;;[9] EntityValue ::= '"' ([^%&"] | PEReference | Reference)* '"' | 245 | ;;[9] EntityValue ::= '"' ([^%&"] | PEReference | Reference)* '"' |
| 246 | ;; | "'" ([^%&'] | PEReference | Reference)* "'" | 246 | ;; | "'" ([^%&'] | PEReference | Reference)* "'" |
| 247 | (defvar xml-entity-value-re (concat "\\(?:\"\\(?:[^%&\"]\\|" xml-pe-reference-re | 247 | (defvar xml-entity-value-re (concat "\\(?:\"\\(?:[^%&\"]\\|" xml-pe-reference-re |
| 248 | "\\|" xml-reference-re "\\)*\"\\|'\\(?:[^%&']\\|" | 248 | "\\|" xml-reference-re "\\)*\"\\|'\\(?:[^%&']\\|" |
| 249 | xml-pe-reference-re "\\|" xml-reference-re "\\)*'\\)"))) | 249 | xml-pe-reference-re "\\|" xml-reference-re "\\)*'\\)"))) |
| @@ -269,7 +269,7 @@ If PARSE-NS is non-nil, then QNAMES are expanded." | |||
| 269 | ;; Get space syntax correct per XML [3]. | 269 | ;; Get space syntax correct per XML [3]. |
| 270 | (dotimes (c 31) | 270 | (dotimes (c 31) |
| 271 | (modify-syntax-entry c "." table)) ; all are space in standard table | 271 | (modify-syntax-entry c "." table)) ; all are space in standard table |
| 272 | (dolist (c '(?\t ?\n ?\r)) ; these should be space | 272 | (dolist (c '(?\t ?\n ?\r)) ; these should be space |
| 273 | (modify-syntax-entry c " " table)) | 273 | (modify-syntax-entry c " " table)) |
| 274 | ;; For skipping attributes. | 274 | ;; For skipping attributes. |
| 275 | (modify-syntax-entry ?\" "\"" table) | 275 | (modify-syntax-entry ?\" "\"" table) |
| @@ -306,16 +306,16 @@ is not well-formed XML. | |||
| 306 | If PARSE-DTD is non-nil, the DTD is parsed rather than skipped, | 306 | If PARSE-DTD is non-nil, the DTD is parsed rather than skipped, |
| 307 | and returned as the first element of the list. | 307 | and returned as the first element of the list. |
| 308 | If PARSE-NS is non-nil, then QNAMES are expanded." | 308 | If PARSE-NS is non-nil, then QNAMES are expanded." |
| 309 | (save-restriction | 309 | ;; Use fixed syntax table to ensure regexp char classes and syntax |
| 310 | (narrow-to-region beg end) | 310 | ;; specs DTRT. |
| 311 | ;; Use fixed syntax table to ensure regexp char classes and syntax | 311 | (with-syntax-table (standard-syntax-table) |
| 312 | ;; specs DTRT. | 312 | (let ((case-fold-search nil) ; XML is case-sensitive. |
| 313 | (with-syntax-table (standard-syntax-table) | 313 | xml result dtd) |
| 314 | (let ((case-fold-search nil) ; XML is case-sensitive. | 314 | (save-excursion |
| 315 | xml result dtd) | 315 | (if buffer |
| 316 | (save-excursion | 316 | (set-buffer buffer)) |
| 317 | (if buffer | 317 | (save-restriction |
| 318 | (set-buffer buffer)) | 318 | (narrow-to-region beg end) |
| 319 | (goto-char (point-min)) | 319 | (goto-char (point-min)) |
| 320 | (while (not (eobp)) | 320 | (while (not (eobp)) |
| 321 | (if (search-forward "<" nil t) | 321 | (if (search-forward "<" nil t) |
| @@ -390,7 +390,7 @@ Returns one of: | |||
| 390 | parse-ns | 390 | parse-ns |
| 391 | (if parse-ns | 391 | (if parse-ns |
| 392 | (list | 392 | (list |
| 393 | ;; Default for empty prefix is no namespace | 393 | ;; Default for empty prefix is no namespace |
| 394 | (cons "" "") | 394 | (cons "" "") |
| 395 | ;; "xml" namespace | 395 | ;; "xml" namespace |
| 396 | (cons "xml" "http://www.w3.org/XML/1998/namespace") | 396 | (cons "xml" "http://www.w3.org/XML/1998/namespace") |
| @@ -431,12 +431,12 @@ Returns one of: | |||
| 431 | 431 | ||
| 432 | ;; Parse this node | 432 | ;; Parse this node |
| 433 | (let* ((node-name (match-string 1)) | 433 | (let* ((node-name (match-string 1)) |
| 434 | ;; Parse the attribute list. | 434 | ;; Parse the attribute list. |
| 435 | (attrs (xml-parse-attlist xml-ns)) | 435 | (attrs (xml-parse-attlist xml-ns)) |
| 436 | children pos) | 436 | children pos) |
| 437 | 437 | ||
| 438 | ;; add the xmlns:* attrs to our cache | 438 | ;; add the xmlns:* attrs to our cache |
| 439 | (when (consp xml-ns) | 439 | (when (consp xml-ns) |
| 440 | (dolist (attr attrs) | 440 | (dolist (attr attrs) |
| 441 | (when (and (consp (car attr)) | 441 | (when (and (consp (car attr)) |
| 442 | (equal "http://www.w3.org/2000/xmlns/" | 442 | (equal "http://www.w3.org/2000/xmlns/" |
| @@ -444,7 +444,7 @@ Returns one of: | |||
| 444 | (push (cons (cdar attr) (cdr attr)) | 444 | (push (cons (cdar attr) (cdr attr)) |
| 445 | xml-ns)))) | 445 | xml-ns)))) |
| 446 | 446 | ||
| 447 | (setq children (list attrs (xml-maybe-do-ns node-name "" xml-ns))) | 447 | (setq children (list attrs (xml-maybe-do-ns node-name "" xml-ns))) |
| 448 | 448 | ||
| 449 | ;; is this an empty element ? | 449 | ;; is this an empty element ? |
| 450 | (if (looking-at "/>") | 450 | (if (looking-at "/>") |
| @@ -494,21 +494,21 @@ Returns one of: | |||
| 494 | 494 | ||
| 495 | (defun xml-parse-string () | 495 | (defun xml-parse-string () |
| 496 | "Parse the next whatever. Could be a string, or an element." | 496 | "Parse the next whatever. Could be a string, or an element." |
| 497 | (let* ((pos (point)) | 497 | (let* ((pos (point)) |
| 498 | (string (progn (if (search-forward "<" nil t) | 498 | (string (progn (if (search-forward "<" nil t) |
| 499 | (forward-char -1) | 499 | (forward-char -1) |
| 500 | (goto-char (point-max))) | 500 | (goto-char (point-max))) |
| 501 | (buffer-substring pos (point))))) | 501 | (buffer-substring pos (point))))) |
| 502 | ;; Clean up the string. As per XML specifications, the XML | 502 | ;; Clean up the string. As per XML specifications, the XML |
| 503 | ;; processor should always pass the whole string to the | 503 | ;; processor should always pass the whole string to the |
| 504 | ;; application. But \r's should be replaced: | 504 | ;; application. But \r's should be replaced: |
| 505 | ;; http://www.w3.org/TR/2000/REC-xml-20001006#sec-line-ends | 505 | ;; http://www.w3.org/TR/2000/REC-xml-20001006#sec-line-ends |
| 506 | (setq pos 0) | 506 | (setq pos 0) |
| 507 | (while (string-match "\r\n?" string pos) | 507 | (while (string-match "\r\n?" string pos) |
| 508 | (setq string (replace-match "\n" t t string)) | 508 | (setq string (replace-match "\n" t t string)) |
| 509 | (setq pos (1+ (match-beginning 0)))) | 509 | (setq pos (1+ (match-beginning 0)))) |
| 510 | 510 | ||
| 511 | (xml-substitute-special string))) | 511 | (xml-substitute-special string))) |
| 512 | 512 | ||
| 513 | (defun xml-parse-attlist (&optional xml-ns) | 513 | (defun xml-parse-attlist (&optional xml-ns) |
| 514 | "Return the attribute-list after point. | 514 | "Return the attribute-list after point. |
| @@ -543,8 +543,8 @@ Leave point at the first non-blank character after the tag." | |||
| 543 | (replace-regexp-in-string "\\s-\\{2,\\}" " " string) | 543 | (replace-regexp-in-string "\\s-\\{2,\\}" " " string) |
| 544 | (let ((expansion (xml-substitute-special string))) | 544 | (let ((expansion (xml-substitute-special string))) |
| 545 | (unless (stringp expansion) | 545 | (unless (stringp expansion) |
| 546 | ; We say this is the constraint. It is acctually that | 546 | ; We say this is the constraint. It is acctually that |
| 547 | ; external entities nor "<" can be in an attribute value. | 547 | ; external entities nor "<" can be in an attribute value. |
| 548 | (error "XML: (Not Well-Formed) Entities in attributes cannot expand into elements")) | 548 | (error "XML: (Not Well-Formed) Entities in attributes cannot expand into elements")) |
| 549 | (push (cons name expansion) attlist))) | 549 | (push (cons name expansion) attlist))) |
| 550 | 550 | ||
diff --git a/lispref/frames.texi b/lispref/frames.texi index 4b967d8989c..8212e9325f9 100644 --- a/lispref/frames.texi +++ b/lispref/frames.texi | |||
| @@ -64,6 +64,7 @@ The frame is displayed on an MS-DOS terminal. | |||
| 64 | * Dialog Boxes:: Displaying a box to ask yes or no. | 64 | * Dialog Boxes:: Displaying a box to ask yes or no. |
| 65 | * Pointer Shapes:: Specifying the shape of the mouse pointer. | 65 | * Pointer Shapes:: Specifying the shape of the mouse pointer. |
| 66 | * Window System Selections:: Transferring text to and from other X clients. | 66 | * Window System Selections:: Transferring text to and from other X clients. |
| 67 | * Drag and Drop:: Internals of Drag-and-Drop implementation. | ||
| 67 | * Color Names:: Getting the definitions of color names. | 68 | * Color Names:: Getting the definitions of color names. |
| 68 | * Text Terminal Colors:: Defining colors for text-only terminals. | 69 | * Text Terminal Colors:: Defining colors for text-only terminals. |
| 69 | * Resources:: Getting resource values from the server. | 70 | * Resources:: Getting resource values from the server. |
| @@ -469,7 +470,7 @@ frame, or control their sizes. | |||
| 469 | The width in pixels of the frame's border. | 470 | The width in pixels of the frame's border. |
| 470 | 471 | ||
| 471 | @item internal-border-width | 472 | @item internal-border-width |
| 472 | The distance in pixels between text and the frame's border. | 473 | The distance in pixels between text (or fringe) and the frame's border. |
| 473 | 474 | ||
| 474 | @item vertical-scroll-bars | 475 | @item vertical-scroll-bars |
| 475 | Whether the frame has scroll bars for vertical scrolling, and which side | 476 | Whether the frame has scroll bars for vertical scrolling, and which side |
| @@ -1685,6 +1686,35 @@ access the clipboard at all. The default is @code{nil} on most systems, | |||
| 1685 | but @code{t} on MS-Windows. | 1686 | but @code{t} on MS-Windows. |
| 1686 | @end defopt | 1687 | @end defopt |
| 1687 | 1688 | ||
| 1689 | @node Drag and Drop | ||
| 1690 | @section Drag and Drop | ||
| 1691 | |||
| 1692 | @vindex x-dnd-test-function | ||
| 1693 | @vindex x-dnd-known-types | ||
| 1694 | When a user drags something from another application over Emacs, that other | ||
| 1695 | application expects Emacs to tell it if Emacs can handle the data that is | ||
| 1696 | dragged. The variable @code{x-dnd-test-function} is used by Emacs to determine | ||
| 1697 | what to reply. The default value is @code{x-dnd-default-test-function} | ||
| 1698 | which accepts drops if the type of the data to be dropped is present in | ||
| 1699 | @code{x-dnd-known-types}. You can customize @code{x-dnd-test-function} and/or | ||
| 1700 | @code{x-dnd-known-types} if you want Emacs to accept or reject drops based | ||
| 1701 | on some other criteria. | ||
| 1702 | |||
| 1703 | @vindex x-dnd-types-alist | ||
| 1704 | If you want to change the way Emacs handles drop of different types | ||
| 1705 | or add a new type, customize @code{x-dnd-types-alist}. This requires | ||
| 1706 | detailed knowledge of what types other applications use for drag and | ||
| 1707 | drop. | ||
| 1708 | |||
| 1709 | @vindex dnd-protocol-alist | ||
| 1710 | When an URL is dropped on Emacs it may be a file, but it may also be | ||
| 1711 | another URL type (ftp, http, etc.). Emacs first checks | ||
| 1712 | @code{dnd-protocol-alist} to determine what to do with the URL. If | ||
| 1713 | there is no match there and if @code{browse-url-browser-function} is | ||
| 1714 | an alist, Emacs looks for a match there. If no match is found the | ||
| 1715 | text for the URL is inserted. If you want to alter Emacs behavior, | ||
| 1716 | you can customize these variables. | ||
| 1717 | |||
| 1688 | @node Color Names | 1718 | @node Color Names |
| 1689 | @section Color Names | 1719 | @section Color Names |
| 1690 | 1720 | ||
diff --git a/lispref/keymaps.texi b/lispref/keymaps.texi index f30fb5c9659..5a732af4ebb 100644 --- a/lispref/keymaps.texi +++ b/lispref/keymaps.texi | |||
| @@ -22,10 +22,13 @@ found. The whole process is called @dfn{key lookup}. | |||
| 22 | * Inheritance and Keymaps:: How one keymap can inherit the bindings | 22 | * Inheritance and Keymaps:: How one keymap can inherit the bindings |
| 23 | of another keymap. | 23 | of another keymap. |
| 24 | * Prefix Keys:: Defining a key with a keymap as its definition. | 24 | * Prefix Keys:: Defining a key with a keymap as its definition. |
| 25 | * Active Keymaps:: Each buffer has a local keymap | 25 | * Active Keymaps:: How Emacs searches the active keymaps |
| 26 | for a key binding. | ||
| 27 | * Searching Keymaps:: A pseudo-Lisp summary of searching active maps. | ||
| 28 | * Controlling Active Maps:: Each buffer has a local keymap | ||
| 26 | to override the standard (global) bindings. | 29 | to override the standard (global) bindings. |
| 27 | A minor mode can also override them. | 30 | A minor mode can also override them. |
| 28 | * Key Lookup:: How extracting elements from keymaps works. | 31 | * Key Lookup:: Finding a key's binding in one keymap. |
| 29 | * Functions for Key Lookup:: How to request key lookup. | 32 | * Functions for Key Lookup:: How to request key lookup. |
| 30 | * Changing Key Bindings:: Redefining a key in a keymap. | 33 | * Changing Key Bindings:: Redefining a key in a keymap. |
| 31 | * Remapping Commands:: Bindings that translate one command to another. | 34 | * Remapping Commands:: Bindings that translate one command to another. |
| @@ -537,17 +540,38 @@ string for the keymap. The prompt string should be given for menu keymaps | |||
| 537 | @cindex local keymap | 540 | @cindex local keymap |
| 538 | 541 | ||
| 539 | Emacs normally contains many keymaps; at any given time, just a few | 542 | Emacs normally contains many keymaps; at any given time, just a few |
| 540 | of them are @dfn{active} in that they participate in the | 543 | of them are @dfn{active}, meaning that they participate in the |
| 541 | interpretation of user input. All the active keymaps are used | 544 | interpretation of user input. All the active keymaps are used |
| 542 | together to determine what command to execute when a key is entered. | 545 | together to determine what command to execute when a key is entered. |
| 543 | Emacs searches these keymaps one by one, in a standard order, until it | 546 | Emacs searches these keymaps one by one, in a standard order, until it |
| 544 | finds a binding in one of the keymaps. (Searching a single keymap for a | 547 | finds a binding in one of the keymaps. |
| 545 | binding is called @dfn{key lookup}; see @ref{Key Lookup}.) | ||
| 546 | 548 | ||
| 547 | Normally the active keymaps are the @code{keymap} property keymap, | 549 | Normally the active keymaps are the @code{keymap} property keymap, |
| 548 | the keymaps of any enabled minor modes, the current buffer's local | 550 | the keymaps of any enabled minor modes, the current buffer's local |
| 549 | keymap, and the global keymap, in that order. Therefore, Emacs | 551 | keymap, and the global keymap, in that order. Therefore, Emacs |
| 550 | searches for each input key sequence in all these keymaps. | 552 | searches for each input key sequence in all these keymaps. Here is a |
| 553 | pseudo-Lisp description of how this process works: | ||
| 554 | |||
| 555 | @lisp | ||
| 556 | (or (if overriding-terminal-local-map | ||
| 557 | (@var{find-in} overriding-terminal-local-map) | ||
| 558 | (if overriding-local-map | ||
| 559 | (@var{find-in} overriding-local-map) | ||
| 560 | (or (@var{find-in} (get-text-property (point) 'keymap)) | ||
| 561 | (@var{find-in-any} emulation-mode-map-alists) | ||
| 562 | (@var{find-in-any} minor-mode-overriding-map-alist) | ||
| 563 | (@var{find-in-any} minor-mode-map-alist) | ||
| 564 | (if (get-text-property (point) 'local-map)) | ||
| 565 | (@var{find-in} (get-text-property (point) 'local-map)) | ||
| 566 | (@var{find-in} (current-local-map)))))) | ||
| 567 | (@var{find-in} (current-global-map))) | ||
| 568 | @end lisp | ||
| 569 | |||
| 570 | @noindent | ||
| 571 | Here, the pseudo-function @var{find-in} means to look up the key | ||
| 572 | sequence in a single map, and @var{find-in-any} means to search the | ||
| 573 | appropriate keymaps from an alist. (Searching a single keymap for a | ||
| 574 | binding is called @dfn{key lookup}; see @ref{Key Lookup}.) | ||
| 551 | 575 | ||
| 552 | The @dfn{global keymap} holds the bindings of keys that are defined | 576 | The @dfn{global keymap} holds the bindings of keys that are defined |
| 553 | regardless of the current buffer, such as @kbd{C-f}. The variable | 577 | regardless of the current buffer, such as @kbd{C-f}. The variable |
| @@ -597,10 +621,92 @@ events within @code{read-key-sequence}. @xref{Translating Input}. | |||
| 597 | 621 | ||
| 598 | @xref{Standard Keymaps}, for a list of standard keymaps. | 622 | @xref{Standard Keymaps}, for a list of standard keymaps. |
| 599 | 623 | ||
| 624 | @defun current-active-maps &optional olp | ||
| 625 | This returns the list of active keymaps that would be used by the | ||
| 626 | command loop in the current circumstances to look up a key sequence. | ||
| 627 | Normally it ignores @code{overriding-local-map} and | ||
| 628 | @code{overriding-terminal-local-map}, but if @var{olp} is | ||
| 629 | non-@code{nil} then it pays attention to them. | ||
| 630 | @end defun | ||
| 631 | |||
| 632 | @defun key-binding key &optional accept-defaults no-remap | ||
| 633 | This function returns the binding for @var{key} according to the | ||
| 634 | current active keymaps. The result is @code{nil} if @var{key} is | ||
| 635 | undefined in the keymaps. | ||
| 636 | |||
| 637 | @c Emacs 19 feature | ||
| 638 | The argument @var{accept-defaults} controls checking for default | ||
| 639 | bindings, as in @code{lookup-key} (above). | ||
| 640 | |||
| 641 | When commands are remapped (@pxref{Remapping Commands}), | ||
| 642 | @code{key-binding} normally processes command remappings so as to | ||
| 643 | returns the remapped command that will actually be executed. However, | ||
| 644 | if @var{no-remap} is non-@code{nil}, @code{key-binding} ignores | ||
| 645 | remappings and returns the binding directly specified for @var{key}. | ||
| 646 | |||
| 647 | An error is signaled if @var{key} is not a string or a vector. | ||
| 648 | |||
| 649 | @example | ||
| 650 | @group | ||
| 651 | (key-binding "\C-x\C-f") | ||
| 652 | @result{} find-file | ||
| 653 | @end group | ||
| 654 | @end example | ||
| 655 | @end defun | ||
| 656 | |||
| 657 | @node Searching Keymaps | ||
| 658 | @section Searching the Active Keymaps | ||
| 659 | |||
| 660 | After translation of the input events (@pxref{Translating Input}) | ||
| 661 | Emacs looks for them in the active keymaps. Here is a pseudo-Lisp | ||
| 662 | description of the order in which the active keymaps are searched: | ||
| 663 | |||
| 664 | @lisp | ||
| 665 | (or (if overriding-terminal-local-map | ||
| 666 | (@var{find-in} overriding-terminal-local-map) | ||
| 667 | (if overriding-local-map | ||
| 668 | (@var{find-in} overriding-local-map) | ||
| 669 | (or (@var{find-in} (get-text-property (point) 'keymap)) | ||
| 670 | (@var{find-in-any} emulation-mode-map-alists) | ||
| 671 | (@var{find-in-any} minor-mode-overriding-map-alist) | ||
| 672 | (@var{find-in-any} minor-mode-map-alist) | ||
| 673 | (@var{find-in} (get-text-property (point) 'local-map)) | ||
| 674 | (@var{find-in} (current-local-map))))) | ||
| 675 | (@var{find-in} (current-global-map))) | ||
| 676 | @end lisp | ||
| 677 | |||
| 678 | @noindent | ||
| 679 | The @var{find-in} and @var{find-in-any} are pseudo functions that | ||
| 680 | searches in one keymap respectively an alist of keymaps. | ||
| 681 | |||
| 682 | @enumerate | ||
| 683 | @item | ||
| 684 | The function finally found may be remapped | ||
| 685 | (@pxref{Remapping Commands}). | ||
| 686 | |||
| 687 | @item | ||
| 688 | Characters that are bound to @code{self-insert-command} are translated | ||
| 689 | according to @code{translation-table-for-input} before insertion. | ||
| 690 | |||
| 691 | @item | ||
| 692 | @code{current-active-maps} returns a list of the | ||
| 693 | currently active keymaps at point. | ||
| 694 | |||
| 695 | @item | ||
| 696 | When a match is found (@pxref{Key Lookup}), if the binding in the | ||
| 697 | keymap is a function, the search is over. However if the keymap entry | ||
| 698 | is a symbol with a value or a string, Emacs replaces the input key | ||
| 699 | sequences with the variable's value or the string, and restarts the | ||
| 700 | search of the active keymaps. | ||
| 701 | @end enumerate | ||
| 702 | |||
| 703 | @node Controlling Active Maps | ||
| 704 | @section Controlling the Active Keymaps | ||
| 705 | |||
| 600 | @defvar global-map | 706 | @defvar global-map |
| 601 | This variable contains the default global keymap that maps Emacs | 707 | This variable contains the default global keymap that maps Emacs |
| 602 | keyboard input to commands. The global keymap is normally this keymap. | 708 | keyboard input to commands. The global keymap is normally this |
| 603 | The default global keymap is a full keymap that binds | 709 | keymap. The default global keymap is a full keymap that binds |
| 604 | @code{self-insert-command} to all of the printing characters. | 710 | @code{self-insert-command} to all of the printing characters. |
| 605 | 711 | ||
| 606 | It is normal practice to change the bindings in the global keymap, but you | 712 | It is normal practice to change the bindings in the global keymap, but you |
| @@ -763,14 +869,14 @@ are used before @code{minor-mode-map-alist} and | |||
| 763 | @cindex keymap entry | 869 | @cindex keymap entry |
| 764 | 870 | ||
| 765 | @dfn{Key lookup} is the process of finding the binding of a key | 871 | @dfn{Key lookup} is the process of finding the binding of a key |
| 766 | sequence from a given keymap. Actual execution of the binding is not | 872 | sequence from a given keymap. The execution or use of the binding is |
| 767 | part of key lookup. | 873 | not part of key lookup. |
| 768 | 874 | ||
| 769 | Key lookup uses just the event type of each event in the key sequence; | 875 | Key lookup uses just the event type of each event in the key sequence; |
| 770 | the rest of the event is ignored. In fact, a key sequence used for key | 876 | the rest of the event is ignored. In fact, a key sequence used for key |
| 771 | lookup may designate a mouse event with just its types (a symbol) | 877 | lookup may designate a mouse event with just its types (a symbol) |
| 772 | instead of the entire event (a list). @xref{Input Events}. Such | 878 | instead of the entire event (a list). @xref{Input Events}. Such |
| 773 | a ``key-sequence'' is insufficient for @code{command-execute} to run, | 879 | a ``key sequence'' is insufficient for @code{command-execute} to run, |
| 774 | but it is sufficient for looking up or rebinding a key. | 880 | but it is sufficient for looking up or rebinding a key. |
| 775 | 881 | ||
| 776 | When the key sequence consists of multiple events, key lookup | 882 | When the key sequence consists of multiple events, key lookup |
| @@ -965,39 +1071,6 @@ Used in keymaps to undefine keys. It calls @code{ding}, but does | |||
| 965 | not cause an error. | 1071 | not cause an error. |
| 966 | @end deffn | 1072 | @end deffn |
| 967 | 1073 | ||
| 968 | @defun key-binding key &optional accept-defaults no-remap | ||
| 969 | This function returns the binding for @var{key} in the current | ||
| 970 | keymaps, trying all the active keymaps. The result is @code{nil} if | ||
| 971 | @var{key} is undefined in the keymaps. | ||
| 972 | |||
| 973 | @c Emacs 19 feature | ||
| 974 | The argument @var{accept-defaults} controls checking for default | ||
| 975 | bindings, as in @code{lookup-key} (above). | ||
| 976 | |||
| 977 | When commands are remapped (@pxref{Remapping Commands}), | ||
| 978 | @code{key-binding} normally processes command remappings so as to | ||
| 979 | returns the remapped command that will actually be executed. However, | ||
| 980 | if @var{no-remap} is non-@code{nil}, @code{key-binding} ignores | ||
| 981 | remappings and returns the binding directly specified for @var{key}. | ||
| 982 | |||
| 983 | An error is signaled if @var{key} is not a string or a vector. | ||
| 984 | |||
| 985 | @example | ||
| 986 | @group | ||
| 987 | (key-binding "\C-x\C-f") | ||
| 988 | @result{} find-file | ||
| 989 | @end group | ||
| 990 | @end example | ||
| 991 | @end defun | ||
| 992 | |||
| 993 | @defun current-active-maps &optional olp | ||
| 994 | This returns the list of keymaps that would be used by the command | ||
| 995 | loop in the current circumstances to look up a key sequence. Normally | ||
| 996 | it ignores @code{overriding-local-map} and | ||
| 997 | @code{overriding-terminal-local-map}, but if @var{olp} is | ||
| 998 | non-@code{nil} then it pays attention to them. | ||
| 999 | @end defun | ||
| 1000 | |||
| 1001 | @defun local-key-binding key &optional accept-defaults | 1074 | @defun local-key-binding key &optional accept-defaults |
| 1002 | This function returns the binding for @var{key} in the current | 1075 | This function returns the binding for @var{key} in the current |
| 1003 | local keymap, or @code{nil} if it is undefined there. | 1076 | local keymap, or @code{nil} if it is undefined there. |
| @@ -1036,11 +1109,11 @@ bindings, as in @code{lookup-key} (above). | |||
| 1036 | 1109 | ||
| 1037 | @defvar meta-prefix-char | 1110 | @defvar meta-prefix-char |
| 1038 | @cindex @key{ESC} | 1111 | @cindex @key{ESC} |
| 1039 | This variable is the meta-prefix character code. It is used when | 1112 | This variable is the meta-prefix character code. It is used for |
| 1040 | translating a meta character to a two-character sequence so it can be | 1113 | translating a meta character to a two-character sequence so it can be |
| 1041 | looked up in a keymap. For useful results, the value should be a prefix | 1114 | looked up in a keymap. For useful results, the value should be a |
| 1042 | event (@pxref{Prefix Keys}). The default value is 27, which is the | 1115 | prefix event (@pxref{Prefix Keys}). The default value is 27, which is |
| 1043 | @acronym{ASCII} code for @key{ESC}. | 1116 | the @acronym{ASCII} code for @key{ESC}. |
| 1044 | 1117 | ||
| 1045 | As long as the value of @code{meta-prefix-char} remains 27, key lookup | 1118 | As long as the value of @code{meta-prefix-char} remains 27, key lookup |
| 1046 | translates @kbd{M-b} into @kbd{@key{ESC} b}, which is normally defined | 1119 | translates @kbd{M-b} into @kbd{@key{ESC} b}, which is normally defined |
diff --git a/lispref/minibuf.texi b/lispref/minibuf.texi index 6f98785f69f..c0990bae3ee 100644 --- a/lispref/minibuf.texi +++ b/lispref/minibuf.texi | |||
| @@ -583,6 +583,10 @@ themselves to do with minibuffers. We describe them in this chapter | |||
| 583 | so as to keep them near the higher-level completion features that do | 583 | so as to keep them near the higher-level completion features that do |
| 584 | use the minibuffer. | 584 | use the minibuffer. |
| 585 | 585 | ||
| 586 | If you store a completion alist in a variable, you should mark the | ||
| 587 | variable as ``risky'' with a non-@code{nil} | ||
| 588 | @code{risky-local-variable} property. | ||
| 589 | |||
| 586 | @defun try-completion string collection &optional predicate | 590 | @defun try-completion string collection &optional predicate |
| 587 | This function returns the longest common substring of all possible | 591 | This function returns the longest common substring of all possible |
| 588 | completions of @var{string} in @var{collection}. The value of | 592 | completions of @var{string} in @var{collection}. The value of |
diff --git a/man/ChangeLog b/man/ChangeLog index e7c90d400bc..d4923434daf 100644 --- a/man/ChangeLog +++ b/man/ChangeLog | |||
| @@ -1,3 +1,67 @@ | |||
| 1 | 2006-02-03 Eli Zaretskii <eliz@gnu.org> | ||
| 2 | |||
| 3 | * custom.texi (Init File, Find Init): Add cross-references to | ||
| 4 | where $HOME is described. | ||
| 5 | |||
| 6 | 2006-02-01 Luc Teirlinck <teirllm@auburn.edu> | ||
| 7 | |||
| 8 | * frames.texi (Frame Parameters): Remove @item for S-Mouse-1; it | ||
| 9 | is not inside the @table. | ||
| 10 | |||
| 11 | * emacs.texi (Top): Correct node name. | ||
| 12 | |||
| 13 | * files.texi (File Names): Fix @xref. | ||
| 14 | (Reverting): Fix typo. | ||
| 15 | |||
| 16 | * mule.texi (International): Correct node name. | ||
| 17 | |||
| 18 | * kmacro.texi (Save Keyboard Macro): Add missing @kbd to @table. | ||
| 19 | |||
| 20 | 2006-02-01 Richard M. Stallman <rms@gnu.org> | ||
| 21 | |||
| 22 | * emacs.texi (Top): Update subnode menu. | ||
| 23 | |||
| 24 | * mule.texi: Minor clarifications. | ||
| 25 | Reduce the specific references to X Windows. | ||
| 26 | Refer to "graphical" terminals, rather than window systems. | ||
| 27 | (Text Coding): Renamed from Specify Coding. | ||
| 28 | (Communication Coding, File Name Coding, Terminal Coding): | ||
| 29 | New nodes split out from Text Coding. | ||
| 30 | |||
| 31 | * kmacro.texi: Minor clarifications. | ||
| 32 | (Keyboard Macro Ring): Comment out some excessive commands. | ||
| 33 | (Basic Keyboard Macro): Split up the table, putting part in each node. | ||
| 34 | |||
| 35 | * major.texi: Minor clarifications. | ||
| 36 | |||
| 37 | * misc.texi (Single Shell, Interactive Shell): Fix xrefs. | ||
| 38 | |||
| 39 | * windows.texi: Minor clarifications. | ||
| 40 | (Change Window): Don't describe mode-line mouse cmds here. | ||
| 41 | Add xref to Mode Line Mouse. | ||
| 42 | |||
| 43 | * msdog.texi (Text and Binary, MS-DOS and MULE): Fix xrefs. | ||
| 44 | |||
| 45 | * macos.texi (Mac International): Fix xref. | ||
| 46 | |||
| 47 | * indent.texi: Minor clarifications. | ||
| 48 | |||
| 49 | * frames.texi: Minor clarifications. | ||
| 50 | Reduce the specific references to X Windows. | ||
| 51 | Refer to "graphical" terminals, rather than window systems. | ||
| 52 | (Frame Parameters): Don't mention commands like | ||
| 53 | set-foreground-color. Just say to customize a face. | ||
| 54 | (Drag and Drop): Lisp-level stuff moved to Emacs Lisp manual. | ||
| 55 | |||
| 56 | * files.texi: Minor clarifications. | ||
| 57 | (Numbered Backups): New node, split out from Backup Names. | ||
| 58 | |||
| 59 | * display.texi (Font Lock): C mode no longer depends on (-in-col-0. | ||
| 60 | |||
| 61 | * cmdargs.texi (General Variables): Fix xref. | ||
| 62 | |||
| 63 | * buffers.texi: Minor clarifications. | ||
| 64 | |||
| 1 | 2006-01-31 Romain Francoise <romain@orebokech.com> | 65 | 2006-01-31 Romain Francoise <romain@orebokech.com> |
| 2 | 66 | ||
| 3 | * message.texi (Message Headers): Explain what | 67 | * message.texi (Message Headers): Explain what |
diff --git a/man/buffers.texi b/man/buffers.texi index 3e4b311bd50..a8e23086f79 100644 --- a/man/buffers.texi +++ b/man/buffers.texi | |||
| @@ -87,8 +87,8 @@ selected buffer other than the current buffer. | |||
| 87 | @findex switch-to-buffer | 87 | @findex switch-to-buffer |
| 88 | To select the buffer named @var{bufname}, type @kbd{C-x b @var{bufname} | 88 | To select the buffer named @var{bufname}, type @kbd{C-x b @var{bufname} |
| 89 | @key{RET}}. This runs the command @code{switch-to-buffer} with argument | 89 | @key{RET}}. This runs the command @code{switch-to-buffer} with argument |
| 90 | @var{bufname}. You can use completion on an abbreviation for the buffer | 90 | @var{bufname}. You can use completion to enter the buffer |
| 91 | name you want (@pxref{Completion}). An empty argument to @kbd{C-x b} | 91 | name (@pxref{Completion}). An empty argument to @kbd{C-x b} |
| 92 | specifies the buffer that was current most recently among those not | 92 | specifies the buffer that was current most recently among those not |
| 93 | now displayed in any window. | 93 | now displayed in any window. |
| 94 | 94 | ||
| @@ -128,7 +128,7 @@ customizing the variables @code{special-display-buffer-names}, | |||
| 128 | @ref{Special Buffer Frames}, for more about these variables. In | 128 | @ref{Special Buffer Frames}, for more about these variables. In |
| 129 | addition, if the value of @code{display-buffer-reuse-frames} is | 129 | addition, if the value of @code{display-buffer-reuse-frames} is |
| 130 | non-@code{nil}, and the buffer you want to switch to is already | 130 | non-@code{nil}, and the buffer you want to switch to is already |
| 131 | displayed in some frame, Emacs will raise that frame. | 131 | displayed in some frame, Emacs will just raise that frame. |
| 132 | 132 | ||
| 133 | Most buffers are created by visiting files, or by Emacs commands that | 133 | Most buffers are created by visiting files, or by Emacs commands that |
| 134 | want to display some text, but you can also create a buffer explicitly | 134 | want to display some text, but you can also create a buffer explicitly |
| @@ -177,10 +177,11 @@ line in the list shows one buffer's name, major mode and visited file. | |||
| 177 | The buffers are listed in the order that they were current; the | 177 | The buffers are listed in the order that they were current; the |
| 178 | buffers that were current most recently come first. | 178 | buffers that were current most recently come first. |
| 179 | 179 | ||
| 180 | @samp{*} in the first field of a line indicates the buffer is ``modified.'' | 180 | @samp{*} in the first field of a line indicates the buffer is |
| 181 | If several buffers are modified, it may be time to save some with @kbd{C-x s} | 181 | ``modified.'' If several buffers are modified, it may be time to save |
| 182 | (@pxref{Save Commands}). @samp{%} indicates a read-only buffer. @samp{.} marks the | 182 | some with @kbd{C-x s} (@pxref{Save Commands}). @samp{%} indicates a |
| 183 | current buffer. Here is an example of a buffer list:@refill | 183 | read-only buffer. @samp{.} marks the current buffer. Here is an |
| 184 | example of a buffer list:@refill | ||
| 184 | 185 | ||
| 185 | @smallexample | 186 | @smallexample |
| 186 | CRM Buffer Size Mode File | 187 | CRM Buffer Size Mode File |
| @@ -199,7 +200,7 @@ CRM Buffer Size Mode File | |||
| 199 | Note that the buffer @samp{*Help*} was made by a help request; it is | 200 | Note that the buffer @samp{*Help*} was made by a help request; it is |
| 200 | not visiting any file. The buffer @code{src} was made by Dired on the | 201 | not visiting any file. The buffer @code{src} was made by Dired on the |
| 201 | directory @file{~/cvs/emacs/src/}. You can list only buffers that are | 202 | directory @file{~/cvs/emacs/src/}. You can list only buffers that are |
| 202 | visiting files by giving the command a prefix; for instance, by typing | 203 | visiting files by giving the command a prefix argument, as in |
| 203 | @kbd{C-u C-x C-b}. | 204 | @kbd{C-u C-x C-b}. |
| 204 | 205 | ||
| 205 | @code{list-buffers} omits buffers whose names begin with a space, | 206 | @code{list-buffers} omits buffers whose names begin with a space, |
| @@ -243,10 +244,10 @@ flag, but it also checks the file in or out. @xref{Version | |||
| 243 | Control}. | 244 | Control}. |
| 244 | 245 | ||
| 245 | @findex rename-buffer | 246 | @findex rename-buffer |
| 246 | @kbd{M-x rename-buffer} changes the name of the current buffer. Specify | 247 | @kbd{M-x rename-buffer} changes the name of the current buffer. You |
| 247 | the new name as a minibuffer argument. There is no default. If you | 248 | specify the new name as a minibuffer argument; there is no default. |
| 248 | specify a name that is in use for some other buffer, an error happens and | 249 | If you specify a name that is in use for some other buffer, an error |
| 249 | no renaming is done. | 250 | happens and no renaming is done. |
| 250 | 251 | ||
| 251 | @findex rename-uniquely | 252 | @findex rename-uniquely |
| 252 | @kbd{M-x rename-uniquely} renames the current buffer to a similar | 253 | @kbd{M-x rename-uniquely} renames the current buffer to a similar |
| @@ -274,7 +275,7 @@ your perusal remain in effect. | |||
| 274 | 275 | ||
| 275 | The commands @kbd{M-x append-to-buffer} and @kbd{M-x insert-buffer} | 276 | The commands @kbd{M-x append-to-buffer} and @kbd{M-x insert-buffer} |
| 276 | can be used to copy text from one buffer to another. @xref{Accumulating | 277 | can be used to copy text from one buffer to another. @xref{Accumulating |
| 277 | Text}.@refill | 278 | Text}. |
| 278 | 279 | ||
| 279 | @node Kill Buffer | 280 | @node Kill Buffer |
| 280 | @section Killing Buffers | 281 | @section Killing Buffers |
| @@ -470,17 +471,15 @@ you run @code{list-buffers} (that is, type @kbd{C-x C-b}) and select | |||
| 470 | the buffer list manually, you can use all of the commands described | 471 | the buffer list manually, you can use all of the commands described |
| 471 | here. | 472 | here. |
| 472 | 473 | ||
| 473 | Normally, the buffer @samp{*Buffer List*} is not updated automatically when | 474 | Normally, the buffer @samp{*Buffer List*} is not updated |
| 474 | buffers are created and killed; its contents are just text. If you have | 475 | automatically when buffers are created and killed; its contents are |
| 475 | created, deleted or renamed buffers, the way to update @samp{*Buffer | 476 | just text. If you have created, deleted or renamed buffers, the way |
| 476 | List*} to show what you have done is to type @kbd{g} | 477 | to update @samp{*Buffer List*} to show what you have done is to type |
| 477 | (@code{revert-buffer}) or repeat the @code{buffer-menu} command. | 478 | @kbd{g} (@code{revert-buffer}). You can make this happen regularly |
| 478 | 479 | every @code{auto-revert-interval} seconds if you enable Auto Revert | |
| 479 | The @samp{*Buffer List*} buffer does automatically update every | 480 | mode in this buffer, as long as it is not marked modified. Global |
| 480 | @code{auto-revert-interval} seconds if you enable Auto Revert mode in | 481 | Auto Revert mode applies to the @samp{*Buffer List*} buffer only if |
| 481 | it. (As long as it is not marked modified.) Global Auto Revert mode | 482 | @code{global-auto-revert-non-file-buffers} is non-@code{nil}. |
| 482 | does not update the @samp{*Buffer List*} buffer by default, but it | ||
| 483 | does if @code{global-auto-revert-non-file-buffers} is non-@code{nil}. | ||
| 484 | @inforef{Autorevert,, emacs-xtra}, for details. | 483 | @inforef{Autorevert,, emacs-xtra}, for details. |
| 485 | 484 | ||
| 486 | The command @code{buffer-menu-other-window} works the same as | 485 | The command @code{buffer-menu-other-window} works the same as |
| @@ -589,7 +588,7 @@ forward order after the file name, as in @samp{file|top/middle}. | |||
| 589 | name is not very important if you are going to @emph{look} at the | 588 | name is not very important if you are going to @emph{look} at the |
| 590 | buffer names before you type one. But as an experienced user, if you | 589 | buffer names before you type one. But as an experienced user, if you |
| 591 | know the rule, you won't have to look. And then you may find that one | 590 | know the rule, you won't have to look. And then you may find that one |
| 592 | rule or another is easier for you to remember and utilize fast. | 591 | rule or another is easier for you to remember and apply quickly. |
| 593 | 592 | ||
| 594 | @node Iswitchb | 593 | @node Iswitchb |
| 595 | @subsection Switching Between Buffers using Substrings | 594 | @subsection Switching Between Buffers using Substrings |
diff --git a/man/cmdargs.texi b/man/cmdargs.texi index 28cb567f0cd..74de707cd2c 100644 --- a/man/cmdargs.texi +++ b/man/cmdargs.texi | |||
| @@ -577,8 +577,7 @@ does not use @env{TZ} at all. | |||
| 577 | The user's login name. See also @env{LOGNAME}. On MS-DOS, this | 577 | The user's login name. See also @env{LOGNAME}. On MS-DOS, this |
| 578 | defaults to @samp{root}. | 578 | defaults to @samp{root}. |
| 579 | @item VERSION_CONTROL | 579 | @item VERSION_CONTROL |
| 580 | Used to initialize the @code{version-control} variable (@pxref{Backup | 580 | Used to initialize the @code{version-control} variable (@pxref{Numbered Backups}). |
| 581 | Names}). | ||
| 582 | @end table | 581 | @end table |
| 583 | 582 | ||
| 584 | @node Misc Variables | 583 | @node Misc Variables |
diff --git a/man/custom.texi b/man/custom.texi index 509a63a4de2..d10c8aeca2e 100644 --- a/man/custom.texi +++ b/man/custom.texi | |||
| @@ -2029,8 +2029,9 @@ Reference Manual}. | |||
| 2029 | @cindex startup (init file) | 2029 | @cindex startup (init file) |
| 2030 | 2030 | ||
| 2031 | When Emacs is started, it normally loads a Lisp program from the | 2031 | When Emacs is started, it normally loads a Lisp program from the |
| 2032 | file @file{.emacs} or @file{.emacs.el} in your home directory. We | 2032 | file @file{.emacs} or @file{.emacs.el} in your home directory |
| 2033 | call this file your @dfn{init file} because it specifies how to | 2033 | (see @ref{General Variables, HOME} if you don't know where that is). |
| 2034 | We call this file your @dfn{init file} because it specifies how to | ||
| 2034 | initialize Emacs for you. You can use the command line switch | 2035 | initialize Emacs for you. You can use the command line switch |
| 2035 | @samp{-q} to prevent loading your init file, and @samp{-u} (or | 2036 | @samp{-q} to prevent loading your init file, and @samp{-u} (or |
| 2036 | @samp{--user}) to specify a different user's init file (@pxref{Initial | 2037 | @samp{--user}) to specify a different user's init file (@pxref{Initial |
| @@ -2442,11 +2443,12 @@ library. @xref{Hooks}. | |||
| 2442 | @node Find Init | 2443 | @node Find Init |
| 2443 | @subsection How Emacs Finds Your Init File | 2444 | @subsection How Emacs Finds Your Init File |
| 2444 | 2445 | ||
| 2445 | Normally Emacs uses the environment variable @env{HOME} to find | 2446 | Normally Emacs uses the environment variable @env{HOME} |
| 2446 | @file{.emacs}; that's what @samp{~} means in a file name. If | 2447 | (@pxref{General Variables, HOME}) to find @file{.emacs}; that's what |
| 2447 | @file{.emacs} is not found inside @file{~/} (nor @file{.emacs.el}), | 2448 | @samp{~} means in a file name. If @file{.emacs} is not found inside |
| 2448 | Emacs looks for @file{~/.emacs.d/init.el} (which, like | 2449 | @file{~/} (nor @file{.emacs.el}), Emacs looks for |
| 2449 | @file{~/.emacs.el}, can be byte-compiled). | 2450 | @file{~/.emacs.d/init.el} (which, like @file{~/.emacs.el}, can be |
| 2451 | byte-compiled). | ||
| 2450 | 2452 | ||
| 2451 | However, if you run Emacs from a shell started by @code{su}, Emacs | 2453 | However, if you run Emacs from a shell started by @code{su}, Emacs |
| 2452 | tries to find your own @file{.emacs}, not that of the user you are | 2454 | tries to find your own @file{.emacs}, not that of the user you are |
diff --git a/man/display.texi b/man/display.texi index 37edc372fa0..1f359f9e5aa 100644 --- a/man/display.texi +++ b/man/display.texi | |||
| @@ -557,13 +557,13 @@ buffer fontification is suppressed. | |||
| 557 | @cindex brace in column zero and fontification | 557 | @cindex brace in column zero and fontification |
| 558 | Comment and string fontification (or ``syntactic'' fontification) | 558 | Comment and string fontification (or ``syntactic'' fontification) |
| 559 | relies on analysis of the syntactic structure of the buffer text. For | 559 | relies on analysis of the syntactic structure of the buffer text. For |
| 560 | the sake of speed, some modes, including C mode and Lisp mode, | 560 | the sake of speed, some modes, including Lisp mode, rely on a special |
| 561 | rely on a special convention: an open-parenthesis or open-brace in the | 561 | convention: an open-parenthesis or open-brace in the leftmost column |
| 562 | leftmost column always defines the @w{beginning} of a defun, and is | 562 | always defines the @w{beginning} of a defun, and is thus always |
| 563 | thus always outside any string or comment. (@xref{Left Margin | 563 | outside any string or comment. (@xref{Left Margin Paren}.) If you |
| 564 | Paren}.) If you don't follow this convention, Font Lock mode can | 564 | don't follow this convention, Font Lock mode can misfontify the text |
| 565 | misfontify the text that follows an open-parenthesis or open-brace in | 565 | that follows an open-parenthesis or open-brace in the leftmost column |
| 566 | the leftmost column that is inside a string or comment. | 566 | that is inside a string or comment. |
| 567 | 567 | ||
| 568 | @cindex slow display during scrolling | 568 | @cindex slow display during scrolling |
| 569 | The variable @code{font-lock-beginning-of-syntax-function} (always | 569 | The variable @code{font-lock-beginning-of-syntax-function} (always |
diff --git a/man/emacs.texi b/man/emacs.texi index ddd0660c41d..5fb9af71c43 100644 --- a/man/emacs.texi +++ b/man/emacs.texi | |||
| @@ -460,7 +460,11 @@ International Character Set Support | |||
| 460 | * Coding Systems:: Character set conversion when you read and | 460 | * Coding Systems:: Character set conversion when you read and |
| 461 | write files, and so on. | 461 | write files, and so on. |
| 462 | * Recognize Coding:: How Emacs figures out which conversion to use. | 462 | * Recognize Coding:: How Emacs figures out which conversion to use. |
| 463 | * Specify Coding:: Various ways to choose which conversion to use. | 463 | * Text Coding:: Choosing conversion to use for file text. |
| 464 | * Communication Coding:: Coding systems for interprocess communication. | ||
| 465 | * File Name Coding:: Coding systems for file @emph{names}. | ||
| 466 | * Terminal Coding:: Specifying coding systems for converting | ||
| 467 | terminal input and output. | ||
| 464 | * Fontsets:: Fontsets are collections of fonts | 468 | * Fontsets:: Fontsets are collections of fonts |
| 465 | that cover the whole spectrum of characters. | 469 | that cover the whole spectrum of characters. |
| 466 | * Defining Fontsets:: Defining a new fontset. | 470 | * Defining Fontsets:: Defining a new fontset. |
diff --git a/man/files.texi b/man/files.texi index 7b08fc5c791..6edf938261a 100644 --- a/man/files.texi +++ b/man/files.texi | |||
| @@ -68,21 +68,22 @@ a slash, it is interpreted with respect to the default directory. The | |||
| 68 | default directory is kept in the variable @code{default-directory}, | 68 | default directory is kept in the variable @code{default-directory}, |
| 69 | which has a separate value in every buffer. | 69 | which has a separate value in every buffer. |
| 70 | 70 | ||
| 71 | For example, if the default file name is @file{/u/rms/gnu/gnu.tasks} then | ||
| 72 | the default directory is @file{/u/rms/gnu/}. If you type just @samp{foo}, | ||
| 73 | which does not specify a directory, it is short for @file{/u/rms/gnu/foo}. | ||
| 74 | @samp{../.login} would stand for @file{/u/rms/.login}. @samp{new/foo} | ||
| 75 | would stand for the file name @file{/u/rms/gnu/new/foo}. | ||
| 76 | |||
| 77 | @findex cd | 71 | @findex cd |
| 78 | @findex pwd | 72 | @findex pwd |
| 79 | The command @kbd{M-x pwd} displays the current buffer's default | 73 | The command @kbd{M-x pwd} displays the current buffer's default |
| 80 | directory, and the command @kbd{M-x cd} sets it (to a value read using | 74 | directory, and the command @kbd{M-x cd} sets it (to a value read using |
| 81 | the minibuffer). A buffer's default directory changes only when the | 75 | the minibuffer). A buffer's default directory changes only when the |
| 82 | @code{cd} command is used. A file-visiting buffer's default directory | 76 | @code{cd} command is used. A file-visiting buffer's default directory |
| 83 | is initialized to the directory of the file that is visited in that buffer. If | 77 | is initialized to the directory of the file it visits. If you create |
| 84 | you create a buffer with @kbd{C-x b}, its default directory is copied | 78 | a buffer with @kbd{C-x b}, its default directory is copied from that |
| 85 | from that of the buffer that was current at the time. | 79 | of the buffer that was current at the time. |
| 80 | |||
| 81 | For example, if the default file name is @file{/u/rms/gnu/gnu.tasks} | ||
| 82 | then the default directory is normally @file{/u/rms/gnu/}. If you | ||
| 83 | type just @samp{foo}, which does not specify a directory, it is short | ||
| 84 | for @file{/u/rms/gnu/foo}. @samp{../.login} would stand for | ||
| 85 | @file{/u/rms/.login}. @samp{new/foo} would stand for the file name | ||
| 86 | @file{/u/rms/gnu/new/foo}. | ||
| 86 | 87 | ||
| 87 | @vindex insert-default-directory | 88 | @vindex insert-default-directory |
| 88 | The default directory actually appears in the minibuffer when the | 89 | The default directory actually appears in the minibuffer when the |
| @@ -102,6 +103,14 @@ with @samp{/usr/tmp/} and you add @samp{/x1/rms/foo}, you get | |||
| 102 | first slash in the double slash; the result is @samp{/x1/rms/foo}. | 103 | first slash in the double slash; the result is @samp{/x1/rms/foo}. |
| 103 | @xref{Minibuffer File}. | 104 | @xref{Minibuffer File}. |
| 104 | 105 | ||
| 106 | @cindex home directory shorthand | ||
| 107 | You can use @file{~/} in a file name to mean your home directory, | ||
| 108 | or @file{~@var{user-id}/} to mean the home directory of a user whose | ||
| 109 | login name is @code{user-id}. (On DOS and Windows systems, where a user | ||
| 110 | doesn't have a home directory, Emacs substitutes @file{~/} with the | ||
| 111 | value of the environment variable @code{HOME}; see @ref{General | ||
| 112 | Variables}.) | ||
| 113 | |||
| 105 | @cindex environment variables in file names | 114 | @cindex environment variables in file names |
| 106 | @cindex expansion of environment variables | 115 | @cindex expansion of environment variables |
| 107 | @cindex @code{$} in file names | 116 | @cindex @code{$} in file names |
| @@ -120,14 +129,6 @@ is not defined). | |||
| 120 | Note that shell commands to set environment variables affect Emacs | 129 | Note that shell commands to set environment variables affect Emacs |
| 121 | only when done before Emacs is started. | 130 | only when done before Emacs is started. |
| 122 | 131 | ||
| 123 | @cindex home directory shorthand | ||
| 124 | You can use @file{~/} in a file name to mean your home directory, | ||
| 125 | or @file{~@var{user-id}/} to mean the home directory of a user whose | ||
| 126 | login name is @code{user-id}. (On DOS and Windows systems, where a user | ||
| 127 | doesn't have a home directory, Emacs substitutes @file{~/} with the | ||
| 128 | value of the environment variable @code{HOME}; see @ref{General | ||
| 129 | Variables}.) | ||
| 130 | |||
| 131 | To access a file with @samp{$} in its name, if the @samp{$} causes | 132 | To access a file with @samp{$} in its name, if the @samp{$} causes |
| 132 | expansion, type @samp{$$}. This pair is converted to a single | 133 | expansion, type @samp{$$}. This pair is converted to a single |
| 133 | @samp{$} at the same time as variable substitution is performed for a | 134 | @samp{$} at the same time as variable substitution is performed for a |
| @@ -136,13 +137,13 @@ single @samp{$}. Alternatively, quote the whole file name with | |||
| 136 | literal @samp{~} should also be quoted with @samp{/:}. | 137 | literal @samp{~} should also be quoted with @samp{/:}. |
| 137 | 138 | ||
| 138 | @findex substitute-in-file-name | 139 | @findex substitute-in-file-name |
| 139 | The Lisp function that performs the substitution is called | 140 | The Lisp function that performs the @samp{$}-substitution is called |
| 140 | @code{substitute-in-file-name}. The substitution is performed only on | 141 | @code{substitute-in-file-name}. The substitution is performed only on |
| 141 | file names read as such using the minibuffer. | 142 | file names read as such using the minibuffer. |
| 142 | 143 | ||
| 143 | You can include non-@acronym{ASCII} characters in file names if you set the | 144 | You can include non-@acronym{ASCII} characters in file names if you set the |
| 144 | variable @code{file-name-coding-system} to a non-@code{nil} value. | 145 | variable @code{file-name-coding-system} to a non-@code{nil} value. |
| 145 | @xref{Specify Coding}. | 146 | @xref{File Name Coding}. |
| 146 | 147 | ||
| 147 | @node Visiting | 148 | @node Visiting |
| 148 | @section Visiting Files | 149 | @section Visiting Files |
| @@ -185,7 +186,7 @@ in that window, so you can always tell what buffer you are editing. | |||
| 185 | 186 | ||
| 186 | The changes you make with editing commands are made in the Emacs | 187 | The changes you make with editing commands are made in the Emacs |
| 187 | buffer. They do not take effect in the file that you visited, or any | 188 | buffer. They do not take effect in the file that you visited, or any |
| 188 | place permanent, until you @dfn{save} the buffer. Saving the buffer | 189 | permanent place, until you @dfn{save} the buffer. Saving the buffer |
| 189 | means that Emacs writes the current contents of the buffer into its | 190 | means that Emacs writes the current contents of the buffer into its |
| 190 | visited file. @xref{Saving}. | 191 | visited file. @xref{Saving}. |
| 191 | 192 | ||
| @@ -208,17 +209,17 @@ While in the minibuffer, you can abort @kbd{C-x C-f} by typing | |||
| 208 | @kbd{C-g}. File-name completion ignores certain filenames; for more | 209 | @kbd{C-g}. File-name completion ignores certain filenames; for more |
| 209 | about this, see @ref{Completion Options}. | 210 | about this, see @ref{Completion Options}. |
| 210 | 211 | ||
| 211 | Your confirmation that @kbd{C-x C-f} has completed successfully is the | 212 | Your confirmation that @kbd{C-x C-f} has completed successfully is |
| 212 | appearance of new text on the screen and a new buffer name in the mode | 213 | the appearance of new text on the screen and a new buffer name in the |
| 213 | line. If the specified file does not exist and could not be created, or | 214 | mode line. If the specified file does not exist and you could not |
| 214 | cannot be read, then you get an error, with an error message displayed | 215 | create it, or exists but you can't read it, then you get an error, |
| 215 | in the echo area. | 216 | with an error message displayed in the echo area. |
| 216 | 217 | ||
| 217 | If you visit a file that is already in Emacs, @kbd{C-x C-f} does not make | 218 | If you visit a file that is already in Emacs, @kbd{C-x C-f} does not make |
| 218 | another copy. It selects the existing buffer containing that file. | 219 | another copy. It selects the existing buffer containing that file. |
| 219 | However, before doing so, it checks that the file itself has not changed | 220 | However, before doing so, it checks whether the file itself has changed |
| 220 | since you visited or saved it last. If the file has changed, a warning | 221 | since you visited or saved it last. If the file has changed, Emacs offers |
| 221 | message is shown. @xref{Interlocking,,Simultaneous Editing}. | 222 | to reread it. |
| 222 | 223 | ||
| 223 | @vindex large-file-warning-threshold | 224 | @vindex large-file-warning-threshold |
| 224 | @cindex maximum buffer size exceeded, error message | 225 | @cindex maximum buffer size exceeded, error message |
| @@ -232,7 +233,7 @@ buffer size, which is around 256 megabytes on 32-bit machines | |||
| 232 | saying that the maximum buffer size has been exceeded. | 233 | saying that the maximum buffer size has been exceeded. |
| 233 | 234 | ||
| 234 | @cindex file selection dialog | 235 | @cindex file selection dialog |
| 235 | On graphical terminals, there are two additional methods for | 236 | On graphical displays there are two additional methods for |
| 236 | visiting files. Firstly, when Emacs is built with a suitable GUI | 237 | visiting files. Firstly, when Emacs is built with a suitable GUI |
| 237 | toolkit, commands invoked with the mouse (by clicking on the menu bar | 238 | toolkit, commands invoked with the mouse (by clicking on the menu bar |
| 238 | or tool bar) use the toolkit's standard File Selection dialog instead | 239 | or tool bar) use the toolkit's standard File Selection dialog instead |
| @@ -313,9 +314,6 @@ buffer (after first offering to save it if it is modified). When | |||
| 313 | default file name in the buffer, with point just after the directory | 314 | default file name in the buffer, with point just after the directory |
| 314 | part; this is convenient if you made a slight error in typing the name. | 315 | part; this is convenient if you made a slight error in typing the name. |
| 315 | 316 | ||
| 316 | If you find a file which exists but cannot be read, @kbd{C-x C-f} | ||
| 317 | signals an error. | ||
| 318 | |||
| 319 | @kindex C-x 4 f | 317 | @kindex C-x 4 f |
| 320 | @findex find-file-other-window | 318 | @findex find-file-other-window |
| 321 | @kbd{C-x 4 f} (@code{find-file-other-window}) is like @kbd{C-x C-f} | 319 | @kbd{C-x 4 f} (@code{find-file-other-window}) is like @kbd{C-x C-f} |
| @@ -392,7 +390,7 @@ Save any or all buffers in their visited files (@code{save-some-buffers}). | |||
| 392 | Forget that the current buffer has been changed (@code{not-modified}). | 390 | Forget that the current buffer has been changed (@code{not-modified}). |
| 393 | With prefix argument (@kbd{C-u}), mark the current buffer as changed. | 391 | With prefix argument (@kbd{C-u}), mark the current buffer as changed. |
| 394 | @item C-x C-w | 392 | @item C-x C-w |
| 395 | Save the current buffer as a specified file name (@code{write-file}). | 393 | Save the current buffer with a specified file name (@code{write-file}). |
| 396 | @item M-x set-visited-file-name | 394 | @item M-x set-visited-file-name |
| 397 | Change the file name under which the current buffer will be saved. | 395 | Change the file name under which the current buffer will be saved. |
| 398 | @end table | 396 | @end table |
| @@ -464,9 +462,9 @@ saved. (@samp{~} is often used as a mathematical symbol for `not'; thus | |||
| 464 | a different file name, one which is not in use for anything important. | 462 | a different file name, one which is not in use for anything important. |
| 465 | Alternatively, you can cancel all the changes made since the file was | 463 | Alternatively, you can cancel all the changes made since the file was |
| 466 | visited or saved, by reading the text from the file again. This is | 464 | visited or saved, by reading the text from the file again. This is |
| 467 | called @dfn{reverting}. @xref{Reverting}. You could also undo all the | 465 | called @dfn{reverting}. @xref{Reverting}. (You could also undo all the |
| 468 | changes by repeating the undo command @kbd{C-x u} until you have undone | 466 | changes by repeating the undo command @kbd{C-x u} until you have undone |
| 469 | all the changes; but reverting is easier. | 467 | all the changes; but reverting is easier.) You can also kill the buffer. |
| 470 | 468 | ||
| 471 | @findex set-visited-file-name | 469 | @findex set-visited-file-name |
| 472 | @kbd{M-x set-visited-file-name} alters the name of the file that the | 470 | @kbd{M-x set-visited-file-name} alters the name of the file that the |
| @@ -522,6 +520,9 @@ to make backup files. By default it is @code{nil}, since backup files | |||
| 522 | are redundant when you store all the previous versions in a version | 520 | are redundant when you store all the previous versions in a version |
| 523 | control system. @xref{General VC Options}. | 521 | control system. @xref{General VC Options}. |
| 524 | 522 | ||
| 523 | At your option, Emacs can keep either a single backup for each file, | ||
| 524 | or make a series of numbered backup files for each file that you edit. | ||
| 525 | |||
| 525 | @vindex backup-enable-predicate | 526 | @vindex backup-enable-predicate |
| 526 | @vindex temporary-file-directory | 527 | @vindex temporary-file-directory |
| 527 | @vindex small-temporary-file-directory | 528 | @vindex small-temporary-file-directory |
| @@ -530,9 +531,6 @@ prevents backup files being written for files in the directories used | |||
| 530 | for temporary files, specified by @code{temporary-file-directory} or | 531 | for temporary files, specified by @code{temporary-file-directory} or |
| 531 | @code{small-temporary-file-directory}. | 532 | @code{small-temporary-file-directory}. |
| 532 | 533 | ||
| 533 | At your option, Emacs can keep either a single backup file or a series of | ||
| 534 | numbered backup files for each file that you edit. | ||
| 535 | |||
| 536 | Emacs makes a backup for a file only the first time the file is saved | 534 | Emacs makes a backup for a file only the first time the file is saved |
| 537 | from one buffer. No matter how many times you save a file, its backup file | 535 | from one buffer. No matter how many times you save a file, its backup file |
| 538 | continues to contain the contents from before the file was visited. | 536 | continues to contain the contents from before the file was visited. |
| @@ -550,19 +548,54 @@ backup from the previous contents, and arranges to make another from the | |||
| 550 | newly saved contents if you save again. | 548 | newly saved contents if you save again. |
| 551 | 549 | ||
| 552 | @menu | 550 | @menu |
| 553 | * Names: Backup Names. How backup files are named; | 551 | * One or Many: Numbered Backups. Whether to make one backup file or many. |
| 554 | choosing single or numbered backup files. | 552 | * Names: Backup Names. How backup files are named. |
| 555 | * Deletion: Backup Deletion. Emacs deletes excess numbered backups. | 553 | * Deletion: Backup Deletion. Emacs deletes excess numbered backups. |
| 556 | * Copying: Backup Copying. Backups can be made by copying or renaming. | 554 | * Copying: Backup Copying. Backups can be made by copying or renaming. |
| 557 | @end menu | 555 | @end menu |
| 558 | 556 | ||
| 557 | @node Numbered Backups | ||
| 558 | @subsubsection Numbered Backups | ||
| 559 | |||
| 560 | @vindex version-control | ||
| 561 | The choice of single backup file or multiple numbered backup files | ||
| 562 | is controlled by the variable @code{version-control}. Its possible | ||
| 563 | values are: | ||
| 564 | |||
| 565 | @table @code | ||
| 566 | @item t | ||
| 567 | Make numbered backups. | ||
| 568 | @item nil | ||
| 569 | Make numbered backups for files that have numbered backups already. | ||
| 570 | Otherwise, make single backups. | ||
| 571 | @item never | ||
| 572 | Never make numbered backups; always make single backups. | ||
| 573 | @end table | ||
| 574 | |||
| 575 | @noindent | ||
| 576 | The usual way to set this variable is globally, through your | ||
| 577 | @file{.emacs} file or the customization buffer. However, you can set | ||
| 578 | @code{version-control} locally in an individual buffer to control the | ||
| 579 | making of backups for that buffer's file. For example, Rmail mode | ||
| 580 | locally sets @code{version-control} to @code{never} to make sure that | ||
| 581 | there is only one backup for an Rmail file. @xref{Locals}. | ||
| 582 | |||
| 583 | @cindex @env{VERSION_CONTROL} environment variable | ||
| 584 | If you set the environment variable @env{VERSION_CONTROL}, to tell | ||
| 585 | various GNU utilities what to do with backup files, Emacs also obeys the | ||
| 586 | environment variable by setting the Lisp variable @code{version-control} | ||
| 587 | accordingly at startup. If the environment variable's value is @samp{t} | ||
| 588 | or @samp{numbered}, then @code{version-control} becomes @code{t}; if the | ||
| 589 | value is @samp{nil} or @samp{existing}, then @code{version-control} | ||
| 590 | becomes @code{nil}; if it is @samp{never} or @samp{simple}, then | ||
| 591 | @code{version-control} becomes @code{never}. | ||
| 592 | |||
| 559 | @node Backup Names | 593 | @node Backup Names |
| 560 | @subsubsection Single or Numbered Backups | 594 | @subsubsection Single or Numbered Backups |
| 561 | 595 | ||
| 562 | If you choose to have a single backup file (this is the default), | 596 | When Emacs makes a single backup file, its name is normally |
| 563 | the backup file's name is normally constructed by appending @samp{~} to the | 597 | constructed by appending @samp{~} to the file name being edited; thus, |
| 564 | file name being edited; thus, the backup file for @file{eval.c} would | 598 | the backup file for @file{eval.c} would be @file{eval.c~}. |
| 565 | be @file{eval.c~}. | ||
| 566 | 599 | ||
| 567 | @vindex make-backup-file-name-function | 600 | @vindex make-backup-file-name-function |
| 568 | @vindex backup-directory-alist | 601 | @vindex backup-directory-alist |
| @@ -593,36 +626,6 @@ through names like @file{eval.c.~259~} and beyond. The variable | |||
| 593 | @code{backup-directory-alist} applies to numbered backups just as | 626 | @code{backup-directory-alist} applies to numbered backups just as |
| 594 | usual. | 627 | usual. |
| 595 | 628 | ||
| 596 | @vindex version-control | ||
| 597 | The choice of single backup or numbered backups is controlled by the | ||
| 598 | variable @code{version-control}. Its possible values are | ||
| 599 | |||
| 600 | @table @code | ||
| 601 | @item t | ||
| 602 | Make numbered backups. | ||
| 603 | @item nil | ||
| 604 | Make numbered backups for files that have numbered backups already. | ||
| 605 | Otherwise, make single backups. | ||
| 606 | @item never | ||
| 607 | Never make numbered backups; always make single backups. | ||
| 608 | @end table | ||
| 609 | |||
| 610 | @noindent | ||
| 611 | You can set @code{version-control} locally in an individual buffer to | ||
| 612 | control the making of backups for that buffer's file. For example, | ||
| 613 | Rmail mode locally sets @code{version-control} to @code{never} to make sure | ||
| 614 | that there is only one backup for an Rmail file. @xref{Locals}. | ||
| 615 | |||
| 616 | @cindex @env{VERSION_CONTROL} environment variable | ||
| 617 | If you set the environment variable @env{VERSION_CONTROL}, to tell | ||
| 618 | various GNU utilities what to do with backup files, Emacs also obeys the | ||
| 619 | environment variable by setting the Lisp variable @code{version-control} | ||
| 620 | accordingly at startup. If the environment variable's value is @samp{t} | ||
| 621 | or @samp{numbered}, then @code{version-control} becomes @code{t}; if the | ||
| 622 | value is @samp{nil} or @samp{existing}, then @code{version-control} | ||
| 623 | becomes @code{nil}; if it is @samp{never} or @samp{simple}, then | ||
| 624 | @code{version-control} becomes @code{never}. | ||
| 625 | |||
| 626 | @node Backup Deletion | 629 | @node Backup Deletion |
| 627 | @subsubsection Automatic Deletion of Backups | 630 | @subsubsection Automatic Deletion of Backups |
| 628 | 631 | ||
| @@ -822,6 +825,7 @@ different name, and use @code{diff} to compare the two files.@refill | |||
| 822 | @subsection Shadowing Files | 825 | @subsection Shadowing Files |
| 823 | @cindex shadow files | 826 | @cindex shadow files |
| 824 | @cindex file shadows | 827 | @cindex file shadows |
| 828 | @findex shadow-initialize | ||
| 825 | 829 | ||
| 826 | @table @kbd | 830 | @table @kbd |
| 827 | @item M-x shadow-initialize | 831 | @item M-x shadow-initialize |
| @@ -867,7 +871,6 @@ shadow-define-cluster}. | |||
| 867 | 871 | ||
| 868 | @node Time Stamps | 872 | @node Time Stamps |
| 869 | @subsection Updating Time Stamps Automatically | 873 | @subsection Updating Time Stamps Automatically |
| 870 | @findex time-stamp | ||
| 871 | @cindex time stamps | 874 | @cindex time stamps |
| 872 | @cindex modification dates | 875 | @cindex modification dates |
| 873 | @cindex locale, date format | 876 | @cindex locale, date format |
| @@ -888,6 +891,7 @@ or like this: | |||
| 888 | Time-stamp: " " | 891 | Time-stamp: " " |
| 889 | @end example | 892 | @end example |
| 890 | 893 | ||
| 894 | @findex time-stamp | ||
| 891 | Then add the hook function @code{time-stamp} to the hook | 895 | Then add the hook function @code{time-stamp} to the hook |
| 892 | @code{before-save-hook}; that hook function will automatically update | 896 | @code{before-save-hook}; that hook function will automatically update |
| 893 | the time stamp, inserting the current date and time when you save the | 897 | the time stamp, inserting the current date and time when you save the |
| @@ -946,24 +950,26 @@ discard your changes.) | |||
| 946 | You may find it useful to have Emacs revert files automatically when | 950 | You may find it useful to have Emacs revert files automatically when |
| 947 | they change. Three minor modes are available to do this. | 951 | they change. Three minor modes are available to do this. |
| 948 | 952 | ||
| 949 | @kbd{M-x global-auto-revert-mode} runs Global Auto-Revert mode, | 953 | @kbd{M-x global-auto-revert-mode} enables Global Auto-Revert mode, |
| 950 | which periodically checks all file buffers and reverts when the | 954 | which periodically checks all file buffers and reverts when the |
| 951 | corresponding file has changed. @kbd{M-x auto-revert-mode} runs a | 955 | corresponding file has changed. @kbd{M-x auto-revert-mode} enables a |
| 952 | local version, Auto-Revert mode, which applies only to the buffer in | 956 | local version, Auto-Revert mode, which applies only to the current |
| 953 | which it was activated. Auto-Revert mode can be used to ``tail'' a | 957 | buffer. |
| 954 | file, such as a system log, so that changes made to that file by other | 958 | |
| 955 | programs are continuously displayed. To do this, just move the point | 959 | You can use Auto-Revert mode to ``tail'' a file such as a system |
| 956 | to the end of the buffer, and it will stay there as the file contents | 960 | log, so that changes made to that file by other programs are |
| 957 | change. However, if you are sure that the file will only change by | 961 | continuously displayed. To do this, just move the point to the end of |
| 958 | growing at the end, you can tail the file more efficiently using | 962 | the buffer, and it will stay there as the file contents change. |
| 959 | Auto-Revert Tail mode, @kbd{M-x auto-revert-tail-mode}. | 963 | However, if you are sure that the file will only change by growing at |
| 964 | the end, use Auto-Revert Tail mode instead | ||
| 965 | (@code{auto-revert-tail-mode}). It is more efficient for this. | ||
| 960 | 966 | ||
| 961 | @vindex auto-revert-interval | 967 | @vindex auto-revert-interval |
| 962 | The variable @code{auto-revert-interval} controls how often to check | 968 | The variable @code{auto-revert-interval} controls how often to check |
| 963 | for a changed file. Since checking a remote file is too slow, these | 969 | for a changed file. Since checking a remote file is too slow, these |
| 964 | modes do not check or revert remote files. | 970 | modes do not check or revert remote files. |
| 965 | 971 | ||
| 966 | @xref{VC Mode Line}, for Auto Revert peculiarities in buffers that | 972 | @xref{VC Mode Line}, for Auto Revert peculiarities in buffers that |
| 967 | visit files under version control. | 973 | visit files under version control. |
| 968 | 974 | ||
| 969 | @node Auto Save | 975 | @node Auto Save |
| @@ -977,13 +983,13 @@ your keystrokes) without being asked. This is called @dfn{auto-saving}. | |||
| 977 | It prevents you from losing more than a limited amount of work if the | 983 | It prevents you from losing more than a limited amount of work if the |
| 978 | system crashes. | 984 | system crashes. |
| 979 | 985 | ||
| 980 | When Emacs determines that it is time for auto-saving, each buffer is | 986 | When Emacs determines that it is time for auto-saving, it considers |
| 981 | considered, and is auto-saved if auto-saving is turned on for it and it | 987 | each buffer, and each is auto-saved if auto-saving is enabled for it |
| 982 | has been changed since the last time it was auto-saved. The message | 988 | and it has been changed since the last time it was auto-saved. The |
| 983 | @samp{Auto-saving...} is displayed in the echo area during auto-saving, | 989 | message @samp{Auto-saving...} is displayed in the echo area during |
| 984 | if any files are actually auto-saved. Errors occurring during | 990 | auto-saving, if any files are actually auto-saved. Errors occurring |
| 985 | auto-saving are caught so that they do not interfere with the execution | 991 | during auto-saving are caught so that they do not interfere with the |
| 986 | of commands you have been typing. | 992 | execution of commands you have been typing. |
| 987 | 993 | ||
| 988 | @menu | 994 | @menu |
| 989 | * Files: Auto Save Files. The file where auto-saved changes are | 995 | * Files: Auto Save Files. The file where auto-saved changes are |
| @@ -1041,10 +1047,10 @@ saving. | |||
| 1041 | 1047 | ||
| 1042 | @vindex delete-auto-save-files | 1048 | @vindex delete-auto-save-files |
| 1043 | A buffer's auto-save file is deleted when you save the buffer in its | 1049 | A buffer's auto-save file is deleted when you save the buffer in its |
| 1044 | visited file. To inhibit this, set the variable @code{delete-auto-save-files} | 1050 | visited file. (You can inhibit this by setting the variable |
| 1045 | to @code{nil}. Changing the visited file name with @kbd{C-x C-w} or | 1051 | @code{delete-auto-save-files} to @code{nil}.) Changing the visited |
| 1046 | @code{set-visited-file-name} renames any auto-save file to go with | 1052 | file name with @kbd{C-x C-w} or @code{set-visited-file-name} renames |
| 1047 | the new visited name. | 1053 | any auto-save file to go with the new visited name. |
| 1048 | 1054 | ||
| 1049 | @node Auto Save Control | 1055 | @node Auto Save Control |
| 1050 | @subsection Controlling Auto-Saving | 1056 | @subsection Controlling Auto-Saving |
| @@ -1284,9 +1290,11 @@ merging, and use of symbolic links and meta-data in repositories. | |||
| 1284 | terms of capabilities, it is the weakest of the six that VC supports. | 1290 | terms of capabilities, it is the weakest of the six that VC supports. |
| 1285 | VC compensates for certain features missing in SCCS (snapshots, for | 1291 | VC compensates for certain features missing in SCCS (snapshots, for |
| 1286 | example) by implementing them itself, but some other VC features, such | 1292 | example) by implementing them itself, but some other VC features, such |
| 1287 | as multiple branches, are not available with SCCS. You should use | 1293 | as multiple branches, are not available with SCCS. Since SCCS is |
| 1288 | SCCS only if for some reason you cannot use RCS, or one of the | 1294 | non-free, not respecting its users freedom,d, you should not use it; |
| 1289 | higher-level systems such as CVS or GNU Arch. | 1295 | use its free replacement CSSC instead. But you should use CSSC only |
| 1296 | if for some reason you cannot use RCS, or one of the higher-level | ||
| 1297 | systems such as CVS or GNU Arch. | ||
| 1290 | 1298 | ||
| 1291 | In the following, we discuss mainly RCS, SCCS and CVS. Nearly | 1299 | In the following, we discuss mainly RCS, SCCS and CVS. Nearly |
| 1292 | everything said about CVS applies to GNU Arch, Subversion and Meta-CVS | 1300 | everything said about CVS applies to GNU Arch, Subversion and Meta-CVS |
| @@ -1549,13 +1557,13 @@ Version Control}). | |||
| 1549 | When you check in changes, @kbd{C-x v v} first reads a log entry. It | 1557 | When you check in changes, @kbd{C-x v v} first reads a log entry. It |
| 1550 | pops up a buffer called @samp{*VC-Log*} for you to enter the log entry. | 1558 | pops up a buffer called @samp{*VC-Log*} for you to enter the log entry. |
| 1551 | 1559 | ||
| 1552 | Sometimes the @samp{*VC-Log*} buffer contains default text when you enter it, | 1560 | Sometimes the @samp{*VC-Log*} buffer contains default text when you enter it, |
| 1553 | typically the last log message entered. If it does, mark and point | 1561 | typically the last log message entered. If it does, mark and point |
| 1554 | are set around the entire contents of the buffer so that it is easy to | 1562 | are set around the entire contents of the buffer so that it is easy to |
| 1555 | kill the contents of the buffer with @kbd{C-w}. | 1563 | kill the contents of the buffer with @kbd{C-w}. |
| 1556 | 1564 | ||
| 1557 | @findex log-edit-insert-changelog | 1565 | @findex log-edit-insert-changelog |
| 1558 | If you work by writing entries in the @file{ChangeLog} | 1566 | If you work by writing entries in the @file{ChangeLog} |
| 1559 | (@pxref{Change Log}) and then commit the change under revision | 1567 | (@pxref{Change Log}) and then commit the change under revision |
| 1560 | control, you can generate the Log Edit text from the ChangeLog using | 1568 | control, you can generate the Log Edit text from the ChangeLog using |
| 1561 | @kbd{C-c C-a} (@kbd{log-edit-insert-changelog}). This looks for | 1569 | @kbd{C-c C-a} (@kbd{log-edit-insert-changelog}). This looks for |
| @@ -1565,13 +1573,13 @@ if the top entry was made under your user name on the current date. | |||
| 1565 | @xref{Change Logs and VC}, for the opposite way of | 1573 | @xref{Change Logs and VC}, for the opposite way of |
| 1566 | working---generating ChangeLog entries from the revision control log. | 1574 | working---generating ChangeLog entries from the revision control log. |
| 1567 | 1575 | ||
| 1568 | In the @samp{*VC-Log*} buffer, @kbd{C-c C-f} (@kbd{M-x log-edit-show-files}) | 1576 | In the @samp{*VC-Log*} buffer, @kbd{C-c C-f} (@kbd{M-x log-edit-show-files}) |
| 1569 | shows the list of files to be committed in case you need to check | 1577 | shows the list of files to be committed in case you need to check |
| 1570 | that. (This can be a list of more than one file if you use VC Dired | 1578 | that. (This can be a list of more than one file if you use VC Dired |
| 1571 | mode or PCL-CVS. @xref{VC Dired Mode}, and @ref{Top, , About PCL-CVS, | 1579 | mode or PCL-CVS. @xref{VC Dired Mode}, and @ref{Top, , About PCL-CVS, |
| 1572 | pcl-cvs, PCL-CVS --- The Emacs Front-End to CVS}.) | 1580 | pcl-cvs, PCL-CVS --- The Emacs Front-End to CVS}.) |
| 1573 | 1581 | ||
| 1574 | When you have finished editing the log message, type @kbd{C-c C-c} to | 1582 | When you have finished editing the log message, type @kbd{C-c C-c} to |
| 1575 | exit the buffer and commit the change. | 1583 | exit the buffer and commit the change. |
| 1576 | 1584 | ||
| 1577 | To abort check-in, just @strong{don't} type @kbd{C-c C-c} in that | 1585 | To abort check-in, just @strong{don't} type @kbd{C-c C-c} in that |
| @@ -1665,8 +1673,8 @@ them; they exist only in the records of the master file. | |||
| 1665 | For some backends, you can display the file @dfn{annotated} with | 1673 | For some backends, you can display the file @dfn{annotated} with |
| 1666 | per-line version information and using colors to enhance the visual | 1674 | per-line version information and using colors to enhance the visual |
| 1667 | appearance, with the command @kbd{M-x vc-annotate}. | 1675 | appearance, with the command @kbd{M-x vc-annotate}. |
| 1668 | It creates a new buffer | 1676 | It creates a new buffer (the ``annotate buffer'') displaying the |
| 1669 | to display file's text, colored to show how old each part is. Text | 1677 | file's text, with each part colored to show how old it is. Text |
| 1670 | colored red is new, blue means old, and intermediate colors indicate | 1678 | colored red is new, blue means old, and intermediate colors indicate |
| 1671 | intermediate ages. By default, the time scale is 360 days, so that | 1679 | intermediate ages. By default, the time scale is 360 days, so that |
| 1672 | everything more than one year old is shown in blue. | 1680 | everything more than one year old is shown in blue. |
| @@ -1790,8 +1798,8 @@ changes to the current file, including the text of the log entries. The | |||
| 1790 | output appears in a separate window. The point is centered at the | 1798 | output appears in a separate window. The point is centered at the |
| 1791 | revision of the file that is currently being visited. | 1799 | revision of the file that is currently being visited. |
| 1792 | 1800 | ||
| 1793 | From the change log buffer, the following keys are used to move | 1801 | In the change log buffer, you can use the following keys to move |
| 1794 | between the logs of revisions and files, to view past revisions, and | 1802 | between the logs of revisions and of files, to view past revisions, and |
| 1795 | to view diffs: | 1803 | to view diffs: |
| 1796 | 1804 | ||
| 1797 | @table @kbd | 1805 | @table @kbd |
| @@ -2410,14 +2418,16 @@ or a snapshot against a named version. | |||
| 2410 | 2418 | ||
| 2411 | @cindex named configurations (RCS) | 2419 | @cindex named configurations (RCS) |
| 2412 | VC's snapshot facilities are modeled on RCS's named-configuration | 2420 | VC's snapshot facilities are modeled on RCS's named-configuration |
| 2413 | support. They use RCS's native facilities for this, so under VC | 2421 | support. They use RCS's native facilities for this, so |
| 2414 | snapshots made using RCS are visible even when you bypass VC. | 2422 | snapshots made using RCS through VC are visible even when you bypass VC. |
| 2415 | 2423 | ||
| 2416 | @c worded verbosely to avoid overfull hbox. | 2424 | @c worded verbosely to avoid overfull hbox. |
| 2417 | For SCCS, VC implements snapshots itself. The files it uses contain | 2425 | For SCCS, VC implements snapshots itself. The files it uses contain |
| 2418 | name/file/version-number triples. These snapshots are visible only | 2426 | name/file/version-number triples. These snapshots are visible only |
| 2419 | through VC. | 2427 | through VC. |
| 2420 | 2428 | ||
| 2429 | @c ??? What about CVS? | ||
| 2430 | |||
| 2421 | A snapshot is a set of checked-in versions. So make sure that all the | 2431 | A snapshot is a set of checked-in versions. So make sure that all the |
| 2422 | files are checked in and not locked when you make a snapshot. | 2432 | files are checked in and not locked when you make a snapshot. |
| 2423 | 2433 | ||
| @@ -2472,6 +2482,8 @@ most recent entry in the change log file. | |||
| 2472 | 2482 | ||
| 2473 | This command works with RCS or CVS only, not with SCCS. | 2483 | This command works with RCS or CVS only, not with SCCS. |
| 2474 | 2484 | ||
| 2485 | @c ??? What about other back ends? | ||
| 2486 | |||
| 2475 | @item C-u C-x v a | 2487 | @item C-u C-x v a |
| 2476 | As above, but only find entries for the current buffer's file. | 2488 | As above, but only find entries for the current buffer's file. |
| 2477 | 2489 | ||
| @@ -2625,6 +2637,8 @@ directly into working files. Certain special strings called | |||
| 2625 | @dfn{version headers} are replaced in each successive version by the | 2637 | @dfn{version headers} are replaced in each successive version by the |
| 2626 | number of that version. | 2638 | number of that version. |
| 2627 | 2639 | ||
| 2640 | @c ??? How does this relate to CVS? | ||
| 2641 | |||
| 2628 | If you are using RCS, and version headers are present in your working | 2642 | If you are using RCS, and version headers are present in your working |
| 2629 | files, Emacs can use them to determine the current version and the | 2643 | files, Emacs can use them to determine the current version and the |
| 2630 | locking state of the files. This is more reliable than referring to the | 2644 | locking state of the files. This is more reliable than referring to the |
| @@ -2657,7 +2671,7 @@ setting the variables @code{vc-@var{backend}-header} where | |||
| 2657 | each string in the list is inserted as a separate header on a line of | 2671 | each string in the list is inserted as a separate header on a line of |
| 2658 | its own. | 2672 | its own. |
| 2659 | 2673 | ||
| 2660 | It is often necessary to use ``superfluous'' backslashes when | 2674 | It may be necessary to use apparently-superfluous backslashes when |
| 2661 | writing the strings that you put in this variable. For instance, you | 2675 | writing the strings that you put in this variable. For instance, you |
| 2662 | might write @code{"$Id\$"} rather than @code{"$Id@w{$}"}. The extra | 2676 | might write @code{"$Id\$"} rather than @code{"$Id@w{$}"}. The extra |
| 2663 | backslash prevents the string constant from being interpreted as a | 2677 | backslash prevents the string constant from being interpreted as a |
| @@ -2899,8 +2913,8 @@ only for repositories from hosts that match the pattern. | |||
| 2899 | listing} is a list of all the files in a directory. Emacs provides | 2913 | listing} is a list of all the files in a directory. Emacs provides |
| 2900 | commands to create and delete directories, and to make directory | 2914 | commands to create and delete directories, and to make directory |
| 2901 | listings in brief format (file names only) and verbose format (sizes, | 2915 | listings in brief format (file names only) and verbose format (sizes, |
| 2902 | dates, and authors included). There is also a directory browser called | 2916 | dates, and authors included). Emacs also includes a directory browser |
| 2903 | Dired; see @ref{Dired}. | 2917 | feature called Dired; see @ref{Dired}. |
| 2904 | 2918 | ||
| 2905 | @table @kbd | 2919 | @table @kbd |
| 2906 | @item C-x C-d @var{dir-or-pattern} @key{RET} | 2920 | @item C-x C-d @var{dir-or-pattern} @key{RET} |
| @@ -2950,9 +2964,10 @@ default). | |||
| 2950 | 2964 | ||
| 2951 | @vindex directory-free-space-program | 2965 | @vindex directory-free-space-program |
| 2952 | @vindex directory-free-space-args | 2966 | @vindex directory-free-space-args |
| 2953 | Emacs adds information about the amount of free space on the disk | 2967 | In verbose directory listings, Emacs adds information about the |
| 2954 | that contains the directory. To do this, it runs the program | 2968 | amount of free space on the disk that contains the directory. To do |
| 2955 | specified by @code{directory-free-space-program} with arguments | 2969 | this, it runs the program specified by |
| 2970 | @code{directory-free-space-program} with arguments | ||
| 2956 | @code{directory-free-space-args}. | 2971 | @code{directory-free-space-args}. |
| 2957 | 2972 | ||
| 2958 | @node Comparing Files | 2973 | @node Comparing Files |
| @@ -2967,19 +2982,26 @@ running the @code{diff} program, using options taken from the variable | |||
| 2967 | @code{diff-switches}. The value of @code{diff-switches} should be a | 2982 | @code{diff-switches}. The value of @code{diff-switches} should be a |
| 2968 | string; the default is @code{"-c"} to specify a context diff. | 2983 | string; the default is @code{"-c"} to specify a context diff. |
| 2969 | 2984 | ||
| 2970 | @findex diff-goto-source | ||
| 2971 | After running @kbd{M-x diff}, you can use @kbd{C-x `} to visit | ||
| 2972 | successive changed locations in the two source files, as in | ||
| 2973 | Compilation mode (@pxref{Compilation Mode}.) In the @samp{*diff*} buffer, | ||
| 2974 | you can move to a particular hunk of changes and type @kbd{C-c C-c} | ||
| 2975 | (@code{diff-goto-source}) to visit the corresponding source location. | ||
| 2976 | |||
| 2977 | @findex diff-backup | 2985 | @findex diff-backup |
| 2978 | The command @kbd{M-x diff-backup} compares a specified file with its most | 2986 | The command @kbd{M-x diff-backup} compares a specified file with its most |
| 2979 | recent backup. If you specify the name of a backup file, | 2987 | recent backup. If you specify the name of a backup file, |
| 2980 | @code{diff-backup} compares it with the source file that it is a backup | 2988 | @code{diff-backup} compares it with the source file that it is a backup |
| 2981 | of. | 2989 | of. |
| 2982 | 2990 | ||
| 2991 | @findex diff-goto-source | ||
| 2992 | @findex diff-mode | ||
| 2993 | @cindex Diff mode | ||
| 2994 | The @samp{*diff*} buffer uses Diff mode, which enables you to use | ||
| 2995 | @kbd{C-x `} to visit successive changed locations in the two source | ||
| 2996 | files, as in Compilation mode (@pxref{Compilation Mode}.) You can | ||
| 2997 | also move to a particular hunk of changes and type @kbd{C-c C-c} | ||
| 2998 | (@code{diff-goto-source}) to visit the corresponding source location. | ||
| 2999 | |||
| 3000 | @cindex patches | ||
| 3001 | Differences between versions of files are often distributed as | ||
| 3002 | patches, which are the output from the @command{diff} program. You | ||
| 3003 | can use Diff mode to operate on a patch by typing @kbd{M-x diff-mode}. | ||
| 3004 | |||
| 2983 | @findex compare-windows | 3005 | @findex compare-windows |
| 2984 | The command @kbd{M-x compare-windows} compares the text in the | 3006 | The command @kbd{M-x compare-windows} compares the text in the |
| 2985 | current window with that in the next window. (For more information | 3007 | current window with that in the next window. (For more information |
| @@ -2990,10 +3012,10 @@ one character at a time, until it reaches characters that don't match. | |||
| 2990 | Then the command exits. | 3012 | Then the command exits. |
| 2991 | 3013 | ||
| 2992 | If point in the two windows is followed by non-matching text when | 3014 | If point in the two windows is followed by non-matching text when |
| 2993 | the command starts, it tries heuristically to advance up to matching | 3015 | the command starts, @kbd{M-x compare-windows} tries heuristically to |
| 2994 | text in the two windows, and then exits. So if you use @kbd{M-x | 3016 | advance up to matching text in the two windows, and then exits. So if |
| 2995 | compare-windows} repeatedly, each time it either skips one matching | 3017 | you use @kbd{M-x compare-windows} repeatedly, each time it either |
| 2996 | range or finds the start of another. | 3018 | skips one matching range or finds the start of another. |
| 2997 | 3019 | ||
| 2998 | @vindex compare-ignore-case | 3020 | @vindex compare-ignore-case |
| 2999 | @vindex compare-ignore-whitespace | 3021 | @vindex compare-ignore-whitespace |
| @@ -3004,16 +3026,6 @@ If the variable @code{compare-ignore-whitespace} is non-@code{nil}, | |||
| 3004 | @code{compare-windows} normally ignores changes in whitespace, and a | 3026 | @code{compare-windows} normally ignores changes in whitespace, and a |
| 3005 | prefix argument turns that off. | 3027 | prefix argument turns that off. |
| 3006 | 3028 | ||
| 3007 | @findex diff-mode | ||
| 3008 | @cindex diffs | ||
| 3009 | @cindex patches | ||
| 3010 | @cindex Diff mode | ||
| 3011 | Differences between versions of files are often distributed as | ||
| 3012 | @dfn{patches}, which are the output from @command{diff} or a version | ||
| 3013 | control system that uses @command{diff}. @kbd{M-x diff-mode} turns on | ||
| 3014 | Diff mode, a major mode for viewing and editing patches, either as | ||
| 3015 | ``unified diffs'' or ``context diffs.'' | ||
| 3016 | |||
| 3017 | @cindex Smerge mode | 3029 | @cindex Smerge mode |
| 3018 | @findex smerge-mode | 3030 | @findex smerge-mode |
| 3019 | @cindex failed merges | 3031 | @cindex failed merges |
| @@ -3154,19 +3166,20 @@ mode called Tar mode which provides a Dired-like list of the contents | |||
| 3154 | would in Dired, and visit the subfiles contained in the archive. | 3166 | would in Dired, and visit the subfiles contained in the archive. |
| 3155 | However, not all Dired commands are available in Tar mode. | 3167 | However, not all Dired commands are available in Tar mode. |
| 3156 | 3168 | ||
| 3157 | If you enable Auto Compression mode (@pxref{Compressed Files}), then | 3169 | If Auto Compression mode is enabled (@pxref{Compressed Files}), then |
| 3158 | Tar mode is used also for compressed archives---files with extensions | 3170 | Tar mode is used also for compressed archives---files with extensions |
| 3159 | @samp{.tgz}, @code{.tar.Z} and @code{.tar.gz}. | 3171 | @samp{.tgz}, @code{.tar.Z} and @code{.tar.gz}. |
| 3160 | 3172 | ||
| 3161 | The keys @kbd{e}, @kbd{f} and @key{RET} all extract a component file | 3173 | The keys @kbd{e}, @kbd{f} and @key{RET} all extract a component file |
| 3162 | into its own buffer. You can edit it there and when you save the buffer | 3174 | into its own buffer. You can edit it there, and if you save the |
| 3163 | the edited version will replace the version in the Tar buffer. @kbd{v} | 3175 | buffer, the edited version will replace the version in the Tar buffer. |
| 3164 | extracts a file into a buffer in View mode. @kbd{o} extracts the file | 3176 | @kbd{v} extracts a file into a buffer in View mode. @kbd{o} extracts |
| 3165 | and displays it in another window, so you could edit the file and | 3177 | the file and displays it in another window, so you could edit the file |
| 3166 | operate on the archive simultaneously. @kbd{d} marks a file for | 3178 | and operate on the archive simultaneously. @kbd{d} marks a file for |
| 3167 | deletion when you later use @kbd{x}, and @kbd{u} unmarks a file, as in | 3179 | deletion when you later use @kbd{x}, and @kbd{u} unmarks a file, as in |
| 3168 | Dired. @kbd{C} copies a file from the archive to disk and @kbd{R} | 3180 | Dired. @kbd{C} copies a file from the archive to disk and @kbd{R} |
| 3169 | renames a file. @kbd{g} reverts the buffer from the archive on disk. | 3181 | renames a file within the archive. @kbd{g} reverts the buffer from |
| 3182 | the archive on disk. | ||
| 3170 | 3183 | ||
| 3171 | The keys @kbd{M}, @kbd{G}, and @kbd{O} change the file's permission | 3184 | The keys @kbd{M}, @kbd{G}, and @kbd{O} change the file's permission |
| 3172 | bits, group, and owner, respectively. | 3185 | bits, group, and owner, respectively. |
| @@ -3282,8 +3295,6 @@ This is achieved using the variable @code{auto-save-file-name-transforms}. | |||
| 3282 | Normally, if you do not specify a user name in a remote file name, | 3295 | Normally, if you do not specify a user name in a remote file name, |
| 3283 | that means to use your own user name. But if you set the variable | 3296 | that means to use your own user name. But if you set the variable |
| 3284 | @code{ange-ftp-default-user} to a string, that string is used instead. | 3297 | @code{ange-ftp-default-user} to a string, that string is used instead. |
| 3285 | (The Emacs package that implements FTP file access is called | ||
| 3286 | @code{ange-ftp}.) | ||
| 3287 | 3298 | ||
| 3288 | @cindex anonymous FTP | 3299 | @cindex anonymous FTP |
| 3289 | @vindex ange-ftp-generate-anonymous-password | 3300 | @vindex ange-ftp-generate-anonymous-password |
| @@ -3293,8 +3304,8 @@ are handled specially. The variable | |||
| 3293 | @code{ange-ftp-generate-anonymous-password} controls what happens: if | 3304 | @code{ange-ftp-generate-anonymous-password} controls what happens: if |
| 3294 | the value of this variable is a string, then that string is used as | 3305 | the value of this variable is a string, then that string is used as |
| 3295 | the password; if non-@code{nil} (the default), then the value of | 3306 | the password; if non-@code{nil} (the default), then the value of |
| 3296 | @code{user-mail-address} is used; if @code{nil}, the user is prompted | 3307 | @code{user-mail-address} is used; if @code{nil}, then Emacs prompts |
| 3297 | for a password as normal. | 3308 | you for a password as usual. |
| 3298 | 3309 | ||
| 3299 | @cindex firewall, and accessing remote files | 3310 | @cindex firewall, and accessing remote files |
| 3300 | @cindex gateway, and remote file access with @code{ange-ftp} | 3311 | @cindex gateway, and remote file access with @code{ange-ftp} |
| @@ -3453,7 +3464,7 @@ This adds a @samp{Filesets} menu to the menu bar. | |||
| 3453 | 3464 | ||
| 3454 | @findex filesets-add-buffer | 3465 | @findex filesets-add-buffer |
| 3455 | @findex filesets-remove-buffer | 3466 | @findex filesets-remove-buffer |
| 3456 | The simplest way to define filesets is by adding files to them one | 3467 | The simplest way to define a fileset is by adding files to it one |
| 3457 | at a time. To add a file to fileset @var{name}, visit the file and | 3468 | at a time. To add a file to fileset @var{name}, visit the file and |
| 3458 | type @kbd{M-x filesets-add-buffer @kbd{RET} @var{name} @kbd{RET}}. If | 3469 | type @kbd{M-x filesets-add-buffer @kbd{RET} @var{name} @kbd{RET}}. If |
| 3459 | there is no fileset @var{name}, this creates a new one, which | 3470 | there is no fileset @var{name}, this creates a new one, which |
diff --git a/man/frames.texi b/man/frames.texi index dd076262e82..3561bd89b2d 100644 --- a/man/frames.texi +++ b/man/frames.texi | |||
| @@ -3,29 +3,29 @@ | |||
| 3 | @c 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. | 3 | @c 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. |
| 4 | @c See file emacs.texi for copying conditions. | 4 | @c See file emacs.texi for copying conditions. |
| 5 | @node Frames, International, Windows, Top | 5 | @node Frames, International, Windows, Top |
| 6 | @chapter Frames and X Windows | 6 | @chapter Frames and Graphical Displays |
| 7 | @cindex frames | 7 | @cindex frames |
| 8 | 8 | ||
| 9 | When using the X Window System, you can create multiple windows at the | 9 | When using a graphical display, you can create multiple windows at |
| 10 | X level in a single Emacs session. Each X window that belongs to Emacs | 10 | the system in a single Emacs session. Each system-level window that |
| 11 | displays a @dfn{frame} which can contain one or several Emacs windows. | 11 | belongs to Emacs displays a @dfn{frame} which can contain one or |
| 12 | A frame initially contains a single general-purpose Emacs window which | 12 | several Emacs windows. A frame initially contains a single |
| 13 | you can subdivide vertically or horizontally into smaller windows. A | 13 | general-purpose Emacs window which you can subdivide vertically or |
| 14 | frame normally contains its own echo area and minibuffer, but you can | 14 | horizontally into smaller windows. A frame normally contains its own |
| 15 | make frames that don't have these---they use the echo area and | 15 | echo area and minibuffer, but you can make frames that don't have |
| 16 | minibuffer of another frame. | 16 | these---they use the echo area and minibuffer of another frame. |
| 17 | 17 | ||
| 18 | Editing you do in one frame also affects the other frames. For | 18 | To avoid confusion, we reserve the word ``window'' for the |
| 19 | subdivisions that Emacs implements, and never use it to refer to a | ||
| 20 | frame. | ||
| 21 | |||
| 22 | Editing you do in one frame affects the other frames. For | ||
| 19 | instance, if you put text in the kill ring in one frame, you can yank it | 23 | instance, if you put text in the kill ring in one frame, you can yank it |
| 20 | in another frame. If you exit Emacs through @kbd{C-x C-c} in one frame, | 24 | in another frame. If you exit Emacs through @kbd{C-x C-c} in one frame, |
| 21 | it terminates all the frames. To delete just one frame, use @kbd{C-x 5 | 25 | it terminates all the frames. To delete just one frame, use @kbd{C-x 5 |
| 22 | 0} (that is zero, not @kbd{o}). | 26 | 0} (that is zero, not @kbd{o}). |
| 23 | 27 | ||
| 24 | To avoid confusion, we reserve the word ``window'' for the | 28 | Emacs compiled for MS-DOS emulates some windowing functionality, |
| 25 | subdivisions that Emacs implements, and never use it to refer to a | ||
| 26 | frame. | ||
| 27 | |||
| 28 | Emacs compiled for MS-DOS emulates some aspects of the window system | ||
| 29 | so that you can use many of the features described in this chapter. | 29 | so that you can use many of the features described in this chapter. |
| 30 | @xref{MS-DOS Mouse}, for more information. | 30 | @xref{MS-DOS Mouse}, for more information. |
| 31 | 31 | ||
| @@ -185,46 +185,46 @@ point. Then it does not matter where you click, or even which of the | |||
| 185 | frame's windows you click on. The default value is @code{nil}. This | 185 | frame's windows you click on. The default value is @code{nil}. This |
| 186 | variable also affects yanking the secondary selection. | 186 | variable also affects yanking the secondary selection. |
| 187 | 187 | ||
| 188 | @cindex cutting and X | 188 | @cindex cutting |
| 189 | @cindex pasting and X | 189 | @cindex pasting |
| 190 | @cindex X cutting and pasting | 190 | @cindex X cutting and pasting |
| 191 | To copy text to another X window, kill it or save it in the kill ring. | 191 | To copy text to another windowing application, kill it or save it in |
| 192 | Under X, this also sets the @dfn{primary selection}. Then use the | 192 | the kill ring. Then use the ``paste'' or ``yank'' command of the |
| 193 | ``paste'' or ``yank'' command of the program operating the other window | 193 | other application to insert the text. |
| 194 | to insert the text from the selection. | ||
| 195 | |||
| 196 | To copy text from another X window, use the ``cut'' or ``copy'' | ||
| 197 | command of the program operating the other window, to select the text | ||
| 198 | you want. Then yank it in Emacs with @kbd{C-y} or @kbd{Mouse-2}. | ||
| 199 | 194 | ||
| 200 | The standard coding system for X selections is | 195 | To copy text from another windowing application, use its ``cut'' or |
| 201 | @code{compound-text-with-extensions}. To specify another coding | 196 | ``copy'' command to select the text you want. Then yank it in Emacs |
| 202 | system for X selections, use @kbd{C-x @key{RET} x} or @kbd{C-x | 197 | with @kbd{C-y} or @kbd{Mouse-2}. |
| 203 | @key{RET} X}. @xref{Specify Coding}. | ||
| 204 | 198 | ||
| 205 | @cindex primary selection | 199 | @cindex primary selection |
| 206 | @cindex cut buffer | 200 | @cindex cut buffer |
| 207 | @cindex selection, primary | 201 | @cindex selection, primary |
| 208 | @vindex x-cut-buffer-max | 202 | @vindex x-cut-buffer-max |
| 209 | When Emacs puts text into the kill ring, or rotates text to the front | 203 | When Emacs puts text into the kill ring, or rotates text to the |
| 210 | of the kill ring, it sets the @dfn{primary selection} in the X server. | 204 | front of the kill ring, it sets the @dfn{primary selection} in the |
| 211 | This is how other X clients can access the text. Emacs also stores the | 205 | window system. This is how other windowing applications can access |
| 212 | text in the cut buffer, but only if the text is short enough | 206 | the text. On the X Window System, emacs also stores the text in the |
| 213 | (the value of @code{x-cut-buffer-max} specifies the maximum number of | 207 | cut buffer, but only if the text is short enough (the value of |
| 214 | characters); putting long strings in the cut buffer can be slow. | 208 | @code{x-cut-buffer-max} specifies the maximum number of characters); |
| 209 | putting long strings in the cut buffer can be slow. | ||
| 215 | 210 | ||
| 216 | The commands to yank the first entry in the kill ring actually check | 211 | The commands to yank the first entry in the kill ring actually check |
| 217 | first for a primary selection in another program; after that, they check | 212 | first for a primary selection in another program; after that, they check |
| 218 | for text in the cut buffer. If neither of those sources provides text | 213 | for text in the cut buffer. If neither of those sources provides text |
| 219 | to yank, the kill ring contents are used. | 214 | to yank, the kill ring contents are used. |
| 220 | 215 | ||
| 216 | The standard coding system for X Window System selections is | ||
| 217 | @code{compound-text-with-extensions}. To specify another coding | ||
| 218 | system for selections, use @kbd{C-x @key{RET} x} or @kbd{C-x @key{RET} | ||
| 219 | X}. @xref{Communication Coding}. | ||
| 220 | |||
| 221 | @node Secondary Selection | 221 | @node Secondary Selection |
| 222 | @section Secondary Selection | 222 | @section Secondary Selection |
| 223 | @cindex secondary selection | 223 | @cindex secondary selection |
| 224 | 224 | ||
| 225 | The @dfn{secondary selection} is another way of selecting text using | 225 | The @dfn{secondary selection} is another way of selecting text using |
| 226 | X. It does not use point or the mark, so you can use it to kill text | 226 | the X Window System. It does not use point or the mark, so you can |
| 227 | without setting point or the mark. | 227 | use it to kill text without setting point or the mark. |
| 228 | 228 | ||
| 229 | @table @kbd | 229 | @table @kbd |
| 230 | @findex mouse-set-secondary | 230 | @findex mouse-set-secondary |
| @@ -275,16 +275,15 @@ that matters is which window you click on. @xref{Mouse Commands}. | |||
| 275 | 275 | ||
| 276 | @node Clipboard | 276 | @node Clipboard |
| 277 | @section Using the Clipboard | 277 | @section Using the Clipboard |
| 278 | @cindex X clipboard | ||
| 279 | @cindex clipboard | 278 | @cindex clipboard |
| 280 | @vindex x-select-enable-clipboard | 279 | @vindex x-select-enable-clipboard |
| 281 | @findex menu-bar-enable-clipboard | 280 | @findex menu-bar-enable-clipboard |
| 282 | @cindex OpenWindows | 281 | @cindex OpenWindows |
| 283 | @cindex Gnome | 282 | @cindex Gnome |
| 284 | 283 | ||
| 285 | Apart from the primary and secondary selection types, X supports a | 284 | Apart from the primary and secondary selection types, Emacs can |
| 286 | @dfn{clipboard} selection type which is used by some applications, | 285 | handle the @dfn{clipboard} selection type which is used by some |
| 287 | particularly under OpenWindows and Gnome. | 286 | applications, particularly under OpenWindows and Gnome. |
| 288 | 287 | ||
| 289 | The command @kbd{M-x menu-bar-enable-clipboard} makes the @code{Cut}, | 288 | The command @kbd{M-x menu-bar-enable-clipboard} makes the @code{Cut}, |
| 290 | @code{Paste} and @code{Copy} menu items, as well as the keys of the same | 289 | @code{Paste} and @code{Copy} menu items, as well as the keys of the same |
| @@ -295,7 +294,7 @@ the Emacs yank functions consult the clipboard before the primary | |||
| 295 | selection, and to make the kill functions to store in the clipboard as | 294 | selection, and to make the kill functions to store in the clipboard as |
| 296 | well as the primary selection. Otherwise they do not access the | 295 | well as the primary selection. Otherwise they do not access the |
| 297 | clipboard at all. Using the clipboard is the default on MS-Windows, | 296 | clipboard at all. Using the clipboard is the default on MS-Windows, |
| 298 | unlike most systems. | 297 | but not on other systems. |
| 299 | 298 | ||
| 300 | @node Mouse References | 299 | @node Mouse References |
| 301 | @section Following References with the Mouse | 300 | @section Following References with the Mouse |
| @@ -342,16 +341,16 @@ the mouse. | |||
| 342 | 341 | ||
| 343 | @vindex mouse-1-click-follows-link | 342 | @vindex mouse-1-click-follows-link |
| 344 | In Emacs versions before 22, only @kbd{Mouse-2} follows links and | 343 | In Emacs versions before 22, only @kbd{Mouse-2} follows links and |
| 345 | @kbd{Mouse-1} always sets points. If you prefer this behavior, set | 344 | @kbd{Mouse-1} always sets point. If you prefer this older behavior, |
| 346 | the variable @code{mouse-1-click-follows-link} to @code{nil}. This | 345 | set the variable @code{mouse-1-click-follows-link} to @code{nil}. |
| 347 | variable also lets you choose various other alternatives for following | 346 | This variable also lets you choose various other alternatives for |
| 348 | links with the mouse. Type @kbd{C-h v mouse-1-click-follows-link @key{RET}} | 347 | following links with the mouse. Type @kbd{C-h v |
| 349 | for more details. | 348 | mouse-1-click-follows-link @key{RET}} for more details. |
| 350 | 349 | ||
| 351 | @node Menu Mouse Clicks | 350 | @node Menu Mouse Clicks |
| 352 | @section Mouse Clicks for Menus | 351 | @section Mouse Clicks for Menus |
| 353 | 352 | ||
| 354 | Mouse clicks modified with the @key{CTRL} and @key{SHIFT} keys | 353 | Several mouse clicks with the @key{CTRL} and @key{SHIFT} modifiers |
| 355 | bring up menus. | 354 | bring up menus. |
| 356 | 355 | ||
| 357 | @table @kbd | 356 | @table @kbd |
| @@ -382,7 +381,7 @@ present in the menu bar---not just the mode-specific ones---so that | |||
| 382 | you can access them without having to display the menu bar. | 381 | you can access them without having to display the menu bar. |
| 383 | 382 | ||
| 384 | @item S-Mouse-1 | 383 | @item S-Mouse-1 |
| 385 | This menu is for specifying the frame's principal font. | 384 | This menu is for specifying the frame's default font. |
| 386 | @end table | 385 | @end table |
| 387 | 386 | ||
| 388 | @node Mode Line Mouse | 387 | @node Mode Line Mouse |
| @@ -396,17 +395,17 @@ windows. | |||
| 396 | Some areas of the mode line, such as the buffer name and the major | 395 | Some areas of the mode line, such as the buffer name and the major |
| 397 | mode name, have their own special mouse bindings. These areas are | 396 | mode name, have their own special mouse bindings. These areas are |
| 398 | highlighted when you hold the mouse over them, and information about | 397 | highlighted when you hold the mouse over them, and information about |
| 399 | the special bindings will be displayed (@pxref{Tooltips}). | 398 | the special bindings will be displayed (@pxref{Tooltips}). This |
| 400 | 399 | section's commands do not apply in those areas. | |
| 401 | You can also click on areas of the mode line that do not have | ||
| 402 | special mouse bindings of their own. This has the following effects: | ||
| 403 | 400 | ||
| 404 | @table @kbd | 401 | @table @kbd |
| 405 | @item Mouse-1 | 402 | @item Mouse-1 |
| 406 | @kindex Mouse-1 @r{(mode line)} | 403 | @kindex Mouse-1 @r{(mode line)} |
| 407 | @kbd{Mouse-1} on a mode line selects the window it belongs to. By | 404 | @kbd{Mouse-1} on a mode line selects the window it belongs to. By |
| 408 | dragging @kbd{Mouse-1} on the mode line, you can move it, thus | 405 | dragging @kbd{Mouse-1} on the mode line, you can move it, thus |
| 409 | changing the height of the windows above and below. | 406 | changing the height of the windows above and below. Changing heights |
| 407 | with the mouse in this way never deletes windows, it just refuses to | ||
| 408 | make any window smaller than the minimum height. | ||
| 410 | 409 | ||
| 411 | @item Mouse-2 | 410 | @item Mouse-2 |
| 412 | @kindex Mouse-2 @r{(mode line)} | 411 | @kindex Mouse-2 @r{(mode line)} |
| @@ -425,7 +424,10 @@ horizontally, above the place in the mode line where you click. | |||
| 425 | @end table | 424 | @end table |
| 426 | 425 | ||
| 427 | @kindex C-Mouse-2 @r{(scroll bar)} | 426 | @kindex C-Mouse-2 @r{(scroll bar)} |
| 428 | @kbd{C-Mouse-2} on a scroll bar splits the corresponding window | 427 | @kindex Mouse-1 @r{(scroll bar)} |
| 428 | Using @kbd{Mouse-1} on the divider between two side-by-side mode | ||
| 429 | lines, you can move the vertical boundary left or right. Using | ||
| 430 | @kbd{C-Mouse-2} on a scroll bar splits the corresponding window | ||
| 429 | vertically. @xref{Split Window}. | 431 | vertically. @xref{Split Window}. |
| 430 | 432 | ||
| 431 | @node Creating Frames | 433 | @node Creating Frames |
| @@ -638,12 +640,12 @@ for all of them! | |||
| 638 | @section Special Buffer Frames | 640 | @section Special Buffer Frames |
| 639 | 641 | ||
| 640 | @vindex special-display-buffer-names | 642 | @vindex special-display-buffer-names |
| 641 | You can make certain chosen buffers, for which Emacs normally creates | 643 | You can make certain chosen buffers, which Emacs normally displays |
| 642 | a second window when you have just one window, appear in special frames | 644 | in ``another window,'' appear in special frames of their own. To do |
| 643 | of their own. To do this, set the variable | 645 | this, set the variable @code{special-display-buffer-names} to a list |
| 644 | @code{special-display-buffer-names} to a list of buffer names; any | 646 | of buffer names; any buffer whose name is in that list automatically |
| 645 | buffer whose name is in that list automatically gets a special frame, | 647 | gets a special frame, when an Emacs command wants to display it ``in |
| 646 | when an Emacs command wants to display it ``in another window.'' | 648 | another window.'' |
| 647 | 649 | ||
| 648 | For example, if you set the variable this way, | 650 | For example, if you set the variable this way, |
| 649 | 651 | ||
| @@ -664,7 +666,7 @@ frame automatically. | |||
| 664 | More generally, you can set @code{special-display-regexps} to a list | 666 | More generally, you can set @code{special-display-regexps} to a list |
| 665 | of regular expressions; then a buffer gets its own frame if its name | 667 | of regular expressions; then a buffer gets its own frame if its name |
| 666 | matches any of those regular expressions. (Once again, this applies only | 668 | matches any of those regular expressions. (Once again, this applies only |
| 667 | to buffers that normally get displayed for you in a separate window.) | 669 | to buffers that normally get displayed for you in ``another window.'') |
| 668 | 670 | ||
| 669 | @vindex special-display-frame-alist | 671 | @vindex special-display-frame-alist |
| 670 | The variable @code{special-display-frame-alist} specifies the frame | 672 | The variable @code{special-display-frame-alist} specifies the frame |
| @@ -707,79 +709,38 @@ whether that feature is also in use for the same buffer name. | |||
| 707 | @cindex Auto-Raise mode | 709 | @cindex Auto-Raise mode |
| 708 | @cindex Auto-Lower mode | 710 | @cindex Auto-Lower mode |
| 709 | 711 | ||
| 710 | This section describes commands for altering the display style and | 712 | @kindex S-Mouse-1 |
| 711 | window management behavior of the selected frame. | 713 | You can specify the font and colors used for text display, and the |
| 714 | colors for the frame borders, the cursor, and the mouse cursor, by | ||
| 715 | customizing the faces @code{default}, @code{border}, @code{cursor} and | ||
| 716 | @code{mouse}. @xref{Face Customization}. You can also set a frame's | ||
| 717 | default font through a pop-up menu. Press @kbd{S-Mouse-1} to activate | ||
| 718 | this menu. | ||
| 719 | |||
| 720 | These commands are available for controlling the window management | ||
| 721 | behavior of the selected frame. | ||
| 712 | 722 | ||
| 713 | @findex set-foreground-color | ||
| 714 | @findex set-background-color | ||
| 715 | @findex set-cursor-color | ||
| 716 | @findex set-mouse-color | ||
| 717 | @findex set-border-color | ||
| 718 | @findex auto-raise-mode | ||
| 719 | @findex auto-lower-mode | ||
| 720 | @cindex colors | ||
| 721 | @table @kbd | 723 | @table @kbd |
| 722 | @item M-x set-foreground-color @key{RET} @var{color} @key{RET} | 724 | @findex auto-raise-mode |
| 723 | Specify color @var{color} for the foreground of the selected frame. | ||
| 724 | (This also changes the foreground color of the default face.) You can | ||
| 725 | specify @var{color} either by its symbolic name or by its RGB | ||
| 726 | numerical specification@footnote{ | ||
| 727 | See the X Window System documentation for more details. On a typical | ||
| 728 | GNU or Unix system, the command @kbd{man 7 X} or @kbd{man -s 7 X} will | ||
| 729 | display the X manual page that explains how to specify colors.}. | ||
| 730 | |||
| 731 | @item M-x set-background-color @key{RET} @var{color} @key{RET} | ||
| 732 | Specify color @var{color} for the background of the selected frame. | ||
| 733 | (This also changes the background color of the default face.) | ||
| 734 | |||
| 735 | @item M-x set-cursor-color @key{RET} @var{color} @key{RET} | ||
| 736 | Specify color @var{color} for the cursor of the selected frame. | ||
| 737 | |||
| 738 | @item M-x set-mouse-color @key{RET} @var{color} @key{RET} | ||
| 739 | Specify color @var{color} for the mouse cursor when it is over the | ||
| 740 | selected frame. | ||
| 741 | |||
| 742 | @item M-x set-border-color @key{RET} @var{color} @key{RET} | ||
| 743 | Specify color @var{color} for the border of the selected frame. | ||
| 744 | |||
| 745 | @item M-x list-colors-display | ||
| 746 | Display the defined color names and show what the colors look like. | ||
| 747 | This command is somewhat slow. @xref{Colors, list-colors-display, | ||
| 748 | Display available colors}. | ||
| 749 | |||
| 750 | @item M-x auto-raise-mode | 725 | @item M-x auto-raise-mode |
| 751 | Toggle whether or not the selected frame should auto-raise. Auto-raise | 726 | Toggle whether or not the selected frame should auto-raise. Auto-raise |
| 752 | means that every time you move the mouse onto the frame, it raises the | 727 | means that every time you move the mouse onto the frame, it raises the |
| 753 | frame. | 728 | frame. |
| 754 | 729 | ||
| 755 | Note that this auto-raise feature is implemented by Emacs itself. Some | 730 | Some window managers also implement auto-raise. If you enable |
| 756 | window managers also implement auto-raise. If you enable auto-raise for | 731 | auto-raise for Emacs frames in your window manager, it will work, but |
| 757 | Emacs frames in your X window manager, it should work, but it is beyond | 732 | it is beyond Emacs' control, so @code{auto-raise-mode} has no effect |
| 758 | Emacs's control and therefore @code{auto-raise-mode} has no effect on | 733 | on it. |
| 759 | it. | ||
| 760 | 734 | ||
| 735 | @findex auto-lower-mode | ||
| 761 | @item M-x auto-lower-mode | 736 | @item M-x auto-lower-mode |
| 762 | Toggle whether or not the selected frame should auto-lower. | 737 | Toggle whether or not the selected frame should auto-lower. |
| 763 | Auto-lower means that every time you move the mouse off the frame, | 738 | Auto-lower means that every time you move the mouse off the frame, |
| 764 | the frame moves to the bottom of the stack of X windows. | 739 | the frame moves to the bottom of the stack on the screen. |
| 765 | 740 | ||
| 766 | The command @code{auto-lower-mode} has no effect on auto-lower | 741 | The command @code{auto-lower-mode} has no effect on auto-lower |
| 767 | implemented by the X window manager. To control that, you must use | 742 | implemented by the window manager. To control that, you must use the |
| 768 | the appropriate window manager features. | 743 | appropriate window manager features. |
| 769 | |||
| 770 | @findex set-frame-font | ||
| 771 | @item M-x set-frame-font @key{RET} @var{font} @key{RET} | ||
| 772 | @cindex font (principal) | ||
| 773 | Specify font @var{font} as the principal font for the selected frame. | ||
| 774 | The principal font controls several face attributes of the | ||
| 775 | @code{default} face (@pxref{Faces}). For example, if the principal font | ||
| 776 | has a height of 12 pt, all text will be drawn in 12 pt fonts, unless you | ||
| 777 | use another face that specifies a different height. @xref{Font X}, for | ||
| 778 | ways to list the available fonts on your system. | ||
| 779 | |||
| 780 | @kindex S-Mouse-1 | ||
| 781 | You can also set a frame's principal font through a pop-up menu. | ||
| 782 | Press @kbd{S-Mouse-1} to activate this menu. | ||
| 783 | @end table | 744 | @end table |
| 784 | 745 | ||
| 785 | In Emacs versions that use an X toolkit, the color-setting and | 746 | In Emacs versions that use an X toolkit, the color-setting and |
| @@ -800,13 +761,13 @@ Parameters,,, elisp, The Emacs Lisp Reference Manual}. | |||
| 800 | @cindex Scroll Bar mode | 761 | @cindex Scroll Bar mode |
| 801 | @cindex mode, Scroll Bar | 762 | @cindex mode, Scroll Bar |
| 802 | 763 | ||
| 803 | When using X, Emacs normally makes a @dfn{scroll bar} at the left of | 764 | On graphical displays, Emacs normally makes a @dfn{scroll bar} at |
| 804 | each Emacs window.@footnote{Placing it at the left is usually more | 765 | the left of each Emacs window.@footnote{Placing it at the left is |
| 805 | useful with overlapping frames with text starting at the left margin.} | 766 | usually more useful with overlapping frames with text starting at the |
| 806 | The scroll bar runs the height of the window, and shows a moving | 767 | left margin.} The scroll bar runs the height of the window, and shows |
| 807 | rectangular inner box which represents the portion of the buffer | 768 | a moving rectangular inner box which represents the portion of the |
| 808 | currently displayed. The entire height of the scroll bar represents the | 769 | buffer currently displayed. The entire height of the scroll bar |
| 809 | entire length of the buffer. | 770 | represents the entire length of the buffer. |
| 810 | 771 | ||
| 811 | You can use @kbd{Mouse-2} (normally, the middle button) in the scroll | 772 | You can use @kbd{Mouse-2} (normally, the middle button) in the scroll |
| 812 | bar to move or drag the inner box up and down. If you move it to the | 773 | bar to move or drag the inner box up and down. If you move it to the |
| @@ -826,16 +787,18 @@ window vertically. The split occurs on the line where you click. | |||
| 826 | @findex scroll-bar-mode | 787 | @findex scroll-bar-mode |
| 827 | @vindex scroll-bar-mode | 788 | @vindex scroll-bar-mode |
| 828 | You can enable or disable Scroll Bar mode with the command @kbd{M-x | 789 | You can enable or disable Scroll Bar mode with the command @kbd{M-x |
| 829 | scroll-bar-mode}. With no argument, it toggles the use of scroll bars. | 790 | scroll-bar-mode}. With no argument, it toggles the use of scroll |
| 830 | With an argument, it turns use of scroll bars on if and only if the | 791 | bars. With an argument, it turns use of scroll bars on if and only if |
| 831 | argument is positive. This command applies to all frames, including | 792 | the argument is positive. This command applies to all frames, |
| 832 | frames yet to be created. Customize the variable @code{scroll-bar-mode} | 793 | including frames yet to be created. Customize the variable |
| 833 | to control the use of scroll bars at startup. You can use it to specify | 794 | @code{scroll-bar-mode} to control the use of scroll bars at startup. |
| 834 | that they are placed at the right of windows if you prefer that. You | 795 | You can use it to specify that they are placed at the right of windows |
| 835 | have to set this variable through the @samp{Customize} interface | 796 | if you prefer that. You have to set this variable through the |
| 836 | (@pxref{Easy Customization}). Otherwise, it will not work properly. | 797 | @samp{Customize} interface (@pxref{Easy Customization}), or it will |
| 837 | You can use the X resource @samp{verticalScrollBars} to control the | 798 | not work properly. |
| 838 | initial setting of Scroll Bar mode similarly. @xref{Resources}. | 799 | |
| 800 | You can also use the X resource @samp{verticalScrollBars} to control | ||
| 801 | the initial setting of Scroll Bar mode. @xref{Resources}. | ||
| 839 | 802 | ||
| 840 | @findex toggle-scroll-bar | 803 | @findex toggle-scroll-bar |
| 841 | To enable or disable scroll bars for just the selected frame, use the | 804 | To enable or disable scroll bars for just the selected frame, use the |
| @@ -887,37 +850,8 @@ directory displayed in that buffer. | |||
| 887 | you prefer to visit the file in a new window in such cases, customize | 850 | you prefer to visit the file in a new window in such cases, customize |
| 888 | the variable @code{dnd-open-file-other-window}. | 851 | the variable @code{dnd-open-file-other-window}. |
| 889 | 852 | ||
| 890 | @ignore | 853 | The XDND and Motif drag and drop protocols, and the old KDE 1.x |
| 891 | @c ??? To Lisp manual | 854 | protocol, are currently supported. |
| 892 | @vindex x-dnd-test-function | ||
| 893 | @vindex x-dnd-known-types | ||
| 894 | When a user drags something from another application over Emacs, that other | ||
| 895 | application expects Emacs to tell it if Emacs can handle the data that is | ||
| 896 | dragged. The variable @code{x-dnd-test-function} is used by Emacs to determine | ||
| 897 | what to reply. The default value is @code{x-dnd-default-test-function} | ||
| 898 | which accepts drops if the type of the data to be dropped is present in | ||
| 899 | @code{x-dnd-known-types}. You can customize @code{x-dnd-test-function} and/or | ||
| 900 | @code{x-dnd-known-types} if you want Emacs to accept or reject drops based | ||
| 901 | on some other criteria. | ||
| 902 | |||
| 903 | @vindex x-dnd-types-alist | ||
| 904 | If you want to change the way Emacs handles drop of different types | ||
| 905 | or add a new type, customize @code{x-dnd-types-alist}. This requires | ||
| 906 | detailed knowledge of what types other applications use for drag and | ||
| 907 | drop. | ||
| 908 | |||
| 909 | @vindex dnd-protocol-alist | ||
| 910 | When an URL is dropped on Emacs it may be a file, but it may also be | ||
| 911 | another URL type (ftp, http, etc.). Emacs first checks | ||
| 912 | @code{dnd-protocol-alist} to determine what to do with the URL. If | ||
| 913 | there is no match there and if @code{browse-url-browser-function} is | ||
| 914 | an alist, Emacs looks for a match there. If no match is found the | ||
| 915 | text for the URL is inserted. If you want to alter Emacs behavior, | ||
| 916 | you can customize these variables. | ||
| 917 | @end ignore | ||
| 918 | |||
| 919 | The drag and drop protocols XDND, Motif and the | ||
| 920 | old KDE 1.x protocol are currently supported. | ||
| 921 | 855 | ||
| 922 | @node Menu Bars | 856 | @node Menu Bars |
| 923 | @section Menu Bars | 857 | @section Menu Bars |
| @@ -941,7 +875,7 @@ with @kbd{C-Mouse-3} on a display which supports pop-up menus. | |||
| 941 | 875 | ||
| 942 | @xref{Menu Bar}, for information on how to invoke commands with the | 876 | @xref{Menu Bar}, for information on how to invoke commands with the |
| 943 | menu bar. @xref{X Resources}, for how to customize the menu bar | 877 | menu bar. @xref{X Resources}, for how to customize the menu bar |
| 944 | menus. | 878 | menus' visual appearance. |
| 945 | 879 | ||
| 946 | @node Tool Bars | 880 | @node Tool Bars |
| 947 | @section Tool Bars | 881 | @section Tool Bars |
| @@ -980,13 +914,18 @@ use of dialog boxes. This also controls whether to use file selection | |||
| 980 | windows (but those are not supported on all platforms). | 914 | windows (but those are not supported on all platforms). |
| 981 | 915 | ||
| 982 | @vindex use-file-dialog | 916 | @vindex use-file-dialog |
| 983 | A file selection window is a special kind of dialog box for asking for | 917 | A file selection window is a special kind of dialog box for asking |
| 984 | file names. | 918 | for file names. You can customize the variable @code{use-file-dialog} |
| 919 | to suppress the use of file selection windows, even if you still want | ||
| 920 | other kinds of dialogs. This variable has no effect if you have | ||
| 921 | suppressed all dialog boxes with the variable @code{use-dialog-box}. | ||
| 985 | 922 | ||
| 986 | You can customize the variable @code{use-file-dialog} to suppress the | 923 | @vindex x-gtk-show-hidden-files |
| 987 | use of file selection windows even if you still want other kinds | 924 | For Gtk+ version 2.4 and newer, Emacs use the Gtk+ file chooser |
| 988 | of dialogs. This variable has no effect if you have suppressed all dialog | 925 | dialog. Emacs adds a toggle button that enables and disables showing |
| 989 | boxes with the variable @code{use-dialog-box}. | 926 | of hidden files (files starting with a dot) in that dialog. The |
| 927 | variable @code{x-gtk-show-hidden-files} controls whether to show | ||
| 928 | hidden files by default. | ||
| 990 | 929 | ||
| 991 | @vindex x-use-old-gtk-file-dialog | 930 | @vindex x-use-old-gtk-file-dialog |
| 992 | For Gtk+ version 2.4 and 2.6, you can make Emacs use the old file dialog | 931 | For Gtk+ version 2.4 and 2.6, you can make Emacs use the old file dialog |
| @@ -994,12 +933,6 @@ by setting the variable @code{x-use-old-gtk-file-dialog} to a non-@code{nil} | |||
| 994 | value. If Emacs is built with a Gtk+ version that has only one file dialog, | 933 | value. If Emacs is built with a Gtk+ version that has only one file dialog, |
| 995 | the setting of this variable has no effect. | 934 | the setting of this variable has no effect. |
| 996 | 935 | ||
| 997 | @vindex x-gtk-show-hidden-files | ||
| 998 | For Gtk+ version 2.4 and newer, Emacs use the Gtk+ file chooser dialog. | ||
| 999 | Emacs adds a toggle button that enables and disables showing of hidden files | ||
| 1000 | (files starting with a dot) in that dialog. This variable controls if | ||
| 1001 | hidden files should be shown by default or not. | ||
| 1002 | |||
| 1003 | @node Tooltips | 936 | @node Tooltips |
| 1004 | @section Tooltips | 937 | @section Tooltips |
| 1005 | @cindex tooltips | 938 | @cindex tooltips |
| @@ -1010,13 +943,13 @@ movement. There are two types of tooltip: help tooltips and GUD | |||
| 1010 | tooltips. | 943 | tooltips. |
| 1011 | 944 | ||
| 1012 | @dfn{Help tooltips} typically display over text---including the mode | 945 | @dfn{Help tooltips} typically display over text---including the mode |
| 1013 | line---but may be also available for many other parts of the Emacs | 946 | line---but are also available for other parts of the Emacs frame, such |
| 1014 | frame such as the tool bar and menu items. | 947 | as the tool bar and menu items. |
| 1015 | 948 | ||
| 1016 | @findex tooltip-mode | 949 | @findex tooltip-mode |
| 1017 | You can toggle help tooltips (Tooltip mode) with the command | 950 | You can toggle display of help tooltips (Tooltip mode) with the |
| 1018 | @kbd{M-x tooltip-mode}. When Tooltip mode is disabled, the help text | 951 | command @kbd{M-x tooltip-mode}. When Tooltip mode is disabled, the |
| 1019 | is displayed in the echo area instead. | 952 | help text is displayed in the echo area instead. |
| 1020 | 953 | ||
| 1021 | @dfn{GUD tooltips} show values of variables. They are useful when | 954 | @dfn{GUD tooltips} show values of variables. They are useful when |
| 1022 | you are debugging a program. @xref{Debugger Operation}. | 955 | you are debugging a program. @xref{Debugger Operation}. |
| @@ -1066,11 +999,10 @@ the mode. | |||
| 1066 | @cindex non-window terminals | 999 | @cindex non-window terminals |
| 1067 | @cindex single-frame terminals | 1000 | @cindex single-frame terminals |
| 1068 | 1001 | ||
| 1069 | If your terminal does not have a window system that Emacs supports, | 1002 | On a text-only terminal, Emacs can display only one Emacs frame at a |
| 1070 | then it can display only one Emacs frame at a time. However, you can | 1003 | time. However, you can still create multiple Emacs frames, and switch |
| 1071 | still create multiple Emacs frames, and switch between them. Switching | 1004 | between them. Switching frames on these terminals is much like |
| 1072 | frames on these terminals is much like switching between different | 1005 | switching between different window configurations. |
| 1073 | window configurations. | ||
| 1074 | 1006 | ||
| 1075 | Use @kbd{C-x 5 2} to create a new frame and switch to it; use @kbd{C-x | 1007 | Use @kbd{C-x 5 2} to create a new frame and switch to it; use @kbd{C-x |
| 1076 | 5 o} to cycle through the existing frames; use @kbd{C-x 5 0} to delete | 1008 | 5 o} to cycle through the existing frames; use @kbd{C-x 5 0} to delete |
| @@ -1083,20 +1015,20 @@ appears near the beginning of the mode line, in the form | |||
| 1083 | 1015 | ||
| 1084 | @findex set-frame-name | 1016 | @findex set-frame-name |
| 1085 | @findex select-frame-by-name | 1017 | @findex select-frame-by-name |
| 1086 | @samp{F@var{n}} is actually the frame's name. You can also specify a | 1018 | @samp{F@var{n}} is in fact the frame's initial name. You can give |
| 1087 | different name if you wish, and you can select a frame by its name. Use | 1019 | frames more meaningful names if you wish, and you can select a frame |
| 1088 | the command @kbd{M-x set-frame-name @key{RET} @var{name} @key{RET}} to | 1020 | by its name. Use the command @kbd{M-x set-frame-name @key{RET} |
| 1089 | specify a new name for the selected frame, and use @kbd{M-x | 1021 | @var{name} @key{RET}} to specify a new name for the selected frame, |
| 1090 | select-frame-by-name @key{RET} @var{name} @key{RET}} to select a frame | 1022 | and use @kbd{M-x select-frame-by-name @key{RET} @var{name} @key{RET}} |
| 1091 | according to its name. The name you specify appears in the mode line | 1023 | to select a frame according to its name. The name you specify appears |
| 1092 | when the frame is selected. | 1024 | in the mode line when the frame is selected. |
| 1093 | 1025 | ||
| 1094 | @node XTerm Mouse | 1026 | @node XTerm Mouse |
| 1095 | @section Using a Mouse in Terminal Emulators | 1027 | @section Using a Mouse in Terminal Emulators |
| 1096 | @cindex xterm, mouse support | 1028 | @cindex xterm, mouse support |
| 1097 | @cindex terminal emulators, mouse support | 1029 | @cindex terminal emulators, mouse support |
| 1098 | 1030 | ||
| 1099 | Some terminal emulators under X support mouse clicks in the terminal | 1031 | Some terminal emulators under X support mouse clicks in the terminal |
| 1100 | window. In a terminal emulator which is compatible with @code{xterm}, | 1032 | window. In a terminal emulator which is compatible with @code{xterm}, |
| 1101 | you can use @kbd{M-x xterm-mouse-mode} to give Emacs control over | 1033 | you can use @kbd{M-x xterm-mouse-mode} to give Emacs control over |
| 1102 | simple use of the mouse---basically, only non-modified single clicks | 1034 | simple use of the mouse---basically, only non-modified single clicks |
diff --git a/man/indent.texi b/man/indent.texi index c748f5010b1..ad0ef315fe8 100644 --- a/man/indent.texi +++ b/man/indent.texi | |||
| @@ -45,7 +45,7 @@ Insert a tab character. You can type @kbd{C-q @key{TAB}} to do this. | |||
| 45 | 45 | ||
| 46 | A tab character is displayed as a stretch of whitespace which extends | 46 | A tab character is displayed as a stretch of whitespace which extends |
| 47 | to the next display tab stop position, and the default width of a tab | 47 | to the next display tab stop position, and the default width of a tab |
| 48 | stop is eight. @xref{Display Custom}, for more details. | 48 | stop is eight. @xref{Text Display}, for more details. |
| 49 | 49 | ||
| 50 | @item | 50 | @item |
| 51 | Insert whitespace up to the next tab stop. You can set tab stops at | 51 | Insert whitespace up to the next tab stop. You can set tab stops at |
| @@ -114,13 +114,13 @@ regard, @kbd{C-M-o} resembles @kbd{C-o}. | |||
| 114 | @kindex M-^ | 114 | @kindex M-^ |
| 115 | @findex delete-indentation | 115 | @findex delete-indentation |
| 116 | To join two lines cleanly, use the @kbd{M-^} | 116 | To join two lines cleanly, use the @kbd{M-^} |
| 117 | (@code{delete-indentation}) command. It deletes the indentation at the | 117 | (@code{delete-indentation}) command. It deletes the indentation at |
| 118 | front of the current line, and the line boundary as well, replacing them | 118 | the front of the current line, and the line boundary as well, |
| 119 | with a single space. As a special case (useful for Lisp code) the | 119 | replacing them with a single space. As a special case (useful for |
| 120 | single space is omitted if the characters to be joined are consecutive | 120 | Lisp code) the single space is omitted if the characters to be joined |
| 121 | open parentheses or closing parentheses, or if the junction follows | 121 | are consecutive open parentheses or closing parentheses, or if the |
| 122 | another newline. To delete just the indentation of a line, go to the | 122 | junction follows another newline. To delete just the indentation of a |
| 123 | beginning of the line and use @kbd{M-\} | 123 | line, go to the beginning of the line and use @kbd{M-\} |
| 124 | (@code{delete-horizontal-space}), which deletes all spaces and tabs | 124 | (@code{delete-horizontal-space}), which deletes all spaces and tabs |
| 125 | around the cursor. | 125 | around the cursor. |
| 126 | 126 | ||
| @@ -140,12 +140,12 @@ shifted left or right so that its first nonblank character appears in | |||
| 140 | that column. @kbd{C-x @key{TAB}} (@code{indent-rigidly}) moves all of | 140 | that column. @kbd{C-x @key{TAB}} (@code{indent-rigidly}) moves all of |
| 141 | the lines in the region right by its argument (left, for negative | 141 | the lines in the region right by its argument (left, for negative |
| 142 | arguments). The whole group of lines moves rigidly sideways, which is | 142 | arguments). The whole group of lines moves rigidly sideways, which is |
| 143 | how the command gets its name.@refill | 143 | how the command gets its name. |
| 144 | 144 | ||
| 145 | @cindex remove indentation | 145 | @cindex remove indentation |
| 146 | If you want to remove all indentation from all of the line in the | 146 | To remove all indentation from all of the lines in the region, |
| 147 | region, invoke @kbd{C-x @key{TAB}} with a large negative argument, | 147 | invoke @kbd{C-x @key{TAB}} with a large negative argument, such as |
| 148 | such as -1000. | 148 | -1000. |
| 149 | 149 | ||
| 150 | @findex indent-relative | 150 | @findex indent-relative |
| 151 | @kbd{M-x indent-relative} indents at point based on the previous line | 151 | @kbd{M-x indent-relative} indents at point based on the previous line |
diff --git a/man/kmacro.texi b/man/kmacro.texi index 852f999adac..89cd8f9e54b 100644 --- a/man/kmacro.texi +++ b/man/kmacro.texi | |||
| @@ -7,22 +7,22 @@ | |||
| 7 | @cindex defining keyboard macros | 7 | @cindex defining keyboard macros |
| 8 | @cindex keyboard macro | 8 | @cindex keyboard macro |
| 9 | 9 | ||
| 10 | In this chapter we describe how a sequence of editing commands can | 10 | In this chapter we describe how to record a sequence of editing |
| 11 | be recorded and repeated multiple times. | 11 | commands so you can repeat it conveniently later. |
| 12 | 12 | ||
| 13 | A @dfn{keyboard macro} is a command defined by the user to stand for | 13 | A @dfn{keyboard macro} is a command defined by the user to stand for |
| 14 | another sequence of keys. For example, if you discover that you are | 14 | another sequence of keys. For example, if you discover that you are |
| 15 | about to type @kbd{C-n C-d} forty times, you can speed your work by | 15 | about to type @kbd{C-n M-d C-d} forty times, you can speed your work by |
| 16 | defining a keyboard macro to do @kbd{C-n C-d} and calling it with a | 16 | defining a keyboard macro to do @kbd{C-n M-d C-d}, and then executing |
| 17 | repeat count of forty. | 17 | it 39 more times. |
| 18 | 18 | ||
| 19 | You define a keyboard macro while executing the commands which are the | 19 | You define a keyboard macro by executing and recording the commands |
| 20 | definition. Put differently, as you define a keyboard macro, the | 20 | which are its definition. Put differently, as you define a keyboard |
| 21 | definition is being executed for the first time. This way, you can see | 21 | macro, the definition is being executed for the first time. This way, |
| 22 | what the effects of your commands are, so that you don't have to figure | 22 | you can see the effects of your commands, so that you don't have to |
| 23 | them out in your head. When you are finished, the keyboard macro is | 23 | figure them out in your head. When you close the definition, the |
| 24 | defined and also has been, in effect, executed once. You can then do the | 24 | keyboard macro is defined and also has been, in effect, executed once. |
| 25 | whole thing over again by invoking the macro. | 25 | You can then do the whole thing over again by invoking the macro. |
| 26 | 26 | ||
| 27 | Keyboard macros differ from ordinary Emacs commands in that they are | 27 | Keyboard macros differ from ordinary Emacs commands in that they are |
| 28 | written in the Emacs command language rather than in Lisp. This makes it | 28 | written in the Emacs command language rather than in Lisp. This makes it |
| @@ -63,19 +63,6 @@ execute the most recent keyboard macro | |||
| 63 | Re-execute last keyboard macro, then add more keys to its definition. | 63 | Re-execute last keyboard macro, then add more keys to its definition. |
| 64 | @item C-u C-u C-x ( | 64 | @item C-u C-u C-x ( |
| 65 | Add more keys to the last keyboard macro without re-executing it. | 65 | Add more keys to the last keyboard macro without re-executing it. |
| 66 | @item C-x q | ||
| 67 | When this point is reached during macro execution, ask for confirmation | ||
| 68 | (@code{kbd-macro-query}). | ||
| 69 | @item C-x C-k n | ||
| 70 | Give a command name (for the duration of the session) to the most | ||
| 71 | recently defined keyboard macro (@code{kmacro-name-last-macro}). | ||
| 72 | @item C-x C-k b | ||
| 73 | Bind the most recently defined keyboard macro to a key sequence (for | ||
| 74 | the duration of the session) (@code{kmacro-bind-to-key}). | ||
| 75 | @item M-x insert-kbd-macro | ||
| 76 | Insert in the buffer a keyboard macro's definition, as Lisp code. | ||
| 77 | @item C-x C-k e | ||
| 78 | Edit a previously defined keyboard macro (@code{edit-kbd-macro}). | ||
| 79 | @item C-x C-k r | 66 | @item C-x C-k r |
| 80 | Run the last keyboard macro on each line that begins in the region | 67 | Run the last keyboard macro on each line that begins in the region |
| 81 | (@code{apply-macro-to-region-lines}). | 68 | (@code{apply-macro-to-region-lines}). |
| @@ -157,12 +144,12 @@ of that event, the position that the mouse had while you were defining | |||
| 157 | the macro. The effect of this may be hard to predict. (Using the | 144 | the macro. The effect of this may be hard to predict. (Using the |
| 158 | current mouse position would be even less predictable.) | 145 | current mouse position would be even less predictable.) |
| 159 | 146 | ||
| 160 | One thing that doesn't always work well in a keyboard macro is the | 147 | One thing that sometimes works badly in a keyboard macro is the |
| 161 | command @kbd{C-M-c} (@code{exit-recursive-edit}). When this command | 148 | command @kbd{C-M-c} (@code{exit-recursive-edit}). When this command |
| 162 | exits a recursive edit that started within the macro, it works as you'd | 149 | exits a recursive edit that started within the macro, it works as |
| 163 | expect. But if it exits a recursive edit that started before you | 150 | you'd expect. But if it exits a recursive edit that started before |
| 164 | invoked the keyboard macro, it also necessarily exits the keyboard macro | 151 | you invoked the keyboard macro, it also necessarily exits the keyboard |
| 165 | as part of the process. | 152 | macro as part of the process. |
| 166 | 153 | ||
| 167 | After you have terminated the definition of a keyboard macro, you can add | 154 | After you have terminated the definition of a keyboard macro, you can add |
| 168 | to the end of its definition by typing @kbd{C-u C-x (}. This is equivalent | 155 | to the end of its definition by typing @kbd{C-u C-x (}. This is equivalent |
| @@ -190,6 +177,17 @@ beginning of the line and then executing the macro. | |||
| 190 | a list of sequences of keys. There is only one keyboard macro ring, | 177 | a list of sequences of keys. There is only one keyboard macro ring, |
| 191 | shared by all buffers. | 178 | shared by all buffers. |
| 192 | 179 | ||
| 180 | @table @kbd | ||
| 181 | @item C-x C-k C-k | ||
| 182 | Execute the keyboard macro at the head of the ring (@code{kmacro-end-or-call-macro-repeat}). | ||
| 183 | @item C-x C-k C-n | ||
| 184 | Rotate the keyboard macro ring to the next macro (defined earlier) | ||
| 185 | (@code{kmacro-cycle-ring-next}). | ||
| 186 | @item C-x C-k C-p | ||
| 187 | Rotate the keyboard macro ring to the previous macro (defined later) | ||
| 188 | (@code{kmacro-cycle-ring-previous}). | ||
| 189 | @end table | ||
| 190 | |||
| 193 | All commands which operate on the keyboard macro ring use the | 191 | All commands which operate on the keyboard macro ring use the |
| 194 | same @kbd{C-x C-k} prefix. Most of these commands can be executed and | 192 | same @kbd{C-x C-k} prefix. Most of these commands can be executed and |
| 195 | repeated immediately after each other without repeating the @kbd{C-x | 193 | repeated immediately after each other without repeating the @kbd{C-x |
| @@ -212,7 +210,7 @@ executes the keyboard macro at the head of the macro ring. You can | |||
| 212 | repeat the macro immediately by typing another @kbd{C-k}, or you can | 210 | repeat the macro immediately by typing another @kbd{C-k}, or you can |
| 213 | rotate the macro ring immediately by typing @kbd{C-n} or @kbd{C-p}. | 211 | rotate the macro ring immediately by typing @kbd{C-n} or @kbd{C-p}. |
| 214 | 212 | ||
| 215 | When a keyboard macro is being defined, @kbd{C-x C-k C-k} behaves like | 213 | When a keyboard macro is being defined, @kbd{C-x C-k C-k} behaves like |
| 216 | @kbd{C-x )} except that, immediately afterward, you can use most key | 214 | @kbd{C-x )} except that, immediately afterward, you can use most key |
| 217 | bindings of this section without the @kbd{C-x C-k} prefix. For | 215 | bindings of this section without the @kbd{C-x C-k} prefix. For |
| 218 | instance, another @kbd{C-k} will re-execute the macro. | 216 | instance, another @kbd{C-k} will re-execute the macro. |
| @@ -231,12 +229,13 @@ desired macro is at the head of the ring. To execute the new macro | |||
| 231 | ring head immediately, just type @kbd{C-k}. | 229 | ring head immediately, just type @kbd{C-k}. |
| 232 | 230 | ||
| 233 | Note that Emacs treats the head of the macro ring as the ``last | 231 | Note that Emacs treats the head of the macro ring as the ``last |
| 234 | defined keyboard macro''. For instance, it is the keyboard macro that | 232 | defined keyboard macro.'' For instance, @kbd{C-x e} will execute that |
| 235 | @kbd{C-x e} will execute. | 233 | macro, and @kbd{C-x C-k n} will give it a name. |
| 236 | 234 | ||
| 235 | @ignore @c This interface is too kludgy | ||
| 236 | @c and the functionality duplicates the functionality above -- rms. | ||
| 237 | @findex kmacro-view-macro-repeat | 237 | @findex kmacro-view-macro-repeat |
| 238 | @kindex C-x C-k C-v | 238 | @kindex C-x C-k C-v |
| 239 | |||
| 240 | The command @kbd{C-x C-k C-v} (@code{kmacro-view-macro-repeat}) | 239 | The command @kbd{C-x C-k C-v} (@code{kmacro-view-macro-repeat}) |
| 241 | displays the last keyboard macro, or when repeated (with @kbd{C-v}), | 240 | displays the last keyboard macro, or when repeated (with @kbd{C-v}), |
| 242 | it displays the previous macro on the macro ring, just like @kbd{C-x | 241 | it displays the previous macro on the macro ring, just like @kbd{C-x |
| @@ -248,7 +247,11 @@ macro is executed, but still without altering the macro ring. | |||
| 248 | macro the current macro and executes it twice, @kbd{C-x C-k C-v C-v | 247 | macro the current macro and executes it twice, @kbd{C-x C-k C-v C-v |
| 249 | C-v C-k C-k} will display and execute the 3rd previous macro once and | 248 | C-v C-k C-k} will display and execute the 3rd previous macro once and |
| 250 | then the current macro once. | 249 | then the current macro once. |
| 250 | @end ignore | ||
| 251 | 251 | ||
| 252 | @ignore @c This is just too much feeping creaturism. | ||
| 253 | @c If you are reusing certain macros enough to want these, | ||
| 254 | @c you should give then names. -- rms | ||
| 252 | @findex kmacro-delete-ring-head | 255 | @findex kmacro-delete-ring-head |
| 253 | @kindex C-x C-k C-d | 256 | @kindex C-x C-k C-d |
| 254 | 257 | ||
| @@ -269,6 +272,7 @@ the macro ring. | |||
| 269 | 272 | ||
| 270 | The command @kbd{C-x C-k C-l} (@code{kmacro-call-ring-2nd-repeat}) | 273 | The command @kbd{C-x C-k C-l} (@code{kmacro-call-ring-2nd-repeat}) |
| 271 | executes the previous (rather than the head) element on the macro ring. | 274 | executes the previous (rather than the head) element on the macro ring. |
| 275 | @end ignore | ||
| 272 | 276 | ||
| 273 | @vindex kmacro-ring-max | 277 | @vindex kmacro-ring-max |
| 274 | The maximum number of macros stored in the keyboard macro ring is | 278 | The maximum number of macros stored in the keyboard macro ring is |
| @@ -277,6 +281,19 @@ determined by the customizable variable @code{kmacro-ring-max}. | |||
| 277 | @node Keyboard Macro Counter | 281 | @node Keyboard Macro Counter |
| 278 | @section The Keyboard Macro Counter | 282 | @section The Keyboard Macro Counter |
| 279 | 283 | ||
| 284 | @table @kbd | ||
| 285 | @item C-x C-k C-i | ||
| 286 | Insert the keyboard macro counter value in the buffer | ||
| 287 | (@code{kmacro-insert-counter}). | ||
| 288 | @item C-x C-k C-c | ||
| 289 | Set the keyboard macro counter (@code{kmacro-set-counter}). | ||
| 290 | @item C-x C-k C-a | ||
| 291 | Add the prefix arg to the keyboard macro counter (@code{kmacro-add-counter}). | ||
| 292 | @item C-x C-k C-f | ||
| 293 | Specify the format for inserting the keyboard macro counter | ||
| 294 | (@code{kmacro-set-format}). | ||
| 295 | @end table | ||
| 296 | |||
| 280 | Each keyboard macro has an associated counter. Normally, the | 297 | Each keyboard macro has an associated counter. Normally, the |
| 281 | macro counter is initialized to 0 when you start defining the macro, | 298 | macro counter is initialized to 0 when you start defining the macro, |
| 282 | and incremented by 1 after each insertion of the counter value; | 299 | and incremented by 1 after each insertion of the counter value; |
| @@ -364,6 +381,12 @@ numbers stored in registers. | |||
| 364 | @node Keyboard Macro Query | 381 | @node Keyboard Macro Query |
| 365 | @section Executing Macros with Variations | 382 | @section Executing Macros with Variations |
| 366 | 383 | ||
| 384 | @table @kbd | ||
| 385 | @item C-x q | ||
| 386 | When this point is reached during macro execution, ask for confirmation | ||
| 387 | (@code{kbd-macro-query}). | ||
| 388 | @end table | ||
| 389 | |||
| 367 | @kindex C-x q | 390 | @kindex C-x q |
| 368 | @findex kbd-macro-query | 391 | @findex kbd-macro-query |
| 369 | Using @kbd{C-x q} (@code{kbd-macro-query}), you can get an effect | 392 | Using @kbd{C-x q} (@code{kbd-macro-query}), you can get an effect |
| @@ -408,6 +431,17 @@ register as a counter, incrementing it on each repetition of the macro. | |||
| 408 | @node Save Keyboard Macro | 431 | @node Save Keyboard Macro |
| 409 | @section Naming and Saving Keyboard Macros | 432 | @section Naming and Saving Keyboard Macros |
| 410 | 433 | ||
| 434 | @table @kbd | ||
| 435 | @item C-x C-k n | ||
| 436 | Give a command name (for the duration of the Emacs session) to the most | ||
| 437 | recently defined keyboard macro (@code{kmacro-name-last-macro}). | ||
| 438 | @item C-x C-k b | ||
| 439 | Bind the most recently defined keyboard macro to a key sequence (for | ||
| 440 | the duration of the session) (@code{kmacro-bind-to-key}). | ||
| 441 | @item M-x insert-kbd-macro | ||
| 442 | Insert in the buffer a keyboard macro's definition, as Lisp code. | ||
| 443 | @end table | ||
| 444 | |||
| 411 | @cindex saving keyboard macros | 445 | @cindex saving keyboard macros |
| 412 | @findex kmacro-name-last-macro | 446 | @findex kmacro-name-last-macro |
| 413 | @kindex C-x C-k n | 447 | @kindex C-x C-k n |
| @@ -434,7 +468,7 @@ bindings, you should select the key sequence carefully. If you try to | |||
| 434 | bind to a key sequence with an existing binding (in any keymap), this | 468 | bind to a key sequence with an existing binding (in any keymap), this |
| 435 | command asks you for confirmation before replacing the existing binding. | 469 | command asks you for confirmation before replacing the existing binding. |
| 436 | 470 | ||
| 437 | To avoid problems caused by overriding existing bindings, the key | 471 | To avoid problems caused by overriding existing bindings, the key |
| 438 | sequences @kbd{C-x C-k 0} through @kbd{C-x C-k 9} and @kbd{C-x C-k A} | 472 | sequences @kbd{C-x C-k 0} through @kbd{C-x C-k 9} and @kbd{C-x C-k A} |
| 439 | through @kbd{C-x C-k Z} are reserved for your own keyboard macro | 473 | through @kbd{C-x C-k Z} are reserved for your own keyboard macro |
| 440 | bindings. In fact, to bind to one of these key sequences, you only | 474 | bindings. In fact, to bind to one of these key sequences, you only |
| @@ -474,6 +508,16 @@ when you load the file. | |||
| 474 | @node Edit Keyboard Macro | 508 | @node Edit Keyboard Macro |
| 475 | @section Editing a Keyboard Macro | 509 | @section Editing a Keyboard Macro |
| 476 | 510 | ||
| 511 | @table @kbd | ||
| 512 | @item C-x C-k C-e | ||
| 513 | Edit the last defined keyboard macro (@code{kmacro-edit-macro}). | ||
| 514 | @item C-x C-k e @var{name} @key{RET} | ||
| 515 | Edit a previously defined keyboard macro @var{name} (@code{edit-kbd-macro}). | ||
| 516 | @item C-x C-k l | ||
| 517 | Edit the last 100 keystrokes as a keyboard macro | ||
| 518 | (@code{kmacro-edit-lossage}). | ||
| 519 | @end table | ||
| 520 | |||
| 477 | @findex kmacro-edit-macro | 521 | @findex kmacro-edit-macro |
| 478 | @kindex C-x C-k C-e | 522 | @kindex C-x C-k C-e |
| 479 | @kindex C-x C-k RET | 523 | @kindex C-x C-k RET |
diff --git a/man/macos.texi b/man/macos.texi index 3649c18040e..b4c09217092 100644 --- a/man/macos.texi +++ b/man/macos.texi | |||
| @@ -130,7 +130,7 @@ One can still do copy and paste with another application from the Edit | |||
| 130 | menu. | 130 | menu. |
| 131 | 131 | ||
| 132 | On Mac, the role of the coding system for selection that is set by | 132 | On Mac, the role of the coding system for selection that is set by |
| 133 | @code{set-selection-coding-system} (@pxref{Specify Coding}) is | 133 | @code{set-selection-coding-system} (@pxref{Communication Coding}) is |
| 134 | two-fold. First, it is used as a preferred coding system for the | 134 | two-fold. First, it is used as a preferred coding system for the |
| 135 | traditional text flavor that does not specify any particular encodings | 135 | traditional text flavor that does not specify any particular encodings |
| 136 | and is mainly used by applications on Mac OS Classic. Second, it | 136 | and is mainly used by applications on Mac OS Classic. Second, it |
diff --git a/man/major.texi b/man/major.texi index 74613a24321..5bff7146ebe 100644 --- a/man/major.texi +++ b/man/major.texi | |||
| @@ -65,10 +65,10 @@ because most lines in a program are usually indented | |||
| 65 | most of the time Emacs determines which mode to use based on the file | 65 | most of the time Emacs determines which mode to use based on the file |
| 66 | name or on special text in the file. | 66 | name or on special text in the file. |
| 67 | 67 | ||
| 68 | Explicit selection of a new major mode is done with a @kbd{M-x} command. | 68 | To explicitly select a new major, you use an @kbd{M-x} command. |
| 69 | From the name of a major mode, add @code{-mode} to get the name of a | 69 | Take the name of a major mode and add @code{-mode} to get the name of |
| 70 | command to select that mode. Thus, you can enter Lisp mode by executing | 70 | the command to select that mode. Thus, you can enter Lisp mode by |
| 71 | @kbd{M-x lisp-mode}. | 71 | executing @kbd{M-x lisp-mode}. |
| 72 | 72 | ||
| 73 | @vindex auto-mode-alist | 73 | @vindex auto-mode-alist |
| 74 | When you visit a file, Emacs usually chooses the right major mode based | 74 | When you visit a file, Emacs usually chooses the right major mode based |
diff --git a/man/misc.texi b/man/misc.texi index f1f19ea8b6a..cae58a9c7f4 100644 --- a/man/misc.texi +++ b/man/misc.texi | |||
| @@ -419,7 +419,7 @@ the buffer @samp{*Async Shell Command*}. Output arrives in that | |||
| 419 | buffer regardless of whether it is visible in a window. | 419 | buffer regardless of whether it is visible in a window. |
| 420 | 420 | ||
| 421 | To specify a coding system for @kbd{M-!} or @kbd{M-|}, use the command | 421 | To specify a coding system for @kbd{M-!} or @kbd{M-|}, use the command |
| 422 | @kbd{C-x @key{RET} c} immediately beforehand. @xref{Specify Coding}. | 422 | @kbd{C-x @key{RET} c} immediately beforehand. @xref{Communication Coding}. |
| 423 | 423 | ||
| 424 | @vindex shell-command-default-error-buffer | 424 | @vindex shell-command-default-error-buffer |
| 425 | Error output from the command is normally intermixed with the regular | 425 | Error output from the command is normally intermixed with the regular |
| @@ -481,7 +481,7 @@ from. For example, if you use bash, the file sent to it is | |||
| 481 | To specify a coding system for the shell, you can use the command | 481 | To specify a coding system for the shell, you can use the command |
| 482 | @kbd{C-x @key{RET} c} immediately before @kbd{M-x shell}. You can also | 482 | @kbd{C-x @key{RET} c} immediately before @kbd{M-x shell}. You can also |
| 483 | specify a coding system after starting the shell by using @kbd{C-x | 483 | specify a coding system after starting the shell by using @kbd{C-x |
| 484 | @key{RET} p} in the shell buffer. @xref{Specify Coding}. | 484 | @key{RET} p} in the shell buffer. @xref{Communication Coding}. |
| 485 | 485 | ||
| 486 | @cindex @env{EMACS} environment variable | 486 | @cindex @env{EMACS} environment variable |
| 487 | Unless the environment variable @env{EMACS} is already defined, | 487 | Unless the environment variable @env{EMACS} is already defined, |
diff --git a/man/msdog.texi b/man/msdog.texi index 1724a1103fb..58ce170a738 100644 --- a/man/msdog.texi +++ b/man/msdog.texi | |||
| @@ -344,7 +344,7 @@ the usual carriage-return linefeed. | |||
| 344 | 344 | ||
| 345 | @cindex DOS-to-Unix conversion of files | 345 | @cindex DOS-to-Unix conversion of files |
| 346 | To visit a file and specify whether it uses DOS-style or Unix-style | 346 | To visit a file and specify whether it uses DOS-style or Unix-style |
| 347 | end-of-line, specify a coding system (@pxref{Specify Coding}). For | 347 | end-of-line, specify a coding system (@pxref{Text Coding}). For |
| 348 | example, @kbd{C-x @key{RET} c unix @key{RET} C-x C-f foobar.txt} | 348 | example, @kbd{C-x @key{RET} c unix @key{RET} C-x C-f foobar.txt} |
| 349 | visits the file @file{foobar.txt} without converting the EOLs; if some | 349 | visits the file @file{foobar.txt} without converting the EOLs; if some |
| 350 | line ends with a carriage-return linefeed pair, Emacs will display | 350 | line ends with a carriage-return linefeed pair, Emacs will display |
| @@ -719,7 +719,7 @@ visit a file written on a DOS machine in another country), use the | |||
| 719 | the codepage, with completion, then creates the coding system for the | 719 | the codepage, with completion, then creates the coding system for the |
| 720 | specified codepage. You can then use the new coding system to read and | 720 | specified codepage. You can then use the new coding system to read and |
| 721 | write files, but you must specify it explicitly for the file command | 721 | write files, but you must specify it explicitly for the file command |
| 722 | when you want to use it (@pxref{Specify Coding}). | 722 | when you want to use it (@pxref{Text Coding}). |
| 723 | 723 | ||
| 724 | These coding systems are also useful for visiting a file encoded using | 724 | These coding systems are also useful for visiting a file encoded using |
| 725 | a DOS codepage, using Emacs running on some other operating system. | 725 | a DOS codepage, using Emacs running on some other operating system. |
diff --git a/man/mule.texi b/man/mule.texi index fa5e1246f25..86f7bec0b9b 100644 --- a/man/mule.texi +++ b/man/mule.texi | |||
| @@ -40,10 +40,7 @@ including European and Vietnamese variants of the Latin alphabet, as | |||
| 40 | well as Cyrillic, Devanagari (for Hindi and Marathi), Ethiopic, Greek, | 40 | well as Cyrillic, Devanagari (for Hindi and Marathi), Ethiopic, Greek, |
| 41 | Han (for Chinese and Japanese), Hangul (for Korean), Hebrew, IPA, | 41 | Han (for Chinese and Japanese), Hangul (for Korean), Hebrew, IPA, |
| 42 | Kannada, Lao, Malayalam, Tamil, Thai, Tibetan, and Vietnamese scripts. | 42 | Kannada, Lao, Malayalam, Tamil, Thai, Tibetan, and Vietnamese scripts. |
| 43 | These features have been merged from the modified version of Emacs | 43 | Emacs also supports various encodings of these characters used by |
| 44 | known as MULE (for ``MULti-lingual Enhancement to GNU Emacs'') | ||
| 45 | |||
| 46 | Emacs also supports various encodings of these characters used by | ||
| 47 | other internationalized software, such as word processors and mailers. | 44 | other internationalized software, such as word processors and mailers. |
| 48 | 45 | ||
| 49 | Emacs allows editing text with international characters by supporting | 46 | Emacs allows editing text with international characters by supporting |
| @@ -57,15 +54,15 @@ compilers, spell-checkers, and mailers). Setting your language | |||
| 57 | environment (@pxref{Language Environments}) takes care of setting up the | 54 | environment (@pxref{Language Environments}) takes care of setting up the |
| 58 | coding systems and other options for a specific language or culture. | 55 | coding systems and other options for a specific language or culture. |
| 59 | Alternatively, you can specify how Emacs should encode or decode text | 56 | Alternatively, you can specify how Emacs should encode or decode text |
| 60 | for each command; see @ref{Specify Coding}. | 57 | for each command; see @ref{Text Coding}. |
| 61 | 58 | ||
| 62 | @item | 59 | @item |
| 63 | You can display non-@acronym{ASCII} characters encoded by the various scripts. | 60 | You can display non-@acronym{ASCII} characters encoded by the various |
| 64 | This works by using appropriate fonts on X and similar graphics | 61 | scripts. This works by using appropriate fonts on graphics displays |
| 65 | displays (@pxref{Defining Fontsets}), and by sending special codes to | 62 | (@pxref{Defining Fontsets}), and by sending special codes to text-only |
| 66 | text-only displays (@pxref{Specify Coding}). If some characters are | 63 | displays (@pxref{Terminal Coding}). If some characters are displayed |
| 67 | displayed incorrectly, refer to @ref{Undisplayable Characters}, which | 64 | incorrectly, refer to @ref{Undisplayable Characters}, which describes |
| 68 | describes possible problems and explains how to solve them. | 65 | possible problems and explains how to solve them. |
| 69 | 66 | ||
| 70 | @item | 67 | @item |
| 71 | You can insert non-@acronym{ASCII} characters or search for them. To do that, | 68 | You can insert non-@acronym{ASCII} characters or search for them. To do that, |
| @@ -73,12 +70,14 @@ you can specify an input method (@pxref{Select Input Method}) suitable | |||
| 73 | for your language, or use the default input method set up when you set | 70 | for your language, or use the default input method set up when you set |
| 74 | your language environment. If | 71 | your language environment. If |
| 75 | your keyboard can produce non-@acronym{ASCII} characters, you can select an | 72 | your keyboard can produce non-@acronym{ASCII} characters, you can select an |
| 76 | appropriate keyboard coding system (@pxref{Specify Coding}), and Emacs | 73 | appropriate keyboard coding system (@pxref{Terminal Coding}), and Emacs |
| 77 | will accept those characters. Latin-1 characters can also be input by | 74 | will accept those characters. Latin-1 characters can also be input by |
| 78 | using the @kbd{C-x 8} prefix, see @ref{Single-Byte Character Support, | 75 | using the @kbd{C-x 8} prefix, see @ref{Single-Byte Character Support, |
| 79 | C-x 8}. On X Window systems, your locale should be set to an | 76 | C-x 8}. |
| 80 | appropriate value to make sure Emacs interprets keyboard input | 77 | |
| 81 | correctly; see @ref{Language Environments, locales}. | 78 | On X Window systems, your locale should be set to an appropriate value |
| 79 | to make sure Emacs interprets keyboard input correctly; see | ||
| 80 | @ref{Language Environments, locales}. | ||
| 82 | @end itemize | 81 | @end itemize |
| 83 | 82 | ||
| 84 | The rest of this chapter describes these issues in detail. | 83 | The rest of this chapter describes these issues in detail. |
| @@ -93,7 +92,11 @@ correctly; see @ref{Language Environments, locales}. | |||
| 93 | * Coding Systems:: Character set conversion when you read and | 92 | * Coding Systems:: Character set conversion when you read and |
| 94 | write files, and so on. | 93 | write files, and so on. |
| 95 | * Recognize Coding:: How Emacs figures out which conversion to use. | 94 | * Recognize Coding:: How Emacs figures out which conversion to use. |
| 96 | * Specify Coding:: Various ways to choose which conversion to use. | 95 | * Text Coding:: Choosing conversion to use for file text. |
| 96 | * Communication Coding:: Coding systems for interprocess communication. | ||
| 97 | * File Name Coding:: Coding systems for file @emph{names}. | ||
| 98 | * Terminal Coding:: Specifying coding systems for converting | ||
| 99 | terminal input and output. | ||
| 97 | * Fontsets:: Fontsets are collections of fonts | 100 | * Fontsets:: Fontsets are collections of fonts |
| 98 | that cover the whole spectrum of characters. | 101 | that cover the whole spectrum of characters. |
| 99 | * Defining Fontsets:: Defining a new fontset. | 102 | * Defining Fontsets:: Defining a new fontset. |
| @@ -106,15 +109,16 @@ correctly; see @ref{Language Environments, locales}. | |||
| 106 | @node International Chars | 109 | @node International Chars |
| 107 | @section Introduction to International Character Sets | 110 | @section Introduction to International Character Sets |
| 108 | 111 | ||
| 109 | The users of international character sets and scripts have established | 112 | The users of international character sets and scripts have |
| 110 | many more-or-less standard coding systems for storing files. Emacs | 113 | established many more-or-less standard coding systems for storing |
| 111 | internally uses a single multibyte character encoding, so that it can | 114 | files. Emacs internally uses a single multibyte character encoding, |
| 112 | intermix characters from all these scripts in a single buffer or string. | 115 | so that it can intermix characters from all these scripts in a single |
| 113 | This encoding represents each non-@acronym{ASCII} character as a sequence of bytes | 116 | buffer or string. This encoding represents each non-@acronym{ASCII} |
| 114 | in the range 0200 through 0377. Emacs translates between the multibyte | 117 | character as a sequence of bytes in the range 0200 through 0377. |
| 115 | character encoding and various other coding systems when reading and | 118 | Emacs translates between the multibyte character encoding and various |
| 116 | writing files, when exchanging data with subprocesses, and (in some | 119 | other coding systems when reading and writing files, when exchanging |
| 117 | cases) in the @kbd{C-q} command (@pxref{Multibyte Conversion}). | 120 | data with subprocesses, and (in some cases) in the @kbd{C-q} command |
| 121 | (@pxref{Multibyte Conversion}). | ||
| 118 | 122 | ||
| 119 | @kindex C-h h | 123 | @kindex C-h h |
| 120 | @findex view-hello-file | 124 | @findex view-hello-file |
| @@ -138,23 +142,24 @@ to multibyte characters, coding systems, and input methods. | |||
| 138 | @node Enabling Multibyte | 142 | @node Enabling Multibyte |
| 139 | @section Enabling Multibyte Characters | 143 | @section Enabling Multibyte Characters |
| 140 | 144 | ||
| 141 | @cindex turn multibyte support on or off | ||
| 142 | You can enable or disable multibyte character support, either for | ||
| 143 | Emacs as a whole, or for a single buffer. When multibyte characters are | ||
| 144 | disabled in a buffer, then each byte in that buffer represents a | ||
| 145 | character, even codes 0200 through 0377. The old features for | ||
| 146 | supporting the European character sets, ISO Latin-1 and ISO Latin-2, | ||
| 147 | work as they did in Emacs 19 and also work for the other ISO 8859 | ||
| 148 | character sets. | ||
| 149 | |||
| 150 | However, there is no need to turn off multibyte character support to | ||
| 151 | use ISO Latin; the Emacs multibyte character set includes all the | ||
| 152 | characters in these character sets, and Emacs can translate | ||
| 153 | automatically to and from the ISO codes. | ||
| 154 | |||
| 155 | By default, Emacs starts in multibyte mode, because that allows you to | 145 | By default, Emacs starts in multibyte mode, because that allows you to |
| 156 | use all the supported languages and scripts without limitations. | 146 | use all the supported languages and scripts without limitations. |
| 157 | 147 | ||
| 148 | @cindex turn multibyte support on or off | ||
| 149 | You can enable or disable multibyte character support, either for | ||
| 150 | Emacs as a whole, or for a single buffer. When multibyte characters | ||
| 151 | are disabled in a buffer, we call that @dfn{unibyte mode}. Then each | ||
| 152 | byte in that buffer represents a character, even codes 0200 through | ||
| 153 | 0377. | ||
| 154 | |||
| 155 | The old features for supporting the European character sets, ISO | ||
| 156 | Latin-1 and ISO Latin-2, work in unibyte mode as they did in Emacs 19 | ||
| 157 | and also work for the other ISO 8859 character sets. However, there | ||
| 158 | is no need to turn off multibyte character support to use ISO Latin; | ||
| 159 | the Emacs multibyte character set includes all the characters in these | ||
| 160 | character sets, and Emacs can translate automatically to and from the | ||
| 161 | ISO codes. | ||
| 162 | |||
| 158 | To edit a particular file in unibyte representation, visit it using | 163 | To edit a particular file in unibyte representation, visit it using |
| 159 | @code{find-file-literally}. @xref{Visiting}. To convert a buffer in | 164 | @code{find-file-literally}. @xref{Visiting}. To convert a buffer in |
| 160 | multibyte representation into a single-byte representation of the same | 165 | multibyte representation into a single-byte representation of the same |
| @@ -162,7 +167,7 @@ characters, the easiest way is to save the contents in a file, kill the | |||
| 162 | buffer, and find the file again with @code{find-file-literally}. You | 167 | buffer, and find the file again with @code{find-file-literally}. You |
| 163 | can also use @kbd{C-x @key{RET} c} | 168 | can also use @kbd{C-x @key{RET} c} |
| 164 | (@code{universal-coding-system-argument}) and specify @samp{raw-text} as | 169 | (@code{universal-coding-system-argument}) and specify @samp{raw-text} as |
| 165 | the coding system with which to find or save a file. @xref{Specify | 170 | the coding system with which to find or save a file. @xref{Text |
| 166 | Coding}. Finding a file as @samp{raw-text} doesn't disable format | 171 | Coding}. Finding a file as @samp{raw-text} doesn't disable format |
| 167 | conversion, uncompression and auto mode selection as | 172 | conversion, uncompression and auto mode selection as |
| 168 | @code{find-file-literally} does. | 173 | @code{find-file-literally} does. |
| @@ -209,8 +214,8 @@ load a Lisp file as unibyte, on any one occasion, by typing @kbd{C-x | |||
| 209 | The mode line indicates whether multibyte character support is enabled | 214 | The mode line indicates whether multibyte character support is enabled |
| 210 | in the current buffer. If it is, there are two or more characters (most | 215 | in the current buffer. If it is, there are two or more characters (most |
| 211 | often two dashes) before the colon near the beginning of the mode line. | 216 | often two dashes) before the colon near the beginning of the mode line. |
| 212 | When multibyte characters are not enabled, just one dash precedes the | 217 | When multibyte characters are not enabled, nothing precedes the colon |
| 213 | colon. | 218 | except a single dash. |
| 214 | 219 | ||
| 215 | @node Language Environments | 220 | @node Language Environments |
| 216 | @section Language Environments | 221 | @section Language Environments |
| @@ -314,12 +319,12 @@ file. | |||
| 314 | @findex describe-language-environment | 319 | @findex describe-language-environment |
| 315 | To display information about the effects of a certain language | 320 | To display information about the effects of a certain language |
| 316 | environment @var{lang-env}, use the command @kbd{C-h L @var{lang-env} | 321 | environment @var{lang-env}, use the command @kbd{C-h L @var{lang-env} |
| 317 | @key{RET}} (@code{describe-language-environment}). This tells you which | 322 | @key{RET}} (@code{describe-language-environment}). This tells you |
| 318 | languages this language environment is useful for, and lists the | 323 | which languages this language environment is useful for, and lists the |
| 319 | character sets, coding systems, and input methods that go with it. It | 324 | character sets, coding systems, and input methods that go with it. It |
| 320 | also shows some sample text to illustrate scripts used in this language | 325 | also shows some sample text to illustrate scripts used in this |
| 321 | environment. By default, this command describes the chosen language | 326 | language environment. If you give an empty input for @var{lang-env}, |
| 322 | environment. | 327 | this command describes the chosen language environment. |
| 323 | 328 | ||
| 324 | @vindex set-language-environment-hook | 329 | @vindex set-language-environment-hook |
| 325 | You can customize any language environment with the normal hook | 330 | You can customize any language environment with the normal hook |
| @@ -483,9 +488,9 @@ language environment that it is meant to be used with. The variable | |||
| 483 | 488 | ||
| 484 | @findex toggle-input-method | 489 | @findex toggle-input-method |
| 485 | @kindex C-\ | 490 | @kindex C-\ |
| 486 | Input methods use various sequences of @acronym{ASCII} characters to stand for | 491 | Input methods use various sequences of @acronym{ASCII} characters to |
| 487 | non-@acronym{ASCII} characters. Sometimes it is useful to turn off the input | 492 | stand for non-@acronym{ASCII} characters. Sometimes it is useful to |
| 488 | method temporarily. To do this, type @kbd{C-\} | 493 | turn off the input method temporarily. To do this, type @kbd{C-\} |
| 489 | (@code{toggle-input-method}). To reenable the input method, type | 494 | (@code{toggle-input-method}). To reenable the input method, type |
| 490 | @kbd{C-\} again. | 495 | @kbd{C-\} again. |
| 491 | 496 | ||
| @@ -674,13 +679,14 @@ variants @code{iso-latin-1-unix}, @code{iso-latin-1-dos} and | |||
| 674 | @code{iso-latin-1-mac}. | 679 | @code{iso-latin-1-mac}. |
| 675 | 680 | ||
| 676 | The coding system @code{raw-text} is good for a file which is mainly | 681 | The coding system @code{raw-text} is good for a file which is mainly |
| 677 | @acronym{ASCII} text, but may contain byte values above 127 which are not meant to | 682 | @acronym{ASCII} text, but may contain byte values above 127 which are |
| 678 | encode non-@acronym{ASCII} characters. With @code{raw-text}, Emacs copies those | 683 | not meant to encode non-@acronym{ASCII} characters. With |
| 679 | byte values unchanged, and sets @code{enable-multibyte-characters} to | 684 | @code{raw-text}, Emacs copies those byte values unchanged, and sets |
| 680 | @code{nil} in the current buffer so that they will be interpreted | 685 | @code{enable-multibyte-characters} to @code{nil} in the current buffer |
| 681 | properly. @code{raw-text} handles end-of-line conversion in the usual | 686 | so that they will be interpreted properly. @code{raw-text} handles |
| 682 | way, based on the data encountered, and has the usual three variants to | 687 | end-of-line conversion in the usual way, based on the data |
| 683 | specify the kind of end-of-line conversion to use. | 688 | encountered, and has the usual three variants to specify the kind of |
| 689 | end-of-line conversion to use. | ||
| 684 | 690 | ||
| 685 | In contrast, the coding system @code{no-conversion} specifies no | 691 | In contrast, the coding system @code{no-conversion} specifies no |
| 686 | character code conversion at all---none for non-@acronym{ASCII} byte values and | 692 | character code conversion at all---none for non-@acronym{ASCII} byte values and |
| @@ -822,16 +828,16 @@ pattern, are decoded correctly. One of the builtin | |||
| 822 | 828 | ||
| 823 | If Emacs recognizes the encoding of a file incorrectly, you can | 829 | If Emacs recognizes the encoding of a file incorrectly, you can |
| 824 | reread the file using the correct coding system by typing @kbd{C-x | 830 | reread the file using the correct coding system by typing @kbd{C-x |
| 825 | @key{RET} r @var{coding-system} | 831 | @key{RET} r @var{coding-system} @key{RET}}. To see what coding system |
| 826 | @key{RET}}. To see what coding system Emacs actually used to decode | 832 | Emacs actually used to decode the file, look at the coding system |
| 827 | the file, look at the coding system mnemonic letter near the left edge | 833 | mnemonic letter near the left edge of the mode line (@pxref{Mode |
| 828 | of the mode line (@pxref{Mode Line}), or type @kbd{C-h C @key{RET}}. | 834 | Line}), or type @kbd{C-h C @key{RET}}. |
| 829 | 835 | ||
| 830 | @findex unify-8859-on-decoding-mode | 836 | @findex unify-8859-on-decoding-mode |
| 831 | The command @code{unify-8859-on-decoding-mode} enables a mode that | 837 | The command @code{unify-8859-on-decoding-mode} enables a mode that |
| 832 | ``unifies'' the Latin alphabets when decoding text. This works by | 838 | ``unifies'' the Latin alphabets when decoding text. This works by |
| 833 | converting all non-@acronym{ASCII} Latin-@var{n} characters to either Latin-1 or | 839 | converting all non-@acronym{ASCII} Latin-@var{n} characters to either |
| 834 | Unicode characters. This way it is easier to use various | 840 | Latin-1 or Unicode characters. This way it is easier to use various |
| 835 | Latin-@var{n} alphabets together. In a future Emacs version we hope | 841 | Latin-@var{n} alphabets together. In a future Emacs version we hope |
| 836 | to move towards full Unicode support and complete unification of | 842 | to move towards full Unicode support and complete unification of |
| 837 | character sets. | 843 | character sets. |
| @@ -843,7 +849,7 @@ system, by default, for operations that write from this buffer into a | |||
| 843 | file. This includes the commands @code{save-buffer} and | 849 | file. This includes the commands @code{save-buffer} and |
| 844 | @code{write-region}. If you want to write files from this buffer using | 850 | @code{write-region}. If you want to write files from this buffer using |
| 845 | a different coding system, you can specify a different coding system for | 851 | a different coding system, you can specify a different coding system for |
| 846 | the buffer using @code{set-buffer-file-coding-system} (@pxref{Specify | 852 | the buffer using @code{set-buffer-file-coding-system} (@pxref{Text |
| 847 | Coding}). | 853 | Coding}). |
| 848 | 854 | ||
| 849 | You can insert any possible character into any Emacs buffer, but | 855 | You can insert any possible character into any Emacs buffer, but |
| @@ -901,11 +907,12 @@ default value is @code{nil}, which means that Rmail files are not | |||
| 901 | translated (they are read and written in the Emacs internal character | 907 | translated (they are read and written in the Emacs internal character |
| 902 | code). | 908 | code). |
| 903 | 909 | ||
| 904 | @node Specify Coding | 910 | @node Text Coding |
| 905 | @section Specifying a Coding System | 911 | @section Specifying a Coding System for File Text |
| 906 | 912 | ||
| 907 | In cases where Emacs does not automatically choose the right coding | 913 | In cases where Emacs does not automatically choose the right coding |
| 908 | system, you can use these commands to specify one: | 914 | system for a file's contents, you can use these commands to specify |
| 915 | one: | ||
| 909 | 916 | ||
| 910 | @table @kbd | 917 | @table @kbd |
| 911 | @item C-x @key{RET} f @var{coding} @key{RET} | 918 | @item C-x @key{RET} f @var{coding} @key{RET} |
| @@ -919,32 +926,9 @@ command. | |||
| 919 | @item C-x @key{RET} r @var{coding} @key{RET} | 926 | @item C-x @key{RET} r @var{coding} @key{RET} |
| 920 | Revisit the current file using the coding system @var{coding}. | 927 | Revisit the current file using the coding system @var{coding}. |
| 921 | 928 | ||
| 922 | @item C-x @key{RET} k @var{coding} @key{RET} | 929 | @item M-x recode-region @key{RET} @var{right} @key{RET} @var{wrong} @key{RET} |
| 923 | Use coding system @var{coding} for keyboard input. | 930 | Convert a region that was decoded using coding system @var{wrong}, |
| 924 | 931 | decoding it using coding system @var{right} instead. | |
| 925 | @item C-x @key{RET} t @var{coding} @key{RET} | ||
| 926 | Use coding system @var{coding} for terminal output. | ||
| 927 | |||
| 928 | @item C-x @key{RET} p @var{input-coding} @key{RET} @var{output-coding} @key{RET} | ||
| 929 | Use coding systems @var{input-coding} and @var{output-coding} for | ||
| 930 | subprocess input and output in the current buffer. | ||
| 931 | |||
| 932 | @item C-x @key{RET} x @var{coding} @key{RET} | ||
| 933 | Use coding system @var{coding} for transferring selections to and from | ||
| 934 | other programs through the window system. | ||
| 935 | |||
| 936 | @item C-x @key{RET} F @var{coding} @key{RET} | ||
| 937 | Use coding system @var{coding} for encoding and decoding file | ||
| 938 | @emph{names}. This affects the use of non-ASCII characters in file | ||
| 939 | names. It has no effect on reading and writing the @emph{contents} of | ||
| 940 | files. | ||
| 941 | |||
| 942 | @item C-x @key{RET} X @var{coding} @key{RET} | ||
| 943 | Use coding system @var{coding} for transferring @emph{one} | ||
| 944 | selection---the next one---to or from the window system. | ||
| 945 | |||
| 946 | @item M-x recode-region | ||
| 947 | Convert the region from a previous coding system to a new one. | ||
| 948 | @end table | 932 | @end table |
| 949 | 933 | ||
| 950 | @kindex C-x RET f | 934 | @kindex C-x RET f |
| @@ -978,10 +962,9 @@ contains characters that the coding system cannot handle. | |||
| 978 | Other file commands affected by a specified coding system include | 962 | Other file commands affected by a specified coding system include |
| 979 | @kbd{C-x C-i} and @kbd{C-x C-v}, as well as the other-window variants | 963 | @kbd{C-x C-i} and @kbd{C-x C-v}, as well as the other-window variants |
| 980 | of @kbd{C-x C-f}. @kbd{C-x @key{RET} c} also affects commands that | 964 | of @kbd{C-x C-f}. @kbd{C-x @key{RET} c} also affects commands that |
| 981 | start subprocesses, including @kbd{M-x shell} (@pxref{Shell}). | 965 | start subprocesses, including @kbd{M-x shell} (@pxref{Shell}). If the |
| 982 | 966 | immediately following command does not use the coding system, then | |
| 983 | If the immediately following command does not use the coding system, | 967 | @kbd{C-x @key{RET} c} ultimately has no effect. |
| 984 | then @kbd{C-x @key{RET} c} ultimately has no effect. | ||
| 985 | 968 | ||
| 986 | An easy way to visit a file with no conversion is with the @kbd{M-x | 969 | An easy way to visit a file with no conversion is with the @kbd{M-x |
| 987 | find-file-literally} command. @xref{Visiting}. | 970 | find-file-literally} command. @xref{Visiting}. |
| @@ -1000,62 +983,45 @@ environment. | |||
| 1000 | with @kbd{C-x @key{RET} r} (@code{revert-buffer-with-coding-system}). | 983 | with @kbd{C-x @key{RET} r} (@code{revert-buffer-with-coding-system}). |
| 1001 | This visits the current file again, using a coding system you specify. | 984 | This visits the current file again, using a coding system you specify. |
| 1002 | 985 | ||
| 1003 | @kindex C-x RET t | 986 | @findex recode-region |
| 1004 | @findex set-terminal-coding-system | 987 | If a piece of text has already been inserted into a buffer using the |
| 1005 | The command @kbd{C-x @key{RET} t} (@code{set-terminal-coding-system}) | 988 | wrong coding system, you can redo the decoding of it using @kbd{M-x |
| 1006 | specifies the coding system for terminal output. If you specify a | 989 | recode-region}. This prompts you for the proper coding system, then |
| 1007 | character code for terminal output, all characters output to the | 990 | for the wrong coding system that was actually used, and does the |
| 1008 | terminal are translated into that coding system. | 991 | conversion. It first encodes the region using the wrong coding system, |
| 992 | then decodes it again using the proper coding system. | ||
| 1009 | 993 | ||
| 1010 | This feature is useful for certain character-only terminals built to | 994 | @node Communication Coding |
| 1011 | support specific languages or character sets---for example, European | 995 | @section Coding Systems for Interprocess Communication |
| 1012 | terminals that support one of the ISO Latin character sets. You need to | ||
| 1013 | specify the terminal coding system when using multibyte text, so that | ||
| 1014 | Emacs knows which characters the terminal can actually handle. | ||
| 1015 | 996 | ||
| 1016 | By default, output to the terminal is not translated at all, unless | 997 | This section explains how to specify coding systems for use |
| 1017 | Emacs can deduce the proper coding system from your terminal type or | 998 | in communication with other processes. |
| 1018 | your locale specification (@pxref{Language Environments}). | ||
| 1019 | |||
| 1020 | @kindex C-x RET k | ||
| 1021 | @findex set-keyboard-coding-system | ||
| 1022 | @vindex keyboard-coding-system | ||
| 1023 | The command @kbd{C-x @key{RET} k} (@code{set-keyboard-coding-system}) | ||
| 1024 | or the variable @code{keyboard-coding-system} specifies the coding | ||
| 1025 | system for keyboard input. Character-code translation of keyboard | ||
| 1026 | input is useful for terminals with keys that send non-@acronym{ASCII} | ||
| 1027 | graphic characters---for example, some terminals designed for ISO | ||
| 1028 | Latin-1 or subsets of it. | ||
| 1029 | 999 | ||
| 1030 | By default, keyboard input is translated based on your system locale | 1000 | @table @kbd |
| 1031 | setting. If your terminal does not really support the encoding | 1001 | @item C-x @key{RET} x @var{coding} @key{RET} |
| 1032 | implied by your locale (for example, if you find it inserts a | 1002 | Use coding system @var{coding} for transferring selections to and from |
| 1033 | non-@acronym{ASCII} character if you type @kbd{M-i}), you will need to set | 1003 | other programs through the window system. |
| 1034 | @code{keyboard-coding-system} to @code{nil} to turn off encoding. | ||
| 1035 | You can do this by putting | ||
| 1036 | 1004 | ||
| 1037 | @lisp | 1005 | @item C-x @key{RET} X @var{coding} @key{RET} |
| 1038 | (set-keyboard-coding-system nil) | 1006 | Use coding system @var{coding} for transferring @emph{one} |
| 1039 | @end lisp | 1007 | selection---the next one---to or from the window system. |
| 1040 | 1008 | ||
| 1041 | @noindent | 1009 | @item C-x @key{RET} p @var{input-coding} @key{RET} @var{output-coding} @key{RET} |
| 1042 | in your @file{~/.emacs} file. | 1010 | Use coding systems @var{input-coding} and @var{output-coding} for |
| 1011 | subprocess input and output in the current buffer. | ||
| 1043 | 1012 | ||
| 1044 | There is a similarity between using a coding system translation for | 1013 | @item C-x @key{RET} c @var{coding} @key{RET} |
| 1045 | keyboard input, and using an input method: both define sequences of | 1014 | Specify coding system @var{coding} for the immediately following |
| 1046 | keyboard input that translate into single characters. However, input | 1015 | command. |
| 1047 | methods are designed to be convenient for interactive use by humans, and | 1016 | @end table |
| 1048 | the sequences that are translated are typically sequences of @acronym{ASCII} | ||
| 1049 | printing characters. Coding systems typically translate sequences of | ||
| 1050 | non-graphic characters. | ||
| 1051 | 1017 | ||
| 1052 | @kindex C-x RET x | 1018 | @kindex C-x RET x |
| 1053 | @kindex C-x RET X | 1019 | @kindex C-x RET X |
| 1054 | @findex set-selection-coding-system | 1020 | @findex set-selection-coding-system |
| 1055 | @findex set-next-selection-coding-system | 1021 | @findex set-next-selection-coding-system |
| 1056 | The command @kbd{C-x @key{RET} x} (@code{set-selection-coding-system}) | 1022 | The command @kbd{C-x @key{RET} x} (@code{set-selection-coding-system}) |
| 1057 | specifies the coding system for sending selected text to the window | 1023 | specifies the coding system for sending selected text to other windowing |
| 1058 | system, and for receiving the text of selections made in other | 1024 | applications, and for receiving the text of selections made in other |
| 1059 | applications. This command applies to all subsequent selections, until | 1025 | applications. This command applies to all subsequent selections, until |
| 1060 | you override it by using the command again. The command @kbd{C-x | 1026 | you override it by using the command again. The command @kbd{C-x |
| 1061 | @key{RET} X} (@code{set-next-selection-coding-system}) specifies the | 1027 | @key{RET} X} (@code{set-next-selection-coding-system}) specifies the |
| @@ -1070,33 +1036,56 @@ own buffer, and thus you can use this command to specify translation to | |||
| 1070 | and from a particular subprocess by giving the command in the | 1036 | and from a particular subprocess by giving the command in the |
| 1071 | corresponding buffer. | 1037 | corresponding buffer. |
| 1072 | 1038 | ||
| 1039 | You can also use @kbd{C-x @key{RET} c} just before the command that | ||
| 1040 | runs or starts a subprocess, to specify the coding system to use for | ||
| 1041 | communication with that subprocess. | ||
| 1042 | |||
| 1073 | The default for translation of process input and output depends on the | 1043 | The default for translation of process input and output depends on the |
| 1074 | current language environment. | 1044 | current language environment. |
| 1075 | 1045 | ||
| 1076 | @findex recode-region | 1046 | @vindex locale-coding-system |
| 1077 | If a piece of text has already been inserted into a buffer using the | 1047 | @cindex decoding non-@acronym{ASCII} keyboard input on X |
| 1078 | wrong coding system, you can decode it again using @kbd{M-x | 1048 | The variable @code{locale-coding-system} specifies a coding system |
| 1079 | recode-region}. This prompts you for the old coding system and the | 1049 | to use when encoding and decoding system strings such as system error |
| 1080 | desired coding system, and acts on the text in the region. | 1050 | messages and @code{format-time-string} formats and time stamps. That |
| 1051 | coding system is also used for decoding non-@acronym{ASCII} keyboard input on X | ||
| 1052 | Window systems. You should choose a coding system that is compatible | ||
| 1053 | with the underlying system's text representation, which is normally | ||
| 1054 | specified by one of the environment variables @env{LC_ALL}, | ||
| 1055 | @env{LC_CTYPE}, and @env{LANG}. (The first one, in the order | ||
| 1056 | specified above, whose value is nonempty is the one that determines | ||
| 1057 | the text representation.) | ||
| 1058 | |||
| 1059 | @node File Name Coding | ||
| 1060 | @section Coding Systems for File Names | ||
| 1061 | |||
| 1062 | @table @kbd | ||
| 1063 | @item C-x @key{RET} F @var{coding} @key{RET} | ||
| 1064 | Use coding system @var{coding} for encoding and decoding file | ||
| 1065 | @emph{names}. | ||
| 1066 | @end table | ||
| 1081 | 1067 | ||
| 1082 | @vindex file-name-coding-system | 1068 | @vindex file-name-coding-system |
| 1083 | @cindex file names with non-@acronym{ASCII} characters | 1069 | @cindex file names with non-@acronym{ASCII} characters |
| 1070 | The variable @code{file-name-coding-system} specifies a coding | ||
| 1071 | system to use for encoding file names. It has no effect on reading | ||
| 1072 | and writing the @emph{contents} of files. | ||
| 1073 | |||
| 1084 | @findex set-file-name-coding-system | 1074 | @findex set-file-name-coding-system |
| 1085 | @kindex C-x @key{RET} F | 1075 | @kindex C-x @key{RET} F |
| 1086 | The variable @code{file-name-coding-system} specifies a coding | 1076 | If you set the variable to a coding system name (as a Lisp symbol or |
| 1087 | system to use for encoding file names. If you set the variable to a | 1077 | a string), Emacs encodes file names using that coding system for all |
| 1088 | coding system name (as a Lisp symbol or a string), Emacs encodes file | 1078 | file operations. This makes it possible to use non-@acronym{ASCII} |
| 1089 | names using that coding system for all file operations. This makes it | 1079 | characters in file names---or, at least, those non-@acronym{ASCII} |
| 1090 | possible to use non-@acronym{ASCII} characters in file names---or, at | 1080 | characters which the specified coding system can encode. Use @kbd{C-x |
| 1091 | least, those non-@acronym{ASCII} characters which the specified coding | 1081 | @key{RET} F} (@code{set-file-name-coding-system}) to specify this |
| 1092 | system can encode. Use @kbd{C-x @key{RET} F} | 1082 | interactively. |
| 1093 | (@code{set-file-name-coding-system}) to specify this interactively. | 1083 | |
| 1094 | 1084 | If @code{file-name-coding-system} is @code{nil}, Emacs uses a | |
| 1095 | If @code{file-name-coding-system} is @code{nil}, Emacs uses a default | 1085 | default coding system determined by the selected language environment. |
| 1096 | coding system determined by the selected language environment. In the | 1086 | In the default language environment, any non-@acronym{ASCII} |
| 1097 | default language environment, any non-@acronym{ASCII} characters in file names are | 1087 | characters in file names are not encoded specially; they appear in the |
| 1098 | not encoded specially; they appear in the file system using the internal | 1088 | file system using the internal Emacs representation. |
| 1099 | Emacs representation. | ||
| 1100 | 1089 | ||
| 1101 | @strong{Warning:} if you change @code{file-name-coding-system} (or the | 1090 | @strong{Warning:} if you change @code{file-name-coding-system} (or the |
| 1102 | language environment) in the middle of an Emacs session, problems can | 1091 | language environment) in the middle of an Emacs session, problems can |
| @@ -1113,28 +1102,75 @@ C-w} to specify a new file name for that buffer. | |||
| 1113 | system. This prompts for an existing file name, its old coding | 1102 | system. This prompts for an existing file name, its old coding |
| 1114 | system, and the coding system to which you wish to convert. | 1103 | system, and the coding system to which you wish to convert. |
| 1115 | 1104 | ||
| 1116 | @vindex locale-coding-system | 1105 | @node Terminal Coding |
| 1117 | @cindex decoding non-@acronym{ASCII} keyboard input on X | 1106 | @section Coding Systems for Terminal I/O |
| 1118 | The variable @code{locale-coding-system} specifies a coding system | 1107 | |
| 1119 | to use when encoding and decoding system strings such as system error | 1108 | @table @kbd |
| 1120 | messages and @code{format-time-string} formats and time stamps. That | 1109 | @item C-x @key{RET} k @var{coding} @key{RET} |
| 1121 | coding system is also used for decoding non-@acronym{ASCII} keyboard input on X | 1110 | Use coding system @var{coding} for keyboard input. |
| 1122 | Window systems. You should choose a coding system that is compatible | 1111 | |
| 1123 | with the underlying system's text representation, which is normally | 1112 | @item C-x @key{RET} t @var{coding} @key{RET} |
| 1124 | specified by one of the environment variables @env{LC_ALL}, | 1113 | Use coding system @var{coding} for terminal output. |
| 1125 | @env{LC_CTYPE}, and @env{LANG}. (The first one, in the order | 1114 | @end table |
| 1126 | specified above, whose value is nonempty is the one that determines | 1115 | |
| 1127 | the text representation.) | 1116 | @kindex C-x RET t |
| 1117 | @findex set-terminal-coding-system | ||
| 1118 | The command @kbd{C-x @key{RET} t} (@code{set-terminal-coding-system}) | ||
| 1119 | specifies the coding system for terminal output. If you specify a | ||
| 1120 | character code for terminal output, all characters output to the | ||
| 1121 | terminal are translated into that coding system. | ||
| 1122 | |||
| 1123 | This feature is useful for certain character-only terminals built to | ||
| 1124 | support specific languages or character sets---for example, European | ||
| 1125 | terminals that support one of the ISO Latin character sets. You need to | ||
| 1126 | specify the terminal coding system when using multibyte text, so that | ||
| 1127 | Emacs knows which characters the terminal can actually handle. | ||
| 1128 | |||
| 1129 | By default, output to the terminal is not translated at all, unless | ||
| 1130 | Emacs can deduce the proper coding system from your terminal type or | ||
| 1131 | your locale specification (@pxref{Language Environments}). | ||
| 1132 | |||
| 1133 | @kindex C-x RET k | ||
| 1134 | @findex set-keyboard-coding-system | ||
| 1135 | @vindex keyboard-coding-system | ||
| 1136 | The command @kbd{C-x @key{RET} k} (@code{set-keyboard-coding-system}) | ||
| 1137 | or the variable @code{keyboard-coding-system} specifies the coding | ||
| 1138 | system for keyboard input. Character-code translation of keyboard | ||
| 1139 | input is useful for terminals with keys that send non-@acronym{ASCII} | ||
| 1140 | graphic characters---for example, some terminals designed for ISO | ||
| 1141 | Latin-1 or subsets of it. | ||
| 1142 | |||
| 1143 | By default, keyboard input is translated based on your system locale | ||
| 1144 | setting. If your terminal does not really support the encoding | ||
| 1145 | implied by your locale (for example, if you find it inserts a | ||
| 1146 | non-@acronym{ASCII} character if you type @kbd{M-i}), you will need to set | ||
| 1147 | @code{keyboard-coding-system} to @code{nil} to turn off encoding. | ||
| 1148 | You can do this by putting | ||
| 1149 | |||
| 1150 | @lisp | ||
| 1151 | (set-keyboard-coding-system nil) | ||
| 1152 | @end lisp | ||
| 1153 | |||
| 1154 | @noindent | ||
| 1155 | in your @file{~/.emacs} file. | ||
| 1156 | |||
| 1157 | There is a similarity between using a coding system translation for | ||
| 1158 | keyboard input, and using an input method: both define sequences of | ||
| 1159 | keyboard input that translate into single characters. However, input | ||
| 1160 | methods are designed to be convenient for interactive use by humans, and | ||
| 1161 | the sequences that are translated are typically sequences of @acronym{ASCII} | ||
| 1162 | printing characters. Coding systems typically translate sequences of | ||
| 1163 | non-graphic characters. | ||
| 1128 | 1164 | ||
| 1129 | @node Fontsets | 1165 | @node Fontsets |
| 1130 | @section Fontsets | 1166 | @section Fontsets |
| 1131 | @cindex fontsets | 1167 | @cindex fontsets |
| 1132 | 1168 | ||
| 1133 | A font for X typically defines shapes for a single alphabet or script. | 1169 | A font for X Windows typically defines shapes for a single alphabet |
| 1134 | Therefore, displaying the entire range of scripts that Emacs supports | 1170 | or script. Therefore, displaying the entire range of scripts that |
| 1135 | requires a collection of many fonts. In Emacs, such a collection is | 1171 | Emacs supports requires a collection of many fonts. In Emacs, such a |
| 1136 | called a @dfn{fontset}. A fontset is defined by a list of fonts, each | 1172 | collection is called a @dfn{fontset}. A fontset is defined by a list |
| 1137 | assigned to handle a range of character codes. | 1173 | of fonts, each assigned to handle a range of character codes. |
| 1138 | 1174 | ||
| 1139 | Each fontset has a name, like a font. The available X fonts are | 1175 | Each fontset has a name, like a font. The available X fonts are |
| 1140 | defined by the X server; fontsets, however, are defined within Emacs | 1176 | defined by the X server; fontsets, however, are defined within Emacs |
| @@ -1148,11 +1184,11 @@ additional font support.} | |||
| 1148 | 1184 | ||
| 1149 | Emacs creates two fontsets automatically: the @dfn{standard fontset} | 1185 | Emacs creates two fontsets automatically: the @dfn{standard fontset} |
| 1150 | and the @dfn{startup fontset}. The standard fontset is most likely to | 1186 | and the @dfn{startup fontset}. The standard fontset is most likely to |
| 1151 | have fonts for a wide variety of non-@acronym{ASCII} characters; however, this is | 1187 | have fonts for a wide variety of non-@acronym{ASCII} characters; |
| 1152 | not the default for Emacs to use. (By default, Emacs tries to find a | 1188 | however, this is not the default for Emacs to use. (By default, Emacs |
| 1153 | font that has bold and italic variants.) You can specify use of the | 1189 | tries to find a font that has bold and italic variants.) You can |
| 1154 | standard fontset with the @samp{-fn} option, or with the @samp{Font} X | 1190 | specify use of the standard fontset with the @samp{-fn} option, or |
| 1155 | resource (@pxref{Font X}). For example, | 1191 | with the @samp{Font} X resource (@pxref{Font X}). For example, |
| 1156 | 1192 | ||
| 1157 | @example | 1193 | @example |
| 1158 | emacs -fn fontset-standard | 1194 | emacs -fn fontset-standard |
| @@ -1295,13 +1331,13 @@ call this function explicitly to create a fontset. | |||
| 1295 | @section Undisplayable Characters | 1331 | @section Undisplayable Characters |
| 1296 | 1332 | ||
| 1297 | There may be a some non-@acronym{ASCII} characters that your terminal cannot | 1333 | There may be a some non-@acronym{ASCII} characters that your terminal cannot |
| 1298 | display. Most non-windowing terminals support just a single character | 1334 | display. Most text-only terminals support just a single character |
| 1299 | set (use the variable @code{default-terminal-coding-system} | 1335 | set (use the variable @code{default-terminal-coding-system} |
| 1300 | (@pxref{Specify Coding}) to tell Emacs which one); characters which | 1336 | (@pxref{Terminal Coding}) to tell Emacs which one); characters which |
| 1301 | can't be encoded in that coding system are displayed as @samp{?} by | 1337 | can't be encoded in that coding system are displayed as @samp{?} by |
| 1302 | default. | 1338 | default. |
| 1303 | 1339 | ||
| 1304 | Windowing terminals can display a broader range of characters, but | 1340 | Graphical displays can display a broader range of characters, but |
| 1305 | you may not have fonts installed for all of them; characters that have | 1341 | you may not have fonts installed for all of them; characters that have |
| 1306 | no font appear as a hollow box. | 1342 | no font appear as a hollow box. |
| 1307 | 1343 | ||
| @@ -1335,8 +1371,8 @@ such as @samp{Latin-@var{n}}. | |||
| 1335 | 1371 | ||
| 1336 | For more information about unibyte operation, see @ref{Enabling | 1372 | For more information about unibyte operation, see @ref{Enabling |
| 1337 | Multibyte}. Note particularly that you probably want to ensure that | 1373 | Multibyte}. Note particularly that you probably want to ensure that |
| 1338 | your initialization files are read as unibyte if they contain non-@acronym{ASCII} | 1374 | your initialization files are read as unibyte if they contain |
| 1339 | characters. | 1375 | non-@acronym{ASCII} characters. |
| 1340 | 1376 | ||
| 1341 | @vindex unibyte-display-via-language-environment | 1377 | @vindex unibyte-display-via-language-environment |
| 1342 | Emacs can also display those characters, provided the terminal or font | 1378 | Emacs can also display those characters, provided the terminal or font |
| @@ -1377,11 +1413,11 @@ If your keyboard can generate character codes 128 (decimal) and up, | |||
| 1377 | representing non-@acronym{ASCII} characters, you can type those character codes | 1413 | representing non-@acronym{ASCII} characters, you can type those character codes |
| 1378 | directly. | 1414 | directly. |
| 1379 | 1415 | ||
| 1380 | On a window system, you should not need to do anything special to use | 1416 | On a graphical display, you should not need to do anything special to use |
| 1381 | these keys; they should simply work. On a text-only terminal, you | 1417 | these keys; they should simply work. On a text-only terminal, you |
| 1382 | should use the command @code{M-x set-keyboard-coding-system} or the | 1418 | should use the command @code{M-x set-keyboard-coding-system} or the |
| 1383 | variable @code{keyboard-coding-system} to specify which coding system | 1419 | variable @code{keyboard-coding-system} to specify which coding system |
| 1384 | your keyboard uses (@pxref{Specify Coding}). Enabling this feature | 1420 | your keyboard uses (@pxref{Terminal Coding}). Enabling this feature |
| 1385 | will probably require you to use @kbd{ESC} to type Meta characters; | 1421 | will probably require you to use @kbd{ESC} to type Meta characters; |
| 1386 | however, on a console terminal or in @code{xterm}, you can arrange for | 1422 | however, on a console terminal or in @code{xterm}, you can arrange for |
| 1387 | Meta to be converted to @kbd{ESC} and still be able type 8-bit | 1423 | Meta to be converted to @kbd{ESC} and still be able type 8-bit |
| @@ -1417,11 +1453,11 @@ Use @kbd{C-x 8 C-h} to list all the available @kbd{C-x 8} translations. | |||
| 1417 | Emacs groups all supported characters into disjoint @dfn{charsets}. | 1453 | Emacs groups all supported characters into disjoint @dfn{charsets}. |
| 1418 | Each character code belongs to one and only one charset. For | 1454 | Each character code belongs to one and only one charset. For |
| 1419 | historical reasons, Emacs typically divides an 8-bit character code | 1455 | historical reasons, Emacs typically divides an 8-bit character code |
| 1420 | for an extended version of @acronym{ASCII} into two charsets: @acronym{ASCII}, which | 1456 | for an extended version of @acronym{ASCII} into two charsets: |
| 1421 | covers the codes 0 through 127, plus another charset which covers the | 1457 | @acronym{ASCII}, which covers the codes 0 through 127, plus another |
| 1422 | ``right-hand part'' (the codes 128 and up). For instance, the | 1458 | charset which covers the ``right-hand part'' (the codes 128 and up). |
| 1423 | characters of Latin-1 include the Emacs charset @code{ascii} plus the | 1459 | For instance, the characters of Latin-1 include the Emacs charset |
| 1424 | Emacs charset @code{latin-iso8859-1}. | 1460 | @code{ascii} plus the Emacs charset @code{latin-iso8859-1}. |
| 1425 | 1461 | ||
| 1426 | Emacs characters belonging to different charsets may look the same, | 1462 | Emacs characters belonging to different charsets may look the same, |
| 1427 | but they are still different characters. For example, the letter | 1463 | but they are still different characters. For example, the letter |
diff --git a/man/windows.texi b/man/windows.texi index ecd13de7286..53cef3d3cbc 100644 --- a/man/windows.texi +++ b/man/windows.texi | |||
| @@ -29,24 +29,24 @@ one frame. | |||
| 29 | 29 | ||
| 30 | Each Emacs window displays one Emacs buffer at any time. A single | 30 | Each Emacs window displays one Emacs buffer at any time. A single |
| 31 | buffer may appear in more than one window; if it does, any changes in | 31 | buffer may appear in more than one window; if it does, any changes in |
| 32 | its text are displayed in all the windows where it appears. But the | 32 | its text are displayed in all the windows where it appears. But these |
| 33 | windows showing the same buffer can show different parts of it, because | 33 | windows can show different parts of the buffer, because each window |
| 34 | each window has its own value of point. | 34 | has its own value of point. |
| 35 | 35 | ||
| 36 | @cindex selected window | 36 | @cindex selected window |
| 37 | At any time, one of the windows is the @dfn{selected window}; the | 37 | At any time, one Emacs window is the @dfn{selected window}; the |
| 38 | buffer this window is displaying is the current buffer. The terminal's | 38 | buffer this window is displaying is the current buffer. The terminal's |
| 39 | cursor shows the location of point in this window. Each other window | 39 | cursor shows the location of point in this window. Each other window |
| 40 | has a location of point as well. On text-only terminals, there is no | 40 | has a location of point as well. On text-only terminals, there is no |
| 41 | way to show where those locations are, since the terminal has only one | 41 | way to show where those locations are, since the terminal has only one |
| 42 | cursor. If you are using a window system, the location of point in a | 42 | cursor. On a graphical display, the location of point in a |
| 43 | non-selected window is indicated by a hollow box. The cursor in the | 43 | non-selected window is indicated by a hollow box; the cursor in the |
| 44 | selected window is blinking or solid. | 44 | selected window is blinking or solid. |
| 45 | 45 | ||
| 46 | Commands to move point affect the value of point for the selected Emacs | 46 | Commands to move point affect the value of point for the selected Emacs |
| 47 | window only. They do not change the value of point in any other Emacs | 47 | window only. They do not change the value of point in other Emacs |
| 48 | window, even one showing the same buffer. The same is true for commands | 48 | windows, even those showing the same buffer. The same is true for commands |
| 49 | such as @kbd{C-x b} to change the current buffer in the selected window; | 49 | such as @kbd{C-x b} to switch buffers in the selected window; |
| 50 | they do not affect other windows at all. However, there are other commands | 50 | they do not affect other windows at all. However, there are other commands |
| 51 | such as @kbd{C-x 4 b} that select a different window and switch buffers in | 51 | such as @kbd{C-x 4 b} that select a different window and switch buffers in |
| 52 | it. Also, all commands that display information in a window, including | 52 | it. Also, all commands that display information in a window, including |
| @@ -129,8 +129,7 @@ inevitable. If this variable is @code{nil}, then @kbd{C-x 2} tries to | |||
| 129 | avoid scrolling the text currently visible on the screen, by putting | 129 | avoid scrolling the text currently visible on the screen, by putting |
| 130 | point in each window at a position already visible in the window. It | 130 | point in each window at a position already visible in the window. It |
| 131 | also selects whichever window contains the screen line that the cursor | 131 | also selects whichever window contains the screen line that the cursor |
| 132 | was previously on. Some users prefer the latter mode on slow | 132 | was previously on. Some users prefer that mode on slow terminals. |
| 133 | terminals. | ||
| 134 | 133 | ||
| 135 | @node Other Window | 134 | @node Other Window |
| 136 | @section Using Other Windows | 135 | @section Using Other Windows |
| @@ -283,17 +282,6 @@ Shrink this window if its buffer doesn't need so many lines | |||
| 283 | (@code{shrink-window-if-larger-than-buffer}). | 282 | (@code{shrink-window-if-larger-than-buffer}). |
| 284 | @item C-x + | 283 | @item C-x + |
| 285 | Make all windows the same height (@code{balance-windows}). | 284 | Make all windows the same height (@code{balance-windows}). |
| 286 | @item Drag-Mouse-1 | ||
| 287 | Dragging a window's mode line up or down with @kbd{Mouse-1} changes | ||
| 288 | window heights. | ||
| 289 | @item Mouse-2 | ||
| 290 | @kbd{Mouse-2} in a window's mode line deletes all other windows in the frame | ||
| 291 | (@code{mouse-delete-other-windows}). | ||
| 292 | @item Mouse-3 | ||
| 293 | @kbd{Mouse-3} in a window's mode line deletes that window | ||
| 294 | (@code{mouse-delete-window}), unless the frame has only one window, in | ||
| 295 | which case it buries the current buffer instead and switches to another | ||
| 296 | buffer. | ||
| 297 | @end table | 285 | @end table |
| 298 | 286 | ||
| 299 | @kindex C-x 0 | 287 | @kindex C-x 0 |
| @@ -320,19 +308,6 @@ different way; it deletes all the windows except the selected one (and | |||
| 320 | the minibuffer); the selected window expands to use the whole frame | 308 | the minibuffer); the selected window expands to use the whole frame |
| 321 | except for the echo area. | 309 | except for the echo area. |
| 322 | 310 | ||
| 323 | You can also delete a window by clicking on its mode line with | ||
| 324 | @kbd{Mouse-3}, and delete all the windows in a frame except one window | ||
| 325 | by clicking on that window's mode line with @kbd{Mouse-2}. | ||
| 326 | |||
| 327 | You can also adjust window heights and widths with the mouse. If | ||
| 328 | you press @kbd{Mouse-1} on a mode line, you can drag that mode line up | ||
| 329 | or down, changing the heights of the windows above and below it. If | ||
| 330 | you press it on the divider between two consecutive mode lines, you | ||
| 331 | can drag that divider right or left, changing the widths of the | ||
| 332 | windows to either side. Note that changing heights and widths with | ||
| 333 | the mouse never deletes windows, it just refuses to make any window | ||
| 334 | smaller than it can be. | ||
| 335 | |||
| 336 | @kindex C-x ^ | 311 | @kindex C-x ^ |
| 337 | @findex enlarge-window | 312 | @findex enlarge-window |
| 338 | @kindex C-x @} | 313 | @kindex C-x @} |
| @@ -341,7 +316,7 @@ smaller than it can be. | |||
| 341 | @vindex window-min-width | 316 | @vindex window-min-width |
| 342 | To readjust the division of space among vertically adjacent windows, | 317 | To readjust the division of space among vertically adjacent windows, |
| 343 | use @kbd{C-x ^} (@code{enlarge-window}). It makes the currently | 318 | use @kbd{C-x ^} (@code{enlarge-window}). It makes the currently |
| 344 | selected window get one line bigger, or as many lines as is specified | 319 | selected window one line bigger, or as many lines as is specified |
| 345 | with a numeric argument. With a negative argument, it makes the | 320 | with a numeric argument. With a negative argument, it makes the |
| 346 | selected window smaller. @kbd{C-x @}} | 321 | selected window smaller. @kbd{C-x @}} |
| 347 | (@code{enlarge-window-horizontally}) makes the selected window wider by | 322 | (@code{enlarge-window-horizontally}) makes the selected window wider by |
| @@ -349,10 +324,10 @@ the specified number of columns. @kbd{C-x @{} | |||
| 349 | (@code{shrink-window-horizontally}) makes the selected window narrower | 324 | (@code{shrink-window-horizontally}) makes the selected window narrower |
| 350 | by the specified number of columns. | 325 | by the specified number of columns. |
| 351 | 326 | ||
| 352 | When you make a window bigger, the space comes from one of its | 327 | When you make a window bigger, the space comes from its peers. If |
| 353 | neighbors. If this makes any window too small, it is deleted and its | 328 | this makes any window too small, it is deleted and its space is given |
| 354 | space is given to an adjacent window. The minimum size is specified by | 329 | to an adjacent window. The minimum size is specified by the variables |
| 355 | the variables @code{window-min-height} and @code{window-min-width}. | 330 | @code{window-min-height} and @code{window-min-width}. |
| 356 | 331 | ||
| 357 | @kindex C-x - | 332 | @kindex C-x - |
| 358 | @findex shrink-window-if-larger-than-buffer | 333 | @findex shrink-window-if-larger-than-buffer |
| @@ -366,6 +341,9 @@ gives the extra lines to other windows in the frame. | |||
| 366 | You can also use @kbd{C-x +} (@code{balance-windows}) to even out the | 341 | You can also use @kbd{C-x +} (@code{balance-windows}) to even out the |
| 367 | heights of all the windows in the selected frame. | 342 | heights of all the windows in the selected frame. |
| 368 | 343 | ||
| 344 | Mouse clicks on the mode line provide another way to change window | ||
| 345 | heights and to delete windows. @xref{Mode Line Mouse}. | ||
| 346 | |||
| 369 | @node Window Convenience | 347 | @node Window Convenience |
| 370 | @section Window Handling Convenience Features and Customization | 348 | @section Window Handling Convenience Features and Customization |
| 371 | 349 | ||
diff --git a/src/ChangeLog b/src/ChangeLog index cce484a0e3a..dc6a1641ac5 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,19 @@ | |||
| 1 | 2006-02-03 Kim F. Storm <storm@cua.dk> | ||
| 2 | |||
| 3 | * xdisp.c: Cache last merged escape glyph face. | ||
| 4 | (last_escape_glyph_frame, last_escape_glyph_face_id) | ||
| 5 | (last_escape_glyph_merged_face_id): New variables. | ||
| 6 | (get_next_display_element): Use/update them. | ||
| 7 | (redisplay_internal): Reset them before redisplay. | ||
| 8 | |||
| 9 | * xdisp.c (set_iterator_to_next): Optimize 2004-12-13 fix. | ||
| 10 | Only recheck faces after displaying ellipsis. | ||
| 11 | |||
| 12 | 2006-02-02 Kenichi Handa <handa@m17n.org> | ||
| 13 | |||
| 14 | * coding.c (decode_composition_emacs_mule): Fix handling of | ||
| 15 | incorrect format data. | ||
| 16 | |||
| 1 | 2006-01-31 Jan Dj,Ad(Brv <jan.h.d@swipnet.se> | 17 | 2006-01-31 Jan Dj,Ad(Brv <jan.h.d@swipnet.se> |
| 2 | 18 | ||
| 3 | * gtkutil.c (update_frame_tool_bar): Use new tool bar functions | 19 | * gtkutil.c (update_frame_tool_bar): Use new tool bar functions |
diff --git a/src/coding.c b/src/coding.c index 6ec0804353f..f10a10e1e72 100644 --- a/src/coding.c +++ b/src/coding.c | |||
| @@ -1039,7 +1039,7 @@ coding_alloc_by_making_gap (coding, bytes) | |||
| 1039 | make_gap (bytes); | 1039 | make_gap (bytes); |
| 1040 | GAP_SIZE += add; ZV -= add; Z -= add; ZV_BYTE -= add; Z_BYTE -= add; | 1040 | GAP_SIZE += add; ZV -= add; Z -= add; ZV_BYTE -= add; Z_BYTE -= add; |
| 1041 | } | 1041 | } |
| 1042 | else | 1042 | else if (c >= 0x80) |
| 1043 | { | 1043 | { |
| 1044 | Lisp_Object this_buffer; | 1044 | Lisp_Object this_buffer; |
| 1045 | 1045 | ||
| @@ -1308,6 +1308,8 @@ decode_coding_utf_8 (coding) | |||
| 1308 | *charbuf++ = ASCII_BYTE_P (c) ? c : BYTE8_TO_CHAR (c); | 1308 | *charbuf++ = ASCII_BYTE_P (c) ? c : BYTE8_TO_CHAR (c); |
| 1309 | coding->errors++; | 1309 | coding->errors++; |
| 1310 | } | 1310 | } |
| 1311 | else | ||
| 1312 | return 0; | ||
| 1311 | 1313 | ||
| 1312 | no_more_source: | 1314 | no_more_source: |
| 1313 | coding->consumed_char += consumed_chars_base; | 1315 | coding->consumed_char += consumed_chars_base; |
diff --git a/src/xdisp.c b/src/xdisp.c index 8b1b6f59cf2..fb071542925 100644 --- a/src/xdisp.c +++ b/src/xdisp.c | |||
| @@ -5425,6 +5425,10 @@ static int (* get_next_element[NUM_IT_METHODS]) P_ ((struct it *it)) = | |||
| 5425 | display element from the current position of IT. Value is zero if | 5425 | display element from the current position of IT. Value is zero if |
| 5426 | end of buffer (or C string) is reached. */ | 5426 | end of buffer (or C string) is reached. */ |
| 5427 | 5427 | ||
| 5428 | static struct frame *last_escape_glyph_frame = NULL; | ||
| 5429 | static unsigned last_escape_glyph_face_id = (1 << FACE_ID_BITS); | ||
| 5430 | static int last_escape_glyph_merged_face_id = 0; | ||
| 5431 | |||
| 5428 | int | 5432 | int |
| 5429 | get_next_display_element (it) | 5433 | get_next_display_element (it) |
| 5430 | struct it *it; | 5434 | struct it *it; |
| @@ -5536,11 +5540,19 @@ get_next_display_element (it) | |||
| 5536 | face_id = merge_faces (it->f, Qt, lface_id, | 5540 | face_id = merge_faces (it->f, Qt, lface_id, |
| 5537 | it->face_id); | 5541 | it->face_id); |
| 5538 | } | 5542 | } |
| 5543 | else if (it->f == last_escape_glyph_frame | ||
| 5544 | && it->face_id == last_escape_glyph_face_id) | ||
| 5545 | { | ||
| 5546 | face_id = last_escape_glyph_merged_face_id; | ||
| 5547 | } | ||
| 5539 | else | 5548 | else |
| 5540 | { | 5549 | { |
| 5541 | /* Merge the escape-glyph face into the current face. */ | 5550 | /* Merge the escape-glyph face into the current face. */ |
| 5542 | face_id = merge_faces (it->f, Qescape_glyph, 0, | 5551 | face_id = merge_faces (it->f, Qescape_glyph, 0, |
| 5543 | it->face_id); | 5552 | it->face_id); |
| 5553 | last_escape_glyph_frame = it->f; | ||
| 5554 | last_escape_glyph_face_id = it->face_id; | ||
| 5555 | last_escape_glyph_merged_face_id = face_id; | ||
| 5544 | } | 5556 | } |
| 5545 | 5557 | ||
| 5546 | XSETINT (it->ctl_chars[0], g); | 5558 | XSETINT (it->ctl_chars[0], g); |
| @@ -5586,11 +5598,19 @@ get_next_display_element (it) | |||
| 5586 | face_id = merge_faces (it->f, Qt, lface_id, | 5598 | face_id = merge_faces (it->f, Qt, lface_id, |
| 5587 | it->face_id); | 5599 | it->face_id); |
| 5588 | } | 5600 | } |
| 5601 | else if (it->f == last_escape_glyph_frame | ||
| 5602 | && it->face_id == last_escape_glyph_face_id) | ||
| 5603 | { | ||
| 5604 | face_id = last_escape_glyph_merged_face_id; | ||
| 5605 | } | ||
| 5589 | else | 5606 | else |
| 5590 | { | 5607 | { |
| 5591 | /* Merge the escape-glyph face into the current face. */ | 5608 | /* Merge the escape-glyph face into the current face. */ |
| 5592 | face_id = merge_faces (it->f, Qescape_glyph, 0, | 5609 | face_id = merge_faces (it->f, Qescape_glyph, 0, |
| 5593 | it->face_id); | 5610 | it->face_id); |
| 5611 | last_escape_glyph_frame = it->f; | ||
| 5612 | last_escape_glyph_face_id = it->face_id; | ||
| 5613 | last_escape_glyph_merged_face_id = face_id; | ||
| 5594 | } | 5614 | } |
| 5595 | 5615 | ||
| 5596 | /* Handle soft hyphens in the mode where they only get | 5616 | /* Handle soft hyphens in the mode where they only get |
| @@ -5788,6 +5808,8 @@ set_iterator_to_next (it, reseat_p) | |||
| 5788 | 5808 | ||
| 5789 | if (it->dpvec + it->current.dpvec_index == it->dpend) | 5809 | if (it->dpvec + it->current.dpvec_index == it->dpend) |
| 5790 | { | 5810 | { |
| 5811 | int recheck_faces = it->ellipsis_p; | ||
| 5812 | |||
| 5791 | if (it->s) | 5813 | if (it->s) |
| 5792 | it->method = GET_FROM_C_STRING; | 5814 | it->method = GET_FROM_C_STRING; |
| 5793 | else if (STRINGP (it->string)) | 5815 | else if (STRINGP (it->string)) |
| @@ -5810,8 +5832,9 @@ set_iterator_to_next (it, reseat_p) | |||
| 5810 | set_iterator_to_next (it, reseat_p); | 5832 | set_iterator_to_next (it, reseat_p); |
| 5811 | } | 5833 | } |
| 5812 | 5834 | ||
| 5813 | /* Recheck faces after display vector */ | 5835 | /* Maybe recheck faces after display vector */ |
| 5814 | it->stop_charpos = IT_CHARPOS (*it); | 5836 | if (recheck_faces) |
| 5837 | it->stop_charpos = IT_CHARPOS (*it); | ||
| 5815 | } | 5838 | } |
| 5816 | break; | 5839 | break; |
| 5817 | 5840 | ||
| @@ -10651,6 +10674,8 @@ redisplay_internal (preserve_echo_area) | |||
| 10651 | retry: | 10674 | retry: |
| 10652 | pause = 0; | 10675 | pause = 0; |
| 10653 | reconsider_clip_changes (w, current_buffer); | 10676 | reconsider_clip_changes (w, current_buffer); |
| 10677 | last_escape_glyph_frame = NULL; | ||
| 10678 | last_escape_glyph_face_id = (1 << FACE_ID_BITS); | ||
| 10654 | 10679 | ||
| 10655 | /* If new fonts have been loaded that make a glyph matrix adjustment | 10680 | /* If new fonts have been loaded that make a glyph matrix adjustment |
| 10656 | necessary, do it. */ | 10681 | necessary, do it. */ |