diff options
| author | Miles Bader | 2005-06-06 02:39:45 +0000 |
|---|---|---|
| committer | Miles Bader | 2005-06-06 02:39:45 +0000 |
| commit | fdffd346262841cb194225ea0acd8059c57ec2d4 (patch) | |
| tree | d8b3699131f7d1b94bc46c7d8be62af6b8b5ebfe | |
| parent | a5c508fe3a3f456c987283156315d0384d38fe9e (diff) | |
| parent | a9b4333620eb259e974445066a8e64cee0c21d69 (diff) | |
| download | emacs-fdffd346262841cb194225ea0acd8059c57ec2d4.tar.gz emacs-fdffd346262841cb194225ea0acd8059c57ec2d4.zip | |
Revision: miles@gnu.org--gnu-2005/emacs--unicode--0--patch-57
Merge from emacs--cvs-trunk--0
Patches applied:
* emacs--cvs-trunk--0 (patch 324-352)
- Merge from gnus--rel--5.10
- Update from CVS
- etc/emacs-buffer.gdb: Remove RCS keywords
* gnus--rel--5.10 (patch 70-79)
- Update from CVS
- Merge from emacs--cvs-trunk--0
296 files changed, 5877 insertions, 2966 deletions
diff --git a/admin/ChangeLog b/admin/ChangeLog index 03f5e0ed066..9f5b9462a5f 100644 --- a/admin/ChangeLog +++ b/admin/ChangeLog | |||
| @@ -1,3 +1,8 @@ | |||
| 1 | 2005-06-04 Richard M. Stallman <rms@gnu.org> | ||
| 2 | |||
| 3 | * emacs-pretesters: Refer to etc/DEBUG instead of duplicating it. | ||
| 4 | Other cleanups. | ||
| 5 | |||
| 1 | 2005-04-19 Lute Kamstra <lute@gnu.org> | 6 | 2005-04-19 Lute Kamstra <lute@gnu.org> |
| 2 | 7 | ||
| 3 | * make-tarball.txt: Don't commit lisp/loaddefs.el. | 8 | * make-tarball.txt: Don't commit lisp/loaddefs.el. |
diff --git a/admin/emacs-pretesters b/admin/emacs-pretesters index 169c7ee466d..f7b17afd580 100644 --- a/admin/emacs-pretesters +++ b/admin/emacs-pretesters | |||
| @@ -30,13 +30,13 @@ noise into long discussions or even arguments, and that can waste a | |||
| 30 | lot of time. But when you have a reason to ask other pretesters for | 30 | lot of time. But when you have a reason to ask other pretesters for |
| 31 | help, you can do it that way. | 31 | help, you can do it that way. |
| 32 | 32 | ||
| 33 | * It is absolutely vital that you tell me about even the smallest | 33 | * It is absolutely vital that you report even the smallest change or |
| 34 | change or departure from the standard sources and procedure. | 34 | departure from the standard sources and procedure. |
| 35 | 35 | ||
| 36 | Otherwise, you are not testing the same program that I asked you to | 36 | Otherwise, you are not testing the same program that we asked you to |
| 37 | test. Testing a different program is usually of no use whatever. It | 37 | test. Testing a different program is usually of no use whatever. It |
| 38 | can even cause trouble if you fail to tell me that you tested some | 38 | can even cause trouble, if you fail to tell us that you tested some |
| 39 | other program instead of what I am about to release. I might think | 39 | other program instead of what we are about to release. We might think |
| 40 | that Emacs works, when in fact it has not even been tried, and might | 40 | that Emacs works, when in fact it has not even been tried, and might |
| 41 | have a glaring fault. | 41 | have a glaring fault. |
| 42 | 42 | ||
| @@ -46,8 +46,8 @@ site would use it. | |||
| 46 | 46 | ||
| 47 | Actually, it does no harm to test Emacs with such customizations *as | 47 | Actually, it does no harm to test Emacs with such customizations *as |
| 48 | well as* testing it "out of the box". Anything you do that could find | 48 | well as* testing it "out of the box". Anything you do that could find |
| 49 | a bug is useful, as long as you make sure I know exactly what you did. | 49 | a bug is useful, as long as you make sure we know exactly what you |
| 50 | The important point is that testing with local changes is no | 50 | did. The important point is that testing with local changes is no |
| 51 | substitute for testing Emacs exactly as it is distributed. | 51 | substitute for testing Emacs exactly as it is distributed. |
| 52 | 52 | ||
| 53 | * Even changing the compilation options counts as a change in the | 53 | * Even changing the compilation options counts as a change in the |
| @@ -71,10 +71,10 @@ this is effectively changing Emacs. Because the crucial fact about | |||
| 71 | the planned release is that, without changes, it doesn't work on that | 71 | the planned release is that, without changes, it doesn't work on that |
| 72 | machine. | 72 | machine. |
| 73 | 73 | ||
| 74 | To make Emacs work on that machine, I would need to install new | 74 | To make Emacs work on that machine, we would need to install new |
| 75 | configuration files. That is not out of the question, since it is | 75 | configuration files. That is not out of the question, since it is |
| 76 | safe--it certainly won't break any other machines that already work. | 76 | safe--it certainly won't break any other machines that already work. |
| 77 | But you will have to rush me the legal papers to give the FSF | 77 | But you will have to rush in the legal papers to give the FSF |
| 78 | permission to use such a large piece of text. | 78 | permission to use such a large piece of text. |
| 79 | 79 | ||
| 80 | * Look in the etc/MACHINES file. | 80 | * Look in the etc/MACHINES file. |
| @@ -92,25 +92,25 @@ recommendations also, for the same reason. | |||
| 92 | * Send your problem reports to emacs-pretest-bug@gnu.org, not | 92 | * Send your problem reports to emacs-pretest-bug@gnu.org, not |
| 93 | bug-gnu-emacs. | 93 | bug-gnu-emacs. |
| 94 | 94 | ||
| 95 | Sometimes I won't know what to do about a system-dependent issue, and | 95 | Sometimes we won't know what to do about a system-dependent issue, and |
| 96 | I may need people to tell me what happens if you try a certain thing | 96 | we may need people to say what happens if you try a certain thing on a |
| 97 | on a certain system. When this happens, I'll send out a query. | 97 | certain system. When this happens, we'll send out a query. |
| 98 | 98 | ||
| 99 | * Don't delay sending information. | 99 | * Don't delay sending information. |
| 100 | 100 | ||
| 101 | When you test on a system and encounter no problems, please tell me | 101 | When you test on a system and encounter no problems, please report it |
| 102 | about it right away. That way, I will know that someone has tested | 102 | right away. That way, we will know that someone has tested Emacs on |
| 103 | Emacs on that kind of system. | 103 | that kind of system. |
| 104 | 104 | ||
| 105 | Please don't wait for several days "to see if it really works before | 105 | Please don't wait for several days "to see if it really works before |
| 106 | you say anything." Tell me right away that Emacs seems basically to | 106 | you say anything." Tell us right away that Emacs seems basically to |
| 107 | work; then, if you notice a problem a few days later, tell me | 107 | work; then, if you notice a problem a few days later, tell us |
| 108 | immediately about that when you see it. | 108 | immediately about that when you see it. |
| 109 | 109 | ||
| 110 | It is okay if you double check things before reporting a problem, such | 110 | It is okay if you double check things before reporting a problem, such |
| 111 | as to see if you can easily fix it. But don't wait very long. A good | 111 | as to see if you can easily fix it. But don't wait very long. A good |
| 112 | rule to use in pretesting is always to tell me about every problem on | 112 | rule to use in pretesting is always to report every problem on the |
| 113 | the same day you encounter it, even if that means you can't find a | 113 | same day you encounter it, even if that means you can't find a |
| 114 | solution before you report the problem. | 114 | solution before you report the problem. |
| 115 | 115 | ||
| 116 | I'd much rather hear about a problem today and a solution tomorrow | 116 | I'd much rather hear about a problem today and a solution tomorrow |
| @@ -123,20 +123,22 @@ else, then it will be necessary for anyone who wants to investigate | |||
| 123 | the bug to find the other message. This may be difficult, it is | 123 | the bug to find the other message. This may be difficult, it is |
| 124 | probably time-consuming. | 124 | probably time-consuming. |
| 125 | 125 | ||
| 126 | To help me save time, simply copy the relevant parts of any previous | 126 | To help save our time, simply copy the relevant parts of any previous |
| 127 | messages into your own bug report. | 127 | messages into your own bug report. |
| 128 | 128 | ||
| 129 | In particular, if I ask you for more information because a bug report | 129 | In particular, if we ask you for more information because a bug report |
| 130 | was incomplete, it is best to send me the *entire* collection of | 130 | was incomplete, it is best to send me the *entire* collection of |
| 131 | relevant information, all together. If you send just the additional | 131 | relevant information, all together. If you send just the additional |
| 132 | information, that makes me do extra work. There is even a risk that | 132 | information, that makes extra work for us. There is even a risk that |
| 133 | I won't remember what question you are sending me the answer to. | 133 | we won't remember what question you are sending the answer to. |
| 134 | 134 | ||
| 135 | * When you encounter a bug that manifests itself as a Lisp error, | 135 | * When you encounter a bug that manifests itself as a Lisp error, |
| 136 | try setting debug-on-error to t and making the bug happen again. | 136 | try setting debug-on-error to t and making the bug happen again. |
| 137 | Then you will get a Lisp backtrace. Including that in your bug report | 137 | Then you will get a Lisp backtrace. Including that in your bug report |
| 138 | is very useful. | 138 | is very useful. |
| 139 | 139 | ||
| 140 | * For advice on debugging, see etc/DEBUG. | ||
| 141 | |||
| 140 | * Debugging optimized code is possible, if you compile with GCC, but | 142 | * Debugging optimized code is possible, if you compile with GCC, but |
| 141 | in some cases the optimized code can be confusing. If you are not | 143 | in some cases the optimized code can be confusing. If you are not |
| 142 | accustomed to that, recompile Emacs without -O. One way to do this is | 144 | accustomed to that, recompile Emacs without -O. One way to do this is |
| @@ -144,193 +146,6 @@ accustomed to that, recompile Emacs without -O. One way to do this is | |||
| 144 | make clean | 146 | make clean |
| 145 | make CFLAGS=-g | 147 | make CFLAGS=-g |
| 146 | 148 | ||
| 147 | * If you use X windows, it is a good idea to run Emacs under GDB (or | ||
| 148 | some other suitable debugger) *all the time*, at least while | ||
| 149 | pretesting. | ||
| 150 | |||
| 151 | Then, when Emacs crashes, you will be able to debug the live process, | ||
| 152 | not just a core dump. The `pr' command defined in src/.gdbinit is very | ||
| 153 | useful in this case for examining Lisp_Object values as they would | ||
| 154 | appear in Lisp. | ||
| 155 | |||
| 156 | If you can't use `pr' because Emacs has got a fault already, or | ||
| 157 | because you have only a core dump, you can use `xtype' to look at the | ||
| 158 | type of a value, and then choose one of the other commands `xsymbol', | ||
| 159 | `xstring', `xcons', `xvector' and so on to examine the contents. | ||
| 160 | |||
| 161 | I myself *always* run Emacs under GDB so that I can debug conveniently | ||
| 162 | if the occasion arises. | ||
| 163 | |||
| 164 | * To get Lisp-level backtrace information within GDB, | ||
| 165 | look for stack frames that call Ffuncall. Select them one by one in GDB | ||
| 166 | and type this: | ||
| 167 | |||
| 168 | p *args | ||
| 169 | pr | ||
| 170 | |||
| 171 | This will print the name of the Lisp function called by that level | ||
| 172 | of function calling. | ||
| 173 | |||
| 174 | By printing the remaining elements of args, you can see the argument | ||
| 175 | values. Here's how to print the first argument: | ||
| 176 | |||
| 177 | p args[1] | ||
| 178 | pr | ||
| 179 | |||
| 180 | If you do not have a live process, you can use xtype and the other | ||
| 181 | x... commands such as xsymbol to get such information, albeit less | ||
| 182 | conveniently. | ||
| 183 | |||
| 184 | * Even with a live process, these x... commands are useful for | ||
| 185 | examining the fields in a buffer, window, process, frame or marker. | ||
| 186 | Here's an example using concepts explained in the node "Value History" | ||
| 187 | of the GDB manual to print the variable frame from this line in | ||
| 188 | xmenu.c: | ||
| 189 | |||
| 190 | buf.frame_or_window = Fcons (frame, prefix); | ||
| 191 | |||
| 192 | First, use these commands: | ||
| 193 | |||
| 194 | cd src | ||
| 195 | gdb emacs | ||
| 196 | b xmenu.c:1209 | ||
| 197 | r -q | ||
| 198 | |||
| 199 | Then type C-x 5 2 to create a new frame, and it hits the breakpoint: | ||
| 200 | |||
| 201 | (gdb) p frame | ||
| 202 | $1 = 1077872640 | ||
| 203 | (gdb) xtype | ||
| 204 | Lisp_Vectorlike | ||
| 205 | PVEC_FRAME | ||
| 206 | (gdb) xframe | ||
| 207 | $2 = (struct frame *) 0x3f0800 | ||
| 208 | (gdb) p *$ | ||
| 209 | $3 = { | ||
| 210 | size = 536871989, | ||
| 211 | next = 0x366240, | ||
| 212 | name = 809661752, | ||
| 213 | [...] | ||
| 214 | } | ||
| 215 | (gdb) p $3->name | ||
| 216 | $4 = 809661752 | ||
| 217 | |||
| 218 | Now we can use `pr' to print the name of the frame: | ||
| 219 | |||
| 220 | (gdb) pr | ||
| 221 | "emacs@steenrod.math.nwu.edu" | ||
| 222 | |||
| 223 | * The Emacs C code heavily uses macros defined in lisp.h. So suppose | ||
| 224 | we want the address of the l-value expression near the bottom of | ||
| 225 | `kbd_buffer_store_event' from keyboard.c: | ||
| 226 | |||
| 227 | XVECTOR (kbd_buffer_frame_or_window)->contents[kbd_store_ptr | ||
| 228 | - kbd_buffer] | ||
| 229 | = event->frame_or_window); | ||
| 230 | |||
| 231 | XVECTOR is a macro, and therefore GDB does not know about it. | ||
| 232 | GDB cannot evaluate p XVECTOR (kbd_buffer_frame_or_window). | ||
| 233 | |||
| 234 | However, you can use the xvector command in GDB to get the same | ||
| 235 | result. Here is how: | ||
| 236 | |||
| 237 | (gdb) p kbd_buffer_frame_or_window | ||
| 238 | $1 = 1078005760 | ||
| 239 | (gdb) xvector | ||
| 240 | $2 = (struct Lisp_Vector *) 0x411000 | ||
| 241 | 0 | ||
| 242 | (gdb) p $->contents[kbd_store_ptr - kbd_buffer] | ||
| 243 | $3 = 1077872640 | ||
| 244 | (gdb) p &$ | ||
| 245 | $4 = (int *) 0x411008 | ||
| 246 | |||
| 247 | * Here's a related example of macros and the GDB `define' command. | ||
| 248 | There are many Lisp vectors such as `recent_keys', which contains the | ||
| 249 | last 100 keystrokes. We can print this Lisp vector | ||
| 250 | |||
| 251 | p recent_keys | ||
| 252 | pr | ||
| 253 | |||
| 254 | But this may be inconvenient, since `recent_keys' is much more verbose | ||
| 255 | than `C-h l'. We might want to print only the last 10 elements of | ||
| 256 | this vector. `recent_keys' is updated in keyboard.c by the command | ||
| 257 | |||
| 258 | XVECTOR (recent_keys)->contents[recent_keys_index] = c; | ||
| 259 | |||
| 260 | So we define a GDB command `xvector-elts', so the last 10 keystrokes | ||
| 261 | are printed by | ||
| 262 | |||
| 263 | xvector-elts recent_keys recent_keys_index 10 | ||
| 264 | |||
| 265 | where you can define xvector-elts as follows: | ||
| 266 | |||
| 267 | define xvector-elts | ||
| 268 | set $i = 0 | ||
| 269 | p $arg0 | ||
| 270 | xvector | ||
| 271 | set $foo = $ | ||
| 272 | while $i < $arg2 | ||
| 273 | p $foo->contents[$arg1-($i++)] | ||
| 274 | pr | ||
| 275 | end | ||
| 276 | document xvector-elts | ||
| 277 | Prints a range of elements of a Lisp vector. | ||
| 278 | xvector-elts v n i | ||
| 279 | prints `i' elements of the vector `v' ending at the index `n'. | ||
| 280 | end | ||
| 281 | |||
| 282 | * To debug what happens while preloading and dumping Emacs, | ||
| 283 | do `gdb temacs' and start it with `r -batch -l loadup dump'. | ||
| 284 | |||
| 285 | If temacs actually succeeds when running under GDB in this way, do not | ||
| 286 | try to run the dumped Emacs, because it was dumped with the GDB | ||
| 287 | breakpoints in it. | ||
| 288 | |||
| 289 | * If you encounter X protocol errors, try evaluating (x-synchronize t). | ||
| 290 | That puts Emacs into synchronous mode, where each Xlib call checks for | ||
| 291 | errors before it returns. This mode is much slower, but when you get | ||
| 292 | an error, you will see exactly which call really caused the error. | ||
| 293 | |||
| 294 | * If the symptom of the bug is that Emacs fails to respond, don't | ||
| 295 | assume Emacs is `hung'--it may instead be in an infinite loop. To | ||
| 296 | find out which, make the problem happen under GDB and stop Emacs once | ||
| 297 | it is not responding. (If Emacs is using X Windows directly, you can | ||
| 298 | stop Emacs by typing C-z at the GDB job.) Then try stepping with | ||
| 299 | `step'. If Emacs is hung, the `step' command won't return. If it is | ||
| 300 | looping, `step' will return. | ||
| 301 | |||
| 302 | If this shows Emacs is hung in a system call, stop it again and | ||
| 303 | examine the arguments of the call. In your bug report, state exactly | ||
| 304 | where in the source the system call is, and what the arguments are. | ||
| 305 | |||
| 306 | If Emacs is in an infinite loop, please determine where the loop | ||
| 307 | starts and ends. The easiest way to do this is to use the GDB command | ||
| 308 | `finish'. Each time you use it, Emacs resumes execution until it | ||
| 309 | exits one stack frame. Keep typing `finish' until it doesn't | ||
| 310 | return--that means the infinite loop is in the stack frame which you | ||
| 311 | just tried to finish. | ||
| 312 | |||
| 313 | Stop Emacs again, and use `finish' repeatedly again until you get back | ||
| 314 | to that frame. Then use `next' to step through that frame. By | ||
| 315 | stepping, you will see where the loop starts and ends. Also please | ||
| 316 | examine the data being used in the loop and try to determine why the | ||
| 317 | loop does not exit when it should. Include all of this information in | ||
| 318 | your bug report. | ||
| 319 | |||
| 320 | * If certain operations in Emacs are slower than they used to be, here | ||
| 321 | is some advice for how to find out why. | ||
| 322 | |||
| 323 | Stop Emacs repeatedly during the slow operation, and make a backtrace | ||
| 324 | each time. Compare the backtraces looking for a pattern--a specific | ||
| 325 | function that shows up more often than you'd expect. | ||
| 326 | |||
| 327 | If you don't see a pattern in the C backtraces, get some Lisp | ||
| 328 | backtrace information by looking at Ffuncall frames (see above), and | ||
| 329 | again look for a pattern. | ||
| 330 | |||
| 331 | When using X, you can stop Emacs at any time by typing C-z at GDB. | ||
| 332 | When not using X, you can do this with C-g. | ||
| 333 | |||
| 334 | * Configure tries to figure out what kind of system you have by | 149 | * Configure tries to figure out what kind of system you have by |
| 335 | compiling and linking programs which calls various functions and looks | 150 | compiling and linking programs which calls various functions and looks |
| 336 | at whether that succeeds. The file config.log contains any messages | 151 | at whether that succeeds. The file config.log contains any messages |
| @@ -344,6 +159,9 @@ or more simply, | |||
| 344 | rm config.cache | 159 | rm config.cache |
| 345 | ./configure | 160 | ./configure |
| 346 | 161 | ||
| 162 | * Don't try changing Emacs *in any way* during pretest unless it fails | ||
| 163 | to work unchanged. | ||
| 164 | |||
| 347 | * Always be precise when talking about changes you have made. Show | 165 | * Always be precise when talking about changes you have made. Show |
| 348 | things rather than describing them. Use exact filenames (relative to | 166 | things rather than describing them. Use exact filenames (relative to |
| 349 | the main directory of the distribution), not partial ones. For | 167 | the main directory of the distribution), not partial ones. For |
| @@ -352,27 +170,27 @@ makefile". Instead of saying "I defined the MUMBLE macro", send a | |||
| 352 | diff. | 170 | diff. |
| 353 | 171 | ||
| 354 | * Always use `diff -c' to make diffs. If you don't include context, it | 172 | * Always use `diff -c' to make diffs. If you don't include context, it |
| 355 | may be hard for me to figure out where you propose to make the | 173 | may be hard for us to figure out where you propose to make the |
| 356 | changes. So I might have to ignore your patch. | 174 | changes. So we might ignore your patch. |
| 357 | 175 | ||
| 358 | * When you write a fix, keep in mind that I can't install a change | 176 | * When you write a fix, keep in mind that we can't install a change |
| 359 | that *might* break other systems without the risk that it will fail to | 177 | that *might* break other systems without the risk that it will fail to |
| 360 | work and therefore require an additional cycle of pretesting. | 178 | work and therefore require an additional cycle of pretesting. |
| 361 | 179 | ||
| 362 | People often suggest fixing a problem by changing config.h or | 180 | People often suggest fixing a problem by changing config.h or |
| 363 | src/ymakefile or even src/Makefile to do something special that a | 181 | src/ymakefile or even src/Makefile to do something special that a |
| 364 | particular system needs. Sometimes it is totally obvious that such | 182 | particular system needs. Sometimes it is totally obvious that such |
| 365 | changes would break Emacs for almost all users. I can't possibly make | 183 | changes would break Emacs for almost all users. We can't possibly |
| 366 | a change like that. All I can do is send it back to you and ask you | 184 | make a change like that. All we can do is ask you to find a fix that |
| 367 | to find a fix that is safe to install. | 185 | is safe to install. |
| 368 | 186 | ||
| 369 | Sometimes people send fixes that *might* be an improvement in | 187 | Sometimes people send fixes that *might* be an improvement in |
| 370 | general--but it is hard to be sure of this. I can install such | 188 | general--but it is hard to be sure of this. I can install such |
| 371 | changes some of the time, but not during pretest, when I am trying to | 189 | changes some of the time, but not during pretest, when I am trying to |
| 372 | get a new version to work reliably as quickly as possible. | 190 | get a new version to work reliably as quickly as possible. |
| 373 | 191 | ||
| 374 | The safest changes for me to install are changes to the s- and m- | 192 | The safest changes for us to install are changes to the s- and m- |
| 375 | files. At least I know those can't affect most systems. | 193 | files. At least those can't break other systems. |
| 376 | 194 | ||
| 377 | Another safe kind of change is one that uses a conditional to make | 195 | Another safe kind of change is one that uses a conditional to make |
| 378 | sure it will apply only to a particular kind of system. Ordinarily, | 196 | sure it will apply only to a particular kind of system. Ordinarily, |
| @@ -380,60 +198,20 @@ that is a bad way to solve a problem, and I would want to find a | |||
| 380 | cleaner alternative. But the virtue of safety can make it superior at | 198 | cleaner alternative. But the virtue of safety can make it superior at |
| 381 | pretest time. | 199 | pretest time. |
| 382 | 200 | ||
| 383 | * Don't try changing Emacs *in any way* unless it fails to work unchanged. | 201 | * Don't suggest changes during pretest to add features or make |
| 384 | 202 | something cleaner. Every change risks introducing a bug, so I won't | |
| 385 | * Don't even suggest changes to add features or make something | 203 | install a change during pretest unless it is *necessary*. |
| 386 | cleaner. Every change I install could introduce a bug, so I won't | ||
| 387 | install a change during pretest unless I see it is *necessary*. | ||
| 388 | 204 | ||
| 389 | * If you would like to suggest changes for purposes other than fixing | 205 | * If you would like to suggest changes for purposes other than fixing |
| 390 | user-visible bugs, don't wait till pretest time. Instead, send them | 206 | user-visible bugs, don't wait till pretest time. Instead, send them |
| 391 | after I have made a release that proves to be stable. Then I can give | 207 | after we have made a release that proves to be stable. That is the |
| 392 | your suggestions proper consideration. If you send them at pretest | 208 | easiest time to consider such suggestions. If you send them at |
| 393 | time, I will have to defer them till later, and that might mean I | 209 | pretest time, we will have to defer them till later, and that might |
| 394 | forget all about them. | 210 | mean we forget all about them. |
| 395 | 211 | ||
| 396 | * In some cases, if you don't follow these guidelines, your | 212 | * In some cases, if you don't follow these guidelines, your |
| 397 | information might still be useful, but I might have to do more work to | 213 | information might still be useful, but we would have to do more work |
| 398 | make use of it. Unfortunately, I am so far behind in my work that I | 214 | to make use of it. That might cause it to fall by the wayside. |
| 399 | just can't keep up unless you help me to do it efficiently. | ||
| 400 | |||
| 401 | Some suggestions for debugging on MS Windows: | ||
| 402 | |||
| 403 | Marc Fleischeuers, Geoff Voelker and Andrew Innes | ||
| 404 | |||
| 405 | To debug emacs with Microsoft Visual C++, you either start emacs from | ||
| 406 | the debugger or attach the debugger to a running emacs process. To | ||
| 407 | start emacs from the debugger, you can use the file bin/debug.bat. The | ||
| 408 | Microsoft Developer studio will start and under Project, Settings, | ||
| 409 | Debug, General you can set the command-line arguments and emacs' | ||
| 410 | startup directory. Set breakpoints (Edit, Breakpoints) at Fsignal and | ||
| 411 | other functions that you want to examine. Run the program (Build, | ||
| 412 | Start debug). Emacs will start and the debugger will take control as | ||
| 413 | soon as a breakpoint is hit. | ||
| 414 | |||
| 415 | You can also attach the debugger to an already running emacs process. | ||
| 416 | To do this, start up the Microsoft Developer studio and select Build, | ||
| 417 | Start debug, Attach to process. Choose the emacs process from the | ||
| 418 | list. Send a break to the running process (Debug, Break) and you will | ||
| 419 | find that execution is halted somewhere in user32.dll. Open the stack | ||
| 420 | trace window and go up the stack to w32_msg_pump. Now you can set | ||
| 421 | breakpoints in emacs (Edit, Breakpoints). Continue the running emacs | ||
| 422 | process (Debug, Step out) and control will return to emacs, until a | ||
| 423 | breakpoint is hit. | ||
| 424 | |||
| 425 | To examine the contents of a lisp variable, you can use the function | ||
| 426 | 'debug_print'. Right-click on a variable, select QuickWatch, and | ||
| 427 | place 'debug_print(' and ')' around the expression. Press | ||
| 428 | 'Recalculate' and the output is sent to the 'Debug' pane in the Output | ||
| 429 | window. If emacs was started from the debugger, a console window was | ||
| 430 | opened at emacs' startup; this console window also shows the output of | ||
| 431 | 'debug_print'. It is also possible to keep appropriately masked and | ||
| 432 | typecast lisp symbols in the Watch window, this is more convenient | ||
| 433 | when steeping though the code. For instance, on entering | ||
| 434 | apply_lambda, you can watch (struct Lisp_Symbol *) (0xfffffff & | ||
| 435 | args[0]). | ||
| 436 | |||
| 437 | 215 | ||
| 438 | Local Variables: | 216 | Local Variables: |
| 439 | mode: text | 217 | mode: text |
diff --git a/etc/ChangeLog b/etc/ChangeLog index 0efca03ac29..2a21b596300 100644 --- a/etc/ChangeLog +++ b/etc/ChangeLog | |||
| @@ -1,3 +1,20 @@ | |||
| 1 | 2005-05-30 Miles Bader <miles@gnu.org> | ||
| 2 | |||
| 3 | * emacs-buffer.gdb: Remove RCS keywords. | ||
| 4 | |||
| 5 | 2005-05-30 Noah Friedman <friedman@splode.com> | ||
| 6 | |||
| 7 | * emacs-buffer.gdb: New file. | ||
| 8 | * NEWS: Mention it. | ||
| 9 | |||
| 10 | 2005-05-28 Richard M. Stallman <rms@gnu.org> | ||
| 11 | |||
| 12 | * TUTORIAL.fr: Change NBSP to space. | ||
| 13 | |||
| 14 | 2005-05-28 Bill Wohler <wohler@newt.com> | ||
| 15 | |||
| 16 | * NEWS, MH-E-NEWS: Upgraded to MH-E version 7.84. | ||
| 17 | |||
| 1 | 2005-05-19 Nick Roberts <nickrob@snap.net.nz> | 18 | 2005-05-19 Nick Roberts <nickrob@snap.net.nz> |
| 2 | 19 | ||
| 3 | * TODO: post-command-idle-hook has gone. | 20 | * TODO: post-command-idle-hook has gone. |
diff --git a/etc/MH-E-NEWS b/etc/MH-E-NEWS index 25f649b5434..e5b408c8785 100644 --- a/etc/MH-E-NEWS +++ b/etc/MH-E-NEWS | |||
| @@ -1,16 +1,94 @@ | |||
| 1 | * COPYRIGHT | 1 | * COPYRIGHT |
| 2 | 2 | ||
| 3 | Copyright (C) 2003, 2004 Free Software Foundation, Inc. | 3 | Copyright (C) 2003, 2004, 2005 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.84 | ||
| 10 | |||
| 11 | Version 7.84 contains no user-visible changes. This version | ||
| 12 | incorporates changes made in CVS Emacs such as the removal of some | ||
| 13 | deprecated software. | ||
| 14 | |||
| 15 | * Changes in MH-E 7.83 | ||
| 16 | |||
| 17 | Version 7.83 fixes a handful of bugs, adds colors to buttons for | ||
| 18 | signed or encrypted messages, and contains some documentation changes | ||
| 19 | related to the upcoming release of the manual. Some options were moved | ||
| 20 | to other customization groups as a result. | ||
| 21 | |||
| 22 | While not related to this release, the MH-E mailing lists are now | ||
| 23 | gatewayed at gmane.org (closes SF #979308). | ||
| 24 | |||
| 25 | ** New Variables in MH-E 7.83 | ||
| 26 | |||
| 27 | *** mh-show-pgg-bad-face | ||
| 28 | |||
| 29 | Face used to highlight a bad PGG signature. | ||
| 30 | |||
| 31 | *** mh-show-pgg-good-face | ||
| 32 | |||
| 33 | Face used to highlight a good PGG signature. | ||
| 34 | |||
| 35 | *** mh-show-pgg-unknown-face | ||
| 36 | |||
| 37 | Face used to highlight a PGG signature whose status is unknown. This | ||
| 38 | face is also used for a signature when the signer is untrusted. | ||
| 39 | |||
| 40 | ** Bug Fixes in MH-E 7.83 | ||
| 41 | |||
| 42 | *** Whitespace in pick Expressions | ||
| 43 | |||
| 44 | The "C-u / s RET" command now works. In addition, you can now add | ||
| 45 | whitespace to any of the limiting (/) commands (closes SF #1122655). | ||
| 46 | |||
| 47 | *** auto-mode-alist Updated | ||
| 48 | |||
| 49 | MH-E originally updated auto-mode-alist to set the major mode of | ||
| 50 | drafts. Now that we explicitly set the mode, there is no reason to do | ||
| 51 | this, and this behavior caused problems for people who didn't use MH-E | ||
| 52 | who were editing files that looked like MH message files (closes SF | ||
| 53 | #1032353). | ||
| 54 | |||
| 55 | *** mh-show-unquote-From Fails (read-only buffer) | ||
| 56 | |||
| 57 | MH-E quotes the "From " header field that is inserted by MTAs. | ||
| 58 | However, it was trying to do this in a read-only buffer. This has been | ||
| 59 | fixed (closes SF #1089870). | ||
| 60 | |||
| 61 | *** rmmproc Refile Complains No Such Message | ||
| 62 | |||
| 63 | MH-E would get confused about which folder to delete messages from if | ||
| 64 | you were refiling and deleting messages at the same time. This has | ||
| 65 | been fixed (closes SF #1023959). | ||
| 66 | |||
| 67 | *** ! Doesn't Do Regions | ||
| 68 | |||
| 69 | Now it does (closes SF #1046330). | ||
| 70 | |||
| 71 | *** Swish Fixes | ||
| 72 | |||
| 73 | Items in swish indexes that aren't mail messages are now handled more | ||
| 74 | gracefully. | ||
| 75 | |||
| 76 | *** Spamassassin Fixes | ||
| 77 | |||
| 78 | If you use spamassassin, there was an error when you tried to junk | ||
| 79 | mail if the option mh-junk-background was set. This has been fixed. | ||
| 80 | |||
| 81 | *** Mairix Support | ||
| 82 | |||
| 83 | Indexing now compatible with Mairix version 0.12 and later. | ||
| 84 | |||
| 85 | |||
| 86 | |||
| 9 | * Changes in MH-E 7.82 | 87 | * Changes in MH-E 7.82 |
| 10 | 88 | ||
| 11 | Version 7.82 continues to address the saga surrounding the use of CL | 89 | Version 7.82 continues to address the saga surrounding the use of CL |
| 12 | macros in CVS Emacs and fixes the auto-detection of vanilla MH (SF | 90 | macros in CVS Emacs and fixes the auto-detection of vanilla MH (closes |
| 13 | #1014781). | 91 | SF #1014781). |
| 14 | 92 | ||
| 15 | * Changes in MH-E 7.81 | 93 | * Changes in MH-E 7.81 |
| 16 | 94 | ||
| @@ -23,6 +101,8 @@ of "default" in `mh-identity-handlers' to avoid problems with | |||
| 23 | to ":default". This release also corrects the release numbering; the | 101 | to ":default". This release also corrects the release numbering; the |
| 24 | previous version number was intended to be 7.80. | 102 | previous version number was intended to be 7.80. |
| 25 | 103 | ||
| 104 | |||
| 105 | |||
| 26 | * Changes in MH-E 7.4.80 | 106 | * Changes in MH-E 7.4.80 |
| 27 | 107 | ||
| 28 | Version 7.4.80 now supports GNU mailutils, S/MIME, picons, | 108 | Version 7.4.80 now supports GNU mailutils, S/MIME, picons, |
| @@ -183,9 +183,15 @@ types any more. Add -DUSE_LISP_UNION_TYPE if you want union types. | |||
| 183 | --- | 183 | --- |
| 184 | ** When pure storage overflows while dumping, Emacs now prints how | 184 | ** When pure storage overflows while dumping, Emacs now prints how |
| 185 | much pure storage it will approximately need. | 185 | much pure storage it will approximately need. |
| 186 | |||
| 187 | ** The script etc/emacs-buffer.gdb can be used with gdb to retrieve the | ||
| 188 | contents of buffers from a core dump and save them to files easily, should | ||
| 189 | emacs crash. | ||
| 190 | |||
| 186 | 191 | ||
| 187 | * Startup Changes in Emacs 22.1 | 192 | * Startup Changes in Emacs 22.1 |
| 188 | 193 | ||
| 194 | +++ | ||
| 189 | ** New command line option -Q or --quick. | 195 | ** New command line option -Q or --quick. |
| 190 | This is like using -q --no-site-file, but in addition it also disables | 196 | This is like using -q --no-site-file, but in addition it also disables |
| 191 | the fancy startup screen. | 197 | the fancy startup screen. |
| @@ -419,6 +425,10 @@ understand two new boolean pseudo-frame-parameters `same-frame' and | |||
| 419 | ** The default for the paper size (variable ps-paper-type) is taken | 425 | ** The default for the paper size (variable ps-paper-type) is taken |
| 420 | from the locale. | 426 | from the locale. |
| 421 | 427 | ||
| 428 | ** The command `list-faces-display' now accepts a prefix arg. | ||
| 429 | When passed, the function prompts for a regular expression and lists | ||
| 430 | only faces matching this regexp. | ||
| 431 | |||
| 422 | ** Mark command changes: | 432 | ** Mark command changes: |
| 423 | 433 | ||
| 424 | +++ | 434 | +++ |
| @@ -776,6 +786,7 @@ gives the fraction of the window's width to scroll the window. | |||
| 776 | The variable `automatic-hscrolling' was renamed to | 786 | The variable `automatic-hscrolling' was renamed to |
| 777 | `auto-hscroll-mode'. The old name is still available as an alias. | 787 | `auto-hscroll-mode'. The old name is still available as an alias. |
| 778 | 788 | ||
| 789 | --- | ||
| 779 | *** Moving or scrolling through images (and other lines) taller that | 790 | *** Moving or scrolling through images (and other lines) taller that |
| 780 | the window now works sensibly, by automatically adjusting the window's | 791 | the window now works sensibly, by automatically adjusting the window's |
| 781 | vscroll property. | 792 | vscroll property. |
| @@ -892,8 +903,10 @@ trouble with fontification and/or indentation. | |||
| 892 | +++ | 903 | +++ |
| 893 | *** New standard font-lock face `font-lock-preprocessor-face'. | 904 | *** New standard font-lock face `font-lock-preprocessor-face'. |
| 894 | 905 | ||
| 906 | +++ | ||
| 895 | *** New standard font-lock face `font-lock-comment-delimiter-face'. | 907 | *** New standard font-lock face `font-lock-comment-delimiter-face'. |
| 896 | 908 | ||
| 909 | +++ | ||
| 897 | *** Easy to overlook single character negation can now be font-locked. | 910 | *** Easy to overlook single character negation can now be font-locked. |
| 898 | You can use the new variable `font-lock-negation-char-face' and the face of | 911 | You can use the new variable `font-lock-negation-char-face' and the face of |
| 899 | the same name to customize this. Currently the cc-modes, sh-script-mode, | 912 | the same name to customize this. Currently the cc-modes, sh-script-mode, |
| @@ -1313,6 +1326,7 @@ modes (shell-mode etc) inserts arguments from previous command lines, | |||
| 1313 | like bash's `ESC .' binding. It is bound by default to `C-c .', but | 1326 | like bash's `ESC .' binding. It is bound by default to `C-c .', but |
| 1314 | otherwise behaves quite similarly to the bash version. | 1327 | otherwise behaves quite similarly to the bash version. |
| 1315 | 1328 | ||
| 1329 | +++ | ||
| 1316 | *** `comint-use-prompt-regexp-instead-of-fields' has been renamed | 1330 | *** `comint-use-prompt-regexp-instead-of-fields' has been renamed |
| 1317 | `comint-use-prompt-regexp'. The old name has been kept as an alias, | 1331 | `comint-use-prompt-regexp'. The old name has been kept as an alias, |
| 1318 | but declared obsolete. | 1332 | but declared obsolete. |
| @@ -1358,9 +1372,11 @@ buffer causes automatic display in another window of the corresponding | |||
| 1358 | matches, compilation errors, etc. This minor mode can be toggled with | 1372 | matches, compilation errors, etc. This minor mode can be toggled with |
| 1359 | C-c C-f. | 1373 | C-c C-f. |
| 1360 | 1374 | ||
| 1375 | +++ | ||
| 1361 | *** When the left fringe is displayed, an arrow points to current message in | 1376 | *** When the left fringe is displayed, an arrow points to current message in |
| 1362 | the compilation buffer. | 1377 | the compilation buffer. |
| 1363 | 1378 | ||
| 1379 | +++ | ||
| 1364 | *** The new variable `compilation-context-lines' controls lines of leading | 1380 | *** The new variable `compilation-context-lines' controls lines of leading |
| 1365 | context before the current message. If nil and the left fringe is displayed, | 1381 | context before the current message. If nil and the left fringe is displayed, |
| 1366 | it doesn't scroll the compilation output window. If there is no left fringe, | 1382 | it doesn't scroll the compilation output window. If there is no left fringe, |
| @@ -1687,6 +1703,7 @@ referred to as "soft word wrap" in other text editors. This is | |||
| 1687 | similar to Refill mode, but more reliable. To turn the word wrap | 1703 | similar to Refill mode, but more reliable. To turn the word wrap |
| 1688 | feature off, set `longlines-auto-wrap' to nil. | 1704 | feature off, set `longlines-auto-wrap' to nil. |
| 1689 | 1705 | ||
| 1706 | +++ | ||
| 1690 | ** The printing package is now part of the Emacs distribution. | 1707 | ** The printing package is now part of the Emacs distribution. |
| 1691 | 1708 | ||
| 1692 | If you enable the printing package by including (require 'printing) in | 1709 | If you enable the printing package by including (require 'printing) in |
| @@ -1779,6 +1796,7 @@ This was actually done in Emacs-21.1, and was not documented. | |||
| 1779 | 1796 | ||
| 1780 | * Changes in Specialized Modes and Packages in Emacs 22.1: | 1797 | * Changes in Specialized Modes and Packages in Emacs 22.1: |
| 1781 | 1798 | ||
| 1799 | --- | ||
| 1782 | ** Makefile mode has submodes for automake, gmake, makepp and BSD make. | 1800 | ** Makefile mode has submodes for automake, gmake, makepp and BSD make. |
| 1783 | 1801 | ||
| 1784 | The former two couldn't be differentiated before, and the latter two | 1802 | The former two couldn't be differentiated before, and the latter two |
| @@ -2467,6 +2485,7 @@ old name remains available as alias, but has been marked obsolete. | |||
| 2467 | +++ | 2485 | +++ |
| 2468 | *** Desktop saving is now a minor mode, `desktop-save-mode'. | 2486 | *** Desktop saving is now a minor mode, `desktop-save-mode'. |
| 2469 | 2487 | ||
| 2488 | +++ | ||
| 2470 | *** The variable `desktop-enable' is obsolete. | 2489 | *** The variable `desktop-enable' is obsolete. |
| 2471 | 2490 | ||
| 2472 | Customize `desktop-save-mode' to enable desktop saving. | 2491 | Customize `desktop-save-mode' to enable desktop saving. |
| @@ -2537,6 +2556,7 @@ currently highlighted regions in an inferior Ediff session. If you answer 'n' | |||
| 2537 | then it reverts to the old behavior and asks the user to select regions for | 2556 | then it reverts to the old behavior and asks the user to select regions for |
| 2538 | comparison. | 2557 | comparison. |
| 2539 | 2558 | ||
| 2559 | +++ | ||
| 2540 | *** The new command `ediff-backup' compares a file with its most recent | 2560 | *** The new command `ediff-backup' compares a file with its most recent |
| 2541 | backup using `ediff'. If you specify the name of a backup file, | 2561 | backup using `ediff'. If you specify the name of a backup file, |
| 2542 | `ediff-backup' compares it with the file of which it is a backup. | 2562 | `ediff-backup' compares it with the file of which it is a backup. |
| @@ -2726,7 +2746,7 @@ See the file GNUS-NEWS or the node "Oort Gnus" in the Gnus manual for details. | |||
| 2726 | --- | 2746 | --- |
| 2727 | ** MH-E changes. | 2747 | ** MH-E changes. |
| 2728 | 2748 | ||
| 2729 | Upgraded to MH-E version 7.82. There have been major changes since | 2749 | Upgraded to MH-E version 7.84. There have been major changes since |
| 2730 | version 5.0.2; see MH-E-NEWS for details. | 2750 | version 5.0.2; see MH-E-NEWS for details. |
| 2731 | 2751 | ||
| 2732 | ** Calendar changes: | 2752 | ** Calendar changes: |
| @@ -3207,6 +3227,10 @@ It returns nil if the given Lisp form can't possibly do anything | |||
| 3207 | dangerous; otherwise it returns a reason why the form might be unsafe | 3227 | dangerous; otherwise it returns a reason why the form might be unsafe |
| 3208 | (calls unknown function, alters global variable, etc). | 3228 | (calls unknown function, alters global variable, etc). |
| 3209 | 3229 | ||
| 3230 | *** `list-faces-display' takes an optional argument, REGEXP. | ||
| 3231 | |||
| 3232 | If it is non-nil, the function lists only faces matching this regexp. | ||
| 3233 | |||
| 3210 | ** Lisp code indentation features: | 3234 | ** Lisp code indentation features: |
| 3211 | 3235 | ||
| 3212 | +++ | 3236 | +++ |
| @@ -4846,6 +4870,7 @@ used to add text properties to mode-line elements. | |||
| 4846 | to display the size of the accessible part of the buffer on the mode | 4870 | to display the size of the accessible part of the buffer on the mode |
| 4847 | line. | 4871 | line. |
| 4848 | 4872 | ||
| 4873 | +++ | ||
| 4849 | *** Mouse-face on mode-line (and header-line) is now supported. | 4874 | *** Mouse-face on mode-line (and header-line) is now supported. |
| 4850 | `mode-line-highlight' is the standard face indicating mouse sensitive | 4875 | `mode-line-highlight' is the standard face indicating mouse sensitive |
| 4851 | elements on mode-line (and header-line) like `highlight' face on text | 4876 | elements on mode-line (and header-line) like `highlight' face on text |
diff --git a/etc/TUTORIAL.fr b/etc/TUTORIAL.fr index 38853c608b9..e3e940abd4e 100644 --- a/etc/TUTORIAL.fr +++ b/etc/TUTORIAL.fr | |||
| @@ -746,14 +746,14 @@ système se plantait. Pour vous protéger de ce problème, Emacs écrit | |||
| 746 | périodiquement un fichier de « sauvegarde automatique » pour chaque | 746 | périodiquement un fichier de « sauvegarde automatique » pour chaque |
| 747 | fichier en cours d'édition. Le nom de ce fichier commence et se | 747 | fichier en cours d'édition. Le nom de ce fichier commence et se |
| 748 | termine par un # : si, par exemple, votre fichier s'appelle | 748 | termine par un # : si, par exemple, votre fichier s'appelle |
| 749 | « hello.c », son fichier de sauvegarde automatique s'appellera | 749 | « hello.c », son fichier de sauvegarde automatique s'appellera |
| 750 | « #hello.c# ». Lorsque vous sauvegardez le fichier de la façon | 750 | « #hello.c# ». Lorsque vous sauvegardez le fichier de la façon |
| 751 | habituelle, Emacs détruit son fichier de sauvegarde automatique. | 751 | habituelle, Emacs détruit son fichier de sauvegarde automatique. |
| 752 | 752 | ||
| 753 | Si l'ordinateur se plante, vous pouvez récupérer ce qui a été | 753 | Si l'ordinateur se plante, vous pouvez récupérer ce qui a été |
| 754 | sauvegardé automatiquement en ouvrant normalement le fichier (celui | 754 | sauvegardé automatiquement en ouvrant normalement le fichier (celui |
| 755 | que vous éditiez, pas la sauvegarde automatique), puis en faisant | 755 | que vous éditiez, pas la sauvegarde automatique), puis en faisant |
| 756 | M-x recover file<Entrée>. Lorsqu'Emacs vous demande de confirmer, | 756 | M-x recover file<Entrée>. Lorsqu'Emacs vous demande de confirmer, |
| 757 | tapez yes<Entrée> pour continuer et récupérer ainsi les données | 757 | tapez yes<Entrée> pour continuer et récupérer ainsi les données |
| 758 | sauvées par la sauvegarde automatique. | 758 | sauvées par la sauvegarde automatique. |
| 759 | 759 | ||
| @@ -847,7 +847,7 @@ et que la ligne est trop longue. | |||
| 847 | 847 | ||
| 848 | Vous pouvez activer le mode Auto Fill en faisant M-x auto fill | 848 | Vous pouvez activer le mode Auto Fill en faisant M-x auto fill |
| 849 | mode<Entrée>. Lorsqu'il est activé, vous pouvez le désactiver en | 849 | mode<Entrée>. Lorsqu'il est activé, vous pouvez le désactiver en |
| 850 | faisant à nouveau M-x auto fill mode<Entrée>. Si le mode est | 850 | faisant à nouveau M-x auto fill mode<Entrée>. Si le mode est |
| 851 | désactivé, cette commande l'active et, s'il est activé, elle le | 851 | désactivé, cette commande l'active et, s'il est activé, elle le |
| 852 | désactive : on dit que la commande « fait basculer le mode ». | 852 | désactive : on dit que la commande « fait basculer le mode ». |
| 853 | 853 | ||
| @@ -913,10 +913,10 @@ de mettre fin à la recherche. | |||
| 913 | 913 | ||
| 914 | REMARQUE : Sur certains systèmes, C-s gèlera l'écran et vous ne verrez | 914 | REMARQUE : Sur certains systèmes, C-s gèlera l'écran et vous ne verrez |
| 915 | plus rien se produire dans Emacs. Cela indique qu'une | 915 | plus rien se produire dans Emacs. Cela indique qu'une |
| 916 | « fonctionnalité » du système d'exploitation, appelée « contrôle de | 916 | « fonctionnalité » du système d'exploitation, appelée « contrôle de |
| 917 | flux », a intercepté le C-s et ne lui permet pas de parvenir à | 917 | flux », a intercepté le C-s et ne lui permet pas de parvenir à |
| 918 | Emacs. Pour décoincer l'écran, faites C-q puis consultez la section | 918 | Emacs. Pour décoincer l'écran, faites C-q puis consultez la section |
| 919 | « Spontaneous Entry to Incremental Search » dans le manuel d'Emacs | 919 | « Spontaneous Entry to Incremental Search » dans le manuel d'Emacs |
| 920 | pour avoir des avis sur la gestion de cette « fonctionnalité ». | 920 | pour avoir des avis sur la gestion de cette « fonctionnalité ». |
| 921 | 921 | ||
| 922 | Si vous vous trouvez au milieu d'une recherche incrémentale et que | 922 | Si vous vous trouvez au milieu d'une recherche incrémentale et que |
| @@ -924,7 +924,7 @@ vous tapez <Delback>, vous remarquerez que cela supprime le dernier | |||
| 924 | caractère de la chaîne recherchée et que la recherche reprend à | 924 | caractère de la chaîne recherchée et que la recherche reprend à |
| 925 | l'endroit où elle se trouvait précédemment. Supposons, par exemple, | 925 | l'endroit où elle se trouvait précédemment. Supposons, par exemple, |
| 926 | que vous ayiez tapé « c » pour trouver la première occurrence de | 926 | que vous ayiez tapé « c » pour trouver la première occurrence de |
| 927 | « c ». Si vous tapez maintenant « u », le curseur ira sur la première | 927 | « c ». Si vous tapez maintenant « u », le curseur ira sur la première |
| 928 | occurrence de « cu ». Faites <Delback> : cela supprime le « u » de la | 928 | occurrence de « cu ». Faites <Delback> : cela supprime le « u » de la |
| 929 | chaîne de recherche et le curseur revient à la première occurrence de | 929 | chaîne de recherche et le curseur revient à la première occurrence de |
| 930 | « c ». | 930 | « c ». |
| @@ -1038,7 +1038,7 @@ de possibilités avec Emacs qu'il serait impossible de tout expliquer | |||
| 1038 | ici. Cependant, vous pouvez vouloir en apprendre plus, car il a bien | 1038 | ici. Cependant, vous pouvez vouloir en apprendre plus, car il a bien |
| 1039 | d'autres fonctionnalités utiles. Emacs dispose de commandes pour lire | 1039 | d'autres fonctionnalités utiles. Emacs dispose de commandes pour lire |
| 1040 | la documentation sur ses commandes. Ces commandes d'« aide » | 1040 | la documentation sur ses commandes. Ces commandes d'« aide » |
| 1041 | commencent toutes par le caractère C-h, le « caractère d'aide ». | 1041 | commencent toutes par le caractère C-h, le « caractère d'aide ». |
| 1042 | 1042 | ||
| 1043 | Pour utiliser l'aide, tapez C-h suivi d'un caractère indiquant le type | 1043 | Pour utiliser l'aide, tapez C-h suivi d'un caractère indiquant le type |
| 1044 | d'aide que vous souhaitez. Si vous êtes VRAIMENT perdu, faites C-h ? | 1044 | d'aide que vous souhaitez. Si vous êtes VRAIMENT perdu, faites C-h ? |
| @@ -1113,7 +1113,7 @@ leur correspondent, comme find-file. | |||
| 1113 | C-h i Manuels en ligne (alias Info). Cette commande vous place dans | 1113 | C-h i Manuels en ligne (alias Info). Cette commande vous place dans |
| 1114 | un tampon spéciale, appelé « *info* », où vous pouvez | 1114 | un tampon spéciale, appelé « *info* », où vous pouvez |
| 1115 | lire les manuels en ligne des paquetages installés sur | 1115 | lire les manuels en ligne des paquetages installés sur |
| 1116 | votre système. Faites m emacs <Entrée> pour lire le | 1116 | votre système. Faites m emacs <Entrée> pour lire le |
| 1117 | manuel d'Emacs. Si vous n'avez jamais utilisé Info | 1117 | manuel d'Emacs. Si vous n'avez jamais utilisé Info |
| 1118 | auparavant, tapez ? et Emacs vous fera faire une visite | 1118 | auparavant, tapez ? et Emacs vous fera faire une visite |
| 1119 | guidée des fonctionnalités du mode Info. Lorsque vous | 1119 | guidée des fonctionnalités du mode Info. Lorsque vous |
| @@ -1133,7 +1133,7 @@ frappe, et dired, qui simplifie la manipulation des fichiers. | |||
| 1133 | 1133 | ||
| 1134 | La complétion permet d'éviter les frappes inutiles. Si, par exemple, | 1134 | La complétion permet d'éviter les frappes inutiles. Si, par exemple, |
| 1135 | vous voulez basculer vers le tampon *Messages*, tapez simplement | 1135 | vous voulez basculer vers le tampon *Messages*, tapez simplement |
| 1136 | C-x b *M<Tab> et Emacs complètera le nom du tampon s'il peut le | 1136 | C-x b *M<Tab> et Emacs complètera le nom du tampon s'il peut le |
| 1137 | déterminer à partir de ce que vous avez saisi avant la tabulation. La | 1137 | déterminer à partir de ce que vous avez saisi avant la tabulation. La |
| 1138 | complétion est décrite dans la version Info du manuel Emacs, à la | 1138 | complétion est décrite dans la version Info du manuel Emacs, à la |
| 1139 | rubrique "Completion". | 1139 | rubrique "Completion". |
diff --git a/etc/emacs-buffer.gdb b/etc/emacs-buffer.gdb new file mode 100644 index 00000000000..cd0bf0dd59d --- /dev/null +++ b/etc/emacs-buffer.gdb | |||
| @@ -0,0 +1,270 @@ | |||
| 1 | # emacs-buffer.gdb --- gdb macros for recovering buffers from emacs coredumps | ||
| 2 | |||
| 3 | # Copyright (C) 2005 Free Software Foundation, Inc. | ||
| 4 | |||
| 5 | # Maintainer: Noah Friedman <friedman@splode.com> | ||
| 6 | # Status: tested with Emacs 22 | ||
| 7 | # Created: 2005-04-28 | ||
| 8 | |||
| 9 | # This file is part of GNU Emacs. | ||
| 10 | # | ||
| 11 | # GNU Emacs is free software; you can redistribute it and/or modify | ||
| 12 | # it under the terms of the GNU General Public License as published by | ||
| 13 | # the Free Software Foundation; either version 2, or (at your option) | ||
| 14 | # any later version. | ||
| 15 | # | ||
| 16 | # GNU Emacs is distributed in the hope that it will be useful, | ||
| 17 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 18 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 19 | # GNU General Public License for more details. | ||
| 20 | # | ||
| 21 | # You should have received a copy of the GNU General Public License | ||
| 22 | # along with GNU Emacs; see the file COPYING. If not, write to the | ||
| 23 | # Free Software Foundation, Inc.; 51 Franklin Street, Fifth Floor; | ||
| 24 | # Boston, MA 02110-1301, USA. | ||
| 25 | |||
| 26 | # Commentary: | ||
| 27 | |||
| 28 | # This is a set of gdb macros for recovering the contents of buffers from | ||
| 29 | # an Emacs coredump; they may not always be file-backed or have a recent | ||
| 30 | # autosave. | ||
| 31 | # | ||
| 32 | # The Emacs executable must have debugging symbols for this to work. But | ||
| 33 | # you never strip Emacs, right? Right! | ||
| 34 | # | ||
| 35 | # The main commands of interest are `ybuffer-list', `yfile-buffers', | ||
| 36 | # `ysave-buffer', and `ybuffer-contents'. The `y' prefix avoids any | ||
| 37 | # namespace collisions with emacs/src/.gdbinit. | ||
| 38 | |||
| 39 | # Example usage: | ||
| 40 | # | ||
| 41 | # $ gdb /export/src/emacs/2005-05-02--03-17/src/emacs core.emacs.6.9845 | ||
| 42 | # Current directory is /u/noah/ | ||
| 43 | # GNU gdb (6.1post-1.20040607.43rh) | ||
| 44 | # ... | ||
| 45 | # #0 0x400007a2 in _dl_sysinfo_int80 () from /lib/ld-linux.so.2 | ||
| 46 | # (gdb) source emacs-buffer.gdb | ||
| 47 | # (gdb) ybuffer-list | ||
| 48 | # B# M Size Name Mode File | ||
| 49 | # -- - ---- ---- ---- ---- | ||
| 50 | # 0 * 556 mail to emacs-devel@gnu.org Mail | ||
| 51 | # 1 * 0 *Minibuf-1* Fundamental | ||
| 52 | # 2 145769 ChangeLog Change Log /u/noah/lib/elisp/noahf/ChangeLog | ||
| 53 | # 3 6619 ascii-table.el Elisp /u/noah/lib/elisp/noahf/ascii-table.el | ||
| 54 | # 4 * 48396 *Messages* Fundamental | ||
| 55 | # 5 3191 *Apropos* Apropos | ||
| 56 | # 6 17642 init-21.el Elisp /u/noah/etc/init/emacs/init-21.el | ||
| 57 | # 7 333 cpuid.c C /u/noah/cpuid.c | ||
| 58 | # 8 230 src Dired | ||
| 59 | # 9 218 noah Dired | ||
| 60 | # 10 * 21 *Echo Area 0* Fundamental | ||
| 61 | # 11 * 0 *Echo Area 1* Fundamental | ||
| 62 | # 12 319952 *bbdb data* Text /u/noah/.bbdb | ||
| 63 | # (gdb) ysave-buffer 0 mail.save | ||
| 64 | # [Wrote buffer "mail to emacs-devel@gnu.org" to file mail.save] | ||
| 65 | # (gdb) quit | ||
| 66 | # $ ls -l mail.save | ||
| 67 | # -rw-rw-rw- 1 noah user 556 May 2 04:05 mail.save | ||
| 68 | # $ | ||
| 69 | |||
| 70 | # Code: | ||
| 71 | |||
| 72 | # Force loading of symbols, enough to give us gdb_valbits etc. | ||
| 73 | set main | ||
| 74 | |||
| 75 | # When nonzero, display some extra diagnostics in various commands | ||
| 76 | set $yverbose = 1 | ||
| 77 | set $yfile_buffers_only = 0 | ||
| 78 | |||
| 79 | set $tagmask = (((long)1 << gdb_gctypebits) - 1) | ||
| 80 | set $valmask = gdb_use_lsb ? ~($tagmask) : ((long)1 << gdb_valbits) - 1 | ||
| 81 | |||
| 82 | define ygetptr | ||
| 83 | set $ptr = $arg0 | ||
| 84 | set $ptr = (gdb_use_union ? $ptr.u.val : $ptr & $valmask) | gdb_data_seg_bits | ||
| 85 | end | ||
| 86 | |||
| 87 | define ybuffer-list | ||
| 88 | set $files_only = $yfile_buffers_only | ||
| 89 | set $yfile_buffers_only = 0 | ||
| 90 | |||
| 91 | if $yverbose | ||
| 92 | printf "B# M Size Name Mode File\n" | ||
| 93 | printf "-- - ---- ---- ---- ----\n" | ||
| 94 | end | ||
| 95 | |||
| 96 | set $i = 0 | ||
| 97 | set $alist = Vbuffer_alist | ||
| 98 | while $alist != Qnil | ||
| 99 | ygetptr $alist | ||
| 100 | set $this = ((struct Lisp_Cons *) $ptr)->car | ||
| 101 | set $alist = ((struct Lisp_Cons *) $ptr)->cdr | ||
| 102 | |||
| 103 | # Vbuffer_alist elts are pairs of the form (name . buffer) | ||
| 104 | ygetptr $this | ||
| 105 | set $buf = ((struct Lisp_Cons *) $ptr)->cdr | ||
| 106 | ygetptr $buf | ||
| 107 | set $buf = (struct buffer *) $ptr | ||
| 108 | |||
| 109 | if ! ($files_only && $buf->filename == Qnil) | ||
| 110 | ygetptr $buf->name | ||
| 111 | set $name = ((struct Lisp_String *) $ptr)->data | ||
| 112 | set $modp = ($buf->text->modiff > $buf->text->save_modiff) ? '*' : ' ' | ||
| 113 | |||
| 114 | ygetptr $buf->mode_name | ||
| 115 | set $mode = ((struct Lisp_String *) $ptr)->data | ||
| 116 | |||
| 117 | if $buf->filename != Qnil | ||
| 118 | ygetptr $buf->filename | ||
| 119 | set $filename = ((struct Lisp_String *) $ptr)->data | ||
| 120 | else | ||
| 121 | set $filename = ' ' | ||
| 122 | end | ||
| 123 | |||
| 124 | printf "%2d %c %9d %-20s %-10s %s\n", \ | ||
| 125 | $i, $modp, ($buf->text->z_byte - 1), $name, $mode, $filename | ||
| 126 | end | ||
| 127 | |||
| 128 | set $i++ | ||
| 129 | end | ||
| 130 | end | ||
| 131 | document ybuffer-list | ||
| 132 | Display a list of buffer names, sizes, and other attributes. | ||
| 133 | The buffer number in the first column is used as an argument | ||
| 134 | to some other emacs-buffer recovery commands, e.g. `ysave-buffer'. | ||
| 135 | end | ||
| 136 | |||
| 137 | define yfile-buffers | ||
| 138 | set $yfile_buffers_only = 1 | ||
| 139 | ybuffer-list | ||
| 140 | end | ||
| 141 | document yfile-buffers | ||
| 142 | Display a list of buffers which are associated with files. | ||
| 143 | This is like `ybuffer-list', but only buffers that were visiting files | ||
| 144 | are displayed. | ||
| 145 | end | ||
| 146 | |||
| 147 | define yset-buffer | ||
| 148 | set $i = $arg0 | ||
| 149 | |||
| 150 | set $alist = Vbuffer_alist | ||
| 151 | while ($alist != Qnil && $i > 0) | ||
| 152 | ygetptr $alist | ||
| 153 | set $alist = ((struct Lisp_Cons *) $ptr)->cdr | ||
| 154 | set $i-- | ||
| 155 | end | ||
| 156 | |||
| 157 | # Get car of alist; this is a pair (name . buffer) | ||
| 158 | ygetptr $alist | ||
| 159 | set $this = ((struct Lisp_Cons *) $ptr)->car | ||
| 160 | |||
| 161 | # Get the buffer object | ||
| 162 | ygetptr $this | ||
| 163 | set $this = ((struct Lisp_Cons *) $ptr)->cdr | ||
| 164 | |||
| 165 | ygetptr $this | ||
| 166 | set $ycurrent_buffer = (struct buffer *) $ptr | ||
| 167 | end | ||
| 168 | document yset-buffer | ||
| 169 | Set current buffer (for other emacs-buffer recovery commands) to the ARG'th | ||
| 170 | buffer as displayed by `ybuffer-list'. | ||
| 171 | end | ||
| 172 | |||
| 173 | define yget-buffer-pointers | ||
| 174 | yset-buffer $arg0 | ||
| 175 | set $buf = $ycurrent_buffer->text | ||
| 176 | |||
| 177 | set $beg = $buf->beg | ||
| 178 | set $gap = $beg + $buf->gpt_byte | ||
| 179 | set $gap_end = $gap + $buf->gap_size - 1 | ||
| 180 | set $end = $gap_end + ($buf->z_byte - $buf->gpt_byte) | ||
| 181 | |||
| 182 | set $modp = $buf->modiff > $buf->save_modiff | ||
| 183 | |||
| 184 | #print *$beg@($gap - $beg) | ||
| 185 | #print *$gap_end@($end - $gap_end) | ||
| 186 | end | ||
| 187 | document yget-buffer-pointers | ||
| 188 | Update convenience variables with address pointers for the ARG'th buffer | ||
| 189 | as displayed by `ybuffer-list'. | ||
| 190 | |||
| 191 | This also sets the current buffer using `yset-buffer' (which see). | ||
| 192 | end | ||
| 193 | |||
| 194 | define yget-current-buffer-name | ||
| 195 | set $this = $ycurrent_buffer->name | ||
| 196 | ygetptr $this | ||
| 197 | set $ycurrent_buffer_name = ((struct Lisp_String *) $ptr)->data | ||
| 198 | end | ||
| 199 | document yget-current-buffer-name | ||
| 200 | Set $ycurrent_buffer_name to the name of the currently selected buffer. | ||
| 201 | end | ||
| 202 | |||
| 203 | define ycurrent-buffer | ||
| 204 | yget-current-buffer-name | ||
| 205 | printf "%s\n", $ycurrent_buffer_name | ||
| 206 | end | ||
| 207 | document ycurrent-buffer | ||
| 208 | Display the currently selected buffer. | ||
| 209 | end | ||
| 210 | |||
| 211 | define ydump-buffer | ||
| 212 | yget-buffer-pointers $arg0 | ||
| 213 | if $buf->z_byte > 1 | ||
| 214 | if $buf->z_byte <= $buf->gpt_byte | ||
| 215 | set $endptr = $beg + $buf->gpt_byte - 1 | ||
| 216 | dump binary memory $arg1 $beg $endptr | ||
| 217 | else | ||
| 218 | dump binary memory $arg1 $beg $gap-1 | ||
| 219 | append binary memory $arg1 $gap_end $end | ||
| 220 | set $endptr = $end | ||
| 221 | end | ||
| 222 | end | ||
| 223 | end | ||
| 224 | document ydump-buffer | ||
| 225 | Write contents of buffer N (as numbered according to `ybuffer-list') to | ||
| 226 | file FILE. | ||
| 227 | |||
| 228 | This is mainly used as an internal subroutine for `ysave-buffer' and | ||
| 229 | `ybuffer-contents', which see. | ||
| 230 | end | ||
| 231 | |||
| 232 | define ysave-buffer | ||
| 233 | ydump-buffer $arg0 $arg1 | ||
| 234 | if $yverbose | ||
| 235 | yget-current-buffer-name | ||
| 236 | if $buf->z_byte <= 1 | ||
| 237 | printf "[Buffer \"%s\" is empty.]\n", $ycurrent_buffer_name | ||
| 238 | else | ||
| 239 | # Output string broken into separate calls as necessary to avoid | ||
| 240 | # requiring a running process for evaluation. | ||
| 241 | printf "[Wrote buffer \"%s\" to file ", $ycurrent_buffer_name | ||
| 242 | echo $arg1]\n | ||
| 243 | end | ||
| 244 | end | ||
| 245 | end | ||
| 246 | document ysave-buffer | ||
| 247 | Save contents of buffer N (as numbered according to `ybuffer-list') to | ||
| 248 | file FILE. | ||
| 249 | end | ||
| 250 | |||
| 251 | define ybuffer-contents | ||
| 252 | ydump-buffer $arg0 /dev/stdout | ||
| 253 | if $yverbose && $buf->z_byte <= 1 | ||
| 254 | yget-current-buffer-name | ||
| 255 | printf "[Buffer \"%s\" is empty.]\n", $ycurrent_buffer_name | ||
| 256 | else | ||
| 257 | if *($endptr-1) != '\n' | ||
| 258 | echo \n | ||
| 259 | end | ||
| 260 | end | ||
| 261 | end | ||
| 262 | document ybuffer-contents | ||
| 263 | Write contents of buffer N (numbered according to `ybuffer-list') to stdout. | ||
| 264 | end | ||
| 265 | |||
| 266 | # local variables: | ||
| 267 | # mode: gdb-script | ||
| 268 | # end: | ||
| 269 | |||
| 270 | # arch-tag: 02087f62-2663-4868-977a-1fbb2fc2e7ef | ||
diff --git a/leim/ChangeLog b/leim/ChangeLog index f0ef48c9701..551d7e1cfda 100644 --- a/leim/ChangeLog +++ b/leim/ChangeLog | |||
| @@ -1,3 +1,9 @@ | |||
| 1 | 2005-06-04 Eli Zaretskii <eliz@gnu.org> | ||
| 2 | |||
| 3 | * makefile.w32-in (distclean): Fix a typo (colon was after | ||
| 4 | "clean"). | ||
| 5 | (extraclean): New target, emulates Makefile.in. | ||
| 6 | |||
| 1 | 2005-04-06 Kenichi Handa <handa@m17n.org> | 7 | 2005-04-06 Kenichi Handa <handa@m17n.org> |
| 2 | 8 | ||
| 3 | * quail/sgml-input.el ("sgml"): Enable quail-completion by typing | 9 | * quail/sgml-input.el ("sgml"): Enable quail-completion by typing |
diff --git a/leim/makefile.w32-in b/leim/makefile.w32-in index 839d6129a31..8e0d8c3909c 100644 --- a/leim/makefile.w32-in +++ b/leim/makefile.w32-in | |||
| @@ -1,6 +1,7 @@ | |||
| 1 | # -*- Makefile -*- for leim subdirectory in GNU Emacs on the Microsoft W32 API. | 1 | # -*- Makefile -*- for leim subdirectory in GNU Emacs on the Microsoft W32 API. |
| 2 | # Copyright (C) 1997, 2004 Electrotechnical Laboratory, JAPAN. | 2 | # Copyright (C) 1997, 2004 Electrotechnical Laboratory, JAPAN. |
| 3 | # Licensed to the Free Software Foundation. | 3 | # Licensed to the Free Software Foundation. |
| 4 | # Copyright (C) 2005, Free Software Foundation, Inc. | ||
| 4 | 5 | ||
| 5 | # This file is part of GNU Emacs. | 6 | # This file is part of GNU Emacs. |
| 6 | 7 | ||
| @@ -197,9 +198,12 @@ clean mostlyclean: | |||
| 197 | - $(FOREACH) $(MISC_DIC:.elc=.el) $(FORDO) $(DEL) $(FORVAR) $(ENDFOR) | 198 | - $(FOREACH) $(MISC_DIC:.elc=.el) $(FORDO) $(DEL) $(FORVAR) $(ENDFOR) |
| 198 | - $(DEL) leim-list.el | 199 | - $(DEL) leim-list.el |
| 199 | 200 | ||
| 200 | distclean clean: | 201 | distclean: clean |
| 201 | - $(DELTREE) $(SUBDIRS) | 202 | - $(DELTREE) $(SUBDIRS) |
| 202 | - $(DEL) stamp-subdir | 203 | - $(DEL) stamp-subdir |
| 203 | 204 | ||
| 204 | maintainer-clean: distclean | 205 | maintainer-clean: distclean |
| 205 | - $(FOREACH) $(WORLD) $(FORDO) $(DEL) $(FORVAR) $(ENDFOR) | 206 | - $(FOREACH) $(WORLD) $(FORDO) $(DEL) $(FORVAR) $(ENDFOR) |
| 207 | |||
| 208 | extraclean: maintainer-clean | ||
| 209 | - $(FOREACH) *~ "#*" $(FORDO) $(DEL) $(FORVAR) $(ENDFOR) | ||
diff --git a/lib-src/ChangeLog b/lib-src/ChangeLog index aa9d3fe7fc6..196d2fe70dc 100644 --- a/lib-src/ChangeLog +++ b/lib-src/ChangeLog | |||
| @@ -1,3 +1,7 @@ | |||
| 1 | 2005-06-04 Eli Zaretskii <eliz@gnu.org> | ||
| 2 | |||
| 3 | * ntlib.h (fileno): Don't define if already defined. | ||
| 4 | |||
| 1 | 2005-05-25 Thien-Thi Nguyen <ttn@gnu.org> | 5 | 2005-05-25 Thien-Thi Nguyen <ttn@gnu.org> |
| 2 | 6 | ||
| 3 | * yow.c (setup_yow): Use EXIT_FAILURE in case no separators found. | 7 | * yow.c (setup_yow): Use EXIT_FAILURE in case no separators found. |
diff --git a/lib-src/ntlib.h b/lib-src/ntlib.h index 523e3d6fd49..4dd9cae9796 100644 --- a/lib-src/ntlib.h +++ b/lib-src/ntlib.h | |||
| @@ -90,7 +90,9 @@ int fchown (int fd, int uid, int gid); | |||
| 90 | #define fcloseall _fcloseall | 90 | #define fcloseall _fcloseall |
| 91 | #define fdopen _fdopen | 91 | #define fdopen _fdopen |
| 92 | #define fgetchar _fgetchar | 92 | #define fgetchar _fgetchar |
| 93 | #ifndef fileno | ||
| 93 | #define fileno _fileno | 94 | #define fileno _fileno |
| 95 | #endif | ||
| 94 | #define flushall _flushall | 96 | #define flushall _flushall |
| 95 | #define fputchar _fputchar | 97 | #define fputchar _fputchar |
| 96 | #define getcwd _getcwd | 98 | #define getcwd _getcwd |
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index d1e6655232c..72e02620a50 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,8 +1,612 @@ | |||
| 1 | 2005-05-26 Nick Roberts <nickrob@snap.net.nz> | 1 | 2005-06-05 Nick Roberts <nickrob@snap.net.nz> |
| 2 | |||
| 3 | * progmodes/gdb-ui.el (gdb-info-locals-handler): Use window point | ||
| 4 | to preserve point. | ||
| 5 | (gdb-find-file-hook): Add doc string. | ||
| 6 | |||
| 7 | * progmodes/gud.el (gdb, gud-menu-map): Add command to evaluate | ||
| 8 | C dereferenced pointer expression. | ||
| 9 | (gud-tool-bar-map): Put it on the tool bar. Re-order icons. | ||
| 10 | |||
| 11 | * toolbar/gud-pstar.xpm, toolbar/gud-pstar.pbm: New files. | ||
| 12 | |||
| 13 | * toolbar/gud-break.xpm, toolbar/gud-cont.xpm, toolbar/gud-down.xpm, | ||
| 14 | toolbar/gud-finish.xpm, toolbar/gud-ni.xpm, toolbar/gud-n.xpm, | ||
| 15 | toolbar/gud-print.xpm, toolbar/gud-remove.xpm, toolbar/gud-run.xpm, | ||
| 16 | toolbar/gud-si.xpm, toolbar/gud-s.xpm, toolbar/gud-until.xpm, | ||
| 17 | toolbar/gud-up.xpm, toolbar/gud-watch.xpm: | ||
| 18 | Make background transparent. | ||
| 19 | |||
| 20 | 2005-06-04 Luc Teirlinck <teirllm@auburn.edu> | ||
| 21 | |||
| 22 | * font-lock.el (font-lock-add-keywords): Doc fix. Comment change. | ||
| 23 | (font-lock-remove-keywords): Doc fix. | ||
| 24 | (font-lock-mode-major-mode): Compiler defvar. | ||
| 25 | (font-lock-set-defaults): Use `font-lock-mode-major-mode'. | ||
| 26 | |||
| 27 | * font-core.el (font-lock-mode-major-mode): Compiler defvar. | ||
| 28 | (font-lock-mode): Update `font-lock-mode-major-mode'. | ||
| 29 | (font-lock-set-defaults): Compiler defvar. | ||
| 30 | (font-lock-default-function): Take `font-lock-mode-major-mode' | ||
| 31 | into account. | ||
| 32 | |||
| 33 | * emacs-lisp/easy-mmode.el (define-global-minor-mode): Make it | ||
| 34 | keep track of which major mode it enabled the minor mode for. | ||
| 35 | Use find-file-hook again. Update docstring. | ||
| 36 | |||
| 37 | * simple.el (eval-expression-print-level) | ||
| 38 | (eval-expression-print-length, eval-expression-debug-on-error): | ||
| 39 | Doc fixes. | ||
| 40 | |||
| 41 | 2005-06-04 Matt Hodges <MPHodges@member.fsf.org> | ||
| 42 | |||
| 43 | * iswitchb.el (iswitchb-single-match-face) | ||
| 44 | (iswitchb-current-match-face, iswitchb-virtual-matches-face) | ||
| 45 | (iswitchb-invalid-regexp-face): New faces. | ||
| 46 | (iswitchb-completions): Use them. | ||
| 47 | (iswitchb-use-faces): Renamed from iswitchb-use-fonts, which is | ||
| 48 | now marked as an obsolete alias. | ||
| 49 | (iswitchb-read-buffer): Remove check for bound font variables. | ||
| 50 | (iswitchb-invalid-regexp): New free variable. | ||
| 51 | (iswitchb-get-matched-buffers): Catch invalid-regexp errors and | ||
| 52 | set iswitchb-invalid-regexp. | ||
| 53 | (iswitchb, iswitchb-complete, iswitchb-completions): Deal with | ||
| 54 | invalid regexps. | ||
| 55 | (iswitchb-completions): Add check for complete match when entering | ||
| 56 | a regexp. | ||
| 57 | (iswitchb-completions): Remove require-match argument. | ||
| 58 | (iswitchb-exhibit): Fix caller. | ||
| 59 | (iswitchb-common-match-inserted): New variable. | ||
| 60 | (iswitchb-complete, iswitchb-completion-help): Use it. | ||
| 61 | |||
| 62 | 2005-06-04 David Reitter <david.reitter@gmail.com> (tiny change) | ||
| 63 | |||
| 64 | * url-http.el (url-http-chunked-encoding-after-change-function): | ||
| 65 | Use `url-http-debug' instead of `message'. | ||
| 66 | |||
| 67 | 2005-06-04 Thierry Emery <thierry.emery@free.fr> (tiny change) | ||
| 68 | |||
| 69 | * url-http.el (url-http-parse-headers): Pass redirected URL as a | ||
| 70 | callback argument. | ||
| 71 | |||
| 72 | 2005-06-04 Kim F. Storm <storm@cua.dk> | ||
| 73 | |||
| 74 | * simple.el (line-move): Only call sit-for when moving backwards. | ||
| 75 | |||
| 76 | * ido.el (ido-make-merged-file-list-1): New defun split from | ||
| 77 | ido-make-merged-file-list. | ||
| 78 | (ido-make-merged-file-list): Bind throw-on-input around call to | ||
| 79 | ido-make-merged-file-list-1. Return input-pending-p if | ||
| 80 | interrupted by more input available. | ||
| 81 | (ido-read-internal): Handle input-pending-p return value from | ||
| 82 | ido-make-merged-file-list. | ||
| 83 | |||
| 84 | 2005-06-03 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 85 | |||
| 86 | * textmodes/flyspell.el (flyspell-check-word-p): Simplify silly | ||
| 87 | compatibility code. | ||
| 88 | |||
| 89 | * international/latexenc.el (latexenc-find-file-coding-system): | ||
| 90 | Don't inherit the EOL part of the coding-system from the | ||
| 91 | tex-main buffer. Fit within 80 columns. | ||
| 92 | |||
| 93 | 2005-06-03 Matt Hodges <MPHodges@member.fsf.org> | ||
| 94 | |||
| 95 | * tmm.el (tmm-inactive-face): New face. | ||
| 96 | (tmm-remove-inactive-mouse-face): New function. | ||
| 97 | (tmm-prompt, tmm-add-one-shortcut) | ||
| 98 | (tmm-add-prompt, tmm-get-keymap): Make active menu items visible | ||
| 99 | but not selectable. | ||
| 100 | |||
| 101 | 2005-06-03 Juanma Barranquero <lekktu@gmail.com> | ||
| 102 | |||
| 103 | * faces.el (face-equal): Improve argument/docstring consistency. | ||
| 104 | |||
| 105 | 2005-06-03 Daniel Pfeiffer <occitan@esperanto.org> | ||
| 106 | |||
| 107 | * progmodes/make-mode.el (makefile-targets-face) | ||
| 108 | (makefile-shell-face, makefile-makepp-perl-face): Add :version. | ||
| 109 | (makefile-bsdmake-dependency-regex) | ||
| 110 | (makefile-makepp-rule-action-regex) | ||
| 111 | (makefile-bsdmake-rule-action-regex): New constants. | ||
| 112 | (makefile-makepp-mode, makefile-bsdmake-mode): Use them. | ||
| 113 | |||
| 114 | * progmodes/compile.el (compilation-error-regexp-alist-alist): | ||
| 115 | Allow (...) within `...' for makepp messages. | ||
| 116 | |||
| 117 | 2005-06-03 Michael Kifer <kifer@cs.stonybrook.edu> | ||
| 118 | |||
| 119 | * ediff-diff.el (ediff-same-contents): Eliminate CL-type functions. | ||
| 120 | |||
| 121 | * ediff-mult.el (ediff-intersect-directories): Make sure that ".." and | ||
| 122 | "." files are deleted from all file lists before comparison. | ||
| 123 | |||
| 124 | * viper-keym.el (viper-toggle-key, viper-quoted-insert-key) | ||
| 125 | (viper-ESC-key): Made them customizable. | ||
| 126 | |||
| 127 | * viper.el (viper-non-hook-settings): Fix the names of defadvices. | ||
| 128 | |||
| 129 | 2005-06-01 Luc Teirlinck <teirllm@auburn.edu> | ||
| 130 | |||
| 131 | * autorevert.el (auto-revert-buffers): Use save-match-data. | ||
| 132 | |||
| 133 | 2005-06-01 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 134 | |||
| 135 | * emacs-lisp/easymenu.el (easy-menu-return-item): Quick fix to find | ||
| 136 | menu items with a nil command binding. | ||
| 137 | |||
| 138 | 2005-06-01 Juanma Barranquero <lekktu@gmail.com> | ||
| 139 | |||
| 140 | * emacs-lisp/cl-macs.el (defsetf): | ||
| 141 | Improve argument/docstring consistency. | ||
| 142 | |||
| 143 | * faces.el (list-faces-display): Improve the formatting by | ||
| 144 | computing the maximum length required for any face-name (reworked | ||
| 145 | patch of 1999-01-11, accidentally deleted on 1999-07-21). | ||
| 146 | (internal-find-face): Remove redundant info in docstring. | ||
| 147 | |||
| 148 | 2005-06-01 Nick Roberts <nickrob@snap.net.nz> | ||
| 149 | |||
| 150 | * progmodes/gdb-ui.el (gdb-set-gud-minor-mode-1) | ||
| 151 | (gdb-info-breakpoints-custom, gdb-delete-breakpoint) | ||
| 152 | (gdb-goto-breakpoint, gdb-source-info, gdb-get-location) | ||
| 153 | (gdb-assembler-custom): Improve regexps. | ||
| 154 | (def-gdb-auto-update-handler): Use window point to preserve | ||
| 155 | point. | ||
| 156 | |||
| 157 | 2005-05-31 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 158 | |||
| 159 | * thumbs.el (thumbs-mode): Fix misuse of make-variable-buffer-local. | ||
| 160 | |||
| 161 | 2005-05-31 Jay Belanger <belanger@truman.edu> | ||
| 162 | |||
| 163 | * calc/calc-embed.el (calc-embedded-word): Change argument passed | ||
| 164 | to calc-embedded. | ||
| 165 | (calc-embedded-make-info): Have plain prefix argument select | ||
| 166 | entire line. | ||
| 167 | |||
| 168 | 2005-05-31 Juanma Barranquero <lekktu@gmail.com> | ||
| 169 | |||
| 170 | * faces.el (list-faces-display): Signal error if passed a regexp | ||
| 171 | that matches no face name. | ||
| 172 | |||
| 173 | * simple.el (filter-buffer-substring): Fix typo in docstring. | ||
| 174 | |||
| 175 | 2005-05-31 Richard M. Stallman <rms@gnu.org> | ||
| 176 | |||
| 177 | * progmodes/vhdl-mode.el (vhdl-fill-region): Test ARG, not INTERACTIVE. | ||
| 178 | (vhdl-emacs-21): Doc fix. | ||
| 179 | (vhdl-mode): Unconditionally set comment-padding. | ||
| 180 | (vhdl-fixup-whitespace-region): Insert spaces only where | ||
| 181 | there are none. | ||
| 182 | (vhdl-statistics-buffer): Make the Emacs 21 behavior universal. | ||
| 183 | |||
| 184 | 2005-05-30 John Wiegley <johnw@newartisans.com> | ||
| 185 | |||
| 186 | * eshell/em-cmpl.el, eshell/em-dirs.el, eshell/em-glob.el | ||
| 187 | * eshell/em-unix.el, eshell/esh-ext.el, eshell/esh-io.el | ||
| 188 | * eshell/esh-util.el, eshell/esh-var.el: Change all uses of | ||
| 189 | `directory-sep-char' to ?/, and all uses of `string-to-int' to | ||
| 190 | `string-to-number'. | ||
| 191 | |||
| 192 | 2005-05-30 Jay Belanger <belanger@truman.edu> | ||
| 193 | |||
| 194 | * calc/calc.el (calc-bug-address): Fix docstring. | ||
| 195 | (calc-window-hook, calc-trail-window-hook): New variables. | ||
| 196 | (calc-trail-display): Restore use of calc-trail-window-hook. | ||
| 197 | (calc): Restore use of calc-window-hook. | ||
| 198 | |||
| 199 | 2005-05-31 Masatake YAMATO <jet@gyve.org> | ||
| 200 | |||
| 201 | * emacs-lisp/find-func.el (find-function-noselect): Handle subroutines. | ||
| 202 | |||
| 203 | * help-fns.el (help-C-file-name): Add autoload mark for | ||
| 204 | `find-function-noselect'. | ||
| 205 | |||
| 206 | 2005-05-30 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 207 | |||
| 208 | * textmodes/tex-mode.el (tex-compile-commands, tex-compile) | ||
| 209 | (tex-start-tex): Undo all but the last part of the 2005-05-28 change. | ||
| 210 | |||
| 211 | 2005-05-30 Glenn Morris <gmorris@ast.cam.ac.uk> | ||
| 212 | |||
| 213 | * calendar/diary-lib.el (mark-included-diary-files): Only kill | ||
| 214 | included diary buffer if it was not already being visited. | ||
| 215 | Reported by Stephen Berman <Stephen.Berman@gmx.net>. | ||
| 216 | |||
| 217 | * calendar/icalendar.el (top-level): Do not require 'appt. | ||
| 218 | |||
| 219 | * mail/supercite.el (sc-select-attribution): Only use a list | ||
| 220 | element from sc-attrib-selection-list if it returns a string. | ||
| 221 | Reported by Davide G. M. Salvetti <salve@debian.org>. | ||
| 222 | |||
| 223 | 2005-05-30 Juanma Barranquero <lekktu@gmail.com> | ||
| 224 | |||
| 225 | * thumbs.el (thumbs-thumbname): The resulting thubname now | ||
| 226 | includes a hash value to improve its uniqueness, and has a ".jpg" | ||
| 227 | extension. Also, it is now a valid filename on all systems. | ||
| 228 | (thumbs-make-thumb): Use `let', not `let*'. | ||
| 229 | (thumbs-show-thumbs-list): Check for JPEG availability. | ||
| 230 | |||
| 231 | 2005-05-30 Richard M. Stallman <rms@gnu.org> | ||
| 232 | |||
| 233 | * filesets.el (filesets-menu-ensure-use-cached): | ||
| 234 | Prevent warning when emacs-version>= is undefined. | ||
| 235 | |||
| 236 | * printing.el (pr-interactive-n-up): Use string-to-number. | ||
| 237 | |||
| 238 | * emulation/tpu-mapper.el: Use eval-buffer, not eval-current-buffer. | ||
| 239 | |||
| 240 | * emacs-lisp/bytecomp.el (byte-compile-nogroup-warn): | ||
| 241 | Warn only when name to be defined is quoted. | ||
| 242 | |||
| 243 | 2005-05-30 Nick Roberts <nickrob@snap.net.nz> | ||
| 244 | |||
| 245 | * progmodes/gdb-ui.el (gdb-toggle-breakpoint): | ||
| 246 | Make regexp more robust. | ||
| 247 | (gdb-display-assembler-buffer, gdb-frame-assembler-buffer): | ||
| 248 | Force regeneration of disassembly. | ||
| 249 | |||
| 250 | 2005-05-29 Jay Belanger <belanger@truman.edu> | ||
| 251 | |||
| 252 | * calc/calc.el (calc-user-invocation): Check if | ||
| 253 | calc-invocation-macro is non-nil. | ||
| 254 | |||
| 255 | 2005-05-29 Juri Linkov <juri@jurta.org> | ||
| 256 | |||
| 257 | * add-log.el (change-log-font-lock-keywords): | ||
| 258 | Add `+' to e-mail regexp to accept mail address with keywords. | ||
| 259 | |||
| 260 | * man.el (Man-name-regexp): Add `:' to accept qualified names. | ||
| 261 | |||
| 262 | 2005-05-29 Luc Teirlinck <teirllm@auburn.edu> | ||
| 263 | |||
| 264 | * progmodes/inf-lisp.el (inferior-lisp-mode): Use delay-mode-hooks. | ||
| 265 | |||
| 266 | * ielm.el (inferior-emacs-lisp-mode): Ditto. | ||
| 267 | |||
| 268 | 2005-05-29 Richard M. Stallman <rms@gnu.org> | ||
| 269 | |||
| 270 | * textmodes/flyspell.el (flyspell-auto-correct-previous-word): | ||
| 271 | Undo the change that moves to end of the current word. | ||
| 272 | |||
| 273 | 2005-05-29 Nick Roberts <nickrob@snap.net.nz> | ||
| 274 | |||
| 275 | * progmodes/gdb-ui.el (gdb-memory-set-repeat-count): | ||
| 276 | Throw error when count <= 0 to ensure input is a number. | ||
| 277 | (gdb-read-memory-custom): Pick up address from buffer. | ||
| 278 | (gdb-memory-mode): Allow user to increment and decrement | ||
| 279 | memory address from header line. | ||
| 280 | |||
| 281 | 2005-05-29 Richard M. Stallman <rms@gnu.org> | ||
| 282 | |||
| 283 | * flyspell.el (flyspell-version): Function deleted. | ||
| 284 | (flyspell-auto-correct-previous-hook): Doc fix. | ||
| 285 | |||
| 286 | * jit-lock.el (jit-lock-function, jit-lock-after-change): | ||
| 287 | Do nothing if memory is full. | ||
| 288 | |||
| 289 | * font-lock.el (font-lock-fontify-syntactically-region): | ||
| 290 | Pass t for GREEDY to looking-back. | ||
| 291 | |||
| 292 | * saveplace.el (save-place-alist-to-file): Write the file | ||
| 293 | using write-region. | ||
| 294 | |||
| 295 | * subr.el (looking-back): New argument GREEDY. | ||
| 296 | |||
| 297 | * progmodes/compile.el (compilation-start): Set the mode | ||
| 298 | before inserting the initial text. | ||
| 299 | |||
| 300 | * progmodes/which-func.el (which-func-update-1): Turn the mode | ||
| 301 | off in case of error by setting which-func-mode. | ||
| 302 | |||
| 303 | 2005-05-29 Peter Heslin <p.j.heslin@durham.ac.uk> (tiny change) | ||
| 304 | |||
| 305 | * flyspell.el (flyspell-auto-correct-previous-word): | ||
| 306 | Narrow down to what's on the screen, and recenter overlays | ||
| 307 | at the end of the next word. | ||
| 308 | |||
| 309 | 2005-05-29 Manuel Serrano <Manuel.Serrano@sophia.inria.fr> | ||
| 310 | |||
| 311 | * flyspell.el (flyspell-emacs, flyspell-use-local-map): Vars moved up. | ||
| 312 | (flyspell-default-delayed-commands): Add backward-delete-char-untabify. | ||
| 313 | (flyspell-abbrev-p): Default to nil. | ||
| 314 | (flyspell-use-global-abbrev-table-p): Doc fix. | ||
| 315 | (flyspell-large-region): Allow nil as value. | ||
| 316 | (flyspell-use-meta-tab, flyspell-auto-correct-binding): New variables. | ||
| 317 | |||
| 318 | (mail-mode-flyspell-verify): More robust handling | ||
| 319 | of `mail-header-separator'. More efficient signature detection. | ||
| 320 | Allow for regexp metacharacters in message-header-separator. | ||
| 321 | Adding `To' not to be checked in mail-mode-flyspell-verify. | ||
| 322 | |||
| 323 | (flyspell-prog-mode): Run flyspell-prog-mode-hook. | ||
| 324 | (flyspell-mouse-map): Bind M-TAB only if flyspell-use-meta-tab. | ||
| 325 | Bind flyspell-auto-correct-binding. | ||
| 326 | Bind C-. and C-, . | ||
| 327 | (flyspell-mode-map): Likewise. | ||
| 328 | (flyspell-mode): Doc fix. | ||
| 329 | (flyspell-accept-buffer-local-defs): Preserve current buffer. | ||
| 330 | (flyspell-mode-on): Bind flyspell-mouse-map and flyspell-mode-map. | ||
| 331 | (flyspell-word-cache-result): New var, always local. | ||
| 332 | (flyspell-check-pre-word-p): Doc fix. | ||
| 333 | (flyspell-check-changed-word-p): Handle spc like newline. | ||
| 334 | (flyspell-post-command-hook): Set flyspell-word-cache-result. | ||
| 335 | (flyspell-word-search-backward, flyspell-word-search-forward): | ||
| 336 | New functions. | ||
| 337 | (flyspell-word): Return t if nothing to check. | ||
| 338 | When parsing TeX code, check for after } or \. | ||
| 339 | Use flyspell-word-search-backward to find previous word. | ||
| 340 | Return nil if duplicated word. | ||
| 341 | For word already checked, return same value as last time. | ||
| 342 | Set flyspell-word-cache-result after checking. | ||
| 343 | Don't clobber the return value. | ||
| 344 | (flyspell-get-word): Major rewrite. | ||
| 345 | (flyspell-external-point-words): New locals pword, pcount. | ||
| 346 | Fix size used in progress message. | ||
| 347 | Find the proper corresponding word in flyspell-large-region-buffer. | ||
| 348 | (flyspell-region): Check for flyspell-large-region = nil. | ||
| 349 | (flyspell-highlight-incorrect-region): Clean up overlays in region. | ||
| 350 | (flyspell-auto-correct-word): Check that WORD is a cons. | ||
| 351 | (flyspell-correct-word): Likewise. | ||
| 352 | |||
| 353 | 2005-05-29 Daniel Pfeiffer <occitan@esperanto.org> | ||
| 354 | |||
| 355 | * progmodes/make-mode.el (makefile-rule-action-regex) | ||
| 356 | (makefile-macroassign-regex, makefile-makepp-mode) | ||
| 357 | (makefile-bsdmake-mode): Continuation lines may be empty. | ||
| 358 | Reported by Joshua Varner. | ||
| 359 | (makefile-makepp-font-lock-keywords): Add $(stem). | ||
| 360 | |||
| 361 | 2005-05-28 Karl Berry <karl@gnu.org> | ||
| 362 | |||
| 363 | * textmodes/tex-mode.el: Now that tex-send-command calls | ||
| 364 | shell-quote-argument (2005-03-31 change), remove all calls to | ||
| 365 | shell-quote-argument; they all end up invoking tex-send-command. | ||
| 366 | The double quoting loses on filenames with non-safe characters, | ||
| 367 | such as "@". Reported by Frederik Fouvry. | ||
| 368 | |||
| 369 | 2005-05-29 Nick Roberts <nickrob@snap.net.nz> | ||
| 370 | |||
| 371 | * progmodes/gdb-ui.el (gdb-assembler-custom): Be more careful | ||
| 372 | about preserving point. | ||
| 373 | |||
| 374 | 2005-05-27 Jay Belanger <belanger@truman.edu> | ||
| 375 | |||
| 376 | * calc/calc-misc.el (calc-info-goto-node): Use info instead of | ||
| 377 | Info-goto-node. | ||
| 378 | |||
| 379 | * calc/calc-embed.el (calc-embed-arg): New variable. | ||
| 380 | (calc-do-embedded-activate, calc-embedded-activate-formula) | ||
| 381 | (calc-embedded-edit, calc-do-embedded-activate): Replace undeclared | ||
| 382 | variable by new variable. | ||
| 383 | (calc-embedded-make-info): Replace undeclared variable by new | ||
| 384 | variable. When selecting region with positive prefix | ||
| 385 | argument, use end of previous line instead of beginning of line. | ||
| 386 | |||
| 387 | * calc/calc-aent.el (calc-arg-values): Declare it. | ||
| 388 | |||
| 389 | * calc/calc-ext.el (calc-help-map, calc-alg-map, calc-alg-esc-map): | ||
| 390 | Declare them. | ||
| 391 | |||
| 392 | * calc/calc-stuff.el (math-decls-cache-tag): Declare it. | ||
| 393 | |||
| 394 | * calc/calc.el (calc-alg-map): Declare it. | ||
| 395 | |||
| 396 | * calc/calcalg2.el (math-decls-cache, math-decls-all): Declare them. | ||
| 397 | |||
| 398 | 2005-05-28 Nick Roberts <nickrob@snap.net.nz> | ||
| 399 | |||
| 400 | * progmodes/gdb-ui.el (gdb-all-registers): New variable. | ||
| 401 | (gdb-registers-buffer, toggle-gdb-all-registers): | ||
| 402 | Toggle display of floating point registers. | ||
| 403 | (gdb-registers-mode-map): Bind SPC to toggle-gdb-all-registers. | ||
| 404 | |||
| 405 | * progmodes/gud.el (gud-goto-info): Use info. Don't use require. | ||
| 406 | (toggle-gud-tooltip-dereference): | ||
| 407 | Rename from gud-toggle-tooltip-dereference. | ||
| 408 | |||
| 409 | 2005-05-27 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 410 | |||
| 411 | * info.el (Info-goto-node): Revert autoload addition (2004-06-12). | ||
| 412 | |||
| 413 | 2005-05-27 Jay Belanger <belanger@truman.edu> | ||
| 414 | |||
| 415 | * calc/calc-prog.el (calc-kbd-report): Remove. | ||
| 416 | (calc-kbd-query): Rewrite. | ||
| 417 | |||
| 418 | 2005-05-27 Juanma Barranquero <lekktu@gmail.com> | ||
| 419 | |||
| 420 | * image.el (image-library-alist): Move to image.c. | ||
| 421 | (image-type-available-p): Doc fix. | ||
| 422 | |||
| 423 | 2005-05-27 Lute Kamstra <lute@gnu.org> | ||
| 424 | |||
| 425 | * calc/calc.el (calc): | ||
| 426 | * outline.el (outline-1, outline-2, outline-3, outline-4) | ||
| 427 | (outline-5, outline-6, outline-7, outline-8): | ||
| 428 | * textmodes/dns-mode.el (dns-mode): | ||
| 429 | * textmodes/sgml-mode.el (sgml-namespace-face): | ||
| 430 | * textmodes/tex-mode.el (superscript, subscript, tex-math-face) | ||
| 431 | (tex-verbatim-face, tex-use-reftex): | ||
| 432 | * textmodes/texinfo.el (texinfo-heading-face): | ||
| 433 | Specify customization group. | ||
| 434 | |||
| 435 | * longlines.el: Don't require easy-mmode. | ||
| 436 | (longlines-visible-face): Specify customization group. | ||
| 437 | |||
| 438 | 2005-05-27 Kenichi Handa <handa@m17n.org> | ||
| 439 | |||
| 440 | * language/cyrillic.el: Add cyrillic-iso8859-5 characters in the | ||
| 441 | encoding table of windows-1251. | ||
| 442 | |||
| 443 | * international/ucs-tables.el (ucs-set-table-for-input): | ||
| 444 | If translation-table-for-input of a coding system is a symbol, get | ||
| 445 | its translation-table property. | ||
| 446 | |||
| 447 | * international/code-pages.el: Don't register a coding system into | ||
| 448 | non-iso-charset-alist more than once. | ||
| 449 | (cp-make-coding-system): Likewise. | ||
| 450 | |||
| 451 | 2005-05-26 John Wiegley <johnw@newartisans.com> | ||
| 452 | |||
| 453 | * eshell/esh-cmd.el (eshell-eval-command): If the return value of | ||
| 454 | `eshell-resume-eval' is wrapped in a list, it indicates that the | ||
| 455 | command was run asynchronously. In that case, unwrap the value | ||
| 456 | before checking the delimiter value. | ||
| 457 | |||
| 458 | * eshell/em-cmpl.el (eshell-complete-parse-arguments): If the | ||
| 459 | character before a space at the end of a line is \, assume the space | ||
| 460 | is part of the last argument rather than a final argument separator. | ||
| 461 | |||
| 462 | * eshell/esh-io.el (eshell-get-target): If `eshell-buffer-shorthand' | ||
| 463 | is in use, and the target is `t' or `nil' (which are the most common | ||
| 464 | values), don't assume that the symbol target is a buffer. | ||
| 465 | |||
| 466 | 2005-05-26 Luc Teirlinck <teirllm@auburn.edu> | ||
| 467 | |||
| 468 | * calendar/calendar.el (calendar-mode-line-format): | ||
| 469 | Use mode-line-highlight as mouse-face. | ||
| 470 | |||
| 471 | * time.el (display-time-string-forms, display-time-update): | ||
| 472 | Use mode-line-highlight as mouse-face. | ||
| 473 | |||
| 474 | 2005-05-26 Jay Belanger <belanger@truman.edu> | ||
| 475 | |||
| 476 | * calc/calc.el (calc-language-alist): Remove extra defvar. | ||
| 477 | |||
| 478 | 2005-05-26 Lute Kamstra <lute@gnu.org> | ||
| 479 | |||
| 480 | * arc-mode.el (archive-mode): | ||
| 481 | * bookmark.el (bookmark-read-annotation-mode) | ||
| 482 | (bookmark-edit-annotation-mode, bookmark-bmenu-mode): | ||
| 483 | * bs.el (bs-mode): | ||
| 484 | * calc/calc-yank.el (calc-edit-mode): | ||
| 485 | * calc/calc.el (calc-mode, calc-trail-mode): | ||
| 486 | * calculator.el (calculator-mode): | ||
| 487 | * chistory.el (command-history-mode): | ||
| 488 | * comint.el: | ||
| 489 | * cus-edit.el (custom-mode): | ||
| 490 | * descr-text.el (describe-text-mode): | ||
| 491 | * ebuff-menu.el (Electric-buffer-menu-mode): | ||
| 492 | * ediff-util.el (ediff-mode): | ||
| 493 | * emacs-lisp/re-builder.el (reb-mode): | ||
| 494 | * emulation/vi.el (vi-mode-setup): | ||
| 495 | * emulation/ws-mode.el (wordstar-mode): | ||
| 496 | * eshell/esh-mode.el (eshell-mode): | ||
| 497 | * forms.el (forms-mode): | ||
| 498 | * help-mode.el (help-mode): | ||
| 499 | * hexl.el (hexl-mode): | ||
| 500 | * ibuffer.el (ibuffer-mode): | ||
| 501 | * ielm.el (inferior-emacs-lisp-mode): | ||
| 502 | * info.el (Info-mode, Info-edit-mode): | ||
| 503 | * international/swedish.el: | ||
| 504 | * ledit.el (ledit-from-lisp-mode): | ||
| 505 | * locate.el (locate-mode): | ||
| 506 | * mail/rmail.el (rmail-mode): | ||
| 507 | * mail/rmailedit.el (rmail-edit-mode): | ||
| 508 | * mail/rmailsum.el (rmail-summary-mode): | ||
| 509 | * mail/supercite.el (sc-electric-mode): | ||
| 510 | * net/eudc.el (eudc-mode): | ||
| 511 | * net/quickurl.el (quickurl-list-mode): | ||
| 512 | * net/snmp-mode.el (snmp-mode, snmpv2-mode): | ||
| 513 | * obsolete/ooutline.el (outline-mode): | ||
| 514 | * obsolete/options.el (Edit-options-mode): | ||
| 515 | * obsolete/rnews.el (news-mode): | ||
| 516 | * obsolete/rnewspost.el (news-reply-mode): | ||
| 517 | * play/5x5.el (5x5-mode): | ||
| 518 | * play/decipher.el (decipher-mode, decipher-stats-mode): | ||
| 519 | * play/gomoku.el (gomoku-mode): | ||
| 520 | * play/snake.el (snake-mode): | ||
| 521 | * play/solitaire.el (solitaire-mode): | ||
| 522 | * play/tetris.el (tetris-mode): | ||
| 523 | * progmodes/ada-mode.el (ada-mode): | ||
| 524 | * progmodes/antlr-mode.el (antlr-mode): | ||
| 525 | * progmodes/autoconf.el (autoconf-mode): | ||
| 526 | * progmodes/dcl-mode.el (dcl-mode): | ||
| 527 | * progmodes/delphi.el (delphi-mode): | ||
| 528 | * progmodes/ebrowse.el (ebrowse-tree-mode) | ||
| 529 | (ebrowse-electric-list-mode, ebrowse-member-mode) | ||
| 530 | (ebrowse-electric-position-mode): | ||
| 531 | * progmodes/f90.el (f90-mode): | ||
| 532 | * progmodes/fortran.el (fortran-mode): | ||
| 533 | * progmodes/icon.el (icon-mode): | ||
| 534 | * progmodes/idlw-help.el (idlwave-help-mode): | ||
| 535 | * progmodes/idlw-shell.el (idlwave-shell-mode): | ||
| 536 | * progmodes/idlwave.el (idlwave-mode): | ||
| 537 | * progmodes/inf-lisp.el (inferior-lisp-mode): | ||
| 538 | * progmodes/m4-mode.el (m4-mode): | ||
| 539 | * progmodes/meta-mode.el (metafont-mode, metapost-mode): | ||
| 540 | * progmodes/modula2.el (modula-2-mode): | ||
| 541 | * progmodes/octave-inf.el (inferior-octave-mode): | ||
| 542 | * progmodes/octave-mod.el (octave-mode): | ||
| 543 | * progmodes/pascal.el (pascal-mode): | ||
| 544 | * progmodes/sh-script.el (sh-mode): | ||
| 545 | * progmodes/sql.el (sql-mode, sql-interactive-mode): | ||
| 546 | * progmodes/vhdl-mode.el (vhdl-mode): | ||
| 547 | * progmodes/xscheme.el (scheme-interaction-mode): | ||
| 548 | * replace.el (occur-mode): | ||
| 549 | * ses.el (ses-mode): | ||
| 550 | * simple.el (completion-list-mode): | ||
| 551 | * skeleton.el: | ||
| 552 | * speedbar.el (speedbar-mode): | ||
| 553 | * term.el (term-mode): | ||
| 554 | * terminal.el (terminal-edit-mode): | ||
| 555 | * textmodes/reftex-index.el (reftex-index-mode) | ||
| 556 | (reftex-index-phrases-mode): | ||
| 557 | * textmodes/reftex-sel.el (reftex-select-label-mode) | ||
| 558 | (reftex-select-bib-mode): | ||
| 559 | * textmodes/reftex-toc.el (reftex-toc-mode): | ||
| 560 | * wdired.el (wdired-change-to-wdired-mode): | ||
| 561 | * wid-browse.el (widget-browse-mode): | ||
| 562 | Use run-mode-hooks. | ||
| 563 | |||
| 564 | * array.el (array-mode): | ||
| 565 | * calendar/todo-mode.el (todo-mode): | ||
| 566 | * man.el (Man-mode): | ||
| 567 | * play/landmark.el (lm-mode): | ||
| 568 | * play/mpuz.el (mpuz-mode): | ||
| 569 | Use kill-all-local-variables and run-mode-hooks. | ||
| 570 | |||
| 571 | * subr.el (delay-mode-hooks): Specify indentation. | ||
| 572 | |||
| 573 | 2005-05-26 Mark A. Hershberger <mah@everybody.org> | ||
| 574 | |||
| 575 | * xml.el (xml-substitute-special): Don't die for undefined xml entities. | ||
| 576 | |||
| 577 | 2005-05-26 Jay Belanger <belanger@truman.edu> | ||
| 578 | |||
| 579 | * calc/calc-prog.el (calc-user-define-edit): Don't find substring | ||
| 580 | of nil. | ||
| 581 | |||
| 582 | 2005-05-27 Nick Roberts <nickrob@snap.net.nz> | ||
| 583 | |||
| 584 | * progmodes/gdb-ui.el (gdb-frame-address): | ||
| 585 | Rename from gdb-current-address. | ||
| 586 | (gdb-previous-frame-address): Rename from gdb-previous-address. | ||
| 587 | (gdb-selected-frame): Rename from gdb-current-frame. | ||
| 588 | (gdb-get-selected-frame): Rename from gdb-get-current-frame. | ||
| 589 | (gdb-frame-number): Rename from gdb-current-stack-level. | ||
| 590 | (gdb-ann3): Match new mode-name for disassembly buffer. | ||
| 591 | Extend initialisation of variables. | ||
| 592 | (gdb-post-prompt): Update disassembly from gdb-frame-handler. | ||
| 593 | (gdb-memory-mode): Use mouse-face in header line. | ||
| 594 | (gdb-assembler-buffer-name): Call it disassembly and give frame | ||
| 595 | in mode line. | ||
| 596 | (gdb-source-spec-regexp, gdb-assembler-custom) | ||
| 597 | (gdb-invalidate-assembler, gdb-frame-handler): | ||
| 598 | Make robust to leading zeroes in address format. | ||
| 599 | |||
| 600 | 2005-05-26 Carsten Dominik <dominik@science.uva.nl> | ||
| 601 | |||
| 602 | * textmodes/org.el (org-mode): Use `define-derived-mode' to | ||
| 603 | define `org-mode'. | ||
| 604 | (org-agenda-mode): Use `run-mode-hooks' instead of `run-hooks'. | ||
| 605 | |||
| 606 | 2005-05-26 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 2 | 607 | ||
| 3 | * log-edit.el (log-edit-changelog-entries): Distinguish between | 608 | * log-edit.el (log-edit-changelog-entries): Distinguish between |
| 4 | filenames like xfns.c and fns.c. | 609 | filenames like xfns.c and fns.c. |
| 5 | Coded by Stefan Monnier <monnier@iro.umontreal.ca>. | ||
| 6 | 610 | ||
| 7 | 2005-05-25 Luc Teirlinck <teirllm@auburn.edu> | 611 | 2005-05-25 Luc Teirlinck <teirllm@auburn.edu> |
| 8 | 612 | ||
| @@ -35,7 +639,7 @@ | |||
| 35 | 639 | ||
| 36 | 2005-05-24 Andre Spiegel <spiegel@gnu.org> | 640 | 2005-05-24 Andre Spiegel <spiegel@gnu.org> |
| 37 | 641 | ||
| 38 | * progmodes/cperl-mode.el (cperl-vc-header-alist): Obsoleted. | 642 | * progmodes/cperl-mode.el (cperl-vc-header-alist): Obsolete. |
| 39 | (cperl-vc-rcs-header, cperl-vc-sccs-header): New user options. | 643 | (cperl-vc-rcs-header, cperl-vc-sccs-header): New user options. |
| 40 | (cperl-mode): Use them. | 644 | (cperl-mode): Use them. |
| 41 | 645 | ||
| @@ -76,11 +680,11 @@ | |||
| 76 | 680 | ||
| 77 | CC Mode update to 5.30.10: | 681 | CC Mode update to 5.30.10: |
| 78 | 682 | ||
| 79 | * cc-fonts.el (c-font-lock-declarators): Fixed bug where the point | 683 | * cc-fonts.el (c-font-lock-declarators): Fix bug where the point |
| 80 | could go past the limit in decoration level 2, thereby causing | 684 | could go past the limit in decoration level 2, thereby causing |
| 81 | errors during interactive fontification. | 685 | errors during interactive fontification. |
| 82 | 686 | ||
| 83 | * cc-mode.el (c-make-inherited-keymap): Fixed cc-bytecomp bug when | 687 | * cc-mode.el (c-make-inherited-keymap): Fix cc-bytecomp bug when |
| 84 | the file is evaluated interactively. | 688 | the file is evaluated interactively. |
| 85 | 689 | ||
| 86 | * cc-engine.el (c-guess-basic-syntax): Handle operator | 690 | * cc-engine.el (c-guess-basic-syntax): Handle operator |
| @@ -98,7 +702,7 @@ | |||
| 98 | Compensate for return value from `forward-line' when it has moved | 702 | Compensate for return value from `forward-line' when it has moved |
| 99 | but not to a different line due to eob. | 703 | but not to a different line due to eob. |
| 100 | 704 | ||
| 101 | * cc-engine.el (c-guess-basic-syntax): Fixed anchoring in | 705 | * cc-engine.el (c-guess-basic-syntax): Fix anchoring in |
| 102 | `objc-method-intro' and `objc-method-args-cont'. | 706 | `objc-method-intro' and `objc-method-args-cont'. |
| 103 | 707 | ||
| 104 | 2005-05-23 Alan Mackenzie <bug-cc-mode@gnu.org> | 708 | 2005-05-23 Alan Mackenzie <bug-cc-mode@gnu.org> |
| @@ -127,8 +731,7 @@ | |||
| 127 | * subr.el (font-lock-defaults): Remove defvar as it's already | 731 | * subr.el (font-lock-defaults): Remove defvar as it's already |
| 128 | defined in font-core.el. | 732 | defined in font-core.el. |
| 129 | 733 | ||
| 130 | * font-lock.el (font-lock-beginning-of-syntax-function): Fix | 734 | * font-lock.el (font-lock-beginning-of-syntax-function): Fix docstring. |
| 131 | docstring. | ||
| 132 | 735 | ||
| 133 | 2005-05-23 Nick Roberts <nickrob@snap.net.nz> | 736 | 2005-05-23 Nick Roberts <nickrob@snap.net.nz> |
| 134 | 737 | ||
| @@ -140,8 +743,8 @@ | |||
| 140 | 743 | ||
| 141 | * font-core.el: Update comment. | 744 | * font-core.el: Update comment. |
| 142 | 745 | ||
| 143 | * emacs-lisp/easy-mmode.el (define-global-minor-mode): Use | 746 | * emacs-lisp/easy-mmode.el (define-global-minor-mode): |
| 144 | `after-change-major-mode-hook' instead of `find-file-hook'. | 747 | Use `after-change-major-mode-hook' instead of `find-file-hook'. |
| 145 | 748 | ||
| 146 | * buff-menu.el (Buffer-menu-mode): Use `run-mode-hooks'. | 749 | * buff-menu.el (Buffer-menu-mode): Use `run-mode-hooks'. |
| 147 | 750 | ||
| @@ -201,15 +804,14 @@ | |||
| 201 | * vc-cvs.el (vc-cvs-checkout-model): Handle the case where FILE | 804 | * vc-cvs.el (vc-cvs-checkout-model): Handle the case where FILE |
| 202 | doesn't exist. | 805 | doesn't exist. |
| 203 | 806 | ||
| 204 | * vc.el (vc-trunk-p): Add autoload cookie. The function is used | 807 | * vc.el (vc-trunk-p): Add autoload cookie. The function is used in |
| 205 | in vc-rcs.el when vc-mistrust-permissions is t, which is not the | 808 | vc-rcs.el when vc-mistrust-permissions is t, which is not the default. |
| 206 | default. | ||
| 207 | 809 | ||
| 208 | 2005-05-22 Nick Roberts <nickrob@snap.net.nz> | 810 | 2005-05-22 Nick Roberts <nickrob@snap.net.nz> |
| 209 | 811 | ||
| 210 | * emacs-lisp/bytecomp.el: Remove make-obsolete-variable for | 812 | * emacs-lisp/bytecomp.el: Remove make-obsolete-variable for |
| 211 | already deleted variables: auto-fill-hook, blink-paren-hook, | 813 | already deleted variables: auto-fill-hook, blink-paren-hook, |
| 212 | lisp-indent-hook, inhibit-local-variables, unread-command-event | 814 | lisp-indent-hook, inhibit-local-variables, unread-command-event, |
| 213 | suspend-hooks, comment-indent-hook, meta-flag, | 815 | suspend-hooks, comment-indent-hook, meta-flag, |
| 214 | before-change-function, after-change-function, | 816 | before-change-function, after-change-function, |
| 215 | font-lock-doc-string-face. | 817 | font-lock-doc-string-face. |
| @@ -451,7 +1053,7 @@ | |||
| 451 | post-command-idle-delay. | 1053 | post-command-idle-delay. |
| 452 | 1054 | ||
| 453 | * faces.el (list-faces-display): Provide button when describe-face | 1055 | * faces.el (list-faces-display): Provide button when describe-face |
| 454 | is called to take user back to the list of faces. | 1056 | is called to take user back to the list of faces. |
| 455 | 1057 | ||
| 456 | * help-fns.el (describe-variable): Remove hyperlinks in a | 1058 | * help-fns.el (describe-variable): Remove hyperlinks in a |
| 457 | variable's value as these are quite frequently inappropriate. | 1059 | variable's value as these are quite frequently inappropriate. |
| @@ -721,8 +1323,8 @@ | |||
| 721 | 1323 | ||
| 722 | * progmodes/compile.el (compilation-setup): Set local value of | 1324 | * progmodes/compile.el (compilation-setup): Set local value of |
| 723 | overlay-arrow-string to "" always. | 1325 | overlay-arrow-string to "" always. |
| 724 | (compilation-set-window): Left fringe then don't scroll. No left | 1326 | (compilation-set-window): Left fringe then don't scroll. |
| 725 | fringe then no arrow and scroll message to top. | 1327 | No left fringe then no arrow and scroll message to top. |
| 726 | (compilation-context-lines): Adjust doc string accordingly. | 1328 | (compilation-context-lines): Adjust doc string accordingly. |
| 727 | 1329 | ||
| 728 | 2005-05-16 Kim F. Storm <storm@cua.dk> | 1330 | 2005-05-16 Kim F. Storm <storm@cua.dk> |
| @@ -981,7 +1583,7 @@ | |||
| 981 | 1583 | ||
| 982 | 2005-05-11 Stefan Monnier <monnier@iro.umontreal.ca> | 1584 | 2005-05-11 Stefan Monnier <monnier@iro.umontreal.ca> |
| 983 | 1585 | ||
| 984 | * files.el (executable-find): Move from executable.el. Use locate-file. | 1586 | * files.el (executable-find): Move from executable.el. Use locate-file. |
| 985 | * progmodes/executable.el (executable-find): Move to files.el. | 1587 | * progmodes/executable.el (executable-find): Move to files.el. |
| 986 | 1588 | ||
| 987 | * font-lock.el (font-lock-fontify-keywords-region): Use a marker | 1589 | * font-lock.el (font-lock-fontify-keywords-region): Use a marker |
| @@ -1031,10 +1633,10 @@ | |||
| 1031 | 1633 | ||
| 1032 | * progmodes/gdb-ui.el (gdb-macro-info): New variable. | 1634 | * progmodes/gdb-ui.el (gdb-macro-info): New variable. |
| 1033 | (gdb-source-info): Check for preprocessor info. | 1635 | (gdb-source-info): Check for preprocessor info. |
| 1034 | (gdb-tooltip-print-1): New function. Don't print tooltip if it is | 1636 | (gdb-tooltip-print-1): New function. Don't print tooltip if it is |
| 1035 | a macro for a function. | 1637 | a macro for a function. |
| 1036 | found (user might have used GDB dir command). | ||
| 1037 | (gdb-info-breakpoints-custom): Try to find file again if not already | 1638 | (gdb-info-breakpoints-custom): Try to find file again if not already |
| 1639 | found (user might have used GDB dir command). | ||
| 1038 | (gdb-get-location): Update gdb-location-alist correctly for change | 1640 | (gdb-get-location): Update gdb-location-alist correctly for change |
| 1039 | to gdb-info-breakpoints-custom. | 1641 | to gdb-info-breakpoints-custom. |
| 1040 | 1642 | ||
| @@ -1130,7 +1732,7 @@ | |||
| 1130 | * tooltip.el: Move code for GUD tooltips into gud.el. | 1732 | * tooltip.el: Move code for GUD tooltips into gud.el. |
| 1131 | (require): CL no longer needed to compile case. | 1733 | (require): CL no longer needed to compile case. |
| 1132 | (tooltip-mode): Do not toggle functions for GUD tooltips. | 1734 | (tooltip-mode): Do not toggle functions for GUD tooltips. |
| 1133 | (tooltip-gud-tips-p): Remove. Replace with minor mode | 1735 | (tooltip-gud-tips-p): Remove. Replace with minor mode |
| 1134 | gud-tooltip-mode in gud.el. | 1736 | gud-tooltip-mode in gud.el. |
| 1135 | (tooltip-gud-modes, tooltip-gud-display, tooltip-gud-echo-area) | 1737 | (tooltip-gud-modes, tooltip-gud-display, tooltip-gud-echo-area) |
| 1136 | (tooltip-gud-toggle-dereference): Rename in gud.el by replacing | 1738 | (tooltip-gud-toggle-dereference): Rename in gud.el by replacing |
| @@ -1142,14 +1744,14 @@ | |||
| 1142 | (tooltip-gud-original-filter, tooltip-gud-dereference) | 1744 | (tooltip-gud-original-filter, tooltip-gud-dereference) |
| 1143 | (tooltip-gud-event, tooltip-toggle-gud-tips) | 1745 | (tooltip-gud-event, tooltip-toggle-gud-tips) |
| 1144 | (tooltip-gud-process-output, tooltip-gud-print-command) | 1746 | (tooltip-gud-process-output, tooltip-gud-print-command) |
| 1145 | (tooltip-gud-tips): GUD tooltip functions/variables. Rename in | 1747 | (tooltip-gud-tips): GUD tooltip functions/variables. Rename in |
| 1146 | gud.el by replacing tooltip-gud prefix with gud-tooltip. | 1748 | gud.el by replacing tooltip-gud prefix with gud-tooltip. |
| 1147 | (gdb-tooltip-print): Move to gdb-ui.el. | 1749 | (gdb-tooltip-print): Move to gdb-ui.el. |
| 1148 | 1750 | ||
| 1149 | * progmodes/gud.el: Move code for GUD tooltips from tooltip.el. | 1751 | * progmodes/gud.el: Move code for GUD tooltips from tooltip.el. |
| 1150 | (require): CL needed to compile case. | 1752 | (require): CL needed to compile case. |
| 1151 | (gud-tooltip-mode): Use to toggle GUD tooltips unstead of | 1753 | (gud-tooltip-mode): Use to toggle GUD tooltips unstead of |
| 1152 | tooltip-gud-tips-p. Make it a minor-mode. | 1754 | tooltip-gud-tips-p. Make it a minor-mode. |
| 1153 | (gud-find-file): Only prepare GUD tooltips if gud-tooltip-mode is t. | 1755 | (gud-find-file): Only prepare GUD tooltips if gud-tooltip-mode is t. |
| 1154 | (gud-menu-map): GUD tooltips use gud-tooltip-mode now. | 1756 | (gud-menu-map): GUD tooltips use gud-tooltip-mode now. |
| 1155 | (gud-tooltip-modes, gud-tooltip-display, gud-tooltip-echo-area) | 1757 | (gud-tooltip-modes, gud-tooltip-display, gud-tooltip-echo-area) |
| @@ -1245,7 +1847,7 @@ | |||
| 1245 | * ido.el (ido-setup-hook): New hook. | 1847 | * ido.el (ido-setup-hook): New hook. |
| 1246 | (ido-define-mode-map-hook): Remove hook; use ido-setup-hook instead. | 1848 | (ido-define-mode-map-hook): Remove hook; use ido-setup-hook instead. |
| 1247 | (ido-input-stack): New var. | 1849 | (ido-input-stack): New var. |
| 1248 | (ido-define-mode-map): Bind M-b to ido-push-dir. Move old | 1850 | (ido-define-mode-map): Bind M-b to ido-push-dir. Move old |
| 1249 | ido-next-work-file binding to M-O. | 1851 | ido-next-work-file binding to M-O. |
| 1250 | Bind M-f to ido-wide-find-file-or-pop-dir. | 1852 | Bind M-f to ido-wide-find-file-or-pop-dir. |
| 1251 | (ido-define-mode-map): Don't run ido-define-mode-map-hook. | 1853 | (ido-define-mode-map): Don't run ido-define-mode-map-hook. |
| @@ -1338,7 +1940,7 @@ | |||
| 1338 | (gdb-set-gud-minor-mode-1): Handle gdb-define-alist. | 1940 | (gdb-set-gud-minor-mode-1): Handle gdb-define-alist. |
| 1339 | (gdb-source, gdb-memory-set-repeat-count): Replace string-to-int | 1941 | (gdb-source, gdb-memory-set-repeat-count): Replace string-to-int |
| 1340 | with string-to-number. | 1942 | with string-to-number. |
| 1341 | (gdb-reset): Kill gdb-define-alist. Move assignments outside loop. | 1943 | (gdb-reset): Kill gdb-define-alist. Move assignments outside loop. |
| 1342 | 1944 | ||
| 1343 | * progmodes/gud.el: Replace string-to-int with string-to-number. | 1945 | * progmodes/gud.el: Replace string-to-int with string-to-number. |
| 1344 | (gud-find-file): Handle gdb-define-alist. | 1946 | (gud-find-file): Handle gdb-define-alist. |
| @@ -1384,7 +1986,7 @@ | |||
| 1384 | move to cc-vars.el. | 1986 | move to cc-vars.el. |
| 1385 | 1987 | ||
| 1386 | * progmodes/cc-vars.el (cc-define-list-program): | 1988 | * progmodes/cc-vars.el (cc-define-list-program): |
| 1387 | Change to "gcc -E -dM -". Make customizable. | 1989 | Change to "gcc -E -dM -". Make customizable. |
| 1388 | 1990 | ||
| 1389 | 2005-05-02 Kim F. Storm <storm@cua.dk> | 1991 | 2005-05-02 Kim F. Storm <storm@cua.dk> |
| 1390 | 1992 | ||
| @@ -1435,7 +2037,7 @@ | |||
| 1435 | * subr.el (dot, dot-marker, dot-min, dot-max, buffer-flush-undo) | 2037 | * subr.el (dot, dot-marker, dot-min, dot-max, buffer-flush-undo) |
| 1436 | (compiled-function-p, focus-frame, unfocus-frame): | 2038 | (compiled-function-p, focus-frame, unfocus-frame): |
| 1437 | Remove aliases and obsolete declarations. | 2039 | Remove aliases and obsolete declarations. |
| 1438 | Back out inadvertant changes from previous commit. | 2040 | Back out inadvertent changes from previous commit. |
| 1439 | 2041 | ||
| 1440 | 2005-05-01 Luc Teirlinck <teirllm@auburn.edu> | 2042 | 2005-05-01 Luc Teirlinck <teirllm@auburn.edu> |
| 1441 | 2043 | ||
| @@ -1490,7 +2092,7 @@ | |||
| 1490 | 2005-04-30 Nick Roberts <nickrob@snap.net.nz> | 2092 | 2005-04-30 Nick Roberts <nickrob@snap.net.nz> |
| 1491 | 2093 | ||
| 1492 | * progmodes/cc-mode.el (cc-create-define-alist): Check that file | 2094 | * progmodes/cc-mode.el (cc-create-define-alist): Check that file |
| 1493 | exists. Initialise cc-define-alist. | 2095 | exists. Initialise cc-define-alist. |
| 1494 | (c-mode): Add cc-create-define-alist locally to after-save-hook. | 2096 | (c-mode): Add cc-create-define-alist locally to after-save-hook. |
| 1495 | If there is no file (Macroexpansion) don't create an alist. | 2097 | If there is no file (Macroexpansion) don't create an alist. |
| 1496 | 2098 | ||
| @@ -1580,7 +2182,7 @@ | |||
| 1580 | 2182 | ||
| 1581 | 2005-04-28 Nick Roberts <nickrob@snap.net.nz> | 2183 | 2005-04-28 Nick Roberts <nickrob@snap.net.nz> |
| 1582 | 2184 | ||
| 1583 | * progmodes/cc-mode.el: (cc-create-define-alist): New function. | 2185 | * progmodes/cc-mode.el (cc-create-define-alist): New function. |
| 1584 | (cc-define-alist): New variable. | 2186 | (cc-define-alist): New variable. |
| 1585 | (c-mode): Make it local and initialise it. | 2187 | (c-mode): Make it local and initialise it. |
| 1586 | 2188 | ||
| @@ -1709,7 +2311,7 @@ | |||
| 1709 | 2005-04-25 Dan Nicolaescu <dann@ics.uci.edu> | 2311 | 2005-04-25 Dan Nicolaescu <dann@ics.uci.edu> |
| 1710 | 2312 | ||
| 1711 | * term.el (ansi-term-color-vector): Use the xterm colors. | 2313 | * term.el (ansi-term-color-vector): Use the xterm colors. |
| 1712 | (term-raw-map): Don't add mappings for \eO and \e[. Map deletechar. | 2314 | (term-raw-map): Don't add mappings for \eO and \e[. Map deletechar. |
| 1713 | 2315 | ||
| 1714 | 2005-04-25 Lute Kamstra <lute@gnu.org> | 2316 | 2005-04-25 Lute Kamstra <lute@gnu.org> |
| 1715 | 2317 | ||
| @@ -2731,13 +3333,13 @@ | |||
| 2731 | * add-log.el (change-log-font-lock-keywords): The manual | 3333 | * add-log.el (change-log-font-lock-keywords): The manual |
| 2732 | describing a Change Log entry, says: (...) "Aside from these | 3334 | describing a Change Log entry, says: (...) "Aside from these |
| 2733 | header lines, every line in the change log starts with a space or | 3335 | header lines, every line in the change log starts with a space or |
| 2734 | a tab.". The font-lock was not highlighting lines started with | 3336 | a tab.". The font-lock was not highlighting lines started with |
| 2735 | spaces, added support for it. | 3337 | spaces, added support for it. |
| 2736 | 3338 | ||
| 2737 | 2005-04-03 Roland Winkler <Roland.Winkler@physik.uni-erlangen.de> | 3339 | 2005-04-03 Roland Winkler <Roland.Winkler@physik.uni-erlangen.de> |
| 2738 | 3340 | ||
| 2739 | * textmodes/bibtex.el (bibtex-url): Use format to generate the url. | 3341 | * textmodes/bibtex.el (bibtex-url): Use format to generate the url. |
| 2740 | (bibtex-generate-url-list): Update docstring accordingly. Put the | 3342 | (bibtex-generate-url-list): Update docstring accordingly. Put the |
| 2741 | complex example in the docstring. | 3343 | complex example in the docstring. |
| 2742 | (bibtex-font-lock-url): Use pop. | 3344 | (bibtex-font-lock-url): Use pop. |
| 2743 | 3345 | ||
| @@ -2770,7 +3372,7 @@ | |||
| 2770 | 3372 | ||
| 2771 | 2005-04-02 Sergey Poznyakoff <gray@Mirddin.farlep.net> (tiny change) | 3373 | 2005-04-02 Sergey Poznyakoff <gray@Mirddin.farlep.net> (tiny change) |
| 2772 | 3374 | ||
| 2773 | * mail/rmail.el (rmail-parse-url): Bugfix. Parse traditional | 3375 | * mail/rmail.el (rmail-parse-url): Bugfix. Parse traditional |
| 2774 | mailbox specifications as well as URLs. | 3376 | mailbox specifications as well as URLs. |
| 2775 | (rmail-insert-inbox-text): Remove unused conditional branches. | 3377 | (rmail-insert-inbox-text): Remove unused conditional branches. |
| 2776 | 3378 | ||
| @@ -2872,12 +3474,7 @@ | |||
| 2872 | (fill-newline): Use fill-text-properties-at instead of | 3474 | (fill-newline): Use fill-text-properties-at instead of |
| 2873 | text-properties-at. | 3475 | text-properties-at. |
| 2874 | 3476 | ||
| 2875 | 2005-03-31 Karl Berry <karl@freefriends.org> | 3477 | 2005-03-31 Olive Lin <olive.lin@versateladsl.be> (tiny change) |
| 2876 | |||
| 2877 | * textmodes/tex-mode.el (tex-compile): Use shell-quote-argument, | ||
| 2878 | not comint-quote-filename. | ||
| 2879 | |||
| 2880 | 2005-03-31 Olive Lin <olive.lin@versateladsl.be> (tiny change) | ||
| 2881 | 3478 | ||
| 2882 | * textmodes/tex-mode.el (tex-start-tex) Use shell-quote-argument, | 3479 | * textmodes/tex-mode.el (tex-start-tex) Use shell-quote-argument, |
| 2883 | not comint-quote-filename. | 3480 | not comint-quote-filename. |
| @@ -3016,12 +3613,12 @@ | |||
| 3016 | (hs-special-modes-alist): Add a Fortran entry. | 3613 | (hs-special-modes-alist): Add a Fortran entry. |
| 3017 | (fortran-mode-map): Bind fortran-end-of-block, | 3614 | (fortran-mode-map): Bind fortran-end-of-block, |
| 3018 | fortran-beginning-of-block to \M-\C-n, \M-\C-p. | 3615 | fortran-beginning-of-block to \M-\C-n, \M-\C-p. |
| 3019 | (fortran-mode): Doc fix. Add fortran-font-lock-keywords-4. | 3616 | (fortran-mode): Doc fix. Add fortran-font-lock-keywords-4. |
| 3020 | (fortran-looking-at-if-then, fortran-end-of-block) | 3617 | (fortran-looking-at-if-then, fortran-end-of-block) |
| 3021 | (fortran-beginning-of-block): New functions, for hideshow. | 3618 | (fortran-beginning-of-block): New functions, for hideshow. |
| 3022 | 3619 | ||
| 3023 | * progmodes/f90.el (f90-end-block-re, f90-start-block-re): Doc | 3620 | * progmodes/f90.el (f90-end-block-re, f90-start-block-re): |
| 3024 | fix. Tweak regexp. | 3621 | Doc fix. Tweak regexp. |
| 3025 | (f90-beginning-of-block): Push mark first. | 3622 | (f90-beginning-of-block): Push mark first. |
| 3026 | 3623 | ||
| 3027 | 2005-03-29 Jay Belanger <belanger@truman.edu> | 3624 | 2005-03-29 Jay Belanger <belanger@truman.edu> |
| @@ -3039,7 +3636,7 @@ | |||
| 3039 | * vc.el (vc-do-command): Use a pipe for async processes, so password | 3636 | * vc.el (vc-do-command): Use a pipe for async processes, so password |
| 3040 | prompts don't show up at places where the user can't reply. | 3637 | prompts don't show up at places where the user can't reply. |
| 3041 | 3638 | ||
| 3042 | 2005-03-29 Olive Lin <olive.lin@versateladsl.be> (tiny change) | 3639 | 2005-03-29 Olive Lin <olive.lin@versateladsl.be> (tiny change) |
| 3043 | 3640 | ||
| 3044 | * textmodes/tex-mode.el (tex-send-command): shell-quote-argument | 3641 | * textmodes/tex-mode.el (tex-send-command): shell-quote-argument |
| 3045 | on the file name we pass to the inferior shell. | 3642 | on the file name we pass to the inferior shell. |
| @@ -3269,11 +3866,11 @@ | |||
| 3269 | * calendar/calendar.el: Replace `legal' with `valid'. | 3866 | * calendar/calendar.el: Replace `legal' with `valid'. |
| 3270 | * emacs-lisp/advice.el: Replace `legal' with `valid'. | 3867 | * emacs-lisp/advice.el: Replace `legal' with `valid'. |
| 3271 | * mail/supercite.el: Replace `legal' with `valid'. | 3868 | * mail/supercite.el: Replace `legal' with `valid'. |
| 3272 | * progmodes/cperl-mode.el, progmodes/idlw-shell.el, | 3869 | * progmodes/cperl-mode.el, progmodes/idlw-shell.el |
| 3273 | progmodes/idlwave.el, progmodes/vhdl-mode.el: Replace `legal' with | 3870 | * progmodes/idlwave.el, progmodes/vhdl-mode.el: |
| 3274 | `valid'. | 3871 | Replace `legal' with `valid'. |
| 3275 | * textmodes/reftex-vars.el, textmodes/reftex.el: Replace `legal' | 3872 | * textmodes/reftex-vars.el, textmodes/reftex.el: |
| 3276 | with `valid'. | 3873 | Replace `legal' with `valid'. |
| 3277 | 3874 | ||
| 3278 | 2005-03-25 Werner Lemberg <wl@gnu.org> | 3875 | 2005-03-25 Werner Lemberg <wl@gnu.org> |
| 3279 | 3876 | ||
| @@ -3283,15 +3880,15 @@ | |||
| 3283 | * emulation/vip.el: Replace `illegal' with `invalid'. | 3880 | * emulation/vip.el: Replace `illegal' with `invalid'. |
| 3284 | * eshell/esh-io.el, eshell/esh-var.el: Replace `illegal' with `invalid'. | 3881 | * eshell/esh-io.el, eshell/esh-var.el: Replace `illegal' with `invalid'. |
| 3285 | * mail/supercite.el: Replace `illegal' with `invalid'. | 3882 | * mail/supercite.el: Replace `illegal' with `invalid'. |
| 3286 | * progmodes/ebnf-abn.el, progmodes/ebnf-bnf.el, | 3883 | * progmodes/ebnf-abn.el, progmodes/ebnf-bnf.el |
| 3287 | progmodes/ebnf-ebx.el, progmodes/ebnf-dtd.el, progmodes/ebnf-iso.el, | 3884 | * progmodes/ebnf-ebx.el, progmodes/ebnf-dtd.el, progmodes/ebnf-iso.el |
| 3288 | progmodes/ebnf-yac.el, progmodes/ebnf2ps.el, progmodes/idlwave.el, | 3885 | * progmodes/ebnf-yac.el, progmodes/ebnf2ps.el, progmodes/idlwave.el |
| 3289 | progmodes/sh-script.el, progmodes/xscheme.el: Replace `illegal' with | 3886 | * progmodes/sh-script.el, progmodes/xscheme.el: |
| 3290 | `invalid'. | 3887 | Replace `illegal' with `invalid'. |
| 3291 | * textmodes/refbib.el, textmodes/refer.el, textmodes/reftex-cite.el, | 3888 | * textmodes/refbib.el, textmodes/refer.el, textmodes/reftex-cite.el |
| 3292 | textmodes/reftex-index.el, textmodes/reftex-parse.el, | 3889 | * textmodes/reftex-index.el, textmodes/reftex-parse.el |
| 3293 | textmodes/reftex-ref.el, textmodes/reftex-vars.el, | 3890 | * textmodes/reftex-ref.el, textmodes/reftex-vars.el |
| 3294 | textmodes/reftex.el, textmodes/org.el: Replace `illegal' with `invalid'. | 3891 | * textmodes/reftex.el, textmodes/org.el: Replace `illegal' with `invalid'. |
| 3295 | 3892 | ||
| 3296 | 2005-03-24 Stefan Monnier <monnier@iro.umontreal.ca> | 3893 | 2005-03-24 Stefan Monnier <monnier@iro.umontreal.ca> |
| 3297 | 3894 | ||
| @@ -3412,11 +4009,11 @@ | |||
| 3412 | (recentf-include-p): More robust. | 4009 | (recentf-include-p): More robust. |
| 3413 | (recentf-keep-p): New function. | 4010 | (recentf-keep-p): New function. |
| 3414 | (recentf-remove-if-non-kept): Rename from | 4011 | (recentf-remove-if-non-kept): Rename from |
| 3415 | `recentf-remove-if-non-readable'. Use `recentf-keep-p'. | 4012 | `recentf-remove-if-non-readable'. Use `recentf-keep-p'. |
| 3416 | All callers updated. | 4013 | All callers updated. |
| 3417 | (recentf-menu-items-for-commands): Fix help string. | 4014 | (recentf-menu-items-for-commands): Fix help string. |
| 3418 | (recentf-track-closed-file): Update. Doc fix. | 4015 | (recentf-track-closed-file): Update. Doc fix. |
| 3419 | (recentf-cleanup): Update. Count removed files. Doc fix. | 4016 | (recentf-cleanup): Update. Count removed files. Doc fix. |
| 3420 | 4017 | ||
| 3421 | 2005-03-23 Kim F. Storm <storm@cua.dk> | 4018 | 2005-03-23 Kim F. Storm <storm@cua.dk> |
| 3422 | 4019 | ||
| @@ -4132,7 +4729,7 @@ | |||
| 4132 | 4729 | ||
| 4133 | * files.el (mode-require-final-newline): Doc fix. | 4730 | * files.el (mode-require-final-newline): Doc fix. |
| 4134 | 4731 | ||
| 4135 | 2005-03-03 Stephan Stahl <stahl@eos.franken.de> (tiny change) | 4732 | 2005-03-03 Stephan Stahl <stahl@eos.franken.de> (tiny change) |
| 4136 | 4733 | ||
| 4137 | * progmodes/which-func.el (which-function): | 4734 | * progmodes/which-func.el (which-function): |
| 4138 | Specify NOERROR when calling imenu--make-index-alist. | 4735 | Specify NOERROR when calling imenu--make-index-alist. |
| @@ -4727,7 +5324,7 @@ | |||
| 4727 | * progmodes/gdb-ui.el (gdb-find-file-unhook): New variable. | 5324 | * progmodes/gdb-ui.el (gdb-find-file-unhook): New variable. |
| 4728 | (gdb-set-gud-minor-mode, gdb-set-gud-minor-mode-1) | 5325 | (gdb-set-gud-minor-mode, gdb-set-gud-minor-mode-1) |
| 4729 | (gdb-set-gud-minor-mode-existing-buffers): New functions. | 5326 | (gdb-set-gud-minor-mode-existing-buffers): New functions. |
| 4730 | (gdb-find-file-hook): New hook. Add it to find-file-hook. | 5327 | (gdb-find-file-hook): New hook. Add it to find-file-hook. |
| 4731 | (gdb-info-breakpoints-custom, gdb-source-info): Simplify. | 5328 | (gdb-info-breakpoints-custom, gdb-source-info): Simplify. |
| 4732 | 5329 | ||
| 4733 | 2005-02-14 Luc Teirlinck <teirllm@auburn.edu> | 5330 | 2005-02-14 Luc Teirlinck <teirllm@auburn.edu> |
| @@ -4891,13 +5488,13 @@ | |||
| 4891 | 5488 | ||
| 4892 | 2005-02-05 Nick Roberts <nickrob@snap.net.nz> | 5489 | 2005-02-05 Nick Roberts <nickrob@snap.net.nz> |
| 4893 | 5490 | ||
| 4894 | * progmodes/gdb-ui.el: Update copyright. Put GDB-Frames before | 5491 | * progmodes/gdb-ui.el: Update copyright. Put GDB-Frames before |
| 4895 | GDB-Windows on the menu-bar as this works better. | 5492 | GDB-Windows on the menu-bar as this works better. |
| 4896 | 5493 | ||
| 4897 | 2005-02-04 Jay Belanger <belanger@truman.edu> | 5494 | 2005-02-04 Jay Belanger <belanger@truman.edu> |
| 4898 | 5495 | ||
| 4899 | * calc/calc-embed.el (calc-embedded-update): Don't put in | 5496 | * calc/calc-embed.el (calc-embedded-update): Don't put in |
| 4900 | unnecessary newlines. Adjust the end of formula marker. | 5497 | unnecessary newlines. Adjust the end of formula marker. |
| 4901 | 5498 | ||
| 4902 | * calc/calc-lang.el (math-latex-parse-frac): Don't use arguments. | 5499 | * calc/calc-lang.el (math-latex-parse-frac): Don't use arguments. |
| 4903 | (math-latex-parse-two-args): New function. | 5500 | (math-latex-parse-two-args): New function. |
| @@ -4959,7 +5556,7 @@ | |||
| 4959 | 5556 | ||
| 4960 | 2005-02-02 Nick Roberts <nickrob@snap.net.nz> | 5557 | 2005-02-02 Nick Roberts <nickrob@snap.net.nz> |
| 4961 | 5558 | ||
| 4962 | * progmodes/gdb-ui.el: (gdb-goto-info): Delete. | 5559 | * progmodes/gdb-ui.el (gdb-goto-info): Delete. |
| 4963 | 5560 | ||
| 4964 | * progmodes/gud.el (gud-goto-info): New function. | 5561 | * progmodes/gud.el (gud-goto-info): New function. |
| 4965 | (gud-tool-bar-map): Use correct icon. | 5562 | (gud-tool-bar-map): Use correct icon. |
| @@ -5667,8 +6264,8 @@ | |||
| 5667 | 6264 | ||
| 5668 | 2005-01-11 Juri Linkov <juri@jurta.org> | 6265 | 2005-01-11 Juri Linkov <juri@jurta.org> |
| 5669 | 6266 | ||
| 5670 | * toolbar/back_arrow.xpm, toolbar/back_arrow.pbm, | 6267 | * toolbar/back_arrow.xpm, toolbar/back_arrow.pbm |
| 5671 | * toolbar/lc-back_arrow.xpm, toolbar/lc-fwd_arrow.xpm, | 6268 | * toolbar/lc-back_arrow.xpm, toolbar/lc-fwd_arrow.xpm |
| 5672 | * toolbar/fwd_arrow.xpm, toolbar/fwd_arrow.pbm: New icons. | 6269 | * toolbar/fwd_arrow.xpm, toolbar/fwd_arrow.pbm: New icons. |
| 5673 | 6270 | ||
| 5674 | * info.el (Info-history-forward): New variable. | 6271 | * info.el (Info-history-forward): New variable. |
| @@ -6392,7 +6989,7 @@ | |||
| 6392 | 6989 | ||
| 6393 | 2004-12-21 Eli Barzilay <eli@barzilay.org> | 6990 | 2004-12-21 Eli Barzilay <eli@barzilay.org> |
| 6394 | 6991 | ||
| 6395 | * calculator.el: (calculator-radix-grouping-mode) | 6992 | * calculator.el (calculator-radix-grouping-mode) |
| 6396 | (calculator-radix-grouping-digits) | 6993 | (calculator-radix-grouping-digits) |
| 6397 | (calculator-radix-grouping-separator): | 6994 | (calculator-radix-grouping-separator): |
| 6398 | New defcustoms for the new radix grouping mode functionality. | 6995 | New defcustoms for the new radix grouping mode functionality. |
| @@ -6593,11 +7190,11 @@ | |||
| 6593 | (zone-replace-char): New defsubst. | 7190 | (zone-replace-char): New defsubst. |
| 6594 | (zone-park/sit-for): Likewise. | 7191 | (zone-park/sit-for): Likewise. |
| 6595 | (zone-fret): Take window-start arg. | 7192 | (zone-fret): Take window-start arg. |
| 6596 | Update callers. Use `zone-park/sit-for'. | 7193 | Update callers. Use `zone-park/sit-for'. |
| 6597 | (zone-fill-out-screen): Rewrite. | 7194 | (zone-fill-out-screen): Rewrite. |
| 6598 | (zone-fall-through-ws): Likewise. Update callers. | 7195 | (zone-fall-through-ws): Likewise. Update callers. |
| 6599 | (zone-pgm-drip): Use `zone-replace-char'. | 7196 | (zone-pgm-drip): Use `zone-replace-char'. |
| 6600 | Move var inits before while-loop. Use `zone-park/sit-for'. | 7197 | Move var inits before while-loop. Use `zone-park/sit-for'. |
| 6601 | (zone-pgm-random-life): Handle empty initial field. | 7198 | (zone-pgm-random-life): Handle empty initial field. |
| 6602 | Use `zone-replace-char' and `zone-park/sit-for'. | 7199 | Use `zone-replace-char' and `zone-park/sit-for'. |
| 6603 | 7200 | ||
| @@ -7438,16 +8035,16 @@ | |||
| 7438 | (tramp-file-name-handler-alist): Delete file-directory-files, add | 8035 | (tramp-file-name-handler-alist): Delete file-directory-files, add |
| 7439 | directory-files-and-attributes. | 8036 | directory-files-and-attributes. |
| 7440 | (tramp-perl-file-attributes): Surround uid and gid by double | 8037 | (tramp-perl-file-attributes): Surround uid and gid by double |
| 7441 | quotes. Change parameter id-format from nonnumeric. | 8038 | quotes. Change parameter id-format from nonnumeric. |
| 7442 | (tramp-convert-file-attributes): New function. | 8039 | (tramp-convert-file-attributes): New function. |
| 7443 | (tramp-handle-file-attributes): Use it. | 8040 | (tramp-handle-file-attributes): Use it. |
| 7444 | (tramp-maybe-send-perl-script): New function. | 8041 | (tramp-maybe-send-perl-script): New function. |
| 7445 | (tramp-handle-file-attributes-with-perl): Use it. Don't convert | 8042 | (tramp-handle-file-attributes-with-perl): Use it. Don't convert |
| 7446 | file mode. Change parameter id-format from nonnumeric. | 8043 | file mode. Change parameter id-format from nonnumeric. |
| 7447 | (tramp-handle-file-attributes-with-ls): Change parameter id-format | 8044 | (tramp-handle-file-attributes-with-ls): Change parameter id-format |
| 7448 | from nonnumeric. | 8045 | from nonnumeric. |
| 7449 | (tramp-post-connection): Don't send tramp-perl-file-attributes | 8046 | (tramp-post-connection): Don't send tramp-perl-file-attributes |
| 7450 | script. Reset connection property "perl-scripts". | 8047 | script. Reset connection property "perl-scripts". |
| 7451 | (tramp-handle-insert-directory): Run real handler when ls-lisp is | 8048 | (tramp-handle-insert-directory): Run real handler when ls-lisp is |
| 7452 | in use. | 8049 | in use. |
| 7453 | 8050 | ||
| @@ -7470,7 +8067,7 @@ | |||
| 7470 | (gdb-view-source-function, gdb-view-assembler): Delete functions. | 8067 | (gdb-view-source-function, gdb-view-assembler): Delete functions. |
| 7471 | (menu): Delete menu bindings for viewing source/assembler. | 8068 | (menu): Delete menu bindings for viewing source/assembler. |
| 7472 | (gdb-setup-windows, gdb-restore-windows): | 8069 | (gdb-setup-windows, gdb-restore-windows): |
| 7473 | Don't dedicate GUD. No assembler now. | 8070 | Don't dedicate GUD. No assembler now. |
| 7474 | (gdb-reset): No need to undedicate source buffers now. | 8071 | (gdb-reset): No need to undedicate source buffers now. |
| 7475 | (gdb-source-info): No assembler now. | 8072 | (gdb-source-info): No assembler now. |
| 7476 | 8073 | ||
| @@ -7597,7 +8194,7 @@ | |||
| 7597 | (gdb-var-evaluate-expression-handler, gdb-put-string): | 8194 | (gdb-var-evaluate-expression-handler, gdb-put-string): |
| 7598 | Remove unused variable bindings. | 8195 | Remove unused variable bindings. |
| 7599 | (gdb-setup-windows, gdb-display-buffer): | 8196 | (gdb-setup-windows, gdb-display-buffer): |
| 7600 | Simplify. Use pop-to-buffer. | 8197 | Simplify. Use pop-to-buffer. |
| 7601 | (gdb-view-source-function): Simplify. | 8198 | (gdb-view-source-function): Simplify. |
| 7602 | (gdb-frame-breakpoints-buffer): | 8199 | (gdb-frame-breakpoints-buffer): |
| 7603 | Use pop-to-buffer, special-display-regexps. | 8200 | Use pop-to-buffer, special-display-regexps. |
| @@ -7681,8 +8278,8 @@ | |||
| 7681 | * progmodes/gdb-ui.el (dedicated-switch-to-buffer): New function. | 8278 | * progmodes/gdb-ui.el (dedicated-switch-to-buffer): New function. |
| 7682 | (gdb-ann3, gdb-setup-windows, gdb-restore-windows): | 8279 | (gdb-ann3, gdb-setup-windows, gdb-restore-windows): |
| 7683 | Dedicate gdb-related windows. | 8280 | Dedicate gdb-related windows. |
| 7684 | (gdb-display-buffer): Dedicate gdb-related windows. Don't grab | 8281 | (gdb-display-buffer): Dedicate gdb-related windows. |
| 7685 | other frames. | 8282 | Don't grab other frames. |
| 7686 | (gdb-reset): Remove dedicated property after debugging. | 8283 | (gdb-reset): Remove dedicated property after debugging. |
| 7687 | 8284 | ||
| 7688 | 2004-11-24 Jay Belanger <belanger@truman.edu> | 8285 | 2004-11-24 Jay Belanger <belanger@truman.edu> |
| @@ -8548,8 +9145,8 @@ | |||
| 8548 | 9145 | ||
| 8549 | 2004-11-10 Nick Roberts <nickrob@snap.net.nz> | 9146 | 2004-11-10 Nick Roberts <nickrob@snap.net.nz> |
| 8550 | 9147 | ||
| 8551 | * tooltip.el: Don't require cl, comint, gud, gdb-ui for | 9148 | * tooltip.el: Don't require cl, comint, gud, gdb-ui for compilation. |
| 8552 | compilation. The resulting compiler warnings appear to be harmless. | 9149 | The resulting compiler warnings appear to be harmless. |
| 8553 | 9150 | ||
| 8554 | 2004-11-10 Daniel Pfeiffer <occitan@esperanto.org> | 9151 | 2004-11-10 Daniel Pfeiffer <occitan@esperanto.org> |
| 8555 | 9152 | ||
| @@ -9772,7 +10369,7 @@ | |||
| 9772 | * kmacro.el (kmacro-insert-counter, kmacro-add-counter): Use and | 10369 | * kmacro.el (kmacro-insert-counter, kmacro-add-counter): Use and |
| 9773 | reset kmacro-initial-counter-value if set. | 10370 | reset kmacro-initial-counter-value if set. |
| 9774 | (kmacro-set-counter): Only set kmacro-counter if defining or executing | 10371 | (kmacro-set-counter): Only set kmacro-counter if defining or executing |
| 9775 | macro. Set kmacro-initial-counter-value otherwise. Never set both. | 10372 | macro. Set kmacro-initial-counter-value otherwise. Never set both. |
| 9776 | (kmacro-display): Show macro counter if non-zero. | 10373 | (kmacro-display): Show macro counter if non-zero. |
| 9777 | 10374 | ||
| 9778 | * subr.el (substitute-key-definition): Mention command remapping | 10375 | * subr.el (substitute-key-definition): Mention command remapping |
| @@ -9959,8 +10556,8 @@ | |||
| 9959 | 10556 | ||
| 9960 | * term.el (term-adjust-current-row-cache): Don't allow the current | 10557 | * term.el (term-adjust-current-row-cache): Don't allow the current |
| 9961 | row to become negative. | 10558 | row to become negative. |
| 9962 | (term-emulate-terminal): Fix insert mode. Handle tab insertion at | 10559 | (term-emulate-terminal): Fix insert mode. Handle tab insertion at |
| 9963 | the end of the line. Fix scroll down. Add comments. | 10560 | the end of the line. Fix scroll down. Add comments. |
| 9964 | (term-handle-ansi-escape): Don't exceed terminal width when moving | 10561 | (term-handle-ansi-escape): Don't exceed terminal width when moving |
| 9965 | right. | 10562 | right. |
| 9966 | (term-scroll-region): Move the cursor after setting the scroll region. | 10563 | (term-scroll-region): Move the cursor after setting the scroll region. |
| @@ -10115,7 +10712,7 @@ | |||
| 10115 | * calendar/holidays.el (holiday-advent): Report on a specified day | 10712 | * calendar/holidays.el (holiday-advent): Report on a specified day |
| 10116 | offset from advent, not just advent. | 10713 | offset from advent, not just advent. |
| 10117 | (holiday-easter-etc): Report on one specified day offset from | 10714 | (holiday-easter-etc): Report on one specified day offset from |
| 10118 | easter, not all easter holidays. Various Easter holidays moved to | 10715 | easter, not all easter holidays. Various Easter holidays moved to |
| 10119 | `christian-holidays' variable in calendar.el. | 10716 | `christian-holidays' variable in calendar.el. |
| 10120 | * calendar/calendar.el (christian-holidays): Adapt for new | 10717 | * calendar/calendar.el (christian-holidays): Adapt for new |
| 10121 | behaviour of `holiday-advent' and `holiday-easter-etc' functions. | 10718 | behaviour of `holiday-advent' and `holiday-easter-etc' functions. |
| @@ -10130,7 +10727,7 @@ | |||
| 10130 | (ido-read-internal): Handle new `list' context. | 10727 | (ido-read-internal): Handle new `list' context. |
| 10131 | Handle insert-buffer and insert-file ido-exit values. | 10728 | Handle insert-buffer and insert-file ido-exit values. |
| 10132 | (ido-buffer-internal): New arg switch-cmd. Use it to setup | 10729 | (ido-buffer-internal): New arg switch-cmd. Use it to setup |
| 10133 | ido-context-switch-command. Handle insert-file ido-exit value. | 10730 | ido-context-switch-command. Handle insert-file ido-exit value. |
| 10134 | (ido-read-buffer): Set ido-context-switch-command to 'ignore | 10731 | (ido-read-buffer): Set ido-context-switch-command to 'ignore |
| 10135 | unless it is already bound by caller. | 10732 | unless it is already bound by caller. |
| 10136 | (ido-file-internal): New arg switch-cmd. Use it to setup | 10733 | (ido-file-internal): New arg switch-cmd. Use it to setup |
| @@ -10460,7 +11057,7 @@ | |||
| 10460 | Do not call obsolete function compilation-parse-errors. | 11057 | Do not call obsolete function compilation-parse-errors. |
| 10461 | (bibtex-remove-delimiters): Only remove delimiters if present. | 11058 | (bibtex-remove-delimiters): Only remove delimiters if present. |
| 10462 | (bibtex-copy-entry-as-kill): Add docstring. | 11059 | (bibtex-copy-entry-as-kill): Add docstring. |
| 10463 | (bibtex-clean-entry): Use bibtex-string=. Handle empty keys. | 11060 | (bibtex-clean-entry): Use bibtex-string=. Handle empty keys. |
| 10464 | Detect duplicate keys if bibtex-maintain-sorted-entries is nil. | 11061 | Detect duplicate keys if bibtex-maintain-sorted-entries is nil. |
| 10465 | (bibtex-complete): Use bibtex-predefined-month-strings, | 11062 | (bibtex-complete): Use bibtex-predefined-month-strings, |
| 10466 | bibtex-string=, and new function bibtex-complete-key-cleanup. | 11063 | bibtex-string=, and new function bibtex-complete-key-cleanup. |
| @@ -11146,8 +11743,8 @@ | |||
| 11146 | when `c-opt-type-concat-key' is used (i.e. in Pike). | 11743 | when `c-opt-type-concat-key' is used (i.e. in Pike). |
| 11147 | 11744 | ||
| 11148 | * progmodes/cc-engine.el (c-looking-at-special-brace-list): | 11745 | * progmodes/cc-engine.el (c-looking-at-special-brace-list): |
| 11149 | Fix bug when the inner char pair doesn't have paren syntax, i.e. "(< | 11746 | Fix bug when the inner char pair doesn't have paren syntax, |
| 11150 | >)". | 11747 | i.e. "(<>)". |
| 11151 | 11748 | ||
| 11152 | * progmodes/cc-align.el (c-lineup-multi-inher): Made it syntactic | 11749 | * progmodes/cc-align.el (c-lineup-multi-inher): Made it syntactic |
| 11153 | whitespace safe. | 11750 | whitespace safe. |
| @@ -11227,7 +11824,7 @@ | |||
| 11227 | string. (2) Check that settings to `c-offsets-alist' are not | 11824 | string. (2) Check that settings to `c-offsets-alist' are not |
| 11228 | spuriously quoted. | 11825 | spuriously quoted. |
| 11229 | 11826 | ||
| 11230 | * progmodes/cc-cmds.el: (c-electric-brace): Don't delete a comment | 11827 | * progmodes/cc-cmds.el (c-electric-brace): Don't delete a comment |
| 11231 | which precedes the newly inserted `{'. | 11828 | which precedes the newly inserted `{'. |
| 11232 | 11829 | ||
| 11233 | 2004-08-10 Michael Albinus <michael.albinus@gmx.de> | 11830 | 2004-08-10 Michael Albinus <michael.albinus@gmx.de> |
| @@ -11880,7 +12477,7 @@ | |||
| 11880 | 12477 | ||
| 11881 | 2004-06-23 Nick Roberts <nickrob@gnu.org> | 12478 | 2004-06-23 Nick Roberts <nickrob@gnu.org> |
| 11882 | 12479 | ||
| 11883 | * comint.el: (comint-insert-clicked-input, comint-copy-old-input): | 12480 | * comint.el (comint-insert-clicked-input, comint-copy-old-input): |
| 11884 | Remove. | 12481 | Remove. |
| 11885 | (comint-insert-input, comint-mouse-insert-input): New functions | 12482 | (comint-insert-input, comint-mouse-insert-input): New functions |
| 11886 | based on comint-insert-clicked-input for two bindings but just | 12483 | based on comint-insert-clicked-input for two bindings but just |
| @@ -12391,7 +12988,7 @@ | |||
| 12391 | 12988 | ||
| 12392 | 2004-06-04 Karl Fogel <kfogel@red-bean.com> | 12989 | 2004-06-04 Karl Fogel <kfogel@red-bean.com> |
| 12393 | 12990 | ||
| 12394 | * vc-svn.el (vc-svn-checkin): Use 'nconc' instead of 'list*', | 12991 | * vc-svn.el (vc-svn-checkin): Use `nconc' instead of `list*', |
| 12395 | because the latter is a CL-ism. This fixes the bug reported by | 12992 | because the latter is a CL-ism. This fixes the bug reported by |
| 12396 | Shawn Boyette <mdxi@collapsar.net> in | 12993 | Shawn Boyette <mdxi@collapsar.net> in |
| 12397 | http://lists.gnu.org/archive/html/emacs-devel/2004-05/msg00442.html. | 12994 | http://lists.gnu.org/archive/html/emacs-devel/2004-05/msg00442.html. |
| @@ -13331,9 +13928,9 @@ | |||
| 13331 | of 19 months of 19 days, with 4 intercalary days. Each year | 13928 | of 19 months of 19 days, with 4 intercalary days. Each year |
| 13332 | begins on March 21, with the calendar starting in 1844. | 13929 | begins on March 21, with the calendar starting in 1844. |
| 13333 | 13930 | ||
| 13334 | * calendar/cal-menu.el, calendar/calendar.el, | 13931 | * calendar/cal-menu.el, calendar/calendar.el |
| 13335 | calendar/diary-lib.el, calendar/holidays.el: Added support for | 13932 | * calendar/diary-lib.el, calendar/holidays.el: |
| 13336 | using cal-bahai.el. | 13933 | Added support for using cal-bahai.el. |
| 13337 | 13934 | ||
| 13338 | * eshell/em-glob.el (eshell-glob-initialize): Move initialization | 13935 | * eshell/em-glob.el (eshell-glob-initialize): Move initialization |
| 13339 | of `eshell-glob-chars-regexp' into `eshell-glob-regexp', so that | 13936 | of `eshell-glob-chars-regexp' into `eshell-glob-regexp', so that |
| @@ -14157,7 +14754,7 @@ | |||
| 14157 | * emacs-lisp/rx.el (rx-syntax): Move sregex style syntax to code. | 14754 | * emacs-lisp/rx.el (rx-syntax): Move sregex style syntax to code. |
| 14158 | (rx-bracket, rx-check-any, rx-any): Clean up name space. | 14755 | (rx-bracket, rx-check-any, rx-any): Clean up name space. |
| 14159 | 14756 | ||
| 14160 | * wdired.el: (wdired-mode-map): Move init into declaration. | 14757 | * wdired.el (wdired-mode-map): Move init into declaration. |
| 14161 | Fix `return' binding. | 14758 | Fix `return' binding. |
| 14162 | (wdired-change-to-wdired-mode, wdired-change-to-dired-mode): | 14759 | (wdired-change-to-wdired-mode, wdired-change-to-dired-mode): |
| 14163 | Use force-mode-line-update. | 14760 | Use force-mode-line-update. |
| @@ -15700,7 +16297,7 @@ | |||
| 15700 | 16297 | ||
| 15701 | 2004-03-15 David Ponce <david@dponce.com> | 16298 | 2004-03-15 David Ponce <david@dponce.com> |
| 15702 | 16299 | ||
| 15703 | * ruler-mode.el: (ruler-mode-left-fringe-cols) | 16300 | * ruler-mode.el (ruler-mode-left-fringe-cols) |
| 15704 | (ruler-mode-right-fringe-cols, ruler-mode-left-scroll-bar-cols) | 16301 | (ruler-mode-right-fringe-cols, ruler-mode-left-scroll-bar-cols) |
| 15705 | (ruler-mode-right-scroll-bar-cols): Remove. | 16302 | (ruler-mode-right-scroll-bar-cols): Remove. |
| 15706 | (ruler-mode-window-col, ruler-mode-mouse-set-left-margin) | 16303 | (ruler-mode-window-col, ruler-mode-mouse-set-left-margin) |
| @@ -16447,7 +17044,7 @@ | |||
| 16447 | 17044 | ||
| 16448 | 2004-02-16 Eli Tziperman <eli@deas.harvard.edu> | 17045 | 2004-02-16 Eli Tziperman <eli@deas.harvard.edu> |
| 16449 | 17046 | ||
| 16450 | * rmail-spam-filter.el: (vm-use-spam-filter) | 17047 | * rmail-spam-filter.el (vm-use-spam-filter) |
| 16451 | (rsf-min-region-length-added-to-spam-list): New variables. | 17048 | (rsf-min-region-length-added-to-spam-list): New variables. |
| 16452 | (rsf-bbdb-auto-delete-spam-bbdb-entries): Rename from | 17049 | (rsf-bbdb-auto-delete-spam-bbdb-entries): Rename from |
| 16453 | rmail-bbdb-auto-delete-spam-entries. Add cc: to recipients for | 17050 | rmail-bbdb-auto-delete-spam-entries. Add cc: to recipients for |
| @@ -17105,7 +17702,7 @@ | |||
| 17105 | 17702 | ||
| 17106 | * mail/smtpmail.el (smtpmail-send-data): Don't append spurious newline. | 17703 | * mail/smtpmail.el (smtpmail-send-data): Don't append spurious newline. |
| 17107 | 17704 | ||
| 17108 | 2004-01-18 David Ponce <david@dponce.com> (tiny change) | 17705 | 2004-01-18 David Ponce <david@dponce.com> (tiny change) |
| 17109 | 17706 | ||
| 17110 | * progmodes/which-func.el (which-function-mode): Don't cancel | 17707 | * progmodes/which-func.el (which-function-mode): Don't cancel |
| 17111 | which-func-update-timer if not set. | 17708 | which-func-update-timer if not set. |
| @@ -19619,10 +20216,10 @@ | |||
| 19619 | * calendar/cal-tex.el (cal-tex-day-name-format): Doc fix. | 20216 | * calendar/cal-tex.el (cal-tex-day-name-format): Doc fix. |
| 19620 | (cal-tex-LaTeX-hourbox): Move definition before use. | 20217 | (cal-tex-LaTeX-hourbox): Move definition before use. |
| 19621 | 20218 | ||
| 19622 | * calendar/cal-china.el, cal-hebrew.el, cal-islam.el, | 20219 | * calendar/cal-china.el, cal-hebrew.el, cal-islam.el |
| 19623 | cal-julian.el, cal-menu.el, cal-move.el, holidays.el, | 20220 | * cal-julian.el, cal-menu.el, cal-move.el, holidays.el |
| 19624 | lunar.el, solar.el | 20221 | * lunar.el, solar.el (displayed-month, displayed-year): |
| 19625 | (displayed-month, displayed-year): Define for compiler. | 20222 | Define for compiler. |
| 19626 | 20223 | ||
| 19627 | 2003-08-03 Martin Stjernholm <bug-cc-mode@gnu.org> | 20224 | 2003-08-03 Martin Stjernholm <bug-cc-mode@gnu.org> |
| 19628 | 20225 | ||
diff --git a/lisp/add-log.el b/lisp/add-log.el index 6dcbfca0c26..4131b237e5c 100644 --- a/lisp/add-log.el +++ b/lisp/add-log.el | |||
| @@ -220,7 +220,7 @@ Note: The search is conducted only within 10%, at the beginning of the file." | |||
| 220 | ("^\\sw.........[0-9:+ ]*" | 220 | ("^\\sw.........[0-9:+ ]*" |
| 221 | (0 'change-log-date-face) | 221 | (0 'change-log-date-face) |
| 222 | ;; Name and e-mail; some people put e-mail in parens, not angles. | 222 | ;; Name and e-mail; some people put e-mail in parens, not angles. |
| 223 | ("\\([^<(]+?\\)[ \t]*[(<]\\([A-Za-z0-9_.-]+@[A-Za-z0-9_.-]+\\)[>)]" nil nil | 223 | ("\\([^<(]+?\\)[ \t]*[(<]\\([A-Za-z0-9_.+-]+@[A-Za-z0-9_.-]+\\)[>)]" nil nil |
| 224 | (1 'change-log-name-face) | 224 | (1 'change-log-name-face) |
| 225 | (2 'change-log-email-face))) | 225 | (2 'change-log-email-face))) |
| 226 | ;; | 226 | ;; |
diff --git a/lisp/arc-mode.el b/lisp/arc-mode.el index cc8db1e7417..ac2869a301b 100644 --- a/lisp/arc-mode.el +++ b/lisp/arc-mode.el | |||
| @@ -689,7 +689,7 @@ archive. | |||
| 689 | (setq major-mode 'archive-mode) | 689 | (setq major-mode 'archive-mode) |
| 690 | (setq mode-name (concat typename "-Archive")) | 690 | (setq mode-name (concat typename "-Archive")) |
| 691 | ;; Run archive-foo-mode-hook and archive-mode-hook | 691 | ;; Run archive-foo-mode-hook and archive-mode-hook |
| 692 | (run-hooks (archive-name "mode-hook") 'archive-mode-hook) | 692 | (run-mode-hooks (archive-name "mode-hook") 'archive-mode-hook) |
| 693 | (use-local-map archive-mode-map)) | 693 | (use-local-map archive-mode-map)) |
| 694 | 694 | ||
| 695 | (make-local-variable 'archive-proper-file-start) | 695 | (make-local-variable 'archive-proper-file-start) |
diff --git a/lisp/array.el b/lisp/array.el index f65f14ac550..2f270d0f086 100644 --- a/lisp/array.el +++ b/lisp/array.el | |||
| @@ -872,6 +872,7 @@ take a numeric prefix argument): | |||
| 872 | Entering array mode calls the function `array-mode-hook'." | 872 | Entering array mode calls the function `array-mode-hook'." |
| 873 | 873 | ||
| 874 | (interactive) | 874 | (interactive) |
| 875 | (kill-all-local-variables) | ||
| 875 | ;; Number of rows in the array. | 876 | ;; Number of rows in the array. |
| 876 | (make-local-variable 'array-max-row) | 877 | (make-local-variable 'array-max-row) |
| 877 | ;; Number of columns in the array. | 878 | ;; Number of columns in the array. |
| @@ -907,7 +908,7 @@ Entering array mode calls the function `array-mode-hook'." | |||
| 907 | (setq truncate-lines t) | 908 | (setq truncate-lines t) |
| 908 | (setq overwrite-mode 'overwrite-mode-textual) | 909 | (setq overwrite-mode 'overwrite-mode-textual) |
| 909 | (use-local-map array-mode-map) | 910 | (use-local-map array-mode-map) |
| 910 | (run-hooks 'array-mode-hook)) | 911 | (run-mode-hooks 'array-mode-hook)) |
| 911 | 912 | ||
| 912 | 913 | ||
| 913 | 914 | ||
diff --git a/lisp/autorevert.el b/lisp/autorevert.el index 36b5a6f5a37..1769a992f7b 100644 --- a/lisp/autorevert.el +++ b/lisp/autorevert.el | |||
| @@ -484,46 +484,47 @@ are checked first the next time this function is called. | |||
| 484 | This function is also responsible for removing buffers no longer in | 484 | This function is also responsible for removing buffers no longer in |
| 485 | Auto-Revert mode from `auto-revert-buffer-list', and for canceling | 485 | Auto-Revert mode from `auto-revert-buffer-list', and for canceling |
| 486 | the timer when no buffers need to be checked." | 486 | the timer when no buffers need to be checked." |
| 487 | (let ((bufs (if global-auto-revert-mode | 487 | (save-match-data |
| 488 | (buffer-list) | 488 | (let ((bufs (if global-auto-revert-mode |
| 489 | auto-revert-buffer-list)) | 489 | (buffer-list) |
| 490 | (remaining ()) | 490 | auto-revert-buffer-list)) |
| 491 | (new ())) | 491 | (remaining ()) |
| 492 | ;; Partition `bufs' into two halves depending on whether or not | 492 | (new ())) |
| 493 | ;; the buffers are in `auto-revert-remaining-buffers'. The two | 493 | ;; Partition `bufs' into two halves depending on whether or not |
| 494 | ;; halves are then re-joined with the "remaining" buffers at the | 494 | ;; the buffers are in `auto-revert-remaining-buffers'. The two |
| 495 | ;; head of the list. | 495 | ;; halves are then re-joined with the "remaining" buffers at the |
| 496 | (dolist (buf auto-revert-remaining-buffers) | 496 | ;; head of the list. |
| 497 | (if (memq buf bufs) | 497 | (dolist (buf auto-revert-remaining-buffers) |
| 498 | (push buf remaining))) | 498 | (if (memq buf bufs) |
| 499 | (dolist (buf bufs) | 499 | (push buf remaining))) |
| 500 | (if (not (memq buf remaining)) | 500 | (dolist (buf bufs) |
| 501 | (push buf new))) | 501 | (if (not (memq buf remaining)) |
| 502 | (setq bufs (nreverse (nconc new remaining))) | 502 | (push buf new))) |
| 503 | (while (and bufs | 503 | (setq bufs (nreverse (nconc new remaining))) |
| 504 | (not (and auto-revert-stop-on-user-input | 504 | (while (and bufs |
| 505 | (input-pending-p)))) | 505 | (not (and auto-revert-stop-on-user-input |
| 506 | (let ((buf (car bufs))) | 506 | (input-pending-p)))) |
| 507 | (if (buffer-name buf) ; Buffer still alive? | 507 | (let ((buf (car bufs))) |
| 508 | (with-current-buffer buf | 508 | (if (buffer-name buf) ; Buffer still alive? |
| 509 | ;; Test if someone has turned off Auto-Revert Mode in a | 509 | (with-current-buffer buf |
| 510 | ;; non-standard way, for example by changing major mode. | 510 | ;; Test if someone has turned off Auto-Revert Mode in a |
| 511 | (if (and (not auto-revert-mode) | 511 | ;; non-standard way, for example by changing major mode. |
| 512 | (not auto-revert-tail-mode) | 512 | (if (and (not auto-revert-mode) |
| 513 | (memq buf auto-revert-buffer-list)) | 513 | (not auto-revert-tail-mode) |
| 514 | (setq auto-revert-buffer-list | 514 | (memq buf auto-revert-buffer-list)) |
| 515 | (delq buf auto-revert-buffer-list))) | 515 | (setq auto-revert-buffer-list |
| 516 | (when (auto-revert-active-p) (auto-revert-handler))) | 516 | (delq buf auto-revert-buffer-list))) |
| 517 | ;; Remove dead buffer from `auto-revert-buffer-list'. | 517 | (when (auto-revert-active-p) (auto-revert-handler))) |
| 518 | (setq auto-revert-buffer-list | 518 | ;; Remove dead buffer from `auto-revert-buffer-list'. |
| 519 | (delq buf auto-revert-buffer-list)))) | 519 | (setq auto-revert-buffer-list |
| 520 | (setq bufs (cdr bufs))) | 520 | (delq buf auto-revert-buffer-list)))) |
| 521 | (setq auto-revert-remaining-buffers bufs) | 521 | (setq bufs (cdr bufs))) |
| 522 | ;; Check if we should cancel the timer. | 522 | (setq auto-revert-remaining-buffers bufs) |
| 523 | (when (and (not global-auto-revert-mode) | 523 | ;; Check if we should cancel the timer. |
| 524 | (null auto-revert-buffer-list)) | 524 | (when (and (not global-auto-revert-mode) |
| 525 | (cancel-timer auto-revert-timer) | 525 | (null auto-revert-buffer-list)) |
| 526 | (setq auto-revert-timer nil)))) | 526 | (cancel-timer auto-revert-timer) |
| 527 | (setq auto-revert-timer nil))))) | ||
| 527 | 528 | ||
| 528 | 529 | ||
| 529 | ;; The end: | 530 | ;; The end: |
diff --git a/lisp/bookmark.el b/lisp/bookmark.el index 0696f929584..bbf9b3bcce4 100644 --- a/lisp/bookmark.el +++ b/lisp/bookmark.el | |||
| @@ -866,7 +866,7 @@ the annotation. | |||
| 866 | (use-local-map bookmark-read-annotation-mode-map) | 866 | (use-local-map bookmark-read-annotation-mode-map) |
| 867 | (setq major-mode 'bookmark-read-annotation-mode) | 867 | (setq major-mode 'bookmark-read-annotation-mode) |
| 868 | (insert (funcall bookmark-read-annotation-text-func bookmark)) | 868 | (insert (funcall bookmark-read-annotation-text-func bookmark)) |
| 869 | (run-hooks 'text-mode-hook)) | 869 | (run-mode-hooks 'text-mode-hook)) |
| 870 | 870 | ||
| 871 | 871 | ||
| 872 | (defun bookmark-read-annotation (parg bookmark) | 872 | (defun bookmark-read-annotation (parg bookmark) |
| @@ -903,7 +903,7 @@ When you have finished composing, type \\[bookmark-send-annotation]. | |||
| 903 | (let ((annotation (bookmark-get-annotation bookmark))) | 903 | (let ((annotation (bookmark-get-annotation bookmark))) |
| 904 | (if (and annotation (not (string-equal annotation ""))) | 904 | (if (and annotation (not (string-equal annotation ""))) |
| 905 | (insert annotation))) | 905 | (insert annotation))) |
| 906 | (run-hooks 'text-mode-hook)) | 906 | (run-mode-hooks 'text-mode-hook)) |
| 907 | 907 | ||
| 908 | 908 | ||
| 909 | (defun bookmark-send-edited-annotation () | 909 | (defun bookmark-send-edited-annotation () |
| @@ -1618,7 +1618,7 @@ Bookmark names preceded by a \"*\" have annotations. | |||
| 1618 | (setq buffer-read-only t) | 1618 | (setq buffer-read-only t) |
| 1619 | (setq major-mode 'bookmark-bmenu-mode) | 1619 | (setq major-mode 'bookmark-bmenu-mode) |
| 1620 | (setq mode-name "Bookmark Menu") | 1620 | (setq mode-name "Bookmark Menu") |
| 1621 | (run-hooks 'bookmark-bmenu-mode-hook)) | 1621 | (run-mode-hooks 'bookmark-bmenu-mode-hook)) |
| 1622 | 1622 | ||
| 1623 | 1623 | ||
| 1624 | (defun bookmark-bmenu-toggle-filenames (&optional show) | 1624 | (defun bookmark-bmenu-toggle-filenames (&optional show) |
diff --git a/lisp/bs.el b/lisp/bs.el index 76d8d25051f..4c8b74bb59f 100644 --- a/lisp/bs.el +++ b/lisp/bs.el | |||
| @@ -656,7 +656,7 @@ to show always. | |||
| 656 | truncate-lines t | 656 | truncate-lines t |
| 657 | font-lock-defaults '(bs-mode-font-lock-keywords t) | 657 | font-lock-defaults '(bs-mode-font-lock-keywords t) |
| 658 | font-lock-verbose nil) | 658 | font-lock-verbose nil) |
| 659 | (run-hooks 'bs-mode-hook)) | 659 | (run-mode-hooks 'bs-mode-hook)) |
| 660 | 660 | ||
| 661 | (defun bs-kill () | 661 | (defun bs-kill () |
| 662 | "Let buffer disappear and reset window-configuration." | 662 | "Let buffer disappear and reset window-configuration." |
diff --git a/lisp/calc/calc-aent.el b/lisp/calc/calc-aent.el index b947b597acf..8af03c4d206 100644 --- a/lisp/calc/calc-aent.el +++ b/lisp/calc/calc-aent.el | |||
| @@ -947,6 +947,9 @@ in Calc algebraic input.") | |||
| 947 | first nil)) | 947 | first nil)) |
| 948 | x)) | 948 | x)) |
| 949 | 949 | ||
| 950 | ;; calc-arg-values is defined in calc-ext.el, but is used here. | ||
| 951 | (defvar calc-arg-values) | ||
| 952 | |||
| 950 | (defun calc-check-user-syntax (&optional x prec) | 953 | (defun calc-check-user-syntax (&optional x prec) |
| 951 | (let ((p calc-user-parse-table) | 954 | (let ((p calc-user-parse-table) |
| 952 | (matches nil) | 955 | (matches nil) |
diff --git a/lisp/calc/calc-embed.el b/lisp/calc/calc-embed.el index 6b94cd0af0c..c6e0e33e559 100644 --- a/lisp/calc/calc-embed.el +++ b/lisp/calc/calc-embed.el | |||
| @@ -192,8 +192,15 @@ | |||
| 192 | (defvar calc-embed-top) | 192 | (defvar calc-embed-top) |
| 193 | (defvar calc-embed-bot) | 193 | (defvar calc-embed-bot) |
| 194 | 194 | ||
| 195 | ;; The variable calc-embed-arg is local to calc-do-embedded, | ||
| 196 | ;; calc-embedded-update-formula, calc-embedded-edit and | ||
| 197 | ;; calc-do-embedded-activate, but is used by | ||
| 198 | ;; calc-embedded-make-info, which is called by the above | ||
| 199 | ;; functions. | ||
| 200 | (defvar calc-embed-arg) | ||
| 201 | |||
| 195 | (defvar calc-embedded-quiet nil) | 202 | (defvar calc-embedded-quiet nil) |
| 196 | (defun calc-do-embedded (arg end obeg oend) | 203 | (defun calc-do-embedded (calc-embed-arg end obeg oend) |
| 197 | (if calc-embedded-info | 204 | (if calc-embedded-info |
| 198 | 205 | ||
| 199 | ;; Turn embedded mode off or switch to a new buffer. | 206 | ;; Turn embedded mode off or switch to a new buffer. |
| @@ -237,7 +244,7 @@ | |||
| 237 | (buffer-name))) | 244 | (buffer-name))) |
| 238 | (keyboard-quit)) | 245 | (keyboard-quit)) |
| 239 | (calc-embedded nil))) | 246 | (calc-embedded nil))) |
| 240 | (calc-embedded arg end obeg oend))) | 247 | (calc-embedded calc-embed-arg end obeg oend))) |
| 241 | 248 | ||
| 242 | ;; Turn embedded mode on. | 249 | ;; Turn embedded mode on. |
| 243 | (calc-plain-buffer-only) | 250 | (calc-plain-buffer-only) |
| @@ -250,7 +257,8 @@ | |||
| 250 | (calc-embedded-save-original-modes) | 257 | (calc-embedded-save-original-modes) |
| 251 | (or calc-embedded-globals | 258 | (or calc-embedded-globals |
| 252 | (calc-find-globals)) | 259 | (calc-find-globals)) |
| 253 | (setq info (calc-embedded-make-info (point) nil t arg end obeg oend)) | 260 | (setq info |
| 261 | (calc-embedded-make-info (point) nil t calc-embed-arg end obeg oend)) | ||
| 254 | (if (eq (car-safe (aref info 8)) 'error) | 262 | (if (eq (car-safe (aref info 8)) 'error) |
| 255 | (progn | 263 | (progn |
| 256 | (setq calc-embedded-original-modes nil) | 264 | (setq calc-embedded-original-modes nil) |
| @@ -311,13 +319,13 @@ | |||
| 311 | (calc-select-part 2))) | 319 | (calc-select-part 2))) |
| 312 | 320 | ||
| 313 | 321 | ||
| 314 | (defun calc-embedded-update-formula (arg) | 322 | (defun calc-embedded-update-formula (calc-embed-arg) |
| 315 | (interactive "P") | 323 | (interactive "P") |
| 316 | (if arg | 324 | (if calc-embed-arg |
| 317 | (let ((entry (assq (current-buffer) calc-embedded-active))) | 325 | (let ((entry (assq (current-buffer) calc-embedded-active))) |
| 318 | (while (setq entry (cdr entry)) | 326 | (while (setq entry (cdr entry)) |
| 319 | (and (eq (car-safe (aref (car entry) 8)) 'calcFunc-evalto) | 327 | (and (eq (car-safe (aref (car entry) 8)) 'calcFunc-evalto) |
| 320 | (or (not (consp arg)) | 328 | (or (not (consp calc-embed-arg)) |
| 321 | (and (<= (aref (car entry) 2) (region-beginning)) | 329 | (and (<= (aref (car entry) 2) (region-beginning)) |
| 322 | (>= (aref (car entry) 3) (region-end)))) | 330 | (>= (aref (car entry) 3) (region-end)))) |
| 323 | (save-excursion | 331 | (save-excursion |
| @@ -337,9 +345,9 @@ | |||
| 337 | (goto-char (+ (aref info 4) pt)))))))) | 345 | (goto-char (+ (aref info 4) pt)))))))) |
| 338 | 346 | ||
| 339 | 347 | ||
| 340 | (defun calc-embedded-edit (arg) | 348 | (defun calc-embedded-edit (calc-embed-arg) |
| 341 | (interactive "P") | 349 | (interactive "P") |
| 342 | (let ((info (calc-embedded-make-info (point) nil t arg)) | 350 | (let ((info (calc-embedded-make-info (point) nil t calc-embed-arg)) |
| 343 | str) | 351 | str) |
| 344 | (if (eq (car-safe (aref info 8)) 'error) | 352 | (if (eq (car-safe (aref info 8)) 'error) |
| 345 | (progn | 353 | (progn |
| @@ -374,12 +382,12 @@ | |||
| 374 | (aset info 8 val) | 382 | (aset info 8 val) |
| 375 | (calc-embedded-update info 14 t t)))) | 383 | (calc-embedded-update info 14 t t)))) |
| 376 | 384 | ||
| 377 | (defun calc-do-embedded-activate (arg cbuf) | 385 | (defun calc-do-embedded-activate (calc-embed-arg cbuf) |
| 378 | (calc-plain-buffer-only) | 386 | (calc-plain-buffer-only) |
| 379 | (if arg | 387 | (if calc-embed-arg |
| 380 | (calc-embedded-forget)) | 388 | (calc-embedded-forget)) |
| 381 | (calc-find-globals) | 389 | (calc-find-globals) |
| 382 | (if (< (prefix-numeric-value arg) 0) | 390 | (if (< (prefix-numeric-value calc-embed-arg) 0) |
| 383 | (message "Deactivating %s for Calc Embedded mode" (buffer-name)) | 391 | (message "Deactivating %s for Calc Embedded mode" (buffer-name)) |
| 384 | (message "Activating %s for Calc Embedded mode..." (buffer-name)) | 392 | (message "Activating %s for Calc Embedded mode..." (buffer-name)) |
| 385 | (save-excursion | 393 | (save-excursion |
| @@ -432,7 +440,7 @@ | |||
| 432 | 440 | ||
| 433 | (defun calc-embedded-word () | 441 | (defun calc-embedded-word () |
| 434 | (interactive) | 442 | (interactive) |
| 435 | (calc-embedded '(4))) | 443 | (calc-embedded '(t))) |
| 436 | 444 | ||
| 437 | (defun calc-embedded-mark-formula (&optional body-only) | 445 | (defun calc-embedded-mark-formula (&optional body-only) |
| 438 | "Put point at the beginning of this Calc formula, mark at the end. | 446 | "Put point at the beginning of this Calc formula, mark at the end. |
| @@ -799,16 +807,26 @@ The command \\[yank] can retrieve it from there." | |||
| 799 | (aset info 1 (or cbuf (save-excursion | 807 | (aset info 1 (or cbuf (save-excursion |
| 800 | (calc-create-buffer) | 808 | (calc-create-buffer) |
| 801 | (current-buffer))))) | 809 | (current-buffer))))) |
| 802 | (if (and (integerp calc-embed-top) (not calc-embed-bot)) | 810 | (if (and |
| 811 | (or (integerp calc-embed-top) (equal calc-embed-top '(4))) | ||
| 812 | (not calc-embed-bot)) | ||
| 803 | ; started with a user-supplied argument | 813 | ; started with a user-supplied argument |
| 804 | (progn | 814 | (progn |
| 805 | (if (= (setq arg (prefix-numeric-value arg)) 0) | 815 | (if (equal calc-embed-top '(4)) |
| 806 | (progn | 816 | (progn |
| 807 | (aset info 2 (copy-marker (region-beginning))) | 817 | (aset info 2 (copy-marker (line-beginning-position))) |
| 808 | (aset info 3 (copy-marker (region-end)))) | 818 | (aset info 3 (copy-marker (line-end-position)))) |
| 809 | (aset info (if (> arg 0) 2 3) (point-marker)) | 819 | (if (= (setq calc-embed-arg (prefix-numeric-value calc-embed-arg)) 0) |
| 810 | (forward-line arg) | 820 | (progn |
| 811 | (aset info (if (> arg 0) 3 2) (point-marker))) | 821 | (aset info 2 (copy-marker (region-beginning))) |
| 822 | (aset info 3 (copy-marker (region-end)))) | ||
| 823 | (aset info (if (> calc-embed-arg 0) 2 3) (point-marker)) | ||
| 824 | (if (> calc-embed-arg 0) | ||
| 825 | (progn | ||
| 826 | (forward-line (1- calc-embed-arg)) | ||
| 827 | (end-of-line)) | ||
| 828 | (forward-line (1+ calc-embed-arg))) | ||
| 829 | (aset info (if (> calc-embed-arg 0) 3 2) (point-marker)))) | ||
| 812 | (aset info 4 (copy-marker (aref info 2))) | 830 | (aset info 4 (copy-marker (aref info 2))) |
| 813 | (aset info 5 (copy-marker (aref info 3)))) | 831 | (aset info 5 (copy-marker (aref info 3)))) |
| 814 | (if (aref info 4) | 832 | (if (aref info 4) |
diff --git a/lisp/calc/calc-ext.el b/lisp/calc/calc-ext.el index adbdf7a96e2..0b177b06dc4 100644 --- a/lisp/calc/calc-ext.el +++ b/lisp/calc/calc-ext.el | |||
| @@ -43,6 +43,9 @@ | |||
| 43 | (defvar math-comp-sel-cpos nil) | 43 | (defvar math-comp-sel-cpos nil) |
| 44 | (defvar math-compose-hash-args nil) | 44 | (defvar math-compose-hash-args nil) |
| 45 | 45 | ||
| 46 | (defvar calc-alg-map) | ||
| 47 | (defvar calc-alg-esc-map) | ||
| 48 | |||
| 46 | ;;; The following was made a function so that it could be byte-compiled. | 49 | ;;; The following was made a function so that it could be byte-compiled. |
| 47 | (defun calc-init-extensions () | 50 | (defun calc-init-extensions () |
| 48 | 51 | ||
| @@ -1192,8 +1195,9 @@ calc-kill calc-kill-region calc-yank)))) | |||
| 1192 | (math-normalize val))))) | 1195 | (math-normalize val))))) |
| 1193 | 1196 | ||
| 1194 | 1197 | ||
| 1198 | (defvar calc-help-map nil) | ||
| 1195 | 1199 | ||
| 1196 | (if (boundp 'calc-help-map) | 1200 | (if calc-help-map |
| 1197 | nil | 1201 | nil |
| 1198 | (setq calc-help-map (make-keymap)) | 1202 | (setq calc-help-map (make-keymap)) |
| 1199 | (define-key calc-help-map "b" 'calc-describe-bindings) | 1203 | (define-key calc-help-map "b" 'calc-describe-bindings) |
diff --git a/lisp/calc/calc-misc.el b/lisp/calc/calc-misc.el index e8bdfe2fa5a..ce0da11ecaa 100644 --- a/lisp/calc/calc-misc.el +++ b/lisp/calc/calc-misc.el | |||
| @@ -160,7 +160,7 @@ Calc user interface as before (either M-# C or M-# K; initially M-# C)." | |||
| 160 | "Go to a node in the Calculator info documentation." | 160 | "Go to a node in the Calculator info documentation." |
| 161 | (interactive) | 161 | (interactive) |
| 162 | (select-window (get-largest-window)) | 162 | (select-window (get-largest-window)) |
| 163 | (Info-goto-node (concat "(Calc)" node))) | 163 | (info (concat "(Calc)" node))) |
| 164 | 164 | ||
| 165 | (defun calc-tutorial () | 165 | (defun calc-tutorial () |
| 166 | "Run the Emacs Info system on the Calculator Tutorial." | 166 | "Run the Emacs Info system on the Calculator Tutorial." |
diff --git a/lisp/calc/calc-prog.el b/lisp/calc/calc-prog.el index 230b0f6a6c5..8d2fba7fef0 100644 --- a/lisp/calc/calc-prog.el +++ b/lisp/calc/calc-prog.el | |||
| @@ -702,7 +702,7 @@ | |||
| 702 | (get func 'calc-user-defn))) | 702 | (get func 'calc-user-defn))) |
| 703 | (kys (concat "z" (char-to-string (car def)))) | 703 | (kys (concat "z" (char-to-string (car def)))) |
| 704 | (intcmd (symbol-name (cdr def))) | 704 | (intcmd (symbol-name (cdr def))) |
| 705 | (algcmd (substring (symbol-name func) 9))) | 705 | (algcmd (if func (substring (symbol-name func) 9) ""))) |
| 706 | (if (and defn (calc-valid-formula-func func)) | 706 | (if (and defn (calc-valid-formula-func func)) |
| 707 | (let ((niceexpr (math-format-nice-expr defn (frame-width)))) | 707 | (let ((niceexpr (math-format-nice-expr defn (frame-width)))) |
| 708 | (calc-wrapper | 708 | (calc-wrapper |
| @@ -1446,15 +1446,22 @@ Redefine the corresponding command." | |||
| 1446 | (error "Unbalanced Z' in keyboard macro"))) | 1446 | (error "Unbalanced Z' in keyboard macro"))) |
| 1447 | 1447 | ||
| 1448 | 1448 | ||
| 1449 | (defun calc-kbd-report (msg) | 1449 | ;; (defun calc-kbd-report (msg) |
| 1450 | (interactive "sMessage: ") | 1450 | ;; (interactive "sMessage: ") |
| 1451 | (calc-wrapper | 1451 | ;; (calc-wrapper |
| 1452 | (math-working msg (calc-top-n 1)))) | 1452 | ;; (math-working msg (calc-top-n 1)))) |
| 1453 | 1453 | ||
| 1454 | (defun calc-kbd-query (msg) | 1454 | (defun calc-kbd-query () |
| 1455 | (interactive "sPrompt: ") | 1455 | (interactive) |
| 1456 | (calc-wrapper | 1456 | (let ((defining-kbd-macro nil) |
| 1457 | (calc-alg-entry nil (and (not (equal msg "")) msg)))) | 1457 | (executing-kbd-macro nil) |
| 1458 | (msg (calc-top 1))) | ||
| 1459 | (if (not (eq (car-safe msg) 'vec)) | ||
| 1460 | (error "No prompt string provided") | ||
| 1461 | (setq msg (math-vector-to-string msg)) | ||
| 1462 | (calc-wrapper | ||
| 1463 | (calc-pop-stack 1) | ||
| 1464 | (calc-alg-entry nil (and (not (equal msg "")) msg)))))) | ||
| 1458 | 1465 | ||
| 1459 | ;;;; Logical operations. | 1466 | ;;;; Logical operations. |
| 1460 | 1467 | ||
diff --git a/lisp/calc/calc-stuff.el b/lisp/calc/calc-stuff.el index c6e8d8bbf27..0564e39ed57 100644 --- a/lisp/calc/calc-stuff.el +++ b/lisp/calc/calc-stuff.el | |||
| @@ -171,6 +171,7 @@ With a prefix, push that prefix as a number onto the stack." | |||
| 171 | (defvar math-max-digits-cache) ; calc-bin.el | 171 | (defvar math-max-digits-cache) ; calc-bin.el |
| 172 | (defvar math-integral-cache) ; calcalg2.el | 172 | (defvar math-integral-cache) ; calcalg2.el |
| 173 | (defvar math-units-table) ; calc-units.el | 173 | (defvar math-units-table) ; calc-units.el |
| 174 | (defvar math-decls-cache-tag) ; calc-arith.el | ||
| 174 | (defvar math-format-date-cache) ; calc-forms.el | 175 | (defvar math-format-date-cache) ; calc-forms.el |
| 175 | (defvar math-holidays-cache-tag) ; calc-forms.el | 176 | (defvar math-holidays-cache-tag) ; calc-forms.el |
| 176 | 177 | ||
diff --git a/lisp/calc/calc-yank.el b/lisp/calc/calc-yank.el index 84c117a1723..1544e8956c1 100644 --- a/lisp/calc/calc-yank.el +++ b/lisp/calc/calc-yank.el | |||
| @@ -447,7 +447,7 @@ To cancel the edit, simply kill the *Calc Edit* buffer." | |||
| 447 | (setq truncate-lines nil) | 447 | (setq truncate-lines nil) |
| 448 | (setq major-mode 'calc-edit-mode) | 448 | (setq major-mode 'calc-edit-mode) |
| 449 | (setq mode-name "Calc Edit") | 449 | (setq mode-name "Calc Edit") |
| 450 | (run-hooks 'calc-edit-mode-hook) | 450 | (run-mode-hooks 'calc-edit-mode-hook) |
| 451 | (make-local-variable 'calc-original-buffer) | 451 | (make-local-variable 'calc-original-buffer) |
| 452 | (setq calc-original-buffer oldbuf) | 452 | (setq calc-original-buffer oldbuf) |
| 453 | (make-local-variable 'calc-return-buffer) | 453 | (make-local-variable 'calc-return-buffer) |
diff --git a/lisp/calc/calc.el b/lisp/calc/calc.el index 173785dc912..3a99291fdef 100644 --- a/lisp/calc/calc.el +++ b/lisp/calc/calc.el | |||
| @@ -209,7 +209,8 @@ | |||
| 209 | (defgroup calc nil | 209 | (defgroup calc nil |
| 210 | "GNU Calc" | 210 | "GNU Calc" |
| 211 | :prefix "calc-" | 211 | :prefix "calc-" |
| 212 | :tag "Calc") | 212 | :tag "Calc" |
| 213 | :group 'applications) | ||
| 213 | 214 | ||
| 214 | ;;;###autoload | 215 | ;;;###autoload |
| 215 | (defcustom calc-settings-file | 216 | (defcustom calc-settings-file |
| @@ -324,7 +325,7 @@ This is not required to be present for user-written mode annotations." | |||
| 324 | :type '(choice (string) (sexp))) | 325 | :type '(choice (string) (sexp))) |
| 325 | 326 | ||
| 326 | (defvar calc-bug-address "belanger@truman.edu" | 327 | (defvar calc-bug-address "belanger@truman.edu" |
| 327 | "Address of the author of Calc, for use by `report-calc-bug'.") | 328 | "Address of the maintainer of Calc, for use by `report-calc-bug'.") |
| 328 | 329 | ||
| 329 | (defvar calc-scan-for-dels t | 330 | (defvar calc-scan-for-dels t |
| 330 | "If t, scan keymaps to find all DEL-like keys. | 331 | "If t, scan keymaps to find all DEL-like keys. |
| @@ -719,6 +720,12 @@ If nil, selections displayed but ignored.") | |||
| 719 | (defvar calc-load-hook nil | 720 | (defvar calc-load-hook nil |
| 720 | "Hook run when calc.el is loaded.") | 721 | "Hook run when calc.el is loaded.") |
| 721 | 722 | ||
| 723 | (defvar calc-window-hook nil | ||
| 724 | "Hook called to create the Calc window.") | ||
| 725 | |||
| 726 | (defvar calc-trail-window-hook nil | ||
| 727 | "Hook called to create the Calc trail window.") | ||
| 728 | |||
| 722 | ;; Verify that Calc is running on the right kind of system. | 729 | ;; Verify that Calc is running on the right kind of system. |
| 723 | (defvar calc-emacs-type-lucid (not (not (string-match "Lucid" emacs-version)))) | 730 | (defvar calc-emacs-type-lucid (not (not (string-match "Lucid" emacs-version)))) |
| 724 | 731 | ||
| @@ -830,20 +837,6 @@ If nil, selections displayed but ignored.") | |||
| 830 | (defvar var-gamma '(special-const (math-gamma-const))) | 837 | (defvar var-gamma '(special-const (math-gamma-const))) |
| 831 | (defvar var-Modes '(special-const (math-get-modes-vec))) | 838 | (defvar var-Modes '(special-const (math-get-modes-vec))) |
| 832 | 839 | ||
| 833 | (defvar calc-language-alist | ||
| 834 | '((latex-mode . latex) | ||
| 835 | (tex-mode . tex) | ||
| 836 | (plain-tex-mode . tex) | ||
| 837 | (context-mode . tex) | ||
| 838 | (nroff-mode . eqn) | ||
| 839 | (pascal-mode . pascal) | ||
| 840 | (c-mode . c) | ||
| 841 | (c++-mode . c) | ||
| 842 | (fortran-mode . fortran) | ||
| 843 | (f90-mode . fortran)) | ||
| 844 | "Alist of major modes with appropriate Calc languages.") | ||
| 845 | |||
| 846 | |||
| 847 | (mapcar (lambda (v) (or (boundp v) (set v nil))) | 840 | (mapcar (lambda (v) (or (boundp v) (set v nil))) |
| 848 | calc-local-var-list) | 841 | calc-local-var-list) |
| 849 | 842 | ||
| @@ -1066,7 +1059,7 @@ If nil, selections displayed but ignored.") | |||
| 1066 | (use-global-map glob) | 1059 | (use-global-map glob) |
| 1067 | (use-local-map loc))))) | 1060 | (use-local-map loc))))) |
| 1068 | 1061 | ||
| 1069 | 1062 | (defvar calc-alg-map) ; Defined in calc-ext.el | |
| 1070 | 1063 | ||
| 1071 | (defun calc-mode () | 1064 | (defun calc-mode () |
| 1072 | "Calculator major mode. | 1065 | "Calculator major mode. |
| @@ -1131,7 +1124,7 @@ Notations: 3.14e6 3.14 * 10^6 | |||
| 1131 | (string-match "full" (nth 1 p)) | 1124 | (string-match "full" (nth 1 p)) |
| 1132 | (setq calc-standalone-flag t)) | 1125 | (setq calc-standalone-flag t)) |
| 1133 | (setq p (cdr p)))) | 1126 | (setq p (cdr p)))) |
| 1134 | (run-hooks 'calc-mode-hook) | 1127 | (run-mode-hooks 'calc-mode-hook) |
| 1135 | (calc-refresh t) | 1128 | (calc-refresh t) |
| 1136 | (calc-set-mode-line) | 1129 | (calc-set-mode-line) |
| 1137 | (calc-check-defines)) | 1130 | (calc-check-defines)) |
| @@ -1181,7 +1174,7 @@ commands given here will actually operate on the *Calculator* stack." | |||
| 1181 | (insert (propertize (concat "Emacs Calculator v" calc-version | 1174 | (insert (propertize (concat "Emacs Calculator v" calc-version |
| 1182 | " by Dave Gillespie\n") | 1175 | " by Dave Gillespie\n") |
| 1183 | 'font-lock-face 'italic)))) | 1176 | 'font-lock-face 'italic)))) |
| 1184 | (run-hooks 'calc-trail-mode-hook)) | 1177 | (run-mode-hooks 'calc-trail-mode-hook)) |
| 1185 | 1178 | ||
| 1186 | (defun calc-create-buffer () | 1179 | (defun calc-create-buffer () |
| 1187 | (set-buffer (get-buffer-create "*Calculator*")) | 1180 | (set-buffer (get-buffer-create "*Calculator*")) |
| @@ -1218,18 +1211,20 @@ commands given here will actually operate on the *Calculator* stack." | |||
| 1218 | (switch-to-buffer (current-buffer) t) | 1211 | (switch-to-buffer (current-buffer) t) |
| 1219 | (if (get-buffer-window (current-buffer)) | 1212 | (if (get-buffer-window (current-buffer)) |
| 1220 | (select-window (get-buffer-window (current-buffer))) | 1213 | (select-window (get-buffer-window (current-buffer))) |
| 1221 | (let ((w (get-largest-window))) | 1214 | (if calc-window-hook |
| 1222 | (if (and pop-up-windows | 1215 | (run-hooks 'calc-window-hook) |
| 1223 | (> (window-height w) | 1216 | (let ((w (get-largest-window))) |
| 1224 | (+ window-min-height calc-window-height 2))) | 1217 | (if (and pop-up-windows |
| 1225 | (progn | 1218 | (> (window-height w) |
| 1226 | (setq w (split-window w | 1219 | (+ window-min-height calc-window-height 2))) |
| 1227 | (- (window-height w) | 1220 | (progn |
| 1228 | calc-window-height 2) | 1221 | (setq w (split-window w |
| 1229 | nil)) | 1222 | (- (window-height w) |
| 1230 | (set-window-buffer w (current-buffer)) | 1223 | calc-window-height 2) |
| 1231 | (select-window w)) | 1224 | nil)) |
| 1232 | (pop-to-buffer (current-buffer)))))) | 1225 | (set-window-buffer w (current-buffer)) |
| 1226 | (select-window w)) | ||
| 1227 | (pop-to-buffer (current-buffer))))))) | ||
| 1233 | (save-excursion | 1228 | (save-excursion |
| 1234 | (set-buffer (calc-trail-buffer)) | 1229 | (set-buffer (calc-trail-buffer)) |
| 1235 | (and calc-display-trail | 1230 | (and calc-display-trail |
| @@ -1836,15 +1831,17 @@ See calc-keypad for details." | |||
| 1836 | (not (if flag (memq flag '(nil 0)) win))) | 1831 | (not (if flag (memq flag '(nil 0)) win))) |
| 1837 | (if (null win) | 1832 | (if (null win) |
| 1838 | (progn | 1833 | (progn |
| 1839 | (let ((w (split-window nil (/ (* (window-width) 2) 3) t))) | 1834 | (if calc-trail-window-hook |
| 1840 | (set-window-buffer w calc-trail-buffer)) | 1835 | (run-hooks 'calc-trail-window-hook) |
| 1841 | (calc-wrapper | 1836 | (let ((w (split-window nil (/ (* (window-width) 2) 3) t))) |
| 1842 | (setq overlay-arrow-string calc-trail-overlay | 1837 | (set-window-buffer w calc-trail-buffer))) |
| 1843 | overlay-arrow-position calc-trail-pointer) | 1838 | (calc-wrapper |
| 1844 | (or no-refresh | 1839 | (setq overlay-arrow-string calc-trail-overlay |
| 1845 | (if interactive | 1840 | overlay-arrow-position calc-trail-pointer) |
| 1846 | (calc-do-refresh) | 1841 | (or no-refresh |
| 1847 | (calc-refresh)))))) | 1842 | (if interactive |
| 1843 | (calc-do-refresh) | ||
| 1844 | (calc-refresh)))))) | ||
| 1848 | (if win | 1845 | (if win |
| 1849 | (progn | 1846 | (progn |
| 1850 | (delete-window win) | 1847 | (delete-window win) |
| @@ -3444,7 +3441,7 @@ Also looks for the equivalent TeX words, \\gets and \\evalto." | |||
| 3444 | 3441 | ||
| 3445 | (defun calc-user-invocation () | 3442 | (defun calc-user-invocation () |
| 3446 | (interactive) | 3443 | (interactive) |
| 3447 | (unless (stringp calc-invocation-macro) | 3444 | (unless calc-invocation-macro |
| 3448 | (error "Use `Z I' inside Calc to define a `M-# Z' keyboard macro")) | 3445 | (error "Use `Z I' inside Calc to define a `M-# Z' keyboard macro")) |
| 3449 | (execute-kbd-macro calc-invocation-macro nil)) | 3446 | (execute-kbd-macro calc-invocation-macro nil)) |
| 3450 | 3447 | ||
diff --git a/lisp/calc/calcalg2.el b/lisp/calc/calcalg2.el index 7e502aa1a87..d139dcf28ba 100644 --- a/lisp/calc/calcalg2.el +++ b/lisp/calc/calcalg2.el | |||
| @@ -202,6 +202,8 @@ | |||
| 202 | (defvar math-deriv-var) | 202 | (defvar math-deriv-var) |
| 203 | (defvar math-deriv-total) | 203 | (defvar math-deriv-total) |
| 204 | (defvar math-deriv-symb) | 204 | (defvar math-deriv-symb) |
| 205 | (defvar math-decls-cache) | ||
| 206 | (defvar math-decls-all) | ||
| 205 | 207 | ||
| 206 | (defun math-derivative (expr) | 208 | (defun math-derivative (expr) |
| 207 | (cond ((equal expr math-deriv-var) | 209 | (cond ((equal expr math-deriv-var) |
diff --git a/lisp/calculator.el b/lisp/calculator.el index f11be4747b1..0c6ad53dbce 100644 --- a/lisp/calculator.el +++ b/lisp/calculator.el | |||
| @@ -4,7 +4,7 @@ | |||
| 4 | 4 | ||
| 5 | ;; Author: Eli Barzilay <eli@barzilay.org> | 5 | ;; Author: Eli Barzilay <eli@barzilay.org> |
| 6 | ;; Keywords: tools, convenience | 6 | ;; Keywords: tools, convenience |
| 7 | ;; Time-stamp: <2002-07-13 01:14:35 eli> | 7 | ;; Time-stamp: <26 May 2005, 14:32:34, Lute Kamstra, pijl> |
| 8 | 8 | ||
| 9 | ;; This file is part of GNU Emacs. | 9 | ;; This file is part of GNU Emacs. |
| 10 | 10 | ||
| @@ -680,7 +680,7 @@ more information. | |||
| 680 | (setq major-mode 'calculator-mode) | 680 | (setq major-mode 'calculator-mode) |
| 681 | (setq mode-name "Calculator") | 681 | (setq mode-name "Calculator") |
| 682 | (use-local-map calculator-mode-map) | 682 | (use-local-map calculator-mode-map) |
| 683 | (run-hooks 'calculator-mode-hook)) | 683 | (run-mode-hooks 'calculator-mode-hook)) |
| 684 | 684 | ||
| 685 | (eval-when-compile (require 'electric) (require 'ehelp)) | 685 | (eval-when-compile (require 'electric) (require 'ehelp)) |
| 686 | 686 | ||
diff --git a/lisp/calendar/calendar.el b/lisp/calendar/calendar.el index 45754110319..fdf565c7923 100644 --- a/lisp/calendar/calendar.el +++ b/lisp/calendar/calendar.el | |||
| @@ -2335,6 +2335,7 @@ movement commands will not work correctly." | |||
| 2335 | (propertize (substitute-command-keys | 2335 | (propertize (substitute-command-keys |
| 2336 | "\\<calendar-mode-map>\\[scroll-calendar-left]") | 2336 | "\\<calendar-mode-map>\\[scroll-calendar-left]") |
| 2337 | 'help-echo "mouse-2: scroll left" | 2337 | 'help-echo "mouse-2: scroll left" |
| 2338 | 'mouse-face 'mode-line-highlight | ||
| 2338 | 'keymap (make-mode-line-mouse-map 'mouse-2 | 2339 | 'keymap (make-mode-line-mouse-map 'mouse-2 |
| 2339 | 'mouse-scroll-calendar-left)) | 2340 | 'mouse-scroll-calendar-left)) |
| 2340 | "Calendar" | 2341 | "Calendar" |
| @@ -2343,12 +2344,14 @@ movement commands will not work correctly." | |||
| 2343 | (substitute-command-keys | 2344 | (substitute-command-keys |
| 2344 | "\\<calendar-mode-map>\\[calendar-goto-info-node] info") | 2345 | "\\<calendar-mode-map>\\[calendar-goto-info-node] info") |
| 2345 | 'help-echo "mouse-2: read Info on Calendar" | 2346 | 'help-echo "mouse-2: read Info on Calendar" |
| 2347 | 'mouse-face 'mode-line-highlight | ||
| 2346 | 'keymap (make-mode-line-mouse-map 'mouse-2 'calendar-goto-info-node)) | 2348 | 'keymap (make-mode-line-mouse-map 'mouse-2 'calendar-goto-info-node)) |
| 2347 | "/" | 2349 | "/" |
| 2348 | (propertize | 2350 | (propertize |
| 2349 | (substitute-command-keys | 2351 | (substitute-command-keys |
| 2350 | "\\<calendar-mode-map>\\[calendar-other-month] other") | 2352 | "\\<calendar-mode-map>\\[calendar-other-month] other") |
| 2351 | 'help-echo "mouse-2: choose another month" | 2353 | 'help-echo "mouse-2: choose another month" |
| 2354 | 'mouse-face 'mode-line-highlight | ||
| 2352 | 'keymap (make-mode-line-mouse-map | 2355 | 'keymap (make-mode-line-mouse-map |
| 2353 | 'mouse-2 'mouse-calendar-other-month)) | 2356 | 'mouse-2 'mouse-calendar-other-month)) |
| 2354 | "/" | 2357 | "/" |
| @@ -2356,11 +2359,13 @@ movement commands will not work correctly." | |||
| 2356 | (substitute-command-keys | 2359 | (substitute-command-keys |
| 2357 | "\\<calendar-mode-map>\\[calendar-goto-today] today") | 2360 | "\\<calendar-mode-map>\\[calendar-goto-today] today") |
| 2358 | 'help-echo "mouse-2: go to today's date" | 2361 | 'help-echo "mouse-2: go to today's date" |
| 2362 | 'mouse-face 'mode-line-highlight | ||
| 2359 | 'keymap (make-mode-line-mouse-map 'mouse-2 #'calendar-goto-today))) | 2363 | 'keymap (make-mode-line-mouse-map 'mouse-2 #'calendar-goto-today))) |
| 2360 | '(calendar-date-string (calendar-current-date) t) | 2364 | '(calendar-date-string (calendar-current-date) t) |
| 2361 | (propertize (substitute-command-keys | 2365 | (propertize (substitute-command-keys |
| 2362 | "\\<calendar-mode-map>\\[scroll-calendar-right]") | 2366 | "\\<calendar-mode-map>\\[scroll-calendar-right]") |
| 2363 | 'help-echo "mouse-2: scroll right" | 2367 | 'help-echo "mouse-2: scroll right" |
| 2368 | 'mouse-face 'mode-line-highlight | ||
| 2364 | 'keymap (make-mode-line-mouse-map | 2369 | 'keymap (make-mode-line-mouse-map |
| 2365 | 'mouse-2 'mouse-scroll-calendar-right))) | 2370 | 'mouse-2 'mouse-scroll-calendar-right))) |
| 2366 | "The mode line of the calendar buffer. | 2371 | "The mode line of the calendar buffer. |
diff --git a/lisp/calendar/diary-lib.el b/lisp/calendar/diary-lib.el index 312b8841cf9..6aec579c107 100644 --- a/lisp/calendar/diary-lib.el +++ b/lisp/calendar/diary-lib.el | |||
| @@ -1050,15 +1050,16 @@ changing the variable `diary-include-string'." | |||
| 1050 | (regexp-quote diary-include-string) | 1050 | (regexp-quote diary-include-string) |
| 1051 | " \"\\([^\"]*\\)\"") | 1051 | " \"\\([^\"]*\\)\"") |
| 1052 | nil t) | 1052 | nil t) |
| 1053 | (let ((diary-file (substitute-in-file-name | 1053 | (let* ((diary-file (substitute-in-file-name |
| 1054 | (buffer-substring-no-properties | 1054 | (match-string-no-properties 2))) |
| 1055 | (match-beginning 2) (match-end 2)))) | 1055 | (mark-diary-entries-hook 'mark-included-diary-files) |
| 1056 | (mark-diary-entries-hook 'mark-included-diary-files)) | 1056 | (dbuff (find-buffer-visiting diary-file))) |
| 1057 | (if (file-exists-p diary-file) | 1057 | (if (file-exists-p diary-file) |
| 1058 | (if (file-readable-p diary-file) | 1058 | (if (file-readable-p diary-file) |
| 1059 | (progn | 1059 | (progn |
| 1060 | (mark-diary-entries) | 1060 | (mark-diary-entries) |
| 1061 | (kill-buffer (find-buffer-visiting diary-file))) | 1061 | (unless dbuff |
| 1062 | (kill-buffer (find-buffer-visiting diary-file)))) | ||
| 1062 | (beep) | 1063 | (beep) |
| 1063 | (message "Can't read included diary file %s" diary-file) | 1064 | (message "Can't read included diary file %s" diary-file) |
| 1064 | (sleep-for 2)) | 1065 | (sleep-for 2)) |
diff --git a/lisp/calendar/icalendar.el b/lisp/calendar/icalendar.el index f37b966a45a..d15a4b78e2f 100644 --- a/lisp/calendar/icalendar.el +++ b/lisp/calendar/icalendar.el | |||
| @@ -165,7 +165,6 @@ replaced by the organizer." | |||
| 165 | ;; all the other libs we need | 165 | ;; all the other libs we need |
| 166 | ;; ====================================================================== | 166 | ;; ====================================================================== |
| 167 | (require 'calendar) | 167 | (require 'calendar) |
| 168 | (require 'appt) | ||
| 169 | 168 | ||
| 170 | ;; ====================================================================== | 169 | ;; ====================================================================== |
| 171 | ;; misc | 170 | ;; misc |
diff --git a/lisp/calendar/todo-mode.el b/lisp/calendar/todo-mode.el index 0caedee7c8a..132f42369c6 100644 --- a/lisp/calendar/todo-mode.el +++ b/lisp/calendar/todo-mode.el | |||
| @@ -904,11 +904,12 @@ Number of entries for each category is given by `todo-print-priorities'." | |||
| 904 | 904 | ||
| 905 | \\{todo-mode-map}" | 905 | \\{todo-mode-map}" |
| 906 | (interactive) | 906 | (interactive) |
| 907 | (kill-all-local-variables) | ||
| 907 | (setq major-mode 'todo-mode) | 908 | (setq major-mode 'todo-mode) |
| 908 | (setq mode-name "TODO") | 909 | (setq mode-name "TODO") |
| 909 | (use-local-map todo-mode-map) | 910 | (use-local-map todo-mode-map) |
| 910 | (easy-menu-add todo-menu) | 911 | (easy-menu-add todo-menu) |
| 911 | (run-hooks 'todo-mode-hook)) | 912 | (run-mode-hooks 'todo-mode-hook)) |
| 912 | 913 | ||
| 913 | (eval-when-compile | 914 | (eval-when-compile |
| 914 | (defvar date) | 915 | (defvar date) |
diff --git a/lisp/chistory.el b/lisp/chistory.el index dde30c75e0e..ddbc0863a0e 100644 --- a/lisp/chistory.el +++ b/lisp/chistory.el | |||
| @@ -145,7 +145,7 @@ Keybindings: | |||
| 145 | (setq major-mode 'command-history-mode) | 145 | (setq major-mode 'command-history-mode) |
| 146 | (setq mode-name "Command History") | 146 | (setq mode-name "Command History") |
| 147 | (use-local-map command-history-map) | 147 | (use-local-map command-history-map) |
| 148 | (run-hooks 'command-history-mode-hook)) | 148 | (run-mode-hooks 'command-history-mode-hook)) |
| 149 | 149 | ||
| 150 | (defun Command-history-setup () | 150 | (defun Command-history-setup () |
| 151 | (kill-all-local-variables) | 151 | (kill-all-local-variables) |
diff --git a/lisp/comint.el b/lisp/comint.el index fbb5810de16..37550b7b6d9 100644 --- a/lisp/comint.el +++ b/lisp/comint.el | |||
| @@ -3437,7 +3437,7 @@ REGEXP-GROUP is the regular expression group in REGEXP to use." | |||
| 3437 | ;; (make-local-variable 'shell-directory-stack) | 3437 | ;; (make-local-variable 'shell-directory-stack) |
| 3438 | ;; (setq shell-directory-stack nil) | 3438 | ;; (setq shell-directory-stack nil) |
| 3439 | ;; (add-hook 'comint-input-filter-functions 'shell-directory-tracker) | 3439 | ;; (add-hook 'comint-input-filter-functions 'shell-directory-tracker) |
| 3440 | ;; (run-hooks 'shell-mode-hook)) | 3440 | ;; (run-mode-hooks 'shell-mode-hook)) |
| 3441 | ;; | 3441 | ;; |
| 3442 | ;; | 3442 | ;; |
| 3443 | ;; Completion for comint-mode users | 3443 | ;; Completion for comint-mode users |
diff --git a/lisp/cus-edit.el b/lisp/cus-edit.el index 50c9accb9ce..82a5e887bed 100644 --- a/lisp/cus-edit.el +++ b/lisp/cus-edit.el | |||
| @@ -4276,7 +4276,7 @@ if that value is non-nil." | |||
| 4276 | (set (make-local-variable 'widget-link-prefix) "") | 4276 | (set (make-local-variable 'widget-link-prefix) "") |
| 4277 | (set (make-local-variable 'widget-link-suffix) "")) | 4277 | (set (make-local-variable 'widget-link-suffix) "")) |
| 4278 | (add-hook 'widget-edit-functions 'custom-state-buffer-message nil t) | 4278 | (add-hook 'widget-edit-functions 'custom-state-buffer-message nil t) |
| 4279 | (run-hooks 'custom-mode-hook)) | 4279 | (run-mode-hooks 'custom-mode-hook)) |
| 4280 | 4280 | ||
| 4281 | (put 'custom-mode 'mode-class 'special) | 4281 | (put 'custom-mode 'mode-class 'special) |
| 4282 | 4282 | ||
diff --git a/lisp/descr-text.el b/lisp/descr-text.el index d8ef9be6f81..03c12a8f7ba 100644 --- a/lisp/descr-text.el +++ b/lisp/descr-text.el | |||
| @@ -61,7 +61,7 @@ if that value is non-nil." | |||
| 61 | (use-local-map describe-text-mode-map) | 61 | (use-local-map describe-text-mode-map) |
| 62 | (widget-setup) | 62 | (widget-setup) |
| 63 | (add-hook 'change-major-mode-hook 'font-lock-defontify nil t) | 63 | (add-hook 'change-major-mode-hook 'font-lock-defontify nil t) |
| 64 | (run-hooks 'describe-text-mode-hook)) | 64 | (run-mode-hooks 'describe-text-mode-hook)) |
| 65 | 65 | ||
| 66 | ;;; Describe-Text Utilities. | 66 | ;;; Describe-Text Utilities. |
| 67 | 67 | ||
diff --git a/lisp/ebuff-menu.el b/lisp/ebuff-menu.el index bfac2afe6e9..ec230bc8a62 100644 --- a/lisp/ebuff-menu.el +++ b/lisp/ebuff-menu.el | |||
| @@ -162,7 +162,7 @@ Entry to this mode via command `electric-buffer-list' calls the value of | |||
| 162 | (setq major-mode 'Electric-buffer-menu-mode) | 162 | (setq major-mode 'Electric-buffer-menu-mode) |
| 163 | (goto-char (point-min)) | 163 | (goto-char (point-min)) |
| 164 | (if (search-forward "\n." nil t) (forward-char -1)) | 164 | (if (search-forward "\n." nil t) (forward-char -1)) |
| 165 | (run-hooks 'electric-buffer-menu-mode-hook)) | 165 | (run-mode-hooks 'electric-buffer-menu-mode-hook)) |
| 166 | 166 | ||
| 167 | ;; generally the same as Buffer-menu-mode-map | 167 | ;; generally the same as Buffer-menu-mode-map |
| 168 | ;; (except we don't indirect to global-map) | 168 | ;; (except we don't indirect to global-map) |
diff --git a/lisp/ediff-diff.el b/lisp/ediff-diff.el index 4c13e6fc0e1..ec496301405 100644 --- a/lisp/ediff-diff.el +++ b/lisp/ediff-diff.el | |||
| @@ -1353,7 +1353,7 @@ Symlinks and the likes are not handled. | |||
| 1353 | If FILTER-RE is non-nil, recursive checking in directories | 1353 | If FILTER-RE is non-nil, recursive checking in directories |
| 1354 | affects only files whose names match the expression." | 1354 | affects only files whose names match the expression." |
| 1355 | ;; Normalize empty filter RE to nil. | 1355 | ;; Normalize empty filter RE to nil. |
| 1356 | (unless (length filter-re) (setq filter-re nil)) | 1356 | (unless (> (length filter-re) 0) (setq filter-re nil)) |
| 1357 | ;; Indicate progress | 1357 | ;; Indicate progress |
| 1358 | (message "Comparing '%s' and '%s' modulo '%s'" d1 d2 filter-re) | 1358 | (message "Comparing '%s' and '%s' modulo '%s'" d1 d2 filter-re) |
| 1359 | (cond | 1359 | (cond |
| @@ -1367,27 +1367,11 @@ affects only files whose names match the expression." | |||
| 1367 | (if (eq ediff-recurse-to-subdirectories 'yes) | 1367 | (if (eq ediff-recurse-to-subdirectories 'yes) |
| 1368 | (let* ((all-entries-1 (directory-files d1 t filter-re)) | 1368 | (let* ((all-entries-1 (directory-files d1 t filter-re)) |
| 1369 | (all-entries-2 (directory-files d2 t filter-re)) | 1369 | (all-entries-2 (directory-files d2 t filter-re)) |
| 1370 | (entries-1 (remove-if (lambda (s) | 1370 | (entries-1 (ediff-delete-all-matches "^\\.\\.?$" all-entries-1)) |
| 1371 | (string-match "^\\.\\.?$" | 1371 | (entries-2 (ediff-delete-all-matches "^\\.\\.?$" all-entries-2)) |
| 1372 | (file-name-nondirectory s))) | ||
| 1373 | all-entries-1)) | ||
| 1374 | (entries-2 (remove-if (lambda (s) | ||
| 1375 | (string-match "^\\.\\.?$" | ||
| 1376 | (file-name-nondirectory s))) | ||
| 1377 | all-entries-2)) | ||
| 1378 | ) | 1372 | ) |
| 1379 | ;; First, check only the names (works quickly and ensures a | 1373 | |
| 1380 | ;; precondition for subsequent code) | 1374 | (ediff-same-file-contents-lists entries-1 entries-2 filter-re) |
| 1381 | (if (and (= (length entries-1) (length entries-2)) | ||
| 1382 | (every (lambda (a b) (equal (file-name-nondirectory a) | ||
| 1383 | (file-name-nondirectory b))) | ||
| 1384 | entries-1 entries-2)) | ||
| 1385 | ;; With name equality established, compare the entries | ||
| 1386 | ;; through recursion. | ||
| 1387 | (every (lambda (a b) | ||
| 1388 | (ediff-same-contents a b filter-re)) | ||
| 1389 | entries-1 entries-2) | ||
| 1390 | ) | ||
| 1391 | )) | 1375 | )) |
| 1392 | ) ; end of the directories case | 1376 | ) ; end of the directories case |
| 1393 | ;; D1 & D2 are both files => compare directly | 1377 | ;; D1 & D2 are both files => compare directly |
| @@ -1398,6 +1382,42 @@ affects only files whose names match the expression." | |||
| 1398 | ) | 1382 | ) |
| 1399 | ) | 1383 | ) |
| 1400 | 1384 | ||
| 1385 | ;; If lists have the same length and names of files are pairwise equal | ||
| 1386 | ;; (removing the directories) then compare contents pairwise. | ||
| 1387 | ;; True if all contents are the same; false otherwise | ||
| 1388 | (defun ediff-same-file-contents-lists (entries-1 entries-2 filter-re) | ||
| 1389 | ;; First, check only the names (works quickly and ensures a | ||
| 1390 | ;; precondition for subsequent code) | ||
| 1391 | (if (and (= (length entries-1) (length entries-2)) | ||
| 1392 | (equal (mapcar 'file-name-nondirectory entries-1) | ||
| 1393 | (mapcar 'file-name-nondirectory entries-2))) | ||
| 1394 | ;; With name equality established, compare the entries | ||
| 1395 | ;; through recursion. | ||
| 1396 | (let ((continue t)) | ||
| 1397 | (while (and entries-1 continue) | ||
| 1398 | (if (ediff-same-contents | ||
| 1399 | (car entries-1) (car entries-2) filter-re) | ||
| 1400 | (setq entries-1 (cdr entries-1) | ||
| 1401 | entries-2 (cdr entries-2)) | ||
| 1402 | (setq continue nil)) | ||
| 1403 | ) | ||
| 1404 | ;; if reached the end then lists are equal | ||
| 1405 | (null entries-1)) | ||
| 1406 | ) | ||
| 1407 | ) | ||
| 1408 | |||
| 1409 | |||
| 1410 | ;; ARG1 is a regexp, ARG2 is a list of full-filenames | ||
| 1411 | ;; Delete all entries that match the regexp | ||
| 1412 | (defun ediff-delete-all-matches (regex file-list-list) | ||
| 1413 | (let (result elt) | ||
| 1414 | (while file-list-list | ||
| 1415 | (setq elt (car file-list-list)) | ||
| 1416 | (or (string-match regex (file-name-nondirectory elt)) | ||
| 1417 | (setq result (cons elt result))) | ||
| 1418 | (setq file-list-list (cdr file-list-list))) | ||
| 1419 | (reverse result))) | ||
| 1420 | |||
| 1401 | 1421 | ||
| 1402 | ;;; Local Variables: | 1422 | ;;; Local Variables: |
| 1403 | ;;; eval: (put 'ediff-defvar-local 'lisp-indent-hook 'defun) | 1423 | ;;; eval: (put 'ediff-defvar-local 'lisp-indent-hook 'defun) |
diff --git a/lisp/ediff-help.el b/lisp/ediff-help.el index bdd92f5c12d..69d170faedf 100644 --- a/lisp/ediff-help.el +++ b/lisp/ediff-help.el | |||
| @@ -132,7 +132,7 @@ Normally, not a user option. See `ediff-help-message' for details.") | |||
| 132 | "Normally, not a user option. See `ediff-help-message' for details.") | 132 | "Normally, not a user option. See `ediff-help-message' for details.") |
| 133 | 133 | ||
| 134 | (defconst ediff-brief-message-string | 134 | (defconst ediff-brief-message-string |
| 135 | " ? -quick help " | 135 | " Type ? for help" |
| 136 | "Contents of the brief help message.") | 136 | "Contents of the brief help message.") |
| 137 | ;; The actual brief help message | 137 | ;; The actual brief help message |
| 138 | (ediff-defvar-local ediff-brief-help-message "" | 138 | (ediff-defvar-local ediff-brief-help-message "" |
diff --git a/lisp/ediff-mult.el b/lisp/ediff-mult.el index 41a7699cfdc..88ab31fe56a 100644 --- a/lisp/ediff-mult.el +++ b/lisp/ediff-mult.el | |||
| @@ -560,17 +560,23 @@ behavior." | |||
| 560 | (ediff-add-slash-if-directory auxdir1 elt)) | 560 | (ediff-add-slash-if-directory auxdir1 elt)) |
| 561 | lis1) | 561 | lis1) |
| 562 | auxdir2 (file-name-as-directory dir2) | 562 | auxdir2 (file-name-as-directory dir2) |
| 563 | lis2 (directory-files auxdir2 nil regexp) | ||
| 564 | lis2 (delete "." lis2) | ||
| 565 | lis2 (delete ".." lis2) | ||
| 563 | lis2 (mapcar | 566 | lis2 (mapcar |
| 564 | (lambda (elt) | 567 | (lambda (elt) |
| 565 | (ediff-add-slash-if-directory auxdir2 elt)) | 568 | (ediff-add-slash-if-directory auxdir2 elt)) |
| 566 | (directory-files auxdir2 nil regexp))) | 569 | lis2)) |
| 567 | 570 | ||
| 568 | (if (stringp dir3) | 571 | (if (stringp dir3) |
| 569 | (setq auxdir3 (file-name-as-directory dir3) | 572 | (setq auxdir3 (file-name-as-directory dir3) |
| 573 | lis3 (directory-files auxdir3 nil regexp) | ||
| 574 | lis3 (delete "." lis3) | ||
| 575 | lis3 (delete ".." lis3) | ||
| 570 | lis3 (mapcar | 576 | lis3 (mapcar |
| 571 | (lambda (elt) | 577 | (lambda (elt) |
| 572 | (ediff-add-slash-if-directory auxdir3 elt)) | 578 | (ediff-add-slash-if-directory auxdir3 elt)) |
| 573 | (directory-files auxdir3 nil regexp)))) | 579 | lis3))) |
| 574 | 580 | ||
| 575 | (if (ediff-nonempty-string-p merge-autostore-dir) | 581 | (if (ediff-nonempty-string-p merge-autostore-dir) |
| 576 | (setq merge-autostore-dir | 582 | (setq merge-autostore-dir |
diff --git a/lisp/ediff-util.el b/lisp/ediff-util.el index 79f85cc1896..b952c2fb2bf 100644 --- a/lisp/ediff-util.el +++ b/lisp/ediff-util.el | |||
| @@ -1,6 +1,7 @@ | |||
| 1 | ;;; ediff-util.el --- the core commands and utilities of ediff | 1 | ;;; ediff-util.el --- the core commands and utilities of ediff |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1994, 95, 96, 97, 98, 99, 2000, 01, 02, 04 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, |
| 4 | ;; 2004 Free Software Foundation, Inc. | ||
| 4 | 5 | ||
| 5 | ;; Author: Michael Kifer <kifer@cs.stonybrook.edu> | 6 | ;; Author: Michael Kifer <kifer@cs.stonybrook.edu> |
| 6 | 7 | ||
diff --git a/lisp/ediff.el b/lisp/ediff.el index 2a2b481ec59..00a7e2f512a 100644 --- a/lisp/ediff.el +++ b/lisp/ediff.el | |||
| @@ -7,7 +7,7 @@ | |||
| 7 | ;; Keywords: comparing, merging, patching, tools, unix | 7 | ;; Keywords: comparing, merging, patching, tools, unix |
| 8 | 8 | ||
| 9 | (defconst ediff-version "2.80" "The current version of Ediff") | 9 | (defconst ediff-version "2.80" "The current version of Ediff") |
| 10 | (defconst ediff-date "February 19, 2005" "Date of last update") | 10 | (defconst ediff-date "June 3, 2005" "Date of last update") |
| 11 | 11 | ||
| 12 | 12 | ||
| 13 | ;; This file is part of GNU Emacs. | 13 | ;; This file is part of GNU Emacs. |
diff --git a/lisp/emacs-lisp/bytecomp.el b/lisp/emacs-lisp/bytecomp.el index aab4efab9f8..16ade261344 100644 --- a/lisp/emacs-lisp/bytecomp.el +++ b/lisp/emacs-lisp/bytecomp.el | |||
| @@ -1248,15 +1248,15 @@ extra args." | |||
| 1248 | (defun byte-compile-nogroup-warn (form) | 1248 | (defun byte-compile-nogroup-warn (form) |
| 1249 | (let ((keyword-args (cdr (cdr (cdr (cdr form))))) | 1249 | (let ((keyword-args (cdr (cdr (cdr (cdr form))))) |
| 1250 | (name (cadr form))) | 1250 | (name (cadr form))) |
| 1251 | (unless (plist-get keyword-args :group) | 1251 | (or (plist-get keyword-args :group) |
| 1252 | (byte-compile-warn | 1252 | (not (and (consp name) (eq (car name) 'quote))) |
| 1253 | "%s for `%s' fails to specify containing group" | 1253 | (byte-compile-warn |
| 1254 | (cdr (assq (car form) | 1254 | "%s for `%s' fails to specify containing group" |
| 1255 | '((custom-declare-group . defgroup) | 1255 | (cdr (assq (car form) |
| 1256 | (custom-declare-face . defface) | 1256 | '((custom-declare-group . defgroup) |
| 1257 | (custom-declare-variable . defcustom)))) | 1257 | (custom-declare-face . defface) |
| 1258 | (if (and (consp name) (eq (car name) 'quote)) | 1258 | (custom-declare-variable . defcustom)))) |
| 1259 | (cadr name) name))))) | 1259 | (cadr name))))) |
| 1260 | 1260 | ||
| 1261 | ;; Warn if the function or macro is being redefined with a different | 1261 | ;; Warn if the function or macro is being redefined with a different |
| 1262 | ;; number of arguments. | 1262 | ;; number of arguments. |
diff --git a/lisp/emacs-lisp/cl-macs.el b/lisp/emacs-lisp/cl-macs.el index 1be2f9171a6..c47c306e014 100644 --- a/lisp/emacs-lisp/cl-macs.el +++ b/lisp/emacs-lisp/cl-macs.el | |||
| @@ -1565,14 +1565,21 @@ form. See `defsetf' for a simpler way to define most setf-methods. | |||
| 1565 | This macro is an easy-to-use substitute for `define-setf-method' that works | 1565 | This macro is an easy-to-use substitute for `define-setf-method' that works |
| 1566 | well for simple place forms. In the simple `defsetf' form, `setf's of | 1566 | well for simple place forms. In the simple `defsetf' form, `setf's of |
| 1567 | the form (setf (NAME ARGS...) VAL) are transformed to function or macro | 1567 | the form (setf (NAME ARGS...) VAL) are transformed to function or macro |
| 1568 | calls of the form (FUNC ARGS... VAL). Example: (defsetf aref aset). | 1568 | calls of the form (FUNC ARGS... VAL). Example: |
| 1569 | |||
| 1570 | (defsetf aref aset) | ||
| 1571 | |||
| 1569 | Alternate form: (defsetf NAME ARGLIST (STORE) BODY...). | 1572 | Alternate form: (defsetf NAME ARGLIST (STORE) BODY...). |
| 1570 | Here, the above `setf' call is expanded by binding the argument forms ARGS | 1573 | Here, the above `setf' call is expanded by binding the argument forms ARGS |
| 1571 | according to ARGLIST, binding the value form VAL to STORE, then executing | 1574 | according to ARGLIST, binding the value form VAL to STORE, then executing |
| 1572 | BODY, which must return a Lisp form that does the necessary `setf' operation. | 1575 | BODY, which must return a Lisp form that does the necessary `setf' operation. |
| 1573 | Actually, ARGLIST and STORE may be bound to temporary variables which are | 1576 | Actually, ARGLIST and STORE may be bound to temporary variables which are |
| 1574 | introduced automatically to preserve proper execution order of the arguments. | 1577 | introduced automatically to preserve proper execution order of the arguments. |
| 1575 | Example: (defsetf nth (n x) (v) (list 'setcar (list 'nthcdr n x) v))." | 1578 | Example: |
| 1579 | |||
| 1580 | (defsetf nth (n x) (v) (list 'setcar (list 'nthcdr n x) v)) | ||
| 1581 | |||
| 1582 | \(fn NAME [FUNC | ARGLIST (STORE) BODY...])" | ||
| 1576 | (if (listp arg1) | 1583 | (if (listp arg1) |
| 1577 | (let* ((largs nil) (largsr nil) | 1584 | (let* ((largs nil) (largsr nil) |
| 1578 | (temps nil) (tempsr nil) | 1585 | (temps nil) (tempsr nil) |
diff --git a/lisp/emacs-lisp/easy-mmode.el b/lisp/emacs-lisp/easy-mmode.el index 188dc172e07..bb0fa666217 100644 --- a/lisp/emacs-lisp/easy-mmode.el +++ b/lisp/emacs-lisp/easy-mmode.el | |||
| @@ -271,14 +271,26 @@ With zero or negative ARG turn mode off. | |||
| 271 | TURN-ON is a function that will be called with no args in every buffer | 271 | TURN-ON is a function that will be called with no args in every buffer |
| 272 | and that should try to turn MODE on if applicable for that buffer. | 272 | and that should try to turn MODE on if applicable for that buffer. |
| 273 | KEYS is a list of CL-style keyword arguments: | 273 | KEYS is a list of CL-style keyword arguments: |
| 274 | :group to specify the custom group." | 274 | :group to specify the custom group. |
| 275 | |||
| 276 | If MODE's set-up depends on the major mode in effect when it was | ||
| 277 | enabled, then disabling and reenabling MODE should make MODE work | ||
| 278 | correctly with the current major mode. This is important to | ||
| 279 | prevent problems with derived modes, that is, major modes that | ||
| 280 | call another major mode in their body." | ||
| 281 | |||
| 275 | (let* ((global-mode-name (symbol-name global-mode)) | 282 | (let* ((global-mode-name (symbol-name global-mode)) |
| 276 | (pretty-name (easy-mmode-pretty-mode-name mode)) | 283 | (pretty-name (easy-mmode-pretty-mode-name mode)) |
| 277 | (pretty-global-name (easy-mmode-pretty-mode-name global-mode)) | 284 | (pretty-global-name (easy-mmode-pretty-mode-name global-mode)) |
| 278 | (group nil) | 285 | (group nil) |
| 279 | (extra-args nil) | 286 | (extra-args nil) |
| 280 | (buffers (intern (concat global-mode-name "-buffers"))) | 287 | (MODE-buffers (intern (concat global-mode-name "-buffers"))) |
| 281 | (cmmh (intern (concat global-mode-name "-cmmh")))) | 288 | (MODE-enable-in-buffers |
| 289 | (intern (concat global-mode-name "-enable-in-buffers"))) | ||
| 290 | (MODE-check-buffers | ||
| 291 | (intern (concat global-mode-name "-check-buffers"))) | ||
| 292 | (MODE-cmhh (intern (concat global-mode-name "-cmhh"))) | ||
| 293 | (MODE-major-mode (intern (concat (symbol-name mode) "-major-mode")))) | ||
| 282 | 294 | ||
| 283 | ;; Check keys. | 295 | ;; Check keys. |
| 284 | (while (keywordp (car keys)) | 296 | (while (keywordp (car keys)) |
| @@ -294,6 +306,8 @@ KEYS is a list of CL-style keyword arguments: | |||
| 294 | "-mode\\'" "" (symbol-name mode)))))) | 306 | "-mode\\'" "" (symbol-name mode)))))) |
| 295 | 307 | ||
| 296 | `(progn | 308 | `(progn |
| 309 | (defvar ,MODE-major-mode nil) | ||
| 310 | (make-variable-buffer-local ',MODE-major-mode) | ||
| 297 | ;; The actual global minor-mode | 311 | ;; The actual global minor-mode |
| 298 | (define-minor-mode ,global-mode | 312 | (define-minor-mode ,global-mode |
| 299 | ,(format "Toggle %s in every buffer. | 313 | ,(format "Toggle %s in every buffer. |
| @@ -306,10 +320,13 @@ in which `%s' turns it on." | |||
| 306 | ;; Setup hook to handle future mode changes and new buffers. | 320 | ;; Setup hook to handle future mode changes and new buffers. |
| 307 | (if ,global-mode | 321 | (if ,global-mode |
| 308 | (progn | 322 | (progn |
| 309 | (add-hook 'after-change-major-mode-hook ',buffers) | 323 | (add-hook 'after-change-major-mode-hook |
| 310 | (add-hook 'change-major-mode-hook ',cmmh)) | 324 | ',MODE-enable-in-buffers) |
| 311 | (remove-hook 'after-change-major-mode-hook ',buffers) | 325 | (add-hook 'find-file-hook ',MODE-check-buffers) |
| 312 | (remove-hook 'change-major-mode-hook ',cmmh)) | 326 | (add-hook 'change-major-mode-hook ',MODE-cmhh)) |
| 327 | (remove-hook 'after-change-major-mode-hook ',MODE-enable-in-buffers) | ||
| 328 | (remove-hook 'find-file-hook ',MODE-check-buffers) | ||
| 329 | (remove-hook 'change-major-mode-hook ',MODE-cmhh)) | ||
| 313 | 330 | ||
| 314 | ;; Go through existing buffers. | 331 | ;; Go through existing buffers. |
| 315 | (dolist (buf (buffer-list)) | 332 | (dolist (buf (buffer-list)) |
| @@ -321,22 +338,33 @@ in which `%s' turns it on." | |||
| 321 | :autoload-end | 338 | :autoload-end |
| 322 | 339 | ||
| 323 | ;; List of buffers left to process. | 340 | ;; List of buffers left to process. |
| 324 | (defvar ,buffers nil) | 341 | (defvar ,MODE-buffers nil) |
| 325 | 342 | ||
| 326 | ;; The function that calls TURN-ON in each buffer. | 343 | ;; The function that calls TURN-ON in each buffer. |
| 327 | (defun ,buffers () | 344 | (defun ,MODE-enable-in-buffers () |
| 328 | (remove-hook 'post-command-hook ',buffers) | 345 | (dolist (buf ,MODE-buffers) |
| 329 | (while ,buffers | 346 | (when (buffer-live-p buf) |
| 330 | (let ((buf (pop ,buffers))) | 347 | (with-current-buffer buf |
| 331 | (when (buffer-live-p buf) | 348 | (if ,mode |
| 332 | (with-current-buffer buf (,turn-on)))))) | 349 | (unless (eq ,MODE-major-mode major-mode) |
| 333 | (put ',buffers 'definition-name ',global-mode) | 350 | (,mode -1) |
| 351 | (,turn-on) | ||
| 352 | (setq ,MODE-major-mode major-mode)) | ||
| 353 | (,turn-on) | ||
| 354 | (setq ,MODE-major-mode major-mode)))))) | ||
| 355 | (put ',MODE-enable-in-buffers 'definition-name ',global-mode) | ||
| 356 | |||
| 357 | (defun ,MODE-check-buffers () | ||
| 358 | (,MODE-enable-in-buffers) | ||
| 359 | (setq ,MODE-buffers nil) | ||
| 360 | (remove-hook 'post-command-hook ',MODE-check-buffers)) | ||
| 361 | (put ',MODE-check-buffers 'definition-name ',global-mode) | ||
| 334 | 362 | ||
| 335 | ;; The function that catches kill-all-local-variables. | 363 | ;; The function that catches kill-all-local-variables. |
| 336 | (defun ,cmmh () | 364 | (defun ,MODE-cmhh () |
| 337 | (add-to-list ',buffers (current-buffer)) | 365 | (add-to-list ',MODE-buffers (current-buffer)) |
| 338 | (add-hook 'post-command-hook ',buffers)) | 366 | (add-hook 'post-command-hook ',MODE-check-buffers)) |
| 339 | (put ',cmmh 'definition-name ',global-mode)))) | 367 | (put ',MODE-cmhh 'definition-name ',global-mode)))) |
| 340 | 368 | ||
| 341 | ;;; | 369 | ;;; |
| 342 | ;;; easy-mmode-defmap | 370 | ;;; easy-mmode-defmap |
diff --git a/lisp/emacs-lisp/easymenu.el b/lisp/emacs-lisp/easymenu.el index b3160c9b752..982570fb348 100644 --- a/lisp/emacs-lisp/easymenu.el +++ b/lisp/emacs-lisp/easymenu.el | |||
| @@ -1,6 +1,7 @@ | |||
| 1 | ;;; easymenu.el --- support the easymenu interface for defining a menu | 1 | ;;; easymenu.el --- support the easymenu interface for defining a menu |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1994,96,98,1999,2000,2004 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 1994, 1996, 1998, 1999, 2000, 2004, 2005 |
| 4 | ;; Free Software Foundation, Inc. | ||
| 4 | 5 | ||
| 5 | ;; Keywords: emulations | 6 | ;; Keywords: emulations |
| 6 | ;; Author: Richard Stallman <rms@gnu.org> | 7 | ;; Author: Richard Stallman <rms@gnu.org> |
| @@ -534,7 +535,7 @@ earlier by `easy-menu-define' or `easy-menu-create-menu'." | |||
| 534 | (easy-menu-do-add-item map item before))) | 535 | (easy-menu-do-add-item map item before))) |
| 535 | 536 | ||
| 536 | (defun easy-menu-item-present-p (map path name) | 537 | (defun easy-menu-item-present-p (map path name) |
| 537 | "In submenu of MAP with path PATH, return true iff item NAME is present. | 538 | "In submenu of MAP with path PATH, return non-nil iff item NAME is present. |
| 538 | MAP and PATH are defined as in `easy-menu-add-item'. | 539 | MAP and PATH are defined as in `easy-menu-add-item'. |
| 539 | NAME should be a string, the name of the element to be looked for." | 540 | NAME should be a string, the name of the element to be looked for." |
| 540 | (easy-menu-return-item (easy-menu-get-map map path) name)) | 541 | (easy-menu-return-item (easy-menu-get-map map path) name)) |
| @@ -552,7 +553,14 @@ NAME should be a string, the name of the element to be removed." | |||
| 552 | "In menu MENU try to look for menu item with name NAME. | 553 | "In menu MENU try to look for menu item with name NAME. |
| 553 | If a menu item is found, return (NAME . item), otherwise return nil. | 554 | If a menu item is found, return (NAME . item), otherwise return nil. |
| 554 | If item is an old format item, a new format item is returned." | 555 | If item is an old format item, a new format item is returned." |
| 555 | (let ((item (lookup-key menu (vector (easy-menu-intern name)))) | 556 | ;; The call to `lookup-key' also calls the C function `get_keyelt' which |
| 557 | ;; looks inside a menu-item to only return the actual command. This is | ||
| 558 | ;; not what we want here. We should either add an arg to lookup-key to be | ||
| 559 | ;; able to turn off this "feature", or else we could use map-keymap here. | ||
| 560 | ;; In the mean time, I just use `assq' which is an OK approximation since | ||
| 561 | ;; menus are rarely built from vectors or char-tables. | ||
| 562 | (let ((item (or (cdr (assq name menu)) | ||
| 563 | (lookup-key menu (vector (easy-menu-intern name))))) | ||
| 556 | ret enable cache label) | 564 | ret enable cache label) |
| 557 | (cond | 565 | (cond |
| 558 | ((stringp (car-safe item)) | 566 | ((stringp (car-safe item)) |
diff --git a/lisp/emacs-lisp/find-func.el b/lisp/emacs-lisp/find-func.el index eab957e5671..9a0a1606953 100644 --- a/lisp/emacs-lisp/find-func.el +++ b/lisp/emacs-lisp/find-func.el | |||
| @@ -246,8 +246,6 @@ searched for in `find-function-source-path' if non nil, otherwise | |||
| 246 | in `load-path'." | 246 | in `load-path'." |
| 247 | (if (not function) | 247 | (if (not function) |
| 248 | (error "You didn't specify a function")) | 248 | (error "You didn't specify a function")) |
| 249 | (and (subrp (symbol-function function)) | ||
| 250 | (error "%s is a primitive function" function)) | ||
| 251 | (let ((def (symbol-function function)) | 249 | (let ((def (symbol-function function)) |
| 252 | aliases) | 250 | aliases) |
| 253 | (while (symbolp def) | 251 | (while (symbolp def) |
| @@ -265,6 +263,8 @@ in `load-path'." | |||
| 265 | (let ((library | 263 | (let ((library |
| 266 | (cond ((eq (car-safe def) 'autoload) | 264 | (cond ((eq (car-safe def) 'autoload) |
| 267 | (nth 1 def)) | 265 | (nth 1 def)) |
| 266 | ((subrp def) | ||
| 267 | (help-C-file-name def 'subr)) | ||
| 268 | ((symbol-file function 'defun))))) | 268 | ((symbol-file function 'defun))))) |
| 269 | (find-function-search-for-symbol function nil library)))) | 269 | (find-function-search-for-symbol function nil library)))) |
| 270 | 270 | ||
diff --git a/lisp/emacs-lisp/re-builder.el b/lisp/emacs-lisp/re-builder.el index a2aed39d00a..8a53c202ed8 100644 --- a/lisp/emacs-lisp/re-builder.el +++ b/lisp/emacs-lisp/re-builder.el | |||
| @@ -254,7 +254,7 @@ Except for Lisp syntax this is the same as `reb-regexp'.") | |||
| 254 | mode-name "RE Builder") | 254 | mode-name "RE Builder") |
| 255 | (use-local-map reb-mode-map) | 255 | (use-local-map reb-mode-map) |
| 256 | (reb-mode-common) | 256 | (reb-mode-common) |
| 257 | (run-hooks 'reb-mode-hook)) | 257 | (run-mode-hooks 'reb-mode-hook)) |
| 258 | 258 | ||
| 259 | (define-derived-mode reb-lisp-mode | 259 | (define-derived-mode reb-lisp-mode |
| 260 | emacs-lisp-mode "RE Builder Lisp" | 260 | emacs-lisp-mode "RE Builder Lisp" |
diff --git a/lisp/emulation/tpu-mapper.el b/lisp/emulation/tpu-mapper.el index 68a760e2011..db2daf09093 100644 --- a/lisp/emulation/tpu-mapper.el +++ b/lisp/emulation/tpu-mapper.el | |||
| @@ -375,7 +375,7 @@ | |||
| 375 | ;;; | 375 | ;;; |
| 376 | ;;; Load the newly defined keys and clean up | 376 | ;;; Load the newly defined keys and clean up |
| 377 | ;;; | 377 | ;;; |
| 378 | (eval-current-buffer) | 378 | (eval-buffer) |
| 379 | (kill-buffer (current-buffer)) | 379 | (kill-buffer (current-buffer)) |
| 380 | (kill-buffer "*scratch*") | 380 | (kill-buffer "*scratch*") |
| 381 | (kill-buffer "Gold-Keys") | 381 | (kill-buffer "Gold-Keys") |
diff --git a/lisp/emulation/vi.el b/lisp/emulation/vi.el index 70a52617431..cd0092e5e87 100644 --- a/lisp/emulation/vi.el +++ b/lisp/emulation/vi.el | |||
| @@ -403,7 +403,7 @@ form that is ready to be `apply'ed.") | |||
| 403 | (make-local-variable 'vi-mode-old-mode-name) | 403 | (make-local-variable 'vi-mode-old-mode-name) |
| 404 | (make-local-variable 'vi-mode-old-major-mode) | 404 | (make-local-variable 'vi-mode-old-major-mode) |
| 405 | (make-local-variable 'vi-mode-old-case-fold) | 405 | (make-local-variable 'vi-mode-old-case-fold) |
| 406 | (run-hooks 'vi-mode-hook)) | 406 | (run-mode-hooks 'vi-mode-hook)) |
| 407 | 407 | ||
| 408 | ;;;###autoload | 408 | ;;;###autoload |
| 409 | (defun vi-mode () | 409 | (defun vi-mode () |
diff --git a/lisp/emulation/viper-keym.el b/lisp/emulation/viper-keym.el index a74ca05b3df..f14f67d94c8 100644 --- a/lisp/emulation/viper-keym.el +++ b/lisp/emulation/viper-keym.el | |||
| @@ -50,16 +50,25 @@ | |||
| 50 | 50 | ||
| 51 | ;;; Variables | 51 | ;;; Variables |
| 52 | 52 | ||
| 53 | (defvar viper-toggle-key "\C-z" | 53 | (defcustom viper-toggle-key "\C-z" |
| 54 | "The key used to change states from emacs to Vi and back. | 54 | "The key used to change states from emacs to Vi and back. |
| 55 | In insert mode, this key also functions as Meta. | 55 | In insert mode, this key also functions as Meta. |
| 56 | Must be set in .viper file or prior to loading Viper. | 56 | Must be set in .viper file or prior to loading Viper. |
| 57 | This setting cannot be changed interactively.") | 57 | This setting cannot be changed interactively." |
| 58 | :type 'string | ||
| 59 | :group 'viper) | ||
| 60 | |||
| 61 | (defcustom viper-quoted-insert-key "\C-v" | ||
| 62 | "The key used to quote special characters when inserting them in Insert state." | ||
| 63 | :type 'string | ||
| 64 | :group 'viper) | ||
| 58 | 65 | ||
| 59 | (defvar viper-ESC-key "\e" | 66 | (defcustom viper-ESC-key "\e" |
| 60 | "Key used to ESC. | 67 | "Key used to ESC. |
| 61 | Must be set in .viper file or prior to loading Viper. | 68 | Must be set in .viper file or prior to loading Viper. |
| 62 | This setting cannot be changed interactively.") | 69 | This setting cannot be changed interactively." |
| 70 | :type 'string | ||
| 71 | :group 'viper) | ||
| 63 | 72 | ||
| 64 | ;;; Emacs keys in other states. | 73 | ;;; Emacs keys in other states. |
| 65 | 74 | ||
| @@ -242,7 +251,7 @@ viper-insert-basic-map. Not recommended, except for novice users.") | |||
| 242 | (define-key viper-insert-basic-map "\C-t" 'viper-forward-indent) | 251 | (define-key viper-insert-basic-map "\C-t" 'viper-forward-indent) |
| 243 | (define-key viper-insert-basic-map | 252 | (define-key viper-insert-basic-map |
| 244 | (if viper-xemacs-p [(shift tab)] [S-tab]) 'viper-insert-tab) | 253 | (if viper-xemacs-p [(shift tab)] [S-tab]) 'viper-insert-tab) |
| 245 | (define-key viper-insert-basic-map "\C-v" 'quoted-insert) | 254 | (define-key viper-insert-basic-map viper-quoted-insert-key 'quoted-insert) |
| 246 | (define-key viper-insert-basic-map "\C-?" 'viper-del-backward-char-in-insert) | 255 | (define-key viper-insert-basic-map "\C-?" 'viper-del-backward-char-in-insert) |
| 247 | (define-key viper-insert-basic-map [backspace] 'viper-del-backward-char-in-insert) | 256 | (define-key viper-insert-basic-map [backspace] 'viper-del-backward-char-in-insert) |
| 248 | (define-key viper-insert-basic-map "\C-\\" 'viper-alternate-Meta-key) | 257 | (define-key viper-insert-basic-map "\C-\\" 'viper-alternate-Meta-key) |
diff --git a/lisp/emulation/viper.el b/lisp/emulation/viper.el index e3582f2165a..3fdbccc2957 100644 --- a/lisp/emulation/viper.el +++ b/lisp/emulation/viper.el | |||
| @@ -990,12 +990,13 @@ remains buffer-local." | |||
| 990 | (setq global-mode-string | 990 | (setq global-mode-string |
| 991 | (append '("" viper-mode-string) (cdr global-mode-string)))) | 991 | (append '("" viper-mode-string) (cdr global-mode-string)))) |
| 992 | 992 | ||
| 993 | (defadvice describe-key (before viper-read-keyseq-ad protect activate) | 993 | (defadvice describe-key (before viper-describe-key-ad protect activate) |
| 994 | "Force to read key via `viper-read-key-sequence'." | 994 | "Force to read key via `viper-read-key-sequence'." |
| 995 | (interactive (list (viper-read-key-sequence "Describe key: ")))) | 995 | (interactive (list (viper-read-key-sequence "Describe key: ")) |
| 996 | )) | ||
| 996 | 997 | ||
| 997 | (defadvice describe-key-briefly | 998 | (defadvice describe-key-briefly |
| 998 | (before viper-read-keyseq-ad protect activate) | 999 | (before viper-describe-key-briefly-ad protect activate) |
| 999 | "Force to read key via `viper-read-key-sequence'." | 1000 | "Force to read key via `viper-read-key-sequence'." |
| 1000 | (interactive (list (viper-read-key-sequence "Describe key briefly: ")))) | 1001 | (interactive (list (viper-read-key-sequence "Describe key briefly: ")))) |
| 1001 | 1002 | ||
diff --git a/lisp/emulation/ws-mode.el b/lisp/emulation/ws-mode.el index 54be36299c5..482753f111e 100644 --- a/lisp/emulation/ws-mode.el +++ b/lisp/emulation/ws-mode.el | |||
| @@ -294,7 +294,7 @@ The key bindings are: | |||
| 294 | (use-local-map wordstar-mode-map) | 294 | (use-local-map wordstar-mode-map) |
| 295 | (setq mode-name "WordStar") | 295 | (setq mode-name "WordStar") |
| 296 | (setq major-mode 'wordstar-mode) | 296 | (setq major-mode 'wordstar-mode) |
| 297 | (run-hooks 'wordstar-mode-hook)) | 297 | (run-mode-hooks 'wordstar-mode-hook)) |
| 298 | 298 | ||
| 299 | 299 | ||
| 300 | (defun wordstar-center-paragraph () | 300 | (defun wordstar-center-paragraph () |
diff --git a/lisp/eshell/em-cmpl.el b/lisp/eshell/em-cmpl.el index 695a9fb4ed8..2b4dbc76ddc 100644 --- a/lisp/eshell/em-cmpl.el +++ b/lisp/eshell/em-cmpl.el | |||
| @@ -136,8 +136,7 @@ to writing a completion function." | |||
| 136 | :type (get 'pcomplete-file-ignore 'custom-type) | 136 | :type (get 'pcomplete-file-ignore 'custom-type) |
| 137 | :group 'eshell-cmpl) | 137 | :group 'eshell-cmpl) |
| 138 | 138 | ||
| 139 | (defcustom eshell-cmpl-dir-ignore | 139 | (defcustom eshell-cmpl-dir-ignore "\\`\\(\\.\\.?\\|CVS\\)/\\'" |
| 140 | (format "\\`\\(\\.\\.?\\|CVS\\)%c\\'" directory-sep-char) | ||
| 141 | (documentation-property 'pcomplete-dir-ignore | 140 | (documentation-property 'pcomplete-dir-ignore |
| 142 | 'variable-documentation) | 141 | 'variable-documentation) |
| 143 | :type (get 'pcomplete-dir-ignore 'custom-type) | 142 | :type (get 'pcomplete-dir-ignore 'custom-type) |
| @@ -155,7 +154,7 @@ to writing a completion function." | |||
| 155 | :type (get 'pcomplete-autolist 'custom-type) | 154 | :type (get 'pcomplete-autolist 'custom-type) |
| 156 | :group 'eshell-cmpl) | 155 | :group 'eshell-cmpl) |
| 157 | 156 | ||
| 158 | (defcustom eshell-cmpl-suffix-list (list directory-sep-char ?:) | 157 | (defcustom eshell-cmpl-suffix-list (list ?/ ?:) |
| 159 | (documentation-property 'pcomplete-suffix-list | 158 | (documentation-property 'pcomplete-suffix-list |
| 160 | 'variable-documentation) | 159 | 'variable-documentation) |
| 161 | :type (get 'pcomplete-suffix-list 'custom-type) | 160 | :type (get 'pcomplete-suffix-list 'custom-type) |
| @@ -370,7 +369,8 @@ to writing a completion function." | |||
| 370 | (setq args (nthcdr (1+ l) args) | 369 | (setq args (nthcdr (1+ l) args) |
| 371 | posns (nthcdr (1+ l) posns)))) | 370 | posns (nthcdr (1+ l) posns)))) |
| 372 | (assert (= (length args) (length posns))) | 371 | (assert (= (length args) (length posns))) |
| 373 | (when (and args (eq (char-syntax (char-before end)) ? )) | 372 | (when (and args (eq (char-syntax (char-before end)) ? ) |
| 373 | (not (eq (char-before (1- end)) ?\\))) | ||
| 374 | (nconc args (list "")) | 374 | (nconc args (list "")) |
| 375 | (nconc posns (list (point)))) | 375 | (nconc posns (list (point)))) |
| 376 | (cons (mapcar | 376 | (cons (mapcar |
diff --git a/lisp/eshell/em-dirs.el b/lisp/eshell/em-dirs.el index 7b74069454b..6477a546eb8 100644 --- a/lisp/eshell/em-dirs.el +++ b/lisp/eshell/em-dirs.el | |||
| @@ -276,8 +276,7 @@ Thus, this does not include the current directory.") | |||
| 276 | (let* ((letter (match-string 1)) | 276 | (let* ((letter (match-string 1)) |
| 277 | (regexp (concat "\\`" letter)) | 277 | (regexp (concat "\\`" letter)) |
| 278 | (path (eshell-find-previous-directory regexp))) | 278 | (path (eshell-find-previous-directory regexp))) |
| 279 | (concat (or path letter) | 279 | (concat (or path letter) "/")))) |
| 280 | (char-to-string directory-sep-char))))) | ||
| 281 | 280 | ||
| 282 | (defun eshell-complete-user-reference () | 281 | (defun eshell-complete-user-reference () |
| 283 | "If there is a user reference, complete it." | 282 | "If there is a user reference, complete it." |
| @@ -300,7 +299,7 @@ Thus, this does not include the current directory.") | |||
| 300 | (let* ((path default-directory) | 299 | (let* ((path default-directory) |
| 301 | (len (length path))) | 300 | (len (length path))) |
| 302 | (if (and (> len 1) | 301 | (if (and (> len 1) |
| 303 | (eq (aref path (1- len)) directory-sep-char) | 302 | (eq (aref path (1- len)) ?/) |
| 304 | (not (and (eshell-under-windows-p) | 303 | (not (and (eshell-under-windows-p) |
| 305 | (string-match "\\`[A-Za-z]:[\\\\/]\\'" path)))) | 304 | (string-match "\\`[A-Za-z]:[\\\\/]\\'" path)))) |
| 306 | (setq path (substring path 0 (1- (length path))))) | 305 | (setq path (substring path 0 (1- (length path))))) |
| @@ -324,9 +323,7 @@ in the minibuffer: | |||
| 324 | (len (length extra-dots)) | 323 | (len (length extra-dots)) |
| 325 | replace-text) | 324 | replace-text) |
| 326 | (while (> len 0) | 325 | (while (> len 0) |
| 327 | (setq replace-text | 326 | (setq replace-text (concat replace-text "/..") |
| 328 | (concat replace-text | ||
| 329 | (char-to-string directory-sep-char) "..") | ||
| 330 | len (1- len))) | 327 | len (1- len))) |
| 331 | (setq path | 328 | (setq path |
| 332 | (replace-match replace-text t t path 1)))) | 329 | (replace-match replace-text t t path 1)))) |
| @@ -371,7 +368,7 @@ in the minibuffer: | |||
| 371 | (setq path | 368 | (setq path |
| 372 | (ring-remove eshell-last-dir-ring | 369 | (ring-remove eshell-last-dir-ring |
| 373 | (if index | 370 | (if index |
| 374 | (string-to-int index) | 371 | (string-to-number index) |
| 375 | 0))))) | 372 | 0))))) |
| 376 | ((and path (string-match "^=\\(.*\\)$" path)) | 373 | ((and path (string-match "^=\\(.*\\)$" path)) |
| 377 | (let ((oldpath (eshell-find-previous-directory | 374 | (let ((oldpath (eshell-find-previous-directory |
diff --git a/lisp/eshell/em-glob.el b/lisp/eshell/em-glob.el index c84962e66b0..74614d78d9c 100644 --- a/lisp/eshell/em-glob.el +++ b/lisp/eshell/em-glob.el | |||
| @@ -265,9 +265,6 @@ the form: | |||
| 265 | (defvar matches) | 265 | (defvar matches) |
| 266 | (defvar message-shown)) | 266 | (defvar message-shown)) |
| 267 | 267 | ||
| 268 | ;; jww (1999-11-18): this function assumes that directory-sep-char is | ||
| 269 | ;; a forward slash (/) | ||
| 270 | |||
| 271 | (defun eshell-glob-entries (path globs &optional recurse-p) | 268 | (defun eshell-glob-entries (path globs &optional recurse-p) |
| 272 | "Glob the entries in PATHS, possibly recursing if RECURSE-P is non-nil." | 269 | "Glob the entries in PATHS, possibly recursing if RECURSE-P is non-nil." |
| 273 | (let* ((entries (ignore-errors | 270 | (let* ((entries (ignore-errors |
| @@ -303,11 +300,11 @@ the form: | |||
| 303 | ;; can't use `directory-file-name' because it strips away text | 300 | ;; can't use `directory-file-name' because it strips away text |
| 304 | ;; properties in the string | 301 | ;; properties in the string |
| 305 | (let ((len (1- (length incl)))) | 302 | (let ((len (1- (length incl)))) |
| 306 | (if (eq (aref incl len) directory-sep-char) | 303 | (if (eq (aref incl len) ?/) |
| 307 | (setq incl (substring incl 0 len))) | 304 | (setq incl (substring incl 0 len))) |
| 308 | (when excl | 305 | (when excl |
| 309 | (setq len (1- (length excl))) | 306 | (setq len (1- (length excl))) |
| 310 | (if (eq (aref excl len) directory-sep-char) | 307 | (if (eq (aref excl len) ?/) |
| 311 | (setq excl (substring excl 0 len))))) | 308 | (setq excl (substring excl 0 len))))) |
| 312 | (setq incl (eshell-glob-regexp incl) | 309 | (setq incl (eshell-glob-regexp incl) |
| 313 | excl (and excl (eshell-glob-regexp excl))) | 310 | excl (and excl (eshell-glob-regexp excl))) |
| @@ -329,7 +326,7 @@ the form: | |||
| 329 | (while entries | 326 | (while entries |
| 330 | (setq name (car entries) | 327 | (setq name (car entries) |
| 331 | len (length name) | 328 | len (length name) |
| 332 | isdir (eq (aref name (1- len)) directory-sep-char)) | 329 | isdir (eq (aref name (1- len)) ?/)) |
| 333 | (if (let ((fname (directory-file-name name))) | 330 | (if (let ((fname (directory-file-name name))) |
| 334 | (and (not (and excl (string-match excl fname))) | 331 | (and (not (and excl (string-match excl fname))) |
| 335 | (string-match incl fname))) | 332 | (string-match incl fname))) |
diff --git a/lisp/eshell/em-unix.el b/lisp/eshell/em-unix.el index d932916d8c9..62296dde73c 100644 --- a/lisp/eshell/em-unix.el +++ b/lisp/eshell/em-unix.el | |||
| @@ -877,7 +877,7 @@ Summarize disk usage of each FILE, recursively for directories.") | |||
| 877 | (unless by-bytes | 877 | (unless by-bytes |
| 878 | (setq block-size (or block-size 1024))) | 878 | (setq block-size (or block-size 1024))) |
| 879 | (if (and max-depth (stringp max-depth)) | 879 | (if (and max-depth (stringp max-depth)) |
| 880 | (setq max-depth (string-to-int max-depth))) | 880 | (setq max-depth (string-to-number max-depth))) |
| 881 | ;; filesystem support means nothing under Windows | 881 | ;; filesystem support means nothing under Windows |
| 882 | (if (eshell-under-windows-p) | 882 | (if (eshell-under-windows-p) |
| 883 | (setq only-one-filesystem nil)) | 883 | (setq only-one-filesystem nil)) |
diff --git a/lisp/eshell/esh-cmd.el b/lisp/eshell/esh-cmd.el index d7c65066ac6..355369d35ae 100644 --- a/lisp/eshell/esh-cmd.el +++ b/lisp/eshell/esh-cmd.el | |||
| @@ -757,7 +757,7 @@ nil)' if none)." | |||
| 757 | 757 | ||
| 758 | (defmacro eshell-do-subjob (object) | 758 | (defmacro eshell-do-subjob (object) |
| 759 | "Evaluate a command OBJECT as a subjob. | 759 | "Evaluate a command OBJECT as a subjob. |
| 760 | We indicate thet the process was run in the background by returned it | 760 | We indicate that the process was run in the background by returning it |
| 761 | ensconced in a list." | 761 | ensconced in a list." |
| 762 | `(let ((eshell-current-subjob-p t)) | 762 | `(let ((eshell-current-subjob-p t)) |
| 763 | ,object)) | 763 | ,object)) |
| @@ -1006,11 +1006,10 @@ at the moment are: | |||
| 1006 | (eshell-resume-eval)))) | 1006 | (eshell-resume-eval)))) |
| 1007 | ;; On systems that don't support async subprocesses, eshell-resume | 1007 | ;; On systems that don't support async subprocesses, eshell-resume |
| 1008 | ;; can return t. Don't treat that as an error. | 1008 | ;; can return t. Don't treat that as an error. |
| 1009 | (if (listp delim) | ||
| 1010 | (setq delim (car delim))) | ||
| 1009 | (if (and delim (not (eq delim t))) | 1011 | (if (and delim (not (eq delim t))) |
| 1010 | (error "Unmatched delimiter: %c" | 1012 | (error "Unmatched delimiter: %c" delim))))) |
| 1011 | (if (listp delim) | ||
| 1012 | (car delim) | ||
| 1013 | delim)))))) | ||
| 1014 | 1013 | ||
| 1015 | (defun eshell-resume-command (proc status) | 1014 | (defun eshell-resume-command (proc status) |
| 1016 | "Resume the current command when a process ends." | 1015 | "Resume the current command when a process ends." |
diff --git a/lisp/eshell/esh-ext.el b/lisp/eshell/esh-ext.el index c16b6113516..11fecee4de0 100644 --- a/lisp/eshell/esh-ext.el +++ b/lisp/eshell/esh-ext.el | |||
| @@ -103,7 +103,7 @@ wholly ignored." | |||
| 103 | "Invoke a .BAT or .CMD file on DOS/Windows systems." | 103 | "Invoke a .BAT or .CMD file on DOS/Windows systems." |
| 104 | ;; since CMD.EXE can't handle forward slashes in the initial | 104 | ;; since CMD.EXE can't handle forward slashes in the initial |
| 105 | ;; argument... | 105 | ;; argument... |
| 106 | (setcar args (subst-char-in-string directory-sep-char ?\\ (car args))) | 106 | (setcar args (subst-char-in-string ?/ ?\\ (car args))) |
| 107 | (throw 'eshell-replace-command | 107 | (throw 'eshell-replace-command |
| 108 | (eshell-parse-command eshell-windows-shell-file (cons "/c" args)))) | 108 | (eshell-parse-command eshell-windows-shell-file (cons "/c" args)))) |
| 109 | 109 | ||
diff --git a/lisp/eshell/esh-io.el b/lisp/eshell/esh-io.el index 6944770dbc9..8f171760ea0 100644 --- a/lisp/eshell/esh-io.el +++ b/lisp/eshell/esh-io.el | |||
| @@ -192,7 +192,7 @@ not be added to this variable." | |||
| 192 | (eshell-finish-arg | 192 | (eshell-finish-arg |
| 193 | (prog1 | 193 | (prog1 |
| 194 | (list 'eshell-set-output-handle | 194 | (list 'eshell-set-output-handle |
| 195 | (or (and sh (string-to-int sh)) 1) | 195 | (or (and sh (string-to-number sh)) 1) |
| 196 | (list 'quote | 196 | (list 'quote |
| 197 | (aref [overwrite append insert] | 197 | (aref [overwrite append insert] |
| 198 | (1- (length oper))))) | 198 | (1- (length oper))))) |
| @@ -353,7 +353,8 @@ it defaults to `insert'." | |||
| 353 | ((or (bufferp target) | 353 | ((or (bufferp target) |
| 354 | (and (boundp 'eshell-buffer-shorthand) | 354 | (and (boundp 'eshell-buffer-shorthand) |
| 355 | (symbol-value 'eshell-buffer-shorthand) | 355 | (symbol-value 'eshell-buffer-shorthand) |
| 356 | (symbolp target))) | 356 | (symbolp target) |
| 357 | (not (memq target '(t nil))))) | ||
| 357 | (let ((buf (if (bufferp target) | 358 | (let ((buf (if (bufferp target) |
| 358 | target | 359 | target |
| 359 | (get-buffer-create | 360 | (get-buffer-create |
diff --git a/lisp/eshell/esh-mode.el b/lisp/eshell/esh-mode.el index 050c82cc310..9cb05116b79 100644 --- a/lisp/eshell/esh-mode.el +++ b/lisp/eshell/esh-mode.el | |||
| @@ -438,7 +438,7 @@ This is used by `eshell-watch-for-password-prompt'." | |||
| 438 | 438 | ||
| 439 | (if eshell-first-time-p | 439 | (if eshell-first-time-p |
| 440 | (run-hooks 'eshell-first-time-mode-hook)) | 440 | (run-hooks 'eshell-first-time-mode-hook)) |
| 441 | (run-hooks 'eshell-mode-hook) | 441 | (run-mode-hooks 'eshell-mode-hook) |
| 442 | (run-hooks 'eshell-post-command-hook)) | 442 | (run-hooks 'eshell-post-command-hook)) |
| 443 | 443 | ||
| 444 | (put 'eshell-mode 'mode-class 'special) | 444 | (put 'eshell-mode 'mode-class 'special) |
diff --git a/lisp/eshell/esh-util.el b/lisp/eshell/esh-util.el index a2fd0915cf4..91317300ca5 100644 --- a/lisp/eshell/esh-util.el +++ b/lisp/eshell/esh-util.el | |||
| @@ -253,14 +253,13 @@ If N or M is nil, it means the end of the list." | |||
| 253 | parts) | 253 | parts) |
| 254 | (if (and (eshell-under-windows-p) | 254 | (if (and (eshell-under-windows-p) |
| 255 | (> len 2) | 255 | (> len 2) |
| 256 | (eq (aref path 0) directory-sep-char) | 256 | (eq (aref path 0) ?/) |
| 257 | (eq (aref path 1) directory-sep-char)) | 257 | (eq (aref path 1) ?/)) |
| 258 | (setq i 2)) | 258 | (setq i 2)) |
| 259 | (while (< i len) | 259 | (while (< i len) |
| 260 | (if (and (eq (aref path i) directory-sep-char) | 260 | (if (and (eq (aref path i) ?/) |
| 261 | (not (get-text-property i 'escaped path))) | 261 | (not (get-text-property i 'escaped path))) |
| 262 | (setq parts (cons (if (= li i) | 262 | (setq parts (cons (if (= li i) "/" |
| 263 | (char-to-string directory-sep-char) | ||
| 264 | (substring path li (1+ i))) parts) | 263 | (substring path li (1+ i))) parts) |
| 265 | li (1+ i))) | 264 | li (1+ i))) |
| 266 | (setq i (1+ i))) | 265 | (setq i (1+ i))) |
| @@ -268,9 +267,7 @@ If N or M is nil, it means the end of the list." | |||
| 268 | (setq parts (cons (substring path li i) parts))) | 267 | (setq parts (cons (substring path li i) parts))) |
| 269 | (if (and (eshell-under-windows-p) | 268 | (if (and (eshell-under-windows-p) |
| 270 | (string-match "\\`[A-Za-z]:\\'" (car (last parts)))) | 269 | (string-match "\\`[A-Za-z]:\\'" (car (last parts)))) |
| 271 | (setcar (last parts) | 270 | (setcar (last parts) (concat (car (last parts)) "/"))) |
| 272 | (concat (car (last parts)) | ||
| 273 | (char-to-string directory-sep-char)))) | ||
| 274 | (nreverse parts))) | 271 | (nreverse parts))) |
| 275 | 272 | ||
| 276 | (defun eshell-to-flat-string (value) | 273 | (defun eshell-to-flat-string (value) |
| @@ -450,8 +447,8 @@ list." | |||
| 450 | (point) (progn (end-of-line) | 447 | (point) (progn (end-of-line) |
| 451 | (point))) ":"))) | 448 | (point))) ":"))) |
| 452 | (if (and (and fields (nth 0 fields) (nth 2 fields)) | 449 | (if (and (and fields (nth 0 fields) (nth 2 fields)) |
| 453 | (not (assq (string-to-int (nth 2 fields)) names))) | 450 | (not (assq (string-to-number (nth 2 fields)) names))) |
| 454 | (setq names (cons (cons (string-to-int (nth 2 fields)) | 451 | (setq names (cons (cons (string-to-number (nth 2 fields)) |
| 455 | (nth 0 fields)) | 452 | (nth 0 fields)) |
| 456 | names)))) | 453 | names)))) |
| 457 | (forward-line)))) | 454 | (forward-line)))) |
diff --git a/lisp/eshell/esh-var.el b/lisp/eshell/esh-var.el index 9ff9c1898a2..a0294273985 100644 --- a/lisp/eshell/esh-var.el +++ b/lisp/eshell/esh-var.el | |||
| @@ -631,7 +631,7 @@ For example, to retrieve the second element of a user's record in | |||
| 631 | (if (and value | 631 | (if (and value |
| 632 | (stringp value) | 632 | (stringp value) |
| 633 | (file-directory-p value)) | 633 | (file-directory-p value)) |
| 634 | (concat varname (char-to-string directory-sep-char)) | 634 | (concat varname "/") |
| 635 | varname)))) | 635 | varname)))) |
| 636 | (eshell-envvar-names (eshell-environment-variables))) | 636 | (eshell-envvar-names (eshell-environment-variables))) |
| 637 | (all-completions argname obarray 'boundp) | 637 | (all-completions argname obarray 'boundp) |
diff --git a/lisp/faces.el b/lisp/faces.el index 5f19ba7a880..6bbf7da3761 100644 --- a/lisp/faces.el +++ b/lisp/faces.el | |||
| @@ -183,10 +183,7 @@ Return nil if there is no such face. | |||
| 183 | If the optional argument FRAME is given, this gets the face NAME for | 183 | If the optional argument FRAME is given, this gets the face NAME for |
| 184 | that frame; otherwise, it uses the selected frame. | 184 | that frame; otherwise, it uses the selected frame. |
| 185 | If FRAME is the symbol t, then the global, non-frame face is returned. | 185 | If FRAME is the symbol t, then the global, non-frame face is returned. |
| 186 | If NAME is already a face, it is simply returned. | 186 | If NAME is already a face, it is simply returned." |
| 187 | |||
| 188 | This function is defined for compatibility with Emacs 20.2. It | ||
| 189 | should not be used anymore." | ||
| 190 | (facep name)) | 187 | (facep name)) |
| 191 | (make-obsolete 'internal-find-face 'facep "21.1") | 188 | (make-obsolete 'internal-find-face 'facep "21.1") |
| 192 | 189 | ||
| @@ -234,8 +231,8 @@ of a face name is the same for all frames." | |||
| 234 | (defun face-equal (face1 face2 &optional frame) | 231 | (defun face-equal (face1 face2 &optional frame) |
| 235 | "Non-nil if faces FACE1 and FACE2 are equal. | 232 | "Non-nil if faces FACE1 and FACE2 are equal. |
| 236 | Faces are considered equal if all their attributes are equal. | 233 | Faces are considered equal if all their attributes are equal. |
| 237 | If the optional argument FRAME is given, report on face FACE in that frame. | 234 | If the optional argument FRAME is given, report on FACE1 and FACE2 in that frame. |
| 238 | If FRAME is t, report on the defaults for face FACE (for new frames). | 235 | If FRAME is t, report on the defaults for FACE1 and FACE2 (for new frames). |
| 239 | If FRAME is omitted or nil, use the selected frame." | 236 | If FRAME is omitted or nil, use the selected frame." |
| 240 | (internal-lisp-face-equal-p face1 face2 frame)) | 237 | (internal-lisp-face-equal-p face1 face2 frame)) |
| 241 | 238 | ||
| @@ -1154,16 +1151,24 @@ this regular expression. When called interactively with a prefix | |||
| 1154 | arg, prompt for a regular expression." | 1151 | arg, prompt for a regular expression." |
| 1155 | (interactive (list (and current-prefix-arg | 1152 | (interactive (list (and current-prefix-arg |
| 1156 | (read-string "List faces matching regexp: ")))) | 1153 | (read-string "List faces matching regexp: ")))) |
| 1157 | (let ((faces (sort (face-list) #'string-lessp)) | 1154 | (let ((all-faces (zerop (length regexp))) |
| 1158 | (frame (selected-frame)) | 1155 | (frame (selected-frame)) |
| 1156 | (max-length 0) | ||
| 1157 | faces line-format | ||
| 1159 | disp-frame window face-name) | 1158 | disp-frame window face-name) |
| 1160 | (when (> (length regexp) 0) | 1159 | ;; We filter and take the max length in one pass |
| 1161 | (setq faces | 1160 | (setq faces |
| 1162 | (delq nil | 1161 | (delq nil |
| 1163 | (mapcar (lambda (f) | 1162 | (mapcar (lambda (f) |
| 1164 | (when (string-match regexp (symbol-name f)) | 1163 | (let ((s (symbol-name f))) |
| 1165 | f)) | 1164 | (when (or all-faces (string-match regexp s)) |
| 1166 | faces)))) | 1165 | (setq max-length (max (length s) max-length)) |
| 1166 | f))) | ||
| 1167 | (sort (face-list) #'string-lessp)))) | ||
| 1168 | (unless faces | ||
| 1169 | (error "No faces matching \"%s\"" regexp)) | ||
| 1170 | (setq max-length (1+ max-length) | ||
| 1171 | line-format (format "%%-%ds" max-length)) | ||
| 1167 | (with-output-to-temp-buffer "*Faces*" | 1172 | (with-output-to-temp-buffer "*Faces*" |
| 1168 | (save-excursion | 1173 | (save-excursion |
| 1169 | (set-buffer standard-output) | 1174 | (set-buffer standard-output) |
| @@ -1178,7 +1183,7 @@ arg, prompt for a regular expression." | |||
| 1178 | (setq help-xref-stack nil) | 1183 | (setq help-xref-stack nil) |
| 1179 | (dolist (face faces) | 1184 | (dolist (face faces) |
| 1180 | (setq face-name (symbol-name face)) | 1185 | (setq face-name (symbol-name face)) |
| 1181 | (insert (format "%25s " face-name)) | 1186 | (insert (format line-format face-name)) |
| 1182 | ;; Hyperlink to a customization buffer for the face. Using | 1187 | ;; Hyperlink to a customization buffer for the face. Using |
| 1183 | ;; the help xref mechanism may not be the best way. | 1188 | ;; the help xref mechanism may not be the best way. |
| 1184 | (save-excursion | 1189 | (save-excursion |
| @@ -1203,7 +1208,7 @@ arg, prompt for a regular expression." | |||
| 1203 | (goto-char beg) | 1208 | (goto-char beg) |
| 1204 | (forward-line 1) | 1209 | (forward-line 1) |
| 1205 | (while (not (eobp)) | 1210 | (while (not (eobp)) |
| 1206 | (insert " ") | 1211 | (insert-char ?\s max-length) |
| 1207 | (forward-line 1)))) | 1212 | (forward-line 1)))) |
| 1208 | (goto-char (point-min))) | 1213 | (goto-char (point-min))) |
| 1209 | (print-help-return-message)) | 1214 | (print-help-return-message)) |
diff --git a/lisp/files.el b/lisp/files.el index 4602b4e1efa..a75b6b2fc89 100644 --- a/lisp/files.el +++ b/lisp/files.el | |||
| @@ -514,6 +514,10 @@ Runs the usual ange-ftp hook, but only for completion operations." | |||
| 514 | This means to guarantee valid names and perhaps to canonicalize | 514 | This means to guarantee valid names and perhaps to canonicalize |
| 515 | certain patterns. | 515 | certain patterns. |
| 516 | 516 | ||
| 517 | FILENAME should be an absolute file name since the conversion rules | ||
| 518 | sometimes vary depending on the position in the file name. E.g. c:/foo | ||
| 519 | is a valid DOS file name, but c:/bar/c:/foo is not. | ||
| 520 | |||
| 517 | This function's standard definition is trivial; it just returns | 521 | This function's standard definition is trivial; it just returns |
| 518 | the argument. However, on Windows and DOS, replace invalid | 522 | the argument. However, on Windows and DOS, replace invalid |
| 519 | characters. On DOS, make sure to obey the 8.3 limitations. On | 523 | characters. On DOS, make sure to obey the 8.3 limitations. On |
diff --git a/lisp/filesets.el b/lisp/filesets.el index 9d60f20316f..7bbf55d9823 100644 --- a/lisp/filesets.el +++ b/lisp/filesets.el | |||
| @@ -132,7 +132,8 @@ Is buffer local variable.") | |||
| 132 | 132 | ||
| 133 | (defvar filesets-menu-ensure-use-cached | 133 | (defvar filesets-menu-ensure-use-cached |
| 134 | (and filesets-running-xemacs | 134 | (and filesets-running-xemacs |
| 135 | (not (emacs-version>= 21 5))) | 135 | (if (fboundp 'emacs-version>=) |
| 136 | (not (emacs-version>= 21 5)))) | ||
| 136 | "Make sure (X)Emacs uses filesets' cache. | 137 | "Make sure (X)Emacs uses filesets' cache. |
| 137 | 138 | ||
| 138 | Well, if you use XEmacs (prior to 21.5?) custom.el is loaded after | 139 | Well, if you use XEmacs (prior to 21.5?) custom.el is loaded after |
diff --git a/lisp/font-core.el b/lisp/font-core.el index 056c1b3515b..a78e21a762f 100644 --- a/lisp/font-core.el +++ b/lisp/font-core.el | |||
| @@ -88,6 +88,8 @@ settings. See the variable `font-lock-defaults', which takes precedence.") | |||
| 88 | It will be passed one argument, which is the current value of | 88 | It will be passed one argument, which is the current value of |
| 89 | `font-lock-mode'.") | 89 | `font-lock-mode'.") |
| 90 | 90 | ||
| 91 | ;; The mode for which font-lock was initialized, or nil if none. | ||
| 92 | (defvar font-lock-mode-major-mode) | ||
| 91 | (define-minor-mode font-lock-mode | 93 | (define-minor-mode font-lock-mode |
| 92 | "Toggle Font Lock mode. | 94 | "Toggle Font Lock mode. |
| 93 | With arg, turn Font Lock mode off if and only if arg is a non-positive | 95 | With arg, turn Font Lock mode off if and only if arg is a non-positive |
| @@ -156,7 +158,9 @@ your own function which is called when `font-lock-mode' is toggled via | |||
| 156 | ;; Arrange to unfontify this buffer if we change major mode later. | 158 | ;; Arrange to unfontify this buffer if we change major mode later. |
| 157 | (if font-lock-mode | 159 | (if font-lock-mode |
| 158 | (add-hook 'change-major-mode-hook 'font-lock-change-mode nil t) | 160 | (add-hook 'change-major-mode-hook 'font-lock-change-mode nil t) |
| 159 | (remove-hook 'change-major-mode-hook 'font-lock-change-mode t))) | 161 | (remove-hook 'change-major-mode-hook 'font-lock-change-mode t)) |
| 162 | (when font-lock-mode | ||
| 163 | (setq font-lock-mode-major-mode major-mode))) | ||
| 160 | 164 | ||
| 161 | ;; Get rid of fontification for the old major mode. | 165 | ;; Get rid of fontification for the old major mode. |
| 162 | ;; We do this when changing major modes. | 166 | ;; We do this when changing major modes. |
| @@ -175,6 +179,7 @@ this function onto `change-major-mode-hook'." | |||
| 175 | '(font-lock-face))) | 179 | '(font-lock-face))) |
| 176 | (restore-buffer-modified-p modp))) | 180 | (restore-buffer-modified-p modp))) |
| 177 | 181 | ||
| 182 | (defvar font-lock-set-defaults) | ||
| 178 | (defun font-lock-default-function (mode) | 183 | (defun font-lock-default-function (mode) |
| 179 | ;; Turn on Font Lock mode. | 184 | ;; Turn on Font Lock mode. |
| 180 | (when mode | 185 | (when mode |
| @@ -201,9 +206,14 @@ this function onto `change-major-mode-hook'." | |||
| 201 | ;; Only do hard work if the mode has specified stuff in | 206 | ;; Only do hard work if the mode has specified stuff in |
| 202 | ;; `font-lock-defaults'. | 207 | ;; `font-lock-defaults'. |
| 203 | (when (or font-lock-defaults | 208 | (when (or font-lock-defaults |
| 204 | (and (boundp 'font-lock-keywords) font-lock-keywords) | 209 | (if (boundp 'font-lock-keywords) font-lock-keywords) |
| 205 | (with-no-warnings | 210 | (with-no-warnings |
| 206 | (cdr (assq major-mode font-lock-defaults-alist)))) | 211 | (cdr (assq major-mode font-lock-defaults-alist))) |
| 212 | (and mode | ||
| 213 | (boundp 'font-lock-set-defaults) | ||
| 214 | font-lock-set-defaults | ||
| 215 | font-lock-mode-major-mode | ||
| 216 | (not (eq font-lock-mode-major-mode major-mode)))) | ||
| 207 | (font-lock-mode-internal mode))) | 217 | (font-lock-mode-internal mode))) |
| 208 | 218 | ||
| 209 | (defun turn-on-font-lock () | 219 | (defun turn-on-font-lock () |
diff --git a/lisp/font-lock.el b/lisp/font-lock.el index 8ef14191a0a..1d07e5a9283 100644 --- a/lisp/font-lock.el +++ b/lisp/font-lock.el | |||
| @@ -683,9 +683,22 @@ For example: | |||
| 683 | adds two fontification patterns for C mode, to fontify `FIXME:' words, even in | 683 | adds two fontification patterns for C mode, to fontify `FIXME:' words, even in |
| 684 | comments, and to fontify `and', `or' and `not' words as keywords. | 684 | comments, and to fontify `and', `or' and `not' words as keywords. |
| 685 | 685 | ||
| 686 | When used from a Lisp program (such as a minor mode), it is recommended to | 686 | The above procedure will only add the keywords for C mode, not |
| 687 | use nil for MODE (and place the call on a hook) to avoid subtle problems | 687 | for modes derived from C mode. To add them for derived modes too, |
| 688 | due to details of the implementation. | 688 | pass nil for MODE and add the call to c-mode-hook. |
| 689 | |||
| 690 | For example: | ||
| 691 | |||
| 692 | (add-hook 'c-mode-hook | ||
| 693 | (lambda () | ||
| 694 | (font-lock-add-keywords 'c-mode | ||
| 695 | '((\"\\\\\\=<\\\\(FIXME\\\\):\" 1 font-lock-warning-face prepend) | ||
| 696 | (\"\\\\\\=<\\\\(and\\\\|or\\\\|not\\\\)\\\\\\=>\" . | ||
| 697 | font-lock-keyword-face))))) | ||
| 698 | |||
| 699 | The above procedure may fail to add keywords to derived modes if | ||
| 700 | some involved major mode does not follow the standard conventions. | ||
| 701 | File a bug report if this happens, so the major mode can be corrected. | ||
| 689 | 702 | ||
| 690 | Note that some modes have specialized support for additional patterns, e.g., | 703 | Note that some modes have specialized support for additional patterns, e.g., |
| 691 | see the variables `c-font-lock-extra-types', `c++-font-lock-extra-types', | 704 | see the variables `c-font-lock-extra-types', `c++-font-lock-extra-types', |
| @@ -704,7 +717,8 @@ see the variables `c-font-lock-extra-types', `c++-font-lock-extra-types', | |||
| 704 | (font-lock-update-removed-keyword-alist mode keywords append)) | 717 | (font-lock-update-removed-keyword-alist mode keywords append)) |
| 705 | (t | 718 | (t |
| 706 | ;; Otherwise set or add the keywords now. | 719 | ;; Otherwise set or add the keywords now. |
| 707 | ;; This is a no-op if it has been done already in this buffer. | 720 | ;; This is a no-op if it has been done already in this buffer |
| 721 | ;; for the correct major mode. | ||
| 708 | (font-lock-set-defaults) | 722 | (font-lock-set-defaults) |
| 709 | (let ((was-compiled (eq (car font-lock-keywords) t))) | 723 | (let ((was-compiled (eq (car font-lock-keywords) t))) |
| 710 | ;; Bring back the user-level (uncompiled) keywords. | 724 | ;; Bring back the user-level (uncompiled) keywords. |
| @@ -774,9 +788,11 @@ see the variables `c-font-lock-extra-types', `c++-font-lock-extra-types', | |||
| 774 | MODE should be a symbol, the major mode command name, such as `c-mode' | 788 | MODE should be a symbol, the major mode command name, such as `c-mode' |
| 775 | or nil. If nil, highlighting keywords are removed for the current buffer. | 789 | or nil. If nil, highlighting keywords are removed for the current buffer. |
| 776 | 790 | ||
| 777 | When used from a Lisp program (such as a minor mode), it is recommended to | 791 | To make the removal apply to modes derived from MODE as well, |
| 778 | use nil for MODE (and place the call on a hook) to avoid subtle problems | 792 | pass nil for MODE and add the call to MODE-hook. This may fail |
| 779 | due to details of the implementation." | 793 | for some derived modes if some involved major mode does not |
| 794 | follow the standard conventions. File a bug report if this | ||
| 795 | happens, so the major mode can be corrected." | ||
| 780 | (cond (mode | 796 | (cond (mode |
| 781 | ;; Remove one keyword at the time. | 797 | ;; Remove one keyword at the time. |
| 782 | (dolist (keyword keywords) | 798 | (dolist (keyword keywords) |
| @@ -1351,7 +1367,7 @@ START should be at the beginning of a line." | |||
| 1351 | comment-start-skip)) | 1367 | comment-start-skip)) |
| 1352 | (put-text-property beg (match-end 0) 'face | 1368 | (put-text-property beg (match-end 0) 'face |
| 1353 | font-lock-comment-delimiter-face))) | 1369 | font-lock-comment-delimiter-face))) |
| 1354 | (if (looking-back comment-end-regexp (point-at-bol)) | 1370 | (if (looking-back comment-end-regexp (point-at-bol) t) |
| 1355 | (put-text-property (match-beginning 0) (point) 'face | 1371 | (put-text-property (match-beginning 0) (point) 'face |
| 1356 | font-lock-comment-delimiter-face)))) | 1372 | font-lock-comment-delimiter-face)))) |
| 1357 | (< (point) end)) | 1373 | (< (point) end)) |
| @@ -1571,12 +1587,15 @@ A LEVEL of nil is equal to a LEVEL of 0, a LEVEL of t is equal to | |||
| 1571 | 1587 | ||
| 1572 | (defvar font-lock-set-defaults nil) ; Whether we have set up defaults. | 1588 | (defvar font-lock-set-defaults nil) ; Whether we have set up defaults. |
| 1573 | 1589 | ||
| 1590 | (defvar font-lock-mode-major-mode) | ||
| 1574 | (defun font-lock-set-defaults () | 1591 | (defun font-lock-set-defaults () |
| 1575 | "Set fontification defaults appropriately for this mode. | 1592 | "Set fontification defaults appropriately for this mode. |
| 1576 | Sets various variables using `font-lock-defaults' (or, if nil, using | 1593 | Sets various variables using `font-lock-defaults' (or, if nil, using |
| 1577 | `font-lock-defaults-alist') and `font-lock-maximum-decoration'." | 1594 | `font-lock-defaults-alist') and `font-lock-maximum-decoration'." |
| 1578 | ;; Set fontification defaults iff not previously set. | 1595 | ;; Set fontification defaults iff not previously set for correct major mode. |
| 1579 | (unless font-lock-set-defaults | 1596 | (unless (and font-lock-set-defaults |
| 1597 | (eq font-lock-mode-major-mode major-mode)) | ||
| 1598 | (setq font-lock-mode-major-mode major-mode) | ||
| 1580 | (set (make-local-variable 'font-lock-set-defaults) t) | 1599 | (set (make-local-variable 'font-lock-set-defaults) t) |
| 1581 | (make-local-variable 'font-lock-fontified) | 1600 | (make-local-variable 'font-lock-fontified) |
| 1582 | (make-local-variable 'font-lock-multiline) | 1601 | (make-local-variable 'font-lock-multiline) |
diff --git a/lisp/forms.el b/lisp/forms.el index 61d2441a9ea..57985a7297f 100644 --- a/lisp/forms.el +++ b/lisp/forms.el | |||
| @@ -713,7 +713,7 @@ Commands: Equivalent keys in read-only mode: | |||
| 713 | 713 | ||
| 714 | ;; user customising | 714 | ;; user customising |
| 715 | ;;(message "forms: proceeding setup (user hooks)...") | 715 | ;;(message "forms: proceeding setup (user hooks)...") |
| 716 | (run-hooks 'forms-mode-hook 'forms-mode-hooks) | 716 | (run-mode-hooks 'forms-mode-hook 'forms-mode-hooks) |
| 717 | ;;(message "forms: setting up... done.") | 717 | ;;(message "forms: setting up... done.") |
| 718 | 718 | ||
| 719 | ;; be helpful | 719 | ;; be helpful |
diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog index 14450ee3a14..3681f2fa750 100644 --- a/lisp/gnus/ChangeLog +++ b/lisp/gnus/ChangeLog | |||
| @@ -1,3 +1,241 @@ | |||
| 1 | 2005-06-04 Luc Teirlinck <teirllm@auburn.edu> | ||
| 2 | |||
| 3 | * gnus-art.el (article-update-date-lapsed): Use `save-match-data'. | ||
| 4 | |||
| 5 | 2005-06-04 Lute Kamstra <lute@gnu.org> | ||
| 6 | |||
| 7 | * nnfolder.el (nnfolder-read-folder): Make sure that undo | ||
| 8 | information is never recorded. | ||
| 9 | |||
| 10 | 2005-06-03 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 11 | |||
| 12 | * gnus-art.el (gnus-emphasis-alist): Disable the strikethru thingy. | ||
| 13 | |||
| 14 | 2005-06-02 Katsumi Yamaoka <yamaoka@jpl.org> | ||
| 15 | |||
| 16 | * pop3.el (pop3-md5): Run md5 in the binary mode. | ||
| 17 | (pop3-md5-program-args): New variable. | ||
| 18 | |||
| 19 | * starttls.el (starttls-set-process-query-on-exit-flag): | ||
| 20 | Use eval-and-compile. | ||
| 21 | |||
| 22 | 2005-05-31 Katsumi Yamaoka <yamaoka@jpl.org> | ||
| 23 | |||
| 24 | * gnus-art.el (article-display-x-face): Replace | ||
| 25 | process-kill-without-query by gnus-set-process-query-on-exit-flag. | ||
| 26 | |||
| 27 | * gnus-group.el: Bind gnus-cache-active-hashtb when compiling. | ||
| 28 | |||
| 29 | * gnus-util.el (gnus-set-process-query-on-exit-flag): Alias to | ||
| 30 | set-process-query-on-exit-flag or process-kill-without-query. | ||
| 31 | |||
| 32 | * html2text.el (html2text-fix-paragraphs): Use `while - re-search' | ||
| 33 | loop instead of replace-regexp. | ||
| 34 | |||
| 35 | * imap.el (imap-ssl-open): Use set-process-query-on-exit-flag | ||
| 36 | instead of process-kill-without-query if it is available. | ||
| 37 | |||
| 38 | * mm-util.el (mm-insert-file-contents): Bind find-file-hook | ||
| 39 | instead of find-file-hooks if it is available. | ||
| 40 | |||
| 41 | * mml1991.el: Bind pgg-default-user-id when compiling. | ||
| 42 | |||
| 43 | * mml2015.el: Bind pgg-default-user-id when compiling. | ||
| 44 | |||
| 45 | * nndraft.el (nndraft-request-associate-buffer): | ||
| 46 | Use write-contents-functions instead of write-contents-hooks if it is | ||
| 47 | available. | ||
| 48 | |||
| 49 | * nnheader.el (nnheader-find-file-noselect): Bind find-file-hook | ||
| 50 | instead of find-file-hooks if it is available. | ||
| 51 | |||
| 52 | * nntp.el (nntp-open-connection): Replace | ||
| 53 | process-kill-without-query by gnus-set-process-query-on-exit-flag. | ||
| 54 | (nntp-open-ssl-stream): Ditto. | ||
| 55 | (nntp-open-tls-stream): Ditto. | ||
| 56 | |||
| 57 | * pgg.el: Don't bind itimer vars; don't autoload itimer functions. | ||
| 58 | (pgg-run-at-time-1): New macro. | ||
| 59 | (pgg-run-at-time): Use it. | ||
| 60 | |||
| 61 | * starttls.el (starttls-set-process-query-on-exit-flag): Alias to | ||
| 62 | set-process-query-on-exit-flag or process-kill-without-query. | ||
| 63 | (starttls-open-stream-gnutls): Use it instead of | ||
| 64 | process-kill-without-query. | ||
| 65 | (starttls-open-stream): Ditto. | ||
| 66 | |||
| 67 | 2005-05-31 Simon Josefsson <jas@extundo.com> | ||
| 68 | |||
| 69 | * imap.el (imap-ssl-open): Use imap-process-connection-type, | ||
| 70 | instead of hard coding to nil. | ||
| 71 | |||
| 72 | 2005-05-31 Kevin Greiner <kgreiner@xpediantsolutions.com> | ||
| 73 | |||
| 74 | * gnus-group.el (): Require gnus-sum and autoload functions to | ||
| 75 | resolve warnings when gnus-group.el compiled alone. | ||
| 76 | |||
| 77 | 2005-05-30 Reiner Steib <Reiner.Steib@gmx.de> | ||
| 78 | |||
| 79 | * gnus-agent.el (gnus-agent-regenerate-group) | ||
| 80 | (gnus-agent-fetch-articles): Replace `string-to-int' by | ||
| 81 | `string-to-number'. | ||
| 82 | * gnus-art.el (gnus-button-fetch-group): Ditto. | ||
| 83 | * gnus-cache.el (gnus-cache-generate-active) | ||
| 84 | (gnus-cache-articles-in-group): Ditto. | ||
| 85 | * gnus-group.el (gnus-group-set-current-level) | ||
| 86 | (gnus-group-insert-group-line): Ditto. | ||
| 87 | * gnus-score.el (gnus-score-set-expunge-below) | ||
| 88 | (gnus-score-set-mark-below, gnus-summary-score-effect) | ||
| 89 | (gnus-summary-score-entry): Ditto. | ||
| 90 | * gnus-soup.el (gnus-soup-send-packet, gnus-soup-parse-areas) | ||
| 91 | (gnus-soup-pack): Ditto. | ||
| 92 | * gnus-spec.el (gnus-xmas-format): Ditto. | ||
| 93 | * gnus-start.el (gnus-newsrc-to-gnus-format): Ditto. | ||
| 94 | * gnus-sum.el (gnus-create-xref-hashtb): Ditto. | ||
| 95 | * gnus-uu.el (gnus-uu-expand-numbers): Ditto. | ||
| 96 | * nnbabyl.el (nnbabyl-article-group-number): Ditto. | ||
| 97 | * nndb.el (nndb-get-remote-expire-response): Ditto. | ||
| 98 | * nndiary.el (nndiary-parse-schedule-value) | ||
| 99 | (nndiary-string-to-number, nndiary-request-replace-article) | ||
| 100 | (nndiary-request-article): Ditto. | ||
| 101 | * nndoc.el (nndoc-rnews-body-end, nndoc-mbox-body-end): Ditto. | ||
| 102 | * nndraft.el (nndraft-articles, nndraft-request-group): Ditto. | ||
| 103 | * nneething.el (nneething-make-head): Ditto. | ||
| 104 | * nnfolder.el (nnfolder-request-article) | ||
| 105 | (nnfolder-retrieve-headers): Ditto. | ||
| 106 | * nnheader.el (nnheader-file-to-number): Ditto. | ||
| 107 | * nnkiboze.el (nnkiboze-request-article): Ditto. | ||
| 108 | * nnmail.el (nnmail-process-unix-mail-format) | ||
| 109 | (nnmail-process-babyl-mail-format): Ditto. | ||
| 110 | * nnmbox.el (nnmbox-read-mbox, nnmbox-article-group-number): Ditto. | ||
| 111 | * nnmh.el (nnmh-update-gnus-unreads, nnmh-active-number) | ||
| 112 | (nnmh-request-create-group, nnmh-request-list-1) | ||
| 113 | (nnmh-request-group, nnmh-request-article): Ditto. | ||
| 114 | * nnml.el (nnml-request-replace-article, nnml-request-article): Ditto. | ||
| 115 | * nnrss.el (nnrss-find-rss-via-syndic8): Ditto. | ||
| 116 | * nnsoup.el (nnsoup-make-active): Ditto. | ||
| 117 | * nnspool.el (nnspool-find-id, nnspool-request-group): Ditto. | ||
| 118 | * nntp.el (nntp-find-group-and-number) | ||
| 119 | (nntp-retrieve-headers-with-xover): Ditto. | ||
| 120 | * pgg-gpg.el (pgg-gpg-snarf-keys-region): Ditto. | ||
| 121 | * pgg-parse.el (pgg-read-body, pgg-read-bytes) | ||
| 122 | (pgg-format-key-identifier): Ditto. | ||
| 123 | * pop3.el (pop3-last, pop3-stat): Ditto. | ||
| 124 | * qp.el (quoted-printable-decode-region): Ditto. | ||
| 125 | |||
| 126 | * spam-report.el (spam-report-url-ping-mm-url): Use format instead | ||
| 127 | of concat. | ||
| 128 | |||
| 129 | 2005-05-30 Katsumi Yamaoka <yamaoka@jpl.org> | ||
| 130 | |||
| 131 | * gnus-agent.el (gnus-category-mode): Use gnus-run-mode-hooks. | ||
| 132 | |||
| 133 | * gnus-art.el (gnus-article-mode): Use gnus-run-mode-hooks. | ||
| 134 | |||
| 135 | * gnus-cus.el (gnus-custom-mode): Use gnus-run-mode-hooks. | ||
| 136 | |||
| 137 | * gnus-eform.el (gnus-edit-form-mode): Use gnus-run-mode-hooks. | ||
| 138 | |||
| 139 | * gnus-group.el (gnus-group-mode): Use gnus-run-mode-hooks. | ||
| 140 | |||
| 141 | * gnus-kill.el (gnus-kill-file-mode): Use gnus-run-mode-hooks. | ||
| 142 | |||
| 143 | * gnus-salt.el (gnus-tree-mode): Use gnus-run-mode-hooks. | ||
| 144 | (gnus-carpal-mode): Ditto. | ||
| 145 | |||
| 146 | * gnus-srvr.el (gnus-server-mode): Use gnus-run-mode-hooks. | ||
| 147 | (gnus-browse-mode): Ditto. | ||
| 148 | |||
| 149 | * gnus-sum.el (gnus-summary-mode): Use gnus-run-mode-hooks. | ||
| 150 | |||
| 151 | * gnus-util.el (gnus-run-mode-hooks): Save current buffer. | ||
| 152 | |||
| 153 | 2005-05-29 Richard M. Stallman <rms@gnu.org> | ||
| 154 | |||
| 155 | * gnus-cite.el (gnus-cite-add-face): Set overlay's evaporate property. | ||
| 156 | |||
| 157 | 2005-05-27 Katsumi Yamaoka <yamaoka@jpl.org> | ||
| 158 | |||
| 159 | * gnus-util.el (gnus-run-mode-hooks): New function. | ||
| 160 | |||
| 161 | * score-mode.el (gnus-score-mode): Use gnus-run-mode-hooks. | ||
| 162 | |||
| 163 | 2005-05-26 Luc Teirlinck <teirllm@auburn.edu> | ||
| 164 | |||
| 165 | * gnus-agent.el (gnus-agent-make-mode-line-string): | ||
| 166 | Use mode-line-highlight as mouse-face. | ||
| 167 | |||
| 168 | 2005-05-17 Katsumi Yamaoka <yamaoka@jpl.org> | ||
| 169 | |||
| 170 | * canlock.el (canlock): Change the parent group to news. | ||
| 171 | |||
| 172 | * deuglify.el (gnus-outlook-deuglify): Add :group. | ||
| 173 | |||
| 174 | * dig.el (dig): Add :group. | ||
| 175 | |||
| 176 | * gnus-art.el (gnus-inhibit-mime-unbuttonizing): Add :group. | ||
| 177 | |||
| 178 | * gnus-cite.el (gnus-cite-attribution-face): Add :group. | ||
| 179 | (gnus-cite-face-1, gnus-cite-face-2, gnus-cite-face-3): Ditto. | ||
| 180 | (gnus-cite-face-4, gnus-cite-face-5, gnus-cite-face-6): Ditto. | ||
| 181 | (gnus-cite-face-7, gnus-cite-face-8, gnus-cite-face-9): Ditto. | ||
| 182 | (gnus-cite-face-10, gnus-cite-face-11): Ditto. | ||
| 183 | |||
| 184 | * gnus-diary.el (gnus-diary): Add :group. | ||
| 185 | |||
| 186 | * gnus.el (gnus-group-news-1-face): Add :group. | ||
| 187 | (gnus-group-news-1-empty-face): Ditto. | ||
| 188 | (gnus-group-news-2-face, gnus-group-news-2-empty-face): Ditto. | ||
| 189 | (gnus-group-news-3-face, gnus-group-news-3-empty-face): Ditto. | ||
| 190 | (gnus-group-news-4-face, gnus-group-news-4-empty-face): Ditto. | ||
| 191 | (gnus-group-news-5-face, gnus-group-news-5-empty-face): Ditto. | ||
| 192 | (gnus-group-news-6-face, gnus-group-news-6-empty-face): Ditto. | ||
| 193 | (gnus-group-news-low-face, gnus-group-news-low-empty-face): Ditto. | ||
| 194 | (gnus-group-mail-1-face, gnus-group-mail-1-empty-face): Ditto. | ||
| 195 | (gnus-group-mail-2-face, gnus-group-mail-2-empty-face): Ditto. | ||
| 196 | (gnus-group-mail-3-face, gnus-group-mail-3-empty-face): Ditto. | ||
| 197 | (gnus-group-mail-low-face, gnus-group-mail-low-empty-face): Ditto. | ||
| 198 | (gnus-summary-selected-face, gnus-summary-cancelled-face): Ditto. | ||
| 199 | (gnus-summary-high-ticked-face): Ditto. | ||
| 200 | (gnus-summary-low-ticked-face): Ditto. | ||
| 201 | (gnus-summary-normal-ticked-face): Ditto. | ||
| 202 | (gnus-summary-high-ancient-face): Ditto. | ||
| 203 | (gnus-summary-low-ancient-face): Ditto. | ||
| 204 | (gnus-summary-normal-ancient-face): Ditto. | ||
| 205 | (gnus-summary-high-undownloaded-face): Ditto. | ||
| 206 | (gnus-summary-low-undownloaded-face): Ditto. | ||
| 207 | (gnus-summary-normal-undownloaded-face): Ditto. | ||
| 208 | (gnus-summary-high-unread-face): Ditto. | ||
| 209 | (gnus-summary-low-unread-face): Ditto. | ||
| 210 | (gnus-summary-normal-unread-face): Ditto. | ||
| 211 | (gnus-summary-high-read-face, gnus-summary-low-read-face): Ditto. | ||
| 212 | (gnus-summary-normal-read-face, gnus-splash-face): Ditto. | ||
| 213 | |||
| 214 | * message.el (message-minibuffer-local-map): Add :group. | ||
| 215 | |||
| 216 | * sieve-manage.el (sieve-manage-log): Add :group. | ||
| 217 | (sieve-manage-default-user): Diito. | ||
| 218 | (sieve-manage-server-eol, sieve-manage-client-eol): Ditto. | ||
| 219 | (sieve-manage-streams, sieve-manage-stream-alist): Ditto. | ||
| 220 | (sieve-manage-authenticators): Ditto. | ||
| 221 | (sieve-manage-authenticator-alist): Ditto. | ||
| 222 | (sieve-manage-default-port): Ditto. | ||
| 223 | |||
| 224 | * sieve-mode.el (sieve-control-commands-face): Add :group. | ||
| 225 | (sieve-action-commands-face): Ditto. | ||
| 226 | (sieve-test-commands-face): Ditto. | ||
| 227 | (sieve-tagged-arguments-face): Ditto. | ||
| 228 | |||
| 229 | * smime.el (smime): Add :group. | ||
| 230 | |||
| 231 | * spam-report.el (spam-report): Add :group. | ||
| 232 | |||
| 233 | * spam.el (spam, spam-face): Add :group. | ||
| 234 | |||
| 235 | 2005-05-26 Lute Kamstra <lute@gnu.org> | ||
| 236 | |||
| 237 | * score-mode.el (gnus-score-mode): Use run-mode-hooks. | ||
| 238 | |||
| 1 | 2005-05-16 Katsumi Yamaoka <yamaoka@jpl.org> | 239 | 2005-05-16 Katsumi Yamaoka <yamaoka@jpl.org> |
| 2 | 240 | ||
| 3 | * gnus-art.el: Don't autoload mail-extract-address-components. | 241 | * gnus-art.el: Don't autoload mail-extract-address-components. |
| @@ -213,11 +451,11 @@ | |||
| 213 | 451 | ||
| 214 | * nnimap.el (nnimap-date-days-ago): Ditto. | 452 | * nnimap.el (nnimap-date-days-ago): Ditto. |
| 215 | 453 | ||
| 216 | * gnus-demon.el (parse-time-string): Added autoload. | 454 | * gnus-demon.el (parse-time-string): Add autoload. |
| 217 | 455 | ||
| 218 | * gnus-delay.el (parse-time-string): Added autoload. | 456 | * gnus-delay.el (parse-time-string): Add autoload. |
| 219 | 457 | ||
| 220 | * gnus-art.el (parse-time-string): Added autoload. | 458 | * gnus-art.el (parse-time-string): Add autoload. |
| 221 | 459 | ||
| 222 | * nnultimate.el (parse-time): Require for `parse-time-string'. | 460 | * nnultimate.el (parse-time): Require for `parse-time-string'. |
| 223 | 461 | ||
| @@ -271,14 +509,13 @@ | |||
| 271 | (rfc2047-encoded-word-regexp): Don't use shy group. | 509 | (rfc2047-encoded-word-regexp): Don't use shy group. |
| 272 | (rfc2047-decode-region): Follow rfc2047-encoded-word-regexp change. | 510 | (rfc2047-decode-region): Follow rfc2047-encoded-word-regexp change. |
| 273 | (rfc2047-parse-and-decode): Ditto. | 511 | (rfc2047-parse-and-decode): Ditto. |
| 274 | (rfc2047-decode): Treat the ascii coding-system as raw-text by | 512 | (rfc2047-decode): Treat the ascii coding-system as raw-text by default. |
| 275 | default. | ||
| 276 | 513 | ||
| 277 | 2005-03-25 Lars Magne Ingebrigtsen <larsi@gnus.org> | 514 | 2005-03-25 Lars Magne Ingebrigtsen <larsi@gnus.org> |
| 278 | 515 | ||
| 279 | * rfc2047.el (rfc2047-encode-encoded-words): New variable. | 516 | * rfc2047.el (rfc2047-encode-encoded-words): New variable. |
| 280 | (rfc2047-field-value): Strip props. | 517 | (rfc2047-field-value): Strip props. |
| 281 | (rfc2047-encode-message-header): Disabled header folding -- not | 518 | (rfc2047-encode-message-header): Disable header folding -- not |
| 282 | all headers can be folded, and this should be done by the message | 519 | all headers can be folded, and this should be done by the message |
| 283 | composition mode. Probably. I think. | 520 | composition mode. Probably. I think. |
| 284 | (rfc2047-encodable-p): Say that =? needs encoding. | 521 | (rfc2047-encodable-p): Say that =? needs encoding. |
diff --git a/lisp/gnus/canlock.el b/lisp/gnus/canlock.el index 71c7dbe03d8..126ec0c60ca 100644 --- a/lisp/gnus/canlock.el +++ b/lisp/gnus/canlock.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; canlock.el --- functions for Cancel-Lock feature | 1 | ;;; canlock.el --- functions for Cancel-Lock feature |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1998, 1999, 2001, 2002, 2003, 2004 | 3 | ;; Copyright (C) 1998, 1999, 2001, 2002, 2003, 2004, 2005 |
| 4 | ;; Free Software Foundation, Inc. | 4 | ;; Free Software Foundation, Inc. |
| 5 | 5 | ||
| 6 | ;; Author: Katsumi Yamaoka <yamaoka@jpl.org> | 6 | ;; Author: Katsumi Yamaoka <yamaoka@jpl.org> |
| @@ -50,7 +50,7 @@ | |||
| 50 | 50 | ||
| 51 | (defgroup canlock nil | 51 | (defgroup canlock nil |
| 52 | "The Cancel-Lock feature." | 52 | "The Cancel-Lock feature." |
| 53 | :group 'applications) | 53 | :group 'news) |
| 54 | 54 | ||
| 55 | (defcustom canlock-password nil | 55 | (defcustom canlock-password nil |
| 56 | "Password to use when signing a Cancel-Lock or a Cancel-Key header." | 56 | "Password to use when signing a Cancel-Lock or a Cancel-Key header." |
diff --git a/lisp/gnus/deuglify.el b/lisp/gnus/deuglify.el index 0dc6e6d002a..cae18951f7e 100644 --- a/lisp/gnus/deuglify.el +++ b/lisp/gnus/deuglify.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; deuglify.el --- deuglify broken Outlook (Express) articles | 1 | ;;; deuglify.el --- deuglify broken Outlook (Express) articles |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 2002, 2003, 2004 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 2002, 2003, 2004, 2005 Free Software Foundation, Inc. |
| 4 | ;; Copyright (C) 2001, 2002 Raymond Scholz | 4 | ;; Copyright (C) 2001, 2002 Raymond Scholz |
| 5 | 5 | ||
| 6 | ;; Author: Raymond Scholz <rscholz@zonix.de> | 6 | ;; Author: Raymond Scholz <rscholz@zonix.de> |
| @@ -231,7 +231,8 @@ | |||
| 231 | 231 | ||
| 232 | (defgroup gnus-outlook-deuglify nil | 232 | (defgroup gnus-outlook-deuglify nil |
| 233 | "Deuglify articles generated by broken user agents like MS Outlook (Express)." | 233 | "Deuglify articles generated by broken user agents like MS Outlook (Express)." |
| 234 | :version "22.1") | 234 | :version "22.1" |
| 235 | :group 'gnus) | ||
| 235 | 236 | ||
| 236 | ;;;###autoload | 237 | ;;;###autoload |
| 237 | (defcustom gnus-outlook-deuglify-unwrap-min 45 | 238 | (defcustom gnus-outlook-deuglify-unwrap-min 45 |
diff --git a/lisp/gnus/dig.el b/lisp/gnus/dig.el index 08070e985f8..a3d55cbf824 100644 --- a/lisp/gnus/dig.el +++ b/lisp/gnus/dig.el | |||
| @@ -1,5 +1,5 @@ | |||
| 1 | ;;; dig.el --- Domain Name System dig interface | 1 | ;;; dig.el --- Domain Name System dig interface |
| 2 | ;; Copyright (c) 2000, 2001, 2003 Free Software Foundation, Inc. | 2 | ;; Copyright (c) 2000, 2001, 2003, 2005 Free Software Foundation, Inc. |
| 3 | 3 | ||
| 4 | ;; Author: Simon Josefsson <simon@josefsson.org> | 4 | ;; Author: Simon Josefsson <simon@josefsson.org> |
| 5 | ;; Keywords: DNS BIND dig | 5 | ;; Keywords: DNS BIND dig |
| @@ -40,7 +40,8 @@ | |||
| 40 | (eval-when-compile (require 'cl)) | 40 | (eval-when-compile (require 'cl)) |
| 41 | 41 | ||
| 42 | (defgroup dig nil | 42 | (defgroup dig nil |
| 43 | "Dig configuration.") | 43 | "Dig configuration." |
| 44 | :group 'comm) | ||
| 44 | 45 | ||
| 45 | (defcustom dig-program "dig" | 46 | (defcustom dig-program "dig" |
| 46 | "Name of dig (domain information groper) binary." | 47 | "Name of dig (domain information groper) binary." |
diff --git a/lisp/gnus/gnus-agent.el b/lisp/gnus/gnus-agent.el index 4236c7958fb..9f4525e1ae2 100644 --- a/lisp/gnus/gnus-agent.el +++ b/lisp/gnus/gnus-agent.el | |||
| @@ -561,7 +561,8 @@ manipulated as follows: | |||
| 561 | (if (and (fboundp 'propertize) | 561 | (if (and (fboundp 'propertize) |
| 562 | (fboundp 'make-mode-line-mouse-map)) | 562 | (fboundp 'make-mode-line-mouse-map)) |
| 563 | (propertize string 'local-map | 563 | (propertize string 'local-map |
| 564 | (make-mode-line-mouse-map mouse-button mouse-func)) | 564 | (make-mode-line-mouse-map mouse-button mouse-func) |
| 565 | 'mouse-face 'mode-line-highlight) | ||
| 565 | string)) | 566 | string)) |
| 566 | 567 | ||
| 567 | (defun gnus-agent-toggle-plugged (set-to) | 568 | (defun gnus-agent-toggle-plugged (set-to) |
| @@ -1539,7 +1540,7 @@ downloaded into the agent." | |||
| 1539 | (while (looking-at "\\([^: \n]+\\):\\([0-9]+\\) *") | 1540 | (while (looking-at "\\([^: \n]+\\):\\([0-9]+\\) *") |
| 1540 | (push (cons (buffer-substring (match-beginning 1) | 1541 | (push (cons (buffer-substring (match-beginning 1) |
| 1541 | (match-end 1)) | 1542 | (match-end 1)) |
| 1542 | (string-to-int | 1543 | (string-to-number |
| 1543 | (buffer-substring (match-beginning 2) | 1544 | (buffer-substring (match-beginning 2) |
| 1544 | (match-end 2)))) | 1545 | (match-end 2)))) |
| 1545 | crosses) | 1546 | crosses) |
| @@ -2551,7 +2552,7 @@ The following commands are available: | |||
| 2551 | (buffer-disable-undo) | 2552 | (buffer-disable-undo) |
| 2552 | (setq truncate-lines t) | 2553 | (setq truncate-lines t) |
| 2553 | (setq buffer-read-only t) | 2554 | (setq buffer-read-only t) |
| 2554 | (gnus-run-hooks 'gnus-category-mode-hook)) | 2555 | (gnus-run-mode-hooks 'gnus-category-mode-hook)) |
| 2555 | 2556 | ||
| 2556 | (defalias 'gnus-category-position-point 'gnus-goto-colon) | 2557 | (defalias 'gnus-category-position-point 'gnus-goto-colon) |
| 2557 | 2558 | ||
| @@ -3702,7 +3703,7 @@ If REREAD is not nil, downloaded articles are marked as unread." | |||
| 3702 | (dir (file-name-directory file)) | 3703 | (dir (file-name-directory file)) |
| 3703 | point | 3704 | point |
| 3704 | (downloaded (if (file-exists-p dir) | 3705 | (downloaded (if (file-exists-p dir) |
| 3705 | (sort (mapcar (lambda (name) (string-to-int name)) | 3706 | (sort (mapcar (lambda (name) (string-to-number name)) |
| 3706 | (directory-files dir nil "^[0-9]+$" t)) | 3707 | (directory-files dir nil "^[0-9]+$" t)) |
| 3707 | '>) | 3708 | '>) |
| 3708 | (progn (gnus-make-directory dir) nil))) | 3709 | (progn (gnus-make-directory dir) nil))) |
diff --git a/lisp/gnus/gnus-art.el b/lisp/gnus/gnus-art.el index b1a51d65edd..498596dd63c 100644 --- a/lisp/gnus/gnus-art.el +++ b/lisp/gnus/gnus-art.el | |||
| @@ -367,8 +367,12 @@ advertisements. For example: | |||
| 367 | (or (nth 4 spec) 3) | 367 | (or (nth 4 spec) 3) |
| 368 | (intern (format "gnus-emphasis-%s" (nth 2 spec))))) | 368 | (intern (format "gnus-emphasis-%s" (nth 2 spec))))) |
| 369 | types)) | 369 | types)) |
| 370 | '(("\\(\\s-\\|^\\)\\(-\\(\\(\\w\\|-[^-]\\)+\\)-\\)\\(\\s-\\|[?!.,;]\\)" | 370 | '(;; I've never seen anyone use this strikethru convention whereas I've |
| 371 | 2 3 gnus-emphasis-strikethru) | 371 | ;; several times seen it triggered by normal text. --Stef |
| 372 | ;; Miles suggests that this form is sometimes used but for italics, | ||
| 373 | ;; so maybe we should map it to `italic'. | ||
| 374 | ;; ("\\(\\s-\\|^\\)\\(-\\(\\(\\w\\|-[^-]\\)+\\)-\\)\\(\\s-\\|[?!.,;]\\)" | ||
| 375 | ;; 2 3 gnus-emphasis-strikethru) | ||
| 372 | ("\\(\\s-\\|^\\)\\(_\\(\\(\\w\\|_[^_]\\)+\\)_\\)\\(\\s-\\|[?!.,;]\\)" | 376 | ("\\(\\s-\\|^\\)\\(_\\(\\(\\w\\|_[^_]\\)+\\)_\\)\\(\\s-\\|[?!.,;]\\)" |
| 373 | 2 3 gnus-emphasis-underline)))) | 377 | 2 3 gnus-emphasis-underline)))) |
| 374 | "*Alist that says how to fontify certain phrases. | 378 | "*Alist that says how to fontify certain phrases. |
| @@ -814,6 +818,7 @@ When nil (the default value), then some MIME parts do not get buttons, | |||
| 814 | as described by the variables `gnus-buttonized-mime-types' and | 818 | as described by the variables `gnus-buttonized-mime-types' and |
| 815 | `gnus-unbuttonized-mime-types'." | 819 | `gnus-unbuttonized-mime-types'." |
| 816 | :version "22.1" | 820 | :version "22.1" |
| 821 | :group 'gnus-article-mime | ||
| 817 | :type 'boolean) | 822 | :type 'boolean) |
| 818 | 823 | ||
| 819 | (defcustom gnus-body-boundary-delimiter "_" | 824 | (defcustom gnus-body-boundary-delimiter "_" |
| @@ -2180,10 +2185,11 @@ unfolded." | |||
| 2180 | ;; The command is a string, so we interpret the command | 2185 | ;; The command is a string, so we interpret the command |
| 2181 | ;; as a, well, command, and fork it off. | 2186 | ;; as a, well, command, and fork it off. |
| 2182 | (let ((process-connection-type nil)) | 2187 | (let ((process-connection-type nil)) |
| 2183 | (process-kill-without-query | 2188 | (gnus-set-process-query-on-exit-flag |
| 2184 | (start-process | 2189 | (start-process |
| 2185 | "article-x-face" nil shell-file-name | 2190 | "article-x-face" nil shell-file-name |
| 2186 | shell-command-switch gnus-article-x-face-command)) | 2191 | shell-command-switch gnus-article-x-face-command) |
| 2192 | nil) | ||
| 2187 | (with-temp-buffer | 2193 | (with-temp-buffer |
| 2188 | (insert face) | 2194 | (insert face) |
| 2189 | (process-send-region "article-x-face" | 2195 | (process-send-region "article-x-face" |
| @@ -3032,20 +3038,21 @@ function and want to see what the date was before converting." | |||
| 3032 | 3038 | ||
| 3033 | (defun article-update-date-lapsed () | 3039 | (defun article-update-date-lapsed () |
| 3034 | "Function to be run from a timer to update the lapsed time line." | 3040 | "Function to be run from a timer to update the lapsed time line." |
| 3035 | (let (deactivate-mark) | 3041 | (save-match-data |
| 3036 | (save-excursion | 3042 | (let (deactivate-mark) |
| 3037 | (ignore-errors | 3043 | (save-excursion |
| 3038 | (walk-windows | 3044 | (ignore-errors |
| 3039 | (lambda (w) | 3045 | (walk-windows |
| 3040 | (set-buffer (window-buffer w)) | 3046 | (lambda (w) |
| 3041 | (when (eq major-mode 'gnus-article-mode) | 3047 | (set-buffer (window-buffer w)) |
| 3042 | (let ((mark (point-marker))) | 3048 | (when (eq major-mode 'gnus-article-mode) |
| 3043 | (goto-char (point-min)) | 3049 | (let ((mark (point-marker))) |
| 3044 | (when (re-search-forward "^X-Sent:" nil t) | 3050 | (goto-char (point-min)) |
| 3045 | (article-date-lapsed t)) | 3051 | (when (re-search-forward "^X-Sent:" nil t) |
| 3046 | (goto-char (marker-position mark)) | 3052 | (article-date-lapsed t)) |
| 3047 | (move-marker mark nil)))) | 3053 | (goto-char (marker-position mark)) |
| 3048 | nil 'visible))))) | 3054 | (move-marker mark nil)))) |
| 3055 | nil 'visible)))))) | ||
| 3049 | 3056 | ||
| 3050 | (defun gnus-start-date-timer (&optional n) | 3057 | (defun gnus-start-date-timer (&optional n) |
| 3051 | "Start a timer to update the X-Sent header in the article buffers. | 3058 | "Start a timer to update the X-Sent header in the article buffers. |
| @@ -3741,7 +3748,7 @@ commands: | |||
| 3741 | (setq buffer-read-only t) | 3748 | (setq buffer-read-only t) |
| 3742 | (set-syntax-table gnus-article-mode-syntax-table) | 3749 | (set-syntax-table gnus-article-mode-syntax-table) |
| 3743 | (mm-enable-multibyte) | 3750 | (mm-enable-multibyte) |
| 3744 | (gnus-run-hooks 'gnus-article-mode-hook)) | 3751 | (gnus-run-mode-hooks 'gnus-article-mode-hook)) |
| 3745 | 3752 | ||
| 3746 | (defun gnus-article-setup-buffer () | 3753 | (defun gnus-article-setup-buffer () |
| 3747 | "Initialize the article buffer." | 3754 | "Initialize the article buffer." |
| @@ -6786,7 +6793,7 @@ specified by `gnus-button-alist'." | |||
| 6786 | (match-string 3 address) | 6793 | (match-string 3 address) |
| 6787 | "nntp"))) | 6794 | "nntp"))) |
| 6788 | nil nil nil | 6795 | nil nil nil |
| 6789 | (and (match-end 6) (list (string-to-int (match-string 6 address)))))))) | 6796 | (and (match-end 6) (list (string-to-number (match-string 6 address)))))))) |
| 6790 | 6797 | ||
| 6791 | (defun gnus-url-parse-query-string (query &optional downcase) | 6798 | (defun gnus-url-parse-query-string (query &optional downcase) |
| 6792 | (let (retval pairs cur key val) | 6799 | (let (retval pairs cur key val) |
diff --git a/lisp/gnus/gnus-cache.el b/lisp/gnus/gnus-cache.el index 657ade98167..55544d1525c 100644 --- a/lisp/gnus/gnus-cache.el +++ b/lisp/gnus/gnus-cache.el | |||
| @@ -487,7 +487,7 @@ Returns the list of articles removed." | |||
| 487 | articles) | 487 | articles) |
| 488 | (when (file-exists-p dir) | 488 | (when (file-exists-p dir) |
| 489 | (setq articles | 489 | (setq articles |
| 490 | (sort (mapcar (lambda (name) (string-to-int name)) | 490 | (sort (mapcar (lambda (name) (string-to-number name)) |
| 491 | (directory-files dir nil "^[0-9]+$" t)) | 491 | (directory-files dir nil "^[0-9]+$" t)) |
| 492 | '<)) | 492 | '<)) |
| 493 | ;; Update the cache active file, just to synch more. | 493 | ;; Update the cache active file, just to synch more. |
| @@ -681,7 +681,7 @@ If LOW, update the lower bound instead." | |||
| 681 | ;; Separate articles from all other files and directories. | 681 | ;; Separate articles from all other files and directories. |
| 682 | (while files | 682 | (while files |
| 683 | (if (string-match "^[0-9]+$" (file-name-nondirectory (car files))) | 683 | (if (string-match "^[0-9]+$" (file-name-nondirectory (car files))) |
| 684 | (push (string-to-int (file-name-nondirectory (pop files))) nums) | 684 | (push (string-to-number (file-name-nondirectory (pop files))) nums) |
| 685 | (push (pop files) alphs))) | 685 | (push (pop files) alphs))) |
| 686 | ;; If we have nums, then this is probably a valid group. | 686 | ;; If we have nums, then this is probably a valid group. |
| 687 | (when (setq nums (sort nums '<)) | 687 | (when (setq nums (sort nums '<)) |
diff --git a/lisp/gnus/gnus-cite.el b/lisp/gnus/gnus-cite.el index e60ea32e126..090a365f994 100644 --- a/lisp/gnus/gnus-cite.el +++ b/lisp/gnus/gnus-cite.el | |||
| @@ -1,6 +1,7 @@ | |||
| 1 | ;;; gnus-cite.el --- parse citations in articles for Gnus | 1 | ;;; gnus-cite.el --- parse citations in articles for Gnus |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 | 3 | ;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, |
| 4 | ;; 2005 | ||
| 4 | ;; Free Software Foundation, Inc. | 5 | ;; Free Software Foundation, Inc. |
| 5 | 6 | ||
| 6 | ;; Author: Per Abhiddenware | 7 | ;; Author: Per Abhiddenware |
| @@ -138,7 +139,8 @@ the envelope From line." | |||
| 138 | 139 | ||
| 139 | (defface gnus-cite-attribution-face '((t | 140 | (defface gnus-cite-attribution-face '((t |
| 140 | (:italic t))) | 141 | (:italic t))) |
| 141 | "Face used for attribution lines.") | 142 | "Face used for attribution lines." |
| 143 | :group 'gnus-cite) | ||
| 142 | 144 | ||
| 143 | (defcustom gnus-cite-attribution-face 'gnus-cite-attribution-face | 145 | (defcustom gnus-cite-attribution-face 'gnus-cite-attribution-face |
| 144 | "Face used for attribution lines. | 146 | "Face used for attribution lines. |
| @@ -155,7 +157,8 @@ It is merged with the face for the cited text belonging to the attribution." | |||
| 155 | (:foreground "MidnightBlue")) | 157 | (:foreground "MidnightBlue")) |
| 156 | (t | 158 | (t |
| 157 | (:italic t))) | 159 | (:italic t))) |
| 158 | "Citation face.") | 160 | "Citation face." |
| 161 | :group 'gnus-cite) | ||
| 159 | 162 | ||
| 160 | (defface gnus-cite-face-2 '((((class color) | 163 | (defface gnus-cite-face-2 '((((class color) |
| 161 | (background dark)) | 164 | (background dark)) |
| @@ -165,7 +168,8 @@ It is merged with the face for the cited text belonging to the attribution." | |||
| 165 | (:foreground "firebrick")) | 168 | (:foreground "firebrick")) |
| 166 | (t | 169 | (t |
| 167 | (:italic t))) | 170 | (:italic t))) |
| 168 | "Citation face.") | 171 | "Citation face." |
| 172 | :group 'gnus-cite) | ||
| 169 | 173 | ||
| 170 | (defface gnus-cite-face-3 '((((class color) | 174 | (defface gnus-cite-face-3 '((((class color) |
| 171 | (background dark)) | 175 | (background dark)) |
| @@ -175,7 +179,8 @@ It is merged with the face for the cited text belonging to the attribution." | |||
| 175 | (:foreground "dark green")) | 179 | (:foreground "dark green")) |
| 176 | (t | 180 | (t |
| 177 | (:italic t))) | 181 | (:italic t))) |
| 178 | "Citation face.") | 182 | "Citation face." |
| 183 | :group 'gnus-cite) | ||
| 179 | 184 | ||
| 180 | (defface gnus-cite-face-4 '((((class color) | 185 | (defface gnus-cite-face-4 '((((class color) |
| 181 | (background dark)) | 186 | (background dark)) |
| @@ -185,7 +190,8 @@ It is merged with the face for the cited text belonging to the attribution." | |||
| 185 | (:foreground "OrangeRed")) | 190 | (:foreground "OrangeRed")) |
| 186 | (t | 191 | (t |
| 187 | (:italic t))) | 192 | (:italic t))) |
| 188 | "Citation face.") | 193 | "Citation face." |
| 194 | :group 'gnus-cite) | ||
| 189 | 195 | ||
| 190 | (defface gnus-cite-face-5 '((((class color) | 196 | (defface gnus-cite-face-5 '((((class color) |
| 191 | (background dark)) | 197 | (background dark)) |
| @@ -195,7 +201,8 @@ It is merged with the face for the cited text belonging to the attribution." | |||
| 195 | (:foreground "dark khaki")) | 201 | (:foreground "dark khaki")) |
| 196 | (t | 202 | (t |
| 197 | (:italic t))) | 203 | (:italic t))) |
| 198 | "Citation face.") | 204 | "Citation face." |
| 205 | :group 'gnus-cite) | ||
| 199 | 206 | ||
| 200 | (defface gnus-cite-face-6 '((((class color) | 207 | (defface gnus-cite-face-6 '((((class color) |
| 201 | (background dark)) | 208 | (background dark)) |
| @@ -205,7 +212,8 @@ It is merged with the face for the cited text belonging to the attribution." | |||
| 205 | (:foreground "dark violet")) | 212 | (:foreground "dark violet")) |
| 206 | (t | 213 | (t |
| 207 | (:italic t))) | 214 | (:italic t))) |
| 208 | "Citation face.") | 215 | "Citation face." |
| 216 | :group 'gnus-cite) | ||
| 209 | 217 | ||
| 210 | (defface gnus-cite-face-7 '((((class color) | 218 | (defface gnus-cite-face-7 '((((class color) |
| 211 | (background dark)) | 219 | (background dark)) |
| @@ -215,7 +223,8 @@ It is merged with the face for the cited text belonging to the attribution." | |||
| 215 | (:foreground "SteelBlue4")) | 223 | (:foreground "SteelBlue4")) |
| 216 | (t | 224 | (t |
| 217 | (:italic t))) | 225 | (:italic t))) |
| 218 | "Citation face.") | 226 | "Citation face." |
| 227 | :group 'gnus-cite) | ||
| 219 | 228 | ||
| 220 | (defface gnus-cite-face-8 '((((class color) | 229 | (defface gnus-cite-face-8 '((((class color) |
| 221 | (background dark)) | 230 | (background dark)) |
| @@ -225,7 +234,8 @@ It is merged with the face for the cited text belonging to the attribution." | |||
| 225 | (:foreground "magenta")) | 234 | (:foreground "magenta")) |
| 226 | (t | 235 | (t |
| 227 | (:italic t))) | 236 | (:italic t))) |
| 228 | "Citation face.") | 237 | "Citation face." |
| 238 | :group 'gnus-cite) | ||
| 229 | 239 | ||
| 230 | (defface gnus-cite-face-9 '((((class color) | 240 | (defface gnus-cite-face-9 '((((class color) |
| 231 | (background dark)) | 241 | (background dark)) |
| @@ -235,7 +245,8 @@ It is merged with the face for the cited text belonging to the attribution." | |||
| 235 | (:foreground "violet")) | 245 | (:foreground "violet")) |
| 236 | (t | 246 | (t |
| 237 | (:italic t))) | 247 | (:italic t))) |
| 238 | "Citation face.") | 248 | "Citation face." |
| 249 | :group 'gnus-cite) | ||
| 239 | 250 | ||
| 240 | (defface gnus-cite-face-10 '((((class color) | 251 | (defface gnus-cite-face-10 '((((class color) |
| 241 | (background dark)) | 252 | (background dark)) |
| @@ -245,7 +256,8 @@ It is merged with the face for the cited text belonging to the attribution." | |||
| 245 | (:foreground "medium purple")) | 256 | (:foreground "medium purple")) |
| 246 | (t | 257 | (t |
| 247 | (:italic t))) | 258 | (:italic t))) |
| 248 | "Citation face.") | 259 | "Citation face." |
| 260 | :group 'gnus-cite) | ||
| 249 | 261 | ||
| 250 | (defface gnus-cite-face-11 '((((class color) | 262 | (defface gnus-cite-face-11 '((((class color) |
| 251 | (background dark)) | 263 | (background dark)) |
| @@ -255,7 +267,8 @@ It is merged with the face for the cited text belonging to the attribution." | |||
| 255 | (:foreground "turquoise")) | 267 | (:foreground "turquoise")) |
| 256 | (t | 268 | (t |
| 257 | (:italic t))) | 269 | (:italic t))) |
| 258 | "Citation face.") | 270 | "Citation face." |
| 271 | :group 'gnus-cite) | ||
| 259 | 272 | ||
| 260 | (defcustom gnus-cite-face-list | 273 | (defcustom gnus-cite-face-list |
| 261 | '(gnus-cite-face-1 gnus-cite-face-2 gnus-cite-face-3 gnus-cite-face-4 | 274 | '(gnus-cite-face-1 gnus-cite-face-2 gnus-cite-face-3 gnus-cite-face-4 |
| @@ -1004,6 +1017,7 @@ See also the documentation for `gnus-article-highlight-citation'." | |||
| 1004 | (when (< from to) | 1017 | (when (< from to) |
| 1005 | (push (setq overlay (gnus-make-overlay from to)) | 1018 | (push (setq overlay (gnus-make-overlay from to)) |
| 1006 | gnus-cite-overlay-list) | 1019 | gnus-cite-overlay-list) |
| 1020 | (gnus-overlay-put overlay 'evaporate t) | ||
| 1007 | (gnus-overlay-put overlay 'face face)))))) | 1021 | (gnus-overlay-put overlay 'face face)))))) |
| 1008 | 1022 | ||
| 1009 | (defun gnus-cite-toggle (prefix) | 1023 | (defun gnus-cite-toggle (prefix) |
diff --git a/lisp/gnus/gnus-cus.el b/lisp/gnus/gnus-cus.el index 4388db5c9e5..0c31ea9dd1b 100644 --- a/lisp/gnus/gnus-cus.el +++ b/lisp/gnus/gnus-cus.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; gnus-cus.el --- customization commands for Gnus | 1 | ;;; gnus-cus.el --- customization commands for Gnus |
| 2 | ;; | 2 | ;; |
| 3 | ;; Copyright (C) 1996, 1999, 2000, 2001, 2002, 2003, 2004 | 3 | ;; Copyright (C) 1996, 1999, 2000, 2001, 2002, 2003, 2004, 2005 |
| 4 | ;; Free Software Foundation, Inc. | 4 | ;; Free Software Foundation, Inc. |
| 5 | 5 | ||
| 6 | ;; Author: Per Abrahamsen <abraham@dina.kvl.dk> | 6 | ;; Author: Per Abrahamsen <abraham@dina.kvl.dk> |
| @@ -67,7 +67,7 @@ if that value is non-nil." | |||
| 67 | (set (make-local-variable 'widget-push-button-suffix) "") | 67 | (set (make-local-variable 'widget-push-button-suffix) "") |
| 68 | (set (make-local-variable 'widget-link-prefix) "") | 68 | (set (make-local-variable 'widget-link-prefix) "") |
| 69 | (set (make-local-variable 'widget-link-suffix) "")) | 69 | (set (make-local-variable 'widget-link-suffix) "")) |
| 70 | (gnus-run-hooks 'gnus-custom-mode-hook)) | 70 | (gnus-run-mode-hooks 'gnus-custom-mode-hook)) |
| 71 | 71 | ||
| 72 | ;;; Group Customization: | 72 | ;;; Group Customization: |
| 73 | 73 | ||
diff --git a/lisp/gnus/gnus-diary.el b/lisp/gnus/gnus-diary.el index 093f4bd7806..c34c3b6df88 100644 --- a/lisp/gnus/gnus-diary.el +++ b/lisp/gnus/gnus-diary.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; gnus-diary.el --- Wrapper around the NNDiary Gnus backend | 1 | ;;; gnus-diary.el --- Wrapper around the NNDiary Gnus backend |
| 2 | 2 | ||
| 3 | ;; Copyright (c) 2001, 2002, 2003 Free Software Foundation, Inc. | 3 | ;; Copyright (c) 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. |
| 4 | ;; Copyright (C) 1999, 2000, 2001 Didier Verna. | 4 | ;; Copyright (C) 1999, 2000, 2001 Didier Verna. |
| 5 | 5 | ||
| 6 | ;; Author: Didier Verna <didier@xemacs.org> | 6 | ;; Author: Didier Verna <didier@xemacs.org> |
| @@ -103,7 +103,8 @@ | |||
| 103 | 103 | ||
| 104 | (defgroup gnus-diary nil | 104 | (defgroup gnus-diary nil |
| 105 | "Utilities on top of the nndiary backend for Gnus." | 105 | "Utilities on top of the nndiary backend for Gnus." |
| 106 | :version "22.1") | 106 | :version "22.1" |
| 107 | :group 'gnus) | ||
| 107 | 108 | ||
| 108 | (defcustom gnus-diary-summary-line-format "%U%R%z %uD: %(%s%) (%ud)\n" | 109 | (defcustom gnus-diary-summary-line-format "%U%R%z %uD: %(%s%) (%ud)\n" |
| 109 | "*Summary line format for nndiary groups." | 110 | "*Summary line format for nndiary groups." |
diff --git a/lisp/gnus/gnus-eform.el b/lisp/gnus/gnus-eform.el index ae5debaff01..b1e83eab7ec 100644 --- a/lisp/gnus/gnus-eform.el +++ b/lisp/gnus/gnus-eform.el | |||
| @@ -1,5 +1,5 @@ | |||
| 1 | ;;; gnus-eform.el --- a mode for editing forms for Gnus | 1 | ;;; gnus-eform.el --- a mode for editing forms for Gnus |
| 2 | ;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2004 | 2 | ;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2004, 2005 |
| 3 | ;; Free Software Foundation, Inc. | 3 | ;; Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> | 5 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> |
| @@ -83,7 +83,7 @@ It is a slightly enhanced emacs-lisp-mode. | |||
| 83 | (use-local-map gnus-edit-form-mode-map) | 83 | (use-local-map gnus-edit-form-mode-map) |
| 84 | (make-local-variable 'gnus-edit-form-done-function) | 84 | (make-local-variable 'gnus-edit-form-done-function) |
| 85 | (make-local-variable 'gnus-prev-winconf) | 85 | (make-local-variable 'gnus-prev-winconf) |
| 86 | (gnus-run-hooks 'gnus-edit-form-mode-hook)) | 86 | (gnus-run-mode-hooks 'gnus-edit-form-mode-hook)) |
| 87 | 87 | ||
| 88 | (defun gnus-edit-form (form documentation exit-func) | 88 | (defun gnus-edit-form (form documentation exit-func) |
| 89 | "Edit FORM in a new buffer. | 89 | "Edit FORM in a new buffer. |
diff --git a/lisp/gnus/gnus-group.el b/lisp/gnus/gnus-group.el index 30b7fe68dd1..f1343d9dbd3 100644 --- a/lisp/gnus/gnus-group.el +++ b/lisp/gnus/gnus-group.el | |||
| @@ -1,5 +1,5 @@ | |||
| 1 | ;;; gnus-group.el --- group mode commands for Gnus | 1 | ;;; gnus-group.el --- group mode commands for Gnus |
| 2 | ;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 | 2 | ;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 |
| 3 | ;; Free Software Foundation, Inc. | 3 | ;; Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> | 5 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> |
| @@ -41,7 +41,11 @@ | |||
| 41 | (require 'time-date) | 41 | (require 'time-date) |
| 42 | (require 'gnus-ems) | 42 | (require 'gnus-ems) |
| 43 | 43 | ||
| 44 | (eval-when-compile (require 'mm-url)) | 44 | (eval-when-compile |
| 45 | (require 'mm-url) | ||
| 46 | (let ((features (cons 'gnus-group features))) | ||
| 47 | (require 'gnus-sum)) | ||
| 48 | (defvar gnus-cache-active-hashtb)) | ||
| 45 | 49 | ||
| 46 | (defcustom gnus-group-archive-directory | 50 | (defcustom gnus-group-archive-directory |
| 47 | "/ftp@ftp.hpc.uh.edu:/pub/emacs/ding-list/" | 51 | "/ftp@ftp.hpc.uh.edu:/pub/emacs/ding-list/" |
| @@ -1042,7 +1046,7 @@ The following commands are available: | |||
| 1042 | (gnus-undo-mode 1)) | 1046 | (gnus-undo-mode 1)) |
| 1043 | (when gnus-slave | 1047 | (when gnus-slave |
| 1044 | (gnus-slave-mode)) | 1048 | (gnus-slave-mode)) |
| 1045 | (gnus-run-hooks 'gnus-group-mode-hook)) | 1049 | (gnus-run-mode-hooks 'gnus-group-mode-hook)) |
| 1046 | 1050 | ||
| 1047 | (defun gnus-update-group-mark-positions () | 1051 | (defun gnus-update-group-mark-positions () |
| 1048 | (save-excursion | 1052 | (save-excursion |
| @@ -1452,7 +1456,7 @@ if it is a string, only list groups matching REGEXP." | |||
| 1452 | (eval gnus-group-line-format-spec))) | 1456 | (eval gnus-group-line-format-spec))) |
| 1453 | `(gnus-group ,(gnus-intern-safe gnus-tmp-group gnus-active-hashtb) | 1457 | `(gnus-group ,(gnus-intern-safe gnus-tmp-group gnus-active-hashtb) |
| 1454 | gnus-unread ,(if (numberp number) | 1458 | gnus-unread ,(if (numberp number) |
| 1455 | (string-to-int gnus-tmp-number-of-unread) | 1459 | (string-to-number gnus-tmp-number-of-unread) |
| 1456 | t) | 1460 | t) |
| 1457 | gnus-marked ,gnus-tmp-marked-mark | 1461 | gnus-marked ,gnus-tmp-marked-mark |
| 1458 | gnus-indentation ,gnus-group-indentation | 1462 | gnus-indentation ,gnus-group-indentation |
| @@ -3246,7 +3250,7 @@ Uses the process/prefix convention." | |||
| 3246 | (progn | 3250 | (progn |
| 3247 | (unless (gnus-group-process-prefix current-prefix-arg) | 3251 | (unless (gnus-group-process-prefix current-prefix-arg) |
| 3248 | (error "No group on the current line")) | 3252 | (error "No group on the current line")) |
| 3249 | (string-to-int | 3253 | (string-to-number |
| 3250 | (let ((s (read-string | 3254 | (let ((s (read-string |
| 3251 | (format "Level (default %s): " | 3255 | (format "Level (default %s): " |
| 3252 | (or (gnus-group-group-level) | 3256 | (or (gnus-group-group-level) |
diff --git a/lisp/gnus/gnus-kill.el b/lisp/gnus/gnus-kill.el index 7b04422b36c..e35ee0858b4 100644 --- a/lisp/gnus/gnus-kill.el +++ b/lisp/gnus/gnus-kill.el | |||
| @@ -1,5 +1,5 @@ | |||
| 1 | ;;; gnus-kill.el --- kill commands for Gnus | 1 | ;;; gnus-kill.el --- kill commands for Gnus |
| 2 | ;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2003 | 2 | ;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005 |
| 3 | ;; Free Software Foundation, Inc. | 3 | ;; Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Masanobu UMEDA <umerin@flab.flab.fujitsu.junet> | 5 | ;; Author: Masanobu UMEDA <umerin@flab.flab.fujitsu.junet> |
| @@ -161,7 +161,7 @@ gnus-kill-file-mode-hook with no arguments, if that value is non-nil." | |||
| 161 | (setq major-mode 'gnus-kill-file-mode) | 161 | (setq major-mode 'gnus-kill-file-mode) |
| 162 | (setq mode-name "Kill") | 162 | (setq mode-name "Kill") |
| 163 | (lisp-mode-variables nil) | 163 | (lisp-mode-variables nil) |
| 164 | (gnus-run-hooks 'emacs-lisp-mode-hook 'gnus-kill-file-mode-hook)) | 164 | (gnus-run-mode-hooks 'emacs-lisp-mode-hook 'gnus-kill-file-mode-hook)) |
| 165 | 165 | ||
| 166 | (defun gnus-kill-file-edit-file (newsgroup) | 166 | (defun gnus-kill-file-edit-file (newsgroup) |
| 167 | "Begin editing a kill file for NEWSGROUP. | 167 | "Begin editing a kill file for NEWSGROUP. |
diff --git a/lisp/gnus/gnus-salt.el b/lisp/gnus/gnus-salt.el index 0f4984112f5..f3ad1546993 100644 --- a/lisp/gnus/gnus-salt.el +++ b/lisp/gnus/gnus-salt.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; gnus-salt.el --- alternate summary mode interfaces for Gnus | 1 | ;;; gnus-salt.el --- alternate summary mode interfaces for Gnus |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1996, 1997, 1998, 1999, 2001 | 3 | ;; Copyright (C) 1996, 1997, 1998, 1999, 2001, 2002, 2004, 2005 |
| 4 | ;; Free Software Foundation, Inc. | 4 | ;; Free Software Foundation, Inc. |
| 5 | 5 | ||
| 6 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> | 6 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> |
| @@ -496,7 +496,7 @@ Two predefined functions are available: | |||
| 496 | (gnus-set-work-buffer) | 496 | (gnus-set-work-buffer) |
| 497 | (gnus-tree-node-insert (make-mail-header "") nil) | 497 | (gnus-tree-node-insert (make-mail-header "") nil) |
| 498 | (setq gnus-tree-node-length (1- (point)))) | 498 | (setq gnus-tree-node-length (1- (point)))) |
| 499 | (gnus-run-hooks 'gnus-tree-mode-hook)) | 499 | (gnus-run-mode-hooks 'gnus-tree-mode-hook)) |
| 500 | 500 | ||
| 501 | (defun gnus-tree-read-summary-keys (&optional arg) | 501 | (defun gnus-tree-read-summary-keys (&optional arg) |
| 502 | "Read a summary buffer key sequence and execute it." | 502 | "Read a summary buffer key sequence and execute it." |
| @@ -1009,7 +1009,7 @@ The following commands are available: | |||
| 1009 | (buffer-disable-undo) | 1009 | (buffer-disable-undo) |
| 1010 | (setq buffer-read-only t) | 1010 | (setq buffer-read-only t) |
| 1011 | (make-local-variable 'gnus-carpal-attached-buffer) | 1011 | (make-local-variable 'gnus-carpal-attached-buffer) |
| 1012 | (gnus-run-hooks 'gnus-carpal-mode-hook)) | 1012 | (gnus-run-mode-hooks 'gnus-carpal-mode-hook)) |
| 1013 | 1013 | ||
| 1014 | (defun gnus-carpal-setup-buffer (type) | 1014 | (defun gnus-carpal-setup-buffer (type) |
| 1015 | (let ((buffer (symbol-value (intern (format "gnus-carpal-%s-buffer" type))))) | 1015 | (let ((buffer (symbol-value (intern (format "gnus-carpal-%s-buffer" type))))) |
diff --git a/lisp/gnus/gnus-score.el b/lisp/gnus/gnus-score.el index 3a22f9030e5..a2c3b249343 100644 --- a/lisp/gnus/gnus-score.el +++ b/lisp/gnus/gnus-score.el | |||
| @@ -826,7 +826,7 @@ If optional argument `EXTRA' is non-nil, it's a non-standard overview header." | |||
| 826 | ;; If this is an integer comparison, we transform from string to int. | 826 | ;; If this is an integer comparison, we transform from string to int. |
| 827 | (if (eq (nth 2 (assoc header gnus-header-index)) 'gnus-score-integer) | 827 | (if (eq (nth 2 (assoc header gnus-header-index)) 'gnus-score-integer) |
| 828 | (if (stringp match) | 828 | (if (stringp match) |
| 829 | (setq match (string-to-int match))) | 829 | (setq match (string-to-number match))) |
| 830 | (set-text-properties 0 (length match) nil match)) | 830 | (set-text-properties 0 (length match) nil match)) |
| 831 | 831 | ||
| 832 | (unless (eq date 'now) | 832 | (unless (eq date 'now) |
| @@ -891,7 +891,7 @@ EXTRA is the possible non-standard header." | |||
| 891 | t) | 891 | t) |
| 892 | (read-string "Match: ") | 892 | (read-string "Match: ") |
| 893 | (if (y-or-n-p "Use regexp match? ") 'r 's) | 893 | (if (y-or-n-p "Use regexp match? ") 'r 's) |
| 894 | (string-to-int (read-string "Score: ")))) | 894 | (string-to-number (read-string "Score: ")))) |
| 895 | (save-excursion | 895 | (save-excursion |
| 896 | (unless (and (stringp match) (> (length match) 0)) | 896 | (unless (and (stringp match) (> (length match) 0)) |
| 897 | (error "No match")) | 897 | (error "No match")) |
| @@ -945,7 +945,7 @@ EXTRA is the possible non-standard header." | |||
| 945 | "Automatically mark articles with score below SCORE as read." | 945 | "Automatically mark articles with score below SCORE as read." |
| 946 | (interactive | 946 | (interactive |
| 947 | (list (or (and current-prefix-arg (prefix-numeric-value current-prefix-arg)) | 947 | (list (or (and current-prefix-arg (prefix-numeric-value current-prefix-arg)) |
| 948 | (string-to-int (read-string "Mark below: "))))) | 948 | (string-to-number (read-string "Mark below: "))))) |
| 949 | (setq score (or score gnus-summary-default-score 0)) | 949 | (setq score (or score gnus-summary-default-score 0)) |
| 950 | (gnus-score-set 'mark (list score)) | 950 | (gnus-score-set 'mark (list score)) |
| 951 | (gnus-score-set 'touched '(t)) | 951 | (gnus-score-set 'touched '(t)) |
| @@ -979,7 +979,7 @@ EXTRA is the possible non-standard header." | |||
| 979 | "Automatically expunge articles with score below SCORE." | 979 | "Automatically expunge articles with score below SCORE." |
| 980 | (interactive | 980 | (interactive |
| 981 | (list (or (and current-prefix-arg (prefix-numeric-value current-prefix-arg)) | 981 | (list (or (and current-prefix-arg (prefix-numeric-value current-prefix-arg)) |
| 982 | (string-to-int (read-string "Set expunge below: "))))) | 982 | (string-to-number (read-string "Set expunge below: "))))) |
| 983 | (setq score (or score gnus-summary-default-score 0)) | 983 | (setq score (or score gnus-summary-default-score 0)) |
| 984 | (gnus-score-set 'expunge (list score)) | 984 | (gnus-score-set 'expunge (list score)) |
| 985 | (gnus-score-set 'touched '(t))) | 985 | (gnus-score-set 'touched '(t))) |
diff --git a/lisp/gnus/gnus-soup.el b/lisp/gnus/gnus-soup.el index 55dc1635542..48a8fc0c380 100644 --- a/lisp/gnus/gnus-soup.el +++ b/lisp/gnus/gnus-soup.el | |||
| @@ -349,9 +349,9 @@ If NOT-ALL, don't pack ticked articles." | |||
| 349 | (packer (if (< (string-match "%s" packer) | 349 | (packer (if (< (string-match "%s" packer) |
| 350 | (string-match "%d" packer)) | 350 | (string-match "%d" packer)) |
| 351 | (format packer files | 351 | (format packer files |
| 352 | (string-to-int (gnus-soup-unique-prefix dir))) | 352 | (string-to-number (gnus-soup-unique-prefix dir))) |
| 353 | (format packer | 353 | (format packer |
| 354 | (string-to-int (gnus-soup-unique-prefix dir)) | 354 | (string-to-number (gnus-soup-unique-prefix dir)) |
| 355 | files))) | 355 | files))) |
| 356 | (dir (expand-file-name dir))) | 356 | (dir (expand-file-name dir))) |
| 357 | (gnus-make-directory dir) | 357 | (gnus-make-directory dir) |
| @@ -385,7 +385,7 @@ though the two last may be nil if they are missing." | |||
| 385 | (and (eq (preceding-char) ?\t) | 385 | (and (eq (preceding-char) ?\t) |
| 386 | (gnus-soup-field)) | 386 | (gnus-soup-field)) |
| 387 | (and (eq (preceding-char) ?\t) | 387 | (and (eq (preceding-char) ?\t) |
| 388 | (string-to-int (gnus-soup-field)))) | 388 | (string-to-number (gnus-soup-field)))) |
| 389 | areas) | 389 | areas) |
| 390 | (when (eq (preceding-char) ?\t) | 390 | (when (eq (preceding-char) ?\t) |
| 391 | (beginning-of-line 2))) | 391 | (beginning-of-line 2))) |
| @@ -535,7 +535,7 @@ Return whether the unpacking was successful." | |||
| 535 | (error "Bad header")) | 535 | (error "Bad header")) |
| 536 | (forward-line 1) | 536 | (forward-line 1) |
| 537 | (setq beg (point) | 537 | (setq beg (point) |
| 538 | end (+ (point) (string-to-int | 538 | end (+ (point) (string-to-number |
| 539 | (buffer-substring | 539 | (buffer-substring |
| 540 | (match-beginning 1) (match-end 1))))) | 540 | (match-beginning 1) (match-end 1))))) |
| 541 | (switch-to-buffer tmp-buf) | 541 | (switch-to-buffer tmp-buf) |
diff --git a/lisp/gnus/gnus-spec.el b/lisp/gnus/gnus-spec.el index ef1c43167f5..39b87727279 100644 --- a/lisp/gnus/gnus-spec.el +++ b/lisp/gnus/gnus-spec.el | |||
| @@ -509,7 +509,7 @@ are supported for %s." | |||
| 509 | (t | 509 | (t |
| 510 | (if (null args) | 510 | (if (null args) |
| 511 | (error 'wrong-number-of-arguments #'my-format n fstring)) | 511 | (error 'wrong-number-of-arguments #'my-format n fstring)) |
| 512 | (let* ((minlen (string-to-int (or (match-string 2) ""))) | 512 | (let* ((minlen (string-to-number (or (match-string 2) ""))) |
| 513 | (arg (car args)) | 513 | (arg (car args)) |
| 514 | (str (if (stringp arg) arg (format "%s" arg))) | 514 | (str (if (stringp arg) arg (format "%s" arg))) |
| 515 | (lpad (null (match-string 1))) | 515 | (lpad (null (match-string 1))) |
diff --git a/lisp/gnus/gnus-srvr.el b/lisp/gnus/gnus-srvr.el index 7b3c033fddb..1c2ba9447ff 100644 --- a/lisp/gnus/gnus-srvr.el +++ b/lisp/gnus/gnus-srvr.el | |||
| @@ -1,5 +1,6 @@ | |||
| 1 | ;;; gnus-srvr.el --- virtual server support for Gnus | 1 | ;;; gnus-srvr.el --- virtual server support for Gnus |
| 2 | ;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 | 2 | ;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, |
| 3 | ;; 2004, 2005 | ||
| 3 | ;; Free Software Foundation, Inc. | 4 | ;; Free Software Foundation, Inc. |
| 4 | 5 | ||
| 5 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> | 6 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> |
| @@ -269,7 +270,7 @@ The following commands are available: | |||
| 269 | (put 'gnus-server-mode 'font-lock-defaults '(gnus-server-font-lock-keywords t)) | 270 | (put 'gnus-server-mode 'font-lock-defaults '(gnus-server-font-lock-keywords t)) |
| 270 | (set (make-local-variable 'font-lock-defaults) | 271 | (set (make-local-variable 'font-lock-defaults) |
| 271 | '(gnus-server-font-lock-keywords t))) | 272 | '(gnus-server-font-lock-keywords t))) |
| 272 | (gnus-run-hooks 'gnus-server-mode-hook)) | 273 | (gnus-run-mode-hooks 'gnus-server-mode-hook)) |
| 273 | 274 | ||
| 274 | (defun gnus-server-insert-server-line (gnus-tmp-name method) | 275 | (defun gnus-server-insert-server-line (gnus-tmp-name method) |
| 275 | (let* ((gnus-tmp-how (car method)) | 276 | (let* ((gnus-tmp-how (car method)) |
| @@ -849,7 +850,7 @@ buffer. | |||
| 849 | (setq truncate-lines t) | 850 | (setq truncate-lines t) |
| 850 | (gnus-set-default-directory) | 851 | (gnus-set-default-directory) |
| 851 | (setq buffer-read-only t) | 852 | (setq buffer-read-only t) |
| 852 | (gnus-run-hooks 'gnus-browse-mode-hook)) | 853 | (gnus-run-mode-hooks 'gnus-browse-mode-hook)) |
| 853 | 854 | ||
| 854 | (defun gnus-browse-read-group (&optional no-article number) | 855 | (defun gnus-browse-read-group (&optional no-article number) |
| 855 | "Enter the group at the current line. | 856 | "Enter the group at the current line. |
diff --git a/lisp/gnus/gnus-start.el b/lisp/gnus/gnus-start.el index b125a19be77..7c85409fb31 100644 --- a/lisp/gnus/gnus-start.el +++ b/lisp/gnus/gnus-start.el | |||
| @@ -2518,7 +2518,7 @@ If FORCE is non-nil, the .newsrc file is read." | |||
| 2518 | (cond | 2518 | (cond |
| 2519 | ((looking-at "[0-9]+") | 2519 | ((looking-at "[0-9]+") |
| 2520 | ;; We narrow and read a number instead of buffer-substring/ | 2520 | ;; We narrow and read a number instead of buffer-substring/ |
| 2521 | ;; string-to-int because it's faster. narrow/widen is | 2521 | ;; string-to-number because it's faster. narrow/widen is |
| 2522 | ;; faster than save-restriction/narrow, and save-restriction | 2522 | ;; faster than save-restriction/narrow, and save-restriction |
| 2523 | ;; produces a garbage object. | 2523 | ;; produces a garbage object. |
| 2524 | (setq num1 (progn | 2524 | (setq num1 (progn |
diff --git a/lisp/gnus/gnus-sum.el b/lisp/gnus/gnus-sum.el index 17cb1ea2a6b..8d4c536229b 100644 --- a/lisp/gnus/gnus-sum.el +++ b/lisp/gnus/gnus-sum.el | |||
| @@ -2722,7 +2722,7 @@ The following commands are available: | |||
| 2722 | (make-local-variable 'gnus-summary-mark-positions) | 2722 | (make-local-variable 'gnus-summary-mark-positions) |
| 2723 | (gnus-make-local-hook 'pre-command-hook) | 2723 | (gnus-make-local-hook 'pre-command-hook) |
| 2724 | (add-hook 'pre-command-hook 'gnus-set-global-variables nil t) | 2724 | (add-hook 'pre-command-hook 'gnus-set-global-variables nil t) |
| 2725 | (gnus-run-hooks 'gnus-summary-mode-hook) | 2725 | (gnus-run-mode-hooks 'gnus-summary-mode-hook) |
| 2726 | (turn-on-gnus-mailing-list-mode) | 2726 | (turn-on-gnus-mailing-list-mode) |
| 2727 | (mm-enable-multibyte) | 2727 | (mm-enable-multibyte) |
| 2728 | (gnus-update-format-specifications nil 'summary 'summary-mode 'summary-dummy) | 2728 | (gnus-update-format-specifications nil 'summary 'summary-mode 'summary-dummy) |
| @@ -5660,7 +5660,7 @@ The resulting hash table is returned, or nil if no Xrefs were found." | |||
| 5660 | (match-end 1))) | 5660 | (match-end 1))) |
| 5661 | (substring xrefs (match-beginning 1) (match-end 1)))) | 5661 | (substring xrefs (match-beginning 1) (match-end 1)))) |
| 5662 | (setq number | 5662 | (setq number |
| 5663 | (string-to-int (substring xrefs (match-beginning 2) | 5663 | (string-to-number (substring xrefs (match-beginning 2) |
| 5664 | (match-end 2)))) | 5664 | (match-end 2)))) |
| 5665 | (if (setq entry (gnus-gethash group xref-hashtb)) | 5665 | (if (setq entry (gnus-gethash group xref-hashtb)) |
| 5666 | (setcdr entry (cons number (cdr entry))) | 5666 | (setcdr entry (cons number (cdr entry))) |
diff --git a/lisp/gnus/gnus-util.el b/lisp/gnus/gnus-util.el index 237e0507775..6171d42834e 100644 --- a/lisp/gnus/gnus-util.el +++ b/lisp/gnus/gnus-util.el | |||
| @@ -1015,6 +1015,13 @@ ARG is passed to the first function." | |||
| 1015 | (save-current-buffer | 1015 | (save-current-buffer |
| 1016 | (apply 'run-hooks funcs))) | 1016 | (apply 'run-hooks funcs))) |
| 1017 | 1017 | ||
| 1018 | (defun gnus-run-mode-hooks (&rest funcs) | ||
| 1019 | "Run `run-mode-hooks' if it is available, otherwise `run-hooks'. | ||
| 1020 | This function saves the current buffer." | ||
| 1021 | (if (fboundp 'run-mode-hooks) | ||
| 1022 | (save-current-buffer (apply 'run-mode-hooks funcs)) | ||
| 1023 | (save-current-buffer (apply 'run-hooks funcs)))) | ||
| 1024 | |||
| 1018 | ;;; Various | 1025 | ;;; Various |
| 1019 | 1026 | ||
| 1020 | (defvar gnus-group-buffer) ; Compiler directive | 1027 | (defvar gnus-group-buffer) ; Compiler directive |
| @@ -1564,6 +1571,11 @@ empty directories from OLD-PATH." | |||
| 1564 | (file-truename | 1571 | (file-truename |
| 1565 | (concat old-dir ".."))))))))) | 1572 | (concat old-dir ".."))))))))) |
| 1566 | 1573 | ||
| 1574 | (if (fboundp 'set-process-query-on-exit-flag) | ||
| 1575 | (defalias 'gnus-set-process-query-on-exit-flag | ||
| 1576 | 'set-process-query-on-exit-flag) | ||
| 1577 | (defalias 'gnus-set-process-query-on-exit-flag | ||
| 1578 | 'process-kill-without-query)) | ||
| 1567 | 1579 | ||
| 1568 | (provide 'gnus-util) | 1580 | (provide 'gnus-util) |
| 1569 | 1581 | ||
diff --git a/lisp/gnus/gnus-uu.el b/lisp/gnus/gnus-uu.el index 3b2a29c238e..a705f230241 100644 --- a/lisp/gnus/gnus-uu.el +++ b/lisp/gnus/gnus-uu.el | |||
| @@ -1185,7 +1185,7 @@ When called interactively, prompt for REGEXP." | |||
| 1185 | (ignore-errors | 1185 | (ignore-errors |
| 1186 | (replace-match | 1186 | (replace-match |
| 1187 | (format "%06d" | 1187 | (format "%06d" |
| 1188 | (string-to-int (buffer-substring | 1188 | (string-to-number (buffer-substring |
| 1189 | (match-beginning 0) (match-end 0))))))) | 1189 | (match-beginning 0) (match-end 0))))))) |
| 1190 | (setq string (buffer-substring 1 (point-max))) | 1190 | (setq string (buffer-substring 1 (point-max))) |
| 1191 | (setcar (car string-list) string) | 1191 | (setcar (car string-list) string) |
diff --git a/lisp/gnus/gnus.el b/lisp/gnus/gnus.el index 98c41de45e5..a134ac661ac 100644 --- a/lisp/gnus/gnus.el +++ b/lisp/gnus/gnus.el | |||
| @@ -366,7 +366,8 @@ be set in `.emacs' instead." | |||
| 366 | (:foreground "ForestGreen" :bold t)) | 366 | (:foreground "ForestGreen" :bold t)) |
| 367 | (t | 367 | (t |
| 368 | ())) | 368 | ())) |
| 369 | "Level 1 newsgroup face.") | 369 | "Level 1 newsgroup face." |
| 370 | :group 'gnus-group) | ||
| 370 | 371 | ||
| 371 | (defface gnus-group-news-1-empty-face | 372 | (defface gnus-group-news-1-empty-face |
| 372 | '((((class color) | 373 | '((((class color) |
| @@ -377,7 +378,8 @@ be set in `.emacs' instead." | |||
| 377 | (:foreground "ForestGreen")) | 378 | (:foreground "ForestGreen")) |
| 378 | (t | 379 | (t |
| 379 | ())) | 380 | ())) |
| 380 | "Level 1 empty newsgroup face.") | 381 | "Level 1 empty newsgroup face." |
| 382 | :group 'gnus-group) | ||
| 381 | 383 | ||
| 382 | (defface gnus-group-news-2-face | 384 | (defface gnus-group-news-2-face |
| 383 | '((((class color) | 385 | '((((class color) |
| @@ -388,7 +390,8 @@ be set in `.emacs' instead." | |||
| 388 | (:foreground "CadetBlue4" :bold t)) | 390 | (:foreground "CadetBlue4" :bold t)) |
| 389 | (t | 391 | (t |
| 390 | ())) | 392 | ())) |
| 391 | "Level 2 newsgroup face.") | 393 | "Level 2 newsgroup face." |
| 394 | :group 'gnus-group) | ||
| 392 | 395 | ||
| 393 | (defface gnus-group-news-2-empty-face | 396 | (defface gnus-group-news-2-empty-face |
| 394 | '((((class color) | 397 | '((((class color) |
| @@ -399,7 +402,8 @@ be set in `.emacs' instead." | |||
| 399 | (:foreground "CadetBlue4")) | 402 | (:foreground "CadetBlue4")) |
| 400 | (t | 403 | (t |
| 401 | ())) | 404 | ())) |
| 402 | "Level 2 empty newsgroup face.") | 405 | "Level 2 empty newsgroup face." |
| 406 | :group 'gnus-group) | ||
| 403 | 407 | ||
| 404 | (defface gnus-group-news-3-face | 408 | (defface gnus-group-news-3-face |
| 405 | '((((class color) | 409 | '((((class color) |
| @@ -410,7 +414,8 @@ be set in `.emacs' instead." | |||
| 410 | (:bold t)) | 414 | (:bold t)) |
| 411 | (t | 415 | (t |
| 412 | ())) | 416 | ())) |
| 413 | "Level 3 newsgroup face.") | 417 | "Level 3 newsgroup face." |
| 418 | :group 'gnus-group) | ||
| 414 | 419 | ||
| 415 | (defface gnus-group-news-3-empty-face | 420 | (defface gnus-group-news-3-empty-face |
| 416 | '((((class color) | 421 | '((((class color) |
| @@ -421,7 +426,8 @@ be set in `.emacs' instead." | |||
| 421 | ()) | 426 | ()) |
| 422 | (t | 427 | (t |
| 423 | ())) | 428 | ())) |
| 424 | "Level 3 empty newsgroup face.") | 429 | "Level 3 empty newsgroup face." |
| 430 | :group 'gnus-group) | ||
| 425 | 431 | ||
| 426 | (defface gnus-group-news-4-face | 432 | (defface gnus-group-news-4-face |
| 427 | '((((class color) | 433 | '((((class color) |
| @@ -432,7 +438,8 @@ be set in `.emacs' instead." | |||
| 432 | (:bold t)) | 438 | (:bold t)) |
| 433 | (t | 439 | (t |
| 434 | ())) | 440 | ())) |
| 435 | "Level 4 newsgroup face.") | 441 | "Level 4 newsgroup face." |
| 442 | :group 'gnus-group) | ||
| 436 | 443 | ||
| 437 | (defface gnus-group-news-4-empty-face | 444 | (defface gnus-group-news-4-empty-face |
| 438 | '((((class color) | 445 | '((((class color) |
| @@ -443,7 +450,8 @@ be set in `.emacs' instead." | |||
| 443 | ()) | 450 | ()) |
| 444 | (t | 451 | (t |
| 445 | ())) | 452 | ())) |
| 446 | "Level 4 empty newsgroup face.") | 453 | "Level 4 empty newsgroup face." |
| 454 | :group 'gnus-group) | ||
| 447 | 455 | ||
| 448 | (defface gnus-group-news-5-face | 456 | (defface gnus-group-news-5-face |
| 449 | '((((class color) | 457 | '((((class color) |
| @@ -454,7 +462,8 @@ be set in `.emacs' instead." | |||
| 454 | (:bold t)) | 462 | (:bold t)) |
| 455 | (t | 463 | (t |
| 456 | ())) | 464 | ())) |
| 457 | "Level 5 newsgroup face.") | 465 | "Level 5 newsgroup face." |
| 466 | :group 'gnus-group) | ||
| 458 | 467 | ||
| 459 | (defface gnus-group-news-5-empty-face | 468 | (defface gnus-group-news-5-empty-face |
| 460 | '((((class color) | 469 | '((((class color) |
| @@ -465,7 +474,8 @@ be set in `.emacs' instead." | |||
| 465 | ()) | 474 | ()) |
| 466 | (t | 475 | (t |
| 467 | ())) | 476 | ())) |
| 468 | "Level 5 empty newsgroup face.") | 477 | "Level 5 empty newsgroup face." |
| 478 | :group 'gnus-group) | ||
| 469 | 479 | ||
| 470 | (defface gnus-group-news-6-face | 480 | (defface gnus-group-news-6-face |
| 471 | '((((class color) | 481 | '((((class color) |
| @@ -476,7 +486,8 @@ be set in `.emacs' instead." | |||
| 476 | (:bold t)) | 486 | (:bold t)) |
| 477 | (t | 487 | (t |
| 478 | ())) | 488 | ())) |
| 479 | "Level 6 newsgroup face.") | 489 | "Level 6 newsgroup face." |
| 490 | :group 'gnus-group) | ||
| 480 | 491 | ||
| 481 | (defface gnus-group-news-6-empty-face | 492 | (defface gnus-group-news-6-empty-face |
| 482 | '((((class color) | 493 | '((((class color) |
| @@ -487,7 +498,8 @@ be set in `.emacs' instead." | |||
| 487 | ()) | 498 | ()) |
| 488 | (t | 499 | (t |
| 489 | ())) | 500 | ())) |
| 490 | "Level 6 empty newsgroup face.") | 501 | "Level 6 empty newsgroup face." |
| 502 | :group 'gnus-group) | ||
| 491 | 503 | ||
| 492 | (defface gnus-group-news-low-face | 504 | (defface gnus-group-news-low-face |
| 493 | '((((class color) | 505 | '((((class color) |
| @@ -498,7 +510,8 @@ be set in `.emacs' instead." | |||
| 498 | (:foreground "DarkGreen" :bold t)) | 510 | (:foreground "DarkGreen" :bold t)) |
| 499 | (t | 511 | (t |
| 500 | ())) | 512 | ())) |
| 501 | "Low level newsgroup face.") | 513 | "Low level newsgroup face." |
| 514 | :group 'gnus-group) | ||
| 502 | 515 | ||
| 503 | (defface gnus-group-news-low-empty-face | 516 | (defface gnus-group-news-low-empty-face |
| 504 | '((((class color) | 517 | '((((class color) |
| @@ -509,7 +522,8 @@ be set in `.emacs' instead." | |||
| 509 | (:foreground "DarkGreen")) | 522 | (:foreground "DarkGreen")) |
| 510 | (t | 523 | (t |
| 511 | ())) | 524 | ())) |
| 512 | "Low level empty newsgroup face.") | 525 | "Low level empty newsgroup face." |
| 526 | :group 'gnus-group) | ||
| 513 | 527 | ||
| 514 | (defface gnus-group-mail-1-face | 528 | (defface gnus-group-mail-1-face |
| 515 | '((((class color) | 529 | '((((class color) |
| @@ -520,7 +534,8 @@ be set in `.emacs' instead." | |||
| 520 | (:foreground "DeepPink3" :bold t)) | 534 | (:foreground "DeepPink3" :bold t)) |
| 521 | (t | 535 | (t |
| 522 | (:bold t))) | 536 | (:bold t))) |
| 523 | "Level 1 mailgroup face.") | 537 | "Level 1 mailgroup face." |
| 538 | :group 'gnus-group) | ||
| 524 | 539 | ||
| 525 | (defface gnus-group-mail-1-empty-face | 540 | (defface gnus-group-mail-1-empty-face |
| 526 | '((((class color) | 541 | '((((class color) |
| @@ -531,7 +546,8 @@ be set in `.emacs' instead." | |||
| 531 | (:foreground "DeepPink3")) | 546 | (:foreground "DeepPink3")) |
| 532 | (t | 547 | (t |
| 533 | (:italic t :bold t))) | 548 | (:italic t :bold t))) |
| 534 | "Level 1 empty mailgroup face.") | 549 | "Level 1 empty mailgroup face." |
| 550 | :group 'gnus-group) | ||
| 535 | 551 | ||
| 536 | (defface gnus-group-mail-2-face | 552 | (defface gnus-group-mail-2-face |
| 537 | '((((class color) | 553 | '((((class color) |
| @@ -542,7 +558,8 @@ be set in `.emacs' instead." | |||
| 542 | (:foreground "HotPink3" :bold t)) | 558 | (:foreground "HotPink3" :bold t)) |
| 543 | (t | 559 | (t |
| 544 | (:bold t))) | 560 | (:bold t))) |
| 545 | "Level 2 mailgroup face.") | 561 | "Level 2 mailgroup face." |
| 562 | :group 'gnus-group) | ||
| 546 | 563 | ||
| 547 | (defface gnus-group-mail-2-empty-face | 564 | (defface gnus-group-mail-2-empty-face |
| 548 | '((((class color) | 565 | '((((class color) |
| @@ -553,7 +570,8 @@ be set in `.emacs' instead." | |||
| 553 | (:foreground "HotPink3")) | 570 | (:foreground "HotPink3")) |
| 554 | (t | 571 | (t |
| 555 | (:bold t))) | 572 | (:bold t))) |
| 556 | "Level 2 empty mailgroup face.") | 573 | "Level 2 empty mailgroup face." |
| 574 | :group 'gnus-group) | ||
| 557 | 575 | ||
| 558 | (defface gnus-group-mail-3-face | 576 | (defface gnus-group-mail-3-face |
| 559 | '((((class color) | 577 | '((((class color) |
| @@ -564,7 +582,8 @@ be set in `.emacs' instead." | |||
| 564 | (:foreground "magenta4" :bold t)) | 582 | (:foreground "magenta4" :bold t)) |
| 565 | (t | 583 | (t |
| 566 | (:bold t))) | 584 | (:bold t))) |
| 567 | "Level 3 mailgroup face.") | 585 | "Level 3 mailgroup face." |
| 586 | :group 'gnus-group) | ||
| 568 | 587 | ||
| 569 | (defface gnus-group-mail-3-empty-face | 588 | (defface gnus-group-mail-3-empty-face |
| 570 | '((((class color) | 589 | '((((class color) |
| @@ -575,7 +594,8 @@ be set in `.emacs' instead." | |||
| 575 | (:foreground "magenta4")) | 594 | (:foreground "magenta4")) |
| 576 | (t | 595 | (t |
| 577 | ())) | 596 | ())) |
| 578 | "Level 3 empty mailgroup face.") | 597 | "Level 3 empty mailgroup face." |
| 598 | :group 'gnus-group) | ||
| 579 | 599 | ||
| 580 | (defface gnus-group-mail-low-face | 600 | (defface gnus-group-mail-low-face |
| 581 | '((((class color) | 601 | '((((class color) |
| @@ -586,7 +606,8 @@ be set in `.emacs' instead." | |||
| 586 | (:foreground "DeepPink4" :bold t)) | 606 | (:foreground "DeepPink4" :bold t)) |
| 587 | (t | 607 | (t |
| 588 | (:bold t))) | 608 | (:bold t))) |
| 589 | "Low level mailgroup face.") | 609 | "Low level mailgroup face." |
| 610 | :group 'gnus-group) | ||
| 590 | 611 | ||
| 591 | (defface gnus-group-mail-low-empty-face | 612 | (defface gnus-group-mail-low-empty-face |
| 592 | '((((class color) | 613 | '((((class color) |
| @@ -597,18 +618,21 @@ be set in `.emacs' instead." | |||
| 597 | (:foreground "DeepPink4")) | 618 | (:foreground "DeepPink4")) |
| 598 | (t | 619 | (t |
| 599 | (:bold t))) | 620 | (:bold t))) |
| 600 | "Low level empty mailgroup face.") | 621 | "Low level empty mailgroup face." |
| 622 | :group 'gnus-group) | ||
| 601 | 623 | ||
| 602 | ;; Summary mode faces. | 624 | ;; Summary mode faces. |
| 603 | 625 | ||
| 604 | (defface gnus-summary-selected-face '((t | 626 | (defface gnus-summary-selected-face '((t |
| 605 | (:underline t))) | 627 | (:underline t))) |
| 606 | "Face used for selected articles.") | 628 | "Face used for selected articles." |
| 629 | :group 'gnus-summary) | ||
| 607 | 630 | ||
| 608 | (defface gnus-summary-cancelled-face | 631 | (defface gnus-summary-cancelled-face |
| 609 | '((((class color)) | 632 | '((((class color)) |
| 610 | (:foreground "yellow" :background "black"))) | 633 | (:foreground "yellow" :background "black"))) |
| 611 | "Face used for cancelled articles.") | 634 | "Face used for cancelled articles." |
| 635 | :group 'gnus-summary) | ||
| 612 | 636 | ||
| 613 | (defface gnus-summary-high-ticked-face | 637 | (defface gnus-summary-high-ticked-face |
| 614 | '((((class color) | 638 | '((((class color) |
| @@ -619,7 +643,8 @@ be set in `.emacs' instead." | |||
| 619 | (:foreground "firebrick" :bold t)) | 643 | (:foreground "firebrick" :bold t)) |
| 620 | (t | 644 | (t |
| 621 | (:bold t))) | 645 | (:bold t))) |
| 622 | "Face used for high interest ticked articles.") | 646 | "Face used for high interest ticked articles." |
| 647 | :group 'gnus-summary) | ||
| 623 | 648 | ||
| 624 | (defface gnus-summary-low-ticked-face | 649 | (defface gnus-summary-low-ticked-face |
| 625 | '((((class color) | 650 | '((((class color) |
| @@ -630,7 +655,8 @@ be set in `.emacs' instead." | |||
| 630 | (:foreground "firebrick" :italic t)) | 655 | (:foreground "firebrick" :italic t)) |
| 631 | (t | 656 | (t |
| 632 | (:italic t))) | 657 | (:italic t))) |
| 633 | "Face used for low interest ticked articles.") | 658 | "Face used for low interest ticked articles." |
| 659 | :group 'gnus-summary) | ||
| 634 | 660 | ||
| 635 | (defface gnus-summary-normal-ticked-face | 661 | (defface gnus-summary-normal-ticked-face |
| 636 | '((((class color) | 662 | '((((class color) |
| @@ -641,7 +667,8 @@ be set in `.emacs' instead." | |||
| 641 | (:foreground "firebrick")) | 667 | (:foreground "firebrick")) |
| 642 | (t | 668 | (t |
| 643 | ())) | 669 | ())) |
| 644 | "Face used for normal interest ticked articles.") | 670 | "Face used for normal interest ticked articles." |
| 671 | :group 'gnus-summary) | ||
| 645 | 672 | ||
| 646 | (defface gnus-summary-high-ancient-face | 673 | (defface gnus-summary-high-ancient-face |
| 647 | '((((class color) | 674 | '((((class color) |
| @@ -652,7 +679,8 @@ be set in `.emacs' instead." | |||
| 652 | (:foreground "RoyalBlue" :bold t)) | 679 | (:foreground "RoyalBlue" :bold t)) |
| 653 | (t | 680 | (t |
| 654 | (:bold t))) | 681 | (:bold t))) |
| 655 | "Face used for high interest ancient articles.") | 682 | "Face used for high interest ancient articles." |
| 683 | :group 'gnus-summary) | ||
| 656 | 684 | ||
| 657 | (defface gnus-summary-low-ancient-face | 685 | (defface gnus-summary-low-ancient-face |
| 658 | '((((class color) | 686 | '((((class color) |
| @@ -663,7 +691,8 @@ be set in `.emacs' instead." | |||
| 663 | (:foreground "RoyalBlue" :italic t)) | 691 | (:foreground "RoyalBlue" :italic t)) |
| 664 | (t | 692 | (t |
| 665 | (:italic t))) | 693 | (:italic t))) |
| 666 | "Face used for low interest ancient articles.") | 694 | "Face used for low interest ancient articles." |
| 695 | :group 'gnus-summary) | ||
| 667 | 696 | ||
| 668 | (defface gnus-summary-normal-ancient-face | 697 | (defface gnus-summary-normal-ancient-face |
| 669 | '((((class color) | 698 | '((((class color) |
| @@ -674,7 +703,8 @@ be set in `.emacs' instead." | |||
| 674 | (:foreground "RoyalBlue")) | 703 | (:foreground "RoyalBlue")) |
| 675 | (t | 704 | (t |
| 676 | ())) | 705 | ())) |
| 677 | "Face used for normal interest ancient articles.") | 706 | "Face used for normal interest ancient articles." |
| 707 | :group 'gnus-summary) | ||
| 678 | 708 | ||
| 679 | (defface gnus-summary-high-undownloaded-face | 709 | (defface gnus-summary-high-undownloaded-face |
| 680 | '((((class color) | 710 | '((((class color) |
| @@ -683,7 +713,8 @@ be set in `.emacs' instead." | |||
| 683 | (((class color) (background dark)) | 713 | (((class color) (background dark)) |
| 684 | (:bold t :foreground "LightGray")) | 714 | (:bold t :foreground "LightGray")) |
| 685 | (t (:inverse-video t :bold t))) | 715 | (t (:inverse-video t :bold t))) |
| 686 | "Face used for high interest uncached articles.") | 716 | "Face used for high interest uncached articles." |
| 717 | :group 'gnus-summary) | ||
| 687 | 718 | ||
| 688 | (defface gnus-summary-low-undownloaded-face | 719 | (defface gnus-summary-low-undownloaded-face |
| 689 | '((((class color) | 720 | '((((class color) |
| @@ -692,7 +723,8 @@ be set in `.emacs' instead." | |||
| 692 | (((class color) (background dark)) | 723 | (((class color) (background dark)) |
| 693 | (:italic t :foreground "LightGray" :bold nil)) | 724 | (:italic t :foreground "LightGray" :bold nil)) |
| 694 | (t (:inverse-video t :italic t))) | 725 | (t (:inverse-video t :italic t))) |
| 695 | "Face used for low interest uncached articles.") | 726 | "Face used for low interest uncached articles." |
| 727 | :group 'gnus-summary) | ||
| 696 | 728 | ||
| 697 | (defface gnus-summary-normal-undownloaded-face | 729 | (defface gnus-summary-normal-undownloaded-face |
| 698 | '((((class color) | 730 | '((((class color) |
| @@ -701,22 +733,26 @@ be set in `.emacs' instead." | |||
| 701 | (((class color) (background dark)) | 733 | (((class color) (background dark)) |
| 702 | (:foreground "LightGray" :bold nil)) | 734 | (:foreground "LightGray" :bold nil)) |
| 703 | (t (:inverse-video t))) | 735 | (t (:inverse-video t))) |
| 704 | "Face used for normal interest uncached articles.") | 736 | "Face used for normal interest uncached articles." |
| 737 | :group 'gnus-summary) | ||
| 705 | 738 | ||
| 706 | (defface gnus-summary-high-unread-face | 739 | (defface gnus-summary-high-unread-face |
| 707 | '((t | 740 | '((t |
| 708 | (:bold t))) | 741 | (:bold t))) |
| 709 | "Face used for high interest unread articles.") | 742 | "Face used for high interest unread articles." |
| 743 | :group 'gnus-summary) | ||
| 710 | 744 | ||
| 711 | (defface gnus-summary-low-unread-face | 745 | (defface gnus-summary-low-unread-face |
| 712 | '((t | 746 | '((t |
| 713 | (:italic t))) | 747 | (:italic t))) |
| 714 | "Face used for low interest unread articles.") | 748 | "Face used for low interest unread articles." |
| 749 | :group 'gnus-summary) | ||
| 715 | 750 | ||
| 716 | (defface gnus-summary-normal-unread-face | 751 | (defface gnus-summary-normal-unread-face |
| 717 | '((t | 752 | '((t |
| 718 | ())) | 753 | ())) |
| 719 | "Face used for normal interest unread articles.") | 754 | "Face used for normal interest unread articles." |
| 755 | :group 'gnus-summary) | ||
| 720 | 756 | ||
| 721 | (defface gnus-summary-high-read-face | 757 | (defface gnus-summary-high-read-face |
| 722 | '((((class color) | 758 | '((((class color) |
| @@ -729,7 +765,8 @@ be set in `.emacs' instead." | |||
| 729 | :bold t)) | 765 | :bold t)) |
| 730 | (t | 766 | (t |
| 731 | (:bold t))) | 767 | (:bold t))) |
| 732 | "Face used for high interest read articles.") | 768 | "Face used for high interest read articles." |
| 769 | :group 'gnus-summary) | ||
| 733 | 770 | ||
| 734 | (defface gnus-summary-low-read-face | 771 | (defface gnus-summary-low-read-face |
| 735 | '((((class color) | 772 | '((((class color) |
| @@ -742,7 +779,8 @@ be set in `.emacs' instead." | |||
| 742 | :italic t)) | 779 | :italic t)) |
| 743 | (t | 780 | (t |
| 744 | (:italic t))) | 781 | (:italic t))) |
| 745 | "Face used for low interest read articles.") | 782 | "Face used for low interest read articles." |
| 783 | :group 'gnus-summary) | ||
| 746 | 784 | ||
| 747 | (defface gnus-summary-normal-read-face | 785 | (defface gnus-summary-normal-read-face |
| 748 | '((((class color) | 786 | '((((class color) |
| @@ -753,7 +791,8 @@ be set in `.emacs' instead." | |||
| 753 | (:foreground "DarkGreen")) | 791 | (:foreground "DarkGreen")) |
| 754 | (t | 792 | (t |
| 755 | ())) | 793 | ())) |
| 756 | "Face used for normal interest read articles.") | 794 | "Face used for normal interest read articles." |
| 795 | :group 'gnus-summary) | ||
| 757 | 796 | ||
| 758 | 797 | ||
| 759 | ;;; | 798 | ;;; |
| @@ -806,7 +845,8 @@ be set in `.emacs' instead." | |||
| 806 | (:foreground "#888888")) | 845 | (:foreground "#888888")) |
| 807 | (t | 846 | (t |
| 808 | ())) | 847 | ())) |
| 809 | "Face for the splash screen.") | 848 | "Face for the splash screen." |
| 849 | :group 'gnus) | ||
| 810 | 850 | ||
| 811 | (defun gnus-splash () | 851 | (defun gnus-splash () |
| 812 | (save-excursion | 852 | (save-excursion |
diff --git a/lisp/gnus/html2text.el b/lisp/gnus/html2text.el index ef05af9bae6..81d8f5d8cc3 100644 --- a/lisp/gnus/html2text.el +++ b/lisp/gnus/html2text.el | |||
| @@ -1,5 +1,5 @@ | |||
| 1 | ;;; html2text.el --- a simple html to plain text converter | 1 | ;;; html2text.el --- a simple html to plain text converter |
| 2 | ;; Copyright (C) 2002, 2003, 2004 Free Software Foundation, Inc. | 2 | ;; Copyright (C) 2002, 2003, 2004, 2005 Free Software Foundation, Inc. |
| 3 | 3 | ||
| 4 | ;; Author: Joakim Hove <hove@phys.ntnu.no> | 4 | ;; Author: Joakim Hove <hove@phys.ntnu.no> |
| 5 | 5 | ||
| @@ -374,7 +374,8 @@ formatting, and then moved afterward.") | |||
| 374 | fashion, quite close to pure guess-work. It does work in some cases though." | 374 | fashion, quite close to pure guess-work. It does work in some cases though." |
| 375 | (interactive) | 375 | (interactive) |
| 376 | (goto-char (point-min)) | 376 | (goto-char (point-min)) |
| 377 | (replace-regexp "^<br>$" "") | 377 | (while (re-search-forward "^<br>$" nil t) |
| 378 | (delete-region (match-beginning 0) (match-end 0))) | ||
| 378 | ;; Removing lonely <br> on a single line, if they are left intact we | 379 | ;; Removing lonely <br> on a single line, if they are left intact we |
| 379 | ;; dont have any paragraphs at all. | 380 | ;; dont have any paragraphs at all. |
| 380 | (goto-char (point-min)) | 381 | (goto-char (point-min)) |
diff --git a/lisp/gnus/imap.el b/lisp/gnus/imap.el index c7f9d60339f..48d7c0f6eb6 100644 --- a/lisp/gnus/imap.el +++ b/lisp/gnus/imap.el | |||
| @@ -640,7 +640,11 @@ sure of changing the value of `foo'." | |||
| 640 | (let* ((port (or port imap-default-ssl-port)) | 640 | (let* ((port (or port imap-default-ssl-port)) |
| 641 | (coding-system-for-read imap-coding-system-for-read) | 641 | (coding-system-for-read imap-coding-system-for-read) |
| 642 | (coding-system-for-write imap-coding-system-for-write) | 642 | (coding-system-for-write imap-coding-system-for-write) |
| 643 | (process-connection-type nil) | 643 | (process-connection-type imap-process-connection-type) |
| 644 | (set-process-query-on-exit-flag | ||
| 645 | (if (fboundp 'set-process-query-on-exit-flag) | ||
| 646 | 'set-process-query-on-exit-flag | ||
| 647 | 'process-kill-without-query)) | ||
| 644 | process) | 648 | process) |
| 645 | (when (progn | 649 | (when (progn |
| 646 | (setq process (start-process | 650 | (setq process (start-process |
| @@ -650,7 +654,7 @@ sure of changing the value of `foo'." | |||
| 650 | (format-spec-make | 654 | (format-spec-make |
| 651 | ?s server | 655 | ?s server |
| 652 | ?p (number-to-string port))))) | 656 | ?p (number-to-string port))))) |
| 653 | (process-kill-without-query process) | 657 | (funcall set-process-query-on-exit-flag process nil) |
| 654 | process) | 658 | process) |
| 655 | (with-current-buffer buffer | 659 | (with-current-buffer buffer |
| 656 | (goto-char (point-min)) | 660 | (goto-char (point-min)) |
diff --git a/lisp/gnus/message.el b/lisp/gnus/message.el index b743417f4f2..f178576da4e 100644 --- a/lisp/gnus/message.el +++ b/lisp/gnus/message.el | |||
| @@ -842,7 +842,8 @@ the signature is inserted." | |||
| 842 | (set-keymap-parent map minibuffer-local-map) | 842 | (set-keymap-parent map minibuffer-local-map) |
| 843 | map) | 843 | map) |
| 844 | "Keymap for `message-read-from-minibuffer'." | 844 | "Keymap for `message-read-from-minibuffer'." |
| 845 | :version "22.1") | 845 | :version "22.1" |
| 846 | :group 'message-various) | ||
| 846 | 847 | ||
| 847 | ;;;###autoload | 848 | ;;;###autoload |
| 848 | (defcustom message-citation-line-function 'message-insert-citation-line | 849 | (defcustom message-citation-line-function 'message-insert-citation-line |
diff --git a/lisp/gnus/mm-util.el b/lisp/gnus/mm-util.el index 7cb3201f76f..c2e95b5de66 100644 --- a/lisp/gnus/mm-util.el +++ b/lisp/gnus/mm-util.el | |||
| @@ -831,22 +831,28 @@ to advanced Emacs features, such as file-name-handlers, format decoding, | |||
| 831 | `find-file-hooks', etc. | 831 | `find-file-hooks', etc. |
| 832 | If INHIBIT is non-nil, inhibit `mm-inhibit-file-name-handlers'. | 832 | If INHIBIT is non-nil, inhibit `mm-inhibit-file-name-handlers'. |
| 833 | This function ensures that none of these modifications will take place." | 833 | This function ensures that none of these modifications will take place." |
| 834 | (let ((format-alist nil) | 834 | (let* ((format-alist nil) |
| 835 | (auto-mode-alist (if inhibit nil (mm-auto-mode-alist))) | 835 | (auto-mode-alist (if inhibit nil (mm-auto-mode-alist))) |
| 836 | (default-major-mode 'fundamental-mode) | 836 | (default-major-mode 'fundamental-mode) |
| 837 | (enable-local-variables nil) | 837 | (enable-local-variables nil) |
| 838 | (after-insert-file-functions nil) | 838 | (after-insert-file-functions nil) |
| 839 | (enable-local-eval nil) | 839 | (enable-local-eval nil) |
| 840 | (find-file-hooks nil) | 840 | (inhibit-file-name-operation (if inhibit |
| 841 | (inhibit-file-name-operation (if inhibit | 841 | 'insert-file-contents |
| 842 | 'insert-file-contents | 842 | inhibit-file-name-operation)) |
| 843 | inhibit-file-name-operation)) | 843 | (inhibit-file-name-handlers |
| 844 | (inhibit-file-name-handlers | 844 | (if inhibit |
| 845 | (if inhibit | 845 | (append mm-inhibit-file-name-handlers |
| 846 | (append mm-inhibit-file-name-handlers | 846 | inhibit-file-name-handlers) |
| 847 | inhibit-file-name-handlers) | 847 | inhibit-file-name-handlers)) |
| 848 | inhibit-file-name-handlers))) | 848 | (ffh (if (boundp 'find-file-hook) |
| 849 | (insert-file-contents filename visit beg end replace))) | 849 | 'find-file-hook |
| 850 | 'find-file-hooks)) | ||
| 851 | (val (symbol-value ffh))) | ||
| 852 | (set ffh nil) | ||
| 853 | (unwind-protect | ||
| 854 | (insert-file-contents filename visit beg end replace) | ||
| 855 | (set ffh val)))) | ||
| 850 | 856 | ||
| 851 | (defun mm-append-to-file (start end filename &optional codesys inhibit) | 857 | (defun mm-append-to-file (start end filename &optional codesys inhibit) |
| 852 | "Append the contents of the region to the end of file FILENAME. | 858 | "Append the contents of the region to the end of file FILENAME. |
diff --git a/lisp/gnus/mml1991.el b/lisp/gnus/mml1991.el index 14d52e45ce4..640348c1387 100644 --- a/lisp/gnus/mml1991.el +++ b/lisp/gnus/mml1991.el | |||
| @@ -1,5 +1,6 @@ | |||
| 1 | ;;; mml1991.el --- Old PGP message format (RFC 1991) support for MML | 1 | ;;; mml1991.el --- Old PGP message format (RFC 1991) support for MML |
| 2 | ;; Copyright (C) 1998, 1999, 2000, 2001, 2003 Free Software Foundation, Inc. | 2 | ;; Copyright (C) 1998, 1999, 2000, 2001, 2003, 2005 |
| 3 | ;; Free Software Foundation, Inc. | ||
| 3 | 4 | ||
| 4 | ;; Author: Sascha Lüdecke <sascha@meta-x.de>, | 5 | ;; Author: Sascha Lüdecke <sascha@meta-x.de>, |
| 5 | ;; Simon Josefsson <simon@josefsson.org> (Mailcrypt interface, Gnus glue) | 6 | ;; Simon Josefsson <simon@josefsson.org> (Mailcrypt interface, Gnus glue) |
| @@ -219,8 +220,10 @@ | |||
| 219 | 220 | ||
| 220 | ;; pgg wrapper | 221 | ;; pgg wrapper |
| 221 | 222 | ||
| 222 | (defvar pgg-output-buffer) | 223 | (eval-when-compile |
| 223 | (defvar pgg-errors-buffer) | 224 | (defvar pgg-default-user-id) |
| 225 | (defvar pgg-errors-buffer) | ||
| 226 | (defvar pgg-output-buffer)) | ||
| 224 | 227 | ||
| 225 | (defun mml1991-pgg-sign (cont) | 228 | (defun mml1991-pgg-sign (cont) |
| 226 | (let (headers cte) | 229 | (let (headers cte) |
diff --git a/lisp/gnus/mml2015.el b/lisp/gnus/mml2015.el index a0e47dd2f2c..5f53d87bfef 100644 --- a/lisp/gnus/mml2015.el +++ b/lisp/gnus/mml2015.el | |||
| @@ -1,5 +1,6 @@ | |||
| 1 | ;;; mml2015.el --- MIME Security with Pretty Good Privacy (PGP) | 1 | ;;; mml2015.el --- MIME Security with Pretty Good Privacy (PGP) |
| 2 | ;; Copyright (C) 2000, 2001, 2002, 2003 Free Software Foundation, Inc. | 2 | ;; Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005 |
| 3 | ;; Free Software Foundation, Inc. | ||
| 3 | 4 | ||
| 4 | ;; Author: Shenghuo Zhu <zsh@cs.rochester.edu> | 5 | ;; Author: Shenghuo Zhu <zsh@cs.rochester.edu> |
| 5 | ;; Keywords: PGP MIME MML | 6 | ;; Keywords: PGP MIME MML |
| @@ -632,6 +633,7 @@ | |||
| 632 | ;;; pgg wrapper | 633 | ;;; pgg wrapper |
| 633 | 634 | ||
| 634 | (eval-when-compile | 635 | (eval-when-compile |
| 636 | (defvar pgg-default-user-id) | ||
| 635 | (defvar pgg-errors-buffer) | 637 | (defvar pgg-errors-buffer) |
| 636 | (defvar pgg-output-buffer)) | 638 | (defvar pgg-output-buffer)) |
| 637 | 639 | ||
diff --git a/lisp/gnus/nnbabyl.el b/lisp/gnus/nnbabyl.el index e69b6a0304a..dae51fca50b 100644 --- a/lisp/gnus/nnbabyl.el +++ b/lisp/gnus/nnbabyl.el | |||
| @@ -493,7 +493,7 @@ | |||
| 493 | (when (re-search-forward "^X-Gnus-Newsgroup: +\\([^:]+\\):\\([0-9]+\\) " | 493 | (when (re-search-forward "^X-Gnus-Newsgroup: +\\([^:]+\\):\\([0-9]+\\) " |
| 494 | nil t) | 494 | nil t) |
| 495 | (cons (buffer-substring (match-beginning 1) (match-end 1)) | 495 | (cons (buffer-substring (match-beginning 1) (match-end 1)) |
| 496 | (string-to-int | 496 | (string-to-number |
| 497 | (buffer-substring (match-beginning 2) (match-end 2))))))) | 497 | (buffer-substring (match-beginning 2) (match-end 2))))))) |
| 498 | 498 | ||
| 499 | (defun nnbabyl-insert-lines () | 499 | (defun nnbabyl-insert-lines () |
diff --git a/lisp/gnus/nndb.el b/lisp/gnus/nndb.el index 6aaf57c81e1..fe4072c5d35 100644 --- a/lisp/gnus/nndb.el +++ b/lisp/gnus/nndb.el | |||
| @@ -196,7 +196,7 @@ article was posted to nndb") | |||
| 196 | ;; otherwise, pull all of the following numbers into the list | 196 | ;; otherwise, pull all of the following numbers into the list |
| 197 | (re-search-forward "follows\r?\n?" nil t) | 197 | (re-search-forward "follows\r?\n?" nil t) |
| 198 | (while (re-search-forward "^[0-9]+$" nil t) | 198 | (while (re-search-forward "^[0-9]+$" nil t) |
| 199 | (push (string-to-int (match-string 0)) list))) | 199 | (push (string-to-number (match-string 0)) list))) |
| 200 | list)) | 200 | list)) |
| 201 | 201 | ||
| 202 | (defun nndb-request-expire-articles-remote | 202 | (defun nndb-request-expire-articles-remote |
diff --git a/lisp/gnus/nndiary.el b/lisp/gnus/nndiary.el index de33cd156c6..e4b087eec2e 100644 --- a/lisp/gnus/nndiary.el +++ b/lisp/gnus/nndiary.el | |||
| @@ -601,7 +601,7 @@ all. This may very well take some time.") | |||
| 601 | (nnheader-report 'nndiary "Article %s retrieved" id) | 601 | (nnheader-report 'nndiary "Article %s retrieved" id) |
| 602 | ;; We return the article number. | 602 | ;; We return the article number. |
| 603 | (cons (if group-num (car group-num) group) | 603 | (cons (if group-num (car group-num) group) |
| 604 | (string-to-int (file-name-nondirectory path))))))) | 604 | (string-to-number (file-name-nondirectory path))))))) |
| 605 | 605 | ||
| 606 | (deffoo nndiary-request-group (group &optional server dont-check) | 606 | (deffoo nndiary-request-group (group &optional server dont-check) |
| 607 | (let ((file-name-coding-system nnmail-pathname-coding-system)) | 607 | (let ((file-name-coding-system nnmail-pathname-coding-system)) |
| @@ -820,7 +820,7 @@ all. This may very well take some time.") | |||
| 820 | ;; we should insert it. (This situation should never | 820 | ;; we should insert it. (This situation should never |
| 821 | ;; occur, but one likes to make sure...) | 821 | ;; occur, but one likes to make sure...) |
| 822 | (while (and (looking-at "[0-9]+\t") | 822 | (while (and (looking-at "[0-9]+\t") |
| 823 | (< (string-to-int | 823 | (< (string-to-number |
| 824 | (buffer-substring | 824 | (buffer-substring |
| 825 | (match-beginning 0) (match-end 0))) | 825 | (match-beginning 0) (match-end 0))) |
| 826 | article) | 826 | article) |
| @@ -1281,14 +1281,14 @@ all. This may very well take some time.") | |||
| 1281 | (nnheader-article-to-file-alist nndiary-current-directory)))) | 1281 | (nnheader-article-to-file-alist nndiary-current-directory)))) |
| 1282 | 1282 | ||
| 1283 | 1283 | ||
| 1284 | (defun nndiary-string-to-int (str min &optional max) | 1284 | (defun nndiary-string-to-number (str min &optional max) |
| 1285 | ;; Like `string-to-int' but barf if STR is not exactly an integer, and not | 1285 | ;; Like `string-to-number' but barf if STR is not exactly an integer, and not |
| 1286 | ;; within the specified bounds. | 1286 | ;; within the specified bounds. |
| 1287 | ;; Signals are caught by `nndiary-schedule'. | 1287 | ;; Signals are caught by `nndiary-schedule'. |
| 1288 | (if (not (string-match "^[ \t]*[0-9]+[ \t]*$" str)) | 1288 | (if (not (string-match "^[ \t]*[0-9]+[ \t]*$" str)) |
| 1289 | (nndiary-error "not an integer value") | 1289 | (nndiary-error "not an integer value") |
| 1290 | ;; else | 1290 | ;; else |
| 1291 | (let ((val (string-to-int str))) | 1291 | (let ((val (string-to-number str))) |
| 1292 | (and (or (< val min) | 1292 | (and (or (< val min) |
| 1293 | (and max (> val max))) | 1293 | (and max (> val max))) |
| 1294 | (nndiary-error "value out of range")) | 1294 | (nndiary-error "value out of range")) |
| @@ -1315,12 +1315,12 @@ all. This may very well take some time.") | |||
| 1315 | (let ((res (split-string val "-"))) | 1315 | (let ((res (split-string val "-"))) |
| 1316 | (cond | 1316 | (cond |
| 1317 | ((= (length res) 1) | 1317 | ((= (length res) 1) |
| 1318 | (nndiary-string-to-int (car res) min-or-values max)) | 1318 | (nndiary-string-to-number (car res) min-or-values max)) |
| 1319 | ((= (length res) 2) | 1319 | ((= (length res) 2) |
| 1320 | ;; don't know if crontab accepts this, but ensure | 1320 | ;; don't know if crontab accepts this, but ensure |
| 1321 | ;; that BEG is <= END | 1321 | ;; that BEG is <= END |
| 1322 | (let ((beg (nndiary-string-to-int (car res) min-or-values max)) | 1322 | (let ((beg (nndiary-string-to-number (car res) min-or-values max)) |
| 1323 | (end (nndiary-string-to-int (cadr res) min-or-values max))) | 1323 | (end (nndiary-string-to-number (cadr res) min-or-values max))) |
| 1324 | (cond ((< beg end) | 1324 | (cond ((< beg end) |
| 1325 | (cons beg end)) | 1325 | (cons beg end)) |
| 1326 | ((= beg end) | 1326 | ((= beg end) |
diff --git a/lisp/gnus/nndoc.el b/lisp/gnus/nndoc.el index 47a3cbd0292..a7948365680 100644 --- a/lisp/gnus/nndoc.el +++ b/lisp/gnus/nndoc.el | |||
| @@ -421,7 +421,7 @@ from the document.") | |||
| 421 | (search-forward "\n\n" beg t) | 421 | (search-forward "\n\n" beg t) |
| 422 | (re-search-backward | 422 | (re-search-backward |
| 423 | "^Content-Length:[ \t]*\\([0-9]+\\) *$" end t) | 423 | "^Content-Length:[ \t]*\\([0-9]+\\) *$" end t) |
| 424 | (setq len (string-to-int (match-string 1))) | 424 | (setq len (string-to-number (match-string 1))) |
| 425 | (search-forward "\n\n" beg t) | 425 | (search-forward "\n\n" beg t) |
| 426 | (unless (= (setq len (+ (point) len)) (point-max)) | 426 | (unless (= (setq len (+ (point) len)) (point-max)) |
| 427 | (and (< len (point-max)) | 427 | (and (< len (point-max)) |
| @@ -444,7 +444,7 @@ from the document.") | |||
| 444 | (defun nndoc-rnews-body-end () | 444 | (defun nndoc-rnews-body-end () |
| 445 | (and (re-search-backward nndoc-article-begin nil t) | 445 | (and (re-search-backward nndoc-article-begin nil t) |
| 446 | (forward-line 1) | 446 | (forward-line 1) |
| 447 | (goto-char (+ (point) (string-to-int (match-string 1)))))) | 447 | (goto-char (+ (point) (string-to-number (match-string 1)))))) |
| 448 | 448 | ||
| 449 | (defun nndoc-babyl-type-p () | 449 | (defun nndoc-babyl-type-p () |
| 450 | (when (re-search-forward "\^_\^L *\n" nil t) | 450 | (when (re-search-forward "\^_\^L *\n" nil t) |
diff --git a/lisp/gnus/nndraft.el b/lisp/gnus/nndraft.el index 9235bf72a29..2fc65868b9c 100644 --- a/lisp/gnus/nndraft.el +++ b/lisp/gnus/nndraft.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; nndraft.el --- draft article access for Gnus | 1 | ;;; nndraft.el --- draft article access for Gnus |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2003 | 3 | ;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2005 |
| 4 | ;; Free Software Foundation, Inc. | 4 | ;; Free Software Foundation, Inc. |
| 5 | 5 | ||
| 6 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> | 6 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> |
| @@ -174,8 +174,11 @@ | |||
| 174 | (setq buffer-file-name (expand-file-name file) | 174 | (setq buffer-file-name (expand-file-name file) |
| 175 | buffer-auto-save-file-name (make-auto-save-file-name)) | 175 | buffer-auto-save-file-name (make-auto-save-file-name)) |
| 176 | (clear-visited-file-modtime) | 176 | (clear-visited-file-modtime) |
| 177 | (make-local-variable 'write-contents-hooks) | 177 | (let ((hook (if (boundp 'write-contents-functions) |
| 178 | (push 'nndraft-generate-headers write-contents-hooks) | 178 | 'write-contents-functions |
| 179 | 'write-contents-hooks))) | ||
| 180 | (gnus-make-local-hook hook) | ||
| 181 | (add-hook hook 'nndraft-generate-headers nil t)) | ||
| 179 | article)) | 182 | article)) |
| 180 | 183 | ||
| 181 | (deffoo nndraft-request-group (group &optional server dont-check) | 184 | (deffoo nndraft-request-group (group &optional server dont-check) |
| @@ -185,7 +188,7 @@ | |||
| 185 | (file-name-coding-system nnmail-pathname-coding-system) | 188 | (file-name-coding-system nnmail-pathname-coding-system) |
| 186 | dir file) | 189 | dir file) |
| 187 | (nnheader-re-read-dir pathname) | 190 | (nnheader-re-read-dir pathname) |
| 188 | (setq dir (mapcar (lambda (name) (string-to-int (substring name 1))) | 191 | (setq dir (mapcar (lambda (name) (string-to-number (substring name 1))) |
| 189 | (ignore-errors (directory-files | 192 | (ignore-errors (directory-files |
| 190 | pathname nil "^#[0-9]+#$" t)))) | 193 | pathname nil "^#[0-9]+#$" t)))) |
| 191 | (dolist (n dir) | 194 | (dolist (n dir) |
| @@ -293,7 +296,7 @@ | |||
| 293 | "Return the list of messages in the group." | 296 | "Return the list of messages in the group." |
| 294 | (gnus-make-directory nndraft-current-directory) | 297 | (gnus-make-directory nndraft-current-directory) |
| 295 | (sort | 298 | (sort |
| 296 | (mapcar 'string-to-int | 299 | (mapcar 'string-to-number |
| 297 | (directory-files nndraft-current-directory nil "\\`[0-9]+\\'" t)) | 300 | (directory-files nndraft-current-directory nil "\\`[0-9]+\\'" t)) |
| 298 | '<)) | 301 | '<)) |
| 299 | 302 | ||
diff --git a/lisp/gnus/nneething.el b/lisp/gnus/nneething.el index d7698efb845..61f8eefbf17 100644 --- a/lisp/gnus/nneething.el +++ b/lisp/gnus/nneething.el | |||
| @@ -329,7 +329,7 @@ included.") | |||
| 329 | (when (re-search-forward "<[a-zA-Z0-9_]@[-a-zA-Z0-9_]>" 1000 t) | 329 | (when (re-search-forward "<[a-zA-Z0-9_]@[-a-zA-Z0-9_]>" 1000 t) |
| 330 | (concat "From: " (match-string 0) "\n")))) | 330 | (concat "From: " (match-string 0) "\n")))) |
| 331 | (nneething-from-line (nth 2 atts) file)) | 331 | (nneething-from-line (nth 2 atts) file)) |
| 332 | (if (> (string-to-int (int-to-string (nth 7 atts))) 0) | 332 | (if (> (string-to-number (int-to-string (nth 7 atts))) 0) |
| 333 | (concat "Chars: " (int-to-string (nth 7 atts)) "\n") | 333 | (concat "Chars: " (int-to-string (nth 7 atts)) "\n") |
| 334 | "") | 334 | "") |
| 335 | (if buffer | 335 | (if buffer |
diff --git a/lisp/gnus/nnfolder.el b/lisp/gnus/nnfolder.el index f50530ab459..20cdb3da273 100644 --- a/lisp/gnus/nnfolder.el +++ b/lisp/gnus/nnfolder.el | |||
| @@ -200,7 +200,7 @@ the group. Then the marks file will be regenerated properly by Gnus.") | |||
| 200 | ((search-backward (concat "\n" nnfolder-article-marker) | 200 | ((search-backward (concat "\n" nnfolder-article-marker) |
| 201 | nil t) | 201 | nil t) |
| 202 | (goto-char (match-end 0)) | 202 | (goto-char (match-end 0)) |
| 203 | (setq num (string-to-int | 203 | (setq num (string-to-number |
| 204 | (buffer-substring | 204 | (buffer-substring |
| 205 | (point) (gnus-point-at-eol)))) | 205 | (point) (gnus-point-at-eol)))) |
| 206 | (goto-char start) | 206 | (goto-char start) |
| @@ -210,7 +210,7 @@ the group. Then the marks file will be regenerated properly by Gnus.") | |||
| 210 | (search-forward (concat "\n" nnfolder-article-marker) | 210 | (search-forward (concat "\n" nnfolder-article-marker) |
| 211 | nil t) | 211 | nil t) |
| 212 | (progn | 212 | (progn |
| 213 | (setq num (string-to-int | 213 | (setq num (string-to-number |
| 214 | (buffer-substring | 214 | (buffer-substring |
| 215 | (point) (gnus-point-at-eol)))) | 215 | (point) (gnus-point-at-eol)))) |
| 216 | (> num article)) | 216 | (> num article)) |
| @@ -285,7 +285,7 @@ the group. Then the marks file will be regenerated properly by Gnus.") | |||
| 285 | (cons nnfolder-current-group | 285 | (cons nnfolder-current-group |
| 286 | (if (search-forward (concat "\n" nnfolder-article-marker) | 286 | (if (search-forward (concat "\n" nnfolder-article-marker) |
| 287 | nil t) | 287 | nil t) |
| 288 | (string-to-int (buffer-substring | 288 | (string-to-number (buffer-substring |
| 289 | (point) (gnus-point-at-eol))) | 289 | (point) (gnus-point-at-eol))) |
| 290 | -1)))))))) | 290 | -1)))))))) |
| 291 | 291 | ||
| @@ -875,6 +875,7 @@ deleted. Point is left where the deleted region was." | |||
| 875 | nnfolder-file-coding-system)) | 875 | nnfolder-file-coding-system)) |
| 876 | (nnheader-find-file-noselect file t))))) | 876 | (nnheader-find-file-noselect file t))))) |
| 877 | (mm-enable-multibyte) ;; Use multibyte buffer for future copying. | 877 | (mm-enable-multibyte) ;; Use multibyte buffer for future copying. |
| 878 | (buffer-disable-undo) | ||
| 878 | (if (equal (cadr (assoc group nnfolder-scantime-alist)) | 879 | (if (equal (cadr (assoc group nnfolder-scantime-alist)) |
| 879 | (nth 5 (file-attributes file))) | 880 | (nth 5 (file-attributes file))) |
| 880 | ;; This looks up-to-date, so we don't do any scanning. | 881 | ;; This looks up-to-date, so we don't do any scanning. |
| @@ -901,7 +902,6 @@ deleted. Point is left where the deleted region was." | |||
| 901 | maxid start end newscantime | 902 | maxid start end newscantime |
| 902 | novbuf articles newnum | 903 | novbuf articles newnum |
| 903 | buffer-read-only) | 904 | buffer-read-only) |
| 904 | (buffer-disable-undo) | ||
| 905 | (setq maxid (cdr active)) | 905 | (setq maxid (cdr active)) |
| 906 | 906 | ||
| 907 | (unless (or gnus-nov-is-evil nnfolder-nov-is-evil | 907 | (unless (or gnus-nov-is-evil nnfolder-nov-is-evil |
diff --git a/lisp/gnus/nnheader.el b/lisp/gnus/nnheader.el index 6224f9718f1..952d936bd0d 100644 --- a/lisp/gnus/nnheader.el +++ b/lisp/gnus/nnheader.el | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | ;;; nnheader.el --- header access macros for Gnus and its backends | 1 | ;;; nnheader.el --- header access macros for Gnus and its backends |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1987, 1988, 1989, 1990, 1993, 1994, 1995, 1996, | 3 | ;; Copyright (C) 1987, 1988, 1989, 1990, 1993, 1994, 1995, 1996, |
| 4 | ;; 1997, 1998, 2000, 2001, 2002, 2003, 2004 | 4 | ;; 1997, 1998, 2000, 2001, 2002, 2003, 2004, 2005 |
| 5 | ;; Free Software Foundation, Inc. | 5 | ;; Free Software Foundation, Inc. |
| 6 | 6 | ||
| 7 | ;; Author: Masanobu UMEDA <umerin@flab.flab.fujitsu.junet> | 7 | ;; Author: Masanobu UMEDA <umerin@flab.flab.fujitsu.junet> |
| @@ -683,9 +683,9 @@ the line could be found." | |||
| 683 | (defsubst nnheader-file-to-number (file) | 683 | (defsubst nnheader-file-to-number (file) |
| 684 | "Take a FILE name and return the article number." | 684 | "Take a FILE name and return the article number." |
| 685 | (if (string= nnheader-numerical-short-files "^[0-9]+$") | 685 | (if (string= nnheader-numerical-short-files "^[0-9]+$") |
| 686 | (string-to-int file) | 686 | (string-to-number file) |
| 687 | (string-match nnheader-numerical-short-files file) | 687 | (string-match nnheader-numerical-short-files file) |
| 688 | (string-to-int (match-string 0 file)))) | 688 | (string-to-number (match-string 0 file)))) |
| 689 | 689 | ||
| 690 | (defvar nnheader-directory-files-is-safe | 690 | (defvar nnheader-directory-files-is-safe |
| 691 | (or (eq system-type 'windows-nt) | 691 | (or (eq system-type 'windows-nt) |
| @@ -953,15 +953,21 @@ find-file-hooks, etc. | |||
| 953 | (defun nnheader-find-file-noselect (&rest args) | 953 | (defun nnheader-find-file-noselect (&rest args) |
| 954 | "Open a file with some variables bound. | 954 | "Open a file with some variables bound. |
| 955 | See `find-file-noselect' for the arguments." | 955 | See `find-file-noselect' for the arguments." |
| 956 | (let ((format-alist nil) | 956 | (let* ((format-alist nil) |
| 957 | (auto-mode-alist (mm-auto-mode-alist)) | 957 | (auto-mode-alist (mm-auto-mode-alist)) |
| 958 | (default-major-mode 'fundamental-mode) | 958 | (default-major-mode 'fundamental-mode) |
| 959 | (enable-local-variables nil) | 959 | (enable-local-variables nil) |
| 960 | (after-insert-file-functions nil) | 960 | (after-insert-file-functions nil) |
| 961 | (enable-local-eval nil) | 961 | (enable-local-eval nil) |
| 962 | (find-file-hooks nil) | 962 | (coding-system-for-read nnheader-file-coding-system) |
| 963 | (coding-system-for-read nnheader-file-coding-system)) | 963 | (ffh (if (boundp 'find-file-hook) |
| 964 | (apply 'find-file-noselect args))) | 964 | 'find-file-hook |
| 965 | 'find-file-hooks)) | ||
| 966 | (val (symbol-value ffh))) | ||
| 967 | (set ffh nil) | ||
| 968 | (unwind-protect | ||
| 969 | (apply 'find-file-noselect args) | ||
| 970 | (set ffh val)))) | ||
| 965 | 971 | ||
| 966 | (defun nnheader-directory-regular-files (dir) | 972 | (defun nnheader-directory-regular-files (dir) |
| 967 | "Return a list of all regular files in DIR." | 973 | "Return a list of all regular files in DIR." |
diff --git a/lisp/gnus/nnkiboze.el b/lisp/gnus/nnkiboze.el index f68bb8b5f55..f6766836fe1 100644 --- a/lisp/gnus/nnkiboze.el +++ b/lisp/gnus/nnkiboze.el | |||
| @@ -106,7 +106,7 @@ | |||
| 106 | (error "nnkiboze: No xref")) | 106 | (error "nnkiboze: No xref")) |
| 107 | (unless (string-match " \\([^ ]+\\):\\([0-9]+\\)" xref) | 107 | (unless (string-match " \\([^ ]+\\):\\([0-9]+\\)" xref) |
| 108 | (error "nnkiboze: Malformed xref")) | 108 | (error "nnkiboze: Malformed xref")) |
| 109 | (setq num (string-to-int (match-string 2 xref)) | 109 | (setq num (string-to-number (match-string 2 xref)) |
| 110 | group (match-string 1 xref)) | 110 | group (match-string 1 xref)) |
| 111 | (or (with-current-buffer buffer | 111 | (or (with-current-buffer buffer |
| 112 | (or (and gnus-use-cache (gnus-cache-request-article num group)) | 112 | (or (and gnus-use-cache (gnus-cache-request-article num group)) |
diff --git a/lisp/gnus/nnmail.el b/lisp/gnus/nnmail.el index c0689335f67..affe72c75c8 100644 --- a/lisp/gnus/nnmail.el +++ b/lisp/gnus/nnmail.el | |||
| @@ -769,7 +769,7 @@ If SOURCE is a directory spec, try to return the group name component." | |||
| 769 | (if (not (save-excursion | 769 | (if (not (save-excursion |
| 770 | (and (re-search-backward | 770 | (and (re-search-backward |
| 771 | "^Content-Length:[ \t]*\\([0-9]+\\)" start t) | 771 | "^Content-Length:[ \t]*\\([0-9]+\\)" start t) |
| 772 | (setq content-length (string-to-int | 772 | (setq content-length (string-to-number |
| 773 | (buffer-substring | 773 | (buffer-substring |
| 774 | (match-beginning 1) | 774 | (match-beginning 1) |
| 775 | (match-end 1)))) | 775 | (match-end 1)))) |
| @@ -906,7 +906,7 @@ If SOURCE is a directory spec, try to return the group name component." | |||
| 906 | (if (not (re-search-forward | 906 | (if (not (re-search-forward |
| 907 | "^Content-Length:[ \t]*\\([0-9]+\\)" nil t)) | 907 | "^Content-Length:[ \t]*\\([0-9]+\\)" nil t)) |
| 908 | (setq content-length nil) | 908 | (setq content-length nil) |
| 909 | (setq content-length (string-to-int (match-string 1))) | 909 | (setq content-length (string-to-number (match-string 1))) |
| 910 | ;; We destroy the header, since none of the backends ever | 910 | ;; We destroy the header, since none of the backends ever |
| 911 | ;; use it, and we do not want to confuse other mailers by | 911 | ;; use it, and we do not want to confuse other mailers by |
| 912 | ;; having a (possibly) faulty header. | 912 | ;; having a (possibly) faulty header. |
diff --git a/lisp/gnus/nnmbox.el b/lisp/gnus/nnmbox.el index a1957fa0dcd..42721f2e92e 100644 --- a/lisp/gnus/nnmbox.el +++ b/lisp/gnus/nnmbox.el | |||
| @@ -475,7 +475,7 @@ | |||
| 475 | (when (re-search-forward "^X-Gnus-Newsgroup: +\\([^:]+\\):\\([0-9]+\\) " | 475 | (when (re-search-forward "^X-Gnus-Newsgroup: +\\([^:]+\\):\\([0-9]+\\) " |
| 476 | nil t) | 476 | nil t) |
| 477 | (cons (buffer-substring (match-beginning 1) (match-end 1)) | 477 | (cons (buffer-substring (match-beginning 1) (match-end 1)) |
| 478 | (string-to-int | 478 | (string-to-number |
| 479 | (buffer-substring (match-beginning 2) (match-end 2))))))) | 479 | (buffer-substring (match-beginning 2) (match-end 2))))))) |
| 480 | 480 | ||
| 481 | (defun nnmbox-in-header-p (pos) | 481 | (defun nnmbox-in-header-p (pos) |
| @@ -681,7 +681,7 @@ | |||
| 681 | (let (alist) | 681 | (let (alist) |
| 682 | (while (re-search-forward " \\([^:]+\\):\\([0-9]+\\)" end-header t) | 682 | (while (re-search-forward " \\([^:]+\\):\\([0-9]+\\)" end-header t) |
| 683 | (push (cons (match-string 1) | 683 | (push (cons (match-string 1) |
| 684 | (string-to-int (match-string 2))) alist)) | 684 | (string-to-number (match-string 2))) alist)) |
| 685 | (nnmbox-insert-newsgroup-line alist)) | 685 | (nnmbox-insert-newsgroup-line alist)) |
| 686 | ;; this is really a new article | 686 | ;; this is really a new article |
| 687 | (nnmbox-save-mail | 687 | (nnmbox-save-mail |
diff --git a/lisp/gnus/nnmh.el b/lisp/gnus/nnmh.el index 37f0bb353e8..af99217fe6d 100644 --- a/lisp/gnus/nnmh.el +++ b/lisp/gnus/nnmh.el | |||
| @@ -150,7 +150,7 @@ as unread by Gnus.") | |||
| 150 | (file-exists-p file) | 150 | (file-exists-p file) |
| 151 | (not (file-directory-p file)) | 151 | (not (file-directory-p file)) |
| 152 | (save-excursion (nnmail-find-file file)) | 152 | (save-excursion (nnmail-find-file file)) |
| 153 | (string-to-int (file-name-nondirectory file))))) | 153 | (string-to-number (file-name-nondirectory file))))) |
| 154 | 154 | ||
| 155 | (deffoo nnmh-request-group (group &optional server dont-check) | 155 | (deffoo nnmh-request-group (group &optional server dont-check) |
| 156 | (nnheader-init-server-buffer) | 156 | (nnheader-init-server-buffer) |
| @@ -176,7 +176,7 @@ as unread by Gnus.") | |||
| 176 | (nnheader-re-read-dir pathname) | 176 | (nnheader-re-read-dir pathname) |
| 177 | (setq dir | 177 | (setq dir |
| 178 | (sort | 178 | (sort |
| 179 | (mapcar (lambda (name) (string-to-int name)) | 179 | (mapcar (lambda (name) (string-to-number name)) |
| 180 | (directory-files pathname nil "^[0-9]+$" t)) | 180 | (directory-files pathname nil "^[0-9]+$" t)) |
| 181 | '<)) | 181 | '<)) |
| 182 | (cond | 182 | (cond |
| @@ -224,7 +224,7 @@ as unread by Gnus.") | |||
| 224 | ;; For each directory, generate an active file line. | 224 | ;; For each directory, generate an active file line. |
| 225 | (unless (string= (expand-file-name nnmh-toplev) dir) | 225 | (unless (string= (expand-file-name nnmh-toplev) dir) |
| 226 | (let ((files (mapcar | 226 | (let ((files (mapcar |
| 227 | (lambda (name) (string-to-int name)) | 227 | (lambda (name) (string-to-number name)) |
| 228 | (directory-files dir nil "^[0-9]+$" t)))) | 228 | (directory-files dir nil "^[0-9]+$" t)))) |
| 229 | (when files | 229 | (when files |
| 230 | (save-excursion | 230 | (save-excursion |
| @@ -358,7 +358,7 @@ as unread by Gnus.") | |||
| 358 | (nnmh-possibly-change-directory group server) | 358 | (nnmh-possibly-change-directory group server) |
| 359 | (let ((articles (mapcar | 359 | (let ((articles (mapcar |
| 360 | (lambda (file) | 360 | (lambda (file) |
| 361 | (string-to-int file)) | 361 | (string-to-number file)) |
| 362 | (directory-files | 362 | (directory-files |
| 363 | nnmh-current-directory nil "^[0-9]+$")))) | 363 | nnmh-current-directory nil "^[0-9]+$")))) |
| 364 | (when articles | 364 | (when articles |
| @@ -486,7 +486,7 @@ as unread by Gnus.") | |||
| 486 | (let ((files (sort | 486 | (let ((files (sort |
| 487 | (mapcar | 487 | (mapcar |
| 488 | (lambda (f) | 488 | (lambda (f) |
| 489 | (string-to-int f)) | 489 | (string-to-number f)) |
| 490 | (directory-files dir nil "^[0-9]+$")) | 490 | (directory-files dir nil "^[0-9]+$")) |
| 491 | '>))) | 491 | '>))) |
| 492 | (when files | 492 | (when files |
| @@ -509,7 +509,7 @@ as unread by Gnus.") | |||
| 509 | ;; articles in this folder. The articles that are "new" will be | 509 | ;; articles in this folder. The articles that are "new" will be |
| 510 | ;; marked as unread by Gnus. | 510 | ;; marked as unread by Gnus. |
| 511 | (let* ((dir nnmh-current-directory) | 511 | (let* ((dir nnmh-current-directory) |
| 512 | (files (sort (mapcar (function (lambda (name) (string-to-int name))) | 512 | (files (sort (mapcar (function (lambda (name) (string-to-number name))) |
| 513 | (directory-files nnmh-current-directory | 513 | (directory-files nnmh-current-directory |
| 514 | nil "^[0-9]+$" t)) | 514 | nil "^[0-9]+$" t)) |
| 515 | '<)) | 515 | '<)) |
diff --git a/lisp/gnus/nnml.el b/lisp/gnus/nnml.el index b82df8f979a..f330fa97a5a 100644 --- a/lisp/gnus/nnml.el +++ b/lisp/gnus/nnml.el | |||
| @@ -212,7 +212,7 @@ marks file will be regenerated properly by Gnus.") | |||
| 212 | (nnheader-report 'nnml "Article %s retrieved" id) | 212 | (nnheader-report 'nnml "Article %s retrieved" id) |
| 213 | ;; We return the article number. | 213 | ;; We return the article number. |
| 214 | (cons (if group-num (car group-num) group) | 214 | (cons (if group-num (car group-num) group) |
| 215 | (string-to-int (file-name-nondirectory path))))))) | 215 | (string-to-number (file-name-nondirectory path))))))) |
| 216 | 216 | ||
| 217 | (deffoo nnml-request-group (group &optional server dont-check) | 217 | (deffoo nnml-request-group (group &optional server dont-check) |
| 218 | (let ((file-name-coding-system nnmail-pathname-coding-system)) | 218 | (let ((file-name-coding-system nnmail-pathname-coding-system)) |
| @@ -426,7 +426,7 @@ marks file will be regenerated properly by Gnus.") | |||
| 426 | ;; we should insert it. (This situation should never | 426 | ;; we should insert it. (This situation should never |
| 427 | ;; occur, but one likes to make sure...) | 427 | ;; occur, but one likes to make sure...) |
| 428 | (while (and (looking-at "[0-9]+\t") | 428 | (while (and (looking-at "[0-9]+\t") |
| 429 | (< (string-to-int | 429 | (< (string-to-number |
| 430 | (buffer-substring | 430 | (buffer-substring |
| 431 | (match-beginning 0) (match-end 0))) | 431 | (match-beginning 0) (match-end 0))) |
| 432 | article) | 432 | article) |
diff --git a/lisp/gnus/nnrss.el b/lisp/gnus/nnrss.el index 42ab072f438..ee5d6560354 100644 --- a/lisp/gnus/nnrss.el +++ b/lisp/gnus/nnrss.el | |||
| @@ -899,7 +899,7 @@ whether they are `offsite' or `onsite'." | |||
| 899 | (selection | 899 | (selection |
| 900 | (mapcar (lambda (listinfo) | 900 | (mapcar (lambda (listinfo) |
| 901 | (cons (cdr (assoc "sitename" listinfo)) | 901 | (cons (cdr (assoc "sitename" listinfo)) |
| 902 | (string-to-int | 902 | (string-to-number |
| 903 | (cdr (assoc "feedid" listinfo))))) | 903 | (cdr (assoc "feedid" listinfo))))) |
| 904 | feedinfo))) | 904 | feedinfo))) |
| 905 | (cdr (assoc | 905 | (cdr (assoc |
diff --git a/lisp/gnus/nnsoup.el b/lisp/gnus/nnsoup.el index 9c69b1d3c63..836d97e1e42 100644 --- a/lisp/gnus/nnsoup.el +++ b/lisp/gnus/nnsoup.el | |||
| @@ -752,9 +752,9 @@ backend for the messages.") | |||
| 752 | (let ((files (sort (directory-files nnsoup-directory t "IDX$") | 752 | (let ((files (sort (directory-files nnsoup-directory t "IDX$") |
| 753 | (lambda (f1 f2) | 753 | (lambda (f1 f2) |
| 754 | (< (progn (string-match "/\\([0-9]+\\)\\." f1) | 754 | (< (progn (string-match "/\\([0-9]+\\)\\." f1) |
| 755 | (string-to-int (match-string 1 f1))) | 755 | (string-to-number (match-string 1 f1))) |
| 756 | (progn (string-match "/\\([0-9]+\\)\\." f2) | 756 | (progn (string-match "/\\([0-9]+\\)\\." f2) |
| 757 | (string-to-int (match-string 1 f2))))))) | 757 | (string-to-number (match-string 1 f2))))))) |
| 758 | active group lines ident elem min) | 758 | active group lines ident elem min) |
| 759 | (set-buffer (get-buffer-create " *nnsoup work*")) | 759 | (set-buffer (get-buffer-create " *nnsoup work*")) |
| 760 | (while files | 760 | (while files |
diff --git a/lisp/gnus/nnspool.el b/lisp/gnus/nnspool.el index d54897a7750..6418c96d931 100644 --- a/lisp/gnus/nnspool.el +++ b/lisp/gnus/nnspool.el | |||
| @@ -248,7 +248,7 @@ there.") | |||
| 248 | ;; Fix by Sudish Joseph <joseph@cis.ohio-state.edu> | 248 | ;; Fix by Sudish Joseph <joseph@cis.ohio-state.edu> |
| 249 | (when (setq dir (directory-files pathname nil "^[0-9]+$" t)) | 249 | (when (setq dir (directory-files pathname nil "^[0-9]+$" t)) |
| 250 | (setq dir | 250 | (setq dir |
| 251 | (sort (mapcar (lambda (name) (string-to-int name)) dir) '<))) | 251 | (sort (mapcar (lambda (name) (string-to-number name)) dir) '<))) |
| 252 | (if dir | 252 | (if dir |
| 253 | (nnheader-insert | 253 | (nnheader-insert |
| 254 | "211 %d %d %d %s\n" (length dir) (car dir) | 254 | "211 %d %d %d %s\n" (length dir) (car dir) |
| @@ -440,7 +440,7 @@ there.") | |||
| 440 | (goto-char (point-min)) | 440 | (goto-char (point-min)) |
| 441 | (prog1 | 441 | (prog1 |
| 442 | (when (looking-at "<[^>]+>[ \t]+[-0-9~]+[ \t]+\\([^ /\t\n]+\\)/\\([0-9]+\\)[ \t\n]") | 442 | (when (looking-at "<[^>]+>[ \t]+[-0-9~]+[ \t]+\\([^ /\t\n]+\\)/\\([0-9]+\\)[ \t\n]") |
| 443 | (cons (match-string 1) (string-to-int (match-string 2)))) | 443 | (cons (match-string 1) (string-to-number (match-string 2)))) |
| 444 | (kill-buffer (current-buffer))))) | 444 | (kill-buffer (current-buffer))))) |
| 445 | 445 | ||
| 446 | (defun nnspool-find-file (file) | 446 | (defun nnspool-find-file (file) |
diff --git a/lisp/gnus/nntp.el b/lisp/gnus/nntp.el index ab85ad25931..888a6edcfb1 100644 --- a/lisp/gnus/nntp.el +++ b/lisp/gnus/nntp.el | |||
| @@ -1128,7 +1128,7 @@ password contained in '~/.nntp-authinfo'." | |||
| 1128 | (nntp-kill-buffer pbuffer)) | 1128 | (nntp-kill-buffer pbuffer)) |
| 1129 | (when (and (buffer-name pbuffer) | 1129 | (when (and (buffer-name pbuffer) |
| 1130 | process) | 1130 | process) |
| 1131 | (process-kill-without-query process) | 1131 | (gnus-set-process-query-on-exit-flag process nil) |
| 1132 | (if (and (nntp-wait-for process "^2.*\n" buffer nil t) | 1132 | (if (and (nntp-wait-for process "^2.*\n" buffer nil t) |
| 1133 | (memq (process-status process) '(open run))) | 1133 | (memq (process-status process) '(open run))) |
| 1134 | (prog1 | 1134 | (prog1 |
| @@ -1162,7 +1162,7 @@ password contained in '~/.nntp-authinfo'." | |||
| 1162 | (format-spec-make | 1162 | (format-spec-make |
| 1163 | ?s nntp-address | 1163 | ?s nntp-address |
| 1164 | ?p nntp-port-number))))) | 1164 | ?p nntp-port-number))))) |
| 1165 | (process-kill-without-query proc) | 1165 | (gnus-set-process-query-on-exit-flag proc nil) |
| 1166 | (save-excursion | 1166 | (save-excursion |
| 1167 | (set-buffer buffer) | 1167 | (set-buffer buffer) |
| 1168 | (let ((nntp-connection-alist (list proc buffer nil))) | 1168 | (let ((nntp-connection-alist (list proc buffer nil))) |
| @@ -1173,7 +1173,7 @@ password contained in '~/.nntp-authinfo'." | |||
| 1173 | 1173 | ||
| 1174 | (defun nntp-open-tls-stream (buffer) | 1174 | (defun nntp-open-tls-stream (buffer) |
| 1175 | (let ((proc (open-tls-stream "nntpd" buffer nntp-address nntp-port-number))) | 1175 | (let ((proc (open-tls-stream "nntpd" buffer nntp-address nntp-port-number))) |
| 1176 | (process-kill-without-query proc) | 1176 | (gnus-set-process-query-on-exit-flag proc nil) |
| 1177 | (save-excursion | 1177 | (save-excursion |
| 1178 | (set-buffer buffer) | 1178 | (set-buffer buffer) |
| 1179 | (let ((nntp-connection-alist (list proc buffer nil))) | 1179 | (let ((nntp-connection-alist (list proc buffer nil))) |
| @@ -1499,7 +1499,7 @@ password contained in '~/.nntp-authinfo'." | |||
| 1499 | (when (<= count 1) | 1499 | (when (<= count 1) |
| 1500 | (goto-char (point-min)) | 1500 | (goto-char (point-min)) |
| 1501 | (when (re-search-forward "^[0-9][0-9][0-9] .*\n\\([0-9]+\\)" nil t) | 1501 | (when (re-search-forward "^[0-9][0-9][0-9] .*\n\\([0-9]+\\)" nil t) |
| 1502 | (let ((low-limit (string-to-int | 1502 | (let ((low-limit (string-to-number |
| 1503 | (buffer-substring (match-beginning 1) | 1503 | (buffer-substring (match-beginning 1) |
| 1504 | (match-end 1))))) | 1504 | (match-end 1))))) |
| 1505 | (while (and articles (<= (car articles) low-limit)) | 1505 | (while (and articles (<= (car articles) low-limit)) |
| @@ -1571,7 +1571,7 @@ password contained in '~/.nntp-authinfo'." | |||
| 1571 | (goto-char (point-min)) | 1571 | (goto-char (point-min)) |
| 1572 | ;; We first find the number by looking at the status line. | 1572 | ;; We first find the number by looking at the status line. |
| 1573 | (let ((number (and (looking-at "2[0-9][0-9] +\\([0-9]+\\) ") | 1573 | (let ((number (and (looking-at "2[0-9][0-9] +\\([0-9]+\\) ") |
| 1574 | (string-to-int | 1574 | (string-to-number |
| 1575 | (buffer-substring (match-beginning 1) | 1575 | (buffer-substring (match-beginning 1) |
| 1576 | (match-end 1))))) | 1576 | (match-end 1))))) |
| 1577 | newsgroups xref) | 1577 | newsgroups xref) |
| @@ -1609,7 +1609,7 @@ password contained in '~/.nntp-authinfo'." | |||
| 1609 | "\\([^ :]+\\):\\([0-9]+\\)") | 1609 | "\\([^ :]+\\):\\([0-9]+\\)") |
| 1610 | xref)) | 1610 | xref)) |
| 1611 | (setq group (match-string 1 xref) | 1611 | (setq group (match-string 1 xref) |
| 1612 | number (string-to-int (match-string 2 xref)))) | 1612 | number (string-to-number (match-string 2 xref)))) |
| 1613 | ((and (setq newsgroups | 1613 | ((and (setq newsgroups |
| 1614 | (mail-fetch-field "newsgroups")) | 1614 | (mail-fetch-field "newsgroups")) |
| 1615 | (not (string-match "," newsgroups))) | 1615 | (not (string-match "," newsgroups))) |
diff --git a/lisp/gnus/pgg-gpg.el b/lisp/gnus/pgg-gpg.el index 2b3e521c60f..463020838c9 100644 --- a/lisp/gnus/pgg-gpg.el +++ b/lisp/gnus/pgg-gpg.el | |||
| @@ -252,7 +252,7 @@ If optional argument SIGN is non-nil, do a combined sign and encrypt." | |||
| 252 | (when (re-search-forward "^\\[GNUPG:] IMPORT_RES\\>" nil t) | 252 | (when (re-search-forward "^\\[GNUPG:] IMPORT_RES\\>" nil t) |
| 253 | (setq status (buffer-substring (match-end 0) | 253 | (setq status (buffer-substring (match-end 0) |
| 254 | (progn (end-of-line)(point))) | 254 | (progn (end-of-line)(point))) |
| 255 | status (vconcat (mapcar #'string-to-int (split-string status)))) | 255 | status (vconcat (mapcar #'string-to-number (split-string status)))) |
| 256 | (erase-buffer) | 256 | (erase-buffer) |
| 257 | (insert (format "Imported %d key(s). | 257 | (insert (format "Imported %d key(s). |
| 258 | \tArmor contains %d key(s) [%d bad, %d old].\n" | 258 | \tArmor contains %d key(s) [%d bad, %d old].\n" |
diff --git a/lisp/gnus/pgg-parse.el b/lisp/gnus/pgg-parse.el index bf04ca914a8..7929b54010d 100644 --- a/lisp/gnus/pgg-parse.el +++ b/lisp/gnus/pgg-parse.el | |||
| @@ -113,7 +113,7 @@ | |||
| 113 | `(mapconcat (lambda (c) (format "%02X" (pgg-char-int c))) | 113 | `(mapconcat (lambda (c) (format "%02X" (pgg-char-int c))) |
| 114 | ,string "") | 114 | ,string "") |
| 115 | ;; `(upcase (apply #'format "%02x%02x%02x%02x%02x%02x%02x%02x" | 115 | ;; `(upcase (apply #'format "%02x%02x%02x%02x%02x%02x%02x%02x" |
| 116 | ;; (string-to-int-list ,string))) | 116 | ;; (string-to-number-list ,string))) |
| 117 | ) | 117 | ) |
| 118 | 118 | ||
| 119 | (defmacro pgg-parse-time-field (bytes) | 119 | (defmacro pgg-parse-time-field (bytes) |
| @@ -136,7 +136,7 @@ | |||
| 136 | 136 | ||
| 137 | (defmacro pgg-read-bytes (nbytes) | 137 | (defmacro pgg-read-bytes (nbytes) |
| 138 | `(mapcar #'pgg-char-int (pgg-read-bytes-string ,nbytes)) | 138 | `(mapcar #'pgg-char-int (pgg-read-bytes-string ,nbytes)) |
| 139 | ;; `(string-to-int-list (pgg-read-bytes-string ,nbytes)) | 139 | ;; `(string-to-number-list (pgg-read-bytes-string ,nbytes)) |
| 140 | ) | 140 | ) |
| 141 | 141 | ||
| 142 | (defmacro pgg-read-body-string (ptag) | 142 | (defmacro pgg-read-body-string (ptag) |
| @@ -146,7 +146,7 @@ | |||
| 146 | 146 | ||
| 147 | (defmacro pgg-read-body (ptag) | 147 | (defmacro pgg-read-body (ptag) |
| 148 | `(mapcar #'pgg-char-int (pgg-read-body-string ,ptag)) | 148 | `(mapcar #'pgg-char-int (pgg-read-body-string ,ptag)) |
| 149 | ;; `(string-to-int-list (pgg-read-body-string ,ptag)) | 149 | ;; `(string-to-number-list (pgg-read-body-string ,ptag)) |
| 150 | ) | 150 | ) |
| 151 | 151 | ||
| 152 | (defalias 'pgg-skip-bytes 'forward-char) | 152 | (defalias 'pgg-skip-bytes 'forward-char) |
diff --git a/lisp/gnus/pgg.el b/lisp/gnus/pgg.el index 888219a8c57..eff02a1c32a 100644 --- a/lisp/gnus/pgg.el +++ b/lisp/gnus/pgg.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; pgg.el --- glue for the various PGP implementations. | 1 | ;;; pgg.el --- glue for the various PGP implementations. |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1999, 2000, 2003 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 1999, 2000, 2003, 2005 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Daiki Ueno <ueno@unixuser.org> | 5 | ;; Author: Daiki Ueno <ueno@unixuser.org> |
| 6 | ;; Created: 1999/10/28 | 6 | ;; Created: 1999/10/28 |
| @@ -97,82 +97,76 @@ | |||
| 97 | (read-passwd prompt))) | 97 | (read-passwd prompt))) |
| 98 | 98 | ||
| 99 | (eval-when-compile | 99 | (eval-when-compile |
| 100 | (defvar itimer-process) | 100 | (defmacro pgg-run-at-time-1 (time repeat function args) |
| 101 | (defvar itimer-timer) | 101 | (when (featurep 'xemacs) |
| 102 | (autoload 'delete-itimer "itimer") | 102 | (if (condition-case nil |
| 103 | (autoload 'itimer-driver-start "itimer") | 103 | (let ((delete-itimer 'delete-itimer) |
| 104 | (autoload 'itimer-value "itimer") | 104 | (itimer-driver-start 'itimer-driver-start) |
| 105 | (autoload 'set-itimer-function "itimer") | 105 | (itimer-value 'itimer-value) |
| 106 | (autoload 'set-itimer-function-arguments "itimer") | 106 | (start-itimer 'start-itimer)) |
| 107 | (autoload 'set-itimer-restart "itimer") | 107 | (unless (or (symbol-value 'itimer-process) |
| 108 | (autoload 'start-itimer "itimer")) | 108 | (symbol-value 'itimer-timer)) |
| 109 | (funcall itimer-driver-start)) | ||
| 110 | ;; Check whether there is a bug to which the difference of | ||
| 111 | ;; the present time and the time when the itimer driver was | ||
| 112 | ;; woken up is subtracted from the initial itimer value. | ||
| 113 | (let* ((inhibit-quit t) | ||
| 114 | (ctime (current-time)) | ||
| 115 | (itimer-timer-last-wakeup | ||
| 116 | (prog1 | ||
| 117 | ctime | ||
| 118 | (setcar ctime (1- (car ctime))))) | ||
| 119 | (itimer-list nil) | ||
| 120 | (itimer (funcall start-itimer "pgg-run-at-time" | ||
| 121 | 'ignore 5))) | ||
| 122 | (sleep-for 0.1) ;; Accept the timeout interrupt. | ||
| 123 | (prog1 | ||
| 124 | (> (funcall itimer-value itimer) 0) | ||
| 125 | (funcall delete-itimer itimer)))) | ||
| 126 | (error nil)) | ||
| 127 | `(let ((time ,time)) | ||
| 128 | (apply #'start-itimer "pgg-run-at-time" | ||
| 129 | ,function (if time (max time 1e-9) 1e-9) | ||
| 130 | ,repeat nil t ,args))) | ||
| 131 | `(let ((time ,time) | ||
| 132 | (itimers (list nil))) | ||
| 133 | (setcar | ||
| 134 | itimers | ||
| 135 | (apply #'start-itimer "pgg-run-at-time" | ||
| 136 | (lambda (itimers repeat function &rest args) | ||
| 137 | (let ((itimer (car itimers))) | ||
| 138 | (if repeat | ||
| 139 | (progn | ||
| 140 | (set-itimer-function | ||
| 141 | itimer | ||
| 142 | (lambda (itimer repeat function &rest args) | ||
| 143 | (set-itimer-restart itimer repeat) | ||
| 144 | (set-itimer-function itimer function) | ||
| 145 | (set-itimer-function-arguments itimer args) | ||
| 146 | (apply function args))) | ||
| 147 | (set-itimer-function-arguments | ||
| 148 | itimer | ||
| 149 | (append (list itimer repeat function) args))) | ||
| 150 | (set-itimer-function | ||
| 151 | itimer | ||
| 152 | (lambda (itimer function &rest args) | ||
| 153 | (delete-itimer itimer) | ||
| 154 | (apply function args))) | ||
| 155 | (set-itimer-function-arguments | ||
| 156 | itimer | ||
| 157 | (append (list itimer function) args))))) | ||
| 158 | 1e-9 (if time (max time 1e-9) 1e-9) | ||
| 159 | nil t itimers ,repeat ,function ,args)))))) | ||
| 109 | 160 | ||
| 110 | (eval-and-compile | 161 | (eval-and-compile |
| 111 | (defalias | 162 | (if (featurep 'xemacs) |
| 112 | 'pgg-run-at-time | 163 | (defun pgg-run-at-time (time repeat function &rest args) |
| 113 | (if (featurep 'xemacs) | 164 | "Emulating function run as `run-at-time'. |
| 114 | (if (condition-case nil | ||
| 115 | (progn | ||
| 116 | (unless (or itimer-process itimer-timer) | ||
| 117 | (itimer-driver-start)) | ||
| 118 | ;; Check whether there is a bug to which the difference of | ||
| 119 | ;; the present time and the time when the itimer driver was | ||
| 120 | ;; woken up is subtracted from the initial itimer value. | ||
| 121 | (let* ((inhibit-quit t) | ||
| 122 | (ctime (current-time)) | ||
| 123 | (itimer-timer-last-wakeup | ||
| 124 | (prog1 | ||
| 125 | ctime | ||
| 126 | (setcar ctime (1- (car ctime))))) | ||
| 127 | (itimer-list nil) | ||
| 128 | (itimer (start-itimer "pgg-run-at-time" 'ignore 5))) | ||
| 129 | (sleep-for 0.1) ;; Accept the timeout interrupt. | ||
| 130 | (prog1 | ||
| 131 | (> (itimer-value itimer) 0) | ||
| 132 | (delete-itimer itimer)))) | ||
| 133 | (error nil)) | ||
| 134 | (lambda (time repeat function &rest args) | ||
| 135 | "Emulating function run as `run-at-time'. | ||
| 136 | TIME should be nil meaning now, or a number of seconds from now. | 165 | TIME should be nil meaning now, or a number of seconds from now. |
| 137 | Return an itimer object which can be used in either `delete-itimer' | 166 | Return an itimer object which can be used in either `delete-itimer' |
| 138 | or `cancel-timer'." | 167 | or `cancel-timer'." |
| 139 | (apply #'start-itimer "pgg-run-at-time" | 168 | (pgg-run-at-time-1 time repeat function args)) |
| 140 | function (if time (max time 1e-9) 1e-9) | 169 | (defalias 'pgg-run-at-time 'run-at-time))) |
| 141 | repeat nil t args)) | ||
| 142 | (lambda (time repeat function &rest args) | ||
| 143 | "Emulating function run as `run-at-time' in the right way. | ||
| 144 | TIME should be nil meaning now, or a number of seconds from now. | ||
| 145 | Return an itimer object which can be used in either `delete-itimer' | ||
| 146 | or `cancel-timer'." | ||
| 147 | (let ((itimers (list nil))) | ||
| 148 | (setcar | ||
| 149 | itimers | ||
| 150 | (apply #'start-itimer "pgg-run-at-time" | ||
| 151 | (lambda (itimers repeat function &rest args) | ||
| 152 | (let ((itimer (car itimers))) | ||
| 153 | (if repeat | ||
| 154 | (progn | ||
| 155 | (set-itimer-function | ||
| 156 | itimer | ||
| 157 | (lambda (itimer repeat function &rest args) | ||
| 158 | (set-itimer-restart itimer repeat) | ||
| 159 | (set-itimer-function itimer function) | ||
| 160 | (set-itimer-function-arguments itimer args) | ||
| 161 | (apply function args))) | ||
| 162 | (set-itimer-function-arguments | ||
| 163 | itimer | ||
| 164 | (append (list itimer repeat function) args))) | ||
| 165 | (set-itimer-function | ||
| 166 | itimer | ||
| 167 | (lambda (itimer function &rest args) | ||
| 168 | (delete-itimer itimer) | ||
| 169 | (apply function args))) | ||
| 170 | (set-itimer-function-arguments | ||
| 171 | itimer | ||
| 172 | (append (list itimer function) args))))) | ||
| 173 | 1e-9 (if time (max time 1e-9) 1e-9) | ||
| 174 | nil t itimers repeat function args))))) | ||
| 175 | 'run-at-time))) | ||
| 176 | 170 | ||
| 177 | (defun pgg-add-passphrase-cache (key passphrase) | 171 | (defun pgg-add-passphrase-cache (key passphrase) |
| 178 | (setq key (pgg-truncate-key-identifier key)) | 172 | (setq key (pgg-truncate-key-identifier key)) |
diff --git a/lisp/gnus/pop3.el b/lisp/gnus/pop3.el index b21b3dcd5ae..637421c46d9 100644 --- a/lisp/gnus/pop3.el +++ b/lisp/gnus/pop3.el | |||
| @@ -1,6 +1,7 @@ | |||
| 1 | ;;; pop3.el --- Post Office Protocol (RFC 1460) interface | 1 | ;;; pop3.el --- Post Office Protocol (RFC 1460) interface |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 | 3 | ;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, |
| 4 | ;; 2005 | ||
| 4 | ;; Free Software Foundation, Inc. | 5 | ;; Free Software Foundation, Inc. |
| 5 | 6 | ||
| 6 | ;; Author: Richard L. Pieri <ratinox@peorth.gweep.net> | 7 | ;; Author: Richard L. Pieri <ratinox@peorth.gweep.net> |
| @@ -348,21 +349,36 @@ If NOW, use that time instead." | |||
| 348 | 349 | ||
| 349 | ;; AUTHORIZATION STATE | 350 | ;; AUTHORIZATION STATE |
| 350 | 351 | ||
| 352 | (eval-when-compile | ||
| 353 | (if (not (fboundp 'md5)) ;; Emacs 20 | ||
| 354 | (defalias 'md5 'ignore))) | ||
| 355 | |||
| 351 | (eval-and-compile | 356 | (eval-and-compile |
| 352 | (if (fboundp 'md5) | 357 | (if (and (fboundp 'md5) |
| 353 | (defalias 'pop3-md5 'md5) | 358 | ;; There might be an incompatible implementation. |
| 359 | (condition-case nil | ||
| 360 | (md5 "Check whether the 4th argument is allowed" | ||
| 361 | nil nil 'binary) | ||
| 362 | (error nil))) | ||
| 363 | (defun pop3-md5 (string) | ||
| 364 | (md5 string nil nil 'binary)) | ||
| 354 | (defvar pop3-md5-program "md5" | 365 | (defvar pop3-md5-program "md5" |
| 355 | "*Program to encode its input in MD5.") | 366 | "*Program to encode its input in MD5. |
| 356 | 367 | \"openssl\" is a popular alternative; set `pop3-md5-program-args' to | |
| 368 | '(\"md5\") if you use it.") | ||
| 369 | (defvar pop3-md5-program-args nil | ||
| 370 | "*List of arguments passed to `pop3-md5-program'.") | ||
| 357 | (defun pop3-md5 (string) | 371 | (defun pop3-md5 (string) |
| 358 | (with-temp-buffer | 372 | (let ((default-enable-multibyte-characters t) |
| 359 | (insert string) | 373 | (coding-system-for-write 'binary)) |
| 360 | (call-process-region (point-min) (point-max) | 374 | (with-temp-buffer |
| 361 | pop3-md5-program | 375 | (insert string) |
| 362 | t (current-buffer) nil) | 376 | (apply 'call-process-region (point-min) (point-max) |
| 363 | ;; The meaningful output is the first 32 characters. | 377 | pop3-md5-program t (current-buffer) nil |
| 364 | ;; Don't return the newline that follows them! | 378 | pop3-md5-program-args) |
| 365 | (buffer-substring (point-min) (+ 32 (point-min))))))) | 379 | ;; The meaningful output is the first 32 characters. |
| 380 | ;; Don't return the newline that follows them! | ||
| 381 | (buffer-substring (point-min) (+ 32 (point-min)))))))) | ||
| 366 | 382 | ||
| 367 | (defun pop3-user (process user) | 383 | (defun pop3-user (process user) |
| 368 | "Send USER information to POP3 server." | 384 | "Send USER information to POP3 server." |
| @@ -398,8 +414,8 @@ If NOW, use that time instead." | |||
| 398 | "Return the number of messages in the maildrop and the maildrop's size." | 414 | "Return the number of messages in the maildrop and the maildrop's size." |
| 399 | (pop3-send-command process "STAT") | 415 | (pop3-send-command process "STAT") |
| 400 | (let ((response (pop3-read-response process t))) | 416 | (let ((response (pop3-read-response process t))) |
| 401 | (list (string-to-int (nth 1 (split-string response " "))) | 417 | (list (string-to-number (nth 1 (split-string response " "))) |
| 402 | (string-to-int (nth 2 (split-string response " ")))) | 418 | (string-to-number (nth 2 (split-string response " ")))) |
| 403 | )) | 419 | )) |
| 404 | 420 | ||
| 405 | (defun pop3-list (process &optional msg) | 421 | (defun pop3-list (process &optional msg) |
| @@ -449,7 +465,7 @@ This function currently does nothing.") | |||
| 449 | "Return highest accessed message-id number for the session." | 465 | "Return highest accessed message-id number for the session." |
| 450 | (pop3-send-command process "LAST") | 466 | (pop3-send-command process "LAST") |
| 451 | (let ((response (pop3-read-response process t))) | 467 | (let ((response (pop3-read-response process t))) |
| 452 | (string-to-int (nth 1 (split-string response " "))) | 468 | (string-to-number (nth 1 (split-string response " "))) |
| 453 | )) | 469 | )) |
| 454 | 470 | ||
| 455 | (defun pop3-rset (process) | 471 | (defun pop3-rset (process) |
diff --git a/lisp/gnus/qp.el b/lisp/gnus/qp.el index 79810bc18a4..0d140e03fca 100644 --- a/lisp/gnus/qp.el +++ b/lisp/gnus/qp.el | |||
| @@ -69,9 +69,9 @@ them into characters should be done separately." | |||
| 69 | (cond ((eq (char-after (1+ (point))) ?\n) | 69 | (cond ((eq (char-after (1+ (point))) ?\n) |
| 70 | (delete-char 2)) | 70 | (delete-char 2)) |
| 71 | ((looking-at "=[0-9A-F][0-9A-F]") | 71 | ((looking-at "=[0-9A-F][0-9A-F]") |
| 72 | (let ((byte (string-to-int (buffer-substring (1+ (point)) | 72 | (let ((byte (string-to-number (buffer-substring (1+ (point)) |
| 73 | (+ 3 (point))) | 73 | (+ 3 (point))) |
| 74 | 16))) | 74 | 16))) |
| 75 | (mm-insert-byte byte 1) | 75 | (mm-insert-byte byte 1) |
| 76 | (delete-char 3))) | 76 | (delete-char 3))) |
| 77 | (t | 77 | (t |
diff --git a/lisp/gnus/score-mode.el b/lisp/gnus/score-mode.el index a54b57f6fa4..c537012a422 100644 --- a/lisp/gnus/score-mode.el +++ b/lisp/gnus/score-mode.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; score-mode.el --- mode for editing Gnus score files | 1 | ;;; score-mode.el --- mode for editing Gnus score files |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1996, 2001, 2004 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 1996, 2001, 2004, 2005 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> | 5 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> |
| 6 | ;; Keywords: news, mail | 6 | ;; Keywords: news, mail |
| @@ -28,7 +28,7 @@ | |||
| 28 | 28 | ||
| 29 | (eval-when-compile (require 'cl)) | 29 | (eval-when-compile (require 'cl)) |
| 30 | (require 'mm-util) ; for mm-universal-coding-system | 30 | (require 'mm-util) ; for mm-universal-coding-system |
| 31 | (require 'gnus-util) ; for gnus-pp | 31 | (require 'gnus-util) ; for gnus-pp, gnus-run-mode-hooks |
| 32 | 32 | ||
| 33 | (defvar gnus-score-mode-hook nil | 33 | (defvar gnus-score-mode-hook nil |
| 34 | "*Hook run in score mode buffers.") | 34 | "*Hook run in score mode buffers.") |
| @@ -71,7 +71,7 @@ This mode is an extended emacs-lisp mode. | |||
| 71 | (setq mode-name "Score") | 71 | (setq mode-name "Score") |
| 72 | (lisp-mode-variables nil) | 72 | (lisp-mode-variables nil) |
| 73 | (make-local-variable 'gnus-score-edit-exit-function) | 73 | (make-local-variable 'gnus-score-edit-exit-function) |
| 74 | (run-hooks 'emacs-lisp-mode-hook 'gnus-score-mode-hook)) | 74 | (gnus-run-mode-hooks 'emacs-lisp-mode-hook 'gnus-score-mode-hook)) |
| 75 | 75 | ||
| 76 | (defun gnus-score-make-menu-bar () | 76 | (defun gnus-score-make-menu-bar () |
| 77 | (unless (boundp 'gnus-score-menu) | 77 | (unless (boundp 'gnus-score-menu) |
diff --git a/lisp/gnus/sieve-manage.el b/lisp/gnus/sieve-manage.el index 5b7ef9a99fb..d43808d788a 100644 --- a/lisp/gnus/sieve-manage.el +++ b/lisp/gnus/sieve-manage.el | |||
| @@ -86,22 +86,27 @@ | |||
| 86 | 86 | ||
| 87 | (defcustom sieve-manage-log "*sieve-manage-log*" | 87 | (defcustom sieve-manage-log "*sieve-manage-log*" |
| 88 | "Name of buffer for managesieve session trace." | 88 | "Name of buffer for managesieve session trace." |
| 89 | :type 'string) | 89 | :type 'string |
| 90 | :group 'sieve-manage) | ||
| 90 | 91 | ||
| 91 | (defcustom sieve-manage-default-user (user-login-name) | 92 | (defcustom sieve-manage-default-user (user-login-name) |
| 92 | "Default username to use." | 93 | "Default username to use." |
| 93 | :type 'string) | 94 | :type 'string |
| 95 | :group 'sieve-manage) | ||
| 94 | 96 | ||
| 95 | (defcustom sieve-manage-server-eol "\r\n" | 97 | (defcustom sieve-manage-server-eol "\r\n" |
| 96 | "The EOL string sent from the server." | 98 | "The EOL string sent from the server." |
| 97 | :type 'string) | 99 | :type 'string |
| 100 | :group 'sieve-manage) | ||
| 98 | 101 | ||
| 99 | (defcustom sieve-manage-client-eol "\r\n" | 102 | (defcustom sieve-manage-client-eol "\r\n" |
| 100 | "The EOL string we send to the server." | 103 | "The EOL string we send to the server." |
| 101 | :type 'string) | 104 | :type 'string |
| 105 | :group 'sieve-manage) | ||
| 102 | 106 | ||
| 103 | (defcustom sieve-manage-streams '(network starttls shell) | 107 | (defcustom sieve-manage-streams '(network starttls shell) |
| 104 | "Priority of streams to consider when opening connection to server.") | 108 | "Priority of streams to consider when opening connection to server." |
| 109 | :group 'sieve-manage) | ||
| 105 | 110 | ||
| 106 | (defcustom sieve-manage-stream-alist | 111 | (defcustom sieve-manage-stream-alist |
| 107 | '((network sieve-manage-network-p sieve-manage-network-open) | 112 | '((network sieve-manage-network-p sieve-manage-network-open) |
| @@ -113,10 +118,12 @@ | |||
| 113 | 118 | ||
| 114 | NAME names the stream, CHECK is a function returning non-nil if the | 119 | NAME names the stream, CHECK is a function returning non-nil if the |
| 115 | server support the stream and OPEN is a function for opening the | 120 | server support the stream and OPEN is a function for opening the |
| 116 | stream.") | 121 | stream." |
| 122 | :group 'sieve-manage) | ||
| 117 | 123 | ||
| 118 | (defcustom sieve-manage-authenticators '(cram-md5 plain) | 124 | (defcustom sieve-manage-authenticators '(cram-md5 plain) |
| 119 | "Priority of authenticators to consider when authenticating to server.") | 125 | "Priority of authenticators to consider when authenticating to server." |
| 126 | :group 'sieve-manage) | ||
| 120 | 127 | ||
| 121 | (defcustom sieve-manage-authenticator-alist | 128 | (defcustom sieve-manage-authenticator-alist |
| 122 | '((cram-md5 sieve-manage-cram-md5-p sieve-manage-cram-md5-auth) | 129 | '((cram-md5 sieve-manage-cram-md5-p sieve-manage-cram-md5-auth) |
| @@ -127,11 +134,13 @@ stream.") | |||
| 127 | 134 | ||
| 128 | NAME names the authenticator. CHECK is a function returning non-nil if | 135 | NAME names the authenticator. CHECK is a function returning non-nil if |
| 129 | the server support the authenticator and AUTHENTICATE is a function | 136 | the server support the authenticator and AUTHENTICATE is a function |
| 130 | for doing the actual authentication.") | 137 | for doing the actual authentication." |
| 138 | :group 'sieve-manage) | ||
| 131 | 139 | ||
| 132 | (defcustom sieve-manage-default-port 2000 | 140 | (defcustom sieve-manage-default-port 2000 |
| 133 | "Default port number for managesieve protocol." | 141 | "Default port number for managesieve protocol." |
| 134 | :type 'integer) | 142 | :type 'integer |
| 143 | :group 'sieve-manage) | ||
| 135 | 144 | ||
| 136 | ;; Internal variables: | 145 | ;; Internal variables: |
| 137 | 146 | ||
diff --git a/lisp/gnus/sieve-mode.el b/lisp/gnus/sieve-mode.el index e303e8e70b5..c4d019da6df 100644 --- a/lisp/gnus/sieve-mode.el +++ b/lisp/gnus/sieve-mode.el | |||
| @@ -1,5 +1,5 @@ | |||
| 1 | ;;; sieve-mode.el --- Sieve code editing commands for Emacs | 1 | ;;; sieve-mode.el --- Sieve code editing commands for Emacs |
| 2 | ;; Copyright (C) 2001, 2003 Free Software Foundation, Inc. | 2 | ;; Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc. |
| 3 | 3 | ||
| 4 | ;; Author: Simon Josefsson <simon@josefsson.org> | 4 | ;; Author: Simon Josefsson <simon@josefsson.org> |
| 5 | 5 | ||
| @@ -75,7 +75,8 @@ | |||
| 75 | (((class color) (background light)) (:foreground "Orchid")) | 75 | (((class color) (background light)) (:foreground "Orchid")) |
| 76 | (((class color) (background dark)) (:foreground "LightSteelBlue")) | 76 | (((class color) (background dark)) (:foreground "LightSteelBlue")) |
| 77 | (t (:bold t))) | 77 | (t (:bold t))) |
| 78 | "Face used for Sieve Control Commands.") | 78 | "Face used for Sieve Control Commands." |
| 79 | :group 'sieve) | ||
| 79 | 80 | ||
| 80 | (defvar sieve-action-commands-face 'sieve-action-commands-face | 81 | (defvar sieve-action-commands-face 'sieve-action-commands-face |
| 81 | "Face name used for Sieve Action Commands.") | 82 | "Face name used for Sieve Action Commands.") |
| @@ -85,7 +86,8 @@ | |||
| 85 | (((class color) (background light)) (:foreground "Blue")) | 86 | (((class color) (background light)) (:foreground "Blue")) |
| 86 | (((class color) (background dark)) (:foreground "LightSkyBlue")) | 87 | (((class color) (background dark)) (:foreground "LightSkyBlue")) |
| 87 | (t (:inverse-video t :bold t))) | 88 | (t (:inverse-video t :bold t))) |
| 88 | "Face used for Sieve Action Commands.") | 89 | "Face used for Sieve Action Commands." |
| 90 | :group 'sieve) | ||
| 89 | 91 | ||
| 90 | (defvar sieve-test-commands-face 'sieve-test-commands-face | 92 | (defvar sieve-test-commands-face 'sieve-test-commands-face |
| 91 | "Face name used for Sieve Test Commands.") | 93 | "Face name used for Sieve Test Commands.") |
| @@ -99,7 +101,8 @@ | |||
| 99 | (((class color) (background light)) (:foreground "CadetBlue")) | 101 | (((class color) (background light)) (:foreground "CadetBlue")) |
| 100 | (((class color) (background dark)) (:foreground "Aquamarine")) | 102 | (((class color) (background dark)) (:foreground "Aquamarine")) |
| 101 | (t (:bold t :underline t))) | 103 | (t (:bold t :underline t))) |
| 102 | "Face used for Sieve Test Commands.") | 104 | "Face used for Sieve Test Commands." |
| 105 | :group 'sieve) | ||
| 103 | 106 | ||
| 104 | (defvar sieve-tagged-arguments-face 'sieve-tagged-arguments-face | 107 | (defvar sieve-tagged-arguments-face 'sieve-tagged-arguments-face |
| 105 | "Face name used for Sieve Tagged Arguments.") | 108 | "Face name used for Sieve Tagged Arguments.") |
| @@ -111,7 +114,8 @@ | |||
| 111 | (((class color) (background light)) (:foreground "Purple")) | 114 | (((class color) (background light)) (:foreground "Purple")) |
| 112 | (((class color) (background dark)) (:foreground "Cyan")) | 115 | (((class color) (background dark)) (:foreground "Cyan")) |
| 113 | (t (:bold t))) | 116 | (t (:bold t))) |
| 114 | "Face used for Sieve Tagged Arguments.") | 117 | "Face used for Sieve Tagged Arguments." |
| 118 | :group 'sieve) | ||
| 115 | 119 | ||
| 116 | 120 | ||
| 117 | (defconst sieve-font-lock-keywords | 121 | (defconst sieve-font-lock-keywords |
diff --git a/lisp/gnus/smime.el b/lisp/gnus/smime.el index cd921719045..399c0678c41 100644 --- a/lisp/gnus/smime.el +++ b/lisp/gnus/smime.el | |||
| @@ -122,7 +122,8 @@ | |||
| 122 | (eval-when-compile (require 'cl)) | 122 | (eval-when-compile (require 'cl)) |
| 123 | 123 | ||
| 124 | (defgroup smime nil | 124 | (defgroup smime nil |
| 125 | "S/MIME configuration.") | 125 | "S/MIME configuration." |
| 126 | :group 'mime) | ||
| 126 | 127 | ||
| 127 | (defcustom smime-keys nil | 128 | (defcustom smime-keys nil |
| 128 | "*Map mail addresses to a file containing Certificate (and private key). | 129 | "*Map mail addresses to a file containing Certificate (and private key). |
diff --git a/lisp/gnus/spam-report.el b/lisp/gnus/spam-report.el index 59119dc5438..ded68aba4ed 100644 --- a/lisp/gnus/spam-report.el +++ b/lisp/gnus/spam-report.el | |||
| @@ -1,5 +1,5 @@ | |||
| 1 | ;;; spam-report.el --- Reporting spam | 1 | ;;; spam-report.el --- Reporting spam |
| 2 | ;; Copyright (C) 2002, 2003, 2004 Free Software Foundation, Inc. | 2 | ;; Copyright (C) 2002, 2003, 2004, 2005 Free Software Foundation, Inc. |
| 3 | 3 | ||
| 4 | ;; Author: Teodor Zlatanov <tzz@lifelogs.com> | 4 | ;; Author: Teodor Zlatanov <tzz@lifelogs.com> |
| 5 | ;; Keywords: network | 5 | ;; Keywords: network |
| @@ -35,7 +35,9 @@ | |||
| 35 | (autoload 'mm-url-insert "mm-url")) | 35 | (autoload 'mm-url-insert "mm-url")) |
| 36 | 36 | ||
| 37 | (defgroup spam-report nil | 37 | (defgroup spam-report nil |
| 38 | "Spam reporting configuration.") | 38 | "Spam reporting configuration." |
| 39 | :group 'mail | ||
| 40 | :group 'news) | ||
| 39 | 41 | ||
| 40 | (defcustom spam-report-gmane-regex nil | 42 | (defcustom spam-report-gmane-regex nil |
| 41 | "Regexp matching Gmane newsgroups, e.g. \"^nntp\\+.*:gmane\\.\" | 43 | "Regexp matching Gmane newsgroups, e.g. \"^nntp\\+.*:gmane\\.\" |
| @@ -181,14 +183,14 @@ symbol `ask', query before flushing the queue file." | |||
| 181 | the external program specified in `mm-url-program' to connect to | 183 | the external program specified in `mm-url-program' to connect to |
| 182 | server." | 184 | server." |
| 183 | (with-temp-buffer | 185 | (with-temp-buffer |
| 184 | (let ((url (concat "http://" host report))) | 186 | (let ((url (format "http://%s%s" host report))) |
| 185 | (mm-url-insert url t)))) | 187 | (mm-url-insert url t)))) |
| 186 | 188 | ||
| 187 | ;;;###autoload | 189 | ;;;###autoload |
| 188 | (defun spam-report-url-to-file (host report) | 190 | (defun spam-report-url-to-file (host report) |
| 189 | "Collect spam report requests in `spam-report-requests-file'. | 191 | "Collect spam report requests in `spam-report-requests-file'. |
| 190 | Customize `spam-report-url-ping-function' to use this function." | 192 | Customize `spam-report-url-ping-function' to use this function." |
| 191 | (let ((url (concat "http://" host report)) | 193 | (let ((url (format "http://%s%s" host report)) |
| 192 | (file spam-report-requests-file)) | 194 | (file spam-report-requests-file)) |
| 193 | (gnus-make-directory (file-name-directory file)) | 195 | (gnus-make-directory (file-name-directory file)) |
| 194 | (gnus-message 9 "Writing URL `%s' to file `%s'" url file) | 196 | (gnus-message 9 "Writing URL `%s' to file `%s'" url file) |
diff --git a/lisp/gnus/spam.el b/lisp/gnus/spam.el index e36bf8b26c8..5e73c2deb2e 100644 --- a/lisp/gnus/spam.el +++ b/lisp/gnus/spam.el | |||
| @@ -1,5 +1,5 @@ | |||
| 1 | ;;; spam.el --- Identifying spam | 1 | ;;; spam.el --- Identifying spam |
| 2 | ;; Copyright (C) 2002, 2003, 2004 Free Software Foundation, Inc. | 2 | ;; Copyright (C) 2002, 2003, 2004, 2005 Free Software Foundation, Inc. |
| 3 | 3 | ||
| 4 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> | 4 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> |
| 5 | ;; Keywords: network | 5 | ;; Keywords: network |
| @@ -77,7 +77,9 @@ | |||
| 77 | 77 | ||
| 78 | (defgroup spam nil | 78 | (defgroup spam nil |
| 79 | "Spam configuration." | 79 | "Spam configuration." |
| 80 | :version "22.1") | 80 | :version "22.1" |
| 81 | :group 'mail | ||
| 82 | :group 'news) | ||
| 81 | 83 | ||
| 82 | (defcustom spam-directory (nnheader-concat gnus-directory "spam/") | 84 | (defcustom spam-directory (nnheader-concat gnus-directory "spam/") |
| 83 | "Directory for spam whitelists and blacklists." | 85 | "Directory for spam whitelists and blacklists." |
| @@ -308,7 +310,8 @@ All unmarked article in such group receive the spam mark on group entry." | |||
| 308 | (((class color) (background light)) | 310 | (((class color) (background light)) |
| 309 | (:foreground "ivory4")) | 311 | (:foreground "ivory4")) |
| 310 | (t :inverse-video t)) | 312 | (t :inverse-video t)) |
| 311 | "Face for spam-marked articles.") | 313 | "Face for spam-marked articles." |
| 314 | :group 'spam) | ||
| 312 | 315 | ||
| 313 | (defcustom spam-face 'spam-face | 316 | (defcustom spam-face 'spam-face |
| 314 | "Face for spam-marked articles." | 317 | "Face for spam-marked articles." |
diff --git a/lisp/gnus/starttls.el b/lisp/gnus/starttls.el index f2b72fbef1c..ddc91d90d25 100644 --- a/lisp/gnus/starttls.el +++ b/lisp/gnus/starttls.el | |||
| @@ -1,6 +1,7 @@ | |||
| 1 | ;;; starttls.el --- STARTTLS functions | 1 | ;;; starttls.el --- STARTTLS functions |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1999, 2000, 2003, 2004 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 1999, 2000, 2003, 2004, 2005 |
| 4 | ;; Free Software Foundation, Inc. | ||
| 4 | 5 | ||
| 5 | ;; Author: Daiki Ueno <ueno@unixuser.org> | 6 | ;; Author: Daiki Ueno <ueno@unixuser.org> |
| 6 | ;; Author: Simon Josefsson <simon@josefsson.org> | 7 | ;; Author: Simon Josefsson <simon@josefsson.org> |
| @@ -235,6 +236,13 @@ handshake, or NIL on failure." | |||
| 235 | (starttls-negotiate-gnutls process) | 236 | (starttls-negotiate-gnutls process) |
| 236 | (signal-process (process-id process) 'SIGALRM))) | 237 | (signal-process (process-id process) 'SIGALRM))) |
| 237 | 238 | ||
| 239 | (eval-and-compile | ||
| 240 | (if (fboundp 'set-process-query-on-exit-flag) | ||
| 241 | (defalias 'starttls-set-process-query-on-exit-flag | ||
| 242 | 'set-process-query-on-exit-flag) | ||
| 243 | (defalias 'starttls-set-process-query-on-exit-flag | ||
| 244 | 'process-kill-without-query))) | ||
| 245 | |||
| 238 | (defun starttls-open-stream-gnutls (name buffer host service) | 246 | (defun starttls-open-stream-gnutls (name buffer host service) |
| 239 | (message "Opening STARTTLS connection to `%s'..." host) | 247 | (message "Opening STARTTLS connection to `%s'..." host) |
| 240 | (let* (done | 248 | (let* (done |
| @@ -246,7 +254,7 @@ handshake, or NIL on failure." | |||
| 246 | (int-to-string service) | 254 | (int-to-string service) |
| 247 | service) | 255 | service) |
| 248 | starttls-extra-arguments))) | 256 | starttls-extra-arguments))) |
| 249 | (process-kill-without-query process) | 257 | (starttls-set-process-query-on-exit-flag process nil) |
| 250 | (while (and (processp process) | 258 | (while (and (processp process) |
| 251 | (eq (process-status process) 'run) | 259 | (eq (process-status process) 'run) |
| 252 | (save-excursion | 260 | (save-excursion |
| @@ -286,7 +294,7 @@ specifying a port number to connect to." | |||
| 286 | name buffer starttls-program | 294 | name buffer starttls-program |
| 287 | host (format "%s" service) | 295 | host (format "%s" service) |
| 288 | starttls-extra-args))) | 296 | starttls-extra-args))) |
| 289 | (process-kill-without-query process) | 297 | (starttls-set-process-query-on-exit-flag process nil) |
| 290 | process))) | 298 | process))) |
| 291 | 299 | ||
| 292 | (provide 'starttls) | 300 | (provide 'starttls) |
diff --git a/lisp/help-fns.el b/lisp/help-fns.el index c11aaf6da76..b5e22bf1855 100644 --- a/lisp/help-fns.el +++ b/lisp/help-fns.el | |||
| @@ -224,7 +224,7 @@ ARGLIST can also be t or a string of the form \"(FUN ARG1 ARG2 ...)\"." | |||
| 224 | ;;; (symbol-file (if (symbolp subr-or-var) subr-or-var | 224 | ;;; (symbol-file (if (symbolp subr-or-var) subr-or-var |
| 225 | ;;; (subr-name subr-or-var)) | 225 | ;;; (subr-name subr-or-var)) |
| 226 | ;;; (if (eq kind 'var) 'defvar 'defun))) | 226 | ;;; (if (eq kind 'var) 'defvar 'defun))) |
| 227 | 227 | ;;;###autoload | |
| 228 | (defun help-C-file-name (subr-or-var kind) | 228 | (defun help-C-file-name (subr-or-var kind) |
| 229 | "Return the name of the C file where SUBR-OR-VAR is defined. | 229 | "Return the name of the C file where SUBR-OR-VAR is defined. |
| 230 | KIND should be `var' for a variable or `subr' for a subroutine." | 230 | KIND should be `var' for a variable or `subr' for a subroutine." |
diff --git a/lisp/help-mode.el b/lisp/help-mode.el index d94f03200dc..1c516930c3b 100644 --- a/lisp/help-mode.el +++ b/lisp/help-mode.el | |||
| @@ -196,7 +196,7 @@ Commands: | |||
| 196 | (view-mode) | 196 | (view-mode) |
| 197 | (make-local-variable 'view-no-disable-on-exit) | 197 | (make-local-variable 'view-no-disable-on-exit) |
| 198 | (setq view-no-disable-on-exit t) | 198 | (setq view-no-disable-on-exit t) |
| 199 | (run-hooks 'help-mode-hook)) | 199 | (run-mode-hooks 'help-mode-hook)) |
| 200 | 200 | ||
| 201 | ;;;###autoload | 201 | ;;;###autoload |
| 202 | (defun help-mode-setup () | 202 | (defun help-mode-setup () |
diff --git a/lisp/hexl.el b/lisp/hexl.el index db6edfa48c1..b67ab7876b4 100644 --- a/lisp/hexl.el +++ b/lisp/hexl.el | |||
| @@ -291,7 +291,7 @@ You can use \\[hexl-find-file] to visit a file in Hexl mode. | |||
| 291 | "hexl-current-address") | 291 | "hexl-current-address") |
| 292 | 292 | ||
| 293 | (if hexl-follow-ascii (hexl-follow-ascii 1))) | 293 | (if hexl-follow-ascii (hexl-follow-ascii 1))) |
| 294 | (run-hooks 'hexl-mode-hook)) | 294 | (run-mode-hooks 'hexl-mode-hook)) |
| 295 | 295 | ||
| 296 | 296 | ||
| 297 | (defun hexl-isearch-search-function () | 297 | (defun hexl-isearch-search-function () |
diff --git a/lisp/ibuffer.el b/lisp/ibuffer.el index 213160b6f37..217696cb4aa 100644 --- a/lisp/ibuffer.el +++ b/lisp/ibuffer.el | |||
| @@ -2511,7 +2511,7 @@ will be inserted before the group at point." | |||
| 2511 | (when ibuffer-default-directory | 2511 | (when ibuffer-default-directory |
| 2512 | (setq default-directory ibuffer-default-directory)) | 2512 | (setq default-directory ibuffer-default-directory)) |
| 2513 | (add-hook 'change-major-mode-hook 'font-lock-defontify nil t) | 2513 | (add-hook 'change-major-mode-hook 'font-lock-defontify nil t) |
| 2514 | (run-hooks 'ibuffer-mode-hook) | 2514 | (run-mode-hooks 'ibuffer-mode-hook) |
| 2515 | ;; called after mode hooks to allow the user to add filters | 2515 | ;; called after mode hooks to allow the user to add filters |
| 2516 | (ibuffer-update-mode-name)) | 2516 | (ibuffer-update-mode-name)) |
| 2517 | 2517 | ||
diff --git a/lisp/ido.el b/lisp/ido.el index 24b8ba34b75..b01e9e35c37 100644 --- a/lisp/ido.el +++ b/lisp/ido.el | |||
| @@ -1646,6 +1646,7 @@ If INITIAL is non-nil, it specifies the initial input string." | |||
| 1646 | (l (ido-make-merged-file-list ido-text-init | 1646 | (l (ido-make-merged-file-list ido-text-init |
| 1647 | (eq ido-use-merged-list 'auto) | 1647 | (eq ido-use-merged-list 'auto) |
| 1648 | (eq ido-try-merged-list 'wide)))) | 1648 | (eq ido-try-merged-list 'wide)))) |
| 1649 | (ido-trace "merged" l) | ||
| 1649 | (cond | 1650 | (cond |
| 1650 | ((not l) | 1651 | ((not l) |
| 1651 | (if (eq ido-try-merged-list 'wide) | 1652 | (if (eq ido-try-merged-list 'wide) |
| @@ -1665,6 +1666,9 @@ If INITIAL is non-nil, it specifies the initial input string." | |||
| 1665 | ido-use-merged-list nil))) | 1666 | ido-use-merged-list nil))) |
| 1666 | ((eq l t) | 1667 | ((eq l t) |
| 1667 | (setq ido-use-merged-list nil)) | 1668 | (setq ido-use-merged-list nil)) |
| 1669 | ((eq l 'input-pending-p) | ||
| 1670 | (setq ido-try-merged-list t | ||
| 1671 | ido-use-merged-list nil)) | ||
| 1668 | (t | 1672 | (t |
| 1669 | (setq ido-pre-merge-state | 1673 | (setq ido-pre-merge-state |
| 1670 | (list ido-text-init ido-current-directory olist oign omat)) | 1674 | (list ido-text-init ido-current-directory olist oign omat)) |
| @@ -2493,10 +2497,10 @@ If no buffer or file exactly matching the prompt exists, maybe create a new one. | |||
| 2493 | (file-directory-p dir) | 2497 | (file-directory-p dir) |
| 2494 | (or (not must-match) | 2498 | (or (not must-match) |
| 2495 | ;; TODO. check for nonreadable and too-big. | 2499 | ;; TODO. check for nonreadable and too-big. |
| 2496 | (ido-set-matches1 | 2500 | (ido-set-matches-1 |
| 2497 | (if (eq ido-cur-item 'file) | 2501 | (if (eq ido-cur-item 'file) |
| 2498 | (ido-make-file-list1 dir) | 2502 | (ido-make-file-list-1 dir) |
| 2499 | (ido-make-dir-list1 dir))))) | 2503 | (ido-make-dir-list-1 dir))))) |
| 2500 | (setq j n) | 2504 | (setq j n) |
| 2501 | (setq dir nil))) | 2505 | (setq dir nil))) |
| 2502 | (if dir | 2506 | (if dir |
| @@ -2786,11 +2790,11 @@ for first matching file." | |||
| 2786 | (ido-directory-too-big nil)) | 2790 | (ido-directory-too-big nil)) |
| 2787 | (cond | 2791 | (cond |
| 2788 | ((eq ido-cur-item 'file) | 2792 | ((eq ido-cur-item 'file) |
| 2789 | (ido-make-file-list1 ido-current-directory)) | 2793 | (ido-make-file-list-1 ido-current-directory)) |
| 2790 | ((eq ido-cur-item 'dir) | 2794 | ((eq ido-cur-item 'dir) |
| 2791 | (ido-make-dir-list1 ido-current-directory)) | 2795 | (ido-make-dir-list-1 ido-current-directory)) |
| 2792 | ((eq ido-cur-item 'buffer) | 2796 | ((eq ido-cur-item 'buffer) |
| 2793 | (ido-make-buffer-list1)) | 2797 | (ido-make-buffer-list-1)) |
| 2794 | ((eq ido-cur-item 'list) | 2798 | ((eq ido-cur-item 'list) |
| 2795 | ido-choice-list) | 2799 | ido-choice-list) |
| 2796 | (t nil)))) | 2800 | (t nil)))) |
| @@ -2908,74 +2912,87 @@ for first matching file." | |||
| 2908 | (setq items (cdr items))) | 2912 | (setq items (cdr items))) |
| 2909 | res)) | 2913 | res)) |
| 2910 | 2914 | ||
| 2911 | (defun ido-make-merged-file-list (text auto wide) | 2915 | |
| 2916 | (defun ido-make-merged-file-list-1 (text auto wide) | ||
| 2912 | (let (res) | 2917 | (let (res) |
| 2913 | (message "Searching for `%s'...." text) | 2918 | (if (and (ido-final-slash text) ido-dir-file-cache) |
| 2914 | (condition-case nil | 2919 | (if wide |
| 2915 | (if (and (ido-final-slash text) ido-dir-file-cache) | 2920 | (setq res (ido-wide-find-dirs-or-files |
| 2916 | (if wide | 2921 | ido-current-directory (substring text 0 -1) ido-enable-prefix t)) |
| 2917 | (setq res (ido-wide-find-dirs-or-files | 2922 | ;; Use list of cached directories |
| 2918 | ido-current-directory (substring text 0 -1) ido-enable-prefix t)) | 2923 | (let ((re (concat (regexp-quote (substring text 0 -1)) "[^/:]*/\\'")) |
| 2919 | ;; Use list of cached directories | 2924 | (dirs ido-dir-file-cache) |
| 2920 | (let ((re (concat (regexp-quote (substring text 0 -1)) "[^/:]*/\\'")) | 2925 | dir b d f) |
| 2921 | (dirs ido-dir-file-cache) | 2926 | (if nil ;; simple |
| 2922 | dir b d f) | 2927 | (while dirs |
| 2923 | (if nil ;; simple | 2928 | (setq dir (car (car dirs)) |
| 2924 | (while dirs | 2929 | dirs (cdr dirs)) |
| 2925 | (setq dir (car (car dirs)) | 2930 | (when (and (string-match re dir) |
| 2926 | dirs (cdr dirs)) | 2931 | (not (ido-ignore-item-p dir ido-ignore-directories-merge)) |
| 2927 | (when (and (string-match re dir) | 2932 | (file-directory-p dir)) |
| 2928 | (not (ido-ignore-item-p dir ido-ignore-directories-merge)) | 2933 | (setq b (substring dir 0 -1) |
| 2929 | (file-directory-p dir)) | 2934 | f (concat (file-name-nondirectory b) "/") |
| 2930 | (setq b (substring dir 0 -1) | 2935 | d (file-name-directory b) |
| 2931 | f (concat (file-name-nondirectory b) "/") | 2936 | res (cons (cons f d) res)))) |
| 2932 | d (file-name-directory b) | ||
| 2933 | res (cons (cons f d) res)))) | ||
| 2934 | (while dirs | ||
| 2935 | (setq dir (car dirs) | ||
| 2936 | d (car dir) | ||
| 2937 | dirs (cdr dirs)) | ||
| 2938 | (when (not (ido-ignore-item-p d ido-ignore-directories-merge)) | ||
| 2939 | (setq dir (cdr (cdr dir))) | ||
| 2940 | (while dir | ||
| 2941 | (setq f (car dir) | ||
| 2942 | dir (cdr dir)) | ||
| 2943 | (if (and (string-match re f) | ||
| 2944 | (not (ido-ignore-item-p f ido-ignore-directories))) | ||
| 2945 | (setq res (cons (cons f d) res))))) | ||
| 2946 | (if (and auto (input-pending-p)) | ||
| 2947 | (setq dirs nil | ||
| 2948 | res t)))))) | ||
| 2949 | (if wide | ||
| 2950 | (setq res (ido-wide-find-dirs-or-files | ||
| 2951 | ido-current-directory text ido-enable-prefix nil)) | ||
| 2952 | (let ((ido-text text) | ||
| 2953 | (dirs ido-work-directory-list) | ||
| 2954 | (must-match (and text (> (length text) 0))) | ||
| 2955 | dir fl) | ||
| 2956 | (if (and auto (not (member ido-current-directory dirs))) | ||
| 2957 | (setq dirs (cons ido-current-directory dirs))) | ||
| 2958 | (while dirs | 2937 | (while dirs |
| 2959 | (setq dir (car dirs) | 2938 | (setq dir (car dirs) |
| 2939 | d (car dir) | ||
| 2960 | dirs (cdr dirs)) | 2940 | dirs (cdr dirs)) |
| 2961 | (when (and dir (stringp dir) | 2941 | (when (not (ido-ignore-item-p d ido-ignore-directories-merge)) |
| 2962 | (or ido-merge-ftp-work-directories | 2942 | (setq dir (cdr (cdr dir))) |
| 2963 | (not (ido-is-ftp-directory dir))) | 2943 | (while dir |
| 2964 | (file-directory-p dir) | 2944 | (setq f (car dir) |
| 2965 | ;; TODO. check for nonreadable and too-big. | 2945 | dir (cdr dir)) |
| 2966 | (setq fl (if (eq ido-cur-item 'file) | 2946 | (if (and (string-match re f) |
| 2967 | (ido-make-file-list1 dir t) | 2947 | (not (ido-ignore-item-p f ido-ignore-directories))) |
| 2968 | (ido-make-dir-list1 dir t)))) | 2948 | (setq res (cons (cons f d) res))))) |
| 2969 | (if must-match | ||
| 2970 | (setq fl (ido-set-matches1 fl))) | ||
| 2971 | (if fl | ||
| 2972 | (setq res (nconc fl res)))) | ||
| 2973 | (if (and auto (input-pending-p)) | 2949 | (if (and auto (input-pending-p)) |
| 2974 | (setq dirs nil | 2950 | (setq dirs nil |
| 2975 | res t)))))) | 2951 | res t)))))) |
| 2976 | (quit (setq res t))) | 2952 | (if wide |
| 2977 | (if (and res (not (eq res t))) | 2953 | (setq res (ido-wide-find-dirs-or-files |
| 2978 | (setq res (ido-sort-merged-list res auto))) | 2954 | ido-current-directory text ido-enable-prefix nil)) |
| 2955 | (let ((ido-text text) | ||
| 2956 | (dirs ido-work-directory-list) | ||
| 2957 | (must-match (and text (> (length text) 0))) | ||
| 2958 | dir fl) | ||
| 2959 | (if (and auto (not (member ido-current-directory dirs))) | ||
| 2960 | (setq dirs (cons ido-current-directory dirs))) | ||
| 2961 | (while dirs | ||
| 2962 | (setq dir (car dirs) | ||
| 2963 | dirs (cdr dirs)) | ||
| 2964 | (when (and dir (stringp dir) | ||
| 2965 | (or ido-merge-ftp-work-directories | ||
| 2966 | (not (ido-is-ftp-directory dir))) | ||
| 2967 | (file-directory-p dir) | ||
| 2968 | ;; TODO. check for nonreadable and too-big. | ||
| 2969 | (setq fl (if (eq ido-cur-item 'file) | ||
| 2970 | (ido-make-file-list-1 dir t) | ||
| 2971 | (ido-make-dir-list-1 dir t)))) | ||
| 2972 | (if must-match | ||
| 2973 | (setq fl (ido-set-matches-1 fl))) | ||
| 2974 | (if fl | ||
| 2975 | (setq res (nconc fl res)))) | ||
| 2976 | (if (and auto (input-pending-p)) | ||
| 2977 | (setq dirs nil | ||
| 2978 | res t)))))) | ||
| 2979 | res)) | ||
| 2980 | |||
| 2981 | (defun ido-make-merged-file-list (text auto wide) | ||
| 2982 | (let (res) | ||
| 2983 | (message "Searching for `%s'...." text) | ||
| 2984 | (condition-case nil | ||
| 2985 | (unless (catch 'input-pending-p | ||
| 2986 | (let ((throw-on-input 'input-pending-p)) | ||
| 2987 | (setq res (ido-make-merged-file-list-1 text auto wide)) | ||
| 2988 | t)) | ||
| 2989 | (setq res 'input-pending-p)) | ||
| 2990 | (quit | ||
| 2991 | (setq res t | ||
| 2992 | ido-try-merged-list nil | ||
| 2993 | ido-use-merged-list nil))) | ||
| 2994 | (when (and res (listp res)) | ||
| 2995 | (setq res (ido-sort-merged-list res auto))) | ||
| 2979 | (when (and (or ido-rotate-temp ido-rotate-file-list-default) | 2996 | (when (and (or ido-rotate-temp ido-rotate-file-list-default) |
| 2980 | (listp res) | 2997 | (listp res) |
| 2981 | (> (length text) 0)) | 2998 | (> (length text) 0)) |
| @@ -2986,7 +3003,7 @@ for first matching file." | |||
| 2986 | (message nil) | 3003 | (message nil) |
| 2987 | res)) | 3004 | res)) |
| 2988 | 3005 | ||
| 2989 | (defun ido-make-buffer-list1 (&optional frame visible) | 3006 | (defun ido-make-buffer-list-1 (&optional frame visible) |
| 2990 | ;; Return list of non-ignored buffer names | 3007 | ;; Return list of non-ignored buffer names |
| 2991 | (delq nil | 3008 | (delq nil |
| 2992 | (mapcar | 3009 | (mapcar |
| @@ -3004,7 +3021,7 @@ for first matching file." | |||
| 3004 | ;; in this list. If DEFAULT is non-nil, and corresponds to an existing buffer, | 3021 | ;; in this list. If DEFAULT is non-nil, and corresponds to an existing buffer, |
| 3005 | ;; it is put to the start of the list. | 3022 | ;; it is put to the start of the list. |
| 3006 | (let* ((ido-current-buffers (ido-get-buffers-in-frames 'current)) | 3023 | (let* ((ido-current-buffers (ido-get-buffers-in-frames 'current)) |
| 3007 | (ido-temp-list (ido-make-buffer-list1 (selected-frame) ido-current-buffers))) | 3024 | (ido-temp-list (ido-make-buffer-list-1 (selected-frame) ido-current-buffers))) |
| 3008 | (if ido-temp-list | 3025 | (if ido-temp-list |
| 3009 | (nconc ido-temp-list ido-current-buffers) | 3026 | (nconc ido-temp-list ido-current-buffers) |
| 3010 | (setq ido-temp-list ido-current-buffers)) | 3027 | (setq ido-temp-list ido-current-buffers)) |
| @@ -3041,7 +3058,7 @@ for first matching file." | |||
| 3041 | (nconc ido-temp-list items) | 3058 | (nconc ido-temp-list items) |
| 3042 | (setq ido-temp-list items))) | 3059 | (setq ido-temp-list items))) |
| 3043 | 3060 | ||
| 3044 | (defun ido-file-name-all-completions1 (dir) | 3061 | (defun ido-file-name-all-completions-1 (dir) |
| 3045 | (cond | 3062 | (cond |
| 3046 | ((ido-nonreadable-directory-p dir) '()) | 3063 | ((ido-nonreadable-directory-p dir) '()) |
| 3047 | ;; do not check (ido-directory-too-big-p dir) here. | 3064 | ;; do not check (ido-directory-too-big-p dir) here. |
| @@ -3098,13 +3115,13 @@ for first matching file." | |||
| 3098 | (if (and ftp (file-readable-p dir)) | 3115 | (if (and ftp (file-readable-p dir)) |
| 3099 | (setq mtime (cons 'ftp (ido-time-stamp)))) | 3116 | (setq mtime (cons 'ftp (ido-time-stamp)))) |
| 3100 | (if mtime | 3117 | (if mtime |
| 3101 | (setq cached (cons dir (cons mtime (ido-file-name-all-completions1 dir))) | 3118 | (setq cached (cons dir (cons mtime (ido-file-name-all-completions-1 dir))) |
| 3102 | ido-dir-file-cache (cons cached ido-dir-file-cache))) | 3119 | ido-dir-file-cache (cons cached ido-dir-file-cache))) |
| 3103 | (if (> (length ido-dir-file-cache) ido-max-dir-file-cache) | 3120 | (if (> (length ido-dir-file-cache) ido-max-dir-file-cache) |
| 3104 | (setcdr (nthcdr (1- ido-max-dir-file-cache) ido-dir-file-cache) nil))) | 3121 | (setcdr (nthcdr (1- ido-max-dir-file-cache) ido-dir-file-cache) nil))) |
| 3105 | (and cached | 3122 | (and cached |
| 3106 | (cdr (cdr cached)))) | 3123 | (cdr (cdr cached)))) |
| 3107 | (ido-file-name-all-completions1 dir))) | 3124 | (ido-file-name-all-completions-1 dir))) |
| 3108 | 3125 | ||
| 3109 | (defun ido-remove-cached-dir (dir) | 3126 | (defun ido-remove-cached-dir (dir) |
| 3110 | ;; Remove dir from ido-dir-file-cache | 3127 | ;; Remove dir from ido-dir-file-cache |
| @@ -3115,7 +3132,7 @@ for first matching file." | |||
| 3115 | (setq ido-dir-file-cache (delq cached ido-dir-file-cache)))))) | 3132 | (setq ido-dir-file-cache (delq cached ido-dir-file-cache)))))) |
| 3116 | 3133 | ||
| 3117 | 3134 | ||
| 3118 | (defun ido-make-file-list1 (dir &optional merged) | 3135 | (defun ido-make-file-list-1 (dir &optional merged) |
| 3119 | ;; Return list of non-ignored files in DIR | 3136 | ;; Return list of non-ignored files in DIR |
| 3120 | ;; If MERGED is non-nil, each file is cons'ed with DIR | 3137 | ;; If MERGED is non-nil, each file is cons'ed with DIR |
| 3121 | (and (or (ido-is-tramp-root dir) (file-directory-p dir)) | 3138 | (and (or (ido-is-tramp-root dir) (file-directory-p dir)) |
| @@ -3132,7 +3149,7 @@ for first matching file." | |||
| 3132 | ;; The hook `ido-make-file-list-hook' is run after the list has been | 3149 | ;; The hook `ido-make-file-list-hook' is run after the list has been |
| 3133 | ;; created to allow the user to further modify the order of the file names | 3150 | ;; created to allow the user to further modify the order of the file names |
| 3134 | ;; in this list. | 3151 | ;; in this list. |
| 3135 | (let ((ido-temp-list (ido-make-file-list1 ido-current-directory))) | 3152 | (let ((ido-temp-list (ido-make-file-list-1 ido-current-directory))) |
| 3136 | (setq ido-temp-list (sort ido-temp-list | 3153 | (setq ido-temp-list (sort ido-temp-list |
| 3137 | (if ido-file-extensions-order | 3154 | (if ido-file-extensions-order |
| 3138 | #'ido-file-extension-lessp | 3155 | #'ido-file-extension-lessp |
| @@ -3168,7 +3185,7 @@ for first matching file." | |||
| 3168 | (run-hooks 'ido-make-file-list-hook) | 3185 | (run-hooks 'ido-make-file-list-hook) |
| 3169 | ido-temp-list)) | 3186 | ido-temp-list)) |
| 3170 | 3187 | ||
| 3171 | (defun ido-make-dir-list1 (dir &optional merged) | 3188 | (defun ido-make-dir-list-1 (dir &optional merged) |
| 3172 | ;; Return list of non-ignored subdirs in DIR | 3189 | ;; Return list of non-ignored subdirs in DIR |
| 3173 | ;; If MERGED is non-nil, each subdir is cons'ed with DIR | 3190 | ;; If MERGED is non-nil, each subdir is cons'ed with DIR |
| 3174 | (and (or (ido-is-tramp-root dir) (file-directory-p dir)) | 3191 | (and (or (ido-is-tramp-root dir) (file-directory-p dir)) |
| @@ -3184,7 +3201,7 @@ for first matching file." | |||
| 3184 | ;; The hook `ido-make-dir-list-hook' is run after the list has been | 3201 | ;; The hook `ido-make-dir-list-hook' is run after the list has been |
| 3185 | ;; created to allow the user to further modify the order of the | 3202 | ;; created to allow the user to further modify the order of the |
| 3186 | ;; directory names in this list. | 3203 | ;; directory names in this list. |
| 3187 | (let ((ido-temp-list (ido-make-dir-list1 ido-current-directory))) | 3204 | (let ((ido-temp-list (ido-make-dir-list-1 ido-current-directory))) |
| 3188 | (setq ido-temp-list (sort ido-temp-list #'ido-file-lessp)) | 3205 | (setq ido-temp-list (sort ido-temp-list #'ido-file-lessp)) |
| 3189 | (ido-to-end ;; move . files to end | 3206 | (ido-to-end ;; move . files to end |
| 3190 | (delq nil (mapcar | 3207 | (delq nil (mapcar |
| @@ -3238,7 +3255,7 @@ for first matching file." | |||
| 3238 | 3255 | ||
| 3239 | ;;; FIND MATCHING ITEMS | 3256 | ;;; FIND MATCHING ITEMS |
| 3240 | 3257 | ||
| 3241 | (defun ido-set-matches1 (items &optional do-full) | 3258 | (defun ido-set-matches-1 (items &optional do-full) |
| 3242 | ;; Return list of matches in items | 3259 | ;; Return list of matches in items |
| 3243 | (let* ((case-fold-search ido-case-fold) | 3260 | (let* ((case-fold-search ido-case-fold) |
| 3244 | (slash (and (not ido-enable-prefix) (ido-final-slash ido-text))) | 3261 | (slash (and (not ido-enable-prefix) (ido-final-slash ido-text))) |
| @@ -3296,7 +3313,7 @@ for first matching file." | |||
| 3296 | (defun ido-set-matches () | 3313 | (defun ido-set-matches () |
| 3297 | ;; Set `ido-matches' to the list of items matching prompt | 3314 | ;; Set `ido-matches' to the list of items matching prompt |
| 3298 | (when ido-rescan | 3315 | (when ido-rescan |
| 3299 | (setq ido-matches (ido-set-matches1 (reverse ido-cur-list) (not ido-rotate)) | 3316 | (setq ido-matches (ido-set-matches-1 (reverse ido-cur-list) (not ido-rotate)) |
| 3300 | ido-rotate nil))) | 3317 | ido-rotate nil))) |
| 3301 | 3318 | ||
| 3302 | (defun ido-ignore-item-p (name re-list &optional ignore-ext) | 3319 | (defun ido-ignore-item-p (name re-list &optional ignore-ext) |
diff --git a/lisp/ielm.el b/lisp/ielm.el index 65654ca2c7a..5a91361f2d2 100644 --- a/lisp/ielm.el +++ b/lisp/ielm.el | |||
| @@ -480,7 +480,8 @@ The behaviour of IELM may be customized with the following variables: | |||
| 480 | Customized bindings may be defined in `ielm-map', which currently contains: | 480 | Customized bindings may be defined in `ielm-map', which currently contains: |
| 481 | \\{ielm-map}" | 481 | \\{ielm-map}" |
| 482 | (interactive) | 482 | (interactive) |
| 483 | (comint-mode) | 483 | (delay-mode-hooks |
| 484 | (comint-mode)) | ||
| 484 | (setq comint-prompt-regexp (concat "^" (regexp-quote ielm-prompt))) | 485 | (setq comint-prompt-regexp (concat "^" (regexp-quote ielm-prompt))) |
| 485 | (set (make-local-variable 'paragraph-separate) "\\'") | 486 | (set (make-local-variable 'paragraph-separate) "\\'") |
| 486 | (make-local-variable 'paragraph-start) | 487 | (make-local-variable 'paragraph-start) |
| @@ -548,7 +549,7 @@ Customized bindings may be defined in `ielm-map', which currently contains: | |||
| 548 | (set-marker comint-last-input-start (ielm-pm)) | 549 | (set-marker comint-last-input-start (ielm-pm)) |
| 549 | (set-process-filter (get-buffer-process (current-buffer)) 'comint-output-filter)) | 550 | (set-process-filter (get-buffer-process (current-buffer)) 'comint-output-filter)) |
| 550 | 551 | ||
| 551 | (run-hooks 'ielm-mode-hook)) | 552 | (run-mode-hooks 'ielm-mode-hook)) |
| 552 | 553 | ||
| 553 | (defun ielm-get-old-input nil | 554 | (defun ielm-get-old-input nil |
| 554 | ;; Return the previous input surrounding point | 555 | ;; Return the previous input surrounding point |
diff --git a/lisp/image.el b/lisp/image.el index ced73c8fb3a..b7b2d9988a8 100644 --- a/lisp/image.el +++ b/lisp/image.el | |||
| @@ -48,20 +48,6 @@ IMAGE-TYPE must be a pair (PREDICATE . TYPE). PREDICATE is called | |||
| 48 | with one argument, a string containing the image data. If PREDICATE returns | 48 | with one argument, a string containing the image data. If PREDICATE returns |
| 49 | a non-nil value, TYPE is the image's type.") | 49 | a non-nil value, TYPE is the image's type.") |
| 50 | 50 | ||
| 51 | ;;;###autoload | ||
| 52 | (defvar image-library-alist nil | ||
| 53 | "Alist of image types vs external libraries needed to display them. | ||
| 54 | |||
| 55 | Each element is a list (IMAGE-TYPE LIBRARY...), where the car is a symbol | ||
| 56 | representing a supported image type, and the rest are strings giving | ||
| 57 | alternate filenames for the corresponding external libraries. | ||
| 58 | |||
| 59 | Emacs tries to load the libraries in the order they appear on the | ||
| 60 | list; if none is loaded, the running session of Emacs won't | ||
| 61 | support the image type. Types 'pbm and 'xbm don't need to be | ||
| 62 | listed; they're always supported.") | ||
| 63 | ;;;###autoload (put 'image-library-alist 'risky-local-variable t) | ||
| 64 | |||
| 65 | (defun image-jpeg-p (data) | 51 | (defun image-jpeg-p (data) |
| 66 | "Value is non-nil if DATA, a string, consists of JFIF image data. | 52 | "Value is non-nil if DATA, a string, consists of JFIF image data. |
| 67 | We accept the tag Exif because that is the same format." | 53 | We accept the tag Exif because that is the same format." |
| @@ -122,7 +108,7 @@ be determined." | |||
| 122 | 108 | ||
| 123 | ;;;###autoload | 109 | ;;;###autoload |
| 124 | (defun image-type-available-p (type) | 110 | (defun image-type-available-p (type) |
| 125 | "Value is non-nil if image type TYPE is available. | 111 | "Return non-nil if image type TYPE is available. |
| 126 | Image types are symbols like `xbm' or `jpeg'." | 112 | Image types are symbols like `xbm' or `jpeg'." |
| 127 | (and (fboundp 'init-image-library) | 113 | (and (fboundp 'init-image-library) |
| 128 | (init-image-library type image-library-alist))) | 114 | (init-image-library type image-library-alist))) |
diff --git a/lisp/info.el b/lisp/info.el index cfb44cb18f1..c36554e6a7a 100644 --- a/lisp/info.el +++ b/lisp/info.el | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | ;;; info.el --- info package for Emacs | 1 | ;;; info.el --- info package for Emacs |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1985,86,92,93,94,95,96,97,98,99,2000,01,02,03,04,2005 | 3 | ;; Copyright (C) 1985, 1986, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, |
| 4 | ;; Free Software Foundation, Inc. | 4 | ;; 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. |
| 5 | 5 | ||
| 6 | ;; Maintainer: FSF | 6 | ;; Maintainer: FSF |
| 7 | ;; Keywords: help | 7 | ;; Keywords: help |
| @@ -515,9 +515,10 @@ in all the directories in that path." | |||
| 515 | ;; since the argument will then be parsed improperly. This also | 515 | ;; since the argument will then be parsed improperly. This also |
| 516 | ;; has the added benefit of allowing node names to be included | 516 | ;; has the added benefit of allowing node names to be included |
| 517 | ;; following the parenthesized filename. | 517 | ;; following the parenthesized filename. |
| 518 | (if (and (stringp file) (string-match "(.*)" file)) | 518 | (Info-goto-node |
| 519 | (Info-goto-node file) | 519 | (if (and (stringp file) (string-match "(.*)" file)) |
| 520 | (Info-goto-node (concat "(" file ")"))) | 520 | file |
| 521 | (concat "(" file ")"))) | ||
| 521 | (if (zerop (buffer-size)) | 522 | (if (zerop (buffer-size)) |
| 522 | (Info-directory)))) | 523 | (Info-directory)))) |
| 523 | 524 | ||
| @@ -1344,7 +1345,9 @@ any double quotes or backslashes must be escaped (\\\",\\\\)." | |||
| 1344 | ;; Go to an info node specified with a filename-and-nodename string | 1345 | ;; Go to an info node specified with a filename-and-nodename string |
| 1345 | ;; of the sort that is found in pointers in nodes. | 1346 | ;; of the sort that is found in pointers in nodes. |
| 1346 | 1347 | ||
| 1347 | ;;;###autoload | 1348 | ;; Don't autoload this function: the correct entry point for other packages |
| 1349 | ;; to use is `info'. --Stef | ||
| 1350 | ;; ;;;###autoload | ||
| 1348 | (defun Info-goto-node (nodename &optional fork) | 1351 | (defun Info-goto-node (nodename &optional fork) |
| 1349 | "Go to info node named NODENAME. Give just NODENAME or (FILENAME)NODENAME. | 1352 | "Go to info node named NODENAME. Give just NODENAME or (FILENAME)NODENAME. |
| 1350 | If NODENAME is of the form (FILENAME)NODENAME, the node is in the Info file | 1353 | If NODENAME is of the form (FILENAME)NODENAME, the node is in the Info file |
| @@ -3259,7 +3262,7 @@ Advanced commands: | |||
| 3259 | (set (make-local-variable 'search-whitespace-regexp) | 3262 | (set (make-local-variable 'search-whitespace-regexp) |
| 3260 | Info-search-whitespace-regexp) | 3263 | Info-search-whitespace-regexp) |
| 3261 | (Info-set-mode-line) | 3264 | (Info-set-mode-line) |
| 3262 | (run-hooks 'Info-mode-hook)) | 3265 | (run-mode-hooks 'Info-mode-hook)) |
| 3263 | 3266 | ||
| 3264 | ;; When an Info buffer is killed, make sure the associated tags buffer | 3267 | ;; When an Info buffer is killed, make sure the associated tags buffer |
| 3265 | ;; is killed too. | 3268 | ;; is killed too. |
| @@ -3301,7 +3304,7 @@ which returns to Info mode for browsing. | |||
| 3301 | (setq buffer-read-only nil) | 3304 | (setq buffer-read-only nil) |
| 3302 | (force-mode-line-update) | 3305 | (force-mode-line-update) |
| 3303 | (buffer-enable-undo (current-buffer)) | 3306 | (buffer-enable-undo (current-buffer)) |
| 3304 | (run-hooks 'Info-edit-mode-hook)) | 3307 | (run-mode-hooks 'Info-edit-mode-hook)) |
| 3305 | 3308 | ||
| 3306 | (defun Info-edit () | 3309 | (defun Info-edit () |
| 3307 | "Edit the contents of this Info node. | 3310 | "Edit the contents of this Info node. |
| @@ -4127,5 +4130,5 @@ BUFFER is the buffer speedbar is requesting buttons for." | |||
| 4127 | 4130 | ||
| 4128 | (provide 'info) | 4131 | (provide 'info) |
| 4129 | 4132 | ||
| 4130 | ;;; arch-tag: f2480fe2-2139-40c1-a49b-6314991164ac | 4133 | ;; arch-tag: f2480fe2-2139-40c1-a49b-6314991164ac |
| 4131 | ;;; info.el ends here | 4134 | ;;; info.el ends here |
diff --git a/lisp/international/latexenc.el b/lisp/international/latexenc.el index 88da8ffed79..24f7ebc6000 100644 --- a/lisp/international/latexenc.el +++ b/lisp/international/latexenc.el | |||
| @@ -130,46 +130,49 @@ coding system names is determined from `latex-inputenc-coding-alist'." | |||
| 130 | (throw 'cs t) | 130 | (throw 'cs t) |
| 131 | (goto-char (match-end 0)))))) | 131 | (goto-char (match-end 0)))))) |
| 132 | (let* ((match (match-string 1)) | 132 | (let* ((match (match-string 1)) |
| 133 | (sym (intern match))) | 133 | (sym (or (latexenc-inputenc-to-coding-system match) |
| 134 | (when (latexenc-inputenc-to-coding-system match) | 134 | (intern match)))) |
| 135 | (setq sym (latexenc-inputenc-to-coding-system match))) | 135 | (cond |
| 136 | (when (coding-system-p sym) | 136 | ((coding-system-p sym) sym) |
| 137 | sym | 137 | ((and (require 'code-pages nil t) (coding-system-p sym)) sym) |
| 138 | (if (and (require 'code-pages nil t) (coding-system-p sym)) | 138 | (t 'undecided))) |
| 139 | sym | ||
| 140 | 'undecided))) | ||
| 141 | ;; else try to find it in the master/main file | 139 | ;; else try to find it in the master/main file |
| 142 | (let (latexenc-main-file) | 140 | (let ((default-directory (file-name-directory (nth 1 arg-list))) |
| 143 | ;; is there a TeX-master or tex-main-file in the local variable section | 141 | latexenc-main-file) |
| 142 | ;; Is there a TeX-master or tex-main-file in the local variables | ||
| 143 | ;; section? | ||
| 144 | (unless latexenc-dont-use-TeX-master-flag | 144 | (unless latexenc-dont-use-TeX-master-flag |
| 145 | (goto-char (point-max)) | 145 | (goto-char (point-max)) |
| 146 | (search-backward "\n\^L" (max (- (point-max) 3000) (point-min)) 'move) | 146 | (search-backward "\n\^L" (max (- (point-max) 3000) (point-min)) |
| 147 | 'move) | ||
| 147 | (search-forward "Local Variables:" nil t) | 148 | (search-forward "Local Variables:" nil t) |
| 148 | (when (re-search-forward "^%+ *\\(TeX-master\\|tex-main-file\\): *\"\\(.+\\)\"" nil t) | 149 | (when (re-search-forward |
| 149 | (let ((file (concat (file-name-directory (nth 1 arg-list)) (match-string 2)))) | 150 | "^%+ *\\(TeX-master\\|tex-main-file\\): *\"\\(.+\\)\"" |
| 150 | (if (file-exists-p file) | 151 | nil t) |
| 151 | (setq latexenc-main-file file) | 152 | (let ((file (match-string 2))) |
| 152 | (if (boundp 'TeX-default-extension) | 153 | (dolist (ext `("" ,(if (boundp 'TeX-default-extension) |
| 153 | (when (file-exists-p (concat file "." TeX-default-extension)) | 154 | (concat "." TeX-default-extension) |
| 154 | (setq latexenc-main-file (concat file "." TeX-default-extension))) | 155 | "") |
| 155 | (dolist (ext '("drv" "dtx" "ltx" "tex")) | 156 | ".tex" ".ltx" ".dtx" ".drv")) |
| 156 | (if (file-exists-p (concat file "." ext)) | 157 | (if (and (null latexenc-main-file) ;Stop at first. |
| 157 | (setq latexenc-main-file (concat file "." ext))))))))) | 158 | (file-exists-p (concat file ext))) |
| 159 | (setq latexenc-main-file (concat file ext))))))) | ||
| 158 | ;; try tex-modes tex-guess-main-file | 160 | ;; try tex-modes tex-guess-main-file |
| 159 | (when (and (not latexenc-dont-use-tex-guess-main-file-flag) | 161 | (when (and (not latexenc-dont-use-tex-guess-main-file-flag) |
| 160 | (not latexenc-main-file)) | 162 | (not latexenc-main-file) |
| 161 | (when (fboundp 'tex-guess-main-file) | 163 | (fboundp 'tex-guess-main-file)) |
| 162 | (let ((tex-start-of-header "\\\\document\\(style\\|class\\)") | 164 | (let ((tex-start-of-header "\\\\document\\(style\\|class\\)")) |
| 163 | (default-directory (file-name-directory (nth 1 arg-list)))) | 165 | (setq latexenc-main-file (tex-guess-main-file)))) |
| 164 | (setq latexenc-main-file (tex-guess-main-file))))) | ||
| 165 | ;; if we found a master/main file get the coding system from it | 166 | ;; if we found a master/main file get the coding system from it |
| 166 | (if (and latexenc-main-file | 167 | (if (and latexenc-main-file |
| 167 | (file-readable-p latexenc-main-file)) | 168 | (file-readable-p latexenc-main-file)) |
| 168 | (let* ((latexenc-dont-use-tex-guess-main-file-flag t) | 169 | (let* ((latexenc-dont-use-tex-guess-main-file-flag t) |
| 169 | (latexenc-dont-use-TeX-master-flag t) | 170 | (latexenc-dont-use-TeX-master-flag t) |
| 170 | (latexenc-main-buffer (find-file-noselect latexenc-main-file t))) | 171 | (latexenc-main-buffer |
| 171 | (or (buffer-local-value 'coding-system-for-write latexenc-main-buffer) | 172 | (find-file-noselect latexenc-main-file t))) |
| 172 | (buffer-local-value 'buffer-file-coding-system latexenc-main-buffer))) | 173 | (coding-system-base ;Disregard the EOL part of the CS. |
| 174 | (with-current-buffer latexenc-main-buffer | ||
| 175 | (or coding-system-for-write buffer-file-coding-system)))) | ||
| 173 | 'undecided)))) | 176 | 'undecided)))) |
| 174 | 'undecided)) | 177 | 'undecided)) |
| 175 | 178 | ||
diff --git a/lisp/international/swedish.el b/lisp/international/swedish.el index bf9fce5de65..783fe2400e9 100644 --- a/lisp/international/swedish.el +++ b/lisp/international/swedish.el | |||
| @@ -133,7 +133,7 @@ Leaves point just after the word that looks Swedish." | |||
| 133 | ; (setq major-mode 'swedish-mode) | 133 | ; (setq major-mode 'swedish-mode) |
| 134 | ; (setq local-abbrev-table swedish-mode-abbrev-table) | 134 | ; (setq local-abbrev-table swedish-mode-abbrev-table) |
| 135 | ; (set-syntax-table text-mode-syntax-table) | 135 | ; (set-syntax-table text-mode-syntax-table) |
| 136 | ; (run-hooks 'text-mode-hook)) | 136 | ; (run-mode-hooks 'text-mode-hook)) |
| 137 | 137 | ||
| 138 | ;(defun indented-swedish-mode () | 138 | ;(defun indented-swedish-mode () |
| 139 | ; "Major mode for editing indented Swedish text intended for | 139 | ; "Major mode for editing indented Swedish text intended for |
| @@ -151,7 +151,7 @@ Leaves point just after the word that looks Swedish." | |||
| 151 | ; (use-local-map indented-text-mode-map) | 151 | ; (use-local-map indented-text-mode-map) |
| 152 | ; (setq mode-name "Indented Swedish") | 152 | ; (setq mode-name "Indented Swedish") |
| 153 | ; (setq major-mode 'indented-swedish-mode) | 153 | ; (setq major-mode 'indented-swedish-mode) |
| 154 | ; (run-hooks 'text-mode-hook)) | 154 | ; (run-mode-hooks 'text-mode-hook)) |
| 155 | 155 | ||
| 156 | (provide 'swedish) | 156 | (provide 'swedish) |
| 157 | 157 | ||
diff --git a/lisp/iswitchb.el b/lisp/iswitchb.el index 52915c46950..2943be851a0 100644 --- a/lisp/iswitchb.el +++ b/lisp/iswitchb.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; iswitchb.el --- switch between buffers using substrings | 1 | ;;; iswitchb.el --- switch between buffers using substrings |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1996, 1997, 2000, 2001, 2003 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Stephen Eglen <stephen@gnu.org> | 5 | ;; Author: Stephen Eglen <stephen@gnu.org> |
| 6 | ;; Maintainer: Stephen Eglen <stephen@gnu.org> | 6 | ;; Maintainer: Stephen Eglen <stephen@gnu.org> |
| @@ -165,11 +165,10 @@ | |||
| 165 | 165 | ||
| 166 | ;; Font-Lock | 166 | ;; Font-Lock |
| 167 | 167 | ||
| 168 | ;; If you have font-lock loaded, the first matching buffer is | 168 | ;; font-lock is used to highlight the first matching buffer. To |
| 169 | ;; highlighted. To switch this off, set (setq iswitchb-use-fonts nil) | 169 | ;; switch this off, set (setq iswitchb-use-faces nil). Colouring of |
| 170 | ;; I don't use font-lock that much, so I've hardcoded the faces. If | 170 | ;; the matching buffer name was suggested by Carsten Dominik |
| 171 | ;; this is too harsh, let me know. Colouring of the matching buffer | 171 | ;; (dominik@strw.leidenuniv.nl) |
| 172 | ;; name was suggested by Carsten Dominik (dominik@strw.leidenuniv.nl) | ||
| 173 | 172 | ||
| 174 | ;; Replacement for read-buffer | 173 | ;; Replacement for read-buffer |
| 175 | 174 | ||
| @@ -230,16 +229,10 @@ | |||
| 230 | 229 | ||
| 231 | ;; Regexp matching | 230 | ;; Regexp matching |
| 232 | 231 | ||
| 233 | ;; There is limited provision for regexp matching within iswitchb, | 232 | ;; There is provision for regexp matching within iswitchb, enabled |
| 234 | ;; enabled through `iswitchb-regexp'. This allows you to type `c$' | 233 | ;; through `iswitchb-regexp'. This allows you to type `c$' for |
| 235 | ;; for example and see all buffer names ending in `c'. This facility | 234 | ;; example and see all buffer names ending in `c'. No completion |
| 236 | ;; is quite limited though in two respects. First, you can't | 235 | ;; mechanism is currently offered when regexp searching. |
| 237 | ;; currently type in expressions like `[0-9]' directly -- you have to | ||
| 238 | ;; type them in when iswitchb-regexp is nil and then toggle on the | ||
| 239 | ;; regexp functionality. Likewise, don't enter an expression | ||
| 240 | ;; containing `\' in regexp mode. If you try, iswitchb gets confused, | ||
| 241 | ;; so just hit C-g and try again. Secondly, no completion mechanism | ||
| 242 | ;; is currently offered when regexp searching. | ||
| 243 | 236 | ||
| 244 | ;;; TODO | 237 | ;;; TODO |
| 245 | 238 | ||
| @@ -256,6 +249,8 @@ | |||
| 256 | (fboundp 'last))) | 249 | (fboundp 'last))) |
| 257 | (require 'cl)) | 250 | (require 'cl)) |
| 258 | 251 | ||
| 252 | (require 'font-lock) | ||
| 253 | |||
| 259 | ;; Set up the custom library. | 254 | ;; Set up the custom library. |
| 260 | ;; taken from http://www.dina.kvl.dk/~abraham/custom/ | 255 | ;; taken from http://www.dina.kvl.dk/~abraham/custom/ |
| 261 | (eval-and-compile | 256 | (eval-and-compile |
| @@ -377,10 +372,11 @@ See also `iswitchb-newbuffer'." | |||
| 377 | :type 'boolean | 372 | :type 'boolean |
| 378 | :group 'iswitchb) | 373 | :group 'iswitchb) |
| 379 | 374 | ||
| 380 | (defcustom iswitchb-use-fonts t | 375 | (defcustom iswitchb-use-faces t |
| 381 | "*Non-nil means use font-lock fonts for showing first match." | 376 | "*Non-nil means use font-lock fonts for showing first match." |
| 382 | :type 'boolean | 377 | :type 'boolean |
| 383 | :group 'iswitchb) | 378 | :group 'iswitchb) |
| 379 | (define-obsolete-variable-alias 'iswitchb-use-fonts 'iswitchb-use-faces "22.1") | ||
| 384 | 380 | ||
| 385 | (defcustom iswitchb-use-frame-buffer-list nil | 381 | (defcustom iswitchb-use-frame-buffer-list nil |
| 386 | "*Non-nil means use the currently selected frame's buffer list." | 382 | "*Non-nil means use the currently selected frame's buffer list." |
| @@ -408,6 +404,35 @@ iswitchb is running." | |||
| 408 | :type 'hook | 404 | :type 'hook |
| 409 | :group 'iswitchb) | 405 | :group 'iswitchb) |
| 410 | 406 | ||
| 407 | (defface iswitchb-single-match-face | ||
| 408 | '((t | ||
| 409 | (:inherit font-lock-comment-face))) | ||
| 410 | "Iswitchb face for single matching buffer name." | ||
| 411 | :version "22.1" | ||
| 412 | :group 'iswitchb) | ||
| 413 | |||
| 414 | (defface iswitchb-current-match-face | ||
| 415 | '((t | ||
| 416 | (:inherit font-lock-function-name-face))) | ||
| 417 | "Iswitchb face for current matching buffer name." | ||
| 418 | :version "22.1" | ||
| 419 | :group 'iswitchb) | ||
| 420 | |||
| 421 | (defface iswitchb-virtual-matches-face | ||
| 422 | '((t | ||
| 423 | (:inherit font-lock-builtin-face))) | ||
| 424 | "Iswitchb face for matching virtual buffer names. | ||
| 425 | See also `iswitchb-use-virtual-buffers'." | ||
| 426 | :version "22.1" | ||
| 427 | :group 'iswitchb) | ||
| 428 | |||
| 429 | (defface iswitchb-invalid-regexp-face | ||
| 430 | '((t | ||
| 431 | (:inherit font-lock-warning-face))) | ||
| 432 | "Iswitchb face for indicating invalid regexp. " | ||
| 433 | :version "22.1" | ||
| 434 | :group 'iswitchb) | ||
| 435 | |||
| 411 | ;; Do we need the variable iswitchb-use-mycompletion? | 436 | ;; Do we need the variable iswitchb-use-mycompletion? |
| 412 | 437 | ||
| 413 | ;;; Internal Variables | 438 | ;;; Internal Variables |
| @@ -507,6 +532,11 @@ selected.") | |||
| 507 | (defvar iswitchb-minibuf-depth nil | 532 | (defvar iswitchb-minibuf-depth nil |
| 508 | "Value we expect to be returned by `minibuffer-depth' in the minibuffer.") | 533 | "Value we expect to be returned by `minibuffer-depth' in the minibuffer.") |
| 509 | 534 | ||
| 535 | (defvar iswitchb-common-match-inserted nil | ||
| 536 | "Non-nil if we have just inserted a common match in the minibuffer.") | ||
| 537 | |||
| 538 | (defvar iswitchb-invalid-regexp) | ||
| 539 | |||
| 510 | ;;; FUNCTIONS | 540 | ;;; FUNCTIONS |
| 511 | 541 | ||
| 512 | ;;; ISWITCHB KEYMAP | 542 | ;;; ISWITCHB KEYMAP |
| @@ -564,6 +594,7 @@ in a separate window. | |||
| 564 | ;;`iswitchb-buffer-ignore') | 594 | ;;`iswitchb-buffer-ignore') |
| 565 | 595 | ||
| 566 | (let* ((prompt "iswitch ") | 596 | (let* ((prompt "iswitch ") |
| 597 | iswitchb-invalid-regexp | ||
| 567 | (buf (iswitchb-read-buffer prompt))) | 598 | (buf (iswitchb-read-buffer prompt))) |
| 568 | 599 | ||
| 569 | ;;(message "chosen text %s" iswitchb-final-text) | 600 | ;;(message "chosen text %s" iswitchb-final-text) |
| @@ -572,7 +603,8 @@ in a separate window. | |||
| 572 | 603 | ||
| 573 | (cond ( (eq iswitchb-exit 'findfile) | 604 | (cond ( (eq iswitchb-exit 'findfile) |
| 574 | (call-interactively 'find-file)) | 605 | (call-interactively 'find-file)) |
| 575 | 606 | (iswitchb-invalid-regexp | |
| 607 | (message "Won't make invalid regexp named buffer")) | ||
| 576 | (t | 608 | (t |
| 577 | ;; View the buffer | 609 | ;; View the buffer |
| 578 | ;;(message "go to buf %s" buf) | 610 | ;;(message "go to buf %s" buf) |
| @@ -602,10 +634,7 @@ the selection process begins. Used by isearchb.el." | |||
| 602 | buf-sel | 634 | buf-sel |
| 603 | iswitchb-final-text | 635 | iswitchb-final-text |
| 604 | (icomplete-mode nil) ;; prevent icomplete starting up | 636 | (icomplete-mode nil) ;; prevent icomplete starting up |
| 605 | ;; can only use fonts if they have been bound. | 637 | ) |
| 606 | (iswitchb-use-fonts (and iswitchb-use-fonts | ||
| 607 | (boundp 'font-lock-comment-face) | ||
| 608 | (boundp 'font-lock-function-name-face)))) | ||
| 609 | 638 | ||
| 610 | (iswitchb-define-mode-map) | 639 | (iswitchb-define-mode-map) |
| 611 | (setq iswitchb-exit nil) | 640 | (setq iswitchb-exit nil) |
| @@ -691,7 +720,9 @@ The result is stored in `iswitchb-common-match-string'." | |||
| 691 | (let (res) | 720 | (let (res) |
| 692 | (cond ((not iswitchb-matches) | 721 | (cond ((not iswitchb-matches) |
| 693 | (run-hooks 'iswitchb-cannot-complete-hook)) | 722 | (run-hooks 'iswitchb-cannot-complete-hook)) |
| 694 | 723 | (iswitchb-invalid-regexp | |
| 724 | ;; Do nothing | ||
| 725 | ) | ||
| 695 | ((= 1 (length iswitchb-matches)) | 726 | ((= 1 (length iswitchb-matches)) |
| 696 | ;; only one choice, so select it. | 727 | ;; only one choice, so select it. |
| 697 | (exit-minibuffer)) | 728 | (exit-minibuffer)) |
| @@ -703,7 +734,8 @@ The result is stored in `iswitchb-common-match-string'." | |||
| 703 | (not (equal res iswitchb-text))) | 734 | (not (equal res iswitchb-text))) |
| 704 | ;; found something to complete, so put it in the minibuffer. | 735 | ;; found something to complete, so put it in the minibuffer. |
| 705 | (progn | 736 | (progn |
| 706 | (setq iswitchb-rescan nil) | 737 | (setq iswitchb-rescan nil |
| 738 | iswitchb-common-match-inserted t) | ||
| 707 | (delete-region (minibuffer-prompt-end) (point)) | 739 | (delete-region (minibuffer-prompt-end) (point)) |
| 708 | (insert res)) | 740 | (insert res)) |
| 709 | ;; else nothing to complete | 741 | ;; else nothing to complete |
| @@ -889,22 +921,26 @@ BUFFER-LIST can be list of buffers or list of strings." | |||
| 889 | (do-string (stringp (car list))) | 921 | (do-string (stringp (car list))) |
| 890 | name | 922 | name |
| 891 | ret) | 923 | ret) |
| 892 | (mapcar | 924 | (setq iswitchb-invalid-regexp nil) |
| 893 | (lambda (x) | 925 | (catch 'invalid-regexp |
| 894 | 926 | (mapcar | |
| 895 | (if do-string | 927 | (lambda (x) |
| 896 | (setq name x) ;We already have the name | 928 | |
| 897 | (setq name (buffer-name x))) | 929 | (if do-string |
| 898 | 930 | (setq name x) ;We already have the name | |
| 899 | (cond | 931 | (setq name (buffer-name x))) |
| 900 | ((and (or (and string-format (string-match regexp name)) | 932 | |
| 901 | (and (null string-format) | 933 | (cond |
| 902 | (string-match (regexp-quote regexp) name))) | 934 | ((and (if (not string-format) |
| 903 | 935 | (string-match (regexp-quote regexp) name) | |
| 904 | (not (iswitchb-ignore-buffername-p name))) | 936 | (condition-case error |
| 905 | (setq ret (cons name ret)) | 937 | (string-match regexp name) |
| 906 | ))) | 938 | (invalid-regexp |
| 907 | list) | 939 | (setq iswitchb-invalid-regexp t) |
| 940 | (throw 'invalid-regexp (setq ret (cdr error)))))) | ||
| 941 | (not (iswitchb-ignore-buffername-p name))) | ||
| 942 | (setq ret (cons name ret))))) | ||
| 943 | list)) | ||
| 908 | ret)) | 944 | ret)) |
| 909 | 945 | ||
| 910 | (defun iswitchb-ignore-buffername-p (bufname) | 946 | (defun iswitchb-ignore-buffername-p (bufname) |
| @@ -989,7 +1025,8 @@ Return the modified list with the last element prepended to it." | |||
| 989 | (temp-buf "*Completions*") | 1025 | (temp-buf "*Completions*") |
| 990 | (win)) | 1026 | (win)) |
| 991 | 1027 | ||
| 992 | (if (eq last-command this-command) | 1028 | (if (and (eq last-command this-command) |
| 1029 | (not iswitchb-common-match-inserted)) | ||
| 993 | ;; scroll buffer | 1030 | ;; scroll buffer |
| 994 | (progn | 1031 | (progn |
| 995 | (set-buffer temp-buf) | 1032 | (set-buffer temp-buf) |
| @@ -1016,8 +1053,8 @@ Return the modified list with the last element prepended to it." | |||
| 1016 | (fundamental-mode)) | 1053 | (fundamental-mode)) |
| 1017 | (display-completion-list (if iswitchb-matches | 1054 | (display-completion-list (if iswitchb-matches |
| 1018 | iswitchb-matches | 1055 | iswitchb-matches |
| 1019 | iswitchb-buflist)) | 1056 | iswitchb-buflist)))) |
| 1020 | ))))) | 1057 | (setq iswitchb-common-match-inserted nil)))) |
| 1021 | 1058 | ||
| 1022 | ;;; KILL CURRENT BUFFER | 1059 | ;;; KILL CURRENT BUFFER |
| 1023 | 1060 | ||
| @@ -1227,8 +1264,7 @@ Copied from `icomplete-exhibit' with two changes: | |||
| 1227 | 1264 | ||
| 1228 | ;; Insert the match-status information: | 1265 | ;; Insert the match-status information: |
| 1229 | (insert (iswitchb-completions | 1266 | (insert (iswitchb-completions |
| 1230 | contents | 1267 | contents)))))) |
| 1231 | (not minibuffer-completion-confirm))))))) | ||
| 1232 | 1268 | ||
| 1233 | (eval-when-compile | 1269 | (eval-when-compile |
| 1234 | (defvar most-len) | 1270 | (defvar most-len) |
| @@ -1243,27 +1279,29 @@ Copied from `icomplete-exhibit' with two changes: | |||
| 1243 | (setq most-is-exact t)) | 1279 | (setq most-is-exact t)) |
| 1244 | (substring com most-len))) | 1280 | (substring com most-len))) |
| 1245 | 1281 | ||
| 1246 | (defun iswitchb-completions (name require-match) | 1282 | (defun iswitchb-completions (name) |
| 1247 | "Return the string that is displayed after the user's text. | 1283 | "Return the string that is displayed after the user's text. |
| 1248 | Modified from `icomplete-completions'." | 1284 | Modified from `icomplete-completions'." |
| 1249 | 1285 | ||
| 1250 | (let ((comps iswitchb-matches) | 1286 | (let ((comps iswitchb-matches) |
| 1251 | ; "-determined" - only one candidate | 1287 | ; "-determined" - only one candidate |
| 1252 | (open-bracket-determined (if require-match "(" "[")) | 1288 | (open-bracket-determined "[") |
| 1253 | (close-bracket-determined (if require-match ")" "]")) | 1289 | (close-bracket-determined "]") |
| 1254 | ;"-prospects" - more than one candidate | 1290 | ;"-prospects" - more than one candidate |
| 1255 | (open-bracket-prospects "{") | 1291 | (open-bracket-prospects "{") |
| 1256 | (close-bracket-prospects "}") | 1292 | (close-bracket-prospects "}") |
| 1257 | first) | 1293 | first) |
| 1258 | 1294 | ||
| 1259 | (if (and iswitchb-use-fonts comps) | 1295 | (if (and iswitchb-use-faces comps) |
| 1260 | (progn | 1296 | (progn |
| 1261 | (setq first (car comps)) | 1297 | (setq first (car comps)) |
| 1262 | (setq first (format "%s" first)) | 1298 | (setq first (format "%s" first)) |
| 1263 | (put-text-property 0 (length first) 'face | 1299 | (put-text-property 0 (length first) 'face |
| 1264 | (if (= (length comps) 1) | 1300 | (if (= (length comps) 1) |
| 1265 | 'font-lock-comment-face | 1301 | (if iswitchb-invalid-regexp |
| 1266 | 'font-lock-function-name-face) | 1302 | 'iswitchb-invalid-regexp-face |
| 1303 | 'iswitchb-single-match-face) | ||
| 1304 | 'iswitchb-current-match-face) | ||
| 1267 | first) | 1305 | first) |
| 1268 | (setq comps (cons first (cdr comps))))) | 1306 | (setq comps (cons first (cdr comps))))) |
| 1269 | 1307 | ||
| @@ -1292,7 +1330,7 @@ Modified from `icomplete-completions'." | |||
| 1292 | (let ((comp comps)) | 1330 | (let ((comp comps)) |
| 1293 | (while comp | 1331 | (while comp |
| 1294 | (put-text-property 0 (length (car comp)) | 1332 | (put-text-property 0 (length (car comp)) |
| 1295 | 'face 'font-lock-builtin-face | 1333 | 'face 'iswitchb-virtual-matches-face |
| 1296 | (car comp)) | 1334 | (car comp)) |
| 1297 | (setq comp (cdr comp)))))) | 1335 | (setq comp (cdr comp)))))) |
| 1298 | 1336 | ||
| @@ -1300,16 +1338,23 @@ Modified from `icomplete-completions'." | |||
| 1300 | open-bracket-determined | 1338 | open-bracket-determined |
| 1301 | close-bracket-determined)) | 1339 | close-bracket-determined)) |
| 1302 | 1340 | ||
| 1303 | ((null (cdr comps)) ;one match | 1341 | (iswitchb-invalid-regexp |
| 1304 | (concat (if (and (> (length (car comps)) | 1342 | (concat " " (car comps))) |
| 1305 | (length name))) | 1343 | ((null (cdr comps)) ;one match |
| 1306 | (concat open-bracket-determined | 1344 | (concat |
| 1345 | (if (if (not iswitchb-regexp) | ||
| 1346 | (= (length name) | ||
| 1347 | (length (car comps))) | ||
| 1348 | (string-match name (car comps)) | ||
| 1349 | (string-equal (match-string 0 (car comps)) | ||
| 1350 | (car comps))) | ||
| 1351 | "" | ||
| 1352 | (concat open-bracket-determined | ||
| 1307 | ;; when there is one match, show the | 1353 | ;; when there is one match, show the |
| 1308 | ;; matching buffer name in full | 1354 | ;; matching buffer name in full |
| 1309 | (car comps) | 1355 | (car comps) |
| 1310 | close-bracket-determined) | 1356 | close-bracket-determined)) |
| 1311 | "") | 1357 | (if (not iswitchb-use-faces) " [Matched]"))) |
| 1312 | (if (not iswitchb-use-fonts) " [Matched]"))) | ||
| 1313 | (t ;multiple matches | 1358 | (t ;multiple matches |
| 1314 | (if (and iswitchb-max-to-show | 1359 | (if (and iswitchb-max-to-show |
| 1315 | (> (length comps) iswitchb-max-to-show)) | 1360 | (> (length comps) iswitchb-max-to-show)) |
diff --git a/lisp/jit-lock.el b/lisp/jit-lock.el index b34e26f74d4..ba2eed9f17e 100644 --- a/lisp/jit-lock.el +++ b/lisp/jit-lock.el | |||
| @@ -298,7 +298,7 @@ Only applies to the current buffer." | |||
| 298 | "Fontify current buffer starting at position START. | 298 | "Fontify current buffer starting at position START. |
| 299 | This function is added to `fontification-functions' when `jit-lock-mode' | 299 | This function is added to `fontification-functions' when `jit-lock-mode' |
| 300 | is active." | 300 | is active." |
| 301 | (when jit-lock-mode | 301 | (when (and jit-lock-mode (not (memory-full-p))) |
| 302 | (if (null jit-lock-defer-time) | 302 | (if (null jit-lock-defer-time) |
| 303 | ;; No deferral. | 303 | ;; No deferral. |
| 304 | (jit-lock-fontify-now start (+ start jit-lock-chunk-size)) | 304 | (jit-lock-fontify-now start (+ start jit-lock-chunk-size)) |
| @@ -540,7 +540,7 @@ is the pre-change length. | |||
| 540 | This function ensures that lines following the change will be refontified | 540 | This function ensures that lines following the change will be refontified |
| 541 | in case the syntax of those lines has changed. Refontification | 541 | in case the syntax of those lines has changed. Refontification |
| 542 | will take place when text is fontified stealthily." | 542 | will take place when text is fontified stealthily." |
| 543 | (when jit-lock-mode | 543 | (when (and jit-lock-mode (not (memory-full-p))) |
| 544 | (save-excursion | 544 | (save-excursion |
| 545 | (with-buffer-prepared-for-jit-lock | 545 | (with-buffer-prepared-for-jit-lock |
| 546 | ;; It's important that the `fontified' property be set from the | 546 | ;; It's important that the `fontified' property be set from the |
diff --git a/lisp/ledit.el b/lisp/ledit.el index 8568740fd0b..38e03ca60cc 100644 --- a/lisp/ledit.el +++ b/lisp/ledit.el | |||
| @@ -152,7 +152,7 @@ do (setq lisp-mode-hook 'ledit-from-lisp-mode)" | |||
| 152 | (use-local-map ledit-mode-map) | 152 | (use-local-map ledit-mode-map) |
| 153 | (setq mode-name "Ledit") | 153 | (setq mode-name "Ledit") |
| 154 | (setq major-mode 'ledit-mode) | 154 | (setq major-mode 'ledit-mode) |
| 155 | (run-hooks 'ledit-mode-hook)) | 155 | (run-mode-hooks 'ledit-mode-hook)) |
| 156 | 156 | ||
| 157 | (provide 'ledit) | 157 | (provide 'ledit) |
| 158 | 158 | ||
diff --git a/lisp/locate.el b/lisp/locate.el index 42463a160fa..30a6ff41df3 100644 --- a/lisp/locate.el +++ b/lisp/locate.el | |||
| @@ -393,7 +393,7 @@ do not work in subdirectories. | |||
| 393 | (make-local-variable 'revert-buffer-function) | 393 | (make-local-variable 'revert-buffer-function) |
| 394 | (setq revert-buffer-function 'locate-update) | 394 | (setq revert-buffer-function 'locate-update) |
| 395 | (set (make-local-variable 'page-delimiter) "\n\n") | 395 | (set (make-local-variable 'page-delimiter) "\n\n") |
| 396 | (run-hooks 'locate-mode-hook)) | 396 | (run-mode-hooks 'locate-mode-hook)) |
| 397 | 397 | ||
| 398 | (defun locate-do-setup (search-string) | 398 | (defun locate-do-setup (search-string) |
| 399 | (goto-char (point-min)) | 399 | (goto-char (point-min)) |
diff --git a/lisp/longlines.el b/lisp/longlines.el index ebfb7a660b0..e9c300fdbec 100644 --- a/lisp/longlines.el +++ b/lisp/longlines.el | |||
| @@ -39,8 +39,6 @@ | |||
| 39 | 39 | ||
| 40 | ;;; Code: | 40 | ;;; Code: |
| 41 | 41 | ||
| 42 | (require 'easy-mmode) | ||
| 43 | |||
| 44 | (defgroup longlines nil | 42 | (defgroup longlines nil |
| 45 | "Automatic wrapping of long lines when loading files." | 43 | "Automatic wrapping of long lines when loading files." |
| 46 | :group 'fill) | 44 | :group 'fill) |
| @@ -157,7 +155,8 @@ major mode changes." | |||
| 157 | 155 | ||
| 158 | (defface longlines-visible-face | 156 | (defface longlines-visible-face |
| 159 | '((t (:background "red"))) | 157 | '((t (:background "red"))) |
| 160 | "Face used to make hard newlines visible in `longlines-mode'.") | 158 | "Face used to make hard newlines visible in `longlines-mode'." |
| 159 | :group 'longlines) | ||
| 161 | 160 | ||
| 162 | (defun longlines-show-hard-newlines (&optional arg) | 161 | (defun longlines-show-hard-newlines (&optional arg) |
| 163 | "Make hard newlines visible by adding a face. | 162 | "Make hard newlines visible by adding a face. |
diff --git a/lisp/mail/rmail.el b/lisp/mail/rmail.el index 3fa8b3df3cd..e97f7d77cae 100644 --- a/lisp/mail/rmail.el +++ b/lisp/mail/rmail.el | |||
| @@ -1156,7 +1156,7 @@ Instead, these commands are available: | |||
| 1156 | (when rmail-display-summary | 1156 | (when rmail-display-summary |
| 1157 | (rmail-summary)) | 1157 | (rmail-summary)) |
| 1158 | (rmail-construct-io-menu)) | 1158 | (rmail-construct-io-menu)) |
| 1159 | (run-hooks 'rmail-mode-hook))) | 1159 | (run-mode-hooks 'rmail-mode-hook))) |
| 1160 | 1160 | ||
| 1161 | (defun rmail-mode-2 () | 1161 | (defun rmail-mode-2 () |
| 1162 | (kill-all-local-variables) | 1162 | (kill-all-local-variables) |
diff --git a/lisp/mail/rmailedit.el b/lisp/mail/rmailedit.el index a057c019b82..ceea389cea1 100644 --- a/lisp/mail/rmailedit.el +++ b/lisp/mail/rmailedit.el | |||
| @@ -68,7 +68,7 @@ This functions runs the normal hook `rmail-edit-mode-hook'. | |||
| 68 | (save-excursion | 68 | (save-excursion |
| 69 | (set-buffer rmail-summary-buffer) | 69 | (set-buffer rmail-summary-buffer) |
| 70 | (rmail-summary-disable))) | 70 | (rmail-summary-disable))) |
| 71 | (run-hooks 'rmail-edit-mode-hook)) | 71 | (run-mode-hooks 'rmail-edit-mode-hook)) |
| 72 | 72 | ||
| 73 | (defvar rmail-old-pruned nil) | 73 | (defvar rmail-old-pruned nil) |
| 74 | (put 'rmail-old-pruned 'permanent-local t) | 74 | (put 'rmail-old-pruned 'permanent-local t) |
diff --git a/lisp/mail/rmailsum.el b/lisp/mail/rmailsum.el index f551239907d..9c647126d5c 100644 --- a/lisp/mail/rmailsum.el +++ b/lisp/mail/rmailsum.el | |||
| @@ -760,7 +760,7 @@ Commands for sorting the summary: | |||
| 760 | (make-local-variable 'font-lock-defaults) | 760 | (make-local-variable 'font-lock-defaults) |
| 761 | (setq font-lock-defaults '(rmail-summary-font-lock-keywords t)) | 761 | (setq font-lock-defaults '(rmail-summary-font-lock-keywords t)) |
| 762 | (rmail-summary-enable) | 762 | (rmail-summary-enable) |
| 763 | (run-hooks 'rmail-summary-mode-hook)) | 763 | (run-mode-hooks 'rmail-summary-mode-hook)) |
| 764 | 764 | ||
| 765 | ;; Summary features need to be disabled during edit mode. | 765 | ;; Summary features need to be disabled during edit mode. |
| 766 | (defun rmail-summary-disable () | 766 | (defun rmail-summary-disable () |
diff --git a/lisp/mail/supercite.el b/lisp/mail/supercite.el index d9a9d78d0b9..ba4aca881ef 100644 --- a/lisp/mail/supercite.el +++ b/lisp/mail/supercite.el | |||
| @@ -3,7 +3,7 @@ | |||
| 3 | ;; Copyright (C) 1993, 1997, 2003, 2004, 2005 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 1993, 1997, 2003, 2004, 2005 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: 1993 Barry A. Warsaw <bwarsaw@python.org> | 5 | ;; Author: 1993 Barry A. Warsaw <bwarsaw@python.org> |
| 6 | ;; Maintainer: FSF | 6 | ;; Maintainer: Glenn Morris <gmorris@ast.cam.ac.uk> |
| 7 | ;; Created: February 1993 | 7 | ;; Created: February 1993 |
| 8 | ;; Last Modified: 1993/09/22 18:58:46 | 8 | ;; Last Modified: 1993/09/22 18:58:46 |
| 9 | ;; Keywords: mail, news | 9 | ;; Keywords: mail, news |
| @@ -1182,8 +1182,11 @@ to the auto-selected attribution string." | |||
| 1182 | (setq attribution attrib | 1182 | (setq attribution attrib |
| 1183 | attriblist nil)) | 1183 | attriblist nil)) |
| 1184 | ((listp attrib) | 1184 | ((listp attrib) |
| 1185 | (setq attribution (eval attrib) | 1185 | (setq attribution (eval attrib)) |
| 1186 | attriblist nil)) | 1186 | (if (stringp attribution) |
| 1187 | (setq attriblist nil) | ||
| 1188 | (setq attribution nil | ||
| 1189 | attriblist (cdr attriblist)))) | ||
| 1187 | (t (error "%s did not evaluate to a string or list!" | 1190 | (t (error "%s did not evaluate to a string or list!" |
| 1188 | "sc-attrib-selection-list")) | 1191 | "sc-attrib-selection-list")) |
| 1189 | ))) | 1192 | ))) |
| @@ -1667,7 +1670,7 @@ header style to use, unless not supplied or invalid, in which case | |||
| 1667 | (major-mode 'sc-electric-mode)) | 1670 | (major-mode 'sc-electric-mode)) |
| 1668 | (use-local-map sc-electric-mode-map) | 1671 | (use-local-map sc-electric-mode-map) |
| 1669 | (sc-eref-show sc-eref-style) | 1672 | (sc-eref-show sc-eref-style) |
| 1670 | (run-hooks 'sc-electric-mode-hook) | 1673 | (run-mode-hooks 'sc-electric-mode-hook) |
| 1671 | (recursive-edit) | 1674 | (recursive-edit) |
| 1672 | ))) | 1675 | ))) |
| 1673 | 1676 | ||
diff --git a/lisp/man.el b/lisp/man.el index 712b1f30e7f..d7344ed2f7a 100644 --- a/lisp/man.el +++ b/lisp/man.el | |||
| @@ -259,7 +259,7 @@ the associated section number." | |||
| 259 | (defvar Man-cooked-hook nil | 259 | (defvar Man-cooked-hook nil |
| 260 | "Hook run after removing backspaces but before `Man-mode' processing.") | 260 | "Hook run after removing backspaces but before `Man-mode' processing.") |
| 261 | 261 | ||
| 262 | (defvar Man-name-regexp "[-a-zA-Z0-9_+][-a-zA-Z0-9_.+]*" | 262 | (defvar Man-name-regexp "[-a-zA-Z0-9_+][-a-zA-Z0-9_.:+]*" |
| 263 | "Regular expression describing the name of a manpage (without section).") | 263 | "Regular expression describing the name of a manpage (without section).") |
| 264 | 264 | ||
| 265 | (defvar Man-section-regexp "[0-9][a-zA-Z+]*\\|[LNln]" | 265 | (defvar Man-section-regexp "[0-9][a-zA-Z+]*\\|[LNln]" |
| @@ -1061,6 +1061,7 @@ The following variables may be of some use. Try | |||
| 1061 | The following key bindings are currently in effect in the buffer: | 1061 | The following key bindings are currently in effect in the buffer: |
| 1062 | \\{Man-mode-map}" | 1062 | \\{Man-mode-map}" |
| 1063 | (interactive) | 1063 | (interactive) |
| 1064 | (kill-all-local-variables) | ||
| 1064 | (setq major-mode 'Man-mode | 1065 | (setq major-mode 'Man-mode |
| 1065 | mode-name "Man" | 1066 | mode-name "Man" |
| 1066 | buffer-auto-save-file-name nil | 1067 | buffer-auto-save-file-name nil |
| @@ -1069,7 +1070,7 @@ The following key bindings are currently in effect in the buffer: | |||
| 1069 | " {" 'Man-page-mode-string "}") | 1070 | " {" 'Man-page-mode-string "}") |
| 1070 | truncate-lines t | 1071 | truncate-lines t |
| 1071 | buffer-read-only t) | 1072 | buffer-read-only t) |
| 1072 | (buffer-disable-undo (current-buffer)) | 1073 | (buffer-disable-undo) |
| 1073 | (auto-fill-mode -1) | 1074 | (auto-fill-mode -1) |
| 1074 | (use-local-map Man-mode-map) | 1075 | (use-local-map Man-mode-map) |
| 1075 | (set-syntax-table man-mode-syntax-table) | 1076 | (set-syntax-table man-mode-syntax-table) |
| @@ -1080,7 +1081,7 @@ The following key bindings are currently in effect in the buffer: | |||
| 1080 | (Man-strip-page-headers) | 1081 | (Man-strip-page-headers) |
| 1081 | (Man-unindent) | 1082 | (Man-unindent) |
| 1082 | (Man-goto-page 1) | 1083 | (Man-goto-page 1) |
| 1083 | (run-hooks 'Man-mode-hook)) | 1084 | (run-mode-hooks 'Man-mode-hook)) |
| 1084 | 1085 | ||
| 1085 | (defsubst Man-build-section-alist () | 1086 | (defsubst Man-build-section-alist () |
| 1086 | "Build the association list of manpage sections." | 1087 | "Build the association list of manpage sections." |
diff --git a/lisp/mh-e/ChangeLog b/lisp/mh-e/ChangeLog index 92f997d7b4a..23e7c6d44cb 100644 --- a/lisp/mh-e/ChangeLog +++ b/lisp/mh-e/ChangeLog | |||
| @@ -1,27 +1,305 @@ | |||
| 1 | 2005-04-08 Dan Nicolaescu <dann@ics.uci.edu> | 1 | 2005-05-28 Bill Wohler <wohler@newt.com> |
| 2 | |||
| 3 | Released MH-E version 7.84. | ||
| 4 | |||
| 5 | * MH-E-NEWS, README: Updated for release 7.84. | ||
| 6 | |||
| 7 | * mh-e.el (Version, mh-version): Updated for release 7.84. | ||
| 8 | |||
| 9 | 2005-05-28 Bill Wohler <wohler@newt.com> | ||
| 10 | |||
| 11 | * mh-e.el, mh-comp.el: Don't autoload Info-goto-node. It's not | ||
| 12 | used, and if it were, the code should use the info function | ||
| 13 | instead. | ||
| 14 | |||
| 15 | Use full year in copyright notices (for example, 2005, not 05). | ||
| 16 | |||
| 17 | * Makefile (mh-loaddefs.el, mh-e-autoloads.el): Added 2005 to | ||
| 18 | copyright notice. | ||
| 19 | |||
| 20 | * mh-inc.el: Use three ;;; to precede Local Variables to be | ||
| 21 | consistent with other files. Will have to ask Stefan Monnier why | ||
| 22 | he changed it. | ||
| 23 | |||
| 24 | * README: This version of MH-E to appear in GNU Emacs 22.1, not | ||
| 25 | 21.5. | ||
| 26 | |||
| 27 | * ChangeLog: The * in a ChangeLog entry must only be used before a | ||
| 28 | filename. | ||
| 29 | |||
| 30 | Fixed compilation warnings in CVS Emacs. This included using | ||
| 31 | "public" functions instead of "private" ones (info instead of | ||
| 32 | Info-goto-node, view-mode-enter instead of view-mode), and | ||
| 33 | removing a customization group that didn't have a parent group. In | ||
| 34 | addition, string-to-int was recently deprecated; use | ||
| 35 | string-to-number instead. | ||
| 36 | |||
| 37 | * mh-customize.el (Info-goto-node): Deleted autoload. | ||
| 38 | (mh-e): Deleted mh group. Use single mh-e group instead. | ||
| 39 | (mh-tool-bar-folder-help, mh-tool-bar-letter-help): Use info | ||
| 40 | instead of Info-goto-node. | ||
| 41 | |||
| 42 | * mh-e.el (mh-read-msg-list): string-to-int deprecated; use | ||
| 43 | string-to-number. | ||
| 44 | |||
| 45 | * mh-funcs.el (mh-list-folders): Use view-mode-enter instead of | ||
| 46 | view-mode. | ||
| 47 | |||
| 48 | * mh-seq.el (mh-list-sequences): Use view-mode-enter instead of | ||
| 49 | view-mode. | ||
| 50 | |||
| 51 | * mh-utils.el (mh-get-msg-num): string-to-int deprecated; use | ||
| 52 | string-to-number. | ||
| 53 | |||
| 54 | Merged in changes from CVS Emacs including: | ||
| 55 | |||
| 56 | * mh-utils.el (mh-show-mode): | ||
| 57 | * mh-pick.el (mh-pick-mode): Remove spurious run-hooks. Lute | ||
| 58 | Kamstra <lute@gnu.org> 2005-05-26. | ||
| 59 | |||
| 60 | 2005-05-25 Bill Wohler <wohler@newt.com> | ||
| 61 | |||
| 62 | Merged in changes from CVS Emacs including: | ||
| 2 | 63 | ||
| 3 | * mh-customize.el (mh-speedbar-selected-folder-face): Special case | 64 | * mh-customize.el (mh-speedbar-selected-folder-face): Special case |
| 4 | high number of colors displays. | 65 | high number of colors displays. Dan Nicolaescu <dann@ics.uci.edu> |
| 66 | 2005-04-08. | ||
| 67 | |||
| 68 | * mh-e.el, mh-identity.el, mh-mime.el: Replace `legal' with | ||
| 69 | `valid'. Replace `illegal' with `invalid'. Werner Lemberg | ||
| 70 | <wl@gnu.org> 2005-03-25. | ||
| 5 | 71 | ||
| 6 | 2005-03-25 Werner Lemberg <wl@gnu.org> | 72 | * mh-inc.el (mh-inc-spool-list): Correctly declare the external |
| 73 | var. Stefan <monnier@iro.umontreal.ca> 2004-09-07. | ||
| 7 | 74 | ||
| 8 | * mh-e.el, mh-identity.el, mh-mime.el: Replace `legal' with `valid'. | 75 | 2005-05-18 Bill Wohler <wohler@newt.com> |
| 9 | 76 | ||
| 10 | 2005-03-25 Werner Lemberg <wl@gnu.org> | 77 | * mh-comp.el (mh-reply): Mention use of mh-repl-group-formfile in |
| 78 | docstring. | ||
| 11 | 79 | ||
| 12 | * mh-e.el: Replace `illegal' with `invalid'. | 80 | 2005-05-05 Bill Wohler <wohler@newt.com> |
| 13 | 81 | ||
| 14 | 2004-09-07 Stefan <monnier@iro.umontreal.ca> | 82 | * mh-e.el (Version, mh-version): Added +cvs to release number. |
| 15 | 83 | ||
| 16 | * mh-inc.el (mh-inc-spool-list): Correctly declare the external var. | 84 | 2005-05-05 Bill Wohler <wohler@newt.com> |
| 17 | 85 | ||
| 18 | 2004-08-21 Bill Wohler <wohler@newt.com> | 86 | Released MH-E version 7.83. |
| 87 | |||
| 88 | * MH-E-NEWS, README: Updated for release 7.83. | ||
| 89 | |||
| 90 | * mh-e.el (Version, mh-version): Updated for release 7.83. | ||
| 91 | |||
| 92 | 2005-05-05 Bill Wohler <wohler@newt.com> | ||
| 93 | |||
| 94 | * README: To appear in Emacs 21.5, since 21.4 was released (but | ||
| 95 | without the latest MH-E). | ||
| 96 | |||
| 97 | * release-utils (usage): Added --variable-changes. | ||
| 98 | |||
| 99 | 2005-05-04 Bill Wohler <wohler@newt.com> | ||
| 100 | |||
| 101 | * mh-customize.el (*-face): Made docstrings consistent. | ||
| 102 | |||
| 103 | * mh-seq.el (mh-pick-args-list): Extracted function for turning | ||
| 104 | string of pick arguments to list. Fixed list so that multi-word | ||
| 105 | arguments were put in a single string (closes SF #1122655). | ||
| 106 | (mh-edit-pick-expr): Use it. | ||
| 107 | |||
| 108 | * mh-unit.el (mh-unit): Since 21.4 snuck out but didn't contain | ||
| 109 | updated lm-verify, don't run lm-verify on versions before 21.5. | ||
| 110 | (mh-unit-test-pick-args-list): Added. | ||
| 111 | |||
| 112 | * mh-customize.el (mh-yank-from-start-of-msg): Use headline | ||
| 113 | capitalization. Changed wording of some choices to be more consistent. | ||
| 114 | (mh-invisible-header-fields-internal): Added fields from usa.net. | ||
| 115 | |||
| 116 | 2005-04-24 Satyaki Das <satyaki@theforce.stanford.edu> | ||
| 117 | |||
| 118 | * mh-mime.el (mh-mime-security-button-face): New function which | ||
| 119 | determines the face to use to colorize encrypted or signed emails. | ||
| 120 | (mh-insert-mime-security-button): Modified to colorize the button | ||
| 121 | differently based on whether the signature was valid or not, | ||
| 122 | whether the decryption was successful or not, etc. | ||
| 123 | |||
| 124 | * mh-customize.el (mh-show-pgg-good-face) | ||
| 125 | (mh-show-pgg-unknown-face, mh-show-pgg-bad-face): Faces added to | ||
| 126 | highlight buttons introduced for encrpted or signed MIME parts. | ||
| 127 | |||
| 128 | 2005-03-19 Bill Wohler <wohler@newt.com> | ||
| 129 | |||
| 130 | * mh-customize.el (mh-mml-method-default): Sorted alphabetically. | ||
| 131 | (mh-insert-x-mailer-flag, mh-reply-show-message-flag): Moved from | ||
| 132 | mh-letter group to mh-sending-mail group. The writing of the | ||
| 133 | documentation revealed that these options were misplaced. | ||
| 134 | |||
| 135 | 2005-03-17 Bill Wohler <wohler@newt.com> | ||
| 136 | |||
| 137 | * mh-customize.el (mh-junk-background): Put in alphabetical order. | ||
| 138 | Synced with manual. | ||
| 139 | (mh-junk-program): Use double-quotes on non-symbols. | ||
| 140 | |||
| 141 | * mh-pick.el: (mh-search-folder): Synced docstrings with manual. | ||
| 142 | |||
| 143 | * mh-index.el: (mh-index-search, mh-pick-execute-search) | ||
| 144 | (mh-grep-execute-search, mh-mairix-execute-search) | ||
| 145 | (mh-swish-execute-search, mh-swish++-execute-search) | ||
| 146 | (mh-namazu-execute-search): Synced docstrings with manual. Note | ||
| 147 | that I'm now grabbing the output of an Info buffer which is why | ||
| 148 | the indents on the examples has changed a bit. If we all use that | ||
| 149 | methodology in the future, we shouldn't produce as many gratuitous | ||
| 150 | diffs. I also noticed that `grep' and `search' became links to | ||
| 151 | unrelated things, so let's use double-quotes for quoting | ||
| 152 | non-symbols in the docstrings. | ||
| 153 | |||
| 154 | * mh-customize.el (mh-index-new-messages-folders) | ||
| 155 | (mh-index-ticked-messages-folders): Synced docstrings with manual. | ||
| 156 | |||
| 157 | 2005-02-16 Satyaki Das <satyaki@theforce.stanford.edu> | ||
| 158 | |||
| 159 | * mh-index.el (mh-swish-execute-search): Simplify the indexing | ||
| 160 | recipe for swish. Thanks to Eric Jensen for the suggestion. | ||
| 161 | |||
| 162 | 2005-02-11 Satyaki Das <satyaki@theforce.stanford.edu> | ||
| 163 | |||
| 164 | * mh-index.el (mh-swish-execute-search) | ||
| 165 | (mh-swish++-execute-search): Make the indexing recipes better. | ||
| 166 | (mh-swish-next-result): The indexer might find matches in files | ||
| 167 | that aren't messages. Make the function handle that case | ||
| 168 | gracefully. | ||
| 19 | 169 | ||
| 20 | * Released MH-E version 7.82. | 170 | 2005-02-07 Bill Wohler <wohler@newt.com> |
| 171 | |||
| 172 | * mh-customize.el (mh-inc-prog, mh-inc-spool-list): Synced | ||
| 173 | docstrings with manual. | ||
| 174 | |||
| 175 | 2005-02-06 Bill Wohler <wohler@newt.com> | ||
| 176 | |||
| 177 | * mh-junk.el (mh-spamassassin-blacklist): Removed trailing | ||
| 178 | whitespace. | ||
| 179 | |||
| 180 | * mh-e.el (mh-refile-or-write-again): Checkdoc fix. | ||
| 181 | |||
| 182 | * mh-identity.el (mh-identity-list-set) | ||
| 183 | (mh-identity-field-handler, mh-identity-handler-gpg-identity) | ||
| 184 | (mh-identity-handler-signature) | ||
| 185 | (mh-identity-handler-attribution-verb) | ||
| 186 | (mh-identity-handler-default, mh-identity-handler-top): Docstring | ||
| 187 | editing. | ||
| 188 | |||
| 189 | * mh-customize.el (mh-identity-list, mh-auto-fields-list) | ||
| 190 | (mh-identity-default, mh-identity-handlers): Synced docstrings | ||
| 191 | with manual. | ||
| 192 | |||
| 193 | 2005-02-03 Bill Wohler <wohler@newt.com> | ||
| 194 | |||
| 195 | * mh-xemacs.el (define-behavior 'mh): Moved Ben's code here from | ||
| 196 | mh-e.el and added standard documentation. | ||
| 197 | |||
| 198 | * mh-e.el: Received patch from Ben Wing <ben@666.com> to add | ||
| 199 | define-behavior on XEmacs. | ||
| 200 | |||
| 201 | 2005-01-28 Jeffrey C Honig <jch@honig.net> | ||
| 202 | |||
| 203 | * mh-customize.el (mh-invisible-header-fields-internal): Added | ||
| 204 | X-Evolution header added by Evolution mai client. | ||
| 205 | |||
| 206 | 2005-01-18 Bill Wohler <wohler@newt.com> | ||
| 207 | |||
| 208 | * mh-customize.el (mh-invisible-header-fields-internal): Added | ||
| 209 | DomainKey-Signature (http://antispam.yahoo.com/domainkeys/). | ||
| 210 | There's a Comment field that goes with it, but I thought it was | ||
| 211 | too general to add. | ||
| 212 | |||
| 213 | 2005-01-06 Bill Wohler <wohler@newt.com> | ||
| 214 | |||
| 215 | * mh-junk.el (mh-spamassassin-blacklist): Fixed typo to fix an | ||
| 216 | error when junking spamassassin mail when mh-junk-background is | ||
| 217 | turned on. | ||
| 218 | |||
| 219 | 2004-12-25 Satyaki Das <satyaki@theforce.stanford.edu> | ||
| 220 | |||
| 221 | * mh-utils.el (mh-show-unquote-From): Make the buffer writable | ||
| 222 | before trying to change it (closes SF #1089870). | ||
| 223 | |||
| 224 | * mh-comp.el (mh-complete-word): Fix a typo in a variable | ||
| 225 | name (closes SF #1089870) | ||
| 226 | |||
| 227 | 2004-11-28 Jeffrey C Honig <jch@honig.net> | ||
| 228 | |||
| 229 | * mh-comp.el (mh-complete-word): Kill the *Completions* buffer in | ||
| 230 | any cases where we belive we are done with it. Not perfect, but | ||
| 231 | better than just leaving it around. | ||
| 232 | |||
| 233 | 2004-11-08 Satyaki Das <satyaki@theforce.stanford.edu> | ||
| 234 | |||
| 235 | * mh-acros.el (mh-funcall-if-exists): In XEmacs, presence of a | ||
| 236 | function at compile time doesn't guarantee it's existence at run | ||
| 237 | time. So make the macro handle that situation better. | ||
| 238 | |||
| 239 | 2004-11-05 Satyaki Das <satyaki@theforce.stanford.edu> | ||
| 240 | |||
| 241 | * mh-acros.el (advice): Load advice, since it isn't loaded in | ||
| 242 | XEmacs causing compilation problems. | ||
| 243 | |||
| 244 | 2004-10-24 Satyaki Das <satyaki@theforce.stanford.edu> | ||
| 245 | |||
| 246 | * mh-index.el (mh-mairix-execute-search) | ||
| 247 | (mh-mairix-regexp-builder): Update the interface to mairix so that | ||
| 248 | it will work with versions of mairix 0.12 and later. | ||
| 249 | |||
| 250 | * mh-funcs.el (mh-rmf-daemon): Avoid using | ||
| 251 | beginning-of-buffer since it clobbers the mark and it was pointed | ||
| 252 | out on the Emacs developers list to be the wrong thing to do. | ||
| 253 | |||
| 254 | * mh-e.el (mh-inc-folder): Only remove the window on the show | ||
| 255 | buffer. This means if the user has BBDB enabled then the window | ||
| 256 | displaying BBDB information isn't clobbered. | ||
| 257 | (mh-refile-or-write-again): Don't use the function | ||
| 258 | interactive-p. There was a long thread on the Emacs developers | ||
| 259 | list where it was pointed out that it is incorrect to use this | ||
| 260 | function most of the time. | ||
| 261 | |||
| 262 | * mh-comp.el (autoload): Don't set auto-mode-alist. This could | ||
| 263 | screw things up for users that don't use MH-E (closes SF #1032353). | ||
| 264 | |||
| 265 | 2004-10-13 Satyaki Das <satyaki@theforce.stanford.edu> | ||
| 266 | |||
| 267 | * mh-e.el (mh-refile-or-write-again): Generalize the function to | ||
| 268 | work on a range of messages (closes SF #1046330). | ||
| 269 | |||
| 270 | 2004-09-02 Satyaki Das <satyaki@theforce.stanford.edu> | ||
| 271 | |||
| 272 | * mh-e.el (mh-process-commands): The concurrent execution of mark | ||
| 273 | and refile can cause problems since both the commands change the | ||
| 274 | current folder. This change avoids that by getting rid of the | ||
| 275 | concurrency. Another change covers the corner case where we refile | ||
| 276 | messages to a previously empty folder. Before the modification | ||
| 277 | sequences weren't preserved even if the appropriate flag was | ||
| 278 | set. That is no longer the case. | ||
| 279 | |||
| 280 | 2004-08-26 Satyaki Das <satyaki@theforce.stanford.edu> | ||
| 281 | |||
| 282 | * mh-e.el (mh-get-new-mail): Also, update the unseen sequence from | ||
| 283 | disk. Otherwise, the new messages aren't highlighted. | ||
| 284 | |||
| 285 | * mh-seq.el (mh-thread-inc): Fix a bug which appears when inc is | ||
| 286 | run in a narrowed folder. The user sequence notation was getting | ||
| 287 | lost. The change fixes that. | ||
| 288 | |||
| 289 | * mh-e.el (mh-get-new-mail): Make inc more efficient by reusing | ||
| 290 | the existing user sequence notation and deleted/refiled notation. | ||
| 291 | |||
| 292 | 2004-08-24 Bill Wohler <wohler@newt.com> | ||
| 293 | |||
| 294 | * mh-e.el (Version, mh-version): Added +cvs to release number. | ||
| 295 | |||
| 296 | 2004-08-24 Bill Wohler <wohler@newt.com> | ||
| 297 | |||
| 298 | Released MH-E version 7.82. | ||
| 21 | 299 | ||
| 22 | * MH-E-NEWS, README: Updated for release 7.82. | 300 | * MH-E-NEWS, README: Updated for release 7.82. |
| 23 | 301 | ||
| 24 | * mh-e.el (Version, mh-version): Update for release 7.82. | 302 | * mh-e.el (Version, mh-version): Updated for release 7.82. |
| 25 | 303 | ||
| 26 | 2004-08-24 Bill Wohler <wohler@newt.com> | 304 | 2004-08-24 Bill Wohler <wohler@newt.com> |
| 27 | 305 | ||
| @@ -52,11 +330,11 @@ | |||
| 52 | 330 | ||
| 53 | 2004-08-21 Bill Wohler <wohler@newt.com> | 331 | 2004-08-21 Bill Wohler <wohler@newt.com> |
| 54 | 332 | ||
| 55 | * Released MH-E version 7.81. | 333 | Released MH-E version 7.81. |
| 56 | 334 | ||
| 57 | * MH-E-NEWS, README: Updated for release 7.81. | 335 | * MH-E-NEWS, README: Updated for release 7.81. |
| 58 | 336 | ||
| 59 | * mh-e.el (Version, mh-version): Update for release 7.81. | 337 | * mh-e.el (Version, mh-version): Updated for release 7.81. |
| 60 | 338 | ||
| 61 | 2004-08-21 Bill Wohler <wohler@newt.com> | 339 | 2004-08-21 Bill Wohler <wohler@newt.com> |
| 62 | 340 | ||
| @@ -89,7 +367,7 @@ | |||
| 89 | 367 | ||
| 90 | 2004-08-15 Bill Wohler <wohler@newt.com> | 368 | 2004-08-15 Bill Wohler <wohler@newt.com> |
| 91 | 369 | ||
| 92 | * Released MH-E version 7.4.80. | 370 | Released MH-E version 7.4.80. |
| 93 | 371 | ||
| 94 | * MH-E-NEWS, README: Updated for release 7.4.80. | 372 | * MH-E-NEWS, README: Updated for release 7.4.80. |
| 95 | 373 | ||
| @@ -319,13 +597,13 @@ | |||
| 319 | are more useful than a key sequence in these cases. Use "See also" | 597 | are more useful than a key sequence in these cases. Use "See also" |
| 320 | instead of "See also documentation for". | 598 | instead of "See also documentation for". |
| 321 | 599 | ||
| 322 | * Merged in 7.4.4 changes, described below. | 600 | Merged in 7.4.4 changes, described below. |
| 323 | 601 | ||
| 324 | * mh-e.el (Version, mh-version): Set to 7.4.4+cvs. | 602 | * mh-e.el (Version, mh-version): Set to 7.4.4+cvs. |
| 325 | 603 | ||
| 326 | 2004-07-10 Bill Wohler <wohler@newt.com> | 604 | 2004-07-10 Bill Wohler <wohler@newt.com> |
| 327 | 605 | ||
| 328 | * Released MH-E version 7.4.4. | 606 | Released MH-E version 7.4.4. |
| 329 | 607 | ||
| 330 | * MH-E-NEWS, README: Updated for release 7.4.4. | 608 | * MH-E-NEWS, README: Updated for release 7.4.4. |
| 331 | 609 | ||
| @@ -394,9 +672,9 @@ | |||
| 394 | routines in the best way possible (closes SF #930012). | 672 | routines in the best way possible (closes SF #930012). |
| 395 | (require 'mouse): To shush compiler. | 673 | (require 'mouse): To shush compiler. |
| 396 | 674 | ||
| 397 | * Use new function mh-require-cl throughout. | 675 | Use new function mh-require-cl throughout. |
| 398 | 676 | ||
| 399 | * Add arch taglines (courtesy Miles Bader). | 677 | Add arch taglines (courtesy Miles Bader). |
| 400 | 678 | ||
| 401 | * mh-unit.el (mh-unit-files): Replaced mh-xemacs-compat.el and | 679 | * mh-unit.el (mh-unit-files): Replaced mh-xemacs-compat.el and |
| 402 | mh-xemacs-icons.el with mh-xemacs.el. | 680 | mh-xemacs-icons.el with mh-xemacs.el. |
| @@ -536,7 +814,7 @@ | |||
| 536 | 814 | ||
| 537 | 2003-11-18 Bill Wohler <wohler@newt.com> | 815 | 2003-11-18 Bill Wohler <wohler@newt.com> |
| 538 | 816 | ||
| 539 | * Released MH-E version 7.4.3. | 817 | Released MH-E version 7.4.3. |
| 540 | 818 | ||
| 541 | * MH-E-NEWS, README: Updated for release 7.4.3. | 819 | * MH-E-NEWS, README: Updated for release 7.4.3. |
| 542 | 820 | ||
| @@ -679,8 +957,8 @@ | |||
| 679 | 957 | ||
| 680 | 2003-11-04 Steve Youngs <sryoungs@bigpond.net.au> | 958 | 2003-11-04 Steve Youngs <sryoungs@bigpond.net.au> |
| 681 | 959 | ||
| 682 | * Makefile (XEMACS_LOADDEFS_FILE): New. Used to generate mh-loaddefs.el | 960 | * Makefile (XEMACS_LOADDEFS_FILE): New. Used to generate |
| 683 | in XEmacs. | 961 | mh-loaddefs.el in XEmacs. |
| 684 | (XEMACS_LOADDEFS_COOKIE): Ditto. | 962 | (XEMACS_LOADDEFS_COOKIE): Ditto. |
| 685 | (XEMACS_LOADDEFS_PKG_NAME): Ditto. | 963 | (XEMACS_LOADDEFS_PKG_NAME): Ditto. |
| 686 | (xemacs): Add target to build mh-loaddefs.el in XEmacs | 964 | (xemacs): Add target to build mh-loaddefs.el in XEmacs |
| @@ -1358,7 +1636,7 @@ | |||
| 1358 | 1636 | ||
| 1359 | 2003-08-19 Bill Wohler <wohler@newt.com> | 1637 | 2003-08-19 Bill Wohler <wohler@newt.com> |
| 1360 | 1638 | ||
| 1361 | * Released MH-E version 7.4.2. | 1639 | Released MH-E version 7.4.2. |
| 1362 | 1640 | ||
| 1363 | * MH-E-NEWS, README: Updated for release 7.4.2. | 1641 | * MH-E-NEWS, README: Updated for release 7.4.2. |
| 1364 | 1642 | ||
| @@ -2228,7 +2506,7 @@ | |||
| 2228 | 2506 | ||
| 2229 | 2003-06-25 Bill Wohler <wohler@newt.com> | 2507 | 2003-06-25 Bill Wohler <wohler@newt.com> |
| 2230 | 2508 | ||
| 2231 | * Released MH-E version 7.4.1. | 2509 | Released MH-E version 7.4.1. |
| 2232 | 2510 | ||
| 2233 | * MH-E-NEWS, README: Updated for release 7.4.1. | 2511 | * MH-E-NEWS, README: Updated for release 7.4.1. |
| 2234 | 2512 | ||
| @@ -2250,7 +2528,7 @@ | |||
| 2250 | 2528 | ||
| 2251 | 2003-06-24 Bill Wohler <wohler@newt.com> | 2529 | 2003-06-24 Bill Wohler <wohler@newt.com> |
| 2252 | 2530 | ||
| 2253 | * Released MH-E version 7.4. | 2531 | Released MH-E version 7.4. |
| 2254 | 2532 | ||
| 2255 | * MH-E-NEWS, README: Updated for release 7.4. | 2533 | * MH-E-NEWS, README: Updated for release 7.4. |
| 2256 | 2534 | ||
| @@ -3357,7 +3635,7 @@ | |||
| 3357 | 3635 | ||
| 3358 | 2003-04-24 Bill Wohler <wohler@newt.com> | 3636 | 2003-04-24 Bill Wohler <wohler@newt.com> |
| 3359 | 3637 | ||
| 3360 | * Released MH-E version 7.3. | 3638 | Released MH-E version 7.3. |
| 3361 | 3639 | ||
| 3362 | * MH-E-NEWS, README: Updated for release 7.3. | 3640 | * MH-E-NEWS, README: Updated for release 7.3. |
| 3363 | 3641 | ||
| @@ -4915,7 +5193,7 @@ | |||
| 4915 | 5193 | ||
| 4916 | 2003-02-03 Bill Wohler <wohler@newt.com> | 5194 | 2003-02-03 Bill Wohler <wohler@newt.com> |
| 4917 | 5195 | ||
| 4918 | * Released MH-E version 7.2. | 5196 | Released MH-E version 7.2. |
| 4919 | 5197 | ||
| 4920 | * MH-E-NEWS, README: Updated for release 7.2. | 5198 | * MH-E-NEWS, README: Updated for release 7.2. |
| 4921 | 5199 | ||
| @@ -5579,7 +5857,7 @@ | |||
| 5579 | 5857 | ||
| 5580 | 2003-01-07 Bill Wohler <wohler@newt.com> | 5858 | 2003-01-07 Bill Wohler <wohler@newt.com> |
| 5581 | 5859 | ||
| 5582 | * Released MH-E version 7.1. | 5860 | Released MH-E version 7.1. |
| 5583 | 5861 | ||
| 5584 | * MH-E-NEWS, README: Updated for release 7.1. | 5862 | * MH-E-NEWS, README: Updated for release 7.1. |
| 5585 | 5863 | ||
| @@ -6673,7 +6951,7 @@ | |||
| 6673 | 6951 | ||
| 6674 | 2002-11-29 Bill Wohler <wohler@newt.com> | 6952 | 2002-11-29 Bill Wohler <wohler@newt.com> |
| 6675 | 6953 | ||
| 6676 | * Released MH-E version 7.0. | 6954 | Released MH-E version 7.0. |
| 6677 | 6955 | ||
| 6678 | * mh-e.el (Version, mh-version): Updated for release 7.0. | 6956 | * mh-e.el (Version, mh-version): Updated for release 7.0. |
| 6679 | 6957 | ||
| @@ -6698,7 +6976,7 @@ | |||
| 6698 | 6976 | ||
| 6699 | 2002-11-21 Bill Wohler <wohler@newt.com> | 6977 | 2002-11-21 Bill Wohler <wohler@newt.com> |
| 6700 | 6978 | ||
| 6701 | * Released MH-E version 6.1.91. | 6979 | Released MH-E version 6.1.91. |
| 6702 | 6980 | ||
| 6703 | * mh-e.el (Version, mh-version): Updated for release 6.1.91. | 6981 | * mh-e.el (Version, mh-version): Updated for release 6.1.91. |
| 6704 | 6982 | ||
| @@ -6722,7 +7000,7 @@ | |||
| 6722 | 7000 | ||
| 6723 | 2002-11-15 Bill Wohler <wohler@newt.com> | 7001 | 2002-11-15 Bill Wohler <wohler@newt.com> |
| 6724 | 7002 | ||
| 6725 | * Released MH-E version 6.1.90. | 7003 | Released MH-E version 6.1.90. |
| 6726 | 7004 | ||
| 6727 | * README (Compile): New section. Users must now compile MH-E due | 7005 | * README (Compile): New section. Users must now compile MH-E due |
| 6728 | to the vagaries of the various versions of gnus. | 7006 | to the vagaries of the various versions of gnus. |
| @@ -9683,7 +9961,7 @@ | |||
| 9683 | 9961 | ||
| 9684 | 2002-04-08 Bill Wohler <wohler@newt.com> | 9962 | 2002-04-08 Bill Wohler <wohler@newt.com> |
| 9685 | 9963 | ||
| 9686 | * Released mh-e version 6.1. | 9964 | Released mh-e version 6.1. |
| 9687 | 9965 | ||
| 9688 | * mh-e.el (mh-folder-unseen-seq-name): Use "mhparam -component | 9966 | * mh-e.el (mh-folder-unseen-seq-name): Use "mhparam -component |
| 9689 | Unseen-Sequence" command and "Unseen-Sequence: \\(.*\\)$" regexp | 9967 | Unseen-Sequence" command and "Unseen-Sequence: \\(.*\\)$" regexp |
| @@ -9787,7 +10065,7 @@ | |||
| 9787 | 10065 | ||
| 9788 | 2001-12-16 Bill Wohler <wohler@newt.com> | 10066 | 2001-12-16 Bill Wohler <wohler@newt.com> |
| 9789 | 10067 | ||
| 9790 | * Released mh-e version 6.0. | 10068 | Released mh-e version 6.0. |
| 9791 | 10069 | ||
| 9792 | * MH-E-NEWS: Be a little more specific about incompatible changes. | 10070 | * MH-E-NEWS: Be a little more specific about incompatible changes. |
| 9793 | Added info about outdated manual. | 10071 | Added info about outdated manual. |
| @@ -9810,7 +10088,7 @@ | |||
| 9810 | 10088 | ||
| 9811 | 2001-12-14 Bill Wohler <wohler@newt.com> | 10089 | 2001-12-14 Bill Wohler <wohler@newt.com> |
| 9812 | 10090 | ||
| 9813 | * Released mh-e version 5.0.93. | 10091 | Released mh-e version 5.0.93. |
| 9814 | 10092 | ||
| 9815 | * Makefile (MH-E-SRC): Added mh-xemacs-compat.el. | 10093 | * Makefile (MH-E-SRC): Added mh-xemacs-compat.el. |
| 9816 | (MH-E-IMG): Added .pbm images for all. Removed mail_ prefix from | 10094 | (MH-E-IMG): Added .pbm images for all. Removed mail_ prefix from |
| @@ -9995,7 +10273,7 @@ | |||
| 9995 | 10273 | ||
| 9996 | 2001-12-04 Bill Wohler <wohler@newt.com> | 10274 | 2001-12-04 Bill Wohler <wohler@newt.com> |
| 9997 | 10275 | ||
| 9998 | * Released mh-e version 5.0.92. | 10276 | Released mh-e version 5.0.92. |
| 9999 | 10277 | ||
| 10000 | * mh-utils.el (gnus-cite-face-list) | 10278 | * mh-utils.el (gnus-cite-face-list) |
| 10001 | (mh-gnus-article-highlight-citation): Don't autoload. Revert to | 10279 | (mh-gnus-article-highlight-citation): Don't autoload. Revert to |
| @@ -10005,7 +10283,7 @@ | |||
| 10005 | 10283 | ||
| 10006 | 2001-12-03 Bill Wohler <wohler@newt.com> | 10284 | 2001-12-03 Bill Wohler <wohler@newt.com> |
| 10007 | 10285 | ||
| 10008 | * Released mh-e version 5.0.91. | 10286 | Released mh-e version 5.0.91. |
| 10009 | 10287 | ||
| 10010 | * MH-E-NEWS: Removed info about bumping up `max-specpdl-size' now | 10288 | * MH-E-NEWS: Removed info about bumping up `max-specpdl-size' now |
| 10011 | that workaround has been implemented. | 10289 | that workaround has been implemented. |
| @@ -10911,17 +11189,17 @@ | |||
| 10911 | 11189 | ||
| 10912 | 2001-04-14 chad brown <y@mit.edu> | 11190 | 2001-04-14 chad brown <y@mit.edu> |
| 10913 | 11191 | ||
| 10914 | * rearrange the font-lock keywords a bit | 11192 | Rearrange the font-lock keywords a bit. |
| 10915 | 11193 | ||
| 10916 | 2001-04-12 chad brown <y@mit.edu> | 11194 | 2001-04-12 chad brown <y@mit.edu> |
| 10917 | 11195 | ||
| 10918 | * preliminary (somewhat boring) font-lock support for mh-e. More | 11196 | Preliminary (somewhat boring) font-lock support for mh-e. More |
| 10919 | interesting font-lock support probably wants to have better | 11197 | interesting font-lock support probably wants to have better |
| 10920 | support for multiple format files | 11198 | support for multiple format files |
| 10921 | 11199 | ||
| 10922 | 2001-02-24 chad brown <y@mit.edu> | 11200 | 2001-02-24 chad brown <y@mit.edu> |
| 10923 | 11201 | ||
| 10924 | * add default nmh paths to mh-find-prog in mh-utils.el. | 11202 | Add default nmh paths to mh-find-prog in mh-utils.el. |
| 10925 | change to mh-kill-folder in mh-funcs.el to make it more general. | 11203 | change to mh-kill-folder in mh-funcs.el to make it more general. |
| 10926 | 11204 | ||
| 10927 | 2001-02-19 Bill Wohler <wohler@newt.com> | 11205 | 2001-02-19 Bill Wohler <wohler@newt.com> |
| @@ -10934,10 +11212,10 @@ | |||
| 10934 | (dist): Leave release in current directory. | 11212 | (dist): Leave release in current directory. |
| 10935 | 11213 | ||
| 10936 | 11214 | ||
| 10937 | Copyright (C) 2003, 2004, 2005 Free Software Foundation, Inc. | 11215 | Copyright (C) 2003, 2004, 2005 Free Software Foundation, Inc. |
| 10938 | 11216 | ||
| 10939 | Copying and distribution of this file, with or without modification, | 11217 | Copying and distribution of this file, with or without modification, |
| 10940 | are permitted in any medium without royalty provided the copyright | 11218 | are permitted in any medium without royalty provided the copyright |
| 10941 | notice and this notice are preserved. | 11219 | notice and this notice are preserved. |
| 10942 | 11220 | ||
| 10943 | ;;; arch-tag: 87324964-69b6-4925-a3c2-9c1df53d7d51 | 11221 | ;;; arch-tag: 87324964-69b6-4925-a3c2-9c1df53d7d51 |
diff --git a/lisp/mh-e/mh-acros.el b/lisp/mh-e/mh-acros.el index e4921b047df..455daf687a3 100644 --- a/lisp/mh-e/mh-acros.el +++ b/lisp/mh-e/mh-acros.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; mh-acros.el --- Macros used in MH-E | 1 | ;;; mh-acros.el --- Macros used in MH-E |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 2005 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 2004 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Satyaki Das <satyaki@theforce.stanford.edu> | 5 | ;; Author: Satyaki Das <satyaki@theforce.stanford.edu> |
| 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> | 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> |
| @@ -40,6 +40,7 @@ | |||
| 40 | ;;; Code: | 40 | ;;; Code: |
| 41 | 41 | ||
| 42 | (require 'cl) | 42 | (require 'cl) |
| 43 | (require 'advice) | ||
| 43 | 44 | ||
| 44 | ;; The Emacs coding conventions require that the cl package not be required at | 45 | ;; The Emacs coding conventions require that the cl package not be required at |
| 45 | ;; runtime. However, the cl package in versions of Emacs prior to 21.4 left cl | 46 | ;; runtime. However, the cl package in versions of Emacs prior to 21.4 left cl |
| @@ -68,8 +69,9 @@ recognizes that and loads `cl' where appropriate." | |||
| 68 | 69 | ||
| 69 | (defmacro mh-funcall-if-exists (function &rest args) | 70 | (defmacro mh-funcall-if-exists (function &rest args) |
| 70 | "Call FUNCTION with ARGS as parameters if it exists." | 71 | "Call FUNCTION with ARGS as parameters if it exists." |
| 71 | (if (fboundp function) | 72 | (when (fboundp function) |
| 72 | `(funcall ',function ,@args))) | 73 | `(when (fboundp ',function) |
| 74 | (funcall ',function ,@args)))) | ||
| 73 | 75 | ||
| 74 | (defmacro mh-make-local-hook (hook) | 76 | (defmacro mh-make-local-hook (hook) |
| 75 | "Make HOOK local if needed. | 77 | "Make HOOK local if needed. |
diff --git a/lisp/mh-e/mh-alias.el b/lisp/mh-e/mh-alias.el index 7f2cd2f5266..0819c0a7925 100644 --- a/lisp/mh-e/mh-alias.el +++ b/lisp/mh-e/mh-alias.el | |||
| @@ -1,6 +1,7 @@ | |||
| 1 | ;;; mh-alias.el --- MH-E mail alias completion and expansion | 1 | ;;; mh-alias.el --- MH-E mail alias completion and expansion |
| 2 | ;; | 2 | ;; |
| 3 | ;; Copyright (C) 2005 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 1994, 1995, 1996, 1997, |
| 4 | ;; 2001, 2002, 2003, 2004 Free Software Foundation, Inc. | ||
| 4 | 5 | ||
| 5 | ;; Author: Peter S. Galbraith <psg@debian.org> | 6 | ;; Author: Peter S. Galbraith <psg@debian.org> |
| 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> | 7 | ;; Maintainer: Bill Wohler <wohler@newt.com> |
| @@ -162,16 +163,16 @@ Exclude all aliases already in `mh-alias-alist' from `ali'" | |||
| 162 | (while (< (point) (point-max)) | 163 | (while (< (point) (point-max)) |
| 163 | (cond | 164 | (cond |
| 164 | ((looking-at "\\([^:]*\\):[^:]*:\\([^:]*\\):[^:]*:\\([^:]*\\):") | 165 | ((looking-at "\\([^:]*\\):[^:]*:\\([^:]*\\):[^:]*:\\([^:]*\\):") |
| 165 | (when (> (string-to-int (match-string 2)) 200) | 166 | (when (> (string-to-number (match-string 2)) 200) |
| 166 | (let* ((username (match-string 1)) | 167 | (let* ((username (match-string 1)) |
| 167 | (gecos-name (match-string 3)) | 168 | (gecos-name (match-string 3)) |
| 168 | (realname (mh-alias-gecos-name | 169 | (realname (mh-alias-gecos-name |
| 169 | gecos-name username | 170 | gecos-name username |
| 170 | mh-alias-passwd-gecos-comma-separator-flag)) | 171 | mh-alias-passwd-gecos-comma-separator-flag)) |
| 171 | (alias-name (if mh-alias-local-users-prefix | 172 | (alias-name (if mh-alias-local-users-prefix |
| 172 | (concat mh-alias-local-users-prefix | 173 | (concat mh-alias-local-users-prefix |
| 173 | (mh-alias-suggest-alias realname t)) | 174 | (mh-alias-suggest-alias realname t)) |
| 174 | username)) | 175 | username)) |
| 175 | (alias-translation | 176 | (alias-translation |
| 176 | (if (string-equal username realname) | 177 | (if (string-equal username realname) |
| 177 | (concat "<" username ">") | 178 | (concat "<" username ">") |
diff --git a/lisp/mh-e/mh-comp.el b/lisp/mh-e/mh-comp.el index 4f7e413d464..82d0f5b7fd7 100644 --- a/lisp/mh-e/mh-comp.el +++ b/lisp/mh-e/mh-comp.el | |||
| @@ -1,6 +1,7 @@ | |||
| 1 | ;;; mh-comp.el --- MH-E functions for composing messages | 1 | ;;; mh-comp.el --- MH-E functions for composing messages |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1993, 95, 1997, 2000, 2005 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 1993, 1995, 1997, |
| 4 | ;; 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc. | ||
| 4 | 5 | ||
| 5 | ;; Author: Bill Wohler <wohler@newt.com> | 6 | ;; Author: Bill Wohler <wohler@newt.com> |
| 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> | 7 | ;; Maintainer: Bill Wohler <wohler@newt.com> |
| @@ -52,7 +53,6 @@ | |||
| 52 | (defvar mh-identity-menu) | 53 | (defvar mh-identity-menu) |
| 53 | 54 | ||
| 54 | ;;; Autoloads | 55 | ;;; Autoloads |
| 55 | (autoload 'Info-goto-node "info") | ||
| 56 | (autoload 'mail-mode-fill-paragraph "sendmail") | 56 | (autoload 'mail-mode-fill-paragraph "sendmail") |
| 57 | (autoload 'mm-handle-displayed-p "mm-decode") | 57 | (autoload 'mm-handle-displayed-p "mm-decode") |
| 58 | 58 | ||
| @@ -490,8 +490,10 @@ to reply to: | |||
| 490 | cc/all sender and all recipients. | 490 | cc/all sender and all recipients. |
| 491 | If optional prefix argument INCLUDEP provided, then include the message | 491 | If optional prefix argument INCLUDEP provided, then include the message |
| 492 | in the reply using filter `mhl.reply' in your MH directory. | 492 | in the reply using filter `mhl.reply' in your MH directory. |
| 493 | If the file named by `mh-repl-formfile' exists, it is used as a skeleton | 493 | If the file named by `mh-repl-formfile' exists, it is used as a skeleton for |
| 494 | for the reply. | 494 | the reply. If REPLY-TO is cc or all and you're using either the nmh or GNU |
| 495 | mailutils variants and the file names by `mh-repl-group-formfile' exists, it | ||
| 496 | is used instead. | ||
| 495 | 497 | ||
| 496 | See also `mh-send'." | 498 | See also `mh-send'." |
| 497 | (interactive (list | 499 | (interactive (list |
| @@ -1629,15 +1631,22 @@ This is useful in breaking up paragraphs in replies." | |||
| 1629 | (defun mh-complete-word (word choices begin end) | 1631 | (defun mh-complete-word (word choices begin end) |
| 1630 | "Complete WORD at from CHOICES. | 1632 | "Complete WORD at from CHOICES. |
| 1631 | Any match found replaces the text from BEGIN to END." | 1633 | Any match found replaces the text from BEGIN to END." |
| 1632 | (let ((completion (try-completion word choices))) | 1634 | (let ((completion (try-completion word choices)) |
| 1635 | (completions-buffer "*Completions*")) | ||
| 1633 | (cond ((eq completion t) | 1636 | (cond ((eq completion t) |
| 1637 | (ignore-errors | ||
| 1638 | (kill-buffer completions-buffer)) | ||
| 1634 | (message "Completed: %s" word)) | 1639 | (message "Completed: %s" word)) |
| 1635 | ((null completion) | 1640 | ((null completion) |
| 1641 | (ignore-errors | ||
| 1642 | (kill-buffer completions-buffer)) | ||
| 1636 | (message "No completion for `%s'" word)) | 1643 | (message "No completion for `%s'" word)) |
| 1637 | ((stringp completion) | 1644 | ((stringp completion) |
| 1638 | (if (equal word completion) | 1645 | (if (equal word completion) |
| 1639 | (with-output-to-temp-buffer "*Completions*" | 1646 | (with-output-to-temp-buffer completions-buffer |
| 1640 | (display-completion-list (all-completions word choices))) | 1647 | (display-completion-list (all-completions word choices))) |
| 1648 | (ignore-errors | ||
| 1649 | (kill-buffer completions-buffer)) | ||
| 1641 | (delete-region begin end) | 1650 | (delete-region begin end) |
| 1642 | (insert completion)))))) | 1651 | (insert completion)))))) |
| 1643 | 1652 | ||
| @@ -1965,8 +1974,6 @@ Otherwise return the empty string." | |||
| 1965 | 1974 | ||
| 1966 | ;; "C-c /" prefix is used in mh-letter-mode by pgp.el and mailcrypt.el. | 1975 | ;; "C-c /" prefix is used in mh-letter-mode by pgp.el and mailcrypt.el. |
| 1967 | 1976 | ||
| 1968 | ;;;###autoload(add-to-list 'auto-mode-alist '("/drafts/[0-9]+\\'" . mh-letter-mode)) | ||
| 1969 | |||
| 1970 | (provide 'mh-comp) | 1977 | (provide 'mh-comp) |
| 1971 | 1978 | ||
| 1972 | ;;; Local Variables: | 1979 | ;;; Local Variables: |
diff --git a/lisp/mh-e/mh-customize.el b/lisp/mh-e/mh-customize.el index c5689afc13e..54141164391 100644 --- a/lisp/mh-e/mh-customize.el +++ b/lisp/mh-e/mh-customize.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; mh-customize.el --- MH-E customization | 1 | ;;; mh-customize.el --- MH-E customization |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 2005 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 2002, 2003, 2004, 2005 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Bill Wohler <wohler@newt.com> | 5 | ;; Author: Bill Wohler <wohler@newt.com> |
| 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> | 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> |
| @@ -69,8 +69,6 @@ | |||
| 69 | (mh-require-cl) | 69 | (mh-require-cl) |
| 70 | (require 'mh-loaddefs) | 70 | (require 'mh-loaddefs) |
| 71 | 71 | ||
| 72 | (autoload 'Info-goto-node "info") | ||
| 73 | |||
| 74 | (eval-and-compile | 72 | (eval-and-compile |
| 75 | (defvar mh-xemacs-flag (featurep 'xemacs) | 73 | (defvar mh-xemacs-flag (featurep 'xemacs) |
| 76 | "Non-nil means the current Emacs is XEmacs.")) | 74 | "Non-nil means the current Emacs is XEmacs.")) |
| @@ -102,121 +100,115 @@ the frame are removed." | |||
| 102 | 100 | ||
| 103 | ;;; MH-E Customization Groups | 101 | ;;; MH-E Customization Groups |
| 104 | 102 | ||
| 105 | (defgroup mh nil | 103 | (defgroup mh-e nil |
| 106 | "Emacs interface to the MH mail system. | 104 | "Emacs interface to the MH mail system. |
| 107 | MH is the Rand Mail Handler. Other implementations include nmh and GNU | 105 | MH is the Rand Mail Handler. Other implementations include nmh and GNU |
| 108 | mailutils." | 106 | mailutils." |
| 109 | :link '(custom-manual "(mh-e)Top") | 107 | :link '(custom-manual "(mh-e)Top") |
| 110 | :group 'mail) | 108 | :group 'mail) |
| 111 | 109 | ||
| 112 | (defgroup mh-e '((mh custom-group)) ; Sort of an alias for 'mh group | ||
| 113 | "Emacs interface to the MH mail system. | ||
| 114 | MH is the Rand Mail Handler. Other implementations include nmh and GNU | ||
| 115 | mailutils." | ||
| 116 | :link '(custom-manual "(mh-e)Top")) | ||
| 117 | |||
| 118 | (defgroup mh-alias nil | 110 | (defgroup mh-alias nil |
| 119 | "Aliases." | 111 | "Aliases." |
| 120 | :link '(custom-manual "(mh-e)Aliases") | 112 | :link '(custom-manual "(mh-e)Aliases") |
| 121 | :prefix "mh-alias-" | 113 | :prefix "mh-alias-" |
| 122 | :group 'mh) | 114 | :group 'mh-e) |
| 123 | 115 | ||
| 124 | (defgroup mh-folder nil | 116 | (defgroup mh-folder nil |
| 125 | "Organizing your mail with folders." | 117 | "Organizing your mail with folders." |
| 126 | :prefix "mh-" | 118 | :prefix "mh-" |
| 127 | :link '(custom-manual "(mh-e)Organizing") | 119 | :link '(custom-manual "(mh-e)Organizing") |
| 128 | :group 'mh) | 120 | :group 'mh-e) |
| 129 | 121 | ||
| 130 | (defgroup mh-folder-selection nil | 122 | (defgroup mh-folder-selection nil |
| 131 | "Folder selection." | 123 | "Folder selection." |
| 132 | :prefix "mh-" | 124 | :prefix "mh-" |
| 133 | :link '(custom-manual "(mh-e)Folder Selection") | 125 | :link '(custom-manual "(mh-e)Folder Selection") |
| 134 | :group 'mh) | 126 | :group 'mh-e) |
| 135 | 127 | ||
| 136 | (defgroup mh-identity nil | 128 | (defgroup mh-identity nil |
| 137 | "Identities." | 129 | "Identities." |
| 138 | :link '(custom-manual "(mh-e)Identities") | 130 | :link '(custom-manual "(mh-e)Identities") |
| 139 | :prefix "mh-identity-" | 131 | :prefix "mh-identity-" |
| 140 | :group 'mh) | 132 | :group 'mh-e) |
| 141 | 133 | ||
| 142 | (defgroup mh-inc nil | 134 | (defgroup mh-inc nil |
| 143 | "Incorporating your mail." | 135 | "Incorporating your mail." |
| 144 | :prefix "mh-inc-" | 136 | :prefix "mh-inc-" |
| 145 | :link '(custom-manual "(mh-e)Incorporating Mail") | 137 | :link '(custom-manual "(mh-e)Incorporating Mail") |
| 146 | :group 'mh) | 138 | :group 'mh-e) |
| 147 | 139 | ||
| 148 | (defgroup mh-index nil | 140 | (defgroup mh-index nil |
| 149 | "Searching." | 141 | "Searching." |
| 150 | :link '(custom-manual "(mh-e)Searching") | 142 | :link '(custom-manual "(mh-e)Searching") |
| 151 | :prefix "mh-index-" | 143 | :prefix "mh-index-" |
| 152 | :group 'mh) | 144 | :group 'mh-e) |
| 153 | 145 | ||
| 154 | (defgroup mh-junk nil | 146 | (defgroup mh-junk nil |
| 155 | "Dealing with junk mail." | 147 | "Dealing with junk mail." |
| 156 | :link '(custom-manual "(mh-e)Junk") | 148 | :link '(custom-manual "(mh-e)Junk") |
| 157 | :prefix "mh-junk-" | 149 | :prefix "mh-junk-" |
| 158 | :group 'mh) | 150 | :group 'mh-e) |
| 159 | 151 | ||
| 160 | (defgroup mh-letter nil | 152 | (defgroup mh-letter nil |
| 161 | "Editing a draft." | 153 | "Editing a draft." |
| 162 | :prefix "mh-" | 154 | :prefix "mh-" |
| 163 | :link '(custom-manual "(mh-e)Editing Drafts") | 155 | :link '(custom-manual "(mh-e)Editing Drafts") |
| 164 | :group 'mh) | 156 | :group 'mh-e) |
| 165 | 157 | ||
| 166 | (defgroup mh-ranges nil | 158 | (defgroup mh-ranges nil |
| 167 | "Ranges." | 159 | "Ranges." |
| 168 | :prefix "mh-" | 160 | :prefix "mh-" |
| 169 | :link '(custom-manual "(mh-e)Ranges") | 161 | :link '(custom-manual "(mh-e)Ranges") |
| 170 | :group 'mh) | 162 | :group 'mh-e) |
| 171 | 163 | ||
| 172 | (defgroup mh-scan-line-formats nil | 164 | (defgroup mh-scan-line-formats nil |
| 173 | "Scan line formats." | 165 | "Scan line formats." |
| 174 | :link '(custom-manual "(mh-e)Scan Line Formats") | 166 | :link '(custom-manual "(mh-e)Scan Line Formats") |
| 175 | :prefix "mh-" | 167 | :prefix "mh-" |
| 176 | :group 'mh) | 168 | :group 'mh-e) |
| 177 | 169 | ||
| 178 | (defgroup mh-sending-mail nil | 170 | (defgroup mh-sending-mail nil |
| 179 | "Sending mail." | 171 | "Sending mail." |
| 180 | :prefix "mh-" | 172 | :prefix "mh-" |
| 181 | :link '(custom-manual "(mh-e)Sending Mail") | 173 | :link '(custom-manual "(mh-e)Sending Mail") |
| 182 | :group 'mh) | 174 | :group 'mh-e) |
| 183 | 175 | ||
| 184 | (defgroup mh-sequences nil | 176 | (defgroup mh-sequences nil |
| 185 | "Sequences." | 177 | "Sequences." |
| 186 | :prefix "mh-" | 178 | :prefix "mh-" |
| 187 | :link '(custom-manual "(mh-e)Sequences") | 179 | :link '(custom-manual "(mh-e)Sequences") |
| 188 | :group 'mh) | 180 | :group 'mh-e) |
| 189 | 181 | ||
| 190 | (defgroup mh-show nil | 182 | (defgroup mh-show nil |
| 191 | "Reading your mail." | 183 | "Reading your mail." |
| 192 | :prefix "mh-" | 184 | :prefix "mh-" |
| 193 | :link '(custom-manual "(mh-e)Reading Mail") | 185 | :link '(custom-manual "(mh-e)Reading Mail") |
| 194 | :group 'mh) | 186 | :group 'mh-e) |
| 195 | 187 | ||
| 196 | (defgroup mh-speed nil | 188 | (defgroup mh-speed nil |
| 197 | "The speedbar." | 189 | "The speedbar." |
| 198 | :prefix "mh-speed-" | 190 | :prefix "mh-speed-" |
| 199 | :link '(custom-manual "(mh-e)Speedbar") | 191 | :link '(custom-manual "(mh-e)Speedbar") |
| 200 | :group 'mh) | 192 | :group 'mh-e) |
| 201 | 193 | ||
| 202 | (defgroup mh-toolbar nil | 194 | (defgroup mh-toolbar nil |
| 203 | "The toolbar" | 195 | "The toolbar" |
| 204 | :link '(custom-manual "(mh-e)Toolbar") | 196 | :link '(custom-manual "(mh-e)Toolbar") |
| 205 | :prefix "mh-" | 197 | :prefix "mh-" |
| 206 | :group 'mh) | 198 | :group 'mh-e) |
| 207 | 199 | ||
| 208 | (defgroup mh-faces nil | 200 | (defgroup mh-faces nil |
| 209 | "Faces used in MH-E." | 201 | "Faces used in MH-E." |
| 210 | :link '(custom-manual "(mh-e)Top") | 202 | :link '(custom-manual "(mh-e)Top") |
| 211 | :prefix "mh-" | 203 | :prefix "mh-" |
| 212 | :group 'faces | 204 | :group 'faces |
| 213 | :group 'mh) | 205 | :group 'mh-e) |
| 214 | 206 | ||
| 215 | (defgroup mh-hooks nil | 207 | (defgroup mh-hooks nil |
| 216 | "MH-E hooks." | 208 | "MH-E hooks." |
| 217 | :link '(custom-manual "(mh-e)Top") | 209 | :link '(custom-manual "(mh-e)Top") |
| 218 | :prefix "mh-" | 210 | :prefix "mh-" |
| 219 | :group 'mh) | 211 | :group 'mh-e) |
| 220 | 212 | ||
| 221 | ;;; Faces | 213 | ;;; Faces |
| 222 | 214 | ||
| @@ -280,7 +272,7 @@ accordingly." | |||
| 280 | :set (lambda (symbol value) | 272 | :set (lambda (symbol value) |
| 281 | (set-default symbol value) ;Done in mh-variant-set-variant! | 273 | (set-default symbol value) ;Done in mh-variant-set-variant! |
| 282 | (mh-variant-set value)) | 274 | (mh-variant-set value)) |
| 283 | :group 'mh) | 275 | :group 'mh-e) |
| 284 | 276 | ||
| 285 | 277 | ||
| 286 | 278 | ||
| @@ -448,14 +440,34 @@ information." | |||
| 448 | (defcustom mh-identity-list nil | 440 | (defcustom mh-identity-list nil |
| 449 | "*List of identities. | 441 | "*List of identities. |
| 450 | 442 | ||
| 451 | Each element consists of an identity label, and a collection of header fields | 443 | To customize this option, click on the `INS' button and enter a label such as |
| 452 | and a signature to insert if the identity is selected (see | 444 | `Home' or `Work'. Then click on the `INS' button with the label `Add at least |
| 453 | `mh-identity-default', `mh-insert-identity' and the `Identity' menu in a | 445 | one item below'. Then choose one of the items in the `Value Menu'. |
| 454 | MH-Letter buffer). The `Value Menu' contains the common header fields `From' | 446 | |
| 455 | and `Organization'. Other header fields may be added using the `Other Field' | 447 | You can specify an alternate `From:' header field using the `From Field' menu |
| 456 | menu item. The `Signature' menu item is used to insert a signature with | 448 | item. You must include a valid email address. A standard format is `First Last |
| 457 | `mh-insert-signature'. The `GPG Key ID' menu item is used to specify a | 449 | <login@@host.domain>'. If you use an initial with a period, then you must |
| 458 | different key to sign or encrypt messages." | 450 | quote your name as in `\"First I. Last\" <login@@host.domain>'. People usually |
| 451 | list the name of the company where they work using the `Organization Field' | ||
| 452 | menu item. Set any arbitrary header field and value in the `Other Field' menu | ||
| 453 | item. Unless the header field is a standard one, precede the name of your | ||
| 454 | field's label with `X-', as in `X-Fruit-of-the-Day:'. The value of | ||
| 455 | `Attribution Verb' overrides the setting of | ||
| 456 | `mh-extract-from-attribution-verb'. Set your signature with the `Signature' | ||
| 457 | menu item. You can specify the contents of `mh-signature-file-name', a file, | ||
| 458 | or a function. Specify a different key to sign or encrypt messages with the | ||
| 459 | `GPG Key ID' menu item. | ||
| 460 | |||
| 461 | You can select the identities you have added via the menu called `Identity' in | ||
| 462 | the MH-Letter buffer. You can also use \\[mh-insert-identity]. To clear the | ||
| 463 | fields and signature added by the identity, select the `None' identity. | ||
| 464 | |||
| 465 | The `Identity' menu contains two other items to save you from having to set | ||
| 466 | the identity on every message. The menu item `Set Default for Session' can be | ||
| 467 | used to set the default identity to the current identity until you exit Emacs. | ||
| 468 | The menu item `Save as Default' sets the option `mh-identity-default' to the | ||
| 469 | current identity setting. You can also customize the `mh-identity-default' | ||
| 470 | option in the usual fashion." | ||
| 459 | :type '(repeat (list :tag "" | 471 | :type '(repeat (list :tag "" |
| 460 | (string :tag "Label") | 472 | (string :tag "Label") |
| 461 | (repeat :tag "Add at least one item below" | 473 | (repeat :tag "Add at least one item below" |
| @@ -489,12 +501,38 @@ different key to sign or encrypt messages." | |||
| 489 | 501 | ||
| 490 | (defcustom mh-auto-fields-list nil | 502 | (defcustom mh-auto-fields-list nil |
| 491 | "List of recipients for which header lines are automatically inserted. | 503 | "List of recipients for which header lines are automatically inserted. |
| 492 | Each element consists of the recipient, which is a regular expression, and a | 504 | |
| 493 | collection of header fields and identities to insert if the message is sent to | 505 | This option can be used to set the identity depending on the recipient. To |
| 494 | this recipient. The `Value Menu' contains the common header fields `Fcc' and | 506 | customize this option, click on the `INS' button and enter a regular |
| 495 | `Mail-Followup-To'. Other header fields may be added using the `Other Field' | 507 | expression for the recipient's address. Click on the `INS' button with the |
| 496 | menu item. The `Identity' menu item is used to insert entire identities with | 508 | `Add at least one item below' label. Then choose one of the items in the |
| 497 | `mh-insert-identity'." | 509 | `Value Menu'. |
| 510 | |||
| 511 | The `Identity' menu item is used to select an identity from those configured | ||
| 512 | in `mh-identity-list'. All of the information for that identity will be added | ||
| 513 | if the recipient matches. The `Fcc Field' menu item is used to select a folder | ||
| 514 | that is used in the `Fcc:' header. When you send the message, MH will put a | ||
| 515 | copy of your message in this folder. The `Mail-Followup-To Field' menu item is | ||
| 516 | used to insert an `Mail-Followup-To:' header field with the recipients you | ||
| 517 | provide. If the recipient's mail user agent supports this header field (as nmh | ||
| 518 | does), then their replies will go to the addresses listed. This is useful if | ||
| 519 | their replies go both to the list and to you and you don't have a mechanism to | ||
| 520 | suppress duplicates. If you reply to someone not on the list, you must either | ||
| 521 | remove the `Mail-Followup-To:' field, or ensure the recipient is also listed | ||
| 522 | there so that he receives replies to your reply. Other header fields may be | ||
| 523 | added using the `Other Field' menu item. | ||
| 524 | |||
| 525 | These fields can only be added after the recipient is known. Once the header | ||
| 526 | contains one or more recipients, run the \\[mh-insert-auto-fields] command or | ||
| 527 | choose the `Identity -> Insert Auto Fields' menu item to insert these fields | ||
| 528 | manually. However, you can just send the message and the fields will be added | ||
| 529 | automatically. You are given a chance to see these fields and to confirm them | ||
| 530 | before the message is actually sent. You can do away with this confirmation by | ||
| 531 | turning off the option `mh-auto-fields-prompt-flag'. | ||
| 532 | |||
| 533 | You should avoid using the same header field in `mh-auto-fields-list' and | ||
| 534 | `mh-identity-list' definitions that may apply to the same message as the | ||
| 535 | result is undefined." | ||
| 498 | :type `(repeat | 536 | :type `(repeat |
| 499 | (list :tag "" | 537 | (list :tag "" |
| 500 | (string :tag "Recipient") | 538 | (string :tag "Recipient") |
| @@ -525,7 +563,8 @@ See `mh-auto-fields-list'." | |||
| 525 | :group 'mh-identity) | 563 | :group 'mh-identity) |
| 526 | 564 | ||
| 527 | (defcustom mh-identity-default nil | 565 | (defcustom mh-identity-default nil |
| 528 | "Default identity to use when `mh-letter-mode' is called." | 566 | "Default identity to use when `mh-letter-mode' is called. |
| 567 | See `mh-identity-list'." | ||
| 529 | :type (append | 568 | :type (append |
| 530 | '(radio) | 569 | '(radio) |
| 531 | (cons '(const :tag "None" nil) | 570 | (cons '(const :tag "None" nil) |
| @@ -534,16 +573,32 @@ See `mh-auto-fields-list'." | |||
| 534 | :group 'mh-identity) | 573 | :group 'mh-identity) |
| 535 | 574 | ||
| 536 | (defcustom mh-identity-handlers | 575 | (defcustom mh-identity-handlers |
| 537 | '((":default" . mh-identity-handler-bottom) | 576 | '(("From" . mh-identity-handler-top) |
| 538 | ("from" . mh-identity-handler-top) | 577 | (":default" . mh-identity-handler-bottom) |
| 539 | (":attribution-verb" . mh-identity-handler-attribution-verb) | 578 | (":attribution-verb" . mh-identity-handler-attribution-verb) |
| 540 | (":signature" . mh-identity-handler-signature) | 579 | (":signature" . mh-identity-handler-signature) |
| 541 | (":pgg-default-user-id" . mh-identity-handler-gpg-identity)) | 580 | (":pgg-default-user-id" . mh-identity-handler-gpg-identity)) |
| 542 | "Handler functions for fields in `mh-identity-list'. | 581 | "Handler functions for fields in `mh-identity-list'. |
| 543 | This is an alist of fields (strings) and handlers (functions). Strings are | 582 | |
| 544 | lowercase. Use \":signature\" for Signature and \":pgg-default-user-id\" for | 583 | This option is used to change the way that fields, signatures, and |
| 545 | GPG Key ID. The function associated with the string \":default\" is used if no | 584 | attributions in `mh-identity-list' are added. To customize |
| 546 | other functions are appropriate." | 585 | `mh-identity-handlers', replace the name of an existing handler function |
| 586 | associated with the field you want to change with the name of a function you | ||
| 587 | have written. You can also click on an `INS' button and insert a field of your | ||
| 588 | choice and the name of the function you have written to handle it. | ||
| 589 | |||
| 590 | The `Field' field can be any field that you've used in your | ||
| 591 | `mh-identity-list'. The special fields `:attribution-verb', `:signature', or | ||
| 592 | `:pgg-default-user-id' are used for the `mh-identity-list' choices | ||
| 593 | `Attribution Verb', `Signature', and `GPG Key ID' respectively. | ||
| 594 | |||
| 595 | The handler associated with the `:default' field is used when no other field | ||
| 596 | matches. | ||
| 597 | |||
| 598 | The handler functions are passed two or three arguments: the FIELD itself (for | ||
| 599 | example, `From'), or one of the special fields (for example, `:signature'), | ||
| 600 | and the ACTION `'remove' or `'add'. If the action is `'add', an additional | ||
| 601 | argument containing the VALUE for the field is given." | ||
| 547 | :type '(repeat (cons (string :tag "Field") function)) | 602 | :type '(repeat (cons (string :tag "Field") function)) |
| 548 | :group 'mh-identity) | 603 | :group 'mh-identity) |
| 549 | 604 | ||
| @@ -552,45 +607,45 @@ other functions are appropriate." | |||
| 552 | ;;; Incorporating Your Mail (:group 'mh-inc) | 607 | ;;; Incorporating Your Mail (:group 'mh-inc) |
| 553 | 608 | ||
| 554 | (defcustom mh-inc-prog "inc" | 609 | (defcustom mh-inc-prog "inc" |
| 555 | "*Program to run to incorporate new mail into a folder. | 610 | "*Program to incorporate new mail into a folder. |
| 556 | Normally \"inc\". This program is relative to the `mh-progs' directory unless | 611 | |
| 557 | it is an absolute pathname." | 612 | This program generates a one-line summary for each of the new messages. Unless |
| 613 | it is an absolute pathname, the file is assumed to be in the `mh-progs' | ||
| 614 | directory. You may also link a file to `inc' that uses a different format. | ||
| 615 | You'll then need to modify several scan line format variables appropriately." | ||
| 558 | :type 'string | 616 | :type 'string |
| 559 | :group 'mh-inc) | 617 | :group 'mh-inc) |
| 560 | 618 | ||
| 561 | (defcustom mh-inc-spool-list nil | 619 | (defcustom mh-inc-spool-list nil |
| 562 | "*Alist of alternate spool files, corresponding folders and keybindings. | 620 | "*Alternate spool files. |
| 563 | This option will be described by example. | 621 | |
| 622 | You can use the `mh-inc-spool-list' variable to direct MH-E to retrieve mail | ||
| 623 | from arbitrary spool files other than your system mailbox, file it in folders | ||
| 624 | other than your `+inbox', and assign key bindings to incorporate this mail. | ||
| 564 | 625 | ||
| 565 | Suppose you have subscribed to the mh-e-devel mailing list and you use | 626 | Suppose you are subscribed to the `mh-e-devel' mailing list and you use |
| 566 | procmail to filter its mail into `~/mail/mh-e' with the following | 627 | `procmail' to filter this mail into `~/mail/mh-e' with the following recipe in |
| 567 | `.procmailrc' recipe: | 628 | `.procmailrc': |
| 568 | 629 | ||
| 569 | MAILDIR=$HOME/mail | 630 | MAILDIR=$HOME/mail |
| 570 | :0: | 631 | :0: |
| 571 | * ^From mh-e-devel-admin@lists.sourceforge.net | 632 | * ^From mh-e-devel-admin@stop.mail-abuse.org |
| 572 | mh-e | 633 | mh-e |
| 573 | 634 | ||
| 574 | If you wanted to incorporate that spool file into an MH folder called mh-e | 635 | In order to incorporate `~/mail/mh-e' into `+mh-e' with an `I m' |
| 575 | with the \"I m\" or \\[mh-inc-spool-mh-e] commands, you would use the | 636 | \(`mh-inc-spool-mh-e'\) command, customize this option, and click on the `INS' |
| 576 | following: | 637 | button. Enter a `Spool File' of `~/mail/mh-e', a `Folder' of `mh-e', and a |
| 638 | `Key Binding' of `m'. | ||
| 577 | 639 | ||
| 578 | Spool File: ~/mail/mh-e | 640 | You can use `xbuffy' to automate the incorporation of this mail using the |
| 579 | Folder: mh-e | 641 | `gnudoit' command in the `gnuserv' package as follows: |
| 580 | Key Binding: m | ||
| 581 | |||
| 582 | Then, you could also install `xbuffy' and configure an extra mailbox using the | ||
| 583 | gnuserv package to run the `mh-inc-spool-mh-e' command in Emacs: | ||
| 584 | 642 | ||
| 585 | box ~/mail/mh-e | 643 | box ~/mail/mh-e |
| 586 | title mh-e | 644 | title mh-e |
| 587 | origMode | 645 | origMode |
| 588 | polltime 10 | 646 | polltime 10 |
| 589 | headertime 0 | 647 | headertime 0 |
| 590 | command gnudoit -q '(mh-inc-spool-mh-e)' | 648 | command gnudoit -q '(mh-inc-spool-mh-e)'" |
| 591 | |||
| 592 | To incorporate the spool file, click the xbuffy box with the middle mouse | ||
| 593 | button." | ||
| 594 | :type '(repeat (list (file :tag "Spool File") | 649 | :type '(repeat (list (file :tag "Spool File") |
| 595 | (string :tag "Folder") | 650 | (string :tag "Folder") |
| 596 | (character :tag "Key Binding"))) | 651 | (character :tag "Key Binding"))) |
| @@ -602,10 +657,10 @@ button." | |||
| 602 | ;;; Searching (:group 'mh-index) | 657 | ;;; Searching (:group 'mh-index) |
| 603 | 658 | ||
| 604 | (defcustom mh-index-new-messages-folders t | 659 | (defcustom mh-index-new-messages-folders t |
| 605 | "Folders searched for the `unseen' sequence. | 660 | "Folders searched for the \"unseen\" sequence. |
| 606 | This option can be set to `Inbox' to search the `+inbox' folder or `All' to | 661 | Set this option to \"Inbox\" to search the \"+inbox\" folder or \"All\" to |
| 607 | search all of the top level folders. Otherwise, list the folders that should | 662 | search all of the top level folders. Otherwise, list the folders that should |
| 608 | be searched with the `Choose Folders' menu item. | 663 | be searched with the \"Choose Folders\" menu item. |
| 609 | 664 | ||
| 610 | See also `mh-recursive-folders-flag'." | 665 | See also `mh-recursive-folders-flag'." |
| 611 | :group 'mh-index | 666 | :group 'mh-index |
| @@ -633,9 +688,9 @@ found in the documentation of `mh-index-search'." | |||
| 633 | 688 | ||
| 634 | (defcustom mh-index-ticked-messages-folders t | 689 | (defcustom mh-index-ticked-messages-folders t |
| 635 | "Folders searched for `mh-tick-seq'. | 690 | "Folders searched for `mh-tick-seq'. |
| 636 | This option can be set to `Inbox' to search the `+inbox' folder or `All' to | 691 | Set this option to \"Inbox\" to search the \"+inbox\" folder or \"All\" to |
| 637 | search all of the top level folders. Otherwise, list the folders that should | 692 | search all of the top level folders. Otherwise, list the folders that should |
| 638 | be searched with the `Choose Folders' menu item. | 693 | be searched with the \"Choose Folders\" menu item. |
| 639 | 694 | ||
| 640 | See also `mh-recursive-folders-flag'." | 695 | See also `mh-recursive-folders-flag'." |
| 641 | :group 'mh-index | 696 | :group 'mh-index |
| @@ -672,6 +727,15 @@ bound to the new value of `mh-junk-program'. The function sets the variable | |||
| 672 | finally return (car element))))) | 727 | finally return (car element))))) |
| 673 | 728 | ||
| 674 | ;; User customizable variables | 729 | ;; User customizable variables |
| 730 | (defcustom mh-junk-background nil | ||
| 731 | "If on, spam programs are run in background. | ||
| 732 | By default, the programs are run in the foreground, but this can be slow when | ||
| 733 | junking large numbers of messages. If you have enough memory or don't junk | ||
| 734 | that many messages at the same time, you might try turning on this option." | ||
| 735 | :type '(choice (const :tag "Off" nil) | ||
| 736 | (const :tag "On" 0)) | ||
| 737 | :group 'mh-junk) | ||
| 738 | |||
| 675 | (defcustom mh-junk-disposition nil | 739 | (defcustom mh-junk-disposition nil |
| 676 | "Disposition of junk mail." | 740 | "Disposition of junk mail." |
| 677 | :type '(choice (const :tag "Delete Spam" nil) | 741 | :type '(choice (const :tag "Delete Spam" nil) |
| @@ -680,10 +744,12 @@ bound to the new value of `mh-junk-program'. The function sets the variable | |||
| 680 | 744 | ||
| 681 | (defcustom mh-junk-program nil | 745 | (defcustom mh-junk-program nil |
| 682 | "Spam program that MH-E should use. | 746 | "Spam program that MH-E should use. |
| 683 | The default setting of this option is `Auto-detect' which means that MH-E will | 747 | |
| 684 | automatically choose one of SpamAssassin, Bogofilter, or SpamProbe in that | 748 | The default setting of this option is \"Auto-detect\" which means that MH-E |
| 685 | order. If, for example, you have both SpamAssassin and Bogofilter installed | 749 | will automatically choose one of SpamAssassin, Bogofilter, or SpamProbe in |
| 686 | and you want to use BogoFilter, then you can set this option to `Bogofilter'." | 750 | that order. If, for example, you have both SpamAssassin and Bogofilter |
| 751 | installed and you want to use BogoFilter, then you can set this option to | ||
| 752 | \"Bogofilter\"." | ||
| 687 | :type '(choice (const :tag "Auto-detect" nil) | 753 | :type '(choice (const :tag "Auto-detect" nil) |
| 688 | (const :tag "SpamAssassin" spamassassin) | 754 | (const :tag "SpamAssassin" spamassassin) |
| 689 | (const :tag "Bogofilter" bogofilter) | 755 | (const :tag "Bogofilter" bogofilter) |
| @@ -691,32 +757,10 @@ and you want to use BogoFilter, then you can set this option to `Bogofilter'." | |||
| 691 | :set 'mh-junk-choose | 757 | :set 'mh-junk-choose |
| 692 | :group 'mh-junk) | 758 | :group 'mh-junk) |
| 693 | 759 | ||
| 694 | (defcustom mh-junk-background nil | ||
| 695 | "If on, spam programs are run in background. | ||
| 696 | By default, the programs are run in the foreground, but this can be slow when | ||
| 697 | junking large numbers of messages. If you have enough memory or don't junk | ||
| 698 | that many messages at the same time, you might try turning on this option." | ||
| 699 | :type '(choice (const :tag "Off" nil) | ||
| 700 | (const :tag "On" 0)) | ||
| 701 | :group 'mh-junk) | ||
| 702 | |||
| 703 | 760 | ||
| 704 | 761 | ||
| 705 | ;;; Editing a Draft (:group 'mh-letter) | 762 | ;;; Editing a Draft (:group 'mh-letter) |
| 706 | 763 | ||
| 707 | (defcustom mh-mml-method-default (if mh-gnus-pgp-support-flag "pgpmime" "none") | ||
| 708 | "Default method to use in security directives." | ||
| 709 | :type '(choice (const :tag "PGP (MIME)" "pgpmime") | ||
| 710 | (const :tag "PGP" "pgp") | ||
| 711 | (const :tag "S/MIME" "smime") | ||
| 712 | (const :tag "None" "none")) | ||
| 713 | :group 'mh-letter) | ||
| 714 | |||
| 715 | (defcustom mh-compose-forward-as-mime-flag t | ||
| 716 | "Non-nil means that messages are forwarded as a MIME part." | ||
| 717 | :type 'boolean | ||
| 718 | :group 'mh-letter) | ||
| 719 | |||
| 720 | (defcustom mh-compose-insertion (if (locate-library "mml") 'gnus 'mhn) | 764 | (defcustom mh-compose-insertion (if (locate-library "mml") 'gnus 'mhn) |
| 721 | "Type of MIME message directives in messages. | 765 | "Type of MIME message directives in messages. |
| 722 | 766 | ||
| @@ -761,11 +805,6 @@ by \\<mh-letter-mode-map>\\[mh-insert-letter] or \\[mh-yank-cur-msg]." | |||
| 761 | :type 'string | 805 | :type 'string |
| 762 | :group 'mh-letter) | 806 | :group 'mh-letter) |
| 763 | 807 | ||
| 764 | (defcustom mh-insert-x-mailer-flag t | ||
| 765 | "*Non-nil means append an X-Mailer field to the header." | ||
| 766 | :type 'boolean | ||
| 767 | :group 'mh-letter) | ||
| 768 | |||
| 769 | (defcustom mh-letter-complete-function 'ispell-complete-word | 808 | (defcustom mh-letter-complete-function 'ispell-complete-word |
| 770 | "*Function to call when completing outside of address or folder fields. | 809 | "*Function to call when completing outside of address or folder fields. |
| 771 | By default, this is set to `ispell-complete-word'." | 810 | By default, this is set to `ispell-complete-word'." |
| @@ -780,16 +819,12 @@ and it's best to avoid quoted lines that span more than 80 columns." | |||
| 780 | :type 'integer | 819 | :type 'integer |
| 781 | :group 'mh-letter) | 820 | :group 'mh-letter) |
| 782 | 821 | ||
| 783 | (defcustom mh-reply-show-message-flag t | 822 | (defcustom mh-mml-method-default (if mh-gnus-pgp-support-flag "pgpmime" "none") |
| 784 | "*Non-nil means the show buffer is displayed using \\<mh-letter-mode-map>\\[mh-reply]. | 823 | "Default method to use in security directives." |
| 785 | 824 | :type '(choice (const :tag "PGP (MIME)" "pgpmime") | |
| 786 | The setting of this variable determines whether the MH `show-buffer' is | 825 | (const :tag "PGP" "pgp") |
| 787 | displayed with the current message when using `mh-reply' without a prefix | 826 | (const :tag "S/MIME" "smime") |
| 788 | argument. Set it to nil if you already include the message automatically | 827 | (const :tag "None" "none")) |
| 789 | in your draft using | ||
| 790 | repl: -filter repl.filter | ||
| 791 | in your ~/.mh_profile file." | ||
| 792 | :type 'boolean | ||
| 793 | :group 'mh-letter) | 828 | :group 'mh-letter) |
| 794 | 829 | ||
| 795 | (defcustom mh-signature-file-name "~/.signature" | 830 | (defcustom mh-signature-file-name "~/.signature" |
| @@ -881,14 +916,14 @@ If nil, yank only the portion of the message following the point. | |||
| 881 | If the show buffer has a region, this variable is ignored unless its value is | 916 | If the show buffer has a region, this variable is ignored unless its value is |
| 882 | one of `attribution' or `autoattrib' in which case the attribution is added | 917 | one of `attribution' or `autoattrib' in which case the attribution is added |
| 883 | to the yanked region." | 918 | to the yanked region." |
| 884 | :type '(choice (const :tag "Below point" nil) | 919 | :type '(choice (const :tag "Body and Header" t) |
| 885 | (const :tag "Without header" body) | 920 | (const :tag "Body" body) |
| 921 | (const :tag "Below Point" nil) | ||
| 886 | (const :tag "Invoke supercite" supercite) | 922 | (const :tag "Invoke supercite" supercite) |
| 887 | (const :tag "Invoke supercite, automatically" autosupercite) | 923 | (const :tag "Invoke supercite, Automatically" autosupercite) |
| 888 | (const :tag "Without header, with attribution" attribution) | 924 | (const :tag "Body With Attribution" attribution) |
| 889 | (const :tag "Without header, with attribution, automatically" | 925 | (const :tag "Body With Attribution, Automatically" |
| 890 | autoattrib) | 926 | autoattrib)) |
| 891 | (const :tag "Entire message with headers" t)) | ||
| 892 | :group 'mh-letter) | 927 | :group 'mh-letter) |
| 893 | 928 | ||
| 894 | 929 | ||
| @@ -947,6 +982,11 @@ for relative to the `mh-progs' directory unless it is an absolute pathname." | |||
| 947 | 982 | ||
| 948 | ;;; Sending Mail (:group 'mh-sending-mail) | 983 | ;;; Sending Mail (:group 'mh-sending-mail) |
| 949 | 984 | ||
| 985 | (defcustom mh-compose-forward-as-mime-flag t | ||
| 986 | "Non-nil means that messages are forwarded as a MIME part." | ||
| 987 | :type 'boolean | ||
| 988 | :group 'mh-sending-mail) | ||
| 989 | |||
| 950 | (defcustom mh-compose-letter-function nil | 990 | (defcustom mh-compose-letter-function nil |
| 951 | "Invoked when setting up a letter draft. | 991 | "Invoked when setting up a letter draft. |
| 952 | It is passed three arguments: TO recipients, SUBJECT, and CC recipients." | 992 | It is passed three arguments: TO recipients, SUBJECT, and CC recipients." |
| @@ -965,6 +1005,11 @@ message and the original subject line." | |||
| 965 | :type 'string | 1005 | :type 'string |
| 966 | :group 'mh-sending-mail) | 1006 | :group 'mh-sending-mail) |
| 967 | 1007 | ||
| 1008 | (defcustom mh-insert-x-mailer-flag t | ||
| 1009 | "*Non-nil means append an X-Mailer field to the header." | ||
| 1010 | :type 'boolean | ||
| 1011 | :group 'mh-sending-mail) | ||
| 1012 | |||
| 968 | (defcustom mh-reply-default-reply-to nil | 1013 | (defcustom mh-reply-default-reply-to nil |
| 969 | "*Sets the person or persons to whom a reply will be sent. | 1014 | "*Sets the person or persons to whom a reply will be sent. |
| 970 | If nil, prompt for recipient. If non-nil, then \\<mh-folder-mode-map>`\\[mh-reply]' will use this | 1015 | If nil, prompt for recipient. If non-nil, then \\<mh-folder-mode-map>`\\[mh-reply]' will use this |
| @@ -975,6 +1020,18 @@ The values \"cc\" and \"all\" do the same thing." | |||
| 975 | (const "cc") (const "all")) | 1020 | (const "cc") (const "all")) |
| 976 | :group 'mh-sending-mail) | 1021 | :group 'mh-sending-mail) |
| 977 | 1022 | ||
| 1023 | (defcustom mh-reply-show-message-flag t | ||
| 1024 | "*Non-nil means the show buffer is displayed using \\<mh-letter-mode-map>\\[mh-reply]. | ||
| 1025 | |||
| 1026 | The setting of this variable determines whether the MH `show-buffer' is | ||
| 1027 | displayed with the current message when using `mh-reply' without a prefix | ||
| 1028 | argument. Set it to nil if you already include the message automatically | ||
| 1029 | in your draft using | ||
| 1030 | repl: -filter repl.filter | ||
| 1031 | in your ~/.mh_profile file." | ||
| 1032 | :type 'boolean | ||
| 1033 | :group 'mh-sending-mail) | ||
| 1034 | |||
| 978 | 1035 | ||
| 979 | 1036 | ||
| 980 | ;;; Sequences (:group 'mh-sequences) | 1037 | ;;; Sequences (:group 'mh-sequences) |
| @@ -1120,6 +1177,7 @@ The gnus method uses a different color for each indentation." | |||
| 1120 | "Delivered-To:" ; Egroups/yahoogroups mailing list manager | 1177 | "Delivered-To:" ; Egroups/yahoogroups mailing list manager |
| 1121 | "Delivery-Date:" ; MH | 1178 | "Delivery-Date:" ; MH |
| 1122 | "Delivery:" | 1179 | "Delivery:" |
| 1180 | "DomainKey-Signature:" ;http://antispam.yahoo.com/domainkeys | ||
| 1123 | "Encoding:" | 1181 | "Encoding:" |
| 1124 | "Envelope-to:" | 1182 | "Envelope-to:" |
| 1125 | "Errors-To:" | 1183 | "Errors-To:" |
| @@ -1188,6 +1246,7 @@ The gnus method uses a different color for each indentation." | |||
| 1188 | "X-Envelope-From:" | 1246 | "X-Envelope-From:" |
| 1189 | "X-Envelope-Sender:" | 1247 | "X-Envelope-Sender:" |
| 1190 | "X-Envelope-To:" | 1248 | "X-Envelope-To:" |
| 1249 | "X-Evolution:" ; Evolution mail client | ||
| 1191 | "X-Face:" | 1250 | "X-Face:" |
| 1192 | "X-Folder:" ; Spam | 1251 | "X-Folder:" ; Spam |
| 1193 | "X-From-Line" | 1252 | "X-From-Line" |
| @@ -1264,6 +1323,7 @@ The gnus method uses a different color for each indentation." | |||
| 1264 | "X-Trace:" | 1323 | "X-Trace:" |
| 1265 | "X-UID" | 1324 | "X-UID" |
| 1266 | "X-UIDL:" | 1325 | "X-UIDL:" |
| 1326 | "X-USANET-" ; usa.net | ||
| 1267 | "X-UserInfo1:" | 1327 | "X-UserInfo1:" |
| 1268 | "X-VSMLoop:" ; NTMail | 1328 | "X-VSMLoop:" ; NTMail |
| 1269 | "X-Vms-To:" | 1329 | "X-Vms-To:" |
| @@ -1527,13 +1587,13 @@ Optional argument ARG is not used." | |||
| 1527 | (defun mh-tool-bar-folder-help () | 1587 | (defun mh-tool-bar-folder-help () |
| 1528 | "Visit \"(mh-e)Top\"." | 1588 | "Visit \"(mh-e)Top\"." |
| 1529 | (interactive) | 1589 | (interactive) |
| 1530 | (Info-goto-node "(mh-e)Top") | 1590 | (info "(mh-e)Top") |
| 1531 | (delete-other-windows)) | 1591 | (delete-other-windows)) |
| 1532 | 1592 | ||
| 1533 | (defun mh-tool-bar-letter-help () | 1593 | (defun mh-tool-bar-letter-help () |
| 1534 | "Visit \"(mh-e)Draft Editing\"." | 1594 | "Visit \"(mh-e)Draft Editing\"." |
| 1535 | (interactive) | 1595 | (interactive) |
| 1536 | (Info-goto-node "(mh-e)Draft Editing") | 1596 | (info "(mh-e)Draft Editing") |
| 1537 | (delete-other-windows)) | 1597 | (delete-other-windows)) |
| 1538 | 1598 | ||
| 1539 | (defmacro mh-tool-bar-reply-generator (function recipient folder-buffer-flag) | 1599 | (defmacro mh-tool-bar-reply-generator (function recipient folder-buffer-flag) |
| @@ -1907,9 +1967,9 @@ This button runs `mh-previous-undeleted-msg'") | |||
| 1907 | ;; Common buttons | 1967 | ;; Common buttons |
| 1908 | (mh-tool-bar-customize (folder letter) "preferences" "MH-E Preferences") | 1968 | (mh-tool-bar-customize (folder letter) "preferences" "MH-E Preferences") |
| 1909 | (mh-tool-bar-folder-help (folder) "help" | 1969 | (mh-tool-bar-folder-help (folder) "help" |
| 1910 | "Help! (general help)\nThis button runs `Info-goto-node'") | 1970 | "Help! (general help)\nThis button runs `info'") |
| 1911 | (mh-tool-bar-letter-help (letter) "help" | 1971 | (mh-tool-bar-letter-help (letter) "help" |
| 1912 | "Help! (general help)\nThis button runs `Info-goto-node'") | 1972 | "Help! (general help)\nThis button runs `info'") |
| 1913 | ;; Folder narrowed to sequence buttons | 1973 | ;; Folder narrowed to sequence buttons |
| 1914 | (mh-widen (sequence) "widen" | 1974 | (mh-widen (sequence) "widen" |
| 1915 | "Widen from the sequence\nThis button runs `mh-widen'")) | 1975 | "Widen from the sequence\nThis button runs `mh-widen'")) |
| @@ -2085,7 +2145,7 @@ will be removed from the unseen sequence." | |||
| 2085 | ;;; Faces Used in Scan Listing (:group 'mh-folder-faces) | 2145 | ;;; Faces Used in Scan Listing (:group 'mh-folder-faces) |
| 2086 | 2146 | ||
| 2087 | (defvar mh-folder-body-face 'mh-folder-body-face | 2147 | (defvar mh-folder-body-face 'mh-folder-body-face |
| 2088 | "Face for highlighting body text in MH-Folder buffers.") | 2148 | "Face used to highlight body text in MH-Folder buffers.") |
| 2089 | (defface mh-folder-body-face | 2149 | (defface mh-folder-body-face |
| 2090 | '((((type tty) (class color)) (:foreground "green")) | 2150 | '((((type tty) (class color)) (:foreground "green")) |
| 2091 | (((class grayscale) (background light)) (:foreground "DimGray" :italic t)) | 2151 | (((class grayscale) (background light)) (:foreground "DimGray" :italic t)) |
| @@ -2093,11 +2153,11 @@ will be removed from the unseen sequence." | |||
| 2093 | (((class color) (background light)) (:foreground "RosyBrown")) | 2153 | (((class color) (background light)) (:foreground "RosyBrown")) |
| 2094 | (((class color) (background dark)) (:foreground "LightSalmon")) | 2154 | (((class color) (background dark)) (:foreground "LightSalmon")) |
| 2095 | (t (:italic t))) | 2155 | (t (:italic t))) |
| 2096 | "Face for highlighting body text in MH-Folder buffers." | 2156 | "Face used to highlight body text in MH-Folder buffers." |
| 2097 | :group 'mh-folder-faces) | 2157 | :group 'mh-folder-faces) |
| 2098 | 2158 | ||
| 2099 | (defvar mh-folder-cur-msg-face 'mh-folder-cur-msg-face | 2159 | (defvar mh-folder-cur-msg-face 'mh-folder-cur-msg-face |
| 2100 | "Face for the current message line in MH-Folder buffers.") | 2160 | "Face used for the current message line in MH-Folder buffers.") |
| 2101 | (defface mh-folder-cur-msg-face | 2161 | (defface mh-folder-cur-msg-face |
| 2102 | '((((type tty pc) (class color)) | 2162 | '((((type tty pc) (class color)) |
| 2103 | (:background "LightGreen")) | 2163 | (:background "LightGreen")) |
| @@ -2108,11 +2168,11 @@ will be removed from the unseen sequence." | |||
| 2108 | (((class color) (background dark)) | 2168 | (((class color) (background dark)) |
| 2109 | (:background "DarkOliveGreen4")) | 2169 | (:background "DarkOliveGreen4")) |
| 2110 | (t (:underline t))) | 2170 | (t (:underline t))) |
| 2111 | "Face for the current message line in MH-Folder buffers." | 2171 | "Face used for the current message line in MH-Folder buffers." |
| 2112 | :group 'mh-folder-faces) | 2172 | :group 'mh-folder-faces) |
| 2113 | 2173 | ||
| 2114 | (defvar mh-folder-cur-msg-number-face 'mh-folder-cur-msg-number-face | 2174 | (defvar mh-folder-cur-msg-number-face 'mh-folder-cur-msg-number-face |
| 2115 | "Face for highlighting the current message in MH-Folder buffers.") | 2175 | "Face used to highlight the current message in MH-Folder buffers.") |
| 2116 | (defface mh-folder-cur-msg-number-face | 2176 | (defface mh-folder-cur-msg-number-face |
| 2117 | '((((type tty) (class color)) (:foreground "cyan" :weight bold)) | 2177 | '((((type tty) (class color)) (:foreground "cyan" :weight bold)) |
| 2118 | (((class grayscale) (background light)) (:foreground "LightGray" :bold t)) | 2178 | (((class grayscale) (background light)) (:foreground "LightGray" :bold t)) |
| @@ -2120,11 +2180,11 @@ will be removed from the unseen sequence." | |||
| 2120 | (((class color) (background light)) (:foreground "Purple")) | 2180 | (((class color) (background light)) (:foreground "Purple")) |
| 2121 | (((class color) (background dark)) (:foreground "Cyan")) | 2181 | (((class color) (background dark)) (:foreground "Cyan")) |
| 2122 | (t (:bold t))) | 2182 | (t (:bold t))) |
| 2123 | "Face for highlighting the current message in MH-Folder buffers." | 2183 | "Face used to highlight the current message in MH-Folder buffers." |
| 2124 | :group 'mh-folder-faces) | 2184 | :group 'mh-folder-faces) |
| 2125 | 2185 | ||
| 2126 | (defvar mh-folder-date-face 'mh-folder-date-face | 2186 | (defvar mh-folder-date-face 'mh-folder-date-face |
| 2127 | "Face for highlighting the date in MH-Folder buffers.") | 2187 | "Face used to highlight the date in MH-Folder buffers.") |
| 2128 | (defface mh-folder-date-face | 2188 | (defface mh-folder-date-face |
| 2129 | '((((class color) (background light)) | 2189 | '((((class color) (background light)) |
| 2130 | (:foreground "snow4")) | 2190 | (:foreground "snow4")) |
| @@ -2132,11 +2192,11 @@ will be removed from the unseen sequence." | |||
| 2132 | (:foreground "snow3")) | 2192 | (:foreground "snow3")) |
| 2133 | (t | 2193 | (t |
| 2134 | (:bold t))) | 2194 | (:bold t))) |
| 2135 | "Face for highlighting the date in MH-Folder buffers." | 2195 | "Face used to highlight the date in MH-Folder buffers." |
| 2136 | :group 'mh-folder-faces) | 2196 | :group 'mh-folder-faces) |
| 2137 | 2197 | ||
| 2138 | (defvar mh-folder-followup-face 'mh-folder-followup-face | 2198 | (defvar mh-folder-followup-face 'mh-folder-followup-face |
| 2139 | "Face for highlighting Re: (followup) subject text in MH-Folder buffers.") | 2199 | "Face used to highlight Re: subject text in MH-Folder buffers.") |
| 2140 | (defface mh-folder-followup-face | 2200 | (defface mh-folder-followup-face |
| 2141 | '((((class color) (background light)) | 2201 | '((((class color) (background light)) |
| 2142 | (:foreground "blue3")) | 2202 | (:foreground "blue3")) |
| @@ -2144,11 +2204,11 @@ will be removed from the unseen sequence." | |||
| 2144 | (:foreground "LightGoldenRod")) | 2204 | (:foreground "LightGoldenRod")) |
| 2145 | (t | 2205 | (t |
| 2146 | (:bold t))) | 2206 | (:bold t))) |
| 2147 | "Face for highlighting Re: (followup) subject text in MH-Folder buffers." | 2207 | "Face used to highlight Re: subject text in MH-Folder buffers." |
| 2148 | :group 'mh-folder-faces) | 2208 | :group 'mh-folder-faces) |
| 2149 | 2209 | ||
| 2150 | (defvar mh-folder-msg-number-face 'mh-folder-msg-number-face | 2210 | (defvar mh-folder-msg-number-face 'mh-folder-msg-number-face |
| 2151 | "Face for highlighting the message number in MH-Folder buffers.") | 2211 | "Face used to highlight the message number in MH-Folder buffers.") |
| 2152 | (defface mh-folder-msg-number-face | 2212 | (defface mh-folder-msg-number-face |
| 2153 | '((((class color) (background light)) | 2213 | '((((class color) (background light)) |
| 2154 | (:foreground "snow4")) | 2214 | (:foreground "snow4")) |
| @@ -2156,15 +2216,15 @@ will be removed from the unseen sequence." | |||
| 2156 | (:foreground "snow3")) | 2216 | (:foreground "snow3")) |
| 2157 | (t | 2217 | (t |
| 2158 | (:bold t))) | 2218 | (:bold t))) |
| 2159 | "Face for highlighting the message number in MH-Folder buffers." | 2219 | "Face used to highlight the message number in MH-Folder buffers." |
| 2160 | :group 'mh-folder-faces) | 2220 | :group 'mh-folder-faces) |
| 2161 | 2221 | ||
| 2162 | (defvar mh-folder-deleted-face 'mh-folder-deleted-face | 2222 | (defvar mh-folder-deleted-face 'mh-folder-deleted-face |
| 2163 | "Face for highlighting deleted messages in MH-Folder buffers.") | 2223 | "Face used to highlight deleted messages in MH-Folder buffers.") |
| 2164 | (copy-face 'mh-folder-msg-number-face 'mh-folder-deleted-face) | 2224 | (copy-face 'mh-folder-msg-number-face 'mh-folder-deleted-face) |
| 2165 | 2225 | ||
| 2166 | (defvar mh-folder-refiled-face 'mh-folder-refiled-face | 2226 | (defvar mh-folder-refiled-face 'mh-folder-refiled-face |
| 2167 | "Face for highlighting refiled messages in MH-Folder buffers.") | 2227 | "Face used to highlight refiled messages in MH-Folder buffers.") |
| 2168 | (defface mh-folder-refiled-face | 2228 | (defface mh-folder-refiled-face |
| 2169 | '((((type tty) (class color)) (:foreground "yellow" :weight light)) | 2229 | '((((type tty) (class color)) (:foreground "yellow" :weight light)) |
| 2170 | (((class grayscale) (background light)) | 2230 | (((class grayscale) (background light)) |
| @@ -2174,11 +2234,11 @@ will be removed from the unseen sequence." | |||
| 2174 | (((class color) (background light)) (:foreground "DarkGoldenrod")) | 2234 | (((class color) (background light)) (:foreground "DarkGoldenrod")) |
| 2175 | (((class color) (background dark)) (:foreground "LightGoldenrod")) | 2235 | (((class color) (background dark)) (:foreground "LightGoldenrod")) |
| 2176 | (t (:bold t :italic t))) | 2236 | (t (:bold t :italic t))) |
| 2177 | "Face for highlighting refiled messages in MH-Folder buffers." | 2237 | "Face used to highlight refiled messages in MH-Folder buffers." |
| 2178 | :group 'mh-folder-faces) | 2238 | :group 'mh-folder-faces) |
| 2179 | 2239 | ||
| 2180 | (defvar mh-folder-subject-face 'mh-folder-subject-face | 2240 | (defvar mh-folder-subject-face 'mh-folder-subject-face |
| 2181 | "Face for highlighting subject text in MH-Folder buffers.") | 2241 | "Face used to highlight subject text in MH-Folder buffers.") |
| 2182 | (if (boundp 'facemenu-unlisted-faces) | 2242 | (if (boundp 'facemenu-unlisted-faces) |
| 2183 | (add-to-list 'facemenu-unlisted-faces "^mh-folder")) | 2243 | (add-to-list 'facemenu-unlisted-faces "^mh-folder")) |
| 2184 | (defface mh-folder-subject-face | 2244 | (defface mh-folder-subject-face |
| @@ -2188,7 +2248,7 @@ will be removed from the unseen sequence." | |||
| 2188 | (:foreground "yellow")) | 2248 | (:foreground "yellow")) |
| 2189 | (t | 2249 | (t |
| 2190 | (:bold t))) | 2250 | (:bold t))) |
| 2191 | "Face for highlighting subject text in MH-Folder buffers." | 2251 | "Face used to highlight subject text in MH-Folder buffers." |
| 2192 | :group 'mh-folder-faces) | 2252 | :group 'mh-folder-faces) |
| 2193 | 2253 | ||
| 2194 | (defface mh-folder-tick-face | 2254 | (defface mh-folder-tick-face |
| @@ -2199,15 +2259,15 @@ will be removed from the unseen sequence." | |||
| 2199 | :group 'mh-folder-faces) | 2259 | :group 'mh-folder-faces) |
| 2200 | 2260 | ||
| 2201 | (defvar mh-folder-address-face 'mh-folder-address-face | 2261 | (defvar mh-folder-address-face 'mh-folder-address-face |
| 2202 | "Face for highlighting the address in MH-Folder buffers.") | 2262 | "Face used to highlight the address in MH-Folder buffers.") |
| 2203 | (copy-face 'mh-folder-subject-face 'mh-folder-address-face) | 2263 | (copy-face 'mh-folder-subject-face 'mh-folder-address-face) |
| 2204 | 2264 | ||
| 2205 | (defvar mh-folder-scan-format-face 'mh-folder-scan-format-face | 2265 | (defvar mh-folder-scan-format-face 'mh-folder-scan-format-face |
| 2206 | "Face for highlighting `mh-scan-format-regexp' matches in MH-Folder buffers.") | 2266 | "Face used to highlight `mh-scan-format-regexp' matches in MH-Folder buffers.") |
| 2207 | (copy-face 'mh-folder-followup-face 'mh-folder-scan-format-face) | 2267 | (copy-face 'mh-folder-followup-face 'mh-folder-scan-format-face) |
| 2208 | 2268 | ||
| 2209 | (defvar mh-folder-to-face 'mh-folder-to-face | 2269 | (defvar mh-folder-to-face 'mh-folder-to-face |
| 2210 | "Face for highlighting the To: string in MH-Folder buffers.") | 2270 | "Face used to highlight the To: string in MH-Folder buffers.") |
| 2211 | (defface mh-folder-to-face | 2271 | (defface mh-folder-to-face |
| 2212 | '((((type tty) (class color)) (:foreground "green")) | 2272 | '((((type tty) (class color)) (:foreground "green")) |
| 2213 | (((class grayscale) (background light)) (:foreground "DimGray" :italic t)) | 2273 | (((class grayscale) (background light)) (:foreground "DimGray" :italic t)) |
| @@ -2215,7 +2275,7 @@ will be removed from the unseen sequence." | |||
| 2215 | (((class color) (background light)) (:foreground "RosyBrown")) | 2275 | (((class color) (background light)) (:foreground "RosyBrown")) |
| 2216 | (((class color) (background dark)) (:foreground "LightSalmon")) | 2276 | (((class color) (background dark)) (:foreground "LightSalmon")) |
| 2217 | (t (:italic t))) | 2277 | (t (:italic t))) |
| 2218 | "Face for highlighting the To: string in MH-Folder buffers." | 2278 | "Face used to highlight the To: string in MH-Folder buffers." |
| 2219 | :group 'mh-folder-faces) | 2279 | :group 'mh-folder-faces) |
| 2220 | 2280 | ||
| 2221 | 2281 | ||
| @@ -2223,7 +2283,7 @@ will be removed from the unseen sequence." | |||
| 2223 | ;;; Faces Used in Searching (:group 'mh-index-faces) | 2283 | ;;; Faces Used in Searching (:group 'mh-index-faces) |
| 2224 | 2284 | ||
| 2225 | (defvar mh-index-folder-face 'mh-index-folder-face | 2285 | (defvar mh-index-folder-face 'mh-index-folder-face |
| 2226 | "Face for highlighting folders in MH-Index buffers.") | 2286 | "Face used to highlight folders in MH-Index buffers.") |
| 2227 | (defface mh-index-folder-face | 2287 | (defface mh-index-folder-face |
| 2228 | '((((class color) (background light)) | 2288 | '((((class color) (background light)) |
| 2229 | (:foreground "dark green" :bold t)) | 2289 | (:foreground "dark green" :bold t)) |
| @@ -2231,7 +2291,7 @@ will be removed from the unseen sequence." | |||
| 2231 | (:foreground "indian red" :bold t)) | 2291 | (:foreground "indian red" :bold t)) |
| 2232 | (t | 2292 | (t |
| 2233 | (:bold t))) | 2293 | (:bold t))) |
| 2234 | "Face for highlighting folders in MH-Index buffers." | 2294 | "Face used to highlight folders in MH-Index buffers." |
| 2235 | :group 'mh-index-faces) | 2295 | :group 'mh-index-faces) |
| 2236 | 2296 | ||
| 2237 | 2297 | ||
| @@ -2244,7 +2304,7 @@ will be removed from the unseen sequence." | |||
| 2244 | (((class color) (background dark)) | 2304 | (((class color) (background dark)) |
| 2245 | (:background "gray10")) | 2305 | (:background "gray10")) |
| 2246 | (t (:bold t))) | 2306 | (t (:bold t))) |
| 2247 | "Face for displaying header fields in draft buffers." | 2307 | "Face used to display header fields in draft buffers." |
| 2248 | :group 'mh-letter-faces) | 2308 | :group 'mh-letter-faces) |
| 2249 | 2309 | ||
| 2250 | 2310 | ||
| @@ -2252,7 +2312,7 @@ will be removed from the unseen sequence." | |||
| 2252 | ;;; Faces Used in Message Display (:group 'mh-show-faces) | 2312 | ;;; Faces Used in Message Display (:group 'mh-show-faces) |
| 2253 | 2313 | ||
| 2254 | (defvar mh-show-cc-face 'mh-show-cc-face | 2314 | (defvar mh-show-cc-face 'mh-show-cc-face |
| 2255 | "Face for highlighting cc header fields.") | 2315 | "Face used to highlight cc: header fields.") |
| 2256 | (defface mh-show-cc-face | 2316 | (defface mh-show-cc-face |
| 2257 | '((((type tty) (class color)) (:foreground "yellow" :weight light)) | 2317 | '((((type tty) (class color)) (:foreground "yellow" :weight light)) |
| 2258 | (((class grayscale) (background light)) | 2318 | (((class grayscale) (background light)) |
| @@ -2262,11 +2322,11 @@ will be removed from the unseen sequence." | |||
| 2262 | (((class color) (background light)) (:foreground "DarkGoldenrod")) | 2322 | (((class color) (background light)) (:foreground "DarkGoldenrod")) |
| 2263 | (((class color) (background dark)) (:foreground "LightGoldenrod")) | 2323 | (((class color) (background dark)) (:foreground "LightGoldenrod")) |
| 2264 | (t (:bold t :italic t))) | 2324 | (t (:bold t :italic t))) |
| 2265 | "Face for highlighting cc header fields." | 2325 | "Face used to highlight cc: header fields." |
| 2266 | :group 'mh-show-faces) | 2326 | :group 'mh-show-faces) |
| 2267 | 2327 | ||
| 2268 | (defvar mh-show-date-face 'mh-show-date-face | 2328 | (defvar mh-show-date-face 'mh-show-date-face |
| 2269 | "Face for highlighting the Date header field.") | 2329 | "Face used to highlight the Date: header field.") |
| 2270 | (defface mh-show-date-face | 2330 | (defface mh-show-date-face |
| 2271 | '((((type tty) (class color)) (:foreground "green")) | 2331 | '((((type tty) (class color)) (:foreground "green")) |
| 2272 | (((class grayscale) (background light)) (:foreground "Gray90" :bold t)) | 2332 | (((class grayscale) (background light)) (:foreground "Gray90" :bold t)) |
| @@ -2274,7 +2334,7 @@ will be removed from the unseen sequence." | |||
| 2274 | (((class color) (background light)) (:foreground "ForestGreen")) | 2334 | (((class color) (background light)) (:foreground "ForestGreen")) |
| 2275 | (((class color) (background dark)) (:foreground "PaleGreen")) | 2335 | (((class color) (background dark)) (:foreground "PaleGreen")) |
| 2276 | (t (:bold t :underline t))) | 2336 | (t (:bold t :underline t))) |
| 2277 | "Face for highlighting the Date header field." | 2337 | "Face used to highlight the Date: header field." |
| 2278 | :group 'mh-show-faces) | 2338 | :group 'mh-show-faces) |
| 2279 | 2339 | ||
| 2280 | (defvar mh-show-header-face 'mh-show-header-face | 2340 | (defvar mh-show-header-face 'mh-show-header-face |
| @@ -2289,13 +2349,36 @@ will be removed from the unseen sequence." | |||
| 2289 | "Face used to deemphasize unspecified header fields." | 2349 | "Face used to deemphasize unspecified header fields." |
| 2290 | :group 'mh-show-faces) | 2350 | :group 'mh-show-faces) |
| 2291 | 2351 | ||
| 2352 | (defvar mh-show-pgg-good-face 'mh-show-pgg-good-face | ||
| 2353 | "Face used to highlight a good PGG signature.") | ||
| 2354 | (defface mh-show-pgg-good-face | ||
| 2355 | '((t (:bold t :foreground "LimeGreen"))) | ||
| 2356 | "Face used to highlight a good PGG signature." | ||
| 2357 | :group 'mh-show-faces) | ||
| 2358 | |||
| 2359 | (defvar mh-show-pgg-unknown-face 'mh-show-pgg-unknown-face | ||
| 2360 | "Face used to highlight a PGG signature whose status is unknown. | ||
| 2361 | This face is also used for a signature when the signer is untrusted.") | ||
| 2362 | (defface mh-show-pgg-unknown-face | ||
| 2363 | '((t (:bold t :foreground "DarkGoldenrod2"))) | ||
| 2364 | "Face used to highlight a PGG signature whose status is unknown. | ||
| 2365 | This face is also used for a signature when the signer is untrusted." | ||
| 2366 | :group 'mh-show-faces) | ||
| 2367 | |||
| 2368 | (defvar mh-show-pgg-bad-face 'mh-show-pgg-bad-face | ||
| 2369 | "Face used to highlight a bad PGG signature.") | ||
| 2370 | (defface mh-show-pgg-bad-face | ||
| 2371 | '((t (:bold t :foreground "DeepPink1"))) | ||
| 2372 | "Face used to highlight a bad PGG signature." | ||
| 2373 | :group 'mh-show-faces) | ||
| 2374 | |||
| 2292 | (defface mh-show-signature-face | 2375 | (defface mh-show-signature-face |
| 2293 | '((t (:italic t))) | 2376 | '((t (:italic t))) |
| 2294 | "Face for highlighting message signature." | 2377 | "Face used to highlight the message signature." |
| 2295 | :group 'mh-show-faces) | 2378 | :group 'mh-show-faces) |
| 2296 | 2379 | ||
| 2297 | (defvar mh-show-to-face 'mh-show-to-face | 2380 | (defvar mh-show-to-face 'mh-show-to-face |
| 2298 | "Face for highlighting the To: header field.") | 2381 | "Face used to highlight the To: header field.") |
| 2299 | (if (boundp 'facemenu-unlisted-faces) | 2382 | (if (boundp 'facemenu-unlisted-faces) |
| 2300 | (add-to-list 'facemenu-unlisted-faces "^mh-show")) | 2383 | (add-to-list 'facemenu-unlisted-faces "^mh-show")) |
| 2301 | (defface mh-show-to-face | 2384 | (defface mh-show-to-face |
| @@ -2306,11 +2389,11 @@ will be removed from the unseen sequence." | |||
| 2306 | (((class color) (background light)) (:foreground "SaddleBrown")) | 2389 | (((class color) (background light)) (:foreground "SaddleBrown")) |
| 2307 | (((class color) (background dark)) (:foreground "burlywood")) | 2390 | (((class color) (background dark)) (:foreground "burlywood")) |
| 2308 | (t (:underline t))) | 2391 | (t (:underline t))) |
| 2309 | "Face for highlighting the To: header field." | 2392 | "Face used to highlight the To: header field." |
| 2310 | :group 'mh-show-faces) | 2393 | :group 'mh-show-faces) |
| 2311 | 2394 | ||
| 2312 | (defvar mh-show-from-face 'mh-show-from-face | 2395 | (defvar mh-show-from-face 'mh-show-from-face |
| 2313 | "Face for highlighting the From: header field.") | 2396 | "Face used to highlight the From: header field.") |
| 2314 | (defface mh-show-from-face | 2397 | (defface mh-show-from-face |
| 2315 | '((((class color) (background light)) | 2398 | '((((class color) (background light)) |
| 2316 | (:foreground "red3")) | 2399 | (:foreground "red3")) |
| @@ -2318,17 +2401,17 @@ will be removed from the unseen sequence." | |||
| 2318 | (:foreground "cyan")) | 2401 | (:foreground "cyan")) |
| 2319 | (t | 2402 | (t |
| 2320 | (:bold t))) | 2403 | (:bold t))) |
| 2321 | "Face for highlighting the From: header field." | 2404 | "Face used to highlight the From: header field." |
| 2322 | :group 'mh-show-faces) | 2405 | :group 'mh-show-faces) |
| 2323 | 2406 | ||
| 2324 | (defface mh-show-xface-face | 2407 | (defface mh-show-xface-face |
| 2325 | '((t (:foreground "black" :background "white"))) | 2408 | '((t (:foreground "black" :background "white"))) |
| 2326 | "Face for displaying the X-Face image. | 2409 | "Face used to display the X-Face image. |
| 2327 | The background and foreground is used in the image." | 2410 | The background and foreground is used in the image." |
| 2328 | :group 'mh-show-faces) | 2411 | :group 'mh-show-faces) |
| 2329 | 2412 | ||
| 2330 | (defvar mh-show-subject-face 'mh-show-subject-face | 2413 | (defvar mh-show-subject-face 'mh-show-subject-face |
| 2331 | "Face for highlighting the Subject header field.") | 2414 | "Face used to highlight the Subject: header field.") |
| 2332 | (copy-face 'mh-folder-subject-face 'mh-show-subject-face) | 2415 | (copy-face 'mh-folder-subject-face 'mh-show-subject-face) |
| 2333 | 2416 | ||
| 2334 | 2417 | ||
diff --git a/lisp/mh-e/mh-e.el b/lisp/mh-e/mh-e.el index b5eea79ae1e..0cfb053c887 100644 --- a/lisp/mh-e/mh-e.el +++ b/lisp/mh-e/mh-e.el | |||
| @@ -1,11 +1,12 @@ | |||
| 1 | ;;; mh-e.el --- GNU Emacs interface to the MH mail system | 1 | ;;; mh-e.el --- GNU Emacs interface to the MH mail system |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1985, 86, 87, 88, 90, 92, 93, 94, 95, 97, 1999, | 3 | ;; Copyright (C) 1985, 1986, 1987, 1988, |
| 4 | ;; 2000, 2005 Free Software Foundation, Inc. | 4 | ;; 1990, 1992, 1993, 1994, 1995, 1997, 1999, |
| 5 | ;; 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. | ||
| 5 | 6 | ||
| 6 | ;; Author: Bill Wohler <wohler@newt.com> | 7 | ;; Author: Bill Wohler <wohler@newt.com> |
| 7 | ;; Maintainer: Bill Wohler <wohler@newt.com> | 8 | ;; Maintainer: Bill Wohler <wohler@newt.com> |
| 8 | ;; Version: 7.82 | 9 | ;; Version: 7.84 |
| 9 | ;; Keywords: mail | 10 | ;; Keywords: mail |
| 10 | 11 | ||
| 11 | ;; This file is part of GNU Emacs. | 12 | ;; This file is part of GNU Emacs. |
| @@ -97,10 +98,7 @@ | |||
| 97 | (defvar font-lock-auto-fontify) | 98 | (defvar font-lock-auto-fontify) |
| 98 | (defvar font-lock-defaults) | 99 | (defvar font-lock-defaults) |
| 99 | 100 | ||
| 100 | (defconst mh-version "7.82" "Version number of MH-E.") | 101 | (defconst mh-version "7.84" "Version number of MH-E.") |
| 101 | |||
| 102 | ;;; Autoloads | ||
| 103 | (autoload 'Info-goto-node "info") | ||
| 104 | 102 | ||
| 105 | (defvar mh-partial-folder-mode-line-annotation "select" | 103 | (defvar mh-partial-folder-mode-line-annotation "select" |
| 106 | "Annotation when displaying part of a folder. | 104 | "Annotation when displaying part of a folder. |
| @@ -578,7 +576,8 @@ Do not call this function from outside MH-E; use \\[mh-rmail] instead." | |||
| 578 | (setq folder mh-inbox)) | 576 | (setq folder mh-inbox)) |
| 579 | (let ((threading-needed-flag nil)) | 577 | (let ((threading-needed-flag nil)) |
| 580 | (let ((config (current-window-configuration))) | 578 | (let ((config (current-window-configuration))) |
| 581 | (delete-other-windows) | 579 | (when (and mh-show-buffer (get-buffer mh-show-buffer)) |
| 580 | (delete-windows-on mh-show-buffer)) | ||
| 582 | (cond ((not (get-buffer folder)) | 581 | (cond ((not (get-buffer folder)) |
| 583 | (mh-make-folder folder) | 582 | (mh-make-folder folder) |
| 584 | (setq threading-needed-flag mh-show-threads-flag) | 583 | (setq threading-needed-flag mh-show-threads-flag) |
| @@ -717,22 +716,24 @@ updated." | |||
| 717 | (mh-refile-a-msg nil folder)) | 716 | (mh-refile-a-msg nil folder)) |
| 718 | (when (looking-at mh-scan-refiled-msg-regexp) (mh-next-msg))) | 717 | (when (looking-at mh-scan-refiled-msg-regexp) (mh-next-msg))) |
| 719 | 718 | ||
| 720 | (defun mh-refile-or-write-again (message) | 719 | (defun mh-refile-or-write-again (range &optional interactive-flag) |
| 721 | "Re-execute the last refile or write command on the given MESSAGE. | 720 | "Re-execute the last refile or write command on the given RANGE. |
| 722 | Default is the displayed message. Use the same folder or file as the previous | 721 | Default is the displayed message. Use the same folder or file as the previous |
| 723 | refile or write command." | 722 | refile or write command. |
| 724 | (interactive (list (mh-get-msg-num t))) | 723 | If INTERACTIVE-FLAG is non-nil then the function was called interactively." |
| 724 | (interactive (list (mh-interactive-range "Redo") t)) | ||
| 725 | (if (null mh-last-destination) | 725 | (if (null mh-last-destination) |
| 726 | (error "No previous refile or write")) | 726 | (error "No previous refile or write")) |
| 727 | (let (output) | 727 | (let (output) |
| 728 | (setq output | 728 | (setq output |
| 729 | (cond ((eq (car mh-last-destination) 'refile) | 729 | (cond ((eq (car mh-last-destination) 'refile) |
| 730 | (mh-refile-a-msg message (cdr mh-last-destination)) | 730 | (mh-refile-msg range (cdr mh-last-destination)) |
| 731 | (format "Destination folder: %s" (cdr mh-last-destination))) | 731 | (format "Destination folder: %s" (cdr mh-last-destination))) |
| 732 | (t | 732 | (t |
| 733 | (apply 'mh-write-msg-to-file message (cdr mh-last-destination)) | 733 | (mh-iterate-on-range msg range |
| 734 | (apply 'mh-write-msg-to-file msg (cdr mh-last-destination))) | ||
| 735 | (mh-next-msg interactive-flag) | ||
| 734 | (format "Destination: %s" (cdr mh-last-destination))))) | 736 | (format "Destination: %s" (cdr mh-last-destination))))) |
| 735 | (mh-next-msg (interactive-p)) | ||
| 736 | (message output))) | 737 | (message output))) |
| 737 | 738 | ||
| 738 | (defun mh-quit () | 739 | (defun mh-quit () |
| @@ -1801,7 +1802,7 @@ Return in the current buffer." | |||
| 1801 | (message "inc %s..." folder)) | 1802 | (message "inc %s..." folder)) |
| 1802 | (setq mh-next-direction 'forward) | 1803 | (setq mh-next-direction 'forward) |
| 1803 | (goto-char (point-max)) | 1804 | (goto-char (point-max)) |
| 1804 | (mh-remove-all-notation) | 1805 | (mh-remove-cur-notation) |
| 1805 | (let ((start-of-inc (point))) | 1806 | (let ((start-of-inc (point))) |
| 1806 | (if maildrop-name | 1807 | (if maildrop-name |
| 1807 | ;; I think MH 5 used "-ms-file" instead of "-file", | 1808 | ;; I think MH 5 used "-ms-file" instead of "-file", |
| @@ -1827,7 +1828,7 @@ Return in the current buffer." | |||
| 1827 | start-of-inc (point-max)))) | 1828 | start-of-inc (point-max)))) |
| 1828 | (delete-region start-of-inc (point-max)) | 1829 | (delete-region start-of-inc (point-max)) |
| 1829 | (unwind-protect (mh-widen t) | 1830 | (unwind-protect (mh-widen t) |
| 1830 | (mh-remove-all-notation) | 1831 | (mh-remove-cur-notation) |
| 1831 | (goto-char (point-max)) | 1832 | (goto-char (point-max)) |
| 1832 | (setq start-of-inc (point)) | 1833 | (setq start-of-inc (point)) |
| 1833 | (insert saved-text) | 1834 | (insert saved-text) |
| @@ -1846,7 +1847,15 @@ Return in the current buffer." | |||
| 1846 | (t | 1847 | (t |
| 1847 | (setq new-mail-flag t))) | 1848 | (setq new-mail-flag t))) |
| 1848 | (keep-lines mh-scan-valid-regexp) ; Flush random scan lines | 1849 | (keep-lines mh-scan-valid-regexp) ; Flush random scan lines |
| 1849 | (setq mh-seq-list (mh-read-folder-sequences folder t)) | 1850 | (let* ((sequences (mh-read-folder-sequences folder t)) |
| 1851 | (new-cur (assoc 'cur sequences)) | ||
| 1852 | (new-unseen (assoc mh-unseen-seq sequences))) | ||
| 1853 | (unless (assoc 'cur mh-seq-list) | ||
| 1854 | (push (list 'cur) mh-seq-list)) | ||
| 1855 | (unless (assoc mh-unseen-seq mh-seq-list) | ||
| 1856 | (push (list mh-unseen-seq) mh-seq-list)) | ||
| 1857 | (setcdr (assoc 'cur mh-seq-list) (cdr new-cur)) | ||
| 1858 | (setcdr (assoc mh-unseen-seq mh-seq-list) (cdr new-unseen))) | ||
| 1850 | (when (equal (point-max) start-of-inc) | 1859 | (when (equal (point-max) start-of-inc) |
| 1851 | (mh-notate-cur)) | 1860 | (mh-notate-cur)) |
| 1852 | (if new-mail-flag | 1861 | (if new-mail-flag |
| @@ -1858,8 +1867,7 @@ Return in the current buffer." | |||
| 1858 | (mh-thread-inc folder start-of-inc)) | 1867 | (mh-thread-inc folder start-of-inc)) |
| 1859 | (mh-goto-cur-msg)) | 1868 | (mh-goto-cur-msg)) |
| 1860 | (goto-char point-before-inc)) | 1869 | (goto-char point-before-inc)) |
| 1861 | (mh-notate-user-sequences) | 1870 | (mh-notate-user-sequences (cons start-of-inc (point-max))))))) |
| 1862 | (mh-notate-deleted-and-refiled))))) | ||
| 1863 | 1871 | ||
| 1864 | (defun mh-make-folder-mode-line (&optional ignored) | 1872 | (defun mh-make-folder-mode-line (&optional ignored) |
| 1865 | "Set the fields of the mode line for a folder buffer. | 1873 | "Set the fields of the mode line for a folder buffer. |
| @@ -2033,18 +2041,18 @@ with no arguments, before the commands are processed." | |||
| 2033 | (mh-coalesce-msg-list msgs)) | 2041 | (mh-coalesce-msg-list msgs)) |
| 2034 | (mh-delete-scan-msgs msgs) | 2042 | (mh-delete-scan-msgs msgs) |
| 2035 | ;; Preserve sequences in destination folder... | 2043 | ;; Preserve sequences in destination folder... |
| 2036 | (when (and mh-refile-preserves-sequences-flag | 2044 | (when mh-refile-preserves-sequences-flag |
| 2037 | (numberp last)) | ||
| 2038 | (clrhash dest-map) | 2045 | (clrhash dest-map) |
| 2039 | (loop for i from (1+ last) | 2046 | (loop for i from (1+ (or last 0)) |
| 2040 | for msg in (sort (copy-sequence msgs) #'<) | 2047 | for msg in (sort (copy-sequence msgs) #'<) |
| 2041 | do (loop for seq-name in (gethash msg seq-map) | 2048 | do (loop for seq-name in (gethash msg seq-map) |
| 2042 | do (push i (gethash seq-name dest-map)))) | 2049 | do (push i (gethash seq-name dest-map)))) |
| 2043 | (maphash | 2050 | (maphash |
| 2044 | #'(lambda (seq msgs) | 2051 | #'(lambda (seq msgs) |
| 2045 | ;; Run it in the background, since we don't care | 2052 | ;; Can't be run in the background, since the |
| 2046 | ;; about the results. | 2053 | ;; current folder is changed by mark this could |
| 2047 | (apply #'mh-exec-cmd-daemon "mark" #'ignore | 2054 | ;; lead to a race condition with the next refile. |
| 2055 | (apply #'mh-exec-cmd "mark" | ||
| 2048 | "-sequence" (symbol-name seq) dest-folder | 2056 | "-sequence" (symbol-name seq) dest-folder |
| 2049 | "-add" (mapcar #'(lambda (x) (format "%s" x)) | 2057 | "-add" (mapcar #'(lambda (x) (format "%s" x)) |
| 2050 | (mh-coalesce-msg-list msgs)))) | 2058 | (mh-coalesce-msg-list msgs)))) |
| @@ -2201,13 +2209,14 @@ Expands ranges into set of individual numbers." | |||
| 2201 | (end-of-line (save-excursion (end-of-line) (point))) | 2209 | (end-of-line (save-excursion (end-of-line) (point))) |
| 2202 | num) | 2210 | num) |
| 2203 | (while (re-search-forward "[0-9]+" end-of-line t) | 2211 | (while (re-search-forward "[0-9]+" end-of-line t) |
| 2204 | (setq num (string-to-int (buffer-substring (match-beginning 0) | 2212 | (setq num (string-to-number (buffer-substring (match-beginning 0) |
| 2205 | (match-end 0)))) | 2213 | (match-end 0)))) |
| 2206 | (cond ((looking-at "-") ; Message range | 2214 | (cond ((looking-at "-") ; Message range |
| 2207 | (forward-char 1) | 2215 | (forward-char 1) |
| 2208 | (re-search-forward "[0-9]+" end-of-line t) | 2216 | (re-search-forward "[0-9]+" end-of-line t) |
| 2209 | (let ((num2 (string-to-int (buffer-substring (match-beginning 0) | 2217 | (let ((num2 (string-to-number |
| 2210 | (match-end 0))))) | 2218 | (buffer-substring (match-beginning 0) |
| 2219 | (match-end 0))))) | ||
| 2211 | (if (< num2 num) | 2220 | (if (< num2 num) |
| 2212 | (error "Bad message range: %d-%d" num num2)) | 2221 | (error "Bad message range: %d-%d" num num2)) |
| 2213 | (while (<= num num2) | 2222 | (while (<= num num2) |
diff --git a/lisp/mh-e/mh-funcs.el b/lisp/mh-e/mh-funcs.el index a632efc7856..126fd84ce9b 100644 --- a/lisp/mh-e/mh-funcs.el +++ b/lisp/mh-e/mh-funcs.el | |||
| @@ -1,6 +1,7 @@ | |||
| 1 | ;;; mh-funcs.el --- MH-E functions not everyone will use right away | 1 | ;;; mh-funcs.el --- MH-E functions not everyone will use right away |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1993, 1995, 2005 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 1993, 1995, |
| 4 | ;; 2001, 2002, 2003, 2004 Free Software Foundation, Inc. | ||
| 4 | 5 | ||
| 5 | ;; Author: Bill Wohler <wohler@newt.com> | 6 | ;; Author: Bill Wohler <wohler@newt.com> |
| 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> | 7 | ;; Maintainer: Bill Wohler <wohler@newt.com> |
| @@ -127,7 +128,7 @@ Display the results only if something went wrong." | |||
| 127 | (set-buffer (get-buffer-create mh-temp-buffer)) | 128 | (set-buffer (get-buffer-create mh-temp-buffer)) |
| 128 | (insert-before-markers output) | 129 | (insert-before-markers output) |
| 129 | (when (save-excursion | 130 | (when (save-excursion |
| 130 | (beginning-of-buffer) | 131 | (goto-char (point-min)) |
| 131 | (re-search-forward "^rmf: " (point-max) t)) | 132 | (re-search-forward "^rmf: " (point-max) t)) |
| 132 | (display-buffer mh-temp-buffer))) | 133 | (display-buffer mh-temp-buffer))) |
| 133 | 134 | ||
| @@ -148,7 +149,7 @@ Display the results only if something went wrong." | |||
| 148 | "-recurse" | 149 | "-recurse" |
| 149 | "-norecurse")) | 150 | "-norecurse")) |
| 150 | (goto-char (point-min)) | 151 | (goto-char (point-min)) |
| 151 | (view-mode 1) | 152 | (view-mode-enter) |
| 152 | (setq view-exit-action 'kill-buffer) | 153 | (setq view-exit-action 'kill-buffer) |
| 153 | (message "Listing folders...done"))))) | 154 | (message "Listing folders...done"))))) |
| 154 | 155 | ||
diff --git a/lisp/mh-e/mh-gnus.el b/lisp/mh-e/mh-gnus.el index e4b4a5b0d54..b850c8fdc43 100644 --- a/lisp/mh-e/mh-gnus.el +++ b/lisp/mh-e/mh-gnus.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; mh-gnus.el --- Make MH-E compatible with installed version of Gnus. | 1 | ;;; mh-gnus.el --- Make MH-E compatible with installed version of Gnus. |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 2005 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 2003, 2004 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Satyaki Das <satyaki@theforce.stanford.edu> | 5 | ;; Author: Satyaki Das <satyaki@theforce.stanford.edu> |
| 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> | 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> |
diff --git a/lisp/mh-e/mh-identity.el b/lisp/mh-e/mh-identity.el index 7b44dae1d06..dc076751865 100644 --- a/lisp/mh-e/mh-identity.el +++ b/lisp/mh-e/mh-identity.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; mh-identity.el --- Multiple identify support for MH-E. | 1 | ;;; mh-identity.el --- Multiple identify support for MH-E. |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 2005 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 2002, 2003, 2004 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Peter S. Galbraith <psg@debian.org> | 5 | ;; Author: Peter S. Galbraith <psg@debian.org> |
| 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> | 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> |
| @@ -87,18 +87,18 @@ change." | |||
| 87 | ;;;###mh-autoload | 87 | ;;;###mh-autoload |
| 88 | (defun mh-identity-list-set (symbol value) | 88 | (defun mh-identity-list-set (symbol value) |
| 89 | "Update the `mh-identity-list' variable, and rebuild the menu. | 89 | "Update the `mh-identity-list' variable, and rebuild the menu. |
| 90 | Sets the default for SYMBOL (e.g. `mh-identity-list') to VALUE (as set in | 90 | Sets the default for SYMBOL (for example, `mh-identity-list') to VALUE (as set |
| 91 | customization). This is called after 'customize is used to alter | 91 | in customization). This is called after 'customize is used to alter |
| 92 | `mh-identity-list'." | 92 | `mh-identity-list'." |
| 93 | (set-default symbol value) | 93 | (set-default symbol value) |
| 94 | (mh-identity-make-menu)) | 94 | (mh-identity-make-menu)) |
| 95 | 95 | ||
| 96 | (defvar mh-identity-local nil | 96 | (defvar mh-identity-local nil |
| 97 | "Buffer-local variable holding the identity currently in use.") | 97 | "Buffer-local variable that holds the identity currently in use.") |
| 98 | (make-variable-buffer-local 'mh-identity-local) | 98 | (make-variable-buffer-local 'mh-identity-local) |
| 99 | 99 | ||
| 100 | (defun mh-header-field-delete (field value-only) | 100 | (defun mh-header-field-delete (field value-only) |
| 101 | "Delete FIELD in the mail header, or only its value if VALUE-ONLY is t. | 101 | "Delete header FIELD, or only its value if VALUE-ONLY is t. |
| 102 | Return t if anything is deleted." | 102 | Return t if anything is deleted." |
| 103 | (let ((field-colon (if (string-match "^.*:$" field) | 103 | (let ((field-colon (if (string-match "^.*:$" field) |
| 104 | field | 104 | field |
| @@ -119,11 +119,11 @@ Return t if anything is deleted." | |||
| 119 | "Marker for the end of a signature inserted by `mh-insert-identity'.") | 119 | "Marker for the end of a signature inserted by `mh-insert-identity'.") |
| 120 | 120 | ||
| 121 | (defun mh-identity-field-handler (field) | 121 | (defun mh-identity-field-handler (field) |
| 122 | "Return the handler for a FIELD or nil if none set. | 122 | "Return the handler for header FIELD or nil if none set. |
| 123 | The field name is downcased. If the FIELD begins with the character | 123 | The field name is downcased. If the FIELD begins with the character |
| 124 | `:', then it must have a special handler defined in | 124 | `:', then it must have a special handler defined in |
| 125 | `mh-identity-handlers', else return an error since it is not a valid | 125 | `mh-identity-handlers', else return an error since it is not a valid |
| 126 | message header." | 126 | header field." |
| 127 | (or (cdr (assoc (downcase field) mh-identity-handlers)) | 127 | (or (cdr (assoc (downcase field) mh-identity-handlers)) |
| 128 | (and (eq (aref field 0) ?:) | 128 | (and (eq (aref field 0) ?:) |
| 129 | (error (format "Field %s - unknown mh-identity-handler" field))) | 129 | (error (format "Field %s - unknown mh-identity-handler" field))) |
| @@ -132,8 +132,8 @@ message header." | |||
| 132 | 132 | ||
| 133 | ;;;###mh-autoload | 133 | ;;;###mh-autoload |
| 134 | (defun mh-insert-identity (identity) | 134 | (defun mh-insert-identity (identity) |
| 135 | "Insert proper fields for given IDENTITY. | 135 | "Insert fields specified by given IDENTITY. |
| 136 | Edit the `mh-identity-list' variable to define identity." | 136 | See `mh-identity-list'." |
| 137 | (interactive | 137 | (interactive |
| 138 | (list (completing-read | 138 | (list (completing-read |
| 139 | "Identity: " | 139 | "Identity: " |
| @@ -167,7 +167,8 @@ Edit the `mh-identity-list' variable to define identity." | |||
| 167 | 167 | ||
| 168 | ;;;###mh-autoload | 168 | ;;;###mh-autoload |
| 169 | (defun mh-identity-handler-gpg-identity (field action &optional value) | 169 | (defun mh-identity-handler-gpg-identity (field action &optional value) |
| 170 | "For FIELD \"pgg-default-user-id\", process for ACTION 'remove or 'add. | 170 | "Process header FIELD \":pgg-default-user-id\". |
| 171 | The ACTION is one of 'remove or 'add. If 'add, the VALUE is added. | ||
| 171 | The buffer-local variable `mh-identity-pgg-default-user-id' is set to VALUE | 172 | The buffer-local variable `mh-identity-pgg-default-user-id' is set to VALUE |
| 172 | when action 'add is selected." | 173 | when action 'add is selected." |
| 173 | (cond | 174 | (cond |
| @@ -180,8 +181,8 @@ when action 'add is selected." | |||
| 180 | 181 | ||
| 181 | ;;;###mh-autoload | 182 | ;;;###mh-autoload |
| 182 | (defun mh-identity-handler-signature (field action &optional value) | 183 | (defun mh-identity-handler-signature (field action &optional value) |
| 183 | "For FIELD \"signature\", process headers for ACTION 'remove or 'add. | 184 | "Process header FIELD \":signature\". |
| 184 | The VALUE is added." | 185 | The ACTION is one of 'remove or 'add. If 'add, the VALUE is added." |
| 185 | (cond | 186 | (cond |
| 186 | ((equal action 'remove) | 187 | ((equal action 'remove) |
| 187 | (when (and (markerp mh-identity-signature-start) | 188 | (when (and (markerp mh-identity-signature-start) |
| @@ -210,8 +211,8 @@ The VALUE is added." | |||
| 210 | 211 | ||
| 211 | ;;;###mh-autoload | 212 | ;;;###mh-autoload |
| 212 | (defun mh-identity-handler-attribution-verb (field action &optional value) | 213 | (defun mh-identity-handler-attribution-verb (field action &optional value) |
| 213 | "For FIELD \"attribution_verb\", process headers for ACTION 'remove or 'add. | 214 | "Process header FIELD \":attribution-verb\". |
| 214 | The VALUE is added." | 215 | The ACTION is one of 'remove or 'add. If 'add, the VALUE is added." |
| 215 | (when (and (markerp mh-identity-attribution-verb-start) | 216 | (when (and (markerp mh-identity-attribution-verb-start) |
| 216 | (markerp mh-identity-attribution-verb-end)) | 217 | (markerp mh-identity-attribution-verb-end)) |
| 217 | (delete-region mh-identity-attribution-verb-start | 218 | (delete-region mh-identity-attribution-verb-start |
| @@ -239,9 +240,10 @@ If VALUE is nil, use `mh-extract-from-attribution-verb'." | |||
| 239 | (point-max-marker)))) | 240 | (point-max-marker)))) |
| 240 | 241 | ||
| 241 | (defun mh-identity-handler-default (field action top &optional value) | 242 | (defun mh-identity-handler-default (field action top &optional value) |
| 242 | "For FIELD, process mh-identity headers for ACTION 'remove or 'add. | 243 | "Process header FIELD. |
| 243 | if TOP is non-nil, add the field and it's VALUE at the top of the header, else | 244 | The ACTION is one of 'remove or 'add. If TOP is non-nil, add the field and its |
| 244 | add it at the bottom of the header." | 245 | VALUE at the top of the header, else add it at the bottom of the header. If |
| 246 | action is 'add, the VALUE is added." | ||
| 245 | (let ((field-colon (if (string-match "^.*:$" field) | 247 | (let ((field-colon (if (string-match "^.*:$" field) |
| 246 | field | 248 | field |
| 247 | (concat field ":")))) | 249 | (concat field ":")))) |
| @@ -266,14 +268,16 @@ add it at the bottom of the header." | |||
| 266 | 268 | ||
| 267 | ;;;###mh-autoload | 269 | ;;;###mh-autoload |
| 268 | (defun mh-identity-handler-top (field action &optional value) | 270 | (defun mh-identity-handler-top (field action &optional value) |
| 269 | "For FIELD, process mh-identity headers for ACTION 'remove or 'add. | 271 | "Process header FIELD. |
| 270 | If the field wasn't present, the VALUE is added at the top of the header." | 272 | The ACTION is one of 'remove or 'add. If 'add, the VALUE is added. |
| 273 | If the field wasn't present, it is added to the top of the header." | ||
| 271 | (mh-identity-handler-default field action t value)) | 274 | (mh-identity-handler-default field action t value)) |
| 272 | 275 | ||
| 273 | ;;;###mh-autoload | 276 | ;;;###mh-autoload |
| 274 | (defun mh-identity-handler-bottom (field action &optional value) | 277 | (defun mh-identity-handler-bottom (field action &optional value) |
| 275 | "For FIELD, process mh-identity headers for ACTION 'remove or 'add. | 278 | "Process header FIELD. |
| 276 | If the field wasn't present, the VALUE is added at the bottom of the header." | 279 | The ACTION is one of 'remove or 'add. If 'add, the VALUE is added. |
| 280 | If the field wasn't present, it is added to the bottom of the header." | ||
| 277 | (mh-identity-handler-default field action nil value)) | 281 | (mh-identity-handler-default field action nil value)) |
| 278 | 282 | ||
| 279 | (provide 'mh-identity) | 283 | (provide 'mh-identity) |
diff --git a/lisp/mh-e/mh-inc.el b/lisp/mh-e/mh-inc.el index 95341fa75f7..c9a9c6cb6b6 100644 --- a/lisp/mh-e/mh-inc.el +++ b/lisp/mh-e/mh-inc.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; mh-inc.el --- MH-E `inc' and separate mail spool handling | 1 | ;;; mh-inc.el --- MH-E `inc' and separate mail spool handling |
| 2 | ;; | 2 | ;; |
| 3 | ;; Copyright (C) 2005 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 2003, 2004 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Peter S. Galbraith <psg@debian.org> | 5 | ;; Author: Peter S. Galbraith <psg@debian.org> |
| 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> | 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> |
| @@ -98,10 +98,10 @@ This is called after 'customize is used to alter `mh-inc-spool-list'." | |||
| 98 | 98 | ||
| 99 | (provide 'mh-inc) | 99 | (provide 'mh-inc) |
| 100 | 100 | ||
| 101 | ;; Local Variables: | 101 | ;;; Local Variables: |
| 102 | ;; indent-tabs-mode: nil | 102 | ;;; indent-tabs-mode: nil |
| 103 | ;; sentence-end-double-space: nil | 103 | ;;; sentence-end-double-space: nil |
| 104 | ;; End: | 104 | ;;; End: |
| 105 | 105 | ||
| 106 | ;; arch-tag: 3713cf2a-6082-4cb4-8ce2-99d9acaba835 | 106 | ;;; arch-tag: 3713cf2a-6082-4cb4-8ce2-99d9acaba835 |
| 107 | ;;; mh-inc.el ends here | 107 | ;;; mh-inc.el ends here |
diff --git a/lisp/mh-e/mh-index.el b/lisp/mh-e/mh-index.el index cde630236b0..7a52b94dd2b 100644 --- a/lisp/mh-e/mh-index.el +++ b/lisp/mh-e/mh-index.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; mh-index -- MH-E interface to indexing programs | 1 | ;;; mh-index -- MH-E interface to indexing programs |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 2005 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 2002, 2003, 2004, 2005 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Satyaki Das <satyaki@theforce.stanford.edu> | 5 | ;; Author: Satyaki Das <satyaki@theforce.stanford.edu> |
| 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> | 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> |
| @@ -31,6 +31,7 @@ | |||
| 31 | ;;; swish-e | 31 | ;;; swish-e |
| 32 | ;;; mairix | 32 | ;;; mairix |
| 33 | ;;; namazu | 33 | ;;; namazu |
| 34 | ;;; pick | ||
| 34 | ;;; grep | 35 | ;;; grep |
| 35 | ;;; | 36 | ;;; |
| 36 | ;;; (2) To use this package, you first have to build an index. Please read | 37 | ;;; (2) To use this package, you first have to build an index. Please read |
| @@ -352,43 +353,74 @@ they are concatenated to construct the base name." | |||
| 352 | (defun* mh-index-search (redo-search-flag folder search-regexp | 353 | (defun* mh-index-search (redo-search-flag folder search-regexp |
| 353 | &optional window-config) | 354 | &optional window-config) |
| 354 | "Perform an indexed search in an MH mail folder. | 355 | "Perform an indexed search in an MH mail folder. |
| 355 | Use a prefix argument to repeat the search, as in REDO-SEARCH-FLAG below. | 356 | Use a prefix argument to repeat the search. |
| 356 | 357 | ||
| 357 | If REDO-SEARCH-FLAG is non-nil and the current folder buffer was generated by a | 358 | Unlike regular searches, the prompt for the folder to search can be `all' to |
| 358 | index search, then the search is repeated. Otherwise, FOLDER is searched with | 359 | search all folders; in addition, the search works recursively on the listed |
| 359 | SEARCH-REGEXP and the results are presented in an MH-E folder. If FOLDER is | 360 | folder. The search criteria are entered in an MH-Pick buffer as described in |
| 360 | \"+\" then mail in all folders are searched. Optional argument WINDOW-CONFIG | 361 | `mh-search-folder'. |
| 361 | stores the window configuration that will be restored after the user quits the | 362 | |
| 362 | folder containing the index search results. | 363 | To perform the search, type \\<mh-pick-mode-map>\\[mh-do-search]. Another |
| 363 | 364 | difference from the regular searches is that because the search operates on | |
| 364 | Four indexing programs are supported; if none of these are present, then grep | 365 | more than one folder, the messages that are found are put in a temporary |
| 365 | is used. This function picks the first program that is available on your | 366 | sub-folder of `+mhe-index' and are displayed in an MH-Folder buffer. This |
| 366 | system. If you would prefer to use a different program, set the customization | 367 | buffer is special because it displays messages from multiple folders; each set |
| 367 | variable `mh-index-program' accordingly. | 368 | of messages from a given folder has a heading with the folder name. |
| 368 | 369 | ||
| 369 | The documentation for the following functions describes how to generate the | 370 | In addition, the \\<mh-folder-mode-map>\\[mh-index-visit-folder] command can |
| 370 | index for each program: | 371 | be used to visit the folder of the message at point. Initially, only the |
| 372 | messages that matched the search criteria are displayed in the folder. While | ||
| 373 | the temporary buffer has its own set of message numbers, the actual messages | ||
| 374 | numbers are shown in the visited folder. Thus, the \\[mh-index-visit-folder] | ||
| 375 | command is useful to find the actual message number of an interesting message, | ||
| 376 | or to view surrounding messages with the \\[mh-rescan-folder] command. | ||
| 377 | |||
| 378 | Because this folder is temporary, you'll probably get in the habit of killing | ||
| 379 | it when you're done with \\[mh-kill-folder]. | ||
| 380 | |||
| 381 | If you have run the \\[mh-search-folder] command, but change your mind while | ||
| 382 | entering the search criteria and actually want to run an indexed search, then | ||
| 383 | you can use the \\<mh-pick-mode-map>\\[mh-index-do-search] command in the | ||
| 384 | MH-Pick buffer. | ||
| 385 | |||
| 386 | The \\<mh-folder-mode-map>\\[mh-index-search] command runs the command defined | ||
| 387 | by the `mh-index-program' option. The default value is \"Auto-detect\" which | ||
| 388 | means that MH-E will automatically choose one of \"swish++\", \"swish-e\", | ||
| 389 | \"mairix\", \"namazu\", \"pick\" and \"grep\" in that order. If, for example, | ||
| 390 | you have both \"swish++\" and \"mairix\" installed and you want to use | ||
| 391 | \"mairix\", then you can set this option to \"mairix\". | ||
| 392 | |||
| 393 | *NOTE* | ||
| 394 | |||
| 395 | The \"pick\" and \"grep\" commands do not perform a recursive search on | ||
| 396 | the given folder. | ||
| 397 | |||
| 398 | This command uses an \"X-MHE-Checksum:\" header field to cache the MD5 | ||
| 399 | checksum of a message. This means that if an incoming message already contains | ||
| 400 | an \"X-MHE-Checksum:\" field, that message might not be found by this command. | ||
| 401 | The following \"procmail\" recipe avoids this problem by renaming the existing | ||
| 402 | header field: | ||
| 403 | |||
| 404 | :0 wf | ||
| 405 | | formail -R \"X-MHE-Checksum\" \"X-Old-MHE-Checksum\" | ||
| 406 | |||
| 407 | The documentation for the following commands describe how to set up the | ||
| 408 | various indexing programs to use with MH-E. The \"pick\" and \"grep\" commands | ||
| 409 | do not require additional configuration. | ||
| 371 | 410 | ||
| 372 | - `mh-swish++-execute-search' | 411 | - `mh-swish++-execute-search' |
| 373 | - `mh-swish-execute-search' | 412 | - `mh-swish-execute-search' |
| 374 | - `mh-mairix-execute-search' | 413 | - `mh-mairix-execute-search' |
| 375 | - `mh-namazu-execute-search' | 414 | - `mh-namazu-execute-search' |
| 376 | |||
| 377 | If none of these programs are present then we use pick. If desired grep can be | ||
| 378 | used instead. Details about these methods can be found in: | ||
| 379 | |||
| 380 | - `mh-pick-execute-search' | 415 | - `mh-pick-execute-search' |
| 381 | - `mh-grep-execute-search' | 416 | - `mh-grep-execute-search' |
| 382 | 417 | ||
| 383 | This and related functions use an X-MHE-Checksum header to cache the MD5 | 418 | In a program, if REDO-SEARCH-FLAG is non-nil and the current folder buffer was |
| 384 | checksum of a message. This means that already present X-MHE-Checksum headers | 419 | generated by a index search, then the search is repeated. Otherwise, FOLDER is |
| 385 | in the incoming email could result in messages not being found. The following | 420 | searched with SEARCH-REGEXP and the results are presented in an MH-E folder. |
| 386 | procmail recipe should avoid this: | 421 | If FOLDER is \"+\" then mail in all folders are searched. Optional argument |
| 387 | 422 | WINDOW-CONFIG stores the window configuration that will be restored after the | |
| 388 | :0 wf | 423 | user quits the folder containing the index search results." |
| 389 | | formail -R \"X-MHE-Checksum\" \"Old-X-MHE-Checksum\" | ||
| 390 | |||
| 391 | This has the effect of renaming already present X-MHE-Checksum headers." | ||
| 392 | (interactive | 424 | (interactive |
| 393 | (list current-prefix-arg | 425 | (list current-prefix-arg |
| 394 | (progn | 426 | (progn |
| @@ -998,8 +1030,8 @@ Unlike the other index search programs \"pick\" only searches messages present | |||
| 998 | in the folder itself and does not descend into any sub-folders that may be | 1030 | in the folder itself and does not descend into any sub-folders that may be |
| 999 | present. | 1031 | present. |
| 1000 | 1032 | ||
| 1001 | FOLDER-PATH is the directory containing the mails to be searched and | 1033 | In a program, FOLDER-PATH is the directory in which SEARCH-REGEXP is used |
| 1002 | SEARCH-REGEXP is the pattern that pick gets." | 1034 | to search." |
| 1003 | (set-buffer (get-buffer-create mh-index-temp-buffer)) | 1035 | (set-buffer (get-buffer-create mh-index-temp-buffer)) |
| 1004 | (erase-buffer) | 1036 | (erase-buffer) |
| 1005 | (setq mh-index-pick-folder | 1037 | (setq mh-index-pick-folder |
| @@ -1029,7 +1061,13 @@ SEARCH-REGEXP is the pattern that pick gets." | |||
| 1029 | 1061 | ||
| 1030 | (defun mh-grep-execute-search (folder-path search-regexp) | 1062 | (defun mh-grep-execute-search (folder-path search-regexp) |
| 1031 | "Execute grep and read the results. | 1063 | "Execute grep and read the results. |
| 1032 | FOLDER-PATH is the directory in which SEARCH-REGEXP is used to search." | 1064 | |
| 1065 | Unlike the other index search programs \"grep\" only searches messages present | ||
| 1066 | in the folder itself and does not descend into any sub-folders that may be | ||
| 1067 | present. | ||
| 1068 | |||
| 1069 | In a program, FOLDER-PATH is the directory in which SEARCH-REGEXP is used | ||
| 1070 | to search." | ||
| 1033 | (set-buffer (get-buffer-create mh-index-temp-buffer)) | 1071 | (set-buffer (get-buffer-create mh-index-temp-buffer)) |
| 1034 | (erase-buffer) | 1072 | (erase-buffer) |
| 1035 | (call-process mh-grep-binary nil '(t nil) nil | 1073 | (call-process mh-grep-binary nil '(t nil) nil |
| @@ -1081,34 +1119,34 @@ other matches left then return nil. If the current record is invalid return | |||
| 1081 | (defun mh-mairix-execute-search (folder-path search-regexp-list) | 1119 | (defun mh-mairix-execute-search (folder-path search-regexp-list) |
| 1082 | "Execute mairix and read the results. | 1120 | "Execute mairix and read the results. |
| 1083 | 1121 | ||
| 1084 | In the examples below replace /home/user/Mail with the path to your MH | 1122 | In the examples below, replace \"/home/user/Mail\" with the path to your MH |
| 1085 | directory. | 1123 | directory. |
| 1086 | 1124 | ||
| 1087 | First create the directory /home/user/Mail/.mairix. Then create the file | 1125 | First create the directory \"/home/user/Mail/.mairix\". Then create the file |
| 1088 | /home/user/Mail/.mairix/config with the following contents: | 1126 | \"/home/user/Mail/.mairix/config\" with the following contents: |
| 1089 | 1127 | ||
| 1090 | # This should contain the same thing as your `mh-user-path' | 1128 | base=/home/user/Mail |
| 1091 | base=/home/user/Mail | ||
| 1092 | 1129 | ||
| 1093 | # List of folders that should be indexed. 3 dots at the end means there are | 1130 | # List of folders that should be indexed. 3 dots at the end means there |
| 1094 | # subfolders within the folder | 1131 | # are subfolders within the folder |
| 1095 | mh_folders=archive...:inbox:drafts:news:sent:trash | 1132 | mh=archive...:inbox:drafts:news:sent:trash |
| 1096 | 1133 | ||
| 1097 | vfolder_format=raw | 1134 | vfolder_format=raw |
| 1098 | database=/home/user/Mail/mairix/database | 1135 | database=/home/user/Mail/mairix/database |
| 1099 | 1136 | ||
| 1100 | Use the following command line to generate the mairix index. Run this daily | 1137 | Use the following command line to generate the mairix index. Run this daily |
| 1101 | from cron: | 1138 | from cron: |
| 1102 | 1139 | ||
| 1103 | mairix -f /home/user/Mail/.mairix/config | 1140 | mairix -f /home/user/Mail/.mairix/config |
| 1104 | 1141 | ||
| 1105 | FOLDER-PATH is the directory in which SEARCH-REGEXP-LIST is used to search." | 1142 | In a program, FOLDER-PATH is the directory in which SEARCH-REGEXP-LIST is used |
| 1143 | to search." | ||
| 1106 | (set-buffer (get-buffer-create mh-index-temp-buffer)) | 1144 | (set-buffer (get-buffer-create mh-index-temp-buffer)) |
| 1107 | (erase-buffer) | 1145 | (erase-buffer) |
| 1108 | (unless mh-mairix-binary | 1146 | (unless mh-mairix-binary |
| 1109 | (error "Set mh-mairix-binary appropriately")) | 1147 | (error "Set mh-mairix-binary appropriately")) |
| 1110 | (apply #'call-process mh-mairix-binary nil '(t nil) nil | 1148 | (apply #'call-process mh-mairix-binary nil '(t nil) nil |
| 1111 | "-f" (format "%s%s/config" mh-user-path mh-mairix-directory) | 1149 | "-r" "-f" (format "%s%s/config" mh-user-path mh-mairix-directory) |
| 1112 | search-regexp-list) | 1150 | search-regexp-list) |
| 1113 | (goto-char (point-min)) | 1151 | (goto-char (point-min)) |
| 1114 | (setq mh-mairix-folder | 1152 | (setq mh-mairix-folder |
| @@ -1167,10 +1205,10 @@ REGEXP-LIST is an alist of fields and values." | |||
| 1167 | (let ((expr-list (cdr conjunct)) | 1205 | (let ((expr-list (cdr conjunct)) |
| 1168 | (expr-string "")) | 1206 | (expr-string "")) |
| 1169 | (dolist (e expr-list) | 1207 | (dolist (e expr-list) |
| 1170 | (setq expr-string (concat expr-string "+" | 1208 | (setq expr-string (concat expr-string "," |
| 1171 | (if (atom e) "" "~") | 1209 | (if (atom e) "" "~") |
| 1172 | (if (atom e) e (cadr e))))) | 1210 | (if (atom e) e (cadr e))))) |
| 1173 | (setq final (concat final "," (substring expr-string 1))))) | 1211 | (setq final (concat final "/" (substring expr-string 1))))) |
| 1174 | (substring final 1))) | 1212 | (substring final 1))) |
| 1175 | result))) | 1213 | result))) |
| 1176 | result)) | 1214 | result)) |
| @@ -1327,52 +1365,49 @@ space-separated list of FOLDERS, or nothing to search all folders." | |||
| 1327 | (defun mh-swish-execute-search (folder-path search-regexp) | 1365 | (defun mh-swish-execute-search (folder-path search-regexp) |
| 1328 | "Execute swish-e and read the results. | 1366 | "Execute swish-e and read the results. |
| 1329 | 1367 | ||
| 1330 | In the examples below, replace /home/user/Mail with the path to your MH | 1368 | In the examples below, replace \"/home/user/Mail\" with the path to your |
| 1331 | directory. | 1369 | MH directory. |
| 1332 | 1370 | ||
| 1333 | First create the directory /home/user/Mail/.swish. Then create the file | 1371 | First create the directory \"/home/user/Mail/.swish\". Then create the file |
| 1334 | /home/user/Mail/.swish/config with the following contents: | 1372 | \"/home/user/Mail/.swish/config\" with the following contents: |
| 1335 | 1373 | ||
| 1336 | IndexDir /home/user/Mail | 1374 | DefaultContents TXT* |
| 1337 | IndexFile /home/user/Mail/.swish/index | 1375 | IndexDir /home/user/Mail |
| 1338 | IndexName \"Mail Index\" | 1376 | IndexFile /home/user/Mail/.swish/index |
| 1339 | IndexDescription \"Mail Index\" | 1377 | IndexName \"Mail Index\" |
| 1340 | IndexPointer \"http://nowhere\" | 1378 | IndexDescription \"Mail Index\" |
| 1341 | IndexAdmin \"nobody\" | 1379 | IndexPointer \"http://nowhere\" |
| 1342 | #MetaNames automatic | 1380 | IndexAdmin \"nobody\" |
| 1343 | IndexReport 3 | 1381 | #MetaNames automatic |
| 1344 | FollowSymLinks no | 1382 | IndexReport 3 |
| 1345 | UseStemming no | 1383 | FollowSymLinks no |
| 1346 | IgnoreTotalWordCountWhenRanking yes | 1384 | UseStemming no |
| 1347 | WordCharacters abcdefghijklmnopqrstuvwxyz0123456789- | 1385 | IgnoreTotalWordCountWhenRanking yes |
| 1348 | BeginCharacters abcdefghijklmnopqrstuvwxyz | 1386 | WordCharacters abcdefghijklmnopqrstuvwxyz0123456789- |
| 1349 | EndCharacters abcdefghijklmnopqrstuvwxyz0123456789 | 1387 | BeginCharacters abcdefghijklmnopqrstuvwxyz |
| 1350 | IgnoreLimit 50 1000 | 1388 | EndCharacters abcdefghijklmnopqrstuvwxyz0123456789 |
| 1351 | IndexComments 0 | 1389 | IgnoreLimit 50 1000 |
| 1352 | FileRules pathname contains /home/user/Mail/.swish | 1390 | IndexComments 0 |
| 1353 | FileRules pathname contains /home/user/Mail/mhe-index | 1391 | FileRules filename contains \\D |
| 1354 | FileRules filename is index | 1392 | FileRules pathname contains /home/user/Mail/.swish |
| 1355 | FileRules filename is \\..* | 1393 | FileRules pathname contains /home/user/Mail/mhe-index |
| 1356 | FileRules filename is #.* | 1394 | |
| 1357 | FileRules filename is ,.* | 1395 | This configuration does not index the folders that hold the results of your |
| 1358 | FileRules filename is .*~ | 1396 | searches in \"+mhe-index\" since they tend to be ephemeral and the original |
| 1397 | messages are indexed anyway. | ||
| 1359 | 1398 | ||
| 1360 | If there are any directories you would like to ignore, append lines like the | 1399 | If there are any directories you would like to ignore, append lines like the |
| 1361 | following to config: | 1400 | following to \"config\": |
| 1362 | |||
| 1363 | FileRules pathname contains /home/user/Mail/scripts | ||
| 1364 | 1401 | ||
| 1365 | You do not want to index the folders that hold the results of your searches | 1402 | FileRules pathname contains /home/user/Mail/scripts |
| 1366 | since they tend to be ephemeral and the original messages are indexed anyway. | ||
| 1367 | The configuration file above assumes that the results are found in sub-folders | ||
| 1368 | of `mh-index-folder' which is +mhe-index by default. | ||
| 1369 | 1403 | ||
| 1370 | Use the following command line to generate the swish index. Run this | 1404 | Use the following command line to generate the swish index. Run this daily |
| 1371 | daily from cron: | 1405 | from cron: |
| 1372 | 1406 | ||
| 1373 | swish-e -c /home/user/Mail/.swish/config | 1407 | swish-e -c /home/user/Mail/.swish/config |
| 1374 | 1408 | ||
| 1375 | FOLDER-PATH is the directory in which SEARCH-REGEXP is used to search." | 1409 | In a program, FOLDER-PATH is the directory in which SEARCH-REGEXP is used to |
| 1410 | search." | ||
| 1376 | (set-buffer (get-buffer-create mh-index-temp-buffer)) | 1411 | (set-buffer (get-buffer-create mh-index-temp-buffer)) |
| 1377 | (erase-buffer) | 1412 | (erase-buffer) |
| 1378 | (unless mh-swish-binary | 1413 | (unless mh-swish-binary |
| @@ -1407,7 +1442,8 @@ FOLDER-PATH is the directory in which SEARCH-REGEXP is used to search." | |||
| 1407 | (list (let* ((s (buffer-substring-no-properties start (1+ (point))))) | 1442 | (list (let* ((s (buffer-substring-no-properties start (1+ (point))))) |
| 1408 | (unless (string-match mh-swish-folder s) | 1443 | (unless (string-match mh-swish-folder s) |
| 1409 | (return 'error)) | 1444 | (return 'error)) |
| 1410 | (if (string-match mh-user-path s) | 1445 | (if (and (string-match mh-user-path s) |
| 1446 | (< (match-end 0) (1- (length s)))) | ||
| 1411 | (format "+%s" | 1447 | (format "+%s" |
| 1412 | (substring s (match-end 0) (1- (length s)))) | 1448 | (substring s (match-end 0) (1- (length s)))) |
| 1413 | (return 'error))) | 1449 | (return 'error))) |
| @@ -1431,34 +1467,35 @@ FOLDER-PATH is the directory in which SEARCH-REGEXP is used to search." | |||
| 1431 | (defun mh-swish++-execute-search (folder-path search-regexp) | 1467 | (defun mh-swish++-execute-search (folder-path search-regexp) |
| 1432 | "Execute swish++ and read the results. | 1468 | "Execute swish++ and read the results. |
| 1433 | 1469 | ||
| 1434 | In the examples below, replace /home/user/Mail with the path to your MH | 1470 | In the examples below, replace \"/home/user/Mail\" with the path to your MH |
| 1435 | directory. | 1471 | directory. |
| 1436 | 1472 | ||
| 1437 | First create the directory /home/user/Mail/.swish++. Then create the file | 1473 | First create the directory \"/home/user/Mail/.swish++\". Then create the file |
| 1438 | /home/user/Mail/.swish++/swish++.conf with the following contents: | 1474 | \"/home/user/Mail/.swish++/swish++.conf\" with the following contents: |
| 1439 | 1475 | ||
| 1440 | IncludeMeta Bcc Cc Comments Content-Description From Keywords | 1476 | IncludeMeta Bcc Cc Comments Content-Description From Keywords |
| 1441 | IncludeMeta Newsgroups Resent-To Subject To | 1477 | IncludeMeta Newsgroups Resent-To Subject To |
| 1442 | IncludeMeta Message-Id References In-Reply-To | 1478 | IncludeMeta Message-Id References In-Reply-To |
| 1443 | IncludeFile Mail * | 1479 | IncludeFile Mail * |
| 1444 | IndexFile /home/user/Mail/.swish++/swish++.index | 1480 | IndexFile /home/user/Mail/.swish++/swish++.index |
| 1445 | 1481 | ||
| 1446 | Use the following command line to generate the swish index. Run this | 1482 | Use the following command line to generate the swish index. Run this daily |
| 1447 | daily from cron: | 1483 | from cron: |
| 1448 | 1484 | ||
| 1449 | find /home/user/Mail -path /home/user/Mail/mhe-index -prune \\ | 1485 | find /home/user/Mail -path /home/user/Mail/mhe-index -prune \\ |
| 1450 | -o -path /home/user/Mail/.swish++ -prune \\ | 1486 | -o -path /home/user/Mail/.swish++ -prune \\ |
| 1451 | -o -name \"[0-9]*\" -print \\ | 1487 | -o -name \"[0-9]*\" -print \\ |
| 1452 | | index -c /home/user/Mail/.swish++/swish++.conf /home/user/Mail | 1488 | | index -c /home/user/Mail/.swish++/swish++.conf - |
| 1453 | 1489 | ||
| 1454 | You do not want to index the folders that hold the results of your searches | 1490 | This command does not index the folders that hold the results of your searches |
| 1455 | since they tend to be ephemeral and the original messages are indexed anyway. | 1491 | in \"+mhe-index\" since they tend to be ephemeral and the original messages |
| 1456 | The command above assumes that the results are found in sub-folders of | 1492 | are indexed anyway. |
| 1457 | `mh-index-folder' which is +mhe-index by default. | ||
| 1458 | 1493 | ||
| 1459 | On some systems (Debian GNU/Linux, for example), use index++ instead of index. | 1494 | On some systems (Debian GNU/Linux, for example), use \"index++\" instead of |
| 1495 | \"index\". | ||
| 1460 | 1496 | ||
| 1461 | FOLDER-PATH is the directory in which SEARCH-REGEXP is used to search." | 1497 | In a program, FOLDER-PATH is the directory in which SEARCH-REGEXP is used to |
| 1498 | search." | ||
| 1462 | (set-buffer (get-buffer-create mh-index-temp-buffer)) | 1499 | (set-buffer (get-buffer-create mh-index-temp-buffer)) |
| 1463 | (erase-buffer) | 1500 | (erase-buffer) |
| 1464 | (unless mh-swish++-binary | 1501 | (unless mh-swish++-binary |
| @@ -1512,32 +1549,29 @@ REGEXP-LIST is an alist of fields and values." | |||
| 1512 | (defun mh-namazu-execute-search (folder-path search-regexp) | 1549 | (defun mh-namazu-execute-search (folder-path search-regexp) |
| 1513 | "Execute namazu and read the results. | 1550 | "Execute namazu and read the results. |
| 1514 | 1551 | ||
| 1515 | In the examples below, replace /home/user/Mail with the path to your MH | 1552 | In the examples below, replace \"/home/user/Mail\" with the path to your MH |
| 1516 | directory. | 1553 | directory. |
| 1517 | 1554 | ||
| 1518 | First create the directory /home/user/Mail/.namazu. Then create the file | 1555 | First create the directory \"/home/user/Mail/.namazu\". Then create the file |
| 1519 | /home/user/Mail/.namazu/mknmzrc with the following contents: | 1556 | \"/home/user/Mail/.namazu/mknmzrc\" with the following contents: |
| 1520 | 1557 | ||
| 1521 | package conf; # Don't remove this line! | 1558 | package conf; # Don't remove this line! |
| 1522 | $ADDRESS = 'user@localhost'; | 1559 | $ADDRESS = 'user@localhost'; |
| 1523 | $ALLOW_FILE = \"[0-9]*\"; | 1560 | $ALLOW_FILE = \"[0-9]*\"; |
| 1524 | $EXCLUDE_PATH = \"^/home/user/Mail/(mhe-index|spam)\"; | 1561 | $EXCLUDE_PATH = \"^/home/user/Mail/(mhe-index|spam)\"; |
| 1525 | 1562 | ||
| 1526 | In the above example configuration, none of the mail files contained in the | 1563 | This configuration does not index the folders that hold the results of your |
| 1527 | directories /home/user/Mail/mhe-index and /home/user/Mail/spam are indexed. | 1564 | searches in \"+mhe-index\" since they tend to be ephemeral and the original |
| 1565 | messages are indexed anyway. | ||
| 1528 | 1566 | ||
| 1529 | You do not want to index the folders that hold the results of your searches | 1567 | Use the following command line to generate the namazu index. Run this daily |
| 1530 | since they tend to be ephemeral and the original messages are indexed anyway. | 1568 | from cron: |
| 1531 | The configuration file above assumes that the results are found in sub-folders | ||
| 1532 | of `mh-index-folder' which is +mhe-index by default. | ||
| 1533 | |||
| 1534 | Use the following command line to generate the namazu index. Run this | ||
| 1535 | daily from cron: | ||
| 1536 | 1569 | ||
| 1537 | mknmz -f /home/user/Mail/.namazu/mknmzrc -O /home/user/Mail/.namazu \\ | 1570 | mknmz -f /home/user/Mail/.namazu/mknmzrc -O /home/user/Mail/.namazu \\ |
| 1538 | /home/user/Mail | 1571 | /home/user/Mail |
| 1539 | 1572 | ||
| 1540 | FOLDER-PATH is the directory in which SEARCH-REGEXP is used to search." | 1573 | In a program, FOLDER-PATH is the directory in which SEARCH-REGEXP is used to |
| 1574 | search." | ||
| 1541 | (let ((namazu-index-directory | 1575 | (let ((namazu-index-directory |
| 1542 | (format "%s%s" mh-user-path mh-namazu-directory))) | 1576 | (format "%s%s" mh-user-path mh-namazu-directory))) |
| 1543 | (unless (file-exists-p namazu-index-directory) | 1577 | (unless (file-exists-p namazu-index-directory) |
diff --git a/lisp/mh-e/mh-init.el b/lisp/mh-e/mh-init.el index b97e9fcde65..a975b882128 100644 --- a/lisp/mh-e/mh-init.el +++ b/lisp/mh-e/mh-init.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; mh-init.el --- MH-E initialization. | 1 | ;;; mh-init.el --- MH-E initialization. |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 2005 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 2003, 2004 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Peter S. Galbraith <psg@debian.org> | 5 | ;; Author: Peter S. Galbraith <psg@debian.org> |
| 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> | 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> |
diff --git a/lisp/mh-e/mh-junk.el b/lisp/mh-e/mh-junk.el index 29005d47aa6..e66f49e3a55 100644 --- a/lisp/mh-e/mh-junk.el +++ b/lisp/mh-e/mh-junk.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; mh-junk.el --- Interface to anti-spam measures | 1 | ;;; mh-junk.el --- Interface to anti-spam measures |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 2005 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 2003, 2004 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Satyaki Das <satyaki@theforce.stanford.edu>, | 5 | ;; Author: Satyaki Das <satyaki@theforce.stanford.edu>, |
| 6 | ;; Bill Wohler <wohler@newt.com> | 6 | ;; Bill Wohler <wohler@newt.com> |
| @@ -191,8 +191,8 @@ done by adding the following to your crontab: | |||
| 191 | (message (format "Blacklisting message %d..." msg)) | 191 | (message (format "Blacklisting message %d..." msg)) |
| 192 | (set-buffer (get-buffer-create mh-temp-buffer)) | 192 | (set-buffer (get-buffer-create mh-temp-buffer)) |
| 193 | (erase-buffer) | 193 | (erase-buffer) |
| 194 | (call-process (expand-file-name mh-scan-prog mh-progs) mh-junk-background | 194 | (call-process (expand-file-name mh-scan-prog mh-progs) |
| 195 | t nil | 195 | nil mh-junk-background nil |
| 196 | (format "%s" msg) current-folder | 196 | (format "%s" msg) current-folder |
| 197 | "-format" "%<(mymbox{from})%|%(addr{from})%>") | 197 | "-format" "%<(mymbox{from})%|%(addr{from})%>") |
| 198 | (goto-char (point-min)) | 198 | (goto-char (point-min)) |
diff --git a/lisp/mh-e/mh-loaddefs.el b/lisp/mh-e/mh-loaddefs.el index 4abe3b208ef..9accabede57 100644 --- a/lisp/mh-e/mh-loaddefs.el +++ b/lisp/mh-e/mh-loaddefs.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; mh-loaddefs.el --- automatically extracted autoloads | 1 | ;;; mh-loaddefs.el --- automatically extracted autoloads |
| 2 | ;; | 2 | ;; |
| 3 | ;;; Copyright (C) 2005 Free Software Foundation, Inc. | 3 | ;;; Copyright (C) 2003, 2004, 2005 Free Software Foundation, Inc. |
| 4 | ;;; Author: Bill Wohler <wohler@newt.com> | 4 | ;;; Author: Bill Wohler <wohler@newt.com> |
| 5 | ;;; Keywords: mail | 5 | ;;; Keywords: mail |
| 6 | ;;; Commentary: | 6 | ;;; Commentary: |
| @@ -13,7 +13,7 @@ | |||
| 13 | ;;;;;; mh-check-whom mh-insert-signature mh-to-fcc mh-to-field mh-fill-paragraph-function | 13 | ;;;;;; mh-check-whom mh-insert-signature mh-to-fcc mh-to-field mh-fill-paragraph-function |
| 14 | ;;;;;; mh-get-header-field mh-send-other-window mh-send mh-reply | 14 | ;;;;;; mh-get-header-field mh-send-other-window mh-send mh-reply |
| 15 | ;;;;;; mh-redistribute mh-forward mh-extract-rejected-mail mh-edit-again) | 15 | ;;;;;; mh-redistribute mh-forward mh-extract-rejected-mail mh-edit-again) |
| 16 | ;;;;;; "mh-comp" "mh-comp.el" (16665 53716)) | 16 | ;;;;;; "mh-comp" "mh-comp.el" (17048 51103)) |
| 17 | ;;; Generated autoloads from mh-comp.el | 17 | ;;; Generated autoloads from mh-comp.el |
| 18 | 18 | ||
| 19 | (autoload (quote mh-edit-again) "mh-comp" "\ | 19 | (autoload (quote mh-edit-again) "mh-comp" "\ |
| @@ -56,8 +56,10 @@ to reply to: | |||
| 56 | cc/all sender and all recipients. | 56 | cc/all sender and all recipients. |
| 57 | If optional prefix argument INCLUDEP provided, then include the message | 57 | If optional prefix argument INCLUDEP provided, then include the message |
| 58 | in the reply using filter `mhl.reply' in your MH directory. | 58 | in the reply using filter `mhl.reply' in your MH directory. |
| 59 | If the file named by `mh-repl-formfile' exists, it is used as a skeleton | 59 | If the file named by `mh-repl-formfile' exists, it is used as a skeleton for |
| 60 | for the reply. | 60 | the reply. If REPLY-TO is cc or all and you're using either the nmh or GNU |
| 61 | mailutils variants and the file names by `mh-repl-group-formfile' exists, it | ||
| 62 | is used instead. | ||
| 61 | 63 | ||
| 62 | See also `mh-send'." t nil) | 64 | See also `mh-send'." t nil) |
| 63 | 65 | ||
| @@ -183,7 +185,7 @@ If we are at the first header field go to the start of the message body." t nil) | |||
| 183 | ;;;;;; mh-store-msg mh-undo-folder mh-sort-folder mh-page-digest-backwards | 185 | ;;;;;; mh-store-msg mh-undo-folder mh-sort-folder mh-page-digest-backwards |
| 184 | ;;;;;; mh-page-digest mh-pipe-msg mh-pack-folder mh-list-folders | 186 | ;;;;;; mh-page-digest mh-pipe-msg mh-pack-folder mh-list-folders |
| 185 | ;;;;;; mh-kill-folder mh-copy-msg mh-burst-digest) "mh-funcs" "mh-funcs.el" | 187 | ;;;;;; mh-kill-folder mh-copy-msg mh-burst-digest) "mh-funcs" "mh-funcs.el" |
| 186 | ;;;;;; (16671 48788)) | 188 | ;;;;;; (17048 47864)) |
| 187 | ;;; Generated autoloads from mh-funcs.el | 189 | ;;; Generated autoloads from mh-funcs.el |
| 188 | 190 | ||
| 189 | (autoload (quote mh-burst-digest) "mh-funcs" "\ | 191 | (autoload (quote mh-burst-digest) "mh-funcs" "\ |
| @@ -261,7 +263,7 @@ Display cheat sheet for the commands of the current prefix in minibuffer." t nil | |||
| 261 | ;;;;;; mh-identity-insert-attribution-verb mh-identity-handler-attribution-verb | 263 | ;;;;;; mh-identity-insert-attribution-verb mh-identity-handler-attribution-verb |
| 262 | ;;;;;; mh-identity-handler-signature mh-identity-handler-gpg-identity | 264 | ;;;;;; mh-identity-handler-signature mh-identity-handler-gpg-identity |
| 263 | ;;;;;; mh-insert-identity mh-identity-list-set mh-identity-make-menu) | 265 | ;;;;;; mh-insert-identity mh-identity-list-set mh-identity-make-menu) |
| 264 | ;;;;;; "mh-identity" "mh-identity.el" (16671 57010)) | 266 | ;;;;;; "mh-identity" "mh-identity.el" (17044 63778)) |
| 265 | ;;; Generated autoloads from mh-identity.el | 267 | ;;; Generated autoloads from mh-identity.el |
| 266 | 268 | ||
| 267 | (autoload (quote mh-identity-make-menu) "mh-identity" "\ | 269 | (autoload (quote mh-identity-make-menu) "mh-identity" "\ |
| @@ -271,43 +273,46 @@ change." nil nil) | |||
| 271 | 273 | ||
| 272 | (autoload (quote mh-identity-list-set) "mh-identity" "\ | 274 | (autoload (quote mh-identity-list-set) "mh-identity" "\ |
| 273 | Update the `mh-identity-list' variable, and rebuild the menu. | 275 | Update the `mh-identity-list' variable, and rebuild the menu. |
| 274 | Sets the default for SYMBOL (e.g. `mh-identity-list') to VALUE (as set in | 276 | Sets the default for SYMBOL (for example, `mh-identity-list') to VALUE (as set |
| 275 | customization). This is called after 'customize is used to alter | 277 | in customization). This is called after 'customize is used to alter |
| 276 | `mh-identity-list'." nil nil) | 278 | `mh-identity-list'." nil nil) |
| 277 | 279 | ||
| 278 | (autoload (quote mh-insert-identity) "mh-identity" "\ | 280 | (autoload (quote mh-insert-identity) "mh-identity" "\ |
| 279 | Insert proper fields for given IDENTITY. | 281 | Insert fields specified by given IDENTITY. |
| 280 | Edit the `mh-identity-list' variable to define identity." t nil) | 282 | See `mh-identity-list'." t nil) |
| 281 | 283 | ||
| 282 | (autoload (quote mh-identity-handler-gpg-identity) "mh-identity" "\ | 284 | (autoload (quote mh-identity-handler-gpg-identity) "mh-identity" "\ |
| 283 | For FIELD \"pgg-default-user-id\", process for ACTION 'remove or 'add. | 285 | Process header FIELD \":pgg-default-user-id\". |
| 286 | The ACTION is one of 'remove or 'add. If 'add, the VALUE is added. | ||
| 284 | The buffer-local variable `mh-identity-pgg-default-user-id' is set to VALUE | 287 | The buffer-local variable `mh-identity-pgg-default-user-id' is set to VALUE |
| 285 | when action 'add is selected." nil nil) | 288 | when action 'add is selected." nil nil) |
| 286 | 289 | ||
| 287 | (autoload (quote mh-identity-handler-signature) "mh-identity" "\ | 290 | (autoload (quote mh-identity-handler-signature) "mh-identity" "\ |
| 288 | For FIELD \"signature\", process headers for ACTION 'remove or 'add. | 291 | Process header FIELD \":signature\". |
| 289 | The VALUE is added." nil nil) | 292 | The ACTION is one of 'remove or 'add. If 'add, the VALUE is added." nil nil) |
| 290 | 293 | ||
| 291 | (autoload (quote mh-identity-handler-attribution-verb) "mh-identity" "\ | 294 | (autoload (quote mh-identity-handler-attribution-verb) "mh-identity" "\ |
| 292 | For FIELD \"attribution_verb\", process headers for ACTION 'remove or 'add. | 295 | Process header FIELD \":attribution-verb\". |
| 293 | The VALUE is added." nil nil) | 296 | The ACTION is one of 'remove or 'add. If 'add, the VALUE is added." nil nil) |
| 294 | 297 | ||
| 295 | (autoload (quote mh-identity-insert-attribution-verb) "mh-identity" "\ | 298 | (autoload (quote mh-identity-insert-attribution-verb) "mh-identity" "\ |
| 296 | Insert VALUE as attribution verb, setting up delimiting markers. | 299 | Insert VALUE as attribution verb, setting up delimiting markers. |
| 297 | If VALUE is nil, use `mh-extract-from-attribution-verb'." nil nil) | 300 | If VALUE is nil, use `mh-extract-from-attribution-verb'." nil nil) |
| 298 | 301 | ||
| 299 | (autoload (quote mh-identity-handler-top) "mh-identity" "\ | 302 | (autoload (quote mh-identity-handler-top) "mh-identity" "\ |
| 300 | For FIELD, process mh-identity headers for ACTION 'remove or 'add. | 303 | Process header FIELD. |
| 301 | If the field wasn't present, the VALUE is added at the top of the header." nil nil) | 304 | The ACTION is one of 'remove or 'add. If 'add, the VALUE is added. |
| 305 | If the field wasn't present, it is added to the top of the header." nil nil) | ||
| 302 | 306 | ||
| 303 | (autoload (quote mh-identity-handler-bottom) "mh-identity" "\ | 307 | (autoload (quote mh-identity-handler-bottom) "mh-identity" "\ |
| 304 | For FIELD, process mh-identity headers for ACTION 'remove or 'add. | 308 | Process header FIELD. |
| 305 | If the field wasn't present, the VALUE is added at the bottom of the header." nil nil) | 309 | The ACTION is one of 'remove or 'add. If 'add, the VALUE is added. |
| 310 | If the field wasn't present, it is added to the bottom of the header." nil nil) | ||
| 306 | 311 | ||
| 307 | ;;;*** | 312 | ;;;*** |
| 308 | 313 | ||
| 309 | ;;;### (autoloads (mh-inc-spool-list-set) "mh-inc" "mh-inc.el" (16671 | 314 | ;;;### (autoloads (mh-inc-spool-list-set) "mh-inc" "mh-inc.el" (17048 |
| 310 | ;;;;;; 48848)) | 315 | ;;;;;; 44143)) |
| 311 | ;;; Generated autoloads from mh-inc.el | 316 | ;;; Generated autoloads from mh-inc.el |
| 312 | 317 | ||
| 313 | (autoload (quote mh-inc-spool-list-set) "mh-inc" "\ | 318 | (autoload (quote mh-inc-spool-list-set) "mh-inc" "\ |
| @@ -326,7 +331,7 @@ This is called after 'customize is used to alter `mh-inc-spool-list'." nil nil) | |||
| 326 | ;;;;;; mh-index-parse-search-regexp mh-index-do-search mh-index-p | 331 | ;;;;;; mh-index-parse-search-regexp mh-index-do-search mh-index-p |
| 327 | ;;;;;; mh-index-read-data mh-index-search mh-index-create-sequences | 332 | ;;;;;; mh-index-read-data mh-index-search mh-index-create-sequences |
| 328 | ;;;;;; mh-create-sequence-map mh-index-update-maps) "mh-index" "mh-index.el" | 333 | ;;;;;; mh-create-sequence-map mh-index-update-maps) "mh-index" "mh-index.el" |
| 329 | ;;;;;; (16665 53754)) | 334 | ;;;;;; (17044 64025)) |
| 330 | ;;; Generated autoloads from mh-index.el | 335 | ;;; Generated autoloads from mh-index.el |
| 331 | 336 | ||
| 332 | (autoload (quote mh-index-update-maps) "mh-index" "\ | 337 | (autoload (quote mh-index-update-maps) "mh-index" "\ |
| @@ -346,43 +351,74 @@ Mirror sequences present in source folders in index folder." nil nil) | |||
| 346 | 351 | ||
| 347 | (autoload (quote mh-index-search) "mh-index" "\ | 352 | (autoload (quote mh-index-search) "mh-index" "\ |
| 348 | Perform an indexed search in an MH mail folder. | 353 | Perform an indexed search in an MH mail folder. |
| 349 | Use a prefix argument to repeat the search, as in REDO-SEARCH-FLAG below. | 354 | Use a prefix argument to repeat the search. |
| 350 | 355 | ||
| 351 | If REDO-SEARCH-FLAG is non-nil and the current folder buffer was generated by a | 356 | Unlike regular searches, the prompt for the folder to search can be `all' to |
| 352 | index search, then the search is repeated. Otherwise, FOLDER is searched with | 357 | search all folders; in addition, the search works recursively on the listed |
| 353 | SEARCH-REGEXP and the results are presented in an MH-E folder. If FOLDER is | 358 | folder. The search criteria are entered in an MH-Pick buffer as described in |
| 354 | \"+\" then mail in all folders are searched. Optional argument WINDOW-CONFIG | 359 | `mh-search-folder'. |
| 355 | stores the window configuration that will be restored after the user quits the | 360 | |
| 356 | folder containing the index search results. | 361 | To perform the search, type \\<mh-pick-mode-map>\\[mh-do-search]. Another |
| 357 | 362 | difference from the regular searches is that because the search operates on | |
| 358 | Four indexing programs are supported; if none of these are present, then grep | 363 | more than one folder, the messages that are found are put in a temporary |
| 359 | is used. This function picks the first program that is available on your | 364 | sub-folder of `+mhe-index' and are displayed in an MH-Folder buffer. This |
| 360 | system. If you would prefer to use a different program, set the customization | 365 | buffer is special because it displays messages from multiple folders; each set |
| 361 | variable `mh-index-program' accordingly. | 366 | of messages from a given folder has a heading with the folder name. |
| 362 | 367 | ||
| 363 | The documentation for the following functions describes how to generate the | 368 | In addition, the \\<mh-folder-mode-map>\\[mh-index-visit-folder] command can |
| 364 | index for each program: | 369 | be used to visit the folder of the message at point. Initially, only the |
| 370 | messages that matched the search criteria are displayed in the folder. While | ||
| 371 | the temporary buffer has its own set of message numbers, the actual messages | ||
| 372 | numbers are shown in the visited folder. Thus, the \\[mh-index-visit-folder] | ||
| 373 | command is useful to find the actual message number of an interesting message, | ||
| 374 | or to view surrounding messages with the \\[mh-rescan-folder] command. | ||
| 375 | |||
| 376 | Because this folder is temporary, you'll probably get in the habit of killing | ||
| 377 | it when you're done with \\[mh-kill-folder]. | ||
| 378 | |||
| 379 | If you have run the \\[mh-search-folder] command, but change your mind while | ||
| 380 | entering the search criteria and actually want to run an indexed search, then | ||
| 381 | you can use the \\<mh-pick-mode-map>\\[mh-index-do-search] command in the | ||
| 382 | MH-Pick buffer. | ||
| 383 | |||
| 384 | The \\<mh-folder-mode-map>\\[mh-index-search] command runs the command defined | ||
| 385 | by the `mh-index-program' option. The default value is \"Auto-detect\" which | ||
| 386 | means that MH-E will automatically choose one of \"swish++\", \"swish-e\", | ||
| 387 | \"mairix\", \"namazu\", \"pick\" and \"grep\" in that order. If, for example, | ||
| 388 | you have both \"swish++\" and \"mairix\" installed and you want to use | ||
| 389 | \"mairix\", then you can set this option to \"mairix\". | ||
| 390 | |||
| 391 | *NOTE* | ||
| 392 | |||
| 393 | The \"pick\" and \"grep\" commands do not perform a recursive search on | ||
| 394 | the given folder. | ||
| 395 | |||
| 396 | This command uses an \"X-MHE-Checksum:\" header field to cache the MD5 | ||
| 397 | checksum of a message. This means that if an incoming message already contains | ||
| 398 | an \"X-MHE-Checksum:\" field, that message might not be found by this command. | ||
| 399 | The following \"procmail\" recipe avoids this problem by renaming the existing | ||
| 400 | header field: | ||
| 401 | |||
| 402 | :0 wf | ||
| 403 | | formail -R \"X-MHE-Checksum\" \"X-Old-MHE-Checksum\" | ||
| 404 | |||
| 405 | The documentation for the following commands describe how to set up the | ||
| 406 | various indexing programs to use with MH-E. The \"pick\" and \"grep\" commands | ||
| 407 | do not require additional configuration. | ||
| 365 | 408 | ||
| 366 | - `mh-swish++-execute-search' | 409 | - `mh-swish++-execute-search' |
| 367 | - `mh-swish-execute-search' | 410 | - `mh-swish-execute-search' |
| 368 | - `mh-mairix-execute-search' | 411 | - `mh-mairix-execute-search' |
| 369 | - `mh-namazu-execute-search' | 412 | - `mh-namazu-execute-search' |
| 370 | |||
| 371 | If none of these programs are present then we use pick. If desired grep can be | ||
| 372 | used instead. Details about these methods can be found in: | ||
| 373 | |||
| 374 | - `mh-pick-execute-search' | 413 | - `mh-pick-execute-search' |
| 375 | - `mh-grep-execute-search' | 414 | - `mh-grep-execute-search' |
| 376 | 415 | ||
| 377 | This and related functions use an X-MHE-Checksum header to cache the MD5 | 416 | In a program, if REDO-SEARCH-FLAG is non-nil and the current folder buffer was |
| 378 | checksum of a message. This means that already present X-MHE-Checksum headers | 417 | generated by a index search, then the search is repeated. Otherwise, FOLDER is |
| 379 | in the incoming email could result in messages not being found. The following | 418 | searched with SEARCH-REGEXP and the results are presented in an MH-E folder. |
| 380 | procmail recipe should avoid this: | 419 | If FOLDER is \"+\" then mail in all folders are searched. Optional argument |
| 381 | 420 | WINDOW-CONFIG stores the window configuration that will be restored after the | |
| 382 | :0 wf | 421 | user quits the folder containing the index search results." t nil) |
| 383 | | formail -R \"X-MHE-Checksum\" \"Old-X-MHE-Checksum\" | ||
| 384 | |||
| 385 | This has the effect of renaming already present X-MHE-Checksum headers." t nil) | ||
| 386 | 422 | ||
| 387 | (autoload (quote mh-index-read-data) "mh-index" "\ | 423 | (autoload (quote mh-index-read-data) "mh-index" "\ |
| 388 | Read index data from file." nil nil) | 424 | Read index data from file." nil nil) |
| @@ -463,114 +499,109 @@ space-separated list of FOLDERS, or nothing to search all folders." t nil) | |||
| 463 | (autoload (quote mh-swish-execute-search) "mh-index" "\ | 499 | (autoload (quote mh-swish-execute-search) "mh-index" "\ |
| 464 | Execute swish-e and read the results. | 500 | Execute swish-e and read the results. |
| 465 | 501 | ||
| 466 | In the examples below, replace /home/user/Mail with the path to your MH | 502 | In the examples below, replace \"/home/user/Mail\" with the path to your |
| 467 | directory. | 503 | MH directory. |
| 468 | 504 | ||
| 469 | First create the directory /home/user/Mail/.swish. Then create the file | 505 | First create the directory \"/home/user/Mail/.swish\". Then create the file |
| 470 | /home/user/Mail/.swish/config with the following contents: | 506 | \"/home/user/Mail/.swish/config\" with the following contents: |
| 471 | 507 | ||
| 472 | IndexDir /home/user/Mail | 508 | DefaultContents TXT* |
| 473 | IndexFile /home/user/Mail/.swish/index | 509 | IndexDir /home/user/Mail |
| 474 | IndexName \"Mail Index\" | 510 | IndexFile /home/user/Mail/.swish/index |
| 475 | IndexDescription \"Mail Index\" | 511 | IndexName \"Mail Index\" |
| 476 | IndexPointer \"http://nowhere\" | 512 | IndexDescription \"Mail Index\" |
| 477 | IndexAdmin \"nobody\" | 513 | IndexPointer \"http://nowhere\" |
| 478 | #MetaNames automatic | 514 | IndexAdmin \"nobody\" |
| 479 | IndexReport 3 | 515 | #MetaNames automatic |
| 480 | FollowSymLinks no | 516 | IndexReport 3 |
| 481 | UseStemming no | 517 | FollowSymLinks no |
| 482 | IgnoreTotalWordCountWhenRanking yes | 518 | UseStemming no |
| 483 | WordCharacters abcdefghijklmnopqrstuvwxyz0123456789- | 519 | IgnoreTotalWordCountWhenRanking yes |
| 484 | BeginCharacters abcdefghijklmnopqrstuvwxyz | 520 | WordCharacters abcdefghijklmnopqrstuvwxyz0123456789- |
| 485 | EndCharacters abcdefghijklmnopqrstuvwxyz0123456789 | 521 | BeginCharacters abcdefghijklmnopqrstuvwxyz |
| 486 | IgnoreLimit 50 1000 | 522 | EndCharacters abcdefghijklmnopqrstuvwxyz0123456789 |
| 487 | IndexComments 0 | 523 | IgnoreLimit 50 1000 |
| 488 | FileRules pathname contains /home/user/Mail/.swish | 524 | IndexComments 0 |
| 489 | FileRules pathname contains /home/user/Mail/mhe-index | 525 | FileRules filename contains \\D |
| 490 | FileRules filename is index | 526 | FileRules pathname contains /home/user/Mail/.swish |
| 491 | FileRules filename is \\..* | 527 | FileRules pathname contains /home/user/Mail/mhe-index |
| 492 | FileRules filename is #.* | 528 | |
| 493 | FileRules filename is ,.* | 529 | This configuration does not index the folders that hold the results of your |
| 494 | FileRules filename is .*~ | 530 | searches in \"+mhe-index\" since they tend to be ephemeral and the original |
| 531 | messages are indexed anyway. | ||
| 495 | 532 | ||
| 496 | If there are any directories you would like to ignore, append lines like the | 533 | If there are any directories you would like to ignore, append lines like the |
| 497 | following to config: | 534 | following to \"config\": |
| 498 | 535 | ||
| 499 | FileRules pathname contains /home/user/Mail/scripts | 536 | FileRules pathname contains /home/user/Mail/scripts |
| 500 | 537 | ||
| 501 | You do not want to index the folders that hold the results of your searches | 538 | Use the following command line to generate the swish index. Run this daily |
| 502 | since they tend to be ephemeral and the original messages are indexed anyway. | 539 | from cron: |
| 503 | The configuration file above assumes that the results are found in sub-folders | ||
| 504 | of `mh-index-folder' which is +mhe-index by default. | ||
| 505 | 540 | ||
| 506 | Use the following command line to generate the swish index. Run this | 541 | swish-e -c /home/user/Mail/.swish/config |
| 507 | daily from cron: | ||
| 508 | 542 | ||
| 509 | swish-e -c /home/user/Mail/.swish/config | 543 | In a program, FOLDER-PATH is the directory in which SEARCH-REGEXP is used to |
| 510 | 544 | search." nil nil) | |
| 511 | FOLDER-PATH is the directory in which SEARCH-REGEXP is used to search." nil nil) | ||
| 512 | 545 | ||
| 513 | (autoload (quote mh-swish++-execute-search) "mh-index" "\ | 546 | (autoload (quote mh-swish++-execute-search) "mh-index" "\ |
| 514 | Execute swish++ and read the results. | 547 | Execute swish++ and read the results. |
| 515 | 548 | ||
| 516 | In the examples below, replace /home/user/Mail with the path to your MH | 549 | In the examples below, replace \"/home/user/Mail\" with the path to your MH |
| 517 | directory. | 550 | directory. |
| 518 | 551 | ||
| 519 | First create the directory /home/user/Mail/.swish++. Then create the file | 552 | First create the directory \"/home/user/Mail/.swish++\". Then create the file |
| 520 | /home/user/Mail/.swish++/swish++.conf with the following contents: | 553 | \"/home/user/Mail/.swish++/swish++.conf\" with the following contents: |
| 521 | 554 | ||
| 522 | IncludeMeta Bcc Cc Comments Content-Description From Keywords | 555 | IncludeMeta Bcc Cc Comments Content-Description From Keywords |
| 523 | IncludeMeta Newsgroups Resent-To Subject To | 556 | IncludeMeta Newsgroups Resent-To Subject To |
| 524 | IncludeMeta Message-Id References In-Reply-To | 557 | IncludeMeta Message-Id References In-Reply-To |
| 525 | IncludeFile Mail * | 558 | IncludeFile Mail * |
| 526 | IndexFile /home/user/Mail/.swish++/swish++.index | 559 | IndexFile /home/user/Mail/.swish++/swish++.index |
| 527 | 560 | ||
| 528 | Use the following command line to generate the swish index. Run this | 561 | Use the following command line to generate the swish index. Run this daily |
| 529 | daily from cron: | 562 | from cron: |
| 530 | 563 | ||
| 531 | find /home/user/Mail -path /home/user/Mail/mhe-index -prune \\ | 564 | find /home/user/Mail -path /home/user/Mail/mhe-index -prune \\ |
| 532 | -o -path /home/user/Mail/.swish++ -prune \\ | 565 | -o -path /home/user/Mail/.swish++ -prune \\ |
| 533 | -o -name \"[0-9]*\" -print \\ | 566 | -o -name \"[0-9]*\" -print \\ |
| 534 | | index -c /home/user/Mail/.swish++/swish++.conf /home/user/Mail | 567 | | index -c /home/user/Mail/.swish++/swish++.conf - |
| 535 | 568 | ||
| 536 | You do not want to index the folders that hold the results of your searches | 569 | This command does not index the folders that hold the results of your searches |
| 537 | since they tend to be ephemeral and the original messages are indexed anyway. | 570 | in \"+mhe-index\" since they tend to be ephemeral and the original messages |
| 538 | The command above assumes that the results are found in sub-folders of | 571 | are indexed anyway. |
| 539 | `mh-index-folder' which is +mhe-index by default. | ||
| 540 | 572 | ||
| 541 | On some systems (Debian GNU/Linux, for example), use index++ instead of index. | 573 | On some systems (Debian GNU/Linux, for example), use \"index++\" instead of |
| 574 | \"index\". | ||
| 542 | 575 | ||
| 543 | FOLDER-PATH is the directory in which SEARCH-REGEXP is used to search." nil nil) | 576 | In a program, FOLDER-PATH is the directory in which SEARCH-REGEXP is used to |
| 577 | search." nil nil) | ||
| 544 | 578 | ||
| 545 | (autoload (quote mh-namazu-execute-search) "mh-index" "\ | 579 | (autoload (quote mh-namazu-execute-search) "mh-index" "\ |
| 546 | Execute namazu and read the results. | 580 | Execute namazu and read the results. |
| 547 | 581 | ||
| 548 | In the examples below, replace /home/user/Mail with the path to your MH | 582 | In the examples below, replace \"/home/user/Mail\" with the path to your MH |
| 549 | directory. | 583 | directory. |
| 550 | 584 | ||
| 551 | First create the directory /home/user/Mail/.namazu. Then create the file | 585 | First create the directory \"/home/user/Mail/.namazu\". Then create the file |
| 552 | /home/user/Mail/.namazu/mknmzrc with the following contents: | 586 | \"/home/user/Mail/.namazu/mknmzrc\" with the following contents: |
| 553 | |||
| 554 | package conf; # Don't remove this line! | ||
| 555 | $ADDRESS = 'user@localhost'; | ||
| 556 | $ALLOW_FILE = \"[0-9]*\"; | ||
| 557 | $EXCLUDE_PATH = \"^/home/user/Mail/(mhe-index|spam)\"; | ||
| 558 | 587 | ||
| 559 | In the above example configuration, none of the mail files contained in the | 588 | package conf; # Don't remove this line! |
| 560 | directories /home/user/Mail/mhe-index and /home/user/Mail/spam are indexed. | 589 | $ADDRESS = 'user@localhost'; |
| 590 | $ALLOW_FILE = \"[0-9]*\"; | ||
| 591 | $EXCLUDE_PATH = \"^/home/user/Mail/(mhe-index|spam)\"; | ||
| 561 | 592 | ||
| 562 | You do not want to index the folders that hold the results of your searches | 593 | This configuration does not index the folders that hold the results of your |
| 563 | since they tend to be ephemeral and the original messages are indexed anyway. | 594 | searches in \"+mhe-index\" since they tend to be ephemeral and the original |
| 564 | The configuration file above assumes that the results are found in sub-folders | 595 | messages are indexed anyway. |
| 565 | of `mh-index-folder' which is +mhe-index by default. | ||
| 566 | 596 | ||
| 567 | Use the following command line to generate the namazu index. Run this | 597 | Use the following command line to generate the namazu index. Run this daily |
| 568 | daily from cron: | 598 | from cron: |
| 569 | 599 | ||
| 570 | mknmz -f /home/user/Mail/.namazu/mknmzrc -O /home/user/Mail/.namazu \\ | 600 | mknmz -f /home/user/Mail/.namazu/mknmzrc -O /home/user/Mail/.namazu \\ |
| 571 | /home/user/Mail | 601 | /home/user/Mail |
| 572 | 602 | ||
| 573 | FOLDER-PATH is the directory in which SEARCH-REGEXP is used to search." nil nil) | 603 | In a program, FOLDER-PATH is the directory in which SEARCH-REGEXP is used to |
| 604 | search." nil nil) | ||
| 574 | 605 | ||
| 575 | (autoload (quote mh-index-choose) "mh-index" "\ | 606 | (autoload (quote mh-index-choose) "mh-index" "\ |
| 576 | Choose an indexing function. | 607 | Choose an indexing function. |
| @@ -582,7 +613,7 @@ system." nil nil) | |||
| 582 | ;;;*** | 613 | ;;;*** |
| 583 | 614 | ||
| 584 | ;;;### (autoloads (mh-variants mh-variant-p mh-variant-set) "mh-init" | 615 | ;;;### (autoloads (mh-variants mh-variant-p mh-variant-set) "mh-init" |
| 585 | ;;;;;; "mh-init.el" (16684 6777)) | 616 | ;;;;;; "mh-init.el" (17044 64253)) |
| 586 | ;;; Generated autoloads from mh-init.el | 617 | ;;; Generated autoloads from mh-init.el |
| 587 | 618 | ||
| 588 | (autoload (quote mh-variant-set) "mh-init" "\ | 619 | (autoload (quote mh-variant-set) "mh-init" "\ |
| @@ -604,7 +635,7 @@ by the variable `mh-variants'." nil nil) | |||
| 604 | ;;;*** | 635 | ;;;*** |
| 605 | 636 | ||
| 606 | ;;;### (autoloads (mh-junk-whitelist mh-junk-blacklist) "mh-junk" | 637 | ;;;### (autoloads (mh-junk-whitelist mh-junk-blacklist) "mh-junk" |
| 607 | ;;;;;; "mh-junk.el" (16671 48929)) | 638 | ;;;;;; "mh-junk.el" (17044 64253)) |
| 608 | ;;; Generated autoloads from mh-junk.el | 639 | ;;; Generated autoloads from mh-junk.el |
| 609 | 640 | ||
| 610 | (autoload (quote mh-junk-blacklist) "mh-junk" "\ | 641 | (autoload (quote mh-junk-blacklist) "mh-junk" "\ |
| @@ -644,7 +675,7 @@ The `mh-junk-program' option specifies the spam program in use." t nil) | |||
| 644 | ;;;;;; mh-mhn-compose-external-compressed-tar mh-mhn-compose-anon-ftp | 675 | ;;;;;; mh-mhn-compose-external-compressed-tar mh-mhn-compose-anon-ftp |
| 645 | ;;;;;; mh-mhn-compose-insertion mh-file-mime-type mh-have-file-command | 676 | ;;;;;; mh-mhn-compose-insertion mh-file-mime-type mh-have-file-command |
| 646 | ;;;;;; mh-compose-forward mh-compose-insertion) "mh-mime" "mh-mime.el" | 677 | ;;;;;; mh-compose-forward mh-compose-insertion) "mh-mime" "mh-mime.el" |
| 647 | ;;;;;; (16684 7323)) | 678 | ;;;;;; (17048 47895)) |
| 648 | ;;; Generated autoloads from mh-mime.el | 679 | ;;; Generated autoloads from mh-mime.el |
| 649 | 680 | ||
| 650 | (autoload (quote mh-compose-insertion) "mh-mime" "\ | 681 | (autoload (quote mh-compose-insertion) "mh-mime" "\ |
| @@ -857,15 +888,79 @@ View MIME PART-INDEX externally." t nil) | |||
| 857 | ;;;*** | 888 | ;;;*** |
| 858 | 889 | ||
| 859 | ;;;### (autoloads (mh-do-search mh-pick-do-search mh-search-folder) | 890 | ;;;### (autoloads (mh-do-search mh-pick-do-search mh-search-folder) |
| 860 | ;;;;;; "mh-pick" "mh-pick.el" (16671 49140)) | 891 | ;;;;;; "mh-pick" "mh-pick.el" (17048 47905)) |
| 861 | ;;; Generated autoloads from mh-pick.el | 892 | ;;; Generated autoloads from mh-pick.el |
| 862 | 893 | ||
| 863 | (autoload (quote mh-search-folder) "mh-pick" "\ | 894 | (autoload (quote mh-search-folder) "mh-pick" "\ |
| 864 | Search FOLDER for messages matching a pattern. | 895 | Search FOLDER for messages matching a pattern. |
| 865 | This function uses the MH command `pick' to do the work. | 896 | |
| 866 | Add the messages found to the sequence named `search'. | 897 | With this command, you can search a folder for messages to or from a |
| 867 | Argument WINDOW-CONFIG is the current window configuration and is used when | 898 | particular person or about a particular subject. In fact, you can also search |
| 868 | the search folder is dismissed." t nil) | 899 | for messages containing selected strings in any arbitrary header field or any |
| 900 | string found within the messages. | ||
| 901 | |||
| 902 | You are first prompted for the name of the folder to search and then placed in | ||
| 903 | the following buffer in MH-Pick mode: | ||
| 904 | |||
| 905 | From: | ||
| 906 | To: | ||
| 907 | Cc: | ||
| 908 | Date: | ||
| 909 | Subject: | ||
| 910 | -------- | ||
| 911 | |||
| 912 | Edit this template by entering your search criteria in an appropriate header | ||
| 913 | field that is already there, or create a new field yourself. If the string | ||
| 914 | you're looking for could be anywhere in a message, then place the string | ||
| 915 | underneath the row of dashes. The \\[mh-search-folder] command uses the MH | ||
| 916 | command \"pick\" to do the real work. | ||
| 917 | |||
| 918 | There are no semantics associated with the search criteria--they are simply | ||
| 919 | treated as strings. Case is ignored when all lowercase is used, and regular | ||
| 920 | expressions (a la \"ed\") are available. It is all right to specify several | ||
| 921 | search criteria. What happens then is that a logical _and_ of the various | ||
| 922 | fields is performed. If you prefer a logical _or_ operation, run | ||
| 923 | \\[mh-search-folder] multiple times. | ||
| 924 | |||
| 925 | As an example, let's say that we want to find messages from Ginnean about | ||
| 926 | horseback riding in the Kosciusko National Park (Australia) during January, | ||
| 927 | 1994. Normally we would start with a broad search and narrow it down if | ||
| 928 | necessary to produce a manageable amount of data, but we'll cut to the chase | ||
| 929 | and create a fairly restrictive set of criteria as follows: | ||
| 930 | |||
| 931 | From: ginnean | ||
| 932 | To: | ||
| 933 | Cc: | ||
| 934 | Date: Jan 1994 | ||
| 935 | Subject: horse.*kosciusko | ||
| 936 | -------- | ||
| 937 | |||
| 938 | As with MH-Letter mode, MH-Pick provides commands like | ||
| 939 | \\<mh-pick-mode-map>\\[mh-to-field] to help you fill in the blanks. | ||
| 940 | |||
| 941 | To perform the search, type \\[mh-do-search]. The selected messages are placed | ||
| 942 | in the \"search\" sequence, which you can use later in forwarding, printing, | ||
| 943 | or narrowing your field of view. Subsequent searches are appended to the | ||
| 944 | \"search\" sequence. If, however, you wish to start with a clean slate, first | ||
| 945 | delete the \"search\" sequence. | ||
| 946 | |||
| 947 | If you're searching in a folder that is already displayed in an MH-Folder | ||
| 948 | buffer, only those messages contained in the buffer are used for the search. | ||
| 949 | Therefore, if you want to search in all messages, first kill the folder's | ||
| 950 | buffer with \\<mh-folder-mode-map>\\[kill-buffer] or scan the entire folder | ||
| 951 | with \\[mh-rescan-folder]. | ||
| 952 | |||
| 953 | If you find that you do the same thing over and over when editing the search | ||
| 954 | template, you may wish to bind some shortcuts to keys. This can be done with | ||
| 955 | the variable `mh-pick-mode-hook', which is called when \\[mh-search-folder] is | ||
| 956 | run on a new pattern. | ||
| 957 | |||
| 958 | If you have run the \\[mh-index-search] command, but change your mind while | ||
| 959 | entering the search criteria and actually want to run a regular search, then | ||
| 960 | you can use the \\<mh-pick-mode-map>\\[mh-pick-do-search] command. | ||
| 961 | |||
| 962 | In a program, argument WINDOW-CONFIG is the current window configuration and | ||
| 963 | is used when the search folder is dismissed." t nil) | ||
| 869 | 964 | ||
| 870 | (autoload (quote mh-pick-do-search) "mh-pick" "\ | 965 | (autoload (quote mh-pick-do-search) "mh-pick" "\ |
| 871 | Find messages that match the qualifications in the current pattern buffer. | 966 | Find messages that match the qualifications in the current pattern buffer. |
| @@ -882,7 +977,7 @@ indexing program specified in `mh-index-program' is used." t nil) | |||
| 882 | 977 | ||
| 883 | ;;;### (autoloads (mh-print-msg mh-ps-print-toggle-mime mh-ps-print-toggle-color | 978 | ;;;### (autoloads (mh-print-msg mh-ps-print-toggle-mime mh-ps-print-toggle-color |
| 884 | ;;;;;; mh-ps-print-toggle-faces mh-ps-print-msg-show mh-ps-print-msg-file | 979 | ;;;;;; mh-ps-print-toggle-faces mh-ps-print-msg-show mh-ps-print-msg-file |
| 885 | ;;;;;; mh-ps-print-msg) "mh-print" "mh-print.el" (16680 11171)) | 980 | ;;;;;; mh-ps-print-msg) "mh-print" "mh-print.el" (17044 64253)) |
| 886 | ;;; Generated autoloads from mh-print.el | 981 | ;;; Generated autoloads from mh-print.el |
| 887 | 982 | ||
| 888 | (autoload (quote mh-ps-print-msg) "mh-print" "\ | 983 | (autoload (quote mh-ps-print-msg) "mh-print" "\ |
| @@ -935,7 +1030,7 @@ The messages are formatted by mhl. See the variable `mhl-formfile'." t nil) | |||
| 935 | ;;;;;; mh-rename-seq mh-translate-range mh-read-range mh-read-seq-default | 1030 | ;;;;;; mh-rename-seq mh-translate-range mh-read-range mh-read-seq-default |
| 936 | ;;;;;; mh-notate-deleted-and-refiled mh-widen mh-put-msg-in-seq | 1031 | ;;;;;; mh-notate-deleted-and-refiled mh-widen mh-put-msg-in-seq |
| 937 | ;;;;;; mh-narrow-to-seq mh-msg-is-in-seq mh-list-sequences mh-delete-seq) | 1032 | ;;;;;; mh-narrow-to-seq mh-msg-is-in-seq mh-list-sequences mh-delete-seq) |
| 938 | ;;;;;; "mh-seq" "mh-seq.el" (16671 65286)) | 1033 | ;;;;;; "mh-seq" "mh-seq.el" (17048 47921)) |
| 939 | ;;; Generated autoloads from mh-seq.el | 1034 | ;;; Generated autoloads from mh-seq.el |
| 940 | 1035 | ||
| 941 | (autoload (quote mh-delete-seq) "mh-seq" "\ | 1036 | (autoload (quote mh-delete-seq) "mh-seq" "\ |
| @@ -1157,7 +1252,7 @@ Use \\<mh-folder-mode-map>\\[mh-widen] to undo this command." t nil) | |||
| 1157 | 1252 | ||
| 1158 | ;;;### (autoloads (mh-speed-add-folder mh-speed-invalidate-map mh-speed-flists | 1253 | ;;;### (autoloads (mh-speed-add-folder mh-speed-invalidate-map mh-speed-flists |
| 1159 | ;;;;;; mh-speed-view mh-speed-toggle mh-folder-speedbar-buttons) | 1254 | ;;;;;; mh-speed-view mh-speed-toggle mh-folder-speedbar-buttons) |
| 1160 | ;;;;;; "mh-speed" "mh-speed.el" (16665 53793)) | 1255 | ;;;;;; "mh-speed" "mh-speed.el" (17044 64253)) |
| 1161 | ;;; Generated autoloads from mh-speed.el | 1256 | ;;; Generated autoloads from mh-speed.el |
| 1162 | 1257 | ||
| 1163 | (autoload (quote mh-folder-speedbar-buttons) "mh-speed" "\ | 1258 | (autoload (quote mh-folder-speedbar-buttons) "mh-speed" "\ |
| @@ -1196,7 +1291,7 @@ The function invalidates the latest ancestor that is present." nil nil) | |||
| 1196 | ;;;;;; mh-alias-grab-from-field mh-alias-add-alias mh-alias-for-from-p | 1291 | ;;;;;; mh-alias-grab-from-field mh-alias-add-alias mh-alias-for-from-p |
| 1197 | ;;;;;; mh-alias-address-to-alias mh-alias-letter-expand-alias mh-alias-minibuffer-confirm-address | 1292 | ;;;;;; mh-alias-address-to-alias mh-alias-letter-expand-alias mh-alias-minibuffer-confirm-address |
| 1198 | ;;;;;; mh-read-address mh-alias-reload-maybe mh-alias-reload) "mh-alias" | 1293 | ;;;;;; mh-read-address mh-alias-reload-maybe mh-alias-reload) "mh-alias" |
| 1199 | ;;;;;; "mh-alias.el" (16671 49382)) | 1294 | ;;;;;; "mh-alias.el" (17048 47789)) |
| 1200 | ;;; Generated autoloads from mh-alias.el | 1295 | ;;; Generated autoloads from mh-alias.el |
| 1201 | 1296 | ||
| 1202 | (autoload (quote mh-alias-reload) "mh-alias" "\ | 1297 | (autoload (quote mh-alias-reload) "mh-alias" "\ |
diff --git a/lisp/mh-e/mh-mime.el b/lisp/mh-e/mh-mime.el index d286069ba4b..dcd8f67a0f3 100644 --- a/lisp/mh-e/mh-mime.el +++ b/lisp/mh-e/mh-mime.el | |||
| @@ -1,6 +1,7 @@ | |||
| 1 | ;;; mh-mime.el --- MH-E support for composing MIME messages | 1 | ;;; mh-mime.el --- MH-E support for composing MIME messages |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1993, 1995, 2005 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 1993, 1995, |
| 4 | ;; 2001, 2002, 2003, 2004 Free Software Foundation, Inc. | ||
| 4 | 5 | ||
| 5 | ;; Author: Bill Wohler <wohler@newt.com> | 6 | ;; Author: Bill Wohler <wohler@newt.com> |
| 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> | 7 | ;; Maintainer: Bill Wohler <wohler@newt.com> |
| @@ -1325,6 +1326,18 @@ Parameter EL is unused." | |||
| 1325 | (point-max))) | 1326 | (point-max))) |
| 1326 | (forward-line -1))))) | 1327 | (forward-line -1))))) |
| 1327 | 1328 | ||
| 1329 | (defun mh-mime-security-button-face (info) | ||
| 1330 | "Return the button face to use for encrypted/signed mail based on INFO." | ||
| 1331 | (cond ((string-match "OK" info) ;Decrypted mail | ||
| 1332 | mh-show-pgg-good-face) | ||
| 1333 | ((string-match "Failed" info) ;Decryption failed or signature invalid | ||
| 1334 | mh-show-pgg-bad-face) | ||
| 1335 | ((string-match "Undecided" info);Unprocessed mail | ||
| 1336 | mh-show-pgg-unknown-face) | ||
| 1337 | ((string-match "Untrusted" info);Key not trusted | ||
| 1338 | mh-show-pgg-unknown-face) | ||
| 1339 | (t mh-show-pgg-good-face))) | ||
| 1340 | |||
| 1328 | (defun mh-mime-security-press-button (handle) | 1341 | (defun mh-mime-security-press-button (handle) |
| 1329 | "Callback from security button for part HANDLE." | 1342 | "Callback from security button for part HANDLE." |
| 1330 | (if (mm-handle-multipart-ctl-parameter handle 'gnus-info) | 1343 | (if (mm-handle-multipart-ctl-parameter handle 'gnus-info) |
| @@ -1364,9 +1377,10 @@ Parameter EL is unused." | |||
| 1364 | (info (or (mm-handle-multipart-ctl-parameter handle 'gnus-info) | 1377 | (info (or (mm-handle-multipart-ctl-parameter handle 'gnus-info) |
| 1365 | "Undecided")) | 1378 | "Undecided")) |
| 1366 | (details (mm-handle-multipart-ctl-parameter handle 'gnus-details)) | 1379 | (details (mm-handle-multipart-ctl-parameter handle 'gnus-details)) |
| 1367 | pressed-details begin end) | 1380 | pressed-details begin end face) |
| 1368 | (setq details (if details (concat "\n" details) "")) | 1381 | (setq details (if details (concat "\n" details) "")) |
| 1369 | (setq pressed-details (if mh-mime-security-button-pressed details "")) | 1382 | (setq pressed-details (if mh-mime-security-button-pressed details "")) |
| 1383 | (setq face (mh-mime-security-button-face info)) | ||
| 1370 | (unless (bolp) (insert "\n")) | 1384 | (unless (bolp) (insert "\n")) |
| 1371 | (setq begin (point)) | 1385 | (setq begin (point)) |
| 1372 | (gnus-eval-format | 1386 | (gnus-eval-format |
| @@ -1382,6 +1396,7 @@ Parameter EL is unused." | |||
| 1382 | :mime-handle handle | 1396 | :mime-handle handle |
| 1383 | :action 'mh-widget-press-button | 1397 | :action 'mh-widget-press-button |
| 1384 | :button-keymap mh-mime-security-button-map | 1398 | :button-keymap mh-mime-security-button-map |
| 1399 | :button-face face | ||
| 1385 | :help-echo "Mouse-2 click or press RET (in show buffer) to see security details.") | 1400 | :help-echo "Mouse-2 click or press RET (in show buffer) to see security details.") |
| 1386 | (dolist (ov (mh-funcall-if-exists overlays-in begin end)) | 1401 | (dolist (ov (mh-funcall-if-exists overlays-in begin end)) |
| 1387 | (mh-funcall-if-exists overlay-put ov 'evaporate t)) | 1402 | (mh-funcall-if-exists overlay-put ov 'evaporate t)) |
diff --git a/lisp/mh-e/mh-pick.el b/lisp/mh-e/mh-pick.el index 7b0ae4bafdf..5c31fb167cb 100644 --- a/lisp/mh-e/mh-pick.el +++ b/lisp/mh-e/mh-pick.el | |||
| @@ -1,6 +1,7 @@ | |||
| 1 | ;;; mh-pick.el --- make a search pattern and search for a message in MH-E | 1 | ;;; mh-pick.el --- make a search pattern and search for a message in MH-E |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1993, 1995, 2005 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 1993, 1995, |
| 4 | ;; 2001, 2003, 2004, 2005 Free Software Foundation, Inc. | ||
| 4 | 5 | ||
| 5 | ;; Author: Bill Wohler <wohler@newt.com> | 6 | ;; Author: Bill Wohler <wohler@newt.com> |
| 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> | 7 | ;; Maintainer: Bill Wohler <wohler@newt.com> |
| @@ -52,10 +53,74 @@ | |||
| 52 | ;;;###mh-autoload | 53 | ;;;###mh-autoload |
| 53 | (defun mh-search-folder (folder window-config) | 54 | (defun mh-search-folder (folder window-config) |
| 54 | "Search FOLDER for messages matching a pattern. | 55 | "Search FOLDER for messages matching a pattern. |
| 55 | This function uses the MH command `pick' to do the work. | 56 | |
| 56 | Add the messages found to the sequence named `search'. | 57 | With this command, you can search a folder for messages to or from a |
| 57 | Argument WINDOW-CONFIG is the current window configuration and is used when | 58 | particular person or about a particular subject. In fact, you can also search |
| 58 | the search folder is dismissed." | 59 | for messages containing selected strings in any arbitrary header field or any |
| 60 | string found within the messages. | ||
| 61 | |||
| 62 | You are first prompted for the name of the folder to search and then placed in | ||
| 63 | the following buffer in MH-Pick mode: | ||
| 64 | |||
| 65 | From: | ||
| 66 | To: | ||
| 67 | Cc: | ||
| 68 | Date: | ||
| 69 | Subject: | ||
| 70 | -------- | ||
| 71 | |||
| 72 | Edit this template by entering your search criteria in an appropriate header | ||
| 73 | field that is already there, or create a new field yourself. If the string | ||
| 74 | you're looking for could be anywhere in a message, then place the string | ||
| 75 | underneath the row of dashes. The \\[mh-search-folder] command uses the MH | ||
| 76 | command \"pick\" to do the real work. | ||
| 77 | |||
| 78 | There are no semantics associated with the search criteria--they are simply | ||
| 79 | treated as strings. Case is ignored when all lowercase is used, and regular | ||
| 80 | expressions (a la \"ed\") are available. It is all right to specify several | ||
| 81 | search criteria. What happens then is that a logical _and_ of the various | ||
| 82 | fields is performed. If you prefer a logical _or_ operation, run | ||
| 83 | \\[mh-search-folder] multiple times. | ||
| 84 | |||
| 85 | As an example, let's say that we want to find messages from Ginnean about | ||
| 86 | horseback riding in the Kosciusko National Park (Australia) during January, | ||
| 87 | 1994. Normally we would start with a broad search and narrow it down if | ||
| 88 | necessary to produce a manageable amount of data, but we'll cut to the chase | ||
| 89 | and create a fairly restrictive set of criteria as follows: | ||
| 90 | |||
| 91 | From: ginnean | ||
| 92 | To: | ||
| 93 | Cc: | ||
| 94 | Date: Jan 1994 | ||
| 95 | Subject: horse.*kosciusko | ||
| 96 | -------- | ||
| 97 | |||
| 98 | As with MH-Letter mode, MH-Pick provides commands like | ||
| 99 | \\<mh-pick-mode-map>\\[mh-to-field] to help you fill in the blanks. | ||
| 100 | |||
| 101 | To perform the search, type \\[mh-do-search]. The selected messages are placed | ||
| 102 | in the \"search\" sequence, which you can use later in forwarding, printing, | ||
| 103 | or narrowing your field of view. Subsequent searches are appended to the | ||
| 104 | \"search\" sequence. If, however, you wish to start with a clean slate, first | ||
| 105 | delete the \"search\" sequence. | ||
| 106 | |||
| 107 | If you're searching in a folder that is already displayed in an MH-Folder | ||
| 108 | buffer, only those messages contained in the buffer are used for the search. | ||
| 109 | Therefore, if you want to search in all messages, first kill the folder's | ||
| 110 | buffer with \\<mh-folder-mode-map>\\[kill-buffer] or scan the entire folder | ||
| 111 | with \\[mh-rescan-folder]. | ||
| 112 | |||
| 113 | If you find that you do the same thing over and over when editing the search | ||
| 114 | template, you may wish to bind some shortcuts to keys. This can be done with | ||
| 115 | the variable `mh-pick-mode-hook', which is called when \\[mh-search-folder] is | ||
| 116 | run on a new pattern. | ||
| 117 | |||
| 118 | If you have run the \\[mh-index-search] command, but change your mind while | ||
| 119 | entering the search criteria and actually want to run a regular search, then | ||
| 120 | you can use the \\<mh-pick-mode-map>\\[mh-pick-do-search] command. | ||
| 121 | |||
| 122 | In a program, argument WINDOW-CONFIG is the current window configuration and | ||
| 123 | is used when the search folder is dismissed." | ||
| 59 | (interactive (list (mh-prompt-for-folder "Search" mh-current-folder nil nil t) | 124 | (interactive (list (mh-prompt-for-folder "Search" mh-current-folder nil nil t) |
| 60 | (current-window-configuration))) | 125 | (current-window-configuration))) |
| 61 | (let ((pick-folder (if (equal folder "+") mh-current-folder folder))) | 126 | (let ((pick-folder (if (equal folder "+") mh-current-folder folder))) |
| @@ -140,8 +205,7 @@ with no arguments, upon entry to this mode. | |||
| 140 | (make-local-variable 'mh-searching-function) | 205 | (make-local-variable 'mh-searching-function) |
| 141 | (make-local-variable 'mh-help-messages) | 206 | (make-local-variable 'mh-help-messages) |
| 142 | (easy-menu-add mh-pick-menu) | 207 | (easy-menu-add mh-pick-menu) |
| 143 | (setq mh-help-messages mh-pick-mode-help-messages) | 208 | (setq mh-help-messages mh-pick-mode-help-messages)) |
| 144 | (run-hooks 'mh-pick-mode-hook)) | ||
| 145 | 209 | ||
| 146 | ;;;###mh-autoload | 210 | ;;;###mh-autoload |
| 147 | (defun mh-pick-do-search () | 211 | (defun mh-pick-do-search () |
diff --git a/lisp/mh-e/mh-print.el b/lisp/mh-e/mh-print.el index 9a7df0b8fd4..7539e455919 100644 --- a/lisp/mh-e/mh-print.el +++ b/lisp/mh-e/mh-print.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; mh-print.el --- MH-E printing support | 1 | ;;; mh-print.el --- MH-E printing support |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 2005 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 2003, 2004 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Jeffrey C Honig <jch@honig.net> | 5 | ;; Author: Jeffrey C Honig <jch@honig.net> |
| 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> | 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> |
diff --git a/lisp/mh-e/mh-seq.el b/lisp/mh-e/mh-seq.el index d09e9805682..e618e6f41b3 100644 --- a/lisp/mh-e/mh-seq.el +++ b/lisp/mh-e/mh-seq.el | |||
| @@ -1,6 +1,7 @@ | |||
| 1 | ;;; mh-seq.el --- MH-E sequences support | 1 | ;;; mh-seq.el --- MH-E sequences support |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1993, 1995, 2005 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 1993, 1995, |
| 4 | ;; 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. | ||
| 4 | 5 | ||
| 5 | ;; Author: Bill Wohler <wohler@newt.com> | 6 | ;; Author: Bill Wohler <wohler@newt.com> |
| 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> | 7 | ;; Maintainer: Bill Wohler <wohler@newt.com> |
| @@ -195,7 +196,7 @@ redone to get the new thread tree. This makes incremental threading easier.") | |||
| 195 | (insert "\n")) | 196 | (insert "\n")) |
| 196 | (setq seq-list (cdr seq-list))) | 197 | (setq seq-list (cdr seq-list))) |
| 197 | (goto-char (point-min)) | 198 | (goto-char (point-min)) |
| 198 | (view-mode 1) | 199 | (view-mode-enter) |
| 199 | (setq view-exit-action 'kill-buffer) | 200 | (setq view-exit-action 'kill-buffer) |
| 200 | (message "Listing sequences...done"))))) | 201 | (message "Listing sequences...done"))))) |
| 201 | 202 | ||
| @@ -788,10 +789,33 @@ This function can only be used the folder is threaded." | |||
| 788 | If no prefix arg is given, then return DEFAULT." | 789 | If no prefix arg is given, then return DEFAULT." |
| 789 | (let ((default-string (loop for x in default concat (format " %s" x)))) | 790 | (let ((default-string (loop for x in default concat (format " %s" x)))) |
| 790 | (if (or current-prefix-arg (equal default-string "")) | 791 | (if (or current-prefix-arg (equal default-string "")) |
| 791 | (delete "" (split-string (read-string "Pick expression: " | 792 | (mh-pick-args-list (read-string "Pick expression: " |
| 792 | default-string))) | 793 | default-string)) |
| 793 | default))) | 794 | default))) |
| 794 | 795 | ||
| 796 | (defun mh-pick-args-list (s) | ||
| 797 | "Form list by grouping elements in string S suitable for pick arguments. | ||
| 798 | For example, the string \"-subject a b c -from Joe User <user@domain.com>\" | ||
| 799 | is converted to (\"-subject\" \"a b c\" \"-from\" | ||
| 800 | \"Joe User <user@domain.com>\"" | ||
| 801 | (let ((full-list (split-string s)) | ||
| 802 | current-arg collection arg-list) | ||
| 803 | (while full-list | ||
| 804 | (setq current-arg (car full-list)) | ||
| 805 | (if (null (string-match "^-" current-arg)) | ||
| 806 | (setq collection | ||
| 807 | (if (null collection) | ||
| 808 | current-arg | ||
| 809 | (format "%s %s" collection current-arg))) | ||
| 810 | (when collection | ||
| 811 | (setq arg-list (append arg-list (list collection))) | ||
| 812 | (setq collection nil)) | ||
| 813 | (setq arg-list (append arg-list (list current-arg)))) | ||
| 814 | (setq full-list (cdr full-list))) | ||
| 815 | (when collection | ||
| 816 | (setq arg-list (append arg-list (list collection)))) | ||
| 817 | arg-list)) | ||
| 818 | |||
| 795 | ;;;###mh-autoload | 819 | ;;;###mh-autoload |
| 796 | (defun mh-narrow-to-subject (&optional pick-expr) | 820 | (defun mh-narrow-to-subject (&optional pick-expr) |
| 797 | "Limit to messages with same subject. | 821 | "Limit to messages with same subject. |
| @@ -1315,6 +1339,7 @@ All messages after START-POINT are added to the thread tree." | |||
| 1315 | (old-buffer-modified-flag (buffer-modified-p))) | 1339 | (old-buffer-modified-flag (buffer-modified-p))) |
| 1316 | (delete-region (point-min) (point-max)) | 1340 | (delete-region (point-min) (point-max)) |
| 1317 | (mh-thread-print-scan-lines thread-tree) | 1341 | (mh-thread-print-scan-lines thread-tree) |
| 1342 | (mh-notate-user-sequences) | ||
| 1318 | (mh-notate-deleted-and-refiled) | 1343 | (mh-notate-deleted-and-refiled) |
| 1319 | (mh-notate-cur) | 1344 | (mh-notate-cur) |
| 1320 | (set-buffer-modified-p old-buffer-modified-flag)))) | 1345 | (set-buffer-modified-p old-buffer-modified-flag)))) |
diff --git a/lisp/mh-e/mh-speed.el b/lisp/mh-e/mh-speed.el index a20e6e0a410..2617a941de1 100644 --- a/lisp/mh-e/mh-speed.el +++ b/lisp/mh-e/mh-speed.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; mh-speed.el --- Speedbar interface for MH-E. | 1 | ;;; mh-speed.el --- Speedbar interface for MH-E. |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 2005 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 2002, 2003, 2004 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Satyaki Das <satyaki@theforce.stanford.edu> | 5 | ;; Author: Satyaki Das <satyaki@theforce.stanford.edu> |
| 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> | 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> |
diff --git a/lisp/mh-e/mh-utils.el b/lisp/mh-e/mh-utils.el index a7ba9311403..d371087cc6d 100644 --- a/lisp/mh-e/mh-utils.el +++ b/lisp/mh-e/mh-utils.el | |||
| @@ -1,6 +1,7 @@ | |||
| 1 | ;;; mh-utils.el --- MH-E code needed for both sending and reading | 1 | ;;; mh-utils.el --- MH-E code needed for both sending and reading |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1993, 95, 1997, 2000, 01, 2005 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 1993, 1995, 1997, |
| 4 | ;; 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc. | ||
| 4 | 5 | ||
| 5 | ;; Author: Bill Wohler <wohler@newt.com> | 6 | ;; Author: Bill Wohler <wohler@newt.com> |
| 6 | ;; Maintainer: Bill Wohler <wohler@newt.com> | 7 | ;; Maintainer: Bill Wohler <wohler@newt.com> |
| @@ -703,8 +704,8 @@ not pointing to a message." | |||
| 703 | (save-excursion | 704 | (save-excursion |
| 704 | (beginning-of-line) | 705 | (beginning-of-line) |
| 705 | (cond ((looking-at mh-scan-msg-number-regexp) | 706 | (cond ((looking-at mh-scan-msg-number-regexp) |
| 706 | (string-to-int (buffer-substring (match-beginning 1) | 707 | (string-to-number (buffer-substring (match-beginning 1) |
| 707 | (match-end 1)))) | 708 | (match-end 1)))) |
| 708 | (error-if-no-message | 709 | (error-if-no-message |
| 709 | (error "Cursor not pointing to message")) | 710 | (error "Cursor not pointing to message")) |
| 710 | (t nil)))) | 711 | (t nil)))) |
| @@ -1129,8 +1130,7 @@ See also `mh-folder-mode'. | |||
| 1129 | (make-local-variable 'mh-show-folder-buffer) | 1130 | (make-local-variable 'mh-show-folder-buffer) |
| 1130 | (buffer-disable-undo) | 1131 | (buffer-disable-undo) |
| 1131 | (setq buffer-read-only t) | 1132 | (setq buffer-read-only t) |
| 1132 | (use-local-map mh-show-mode-map) | 1133 | (use-local-map mh-show-mode-map)) |
| 1133 | (run-hooks 'mh-show-mode-hook)) | ||
| 1134 | 1134 | ||
| 1135 | (defun mh-show-addr () | 1135 | (defun mh-show-addr () |
| 1136 | "Use `goto-address'." | 1136 | "Use `goto-address'." |
| @@ -1673,7 +1673,8 @@ The message is displayed in raw form." | |||
| 1673 | "Decode >From at beginning of lines for `mh-show-mode'." | 1673 | "Decode >From at beginning of lines for `mh-show-mode'." |
| 1674 | (save-excursion | 1674 | (save-excursion |
| 1675 | (let ((modified (buffer-modified-p)) | 1675 | (let ((modified (buffer-modified-p)) |
| 1676 | (case-fold-search nil)) | 1676 | (case-fold-search nil) |
| 1677 | (buffer-read-only nil)) | ||
| 1677 | (goto-char (mh-mail-header-end)) | 1678 | (goto-char (mh-mail-header-end)) |
| 1678 | (while (re-search-forward "^>From" nil t) | 1679 | (while (re-search-forward "^>From" nil t) |
| 1679 | (replace-match "From")) | 1680 | (replace-match "From")) |
diff --git a/lisp/net/eudc.el b/lisp/net/eudc.el index b279715329f..f234ab059d5 100644 --- a/lisp/net/eudc.el +++ b/lisp/net/eudc.el | |||
| @@ -670,8 +670,7 @@ These are the special commands of EUDC mode: | |||
| 670 | (if eudc-emacs-p | 670 | (if eudc-emacs-p |
| 671 | (easy-menu-define eudc-emacs-menu eudc-mode-map "" (eudc-menu)) | 671 | (easy-menu-define eudc-emacs-menu eudc-mode-map "" (eudc-menu)) |
| 672 | (setq mode-popup-menu (eudc-menu))) | 672 | (setq mode-popup-menu (eudc-menu))) |
| 673 | (run-hooks 'eudc-mode-hook) | 673 | (run-mode-hooks 'eudc-mode-hook)) |
| 674 | ) | ||
| 675 | 674 | ||
| 676 | ;;}}} | 675 | ;;}}} |
| 677 | 676 | ||
diff --git a/lisp/net/quickurl.el b/lisp/net/quickurl.el index ebf4dcd3618..d2ff0140dce 100644 --- a/lisp/net/quickurl.el +++ b/lisp/net/quickurl.el | |||
| @@ -458,7 +458,7 @@ The key bindings for `quickurl-list-mode' are: | |||
| 458 | (use-local-map quickurl-list-mode-map) | 458 | (use-local-map quickurl-list-mode-map) |
| 459 | (setq major-mode 'quickurl-list-mode | 459 | (setq major-mode 'quickurl-list-mode |
| 460 | mode-name "quickurl list") | 460 | mode-name "quickurl list") |
| 461 | (run-hooks 'quickurl-list-mode-hook) | 461 | (run-mode-hooks 'quickurl-list-mode-hook) |
| 462 | (setq buffer-read-only t | 462 | (setq buffer-read-only t |
| 463 | truncate-lines t)) | 463 | truncate-lines t)) |
| 464 | 464 | ||
diff --git a/lisp/net/snmp-mode.el b/lisp/net/snmp-mode.el index 73fef1452a0..f41dd845261 100644 --- a/lisp/net/snmp-mode.el +++ b/lisp/net/snmp-mode.el | |||
| @@ -393,8 +393,7 @@ Turning on snmp-mode runs the hooks in `snmp-common-mode-hook', then | |||
| 393 | (setq snmp-mode-status-list snmp-rfc1212-status) | 393 | (setq snmp-mode-status-list snmp-rfc1212-status) |
| 394 | 394 | ||
| 395 | ;; Run hooks | 395 | ;; Run hooks |
| 396 | (run-hooks 'snmp-common-mode-hook) | 396 | (run-mode-hooks 'snmp-common-mode-hook 'snmp-mode-hook)) |
| 397 | (run-hooks 'snmp-mode-hook)) | ||
| 398 | 397 | ||
| 399 | 398 | ||
| 400 | ;;;###autoload | 399 | ;;;###autoload |
| @@ -429,8 +428,7 @@ then `snmpv2-mode-hook'." | |||
| 429 | (setq snmp-mode-status-list snmp-rfc1902-status) | 428 | (setq snmp-mode-status-list snmp-rfc1902-status) |
| 430 | 429 | ||
| 431 | ;; Run hooks | 430 | ;; Run hooks |
| 432 | (run-hooks 'snmp-common-mode-hook) | 431 | (run-mode-hooks 'snmp-common-mode-hook 'snmpv2-mode-hook)) |
| 433 | (run-hooks 'snmpv2-mode-hook)) | ||
| 434 | 432 | ||
| 435 | 433 | ||
| 436 | ;;;---------------------------------------------------------------------------- | 434 | ;;;---------------------------------------------------------------------------- |
diff --git a/lisp/obsolete/ooutline.el b/lisp/obsolete/ooutline.el index 6b595b86297..0218d097b64 100644 --- a/lisp/obsolete/ooutline.el +++ b/lisp/obsolete/ooutline.el | |||
| @@ -224,7 +224,7 @@ Turning on outline mode calls the value of `text-mode-hook' and then of | |||
| 224 | (setq font-lock-defaults '(outline-font-lock-keywords t)) | 224 | (setq font-lock-defaults '(outline-font-lock-keywords t)) |
| 225 | (make-local-variable 'change-major-mode-hook) | 225 | (make-local-variable 'change-major-mode-hook) |
| 226 | (add-hook 'change-major-mode-hook 'show-all) | 226 | (add-hook 'change-major-mode-hook 'show-all) |
| 227 | (run-hooks 'text-mode-hook 'outline-mode-hook)) | 227 | (run-mode-hooks 'text-mode-hook 'outline-mode-hook)) |
| 228 | 228 | ||
| 229 | (defcustom outline-minor-mode-prefix "\C-c@" | 229 | (defcustom outline-minor-mode-prefix "\C-c@" |
| 230 | "*Prefix key to use for Outline commands in Outline minor mode. | 230 | "*Prefix key to use for Outline commands in Outline minor mode. |
diff --git a/lisp/obsolete/options.el b/lisp/obsolete/options.el index 34d7e532d1a..5ea14678d0b 100644 --- a/lisp/obsolete/options.el +++ b/lisp/obsolete/options.el | |||
| @@ -109,7 +109,7 @@ For convenience, the characters \\[backward-paragraph] and \\[forward-paragraph] | |||
| 109 | (setq truncate-lines t) | 109 | (setq truncate-lines t) |
| 110 | (setq major-mode 'Edit-options-mode) | 110 | (setq major-mode 'Edit-options-mode) |
| 111 | (setq mode-name "Options") | 111 | (setq mode-name "Options") |
| 112 | (run-hooks 'Edit-options-mode-hook)) | 112 | (run-mode-hooks 'Edit-options-mode-hook)) |
| 113 | 113 | ||
| 114 | (defun Edit-options-set () (interactive) | 114 | (defun Edit-options-set () (interactive) |
| 115 | (Edit-options-modify | 115 | (Edit-options-modify |
diff --git a/lisp/obsolete/rnews.el b/lisp/obsolete/rnews.el index cb2ed034ffc..7a546aa3081 100644 --- a/lisp/obsolete/rnews.el +++ b/lisp/obsolete/rnews.el | |||
| @@ -375,7 +375,7 @@ U unsubscribe from specified newsgroup." | |||
| 375 | (set-syntax-table text-mode-syntax-table) | 375 | (set-syntax-table text-mode-syntax-table) |
| 376 | (use-local-map news-mode-map) | 376 | (use-local-map news-mode-map) |
| 377 | (setq local-abbrev-table text-mode-abbrev-table) | 377 | (setq local-abbrev-table text-mode-abbrev-table) |
| 378 | (run-hooks 'news-mode-hook)) | 378 | (run-mode-hooks 'news-mode-hook)) |
| 379 | 379 | ||
| 380 | (defun string-subst-char (new old string) | 380 | (defun string-subst-char (new old string) |
| 381 | (let (index) | 381 | (let (index) |
diff --git a/lisp/obsolete/rnewspost.el b/lisp/obsolete/rnewspost.el index 1b7623f78ae..e1a378c6fb6 100644 --- a/lisp/obsolete/rnewspost.el +++ b/lisp/obsolete/rnewspost.el | |||
| @@ -130,7 +130,7 @@ C-c C-r caesar rotate all letters by 13 places in the article's body (rot13)." | |||
| 130 | (setq mode-name "News Reply") | 130 | (setq mode-name "News Reply") |
| 131 | (make-local-variable 'paragraph-separate) | 131 | (make-local-variable 'paragraph-separate) |
| 132 | (make-local-variable 'paragraph-start) | 132 | (make-local-variable 'paragraph-start) |
| 133 | (run-hooks 'text-mode-hook 'news-reply-mode-hook)) | 133 | (run-mode-hooks 'text-mode-hook 'news-reply-mode-hook)) |
| 134 | 134 | ||
| 135 | (defvar news-reply-yank-from "" | 135 | (defvar news-reply-yank-from "" |
| 136 | "Save `From:' field for `news-reply-yank-original'.") | 136 | "Save `From:' field for `news-reply-yank-original'.") |
diff --git a/lisp/outline.el b/lisp/outline.el index 89e9e193e9c..b807365f733 100644 --- a/lisp/outline.el +++ b/lisp/outline.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; outline.el --- outline mode commands for Emacs | 1 | ;;; outline.el --- outline mode commands for Emacs |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1986, 93, 94, 95, 97, 2000, 01, 2004 | 3 | ;; Copyright (C) 1986, 1993, 1994, 1995, 1997, 2000, 2001, 2004 |
| 4 | ;; Free Software Foundation, Inc. | 4 | ;; Free Software Foundation, Inc. |
| 5 | 5 | ||
| 6 | ;; Maintainer: FSF | 6 | ;; Maintainer: FSF |
| @@ -167,14 +167,45 @@ in the file it applies to." | |||
| 167 | 0 '(outline-font-lock-face) nil t))) | 167 | 0 '(outline-font-lock-face) nil t))) |
| 168 | "Additional expressions to highlight in Outline mode.") | 168 | "Additional expressions to highlight in Outline mode.") |
| 169 | 169 | ||
| 170 | (defface outline-1 '((t :inherit font-lock-function-name-face)) "Level 1.") | 170 | (defface outline-1 |
| 171 | (defface outline-2 '((t :inherit font-lock-variable-name-face)) "Level 2.") | 171 | '((t :inherit font-lock-function-name-face)) |
| 172 | (defface outline-3 '((t :inherit font-lock-keyword-face)) "Level 3.") | 172 | "Level 1." |
| 173 | (defface outline-4 '((t :inherit font-lock-builtin-face)) "Level 4.") | 173 | :group 'outlines) |
| 174 | (defface outline-5 '((t :inherit font-lock-comment-face)) "Level 5.") | 174 | |
| 175 | (defface outline-6 '((t :inherit font-lock-constant-face)) "Level 6.") | 175 | (defface outline-2 |
| 176 | (defface outline-7 '((t :inherit font-lock-type-face)) "Level 7.") | 176 | '((t :inherit font-lock-variable-name-face)) |
| 177 | (defface outline-8 '((t :inherit font-lock-string-face)) "Level 8.") | 177 | "Level 2." |
| 178 | :group 'outlines) | ||
| 179 | |||
| 180 | (defface outline-3 | ||
| 181 | '((t :inherit font-lock-keyword-face)) | ||
| 182 | "Level 3." | ||
| 183 | :group 'outlines) | ||
| 184 | |||
| 185 | (defface outline-4 | ||
| 186 | '((t :inherit font-lock-builtin-face)) | ||
| 187 | "Level 4." | ||
| 188 | :group 'outlines) | ||
| 189 | |||
| 190 | (defface outline-5 | ||
| 191 | '((t :inherit font-lock-comment-face)) | ||
| 192 | "Level 5." | ||
| 193 | :group 'outlines) | ||
| 194 | |||
| 195 | (defface outline-6 | ||
| 196 | '((t :inherit font-lock-constant-face)) | ||
| 197 | "Level 6." | ||
| 198 | :group 'outlines) | ||
| 199 | |||
| 200 | (defface outline-7 | ||
| 201 | '((t :inherit font-lock-type-face)) | ||
| 202 | "Level 7." | ||
| 203 | :group 'outlines) | ||
| 204 | |||
| 205 | (defface outline-8 | ||
| 206 | '((t :inherit font-lock-string-face)) | ||
| 207 | "Level 8." | ||
| 208 | :group 'outlines) | ||
| 178 | 209 | ||
| 179 | (defvar outline-font-lock-faces | 210 | (defvar outline-font-lock-faces |
| 180 | [outline-1 outline-2 outline-3 outline-4 | 211 | [outline-1 outline-2 outline-3 outline-4 |
diff --git a/lisp/play/5x5.el b/lisp/play/5x5.el index a7860244a8a..f012f132352 100644 --- a/lisp/play/5x5.el +++ b/lisp/play/5x5.el | |||
| @@ -178,10 +178,10 @@ The key bindings for 5x5-mode are: | |||
| 178 | (use-local-map 5x5-mode-map) | 178 | (use-local-map 5x5-mode-map) |
| 179 | (setq major-mode '5x5-mode | 179 | (setq major-mode '5x5-mode |
| 180 | mode-name "5x5") | 180 | mode-name "5x5") |
| 181 | (run-hooks '5x5-mode-hook) | 181 | (run-mode-hooks '5x5-mode-hook) |
| 182 | (setq buffer-read-only t | 182 | (setq buffer-read-only t |
| 183 | truncate-lines t) | 183 | truncate-lines t) |
| 184 | (buffer-disable-undo (current-buffer))) | 184 | (buffer-disable-undo)) |
| 185 | 185 | ||
| 186 | ;;;###autoload | 186 | ;;;###autoload |
| 187 | (defun 5x5 (&optional size) | 187 | (defun 5x5 (&optional size) |
diff --git a/lisp/play/decipher.el b/lisp/play/decipher.el index f314a10a9e2..9ef8d0fd01f 100644 --- a/lisp/play/decipher.el +++ b/lisp/play/decipher.el | |||
| @@ -314,7 +314,7 @@ The most useful commands are: | |||
| 314 | (lambda () (setq buffer-read-only nil | 314 | (lambda () (setq buffer-read-only nil |
| 315 | buffer-undo-list nil)) | 315 | buffer-undo-list nil)) |
| 316 | nil t) | 316 | nil t) |
| 317 | (run-hooks 'decipher-mode-hook) | 317 | (run-mode-hooks 'decipher-mode-hook) |
| 318 | (setq buffer-read-only t)) | 318 | (setq buffer-read-only t)) |
| 319 | (put 'decipher-mode 'mode-class 'special) | 319 | (put 'decipher-mode 'mode-class 'special) |
| 320 | 320 | ||
| @@ -998,7 +998,7 @@ Creates the statistics buffer if it doesn't exist." | |||
| 998 | major-mode 'decipher-stats-mode | 998 | major-mode 'decipher-stats-mode |
| 999 | mode-name "Decipher-Stats") | 999 | mode-name "Decipher-Stats") |
| 1000 | (use-local-map decipher-stats-mode-map) | 1000 | (use-local-map decipher-stats-mode-map) |
| 1001 | (run-hooks 'decipher-stats-mode-hook)) | 1001 | (run-mode-hooks 'decipher-stats-mode-hook)) |
| 1002 | (put 'decipher-stats-mode 'mode-class 'special) | 1002 | (put 'decipher-stats-mode 'mode-class 'special) |
| 1003 | 1003 | ||
| 1004 | ;;-------------------------------------------------------------------- | 1004 | ;;-------------------------------------------------------------------- |
diff --git a/lisp/play/gomoku.el b/lisp/play/gomoku.el index b640c1bbbd8..69ec07496d5 100644 --- a/lisp/play/gomoku.el +++ b/lisp/play/gomoku.el | |||
| @@ -206,7 +206,7 @@ is non-nil." | |||
| 206 | (make-local-variable 'font-lock-defaults) | 206 | (make-local-variable 'font-lock-defaults) |
| 207 | (setq font-lock-defaults '(gomoku-font-lock-keywords t)) | 207 | (setq font-lock-defaults '(gomoku-font-lock-keywords t)) |
| 208 | (toggle-read-only t) | 208 | (toggle-read-only t) |
| 209 | (run-hooks 'gomoku-mode-hook)) | 209 | (run-mode-hooks 'gomoku-mode-hook)) |
| 210 | 210 | ||
| 211 | ;;; | 211 | ;;; |
| 212 | ;;; THE BOARD. | 212 | ;;; THE BOARD. |
diff --git a/lisp/play/landmark.el b/lisp/play/landmark.el index 87ebd88fd58..3dc5e8ad320 100644 --- a/lisp/play/landmark.el +++ b/lisp/play/landmark.el | |||
| @@ -248,6 +248,7 @@ Other useful commands: | |||
| 248 | Entry to this mode calls the value of `lm-mode-hook' if that value | 248 | Entry to this mode calls the value of `lm-mode-hook' if that value |
| 249 | is non-nil. One interesting value is `turn-on-font-lock'." | 249 | is non-nil. One interesting value is `turn-on-font-lock'." |
| 250 | (interactive) | 250 | (interactive) |
| 251 | (kill-all-local-variables) | ||
| 251 | (setq major-mode 'lm-mode | 252 | (setq major-mode 'lm-mode |
| 252 | mode-name "Lm") | 253 | mode-name "Lm") |
| 253 | (lm-display-statistics) | 254 | (lm-display-statistics) |
| @@ -255,7 +256,7 @@ is non-nil. One interesting value is `turn-on-font-lock'." | |||
| 255 | (make-local-variable 'font-lock-defaults) | 256 | (make-local-variable 'font-lock-defaults) |
| 256 | (setq font-lock-defaults '(lm-font-lock-keywords t)) | 257 | (setq font-lock-defaults '(lm-font-lock-keywords t)) |
| 257 | (toggle-read-only t) | 258 | (toggle-read-only t) |
| 258 | (run-hooks 'lm-mode-hook)) | 259 | (run-mode-hooks 'lm-mode-hook)) |
| 259 | 260 | ||
| 260 | 261 | ||
| 261 | ;;;_ + THE SCORE TABLE. | 262 | ;;;_ + THE SCORE TABLE. |
diff --git a/lisp/play/mpuz.el b/lisp/play/mpuz.el index a637a2e98d1..849e87a28b0 100644 --- a/lisp/play/mpuz.el +++ b/lisp/play/mpuz.el | |||
| @@ -129,11 +129,12 @@ To leave the game to do other editing work, just switch buffers. | |||
| 129 | Then you may resume the game with M-x mpuz. | 129 | Then you may resume the game with M-x mpuz. |
| 130 | You may abort a game by typing \\<mpuz-mode-map>\\[mpuz-offer-abort]." | 130 | You may abort a game by typing \\<mpuz-mode-map>\\[mpuz-offer-abort]." |
| 131 | (interactive) | 131 | (interactive) |
| 132 | (kill-all-local-variables) | ||
| 132 | (setq major-mode 'mpuz-mode | 133 | (setq major-mode 'mpuz-mode |
| 133 | mode-name "Mult Puzzle" | 134 | mode-name "Mult Puzzle" |
| 134 | tab-width 30) | 135 | tab-width 30) |
| 135 | (use-local-map mpuz-mode-map) | 136 | (use-local-map mpuz-mode-map) |
| 136 | (run-hooks 'mpuz-mode-hook)) | 137 | (run-mode-hooks 'mpuz-mode-hook)) |
| 137 | 138 | ||
| 138 | 139 | ||
| 139 | ;; Some variables for statistics | 140 | ;; Some variables for statistics |
diff --git a/lisp/play/snake.el b/lisp/play/snake.el index 71c460feae5..e676d734755 100644 --- a/lisp/play/snake.el +++ b/lisp/play/snake.el | |||
| @@ -385,7 +385,7 @@ Snake mode keybindings: | |||
| 385 | 385 | ||
| 386 | (gamegrid-init (snake-display-options)) | 386 | (gamegrid-init (snake-display-options)) |
| 387 | 387 | ||
| 388 | (run-hooks 'snake-mode-hook)) | 388 | (run-mode-hooks 'snake-mode-hook)) |
| 389 | 389 | ||
| 390 | ;;;###autoload | 390 | ;;;###autoload |
| 391 | (defun snake () | 391 | (defun snake () |
diff --git a/lisp/play/solitaire.el b/lisp/play/solitaire.el index 1dc57b61c65..22dcea47599 100644 --- a/lisp/play/solitaire.el +++ b/lisp/play/solitaire.el | |||
| @@ -105,7 +105,7 @@ The usual mnemonic keys move the cursor around the board; in addition, | |||
| 105 | (setq truncate-lines t) | 105 | (setq truncate-lines t) |
| 106 | (setq major-mode 'solitaire-mode) | 106 | (setq major-mode 'solitaire-mode) |
| 107 | (setq mode-name "Solitaire") | 107 | (setq mode-name "Solitaire") |
| 108 | (run-hooks 'solitaire-mode-hook)) | 108 | (run-mode-hooks 'solitaire-mode-hook)) |
| 109 | 109 | ||
| 110 | (defvar solitaire-stones 0 | 110 | (defvar solitaire-stones 0 |
| 111 | "Counter for the stones that are still there.") | 111 | "Counter for the stones that are still there.") |
diff --git a/lisp/play/tetris.el b/lisp/play/tetris.el index 045534c2cea..5b8746bb1d7 100644 --- a/lisp/play/tetris.el +++ b/lisp/play/tetris.el | |||
| @@ -616,7 +616,7 @@ tetris-mode keybindings: | |||
| 616 | 616 | ||
| 617 | (gamegrid-init (tetris-display-options)) | 617 | (gamegrid-init (tetris-display-options)) |
| 618 | 618 | ||
| 619 | (run-hooks 'tetris-mode-hook)) | 619 | (run-mode-hooks 'tetris-mode-hook)) |
| 620 | 620 | ||
| 621 | ;;;###autoload | 621 | ;;;###autoload |
| 622 | (defun tetris () | 622 | (defun tetris () |
diff --git a/lisp/printing.el b/lisp/printing.el index b70c55b3f98..ddfe6fd5cc0 100644 --- a/lisp/printing.el +++ b/lisp/printing.el | |||
| @@ -5466,7 +5466,7 @@ non-nil." | |||
| 5466 | (str (pr-f-read-string (format fmt-prompt prompt mess) "1" nil "1")) | 5466 | (str (pr-f-read-string (format fmt-prompt prompt mess) "1" nil "1")) |
| 5467 | int) | 5467 | int) |
| 5468 | (while (if (string-match "^\\s *[0-9]+$" str) | 5468 | (while (if (string-match "^\\s *[0-9]+$" str) |
| 5469 | (setq int (string-to-int str) | 5469 | (setq int (string-to-number str) |
| 5470 | prompt (cond ((< int 1) "Integer below 1; ") | 5470 | prompt (cond ((< int 1) "Integer below 1; ") |
| 5471 | ((> int 100) "Integer above 100; ") | 5471 | ((> int 100) "Integer above 100; ") |
| 5472 | (t nil))) | 5472 | (t nil))) |
diff --git a/lisp/progmodes/ada-mode.el b/lisp/progmodes/ada-mode.el index d31978b5ec9..bc0edb1f047 100644 --- a/lisp/progmodes/ada-mode.el +++ b/lisp/progmodes/ada-mode.el | |||
| @@ -1369,7 +1369,7 @@ If you use ada-xref.el: | |||
| 1369 | (min ada-indent (current-column)))))) | 1369 | (min ada-indent (current-column)))))) |
| 1370 | (add-hook 'skeleton-end-hook 'ada-adjust-case-skeleton nil t) | 1370 | (add-hook 'skeleton-end-hook 'ada-adjust-case-skeleton nil t) |
| 1371 | 1371 | ||
| 1372 | (run-hooks 'ada-mode-hook) | 1372 | (run-mode-hooks 'ada-mode-hook) |
| 1373 | 1373 | ||
| 1374 | ;; To be run after the hook, in case the user modified | 1374 | ;; To be run after the hook, in case the user modified |
| 1375 | ;; ada-fill-comment-prefix | 1375 | ;; ada-fill-comment-prefix |
diff --git a/lisp/progmodes/antlr-mode.el b/lisp/progmodes/antlr-mode.el index 03587577f59..bdf376bfab7 100644 --- a/lisp/progmodes/antlr-mode.el +++ b/lisp/progmodes/antlr-mode.el | |||
| @@ -2624,7 +2624,7 @@ the default language." | |||
| 2624 | (imenu-add-to-menubar | 2624 | (imenu-add-to-menubar |
| 2625 | (if (stringp antlr-imenu-name) antlr-imenu-name "Index"))) | 2625 | (if (stringp antlr-imenu-name) antlr-imenu-name "Index"))) |
| 2626 | (antlr-set-tabs) | 2626 | (antlr-set-tabs) |
| 2627 | (run-hooks 'antlr-mode-hook)) | 2627 | (run-mode-hooks 'antlr-mode-hook)) |
| 2628 | 2628 | ||
| 2629 | ;; A smarter version of `group-buffers-menu-by-mode-then-alphabetically' (in | 2629 | ;; A smarter version of `group-buffers-menu-by-mode-then-alphabetically' (in |
| 2630 | ;; XEmacs) could use the following property. The header of the submenu would | 2630 | ;; XEmacs) could use the following property. The header of the submenu would |
diff --git a/lisp/progmodes/autoconf.el b/lisp/progmodes/autoconf.el index ec83e33b10d..908b18b070b 100644 --- a/lisp/progmodes/autoconf.el +++ b/lisp/progmodes/autoconf.el | |||
| @@ -103,7 +103,7 @@ searching backwards at another AC_... command." | |||
| 103 | (set (make-local-variable 'indent-line-function) #'indent-relative) | 103 | (set (make-local-variable 'indent-line-function) #'indent-relative) |
| 104 | (set (make-local-variable 'add-log-current-defun-function) | 104 | (set (make-local-variable 'add-log-current-defun-function) |
| 105 | #'autoconf-current-defun-function) | 105 | #'autoconf-current-defun-function) |
| 106 | (run-hooks 'autoconf-mode-hook)) | 106 | (run-mode-hooks 'autoconf-mode-hook)) |
| 107 | 107 | ||
| 108 | (provide 'autoconf-mode) | 108 | (provide 'autoconf-mode) |
| 109 | 109 | ||
diff --git a/lisp/progmodes/compile.el b/lisp/progmodes/compile.el index ad43228a100..a27a5282b42 100644 --- a/lisp/progmodes/compile.el +++ b/lisp/progmodes/compile.el | |||
| @@ -231,9 +231,9 @@ of[ \t]+\"?\\([a-zA-Z]?:?[^\":\n]+\\)\"?:" 3 2 nil (1)) | |||
| 231 | 231 | ||
| 232 | (makepp | 232 | (makepp |
| 233 | "^makepp: \\(?:\\(?:warning\\(:\\).*?\\|\\(Scanning\\|[LR]e?l?oading makefile\\) \\|.*?\\)\ | 233 | "^makepp: \\(?:\\(?:warning\\(:\\).*?\\|\\(Scanning\\|[LR]e?l?oading makefile\\) \\|.*?\\)\ |
| 234 | `\\(\\(\\S +?\\)\\(?::\\([0-9]+\\)\\)?\\)'\\)" | 234 | `\\(\\(\\S +?\\)\\(?::\\([0-9]+\\)\\)?\\)['(]\\)" |
| 235 | 4 5 nil (1 . 2) 3 | 235 | 4 5 nil (1 . 2) 3 |
| 236 | ("`\\(\\(\\S +?\\)\\(?::\\([0-9]+\\)\\)?\\)'" nil nil | 236 | ("`\\(\\(\\S +?\\)\\(?::\\([0-9]+\\)\\)?\\)['(]" nil nil |
| 237 | (2 compilation-info-face) | 237 | (2 compilation-info-face) |
| 238 | (3 compilation-line-face nil t) | 238 | (3 compilation-line-face nil t) |
| 239 | (1 (compilation-error-properties 2 3 nil nil nil 0 nil) | 239 | (1 (compilation-error-properties 2 3 nil nil nil 0 nil) |
| @@ -935,12 +935,20 @@ Returns the compilation buffer created." | |||
| 935 | (substitute-env-vars (match-string 1 command)) | 935 | (substitute-env-vars (match-string 1 command)) |
| 936 | "~") | 936 | "~") |
| 937 | default-directory)) | 937 | default-directory)) |
| 938 | ;; Select the desired mode. | ||
| 939 | (if (not (eq mode t)) | ||
| 940 | (funcall mode) | ||
| 941 | (setq buffer-read-only nil) | ||
| 942 | (with-no-warnings (comint-mode)) | ||
| 943 | (compilation-shell-minor-mode)) | ||
| 944 | (if highlight-regexp | ||
| 945 | (set (make-local-variable 'compilation-highlight-regexp) | ||
| 946 | highlight-regexp)) | ||
| 938 | (erase-buffer) | 947 | (erase-buffer) |
| 939 | ;; output a mode setter, for saving and later reloading this buffer | 948 | ;; Output a mode setter, for saving and later reloading this buffer. |
| 940 | (insert "-*- mode: " name-of-mode | 949 | (insert "-*- mode: " name-of-mode |
| 941 | "; default-directory: " (prin1-to-string default-directory) | 950 | "; default-directory: " (prin1-to-string default-directory) |
| 942 | " -*-\n" command "\n") | 951 | " -*-\n" command "\n") (setq thisdir default-directory)) |
| 943 | (setq thisdir default-directory)) | ||
| 944 | (set-buffer-modified-p nil)) | 952 | (set-buffer-modified-p nil)) |
| 945 | ;; If we're already in the compilation buffer, go to the end | 953 | ;; If we're already in the compilation buffer, go to the end |
| 946 | ;; of the buffer, so point will track the compilation output. | 954 | ;; of the buffer, so point will track the compilation output. |
| @@ -963,14 +971,6 @@ Returns the compilation buffer created." | |||
| 963 | ;; don't override users' setting of $EMACS. | 971 | ;; don't override users' setting of $EMACS. |
| 964 | (unless (getenv "EMACS") '("EMACS=t")) | 972 | (unless (getenv "EMACS") '("EMACS=t")) |
| 965 | (copy-sequence process-environment)))) | 973 | (copy-sequence process-environment)))) |
| 966 | (if (not (eq mode t)) | ||
| 967 | (funcall mode) | ||
| 968 | (setq buffer-read-only nil) | ||
| 969 | (with-no-warnings (comint-mode)) | ||
| 970 | (compilation-shell-minor-mode)) | ||
| 971 | (if highlight-regexp | ||
| 972 | (set (make-local-variable 'compilation-highlight-regexp) | ||
| 973 | highlight-regexp)) | ||
| 974 | (set (make-local-variable 'compilation-arguments) | 974 | (set (make-local-variable 'compilation-arguments) |
| 975 | (list command mode name-function highlight-regexp)) | 975 | (list command mode name-function highlight-regexp)) |
| 976 | (set (make-local-variable 'revert-buffer-function) | 976 | (set (make-local-variable 'revert-buffer-function) |
diff --git a/lisp/progmodes/dcl-mode.el b/lisp/progmodes/dcl-mode.el index b52e004e5bb..0a89091165c 100644 --- a/lisp/progmodes/dcl-mode.el +++ b/lisp/progmodes/dcl-mode.el | |||
| @@ -641,7 +641,7 @@ There is some minimal font-lock support (see vars | |||
| 641 | (setq mode-name "DCL") | 641 | (setq mode-name "DCL") |
| 642 | (use-local-map dcl-mode-map) | 642 | (use-local-map dcl-mode-map) |
| 643 | (tempo-use-tag-list 'dcl-tempo-tags) | 643 | (tempo-use-tag-list 'dcl-tempo-tags) |
| 644 | (run-hooks 'dcl-mode-hook)) | 644 | (run-mode-hooks 'dcl-mode-hook)) |
| 645 | 645 | ||
| 646 | 646 | ||
| 647 | ;;; *** Movement commands *************************************************** | 647 | ;;; *** Movement commands *************************************************** |
diff --git a/lisp/progmodes/delphi.el b/lisp/progmodes/delphi.el index 8d3ee554026..3d86f15c175 100644 --- a/lisp/progmodes/delphi.el +++ b/lisp/progmodes/delphi.el | |||
| @@ -2002,7 +2002,7 @@ no args, if that value is non-nil." | |||
| 2002 | (delphi-parse-region (point-min) (point-max)) | 2002 | (delphi-parse-region (point-min) (point-max)) |
| 2003 | (delphi-progress-done)))) | 2003 | (delphi-progress-done)))) |
| 2004 | 2004 | ||
| 2005 | (run-hooks 'delphi-mode-hook)) | 2005 | (run-mode-hooks 'delphi-mode-hook)) |
| 2006 | 2006 | ||
| 2007 | ;;; arch-tag: 410e192d-e9b5-4397-ad62-12340fc3fa41 | 2007 | ;;; arch-tag: 410e192d-e9b5-4397-ad62-12340fc3fa41 |
| 2008 | ;;; delphi.el ends here | 2008 | ;;; delphi.el ends here |
diff --git a/lisp/progmodes/ebrowse.el b/lisp/progmodes/ebrowse.el index 6dd15897e7b..953ecd79f7f 100644 --- a/lisp/progmodes/ebrowse.el +++ b/lisp/progmodes/ebrowse.el | |||
| @@ -1162,7 +1162,7 @@ Tree mode key bindings: | |||
| 1162 | (when tree | 1162 | (when tree |
| 1163 | (ebrowse-redraw-tree) | 1163 | (ebrowse-redraw-tree) |
| 1164 | (set-buffer-modified-p nil)) | 1164 | (set-buffer-modified-p nil)) |
| 1165 | (run-hooks 'ebrowse-tree-mode-hook))) | 1165 | (run-mode-hooks 'ebrowse-tree-mode-hook))) |
| 1166 | 1166 | ||
| 1167 | 1167 | ||
| 1168 | 1168 | ||
| @@ -2026,7 +2026,7 @@ COLLAPSE non-nil means collapse the branch." | |||
| 2026 | truncate-lines t | 2026 | truncate-lines t |
| 2027 | buffer-read-only t | 2027 | buffer-read-only t |
| 2028 | major-mode 'ebrowse-electric-list-mode) | 2028 | major-mode 'ebrowse-electric-list-mode) |
| 2029 | (run-hooks 'ebrowse-electric-list-mode-hook)) | 2029 | (run-mode-hooks 'ebrowse-electric-list-mode-hook)) |
| 2030 | 2030 | ||
| 2031 | 2031 | ||
| 2032 | (defun ebrowse-list-tree-buffers () | 2032 | (defun ebrowse-list-tree-buffers () |
| @@ -2277,7 +2277,7 @@ See 'Electric-command-loop' for a description of STATE and CONDITION." | |||
| 2277 | ebrowse--const-display-flag nil | 2277 | ebrowse--const-display-flag nil |
| 2278 | ebrowse--pure-display-flag nil) | 2278 | ebrowse--pure-display-flag nil) |
| 2279 | (modify-syntax-entry ?_ (char-to-string (char-syntax ?a))) | 2279 | (modify-syntax-entry ?_ (char-to-string (char-syntax ?a))) |
| 2280 | (run-hooks 'ebrowse-member-mode-hook)) | 2280 | (run-mode-hooks 'ebrowse-member-mode-hook)) |
| 2281 | 2281 | ||
| 2282 | 2282 | ||
| 2283 | 2283 | ||
| @@ -3987,7 +3987,7 @@ Runs the hook `ebrowse-electric-position-mode-hook'." | |||
| 3987 | truncate-lines t | 3987 | truncate-lines t |
| 3988 | buffer-read-only t | 3988 | buffer-read-only t |
| 3989 | major-mode 'ebrowse-electric-position-mode) | 3989 | major-mode 'ebrowse-electric-position-mode) |
| 3990 | (run-hooks 'ebrowse-electric-position-mode-hook)) | 3990 | (run-mode-hooks 'ebrowse-electric-position-mode-hook)) |
| 3991 | 3991 | ||
| 3992 | 3992 | ||
| 3993 | (defun ebrowse-draw-position-buffer () | 3993 | (defun ebrowse-draw-position-buffer () |
diff --git a/lisp/progmodes/f90.el b/lisp/progmodes/f90.el index eb6db05c159..6eb39051984 100644 --- a/lisp/progmodes/f90.el +++ b/lisp/progmodes/f90.el | |||
| @@ -830,7 +830,7 @@ with no args, if that value is non-nil." | |||
| 830 | (set (make-local-variable 'end-of-defun-function) 'f90-end-of-subprogram) | 830 | (set (make-local-variable 'end-of-defun-function) 'f90-end-of-subprogram) |
| 831 | (set (make-local-variable 'add-log-current-defun-function) | 831 | (set (make-local-variable 'add-log-current-defun-function) |
| 832 | #'f90-current-defun) | 832 | #'f90-current-defun) |
| 833 | (run-hooks 'f90-mode-hook)) | 833 | (run-mode-hooks 'f90-mode-hook)) |
| 834 | 834 | ||
| 835 | 835 | ||
| 836 | ;; Inline-functions. | 836 | ;; Inline-functions. |
diff --git a/lisp/progmodes/fortran.el b/lisp/progmodes/fortran.el index 30e1977d28d..458a4c8de2b 100644 --- a/lisp/progmodes/fortran.el +++ b/lisp/progmodes/fortran.el | |||
| @@ -799,7 +799,7 @@ with no args, if that value is non-nil." | |||
| 799 | #'fortran-current-defun) | 799 | #'fortran-current-defun) |
| 800 | (set (make-local-variable 'dabbrev-case-fold-search) 'case-fold-search) | 800 | (set (make-local-variable 'dabbrev-case-fold-search) 'case-fold-search) |
| 801 | (set (make-local-variable 'gud-find-expr-function) 'fortran-gud-find-expr) | 801 | (set (make-local-variable 'gud-find-expr-function) 'fortran-gud-find-expr) |
| 802 | (run-hooks 'fortran-mode-hook)) | 802 | (run-mode-hooks 'fortran-mode-hook)) |
| 803 | 803 | ||
| 804 | 804 | ||
| 805 | (defun fortran-gud-find-expr () | 805 | (defun fortran-gud-find-expr () |
diff --git a/lisp/progmodes/gdb-ui.el b/lisp/progmodes/gdb-ui.el index 1a26b64beca..7e2022cc11c 100644 --- a/lisp/progmodes/gdb-ui.el +++ b/lisp/progmodes/gdb-ui.el | |||
| @@ -66,15 +66,16 @@ | |||
| 66 | 66 | ||
| 67 | (require 'gud) | 67 | (require 'gud) |
| 68 | 68 | ||
| 69 | (defvar gdb-current-address "main" "Initialisation for Assembler buffer.") | 69 | (defvar gdb-frame-address "main" "Initialisation for Assembler buffer.") |
| 70 | (defvar gdb-previous-address nil) | 70 | (defvar gdb-previous-frame-address nil) |
| 71 | (defvar gdb-memory-address "main") | 71 | (defvar gdb-memory-address "main") |
| 72 | (defvar gdb-previous-frame nil) | 72 | (defvar gdb-previous-frame nil) |
| 73 | (defvar gdb-current-frame nil) | 73 | (defvar gdb-selected-frame nil) |
| 74 | (defvar gdb-current-stack-level nil) | 74 | (defvar gdb-frame-number nil) |
| 75 | (defvar gdb-current-language nil) | 75 | (defvar gdb-current-language nil) |
| 76 | (defvar gdb-var-list nil "List of variables in watch window.") | 76 | (defvar gdb-var-list nil "List of variables in watch window.") |
| 77 | (defvar gdb-var-changed nil "Non-nil means that gdb-var-list has changed.") | 77 | (defvar gdb-var-changed nil "Non-nil means that gdb-var-list has changed.") |
| 78 | (defvar gdb-main-file nil "Source file from which program execution begins.") | ||
| 78 | (defvar gdb-buffer-type nil) | 79 | (defvar gdb-buffer-type nil) |
| 79 | (defvar gdb-overlay-arrow-position nil) | 80 | (defvar gdb-overlay-arrow-position nil) |
| 80 | (defvar gdb-server-prefix nil) | 81 | (defvar gdb-server-prefix nil) |
| @@ -211,11 +212,18 @@ predefined macros." | |||
| 211 | :version "22.1") | 212 | :version "22.1") |
| 212 | 213 | ||
| 213 | (defcustom gdb-cpp-define-alist-flags "" | 214 | (defcustom gdb-cpp-define-alist-flags "" |
| 214 | "*Preprocessor flags for `gdb-cpp-define-alist-program'." | 215 | "Preprocessor flags for `gdb-cpp-define-alist-program'." |
| 215 | :type 'string | 216 | :type 'string |
| 216 | :group 'gud | 217 | :group 'gud |
| 217 | :version "22.1") | 218 | :version "22.1") |
| 218 | 219 | ||
| 220 | (defcustom gdb-show-main nil | ||
| 221 | "Non-nil means display source file containing the main routine at startup. | ||
| 222 | Also display the main routine in the disassembly buffer if present." | ||
| 223 | :type 'boolean | ||
| 224 | :group 'gud | ||
| 225 | :version "22.1") | ||
| 226 | |||
| 219 | (defvar gdb-define-alist nil "Alist of #define directives for GUD tooltips.") | 227 | (defvar gdb-define-alist nil "Alist of #define directives for GUD tooltips.") |
| 220 | 228 | ||
| 221 | (defun gdb-create-define-alist () | 229 | (defun gdb-create-define-alist () |
| @@ -269,7 +277,7 @@ predefined macros." | |||
| 269 | (defun gdb-set-gud-minor-mode-1 (buffer) | 277 | (defun gdb-set-gud-minor-mode-1 (buffer) |
| 270 | (goto-char (point-min)) | 278 | (goto-char (point-min)) |
| 271 | (when (and (search-forward "Located in " nil t) | 279 | (when (and (search-forward "Located in " nil t) |
| 272 | (looking-at "\\S-*") | 280 | (looking-at "\\S-+") |
| 273 | (string-equal (buffer-file-name buffer) | 281 | (string-equal (buffer-file-name buffer) |
| 274 | (match-string 0))) | 282 | (match-string 0))) |
| 275 | (with-current-buffer buffer | 283 | (with-current-buffer buffer |
| @@ -295,7 +303,7 @@ predefined macros." | |||
| 295 | (set (make-local-variable 'gud-minor-mode) 'gdba) | 303 | (set (make-local-variable 'gud-minor-mode) 'gdba) |
| 296 | (set (make-local-variable 'gud-marker-filter) 'gud-gdba-marker-filter) | 304 | (set (make-local-variable 'gud-marker-filter) 'gud-gdba-marker-filter) |
| 297 | ;; | 305 | ;; |
| 298 | (gud-def gud-break (if (not (string-equal mode-name "Machine")) | 306 | (gud-def gud-break (if (not (string-match "Machine" mode-name)) |
| 299 | (gud-call "break %f:%l" arg) | 307 | (gud-call "break %f:%l" arg) |
| 300 | (save-excursion | 308 | (save-excursion |
| 301 | (beginning-of-line) | 309 | (beginning-of-line) |
| @@ -303,7 +311,7 @@ predefined macros." | |||
| 303 | (gud-call "break *%a" arg))) | 311 | (gud-call "break *%a" arg))) |
| 304 | "\C-b" "Set breakpoint at current line or address.") | 312 | "\C-b" "Set breakpoint at current line or address.") |
| 305 | ;; | 313 | ;; |
| 306 | (gud-def gud-remove (if (not (string-equal mode-name "Machine")) | 314 | (gud-def gud-remove (if (not (string-match "Machine" mode-name)) |
| 307 | (gud-call "clear %f:%l" arg) | 315 | (gud-call "clear %f:%l" arg) |
| 308 | (save-excursion | 316 | (save-excursion |
| 309 | (beginning-of-line) | 317 | (beginning-of-line) |
| @@ -311,7 +319,7 @@ predefined macros." | |||
| 311 | (gud-call "clear *%a" arg))) | 319 | (gud-call "clear *%a" arg))) |
| 312 | "\C-d" "Remove breakpoint at current line or address.") | 320 | "\C-d" "Remove breakpoint at current line or address.") |
| 313 | ;; | 321 | ;; |
| 314 | (gud-def gud-until (if (not (string-equal mode-name "Machine")) | 322 | (gud-def gud-until (if (not (string-match "Machine" mode-name)) |
| 315 | (gud-call "until %f:%l" arg) | 323 | (gud-call "until %f:%l" arg) |
| 316 | (save-excursion | 324 | (save-excursion |
| 317 | (beginning-of-line) | 325 | (beginning-of-line) |
| @@ -332,25 +340,26 @@ predefined macros." | |||
| 332 | (setq comint-input-sender 'gdb-send) | 340 | (setq comint-input-sender 'gdb-send) |
| 333 | ;; | 341 | ;; |
| 334 | ;; (re-)initialize | 342 | ;; (re-)initialize |
| 335 | (setq gdb-current-address "main") | 343 | (setq gdb-frame-address (if gdb-show-main "main" nil)) |
| 336 | (setq gdb-previous-address nil) | 344 | (setq gdb-previous-frame-address nil |
| 337 | (setq gdb-memory-address "main") | 345 | gdb-memory-address "main" |
| 338 | (setq gdb-previous-frame nil) | 346 | gdb-previous-frame nil |
| 339 | (setq gdb-current-frame nil) | 347 | gdb-selected-frame nil |
| 340 | (setq gdb-current-stack-level nil) | 348 | gdb-current-language nil |
| 341 | (setq gdb-var-list nil) | 349 | gdb-frame-number nil |
| 342 | (setq gdb-var-changed nil) | 350 | gdb-var-list nil |
| 343 | (setq gdb-first-prompt nil) | 351 | gdb-var-changed nil |
| 344 | (setq gdb-prompting nil) | 352 | gdb-first-prompt nil |
| 345 | (setq gdb-input-queue nil) | 353 | gdb-prompting nil |
| 346 | (setq gdb-current-item nil) | 354 | gdb-input-queue nil |
| 347 | (setq gdb-pending-triggers nil) | 355 | gdb-current-item nil |
| 348 | (setq gdb-output-sink 'user) | 356 | gdb-pending-triggers nil |
| 349 | (setq gdb-server-prefix "server ") | 357 | gdb-output-sink 'user |
| 350 | (setq gdb-flush-pending-output nil) | 358 | gdb-server-prefix "server " |
| 351 | (setq gdb-location-alist nil) | 359 | gdb-flush-pending-output nil |
| 352 | (setq gdb-find-file-unhook nil) | 360 | gdb-location-alist nil |
| 353 | (setq gdb-macro-info nil) | 361 | gdb-find-file-unhook nil |
| 362 | gdb-macro-info nil) | ||
| 354 | ;; | 363 | ;; |
| 355 | (setq gdb-buffer-type 'gdba) | 364 | (setq gdb-buffer-type 'gdba) |
| 356 | ;; | 365 | ;; |
| @@ -380,8 +389,8 @@ predefined macros." | |||
| 380 | (require 'tooltip) | 389 | (require 'tooltip) |
| 381 | (let ((expr (tooltip-identifier-from-point (point)))) | 390 | (let ((expr (tooltip-identifier-from-point (point)))) |
| 382 | (if (and (string-equal gdb-current-language "c") | 391 | (if (and (string-equal gdb-current-language "c") |
| 383 | gdb-use-colon-colon-notation gdb-current-frame) | 392 | gdb-use-colon-colon-notation gdb-selected-frame) |
| 384 | (setq expr (concat gdb-current-frame "::" expr))) | 393 | (setq expr (concat gdb-selected-frame "::" expr))) |
| 385 | (catch 'already-watched | 394 | (catch 'already-watched |
| 386 | (dolist (var gdb-var-list) | 395 | (dolist (var gdb-var-list) |
| 387 | (if (string-equal expr (car var)) (throw 'already-watched nil))) | 396 | (if (string-equal expr (car var)) (throw 'already-watched nil))) |
| @@ -862,7 +871,7 @@ This filter may simply queue input for a later time." | |||
| 862 | (setq gdb-prompting t)) | 871 | (setq gdb-prompting t)) |
| 863 | 872 | ||
| 864 | (defconst gdb-source-spec-regexp | 873 | (defconst gdb-source-spec-regexp |
| 865 | "\\(.*\\):\\([0-9]*\\):[0-9]*:[a-z]*:\\(0x[a-f0-9]*\\)") | 874 | "\\(.*\\):\\([0-9]*\\):[0-9]*:[a-z]*:0x0*\\([a-f0-9]*\\)") |
| 866 | 875 | ||
| 867 | ;; Do not use this except as an annotation handler. | 876 | ;; Do not use this except as an annotation handler. |
| 868 | (defun gdb-source (args) | 877 | (defun gdb-source (args) |
| @@ -872,7 +881,7 @@ This filter may simply queue input for a later time." | |||
| 872 | (cons | 881 | (cons |
| 873 | (match-string 1 args) | 882 | (match-string 1 args) |
| 874 | (string-to-number (match-string 2 args)))) | 883 | (string-to-number (match-string 2 args)))) |
| 875 | (setq gdb-current-address (match-string 3 args)) | 884 | (setq gdb-frame-address (match-string 3 args)) |
| 876 | ;; cover for auto-display output which comes *before* | 885 | ;; cover for auto-display output which comes *before* |
| 877 | ;; stopped annotation | 886 | ;; stopped annotation |
| 878 | (if (eq gdb-output-sink 'inferior) (setq gdb-output-sink 'user))) | 887 | (if (eq gdb-output-sink 'inferior) (setq gdb-output-sink 'user))) |
| @@ -985,10 +994,12 @@ sink to `user' in `gdb-stopping', that is fine." | |||
| 985 | This begins the collection of output from the current command if that | 994 | This begins the collection of output from the current command if that |
| 986 | happens to be appropriate." | 995 | happens to be appropriate." |
| 987 | (unless gdb-pending-triggers | 996 | (unless gdb-pending-triggers |
| 988 | (gdb-get-current-frame) | 997 | (gdb-get-selected-frame) |
| 989 | (gdb-invalidate-frames) | 998 | (gdb-invalidate-frames) |
| 990 | (gdb-invalidate-breakpoints) | 999 | (gdb-invalidate-breakpoints) |
| 991 | (gdb-invalidate-assembler) | 1000 | ;; Do this through gdb-get-selected-frame -> gdb-frame-handler |
| 1001 | ;; so gdb-frame-address is updated. | ||
| 1002 | ;; (gdb-invalidate-assembler) | ||
| 992 | (gdb-invalidate-registers) | 1003 | (gdb-invalidate-registers) |
| 993 | (gdb-invalidate-memory) | 1004 | (gdb-invalidate-memory) |
| 994 | (gdb-invalidate-locals) | 1005 | (gdb-invalidate-locals) |
| @@ -1150,12 +1161,12 @@ happens to be appropriate." | |||
| 1150 | (let ((buf (gdb-get-buffer ',buf-key))) | 1161 | (let ((buf (gdb-get-buffer ',buf-key))) |
| 1151 | (and buf | 1162 | (and buf |
| 1152 | (with-current-buffer buf | 1163 | (with-current-buffer buf |
| 1153 | (let ((p (point)) | 1164 | (let ((p (window-point (get-buffer-window buf 0))) |
| 1154 | (buffer-read-only nil)) | 1165 | (buffer-read-only nil)) |
| 1155 | (erase-buffer) | 1166 | (erase-buffer) |
| 1156 | (insert-buffer-substring (gdb-get-create-buffer | 1167 | (insert-buffer-substring (gdb-get-create-buffer |
| 1157 | 'gdb-partial-output-buffer)) | 1168 | 'gdb-partial-output-buffer)) |
| 1158 | (goto-char p))))) | 1169 | (set-window-point (get-buffer-window buf 0) p))))) |
| 1159 | ;; put customisation here | 1170 | ;; put customisation here |
| 1160 | (,custom-defun))) | 1171 | (,custom-defun))) |
| 1161 | 1172 | ||
| @@ -1293,7 +1304,7 @@ static char *magick[] = { | |||
| 1293 | (goto-char (point-min)) | 1304 | (goto-char (point-min)) |
| 1294 | (while (< (point) (- (point-max) 1)) | 1305 | (while (< (point) (- (point-max) 1)) |
| 1295 | (forward-line 1) | 1306 | (forward-line 1) |
| 1296 | (if (looking-at "[^\t].*breakpoint") | 1307 | (if (looking-at "[^\t].*?breakpoint") |
| 1297 | (progn | 1308 | (progn |
| 1298 | (looking-at "\\([0-9]+\\)\\s-+\\S-+\\s-+\\S-+\\s-+\\(.\\)") | 1309 | (looking-at "\\([0-9]+\\)\\s-+\\S-+\\s-+\\S-+\\s-+\\(.\\)") |
| 1299 | (setq bptno (match-string 1)) | 1310 | (setq bptno (match-string 1)) |
| @@ -1435,9 +1446,9 @@ static char *magick[] = { | |||
| 1435 | (save-excursion | 1446 | (save-excursion |
| 1436 | (beginning-of-line 1) | 1447 | (beginning-of-line 1) |
| 1437 | (if (if (with-current-buffer gud-comint-buffer (eq gud-minor-mode 'gdba)) | 1448 | (if (if (with-current-buffer gud-comint-buffer (eq gud-minor-mode 'gdba)) |
| 1438 | (looking-at "\\([0-9]+\\).*point\\s-*\\S-*\\s-*\\(.\\)") | 1449 | (looking-at "\\([0-9]+\\).*?point\\s-+\\S-+\\s-+\\(.\\)\\s-+") |
| 1439 | (looking-at | 1450 | (looking-at |
| 1440 | "\\([0-9]+\\)\\s-*\\S-*\\s-*\\S-*\\s-*\\(.\\)\\s-*\\S-*\\s-*\\S-*:[0-9]+")) | 1451 | "\\([0-9]+\\)\\s-+\\S-+\\s-+\\S-+\\s-+\\(.\\)\\s-+\\S-+\\s-+\\S-+:[0-9]+")) |
| 1441 | (gdb-enqueue-input | 1452 | (gdb-enqueue-input |
| 1442 | (list | 1453 | (list |
| 1443 | (concat gdb-server-prefix | 1454 | (concat gdb-server-prefix |
| @@ -1452,9 +1463,9 @@ static char *magick[] = { | |||
| 1452 | (interactive) | 1463 | (interactive) |
| 1453 | (beginning-of-line 1) | 1464 | (beginning-of-line 1) |
| 1454 | (if (if (with-current-buffer gud-comint-buffer (eq gud-minor-mode 'gdba)) | 1465 | (if (if (with-current-buffer gud-comint-buffer (eq gud-minor-mode 'gdba)) |
| 1455 | (looking-at "\\([0-9]+\\).*point\\s-*\\S-*\\s-*\\(.\\)") | 1466 | (looking-at "\\([0-9]+\\).*?point\\s-+\\S-+\\s-+\\(.\\)") |
| 1456 | (looking-at | 1467 | (looking-at |
| 1457 | "\\([0-9]+\\)\\s-*\\S-*\\s-*\\S-*\\s-*.\\s-*\\S-*\\s-*\\S-*:[0-9]+")) | 1468 | "\\([0-9]+\\)\\s-+\\S-+\\s-+\\S-+\\s-+\\s-+\\S-+\\s-+\\S-+:[0-9]+")) |
| 1458 | (gdb-enqueue-input | 1469 | (gdb-enqueue-input |
| 1459 | (list | 1470 | (list |
| 1460 | (concat gdb-server-prefix "delete " (match-string 1) "\n") 'ignore)) | 1471 | (concat gdb-server-prefix "delete " (match-string 1) "\n") 'ignore)) |
| @@ -1467,10 +1478,10 @@ static char *magick[] = { | |||
| 1467 | (save-excursion | 1478 | (save-excursion |
| 1468 | (beginning-of-line 1) | 1479 | (beginning-of-line 1) |
| 1469 | (if (if (with-current-buffer gud-comint-buffer (eq gud-minor-mode 'gdba)) | 1480 | (if (if (with-current-buffer gud-comint-buffer (eq gud-minor-mode 'gdba)) |
| 1470 | (looking-at "\\([0-9]+\\) .* in .* at\\s-+\\(\\S-*\\):\\([0-9]+\\)") | 1481 | (looking-at "\\([0-9]+\\) .+ in .+ at\\s-+\\(\\S-+\\):\\([0-9]+\\)") |
| 1471 | (looking-at | 1482 | (looking-at |
| 1472 | "\\([0-9]+\\)\\s-*\\S-*\\s-*\\S-*\\s-*.\\s-*\\S-*\\s-*\ | 1483 | "\\([0-9]+\\)\\s-+\\S-+\\s-+\\S-+\\s-+.\\s-+\\S-+\\s-+\ |
| 1473 | \\(\\S-*\\):\\([0-9]+\\)")) | 1484 | \\(\\S-+\\):\\([0-9]+\\)")) |
| 1474 | (let ((bptno (match-string 1)) | 1485 | (let ((bptno (match-string 1)) |
| 1475 | (file (match-string 2)) | 1486 | (file (match-string 2)) |
| 1476 | (line (match-string 3))) | 1487 | (line (match-string 3))) |
| @@ -1511,7 +1522,7 @@ static char *magick[] = { | |||
| 1511 | help-echo "mouse-2, RET: Select frame")) | 1522 | help-echo "mouse-2, RET: Select frame")) |
| 1512 | (beginning-of-line) | 1523 | (beginning-of-line) |
| 1513 | (when (and (looking-at "^#\\([0-9]+\\)") | 1524 | (when (and (looking-at "^#\\([0-9]+\\)") |
| 1514 | (equal (match-string 1) gdb-current-stack-level)) | 1525 | (equal (match-string 1) gdb-frame-number)) |
| 1515 | (put-text-property (line-beginning-position) (line-end-position) | 1526 | (put-text-property (line-beginning-position) (line-end-position) |
| 1516 | 'face '(:inverse-video t))) | 1527 | 'face '(:inverse-video t))) |
| 1517 | (forward-line 1)))))) | 1528 | (forward-line 1)))))) |
| @@ -1648,13 +1659,20 @@ static char *magick[] = { | |||
| 1648 | 1659 | ||
| 1649 | ;; Registers buffer. | 1660 | ;; Registers buffer. |
| 1650 | ;; | 1661 | ;; |
| 1662 | (defcustom gdb-all-registers nil | ||
| 1663 | "Non-nil means include floating-point registers." | ||
| 1664 | :type 'boolean | ||
| 1665 | :group 'gud | ||
| 1666 | :version "22.1") | ||
| 1667 | |||
| 1651 | (gdb-set-buffer-rules 'gdb-registers-buffer | 1668 | (gdb-set-buffer-rules 'gdb-registers-buffer |
| 1652 | 'gdb-registers-buffer-name | 1669 | 'gdb-registers-buffer-name |
| 1653 | 'gdb-registers-mode) | 1670 | 'gdb-registers-mode) |
| 1654 | 1671 | ||
| 1655 | (def-gdb-auto-updated-buffer gdb-registers-buffer | 1672 | (def-gdb-auto-updated-buffer gdb-registers-buffer |
| 1656 | gdb-invalidate-registers | 1673 | gdb-invalidate-registers |
| 1657 | (concat gdb-server-prefix "info registers\n") | 1674 | (concat |
| 1675 | gdb-server-prefix "info " (if gdb-all-registers "all-") "registers\n") | ||
| 1658 | gdb-info-registers-handler | 1676 | gdb-info-registers-handler |
| 1659 | gdb-info-registers-custom) | 1677 | gdb-info-registers-custom) |
| 1660 | 1678 | ||
| @@ -1663,6 +1681,7 @@ static char *magick[] = { | |||
| 1663 | (defvar gdb-registers-mode-map | 1681 | (defvar gdb-registers-mode-map |
| 1664 | (let ((map (make-sparse-keymap))) | 1682 | (let ((map (make-sparse-keymap))) |
| 1665 | (suppress-keymap map) | 1683 | (suppress-keymap map) |
| 1684 | (define-key map " " 'toggle-gdb-all-registers) | ||
| 1666 | (define-key map "q" 'kill-this-buffer) | 1685 | (define-key map "q" 'kill-this-buffer) |
| 1667 | map)) | 1686 | map)) |
| 1668 | 1687 | ||
| @@ -1672,7 +1691,7 @@ static char *magick[] = { | |||
| 1672 | \\{gdb-registers-mode-map}" | 1691 | \\{gdb-registers-mode-map}" |
| 1673 | (kill-all-local-variables) | 1692 | (kill-all-local-variables) |
| 1674 | (setq major-mode 'gdb-registers-mode) | 1693 | (setq major-mode 'gdb-registers-mode) |
| 1675 | (setq mode-name "Registers") | 1694 | (setq mode-name "Registers:") |
| 1676 | (setq buffer-read-only t) | 1695 | (setq buffer-read-only t) |
| 1677 | (use-local-map gdb-registers-mode-map) | 1696 | (use-local-map gdb-registers-mode-map) |
| 1678 | (run-mode-hooks 'gdb-registers-mode-hook) | 1697 | (run-mode-hooks 'gdb-registers-mode-hook) |
| @@ -1695,6 +1714,20 @@ static char *magick[] = { | |||
| 1695 | (special-display-frame-alist gdb-frame-parameters)) | 1714 | (special-display-frame-alist gdb-frame-parameters)) |
| 1696 | (display-buffer (gdb-get-create-buffer 'gdb-registers-buffer)))) | 1715 | (display-buffer (gdb-get-create-buffer 'gdb-registers-buffer)))) |
| 1697 | 1716 | ||
| 1717 | (defun toggle-gdb-all-registers () | ||
| 1718 | "Toggle the display of floating-point registers." | ||
| 1719 | (interactive) | ||
| 1720 | (if gdb-all-registers | ||
| 1721 | (progn | ||
| 1722 | (setq gdb-all-registers nil) | ||
| 1723 | (with-current-buffer (gdb-get-buffer 'gdb-registers-buffer) | ||
| 1724 | (setq mode-name "Registers:"))) | ||
| 1725 | (setq gdb-all-registers t) | ||
| 1726 | (with-current-buffer (gdb-get-buffer 'gdb-registers-buffer) | ||
| 1727 | (setq mode-name "Registers:All"))) | ||
| 1728 | (gdb-invalidate-registers)) | ||
| 1729 | |||
| 1730 | |||
| 1698 | ;; Memory buffer. | 1731 | ;; Memory buffer. |
| 1699 | ;; | 1732 | ;; |
| 1700 | (defcustom gdb-memory-repeat-count 32 | 1733 | (defcustom gdb-memory-repeat-count 32 |
| @@ -1733,7 +1766,11 @@ static char *magick[] = { | |||
| 1733 | gdb-read-memory-handler | 1766 | gdb-read-memory-handler |
| 1734 | gdb-read-memory-custom) | 1767 | gdb-read-memory-custom) |
| 1735 | 1768 | ||
| 1736 | (defun gdb-read-memory-custom ()) | 1769 | (defun gdb-read-memory-custom () |
| 1770 | (save-excursion | ||
| 1771 | (goto-char (point-min)) | ||
| 1772 | (if (looking-at "0x[[:xdigit:]]+") | ||
| 1773 | (setq gdb-memory-address (match-string 0))))) | ||
| 1737 | 1774 | ||
| 1738 | (defvar gdb-memory-mode-map | 1775 | (defvar gdb-memory-mode-map |
| 1739 | (let ((map (make-sparse-keymap))) | 1776 | (let ((map (make-sparse-keymap))) |
| @@ -1757,8 +1794,8 @@ static char *magick[] = { | |||
| 1757 | (select-window (posn-window (event-start event))) | 1794 | (select-window (posn-window (event-start event))) |
| 1758 | (let* ((arg (read-from-minibuffer "Repeat count: ")) | 1795 | (let* ((arg (read-from-minibuffer "Repeat count: ")) |
| 1759 | (count (string-to-number arg))) | 1796 | (count (string-to-number arg))) |
| 1760 | (if (< count 0) | 1797 | (if (<= count 0) |
| 1761 | (error "Non-negative numbers only") | 1798 | (error "Positive numbers only") |
| 1762 | (customize-set-variable 'gdb-memory-repeat-count count) | 1799 | (customize-set-variable 'gdb-memory-repeat-count count) |
| 1763 | (gdb-invalidate-memory))))) | 1800 | (gdb-invalidate-memory))))) |
| 1764 | 1801 | ||
| @@ -1911,10 +1948,42 @@ corresponding to the mode line clicked." | |||
| 1911 | (setq header-line-format | 1948 | (setq header-line-format |
| 1912 | '(:eval | 1949 | '(:eval |
| 1913 | (concat | 1950 | (concat |
| 1914 | "Read address: " | 1951 | "Read address[" |
| 1952 | (propertize | ||
| 1953 | "-" | ||
| 1954 | 'face font-lock-warning-face | ||
| 1955 | 'help-echo "mouse-1: Decrement address" | ||
| 1956 | 'mouse-face 'mode-line-highlight | ||
| 1957 | 'local-map | ||
| 1958 | (gdb-make-header-line-mouse-map | ||
| 1959 | 'mouse-1 | ||
| 1960 | #'(lambda () (interactive) | ||
| 1961 | (let ((gdb-memory-address | ||
| 1962 | ;; let GDB do the arithmetic | ||
| 1963 | (concat | ||
| 1964 | gdb-memory-address " - " | ||
| 1965 | (number-to-string | ||
| 1966 | (* gdb-memory-repeat-count | ||
| 1967 | (cond ((string= gdb-memory-unit "b") 1) | ||
| 1968 | ((string= gdb-memory-unit "h") 2) | ||
| 1969 | ((string= gdb-memory-unit "w") 4) | ||
| 1970 | ((string= gdb-memory-unit "g") 8))))))) | ||
| 1971 | (gdb-invalidate-memory))))) | ||
| 1972 | "|" | ||
| 1973 | (propertize "+" | ||
| 1974 | 'face font-lock-warning-face | ||
| 1975 | 'help-echo "mouse-1: Increment address" | ||
| 1976 | 'mouse-face 'mode-line-highlight | ||
| 1977 | 'local-map (gdb-make-header-line-mouse-map | ||
| 1978 | 'mouse-1 | ||
| 1979 | #'(lambda () (interactive) | ||
| 1980 | (let ((gdb-memory-address nil)) | ||
| 1981 | (gdb-invalidate-memory))))) | ||
| 1982 | "]: " | ||
| 1915 | (propertize gdb-memory-address | 1983 | (propertize gdb-memory-address |
| 1916 | 'face font-lock-warning-face | 1984 | 'face font-lock-warning-face |
| 1917 | 'help-echo "mouse-1: Set memory address" | 1985 | 'help-echo "mouse-1: Set memory address" |
| 1986 | 'mouse-face 'mode-line-highlight | ||
| 1918 | 'local-map (gdb-make-header-line-mouse-map | 1987 | 'local-map (gdb-make-header-line-mouse-map |
| 1919 | 'mouse-1 | 1988 | 'mouse-1 |
| 1920 | #'gdb-memory-set-address)) | 1989 | #'gdb-memory-set-address)) |
| @@ -1922,6 +1991,7 @@ corresponding to the mode line clicked." | |||
| 1922 | (propertize (number-to-string gdb-memory-repeat-count) | 1991 | (propertize (number-to-string gdb-memory-repeat-count) |
| 1923 | 'face font-lock-warning-face | 1992 | 'face font-lock-warning-face |
| 1924 | 'help-echo "mouse-1: Set repeat count" | 1993 | 'help-echo "mouse-1: Set repeat count" |
| 1994 | 'mouse-face 'mode-line-highlight | ||
| 1925 | 'local-map (gdb-make-header-line-mouse-map | 1995 | 'local-map (gdb-make-header-line-mouse-map |
| 1926 | 'mouse-1 | 1996 | 'mouse-1 |
| 1927 | #'gdb-memory-set-repeat-count)) | 1997 | #'gdb-memory-set-repeat-count)) |
| @@ -1929,11 +1999,13 @@ corresponding to the mode line clicked." | |||
| 1929 | (propertize gdb-memory-format | 1999 | (propertize gdb-memory-format |
| 1930 | 'face font-lock-warning-face | 2000 | 'face font-lock-warning-face |
| 1931 | 'help-echo "mouse-3: Select display format" | 2001 | 'help-echo "mouse-3: Select display format" |
| 2002 | 'mouse-face 'mode-line-highlight | ||
| 1932 | 'local-map gdb-memory-format-keymap) | 2003 | 'local-map gdb-memory-format-keymap) |
| 1933 | " Unit Size: " | 2004 | " Unit Size: " |
| 1934 | (propertize gdb-memory-unit | 2005 | (propertize gdb-memory-unit |
| 1935 | 'face font-lock-warning-face | 2006 | 'face font-lock-warning-face |
| 1936 | 'help-echo "mouse-3: Select unit size" | 2007 | 'help-echo "mouse-3: Select unit size" |
| 2008 | 'mouse-face 'mode-line-highlight | ||
| 1937 | 'local-map gdb-memory-unit-keymap)))) | 2009 | 'local-map gdb-memory-unit-keymap)))) |
| 1938 | (run-mode-hooks 'gdb-memory-mode-hook) | 2010 | (run-mode-hooks 'gdb-memory-mode-hook) |
| 1939 | 'gdb-invalidate-memory) | 2011 | 'gdb-invalidate-memory) |
| @@ -1986,12 +2058,12 @@ corresponding to the mode line clicked." | |||
| 1986 | (replace-match " (array);\n" nil nil)))) | 2058 | (replace-match " (array);\n" nil nil)))) |
| 1987 | (let ((buf (gdb-get-buffer 'gdb-locals-buffer))) | 2059 | (let ((buf (gdb-get-buffer 'gdb-locals-buffer))) |
| 1988 | (and buf (with-current-buffer buf | 2060 | (and buf (with-current-buffer buf |
| 1989 | (let ((p (point)) | 2061 | (let ((p (window-point (get-buffer-window buf 0))) |
| 1990 | (buffer-read-only nil)) | 2062 | (buffer-read-only nil)) |
| 1991 | (delete-region (point-min) (point-max)) | 2063 | (erase-buffer) |
| 1992 | (insert-buffer-substring (gdb-get-create-buffer | 2064 | (insert-buffer-substring (gdb-get-create-buffer |
| 1993 | 'gdb-partial-output-buffer)) | 2065 | 'gdb-partial-output-buffer)) |
| 1994 | (goto-char p))))) | 2066 | (set-window-point (get-buffer-window buf 0) p))))) |
| 1995 | (run-hooks 'gdb-info-locals-hook)) | 2067 | (run-hooks 'gdb-info-locals-hook)) |
| 1996 | 2068 | ||
| 1997 | (defun gdb-info-locals-custom () | 2069 | (defun gdb-info-locals-custom () |
| @@ -2009,7 +2081,7 @@ corresponding to the mode line clicked." | |||
| 2009 | \\{gdb-locals-mode-map}" | 2081 | \\{gdb-locals-mode-map}" |
| 2010 | (kill-all-local-variables) | 2082 | (kill-all-local-variables) |
| 2011 | (setq major-mode 'gdb-locals-mode) | 2083 | (setq major-mode 'gdb-locals-mode) |
| 2012 | (setq mode-name (concat "Locals:" gdb-current-frame)) | 2084 | (setq mode-name (concat "Locals:" gdb-selected-frame)) |
| 2013 | (setq buffer-read-only t) | 2085 | (setq buffer-read-only t) |
| 2014 | (use-local-map gdb-locals-mode-map) | 2086 | (use-local-map gdb-locals-mode-map) |
| 2015 | (run-mode-hooks 'gdb-locals-mode-hook) | 2087 | (run-mode-hooks 'gdb-locals-mode-hook) |
| @@ -2069,7 +2141,8 @@ corresponding to the mode line clicked." | |||
| 2069 | (define-key menu [gdb] '("Gdb" . gdb-display-gdb-buffer)) | 2141 | (define-key menu [gdb] '("Gdb" . gdb-display-gdb-buffer)) |
| 2070 | (define-key menu [threads] '("Threads" . gdb-display-threads-buffer)) | 2142 | (define-key menu [threads] '("Threads" . gdb-display-threads-buffer)) |
| 2071 | (define-key menu [memory] '("Memory" . gdb-display-memory-buffer)) | 2143 | (define-key menu [memory] '("Memory" . gdb-display-memory-buffer)) |
| 2072 | (define-key menu [assembler] '("Machine" . gdb-display-assembler-buffer)) | 2144 | (define-key menu [disassembly] |
| 2145 | '("Disassembly" . gdb-display-assembler-buffer)) | ||
| 2073 | (define-key menu [registers] '("Registers" . gdb-display-registers-buffer)) | 2146 | (define-key menu [registers] '("Registers" . gdb-display-registers-buffer)) |
| 2074 | (define-key menu [inferior] | 2147 | (define-key menu [inferior] |
| 2075 | '(menu-item "Inferior IO" gdb-display-inferior-io-buffer | 2148 | '(menu-item "Inferior IO" gdb-display-inferior-io-buffer |
| @@ -2086,7 +2159,7 @@ corresponding to the mode line clicked." | |||
| 2086 | (define-key menu [gdb] '("Gdb" . gdb-frame-gdb-buffer)) | 2159 | (define-key menu [gdb] '("Gdb" . gdb-frame-gdb-buffer)) |
| 2087 | (define-key menu [threads] '("Threads" . gdb-frame-threads-buffer)) | 2160 | (define-key menu [threads] '("Threads" . gdb-frame-threads-buffer)) |
| 2088 | (define-key menu [memory] '("Memory" . gdb-frame-memory-buffer)) | 2161 | (define-key menu [memory] '("Memory" . gdb-frame-memory-buffer)) |
| 2089 | (define-key menu [assembler] '("Machine" . gdb-frame-assembler-buffer)) | 2162 | (define-key menu [disassembly] '("Disassembiy" . gdb-frame-assembler-buffer)) |
| 2090 | (define-key menu [registers] '("Registers" . gdb-frame-registers-buffer)) | 2163 | (define-key menu [registers] '("Registers" . gdb-frame-registers-buffer)) |
| 2091 | (define-key menu [inferior] | 2164 | (define-key menu [inferior] |
| 2092 | '(menu-item "Inferior IO" gdb-frame-inferior-io-buffer | 2165 | '(menu-item "Inferior IO" gdb-frame-inferior-io-buffer |
| @@ -2129,14 +2202,6 @@ corresponding to the mode line clicked." | |||
| 2129 | (gdb-display-buffer | 2202 | (gdb-display-buffer |
| 2130 | (gdb-get-create-buffer 'gdba))) | 2203 | (gdb-get-create-buffer 'gdba))) |
| 2131 | 2204 | ||
| 2132 | (defvar gdb-main-file nil "Source file from which program execution begins.") | ||
| 2133 | |||
| 2134 | (defcustom gdb-show-main nil | ||
| 2135 | "Nil means don't display source file containing the main routine." | ||
| 2136 | :type 'boolean | ||
| 2137 | :group 'gud | ||
| 2138 | :version "22.1") | ||
| 2139 | |||
| 2140 | (defun gdb-set-window-buffer (name) | 2205 | (defun gdb-set-window-buffer (name) |
| 2141 | (set-window-buffer (selected-window) (get-buffer name)) | 2206 | (set-window-buffer (selected-window) (get-buffer name)) |
| 2142 | (set-window-dedicated-p (selected-window) t)) | 2207 | (set-window-dedicated-p (selected-window) t)) |
| @@ -2236,7 +2301,7 @@ Kills the gdb buffers and resets the source buffers." | |||
| 2236 | buffers." | 2301 | buffers." |
| 2237 | (goto-char (point-min)) | 2302 | (goto-char (point-min)) |
| 2238 | (if (and (search-forward "Located in " nil t) | 2303 | (if (and (search-forward "Located in " nil t) |
| 2239 | (looking-at "\\S-*")) | 2304 | (looking-at "\\S-+")) |
| 2240 | (setq gdb-main-file (match-string 0))) | 2305 | (setq gdb-main-file (match-string 0))) |
| 2241 | (goto-char (point-min)) | 2306 | (goto-char (point-min)) |
| 2242 | (if (search-forward "Includes preprocessor macro info." nil t) | 2307 | (if (search-forward "Includes preprocessor macro info." nil t) |
| @@ -2254,7 +2319,7 @@ Put in buffer and place breakpoint icon." | |||
| 2254 | (goto-char (point-min)) | 2319 | (goto-char (point-min)) |
| 2255 | (catch 'file-not-found | 2320 | (catch 'file-not-found |
| 2256 | (if (search-forward "Located in " nil t) | 2321 | (if (search-forward "Located in " nil t) |
| 2257 | (when (looking-at "\\S-*") | 2322 | (when (looking-at "\\S-+") |
| 2258 | (delete (cons bptno "File not found") gdb-location-alist) | 2323 | (delete (cons bptno "File not found") gdb-location-alist) |
| 2259 | (push (cons bptno (match-string 0)) gdb-location-alist)) | 2324 | (push (cons bptno (match-string 0)) gdb-location-alist)) |
| 2260 | (gdb-resync) | 2325 | (gdb-resync) |
| @@ -2276,6 +2341,8 @@ Add directory to search path for source files using the GDB command, dir.")) | |||
| 2276 | (add-hook 'find-file-hook 'gdb-find-file-hook) | 2341 | (add-hook 'find-file-hook 'gdb-find-file-hook) |
| 2277 | 2342 | ||
| 2278 | (defun gdb-find-file-hook () | 2343 | (defun gdb-find-file-hook () |
| 2344 | "Set up buffer for debugging if file is part of the source code | ||
| 2345 | of the current session." | ||
| 2279 | (if (and (not gdb-find-file-unhook) | 2346 | (if (and (not gdb-find-file-unhook) |
| 2280 | ;; in case gud or gdb-ui is just loaded | 2347 | ;; in case gud or gdb-ui is just loaded |
| 2281 | gud-comint-buffer | 2348 | gud-comint-buffer |
| @@ -2399,7 +2466,9 @@ BUFFER nil or omitted means use the current buffer." | |||
| 2399 | 2466 | ||
| 2400 | (def-gdb-auto-updated-buffer gdb-assembler-buffer | 2467 | (def-gdb-auto-updated-buffer gdb-assembler-buffer |
| 2401 | gdb-invalidate-assembler | 2468 | gdb-invalidate-assembler |
| 2402 | (concat gdb-server-prefix "disassemble " gdb-current-address "\n") | 2469 | (concat gdb-server-prefix "disassemble " |
| 2470 | (if (member gdb-frame-address '(nil "main")) nil "0x") | ||
| 2471 | gdb-frame-address "\n") | ||
| 2403 | gdb-assembler-handler | 2472 | gdb-assembler-handler |
| 2404 | gdb-assembler-custom) | 2473 | gdb-assembler-custom) |
| 2405 | 2474 | ||
| @@ -2407,38 +2476,38 @@ BUFFER nil or omitted means use the current buffer." | |||
| 2407 | (let ((buffer (gdb-get-buffer 'gdb-assembler-buffer)) | 2476 | (let ((buffer (gdb-get-buffer 'gdb-assembler-buffer)) |
| 2408 | (pos 1) (address) (flag) (bptno)) | 2477 | (pos 1) (address) (flag) (bptno)) |
| 2409 | (with-current-buffer buffer | 2478 | (with-current-buffer buffer |
| 2410 | (if (not (equal gdb-current-address "main")) | 2479 | (save-excursion |
| 2411 | (progn | 2480 | (if (not (equal gdb-frame-address "main")) |
| 2412 | (goto-char (point-min)) | 2481 | (progn |
| 2413 | (if (re-search-forward gdb-current-address nil t) | 2482 | (goto-char (point-min)) |
| 2414 | (progn | 2483 | (if (and gdb-frame-address |
| 2415 | (setq pos (point)) | 2484 | (re-search-forward gdb-frame-address nil t)) |
| 2416 | (beginning-of-line) | 2485 | (progn |
| 2417 | (or gdb-overlay-arrow-position | 2486 | (setq pos (point)) |
| 2418 | (setq gdb-overlay-arrow-position (make-marker))) | 2487 | (beginning-of-line) |
| 2419 | (set-marker gdb-overlay-arrow-position | 2488 | (or gdb-overlay-arrow-position |
| 2420 | (point) (current-buffer)))))) | 2489 | (setq gdb-overlay-arrow-position (make-marker))) |
| 2421 | ;; remove all breakpoint-icons in assembler buffer before updating. | 2490 | (set-marker gdb-overlay-arrow-position |
| 2422 | (gdb-remove-breakpoint-icons (point-min) (point-max))) | 2491 | (point) (current-buffer)))))) |
| 2492 | ;; remove all breakpoint-icons in assembler buffer before updating. | ||
| 2493 | (gdb-remove-breakpoint-icons (point-min) (point-max)))) | ||
| 2423 | (with-current-buffer (gdb-get-buffer 'gdb-breakpoints-buffer) | 2494 | (with-current-buffer (gdb-get-buffer 'gdb-breakpoints-buffer) |
| 2424 | (goto-char (point-min)) | 2495 | (goto-char (point-min)) |
| 2425 | (while (< (point) (- (point-max) 1)) | 2496 | (while (< (point) (- (point-max) 1)) |
| 2426 | (forward-line 1) | 2497 | (forward-line 1) |
| 2427 | (if (looking-at "[^\t].*breakpoint") | 2498 | (if (looking-at "[^\t].*?breakpoint") |
| 2428 | (progn | 2499 | (progn |
| 2429 | (looking-at | 2500 | (looking-at |
| 2430 | "\\([0-9]+\\)\\s-+\\S-+\\s-+\\S-+\\s-+\\(.\\)\\s-+0x\\(\\S-+\\)") | 2501 | "\\([0-9]+\\)\\s-+\\S-+\\s-+\\S-+\\s-+\\(.\\)\\s-+0x0*\\(\\S-+\\)") |
| 2431 | (setq bptno (match-string 1)) | 2502 | (setq bptno (match-string 1)) |
| 2432 | (setq flag (char-after (match-beginning 2))) | 2503 | (setq flag (char-after (match-beginning 2))) |
| 2433 | (setq address (match-string 3)) | 2504 | (setq address (match-string 3)) |
| 2434 | ;; remove leading 0s from output of info break. | ||
| 2435 | (if (string-match "^0+\\(.*\\)" address) | ||
| 2436 | (setq address (match-string 1 address))) | ||
| 2437 | (with-current-buffer buffer | 2505 | (with-current-buffer buffer |
| 2506 | (save-excursion | ||
| 2438 | (goto-char (point-min)) | 2507 | (goto-char (point-min)) |
| 2439 | (if (re-search-forward address nil t) | 2508 | (if (re-search-forward address nil t) |
| 2440 | (gdb-put-breakpoint-icon (eq flag ?y) bptno))))))) | 2509 | (gdb-put-breakpoint-icon (eq flag ?y) bptno)))))))) |
| 2441 | (if (not (equal gdb-current-address "main")) | 2510 | (if (not (equal gdb-frame-address "main")) |
| 2442 | (set-window-point (get-buffer-window buffer 0) pos)))) | 2511 | (set-window-point (get-buffer-window buffer 0) pos)))) |
| 2443 | 2512 | ||
| 2444 | (defvar gdb-assembler-mode-map | 2513 | (defvar gdb-assembler-mode-map |
| @@ -2468,7 +2537,7 @@ BUFFER nil or omitted means use the current buffer." | |||
| 2468 | \\{gdb-assembler-mode-map}" | 2537 | \\{gdb-assembler-mode-map}" |
| 2469 | (kill-all-local-variables) | 2538 | (kill-all-local-variables) |
| 2470 | (setq major-mode 'gdb-assembler-mode) | 2539 | (setq major-mode 'gdb-assembler-mode) |
| 2471 | (setq mode-name "Machine") | 2540 | (setq mode-name (concat "Machine:" gdb-selected-frame)) |
| 2472 | (setq gdb-overlay-arrow-position nil) | 2541 | (setq gdb-overlay-arrow-position nil) |
| 2473 | (add-to-list 'overlay-arrow-variable-list 'gdb-overlay-arrow-position) | 2542 | (add-to-list 'overlay-arrow-variable-list 'gdb-overlay-arrow-position) |
| 2474 | (setq fringes-outside-margins t) | 2543 | (setq fringes-outside-margins t) |
| @@ -2482,33 +2551,36 @@ BUFFER nil or omitted means use the current buffer." | |||
| 2482 | 2551 | ||
| 2483 | (defun gdb-assembler-buffer-name () | 2552 | (defun gdb-assembler-buffer-name () |
| 2484 | (with-current-buffer gud-comint-buffer | 2553 | (with-current-buffer gud-comint-buffer |
| 2485 | (concat "*Machine Code " (gdb-get-target-string) "*"))) | 2554 | (concat "*Disassembly of " (gdb-get-target-string) "*"))) |
| 2486 | 2555 | ||
| 2487 | (defun gdb-display-assembler-buffer () | 2556 | (defun gdb-display-assembler-buffer () |
| 2488 | "Display disassembly view." | 2557 | "Display disassembly view." |
| 2489 | (interactive) | 2558 | (interactive) |
| 2559 | (setq gdb-previous-frame nil) | ||
| 2490 | (gdb-display-buffer | 2560 | (gdb-display-buffer |
| 2491 | (gdb-get-create-buffer 'gdb-assembler-buffer))) | 2561 | (gdb-get-create-buffer 'gdb-assembler-buffer))) |
| 2492 | 2562 | ||
| 2493 | (defun gdb-frame-assembler-buffer () | 2563 | (defun gdb-frame-assembler-buffer () |
| 2494 | "Display disassembly view in a new frame." | 2564 | "Display disassembly view in a new frame." |
| 2495 | (interactive) | 2565 | (interactive) |
| 2566 | (setq gdb-previous-frame nil) | ||
| 2496 | (let ((special-display-regexps (append special-display-regexps '(".*"))) | 2567 | (let ((special-display-regexps (append special-display-regexps '(".*"))) |
| 2497 | (special-display-frame-alist gdb-frame-parameters)) | 2568 | (special-display-frame-alist gdb-frame-parameters)) |
| 2498 | (display-buffer (gdb-get-create-buffer 'gdb-assembler-buffer)))) | 2569 | (display-buffer (gdb-get-create-buffer 'gdb-assembler-buffer)))) |
| 2499 | 2570 | ||
| 2500 | ;; modified because if gdb-current-address has changed value a new command | 2571 | ;; modified because if gdb-frame-address has changed value a new command |
| 2501 | ;; must be enqueued to update the buffer with the new output | 2572 | ;; must be enqueued to update the buffer with the new output |
| 2502 | (defun gdb-invalidate-assembler (&optional ignored) | 2573 | (defun gdb-invalidate-assembler (&optional ignored) |
| 2503 | (if (gdb-get-buffer 'gdb-assembler-buffer) | 2574 | (if (gdb-get-buffer 'gdb-assembler-buffer) |
| 2504 | (progn | 2575 | (progn |
| 2505 | (unless (string-equal gdb-current-frame gdb-previous-frame) | 2576 | (unless (and gdb-selected-frame |
| 2577 | (string-equal gdb-selected-frame gdb-previous-frame)) | ||
| 2506 | (if (or (not (member 'gdb-invalidate-assembler | 2578 | (if (or (not (member 'gdb-invalidate-assembler |
| 2507 | gdb-pending-triggers)) | 2579 | gdb-pending-triggers)) |
| 2508 | (not (string-equal gdb-current-address | 2580 | (not (string-equal gdb-frame-address |
| 2509 | gdb-previous-address))) | 2581 | gdb-previous-frame-address))) |
| 2510 | (progn | 2582 | (progn |
| 2511 | ;; take previous disassemble command off the queue | 2583 | ;; take previous disassemble command, if any, off the queue |
| 2512 | (with-current-buffer gud-comint-buffer | 2584 | (with-current-buffer gud-comint-buffer |
| 2513 | (let ((queue gdb-input-queue)) | 2585 | (let ((queue gdb-input-queue)) |
| 2514 | (dolist (item queue) | 2586 | (dolist (item queue) |
| @@ -2516,46 +2588,46 @@ BUFFER nil or omitted means use the current buffer." | |||
| 2516 | (setq gdb-input-queue | 2588 | (setq gdb-input-queue |
| 2517 | (delete item gdb-input-queue)))))) | 2589 | (delete item gdb-input-queue)))))) |
| 2518 | (gdb-enqueue-input | 2590 | (gdb-enqueue-input |
| 2519 | (list (concat gdb-server-prefix "disassemble " | 2591 | (list |
| 2520 | gdb-current-address "\n") | 2592 | (concat gdb-server-prefix "disassemble " |
| 2593 | (if (member gdb-frame-address '(nil "main")) nil "0x") | ||
| 2594 | gdb-frame-address "\n") | ||
| 2521 | 'gdb-assembler-handler)) | 2595 | 'gdb-assembler-handler)) |
| 2522 | (push 'gdb-invalidate-assembler gdb-pending-triggers) | 2596 | (push 'gdb-invalidate-assembler gdb-pending-triggers) |
| 2523 | (setq gdb-previous-address gdb-current-address) | 2597 | (setq gdb-previous-frame-address gdb-frame-address) |
| 2524 | (setq gdb-previous-frame gdb-current-frame))))))) | 2598 | (setq gdb-previous-frame gdb-selected-frame))))))) |
| 2525 | 2599 | ||
| 2526 | (defun gdb-get-current-frame () | 2600 | (defun gdb-get-selected-frame () |
| 2527 | (if (not (member 'gdb-get-current-frame gdb-pending-triggers)) | 2601 | (if (not (member 'gdb-get-selected-frame gdb-pending-triggers)) |
| 2528 | (progn | 2602 | (progn |
| 2529 | (gdb-enqueue-input | 2603 | (gdb-enqueue-input |
| 2530 | (list (concat gdb-server-prefix "info frame\n") 'gdb-frame-handler)) | 2604 | (list (concat gdb-server-prefix "info frame\n") 'gdb-frame-handler)) |
| 2531 | (push 'gdb-get-current-frame | 2605 | (push 'gdb-get-selected-frame |
| 2532 | gdb-pending-triggers)))) | 2606 | gdb-pending-triggers)))) |
| 2533 | 2607 | ||
| 2534 | (defun gdb-frame-handler () | 2608 | (defun gdb-frame-handler () |
| 2535 | (setq gdb-pending-triggers | 2609 | (setq gdb-pending-triggers |
| 2536 | (delq 'gdb-get-current-frame gdb-pending-triggers)) | 2610 | (delq 'gdb-get-selected-frame gdb-pending-triggers)) |
| 2537 | (with-current-buffer (gdb-get-create-buffer 'gdb-partial-output-buffer) | 2611 | (with-current-buffer (gdb-get-create-buffer 'gdb-partial-output-buffer) |
| 2538 | (goto-char (point-min)) | 2612 | (goto-char (point-min)) |
| 2539 | (if (looking-at "Stack level \\([0-9]+\\)") | 2613 | (if (re-search-forward "Stack level \\([0-9]+\\)" nil t) |
| 2540 | (setq gdb-current-stack-level (match-string 1))) | 2614 | (setq gdb-frame-number (match-string 1))) |
| 2541 | (forward-line) | 2615 | (goto-char (point-min)) |
| 2542 | (if (looking-at ".*=\\s-+0x\\(\\S-*\\)\\s-+in\\s-+\\(\\S-*?\\);? ") | 2616 | (if (re-search-forward |
| 2617 | ".*=\\s-+0x0*\\(\\S-*\\)\\s-+in\\s-+\\(\\S-*?\\);? " nil t) | ||
| 2543 | (progn | 2618 | (progn |
| 2544 | (setq gdb-current-frame (match-string 2)) | 2619 | (setq gdb-selected-frame (match-string 2)) |
| 2545 | (if (gdb-get-buffer 'gdb-locals-buffer) | 2620 | (if (gdb-get-buffer 'gdb-locals-buffer) |
| 2546 | (with-current-buffer (gdb-get-buffer 'gdb-locals-buffer) | 2621 | (with-current-buffer (gdb-get-buffer 'gdb-locals-buffer) |
| 2547 | (setq mode-name (concat "Locals:" gdb-current-frame)))) | 2622 | (setq mode-name (concat "Locals:" gdb-selected-frame)))) |
| 2548 | (let ((address (match-string 1))) | 2623 | (if (gdb-get-buffer 'gdb-assembler-buffer) |
| 2549 | ;; remove leading 0s from output of info frame command. | 2624 | (with-current-buffer (gdb-get-buffer 'gdb-assembler-buffer) |
| 2550 | (if (string-match "^0+\\(.*\\)" address) | 2625 | (setq mode-name (concat "Machine:" gdb-selected-frame)))) |
| 2551 | (setq gdb-current-address | 2626 | (setq gdb-frame-address (match-string 1)))) |
| 2552 | (concat "0x" (match-string 1 address))) | 2627 | (goto-char (point-min)) |
| 2553 | (setq gdb-current-address (concat "0x" address)))) | ||
| 2554 | (if (not (re-search-forward "(\\S-*:[0-9]*);" nil t)) | ||
| 2555 | ;;update with new frame for machine code if necessary | ||
| 2556 | (gdb-invalidate-assembler))))) | ||
| 2557 | (if (re-search-forward " source language \\(\\S-*\\)\." nil t) | 2628 | (if (re-search-forward " source language \\(\\S-*\\)\." nil t) |
| 2558 | (setq gdb-current-language (match-string 1)))) | 2629 | (setq gdb-current-language (match-string 1)))) |
| 2630 | (gdb-invalidate-assembler)) | ||
| 2559 | 2631 | ||
| 2560 | (provide 'gdb-ui) | 2632 | (provide 'gdb-ui) |
| 2561 | 2633 | ||
diff --git a/lisp/progmodes/gud.el b/lisp/progmodes/gud.el index 4c95fc65d58..f3a95514c13 100644 --- a/lisp/progmodes/gud.el +++ b/lisp/progmodes/gud.el | |||
| @@ -25,17 +25,17 @@ | |||
| 25 | 25 | ||
| 26 | ;;; Commentary: | 26 | ;;; Commentary: |
| 27 | 27 | ||
| 28 | ;; The ancestral gdb.el was by W. Schelter <wfs@rascal.ics.utexas.edu> | 28 | ;; The ancestral gdb.el was by W. Schelter <wfs@rascal.ics.utexas.edu> It was |
| 29 | ;; It was later rewritten by rms. Some ideas were due to Masanobu. | 29 | ;; later rewritten by rms. Some ideas were due to Masanobu. Grand |
| 30 | ;; Grand Unification (sdb/dbx support) by Eric S. Raymond <esr@thyrsus.com> | 30 | ;; Unification (sdb/dbx support) by Eric S. Raymond <esr@thyrsus.com> Barry |
| 31 | ;; The overloading code was then rewritten by Barry Warsaw <bwarsaw@cen.com>, | 31 | ;; Warsaw <bwarsaw@cen.com> hacked the mode to use comint.el. Shane Hartman |
| 32 | ;; who also hacked the mode to use comint.el. Shane Hartman <shane@spr.com> | 32 | ;; <shane@spr.com> added support for xdb (HPUX debugger). Rick Sladkey |
| 33 | ;; added support for xdb (HPUX debugger). Rick Sladkey <jrs@world.std.com> | 33 | ;; <jrs@world.std.com> wrote the GDB command completion code. Dave Love |
| 34 | ;; wrote the GDB command completion code. Dave Love <d.love@dl.ac.uk> | 34 | ;; <d.love@dl.ac.uk> added the IRIX kluge, re-implemented the Mips-ish variant |
| 35 | ;; added the IRIX kluge, re-implemented the Mips-ish variant and added | 35 | ;; and added a menu. Brian D. Carlstrom <bdc@ai.mit.edu> combined the IRIX |
| 36 | ;; a menu. Brian D. Carlstrom <bdc@ai.mit.edu> combined the IRIX kluge with | 36 | ;; kluge with the gud-xdb-directories hack producing gud-dbx-directories. |
| 37 | ;; the gud-xdb-directories hack producing gud-dbx-directories. Derek L. Davies | 37 | ;; Derek L. Davies <ddavies@world.std.com> added support for jdb (Java |
| 38 | ;; <ddavies@world.std.com> added support for jdb (Java debugger.) | 38 | ;; debugger.) |
| 39 | 39 | ||
| 40 | ;;; Code: | 40 | ;;; Code: |
| 41 | 41 | ||
| @@ -107,11 +107,10 @@ Used to grey out relevant togolbar icons.") | |||
| 107 | (setq same-window-regexps nil) | 107 | (setq same-window-regexps nil) |
| 108 | (throw 'info-found nil)))) | 108 | (throw 'info-found nil)))) |
| 109 | nil 0) | 109 | nil 0) |
| 110 | (require 'info) | ||
| 111 | (select-frame (make-frame))) | 110 | (select-frame (make-frame))) |
| 112 | (if (memq gud-minor-mode '(gdbmi gdba)) | 111 | (if (memq gud-minor-mode '(gdbmi gdba)) |
| 113 | (Info-goto-node "(emacs)GDB Graphical Interface") | 112 | (info "(emacs)GDB Graphical Interface") |
| 114 | (Info-goto-node "(emacs)Debuggers")))) | 113 | (info "(emacs)Debuggers")))) |
| 115 | 114 | ||
| 116 | (easy-mmode-defmap gud-menu-map | 115 | (easy-mmode-defmap gud-menu-map |
| 117 | '(([help] "Info" . gud-goto-info) | 116 | '(([help] "Info" . gud-goto-info) |
| @@ -141,6 +140,9 @@ Used to grey out relevant togolbar icons.") | |||
| 141 | :enable (and (not gud-running) | 140 | :enable (and (not gud-running) |
| 142 | (memq gud-minor-mode | 141 | (memq gud-minor-mode |
| 143 | '(gdbmi gdba gdb dbx xdb jdb pdb bashdb)))) | 142 | '(gdbmi gdba gdb dbx xdb jdb pdb bashdb)))) |
| 143 | ([print*] menu-item "Print Dereference" gud-pstar | ||
| 144 | :enable (and (not gud-running) | ||
| 145 | (memq gud-minor-mode '(gdbmi gdba gdb)))) | ||
| 144 | ([print] menu-item "Print Expression" gud-print | 146 | ([print] menu-item "Print Expression" gud-print |
| 145 | :enable (not gud-running)) | 147 | :enable (not gud-running)) |
| 146 | ([watch] menu-item "Watch Expression" gud-watch | 148 | ([watch] menu-item "Watch Expression" gud-watch |
| @@ -184,18 +186,19 @@ Used to grey out relevant togolbar icons.") | |||
| 184 | (dolist (x '((gud-break . "gud-break") | 186 | (dolist (x '((gud-break . "gud-break") |
| 185 | (gud-remove . "gud-remove") | 187 | (gud-remove . "gud-remove") |
| 186 | (gud-print . "gud-print") | 188 | (gud-print . "gud-print") |
| 189 | (gud-pstar . "gud-pstar") | ||
| 187 | (gud-watch . "gud-watch") | 190 | (gud-watch . "gud-watch") |
| 188 | (gud-run . "gud-run") | ||
| 189 | (gud-until . "gud-until") | ||
| 190 | (gud-cont . "gud-cont") | 191 | (gud-cont . "gud-cont") |
| 192 | (gud-until . "gud-until") | ||
| 193 | (gud-finish . "gud-finish") | ||
| 194 | (gud-run . "gud-run") | ||
| 191 | ;; gud-s, gud-si etc. instead of gud-step, | 195 | ;; gud-s, gud-si etc. instead of gud-step, |
| 192 | ;; gud-stepi, to avoid file-name clashes on DOS | 196 | ;; gud-stepi, to avoid file-name clashes on DOS |
| 193 | ;; 8+3 filesystems. | 197 | ;; 8+3 filesystems. |
| 194 | (gud-step . "gud-s") | ||
| 195 | (gud-next . "gud-n") | 198 | (gud-next . "gud-n") |
| 196 | (gud-finish . "gud-finish") | 199 | (gud-step . "gud-s") |
| 197 | (gud-stepi . "gud-si") | ||
| 198 | (gud-nexti . "gud-ni") | 200 | (gud-nexti . "gud-ni") |
| 201 | (gud-stepi . "gud-si") | ||
| 199 | (gud-up . "gud-up") | 202 | (gud-up . "gud-up") |
| 200 | (gud-down . "gud-down") | 203 | (gud-down . "gud-down") |
| 201 | (gud-goto-info . "info")) | 204 | (gud-goto-info . "info")) |
| @@ -343,13 +346,13 @@ t means that there is no stack, and we are in display-file mode.") | |||
| 343 | 346 | ||
| 344 | (defvar gud-speedbar-menu-items | 347 | (defvar gud-speedbar-menu-items |
| 345 | ;; Note to self. Add expand, and turn off items when not available. | 348 | ;; Note to self. Add expand, and turn off items when not available. |
| 346 | '(["Jump to stack frame" speedbar-edit-line | 349 | '(["Jump to stack frame" speedbar-edit-line |
| 347 | (with-current-buffer gud-comint-buffer | 350 | (with-current-buffer gud-comint-buffer |
| 348 | (not (memq gud-minor-mode '(gdbmi gdba))))] | 351 | (not (memq gud-minor-mode '(gdbmi gdba))))] |
| 349 | ["Edit value" speedbar-edit-line | 352 | ["Edit value" speedbar-edit-line |
| 350 | (with-current-buffer gud-comint-buffer | 353 | (with-current-buffer gud-comint-buffer |
| 351 | (not (memq gud-minor-mode '(gdbmi gdba))))] | 354 | (not (memq gud-minor-mode '(gdbmi gdba))))] |
| 352 | ["Delete expression" gdb-var-delete | 355 | ["Delete expression" gdb-var-delete |
| 353 | (with-current-buffer gud-comint-buffer | 356 | (with-current-buffer gud-comint-buffer |
| 354 | (not (memq gud-minor-mode '(gdbmi gdba))))]) | 357 | (not (memq gud-minor-mode '(gdbmi gdba))))]) |
| 355 | "Additional menu items to add to the speedbar frame.") | 358 | "Additional menu items to add to the speedbar frame.") |
| @@ -581,6 +584,8 @@ and source-file directory for your debugger." | |||
| 581 | (gud-def gud-up "up %p" "<" "Up N stack frames (numeric arg).") | 584 | (gud-def gud-up "up %p" "<" "Up N stack frames (numeric arg).") |
| 582 | (gud-def gud-down "down %p" ">" "Down N stack frames (numeric arg).") | 585 | (gud-def gud-down "down %p" ">" "Down N stack frames (numeric arg).") |
| 583 | (gud-def gud-print "print %e" "\C-p" "Evaluate C expression at point.") | 586 | (gud-def gud-print "print %e" "\C-p" "Evaluate C expression at point.") |
| 587 | (gud-def gud-pstar "print* %e" nil | ||
| 588 | "Evaluate C dereferenced pointer expression at point.") | ||
| 584 | (gud-def gud-until "until %l" "\C-u" "Continue to current line.") | 589 | (gud-def gud-until "until %l" "\C-u" "Continue to current line.") |
| 585 | (gud-def gud-run "run" nil "Run the program.") | 590 | (gud-def gud-run "run" nil "Run the program.") |
| 586 | 591 | ||
| @@ -3192,7 +3197,7 @@ For C this would dereference a pointer expression.") | |||
| 3192 | "The mouse movement event that led to a tooltip display. | 3197 | "The mouse movement event that led to a tooltip display. |
| 3193 | This event can be examined by forms in GUD-TOOLTIP-DISPLAY.") | 3198 | This event can be examined by forms in GUD-TOOLTIP-DISPLAY.") |
| 3194 | 3199 | ||
| 3195 | (defun gud-tooltip-toggle-dereference () | 3200 | (defun toggle-gud-tooltip-dereference () |
| 3196 | "Toggle whether tooltips should show `* expr' or `expr'." | 3201 | "Toggle whether tooltips should show `* expr' or `expr'." |
| 3197 | (interactive) | 3202 | (interactive) |
| 3198 | (setq gud-tooltip-dereference (not gud-tooltip-dereference)) | 3203 | (setq gud-tooltip-dereference (not gud-tooltip-dereference)) |
| @@ -3201,7 +3206,7 @@ This event can be examined by forms in GUD-TOOLTIP-DISPLAY.") | |||
| 3201 | (if gud-tooltip-dereference "on" "off")))) | 3206 | (if gud-tooltip-dereference "on" "off")))) |
| 3202 | 3207 | ||
| 3203 | (define-obsolete-function-alias 'tooltip-gud-toggle-dereference | 3208 | (define-obsolete-function-alias 'tooltip-gud-toggle-dereference |
| 3204 | 'gud-tooltip-toggle-dereference "22.1") | 3209 | 'toggle-gud-tooltip-dereference "22.1") |
| 3205 | 3210 | ||
| 3206 | (define-minor-mode gud-tooltip-mode | 3211 | (define-minor-mode gud-tooltip-mode |
| 3207 | "Toggle the display of GUD tooltips." | 3212 | "Toggle the display of GUD tooltips." |
diff --git a/lisp/progmodes/icon.el b/lisp/progmodes/icon.el index c61c64532a3..0eb1b8bf3df 100644 --- a/lisp/progmodes/icon.el +++ b/lisp/progmodes/icon.el | |||
| @@ -205,7 +205,7 @@ with no args, if that value is non-nil." | |||
| 205 | (cons '(icon-mode "\\<procedure\\>" "\\<end\\>" nil | 205 | (cons '(icon-mode "\\<procedure\\>" "\\<end\\>" nil |
| 206 | icon-forward-sexp-function) | 206 | icon-forward-sexp-function) |
| 207 | hs-special-modes-alist))) | 207 | hs-special-modes-alist))) |
| 208 | (run-hooks 'icon-mode-hook)) | 208 | (run-mode-hooks 'icon-mode-hook)) |
| 209 | 209 | ||
| 210 | ;; This is used by indent-for-comment to decide how much to | 210 | ;; This is used by indent-for-comment to decide how much to |
| 211 | ;; indent a comment in Icon code based on its context. | 211 | ;; indent a comment in Icon code based on its context. |
diff --git a/lisp/progmodes/idlw-help.el b/lisp/progmodes/idlw-help.el index 8696e1a7d63..6c2cb00bbde 100644 --- a/lisp/progmodes/idlw-help.el +++ b/lisp/progmodes/idlw-help.el | |||
| @@ -278,7 +278,7 @@ Here are all keybindings. | |||
| 278 | (set (make-local-variable 'idlwave-help-def-pos) nil) | 278 | (set (make-local-variable 'idlwave-help-def-pos) nil) |
| 279 | (set (make-local-variable 'idlwave-help-args) nil) | 279 | (set (make-local-variable 'idlwave-help-args) nil) |
| 280 | (set (make-local-variable 'idlwave-help-in-header) nil) | 280 | (set (make-local-variable 'idlwave-help-in-header) nil) |
| 281 | (run-hooks 'idlwave-help-mode-hook)) | 281 | (run-mode-hooks 'idlwave-help-mode-hook)) |
| 282 | 282 | ||
| 283 | (defun idlwave-html-help-location () | 283 | (defun idlwave-html-help-location () |
| 284 | "Return the help directory where HTML files are, or nil if that is unknown." | 284 | "Return the help directory where HTML files are, or nil if that is unknown." |
diff --git a/lisp/progmodes/idlw-shell.el b/lisp/progmodes/idlw-shell.el index 77244819f1b..e804b9f8d50 100644 --- a/lisp/progmodes/idlw-shell.el +++ b/lisp/progmodes/idlw-shell.el | |||
| @@ -1055,7 +1055,7 @@ IDL has currently stepped.") | |||
| 1055 | (set (make-local-variable 'tool-bar-map) nil) | 1055 | (set (make-local-variable 'tool-bar-map) nil) |
| 1056 | 1056 | ||
| 1057 | ;; Run the hooks. | 1057 | ;; Run the hooks. |
| 1058 | (run-hooks 'idlwave-shell-mode-hook) | 1058 | (run-mode-hooks 'idlwave-shell-mode-hook) |
| 1059 | (idlwave-shell-send-command idlwave-shell-initial-commands nil 'hide) | 1059 | (idlwave-shell-send-command idlwave-shell-initial-commands nil 'hide) |
| 1060 | ;; Turn off IDL's ^d interpreting, and define a system | 1060 | ;; Turn off IDL's ^d interpreting, and define a system |
| 1061 | ;; variable which knows the version of IDLWAVE | 1061 | ;; variable which knows the version of IDLWAVE |
diff --git a/lisp/progmodes/idlwave.el b/lisp/progmodes/idlwave.el index a118b0055a9..6bd7e0eaced 100644 --- a/lisp/progmodes/idlwave.el +++ b/lisp/progmodes/idlwave.el | |||
| @@ -1954,7 +1954,7 @@ The main features of this mode are | |||
| 1954 | (idlwave-new-buffer-update) | 1954 | (idlwave-new-buffer-update) |
| 1955 | 1955 | ||
| 1956 | ;; Run the mode hook | 1956 | ;; Run the mode hook |
| 1957 | (run-hooks 'idlwave-mode-hook)) | 1957 | (run-mode-hooks 'idlwave-mode-hook)) |
| 1958 | 1958 | ||
| 1959 | (defvar idlwave-setup-done nil) | 1959 | (defvar idlwave-setup-done nil) |
| 1960 | (defun idlwave-setup () | 1960 | (defun idlwave-setup () |
diff --git a/lisp/progmodes/inf-lisp.el b/lisp/progmodes/inf-lisp.el index 13bc7f08999..ad7c4cb4cf2 100644 --- a/lisp/progmodes/inf-lisp.el +++ b/lisp/progmodes/inf-lisp.el | |||
| @@ -260,7 +260,8 @@ Paragraphs are separated only by blank lines. Semicolons start comments. | |||
| 260 | If you accidentally suspend your process, use \\[comint-continue-subjob] | 260 | If you accidentally suspend your process, use \\[comint-continue-subjob] |
| 261 | to continue it." | 261 | to continue it." |
| 262 | (interactive) | 262 | (interactive) |
| 263 | (comint-mode) | 263 | (delay-mode-hooks |
| 264 | (comint-mode)) | ||
| 264 | (setq comint-prompt-regexp inferior-lisp-prompt) | 265 | (setq comint-prompt-regexp inferior-lisp-prompt) |
| 265 | (setq major-mode 'inferior-lisp-mode) | 266 | (setq major-mode 'inferior-lisp-mode) |
| 266 | (setq mode-name "Inferior Lisp") | 267 | (setq mode-name "Inferior Lisp") |
| @@ -269,7 +270,7 @@ to continue it." | |||
| 269 | (use-local-map inferior-lisp-mode-map) ;c-c c-k for "kompile" file | 270 | (use-local-map inferior-lisp-mode-map) ;c-c c-k for "kompile" file |
| 270 | (setq comint-get-old-input (function lisp-get-old-input)) | 271 | (setq comint-get-old-input (function lisp-get-old-input)) |
| 271 | (setq comint-input-filter (function lisp-input-filter)) | 272 | (setq comint-input-filter (function lisp-input-filter)) |
| 272 | (run-hooks 'inferior-lisp-mode-hook)) | 273 | (run-mode-hooks 'inferior-lisp-mode-hook)) |
| 273 | 274 | ||
| 274 | (defun lisp-get-old-input () | 275 | (defun lisp-get-old-input () |
| 275 | "Return a string containing the sexp ending at point." | 276 | "Return a string containing the sexp ending at point." |
diff --git a/lisp/progmodes/m4-mode.el b/lisp/progmodes/m4-mode.el index bd6fac5c639..5becd22f6eb 100644 --- a/lisp/progmodes/m4-mode.el +++ b/lisp/progmodes/m4-mode.el | |||
| @@ -147,7 +147,7 @@ | |||
| 147 | font-lock-defaults '(m4-font-lock-keywords nil) | 147 | font-lock-defaults '(m4-font-lock-keywords nil) |
| 148 | ) | 148 | ) |
| 149 | (set-syntax-table m4-mode-syntax-table) | 149 | (set-syntax-table m4-mode-syntax-table) |
| 150 | (run-hooks 'm4-mode-hook)) | 150 | (run-mode-hooks 'm4-mode-hook)) |
| 151 | 151 | ||
| 152 | (provide 'm4-mode) | 152 | (provide 'm4-mode) |
| 153 | ;;stuff to play with for debugging | 153 | ;;stuff to play with for debugging |
diff --git a/lisp/progmodes/make-mode.el b/lisp/progmodes/make-mode.el index 05c3ac50787..7356583fb90 100644 --- a/lisp/progmodes/make-mode.el +++ b/lisp/progmodes/make-mode.el | |||
| @@ -111,7 +111,8 @@ | |||
| 111 | '((t (:underline t))) | 111 | '((t (:underline t))) |
| 112 | "Face to use for additionally highlighting rule targets in Font-Lock mode." | 112 | "Face to use for additionally highlighting rule targets in Font-Lock mode." |
| 113 | :group 'faces | 113 | :group 'faces |
| 114 | :group 'makefile) | 114 | :group 'makefile |
| 115 | :version "22.1") | ||
| 115 | 116 | ||
| 116 | (defface makefile-shell-face | 117 | (defface makefile-shell-face |
| 117 | '((((class color) (background light)) (:background "seashell1")) | 118 | '((((class color) (background light)) (:background "seashell1")) |
| @@ -119,7 +120,8 @@ | |||
| 119 | (t (:reverse-video t))) | 120 | (t (:reverse-video t))) |
| 120 | "Face to use for additionally highlighting Shell commands in Font-Lock mode." | 121 | "Face to use for additionally highlighting Shell commands in Font-Lock mode." |
| 121 | :group 'faces | 122 | :group 'faces |
| 122 | :group 'makefile) | 123 | :group 'makefile |
| 124 | :version "22.1") | ||
| 123 | 125 | ||
| 124 | (defface makefile-makepp-perl-face | 126 | (defface makefile-makepp-perl-face |
| 125 | '((((class color) (background light)) (:background "LightBlue1")) ; Camel Book | 127 | '((((class color) (background light)) (:background "LightBlue1")) ; Camel Book |
| @@ -127,7 +129,8 @@ | |||
| 127 | (t (:reverse-video t))) | 129 | (t (:reverse-video t))) |
| 128 | "Face to use for additionally highlighting Perl code in Font-Lock mode." | 130 | "Face to use for additionally highlighting Perl code in Font-Lock mode." |
| 129 | :group 'faces | 131 | :group 'faces |
| 130 | :group 'makefile) | 132 | :group 'makefile |
| 133 | :version "22.1") | ||
| 131 | 134 | ||
| 132 | (defcustom makefile-browser-buffer-name "*Macros and Targets*" | 135 | (defcustom makefile-browser-buffer-name "*Macros and Targets*" |
| 133 | "*Name of the macro- and target browser buffer." | 136 | "*Name of the macro- and target browser buffer." |
| @@ -262,18 +265,33 @@ not be enclosed in { } or ( )." | |||
| 262 | "^ *\\(\\(?: *\\$\\(?:[({]\\(?:\\$\\(?:[({]\\(?:\\$\\(?:[^({]\\|.[^\n$#})]+?[})]\\)\\|[^\n$#)}]\\)+?[})]\\|[^({]\\)\\|[^\n$#)}]\\)+?[})]\\|[^({]\\)\\| *[^ \n$#:=]+\\)+?\\)[ \t]*\\(:\\)\\(?:[ \t]*$\\|[^=\n]\\(?:[^#\n]*?;[ \t]*\\(.+\\)\\)?\\)" | 265 | "^ *\\(\\(?: *\\$\\(?:[({]\\(?:\\$\\(?:[({]\\(?:\\$\\(?:[^({]\\|.[^\n$#})]+?[})]\\)\\|[^\n$#)}]\\)+?[})]\\|[^({]\\)\\|[^\n$#)}]\\)+?[})]\\|[^({]\\)\\| *[^ \n$#:=]+\\)+?\\)[ \t]*\\(:\\)\\(?:[ \t]*$\\|[^=\n]\\(?:[^#\n]*?;[ \t]*\\(.+\\)\\)?\\)" |
| 263 | "Regex used to find dependency lines in a makefile.") | 266 | "Regex used to find dependency lines in a makefile.") |
| 264 | 267 | ||
| 268 | (defconst makefile-bsdmake-dependency-regex | ||
| 269 | (progn (string-match (regexp-quote "\\(:\\)") makefile-dependency-regex) | ||
| 270 | (replace-match "\\([:!]\\)" t t makefile-dependency-regex)) | ||
| 271 | "Regex used to find dependency lines in a BSD makefile.") | ||
| 272 | |||
| 265 | (defvar makefile-dependency-skip "^:" | 273 | (defvar makefile-dependency-skip "^:" |
| 266 | "Characters to skip to find a line that might be a dependency.") | 274 | "Characters to skip to find a line that might be a dependency.") |
| 267 | 275 | ||
| 268 | (defvar makefile-rule-action-regex | 276 | (defvar makefile-rule-action-regex |
| 269 | "^\t[ \t]*\\([-@]*\\)[ \t]*\\(\\(?:.+\\\\\n\\)*.+\\)" | 277 | "^\t[ \t]*\\([-@]*\\)[ \t]*\\(\\(?:.*\\\\\n\\)*.*\\)" |
| 270 | "Regex used to highlight rule action lines in font lock mode.") | 278 | "Regex used to highlight rule action lines in font lock mode.") |
| 271 | 279 | ||
| 280 | (defconst makefile-makepp-rule-action-regex | ||
| 281 | ;; Don't care about initial tab, but I don't know how to font-lock correctly without. | ||
| 282 | "^\t[ \t]*\\(\\(?:\\(?:noecho\\|ignore[-_]error\\|[-@]+\\)[ \t]*\\)*\\)\\(\\(&\\S +\\)?\\(?:.*\\\\\n\\)*.*\\)" | ||
| 283 | "Regex used to highlight makepp rule action lines in font lock mode.") | ||
| 284 | |||
| 285 | (defconst makefile-bsdmake-rule-action-regex | ||
| 286 | (progn (string-match "-@" makefile-rule-action-regex) | ||
| 287 | (replace-match "-+@" t t makefile-rule-action-regex)) | ||
| 288 | "Regex used to highlight BSD rule action lines in font lock mode.") | ||
| 289 | |||
| 272 | ;; Note that the first and second subexpression is used by font lock. Note | 290 | ;; Note that the first and second subexpression is used by font lock. Note |
| 273 | ;; that if you change this regexp you might have to fix the imenu index in | 291 | ;; that if you change this regexp you might have to fix the imenu index in |
| 274 | ;; makefile-imenu-generic-expression. | 292 | ;; makefile-imenu-generic-expression. |
| 275 | (defconst makefile-macroassign-regex | 293 | (defconst makefile-macroassign-regex |
| 276 | "^ *\\([^ \n\t][^:#= \t\n]*\\)[ \t]*\\(?:!=[ \t]*\\(\\(?:.+\\\\\n\\)*.+\\)\\|[*:+]?[:?]?=[ \t]*\\(\\(?:.+\\\\\n\\)*.+\\)\\)" | 294 | "^ *\\([^ \n\t][^:#= \t\n]*\\)[ \t]*\\(?:!=[ \t]*\\(\\(?:.+\\\\\n\\)*.+\\)\\|[*:+]?[:?]?=[ \t]*\\(\\(?:.*\\\\\n\\)*.*\\)\\)" |
| 277 | "Regex used to find macro assignment lines in a makefile.") | 295 | "Regex used to find macro assignment lines in a makefile.") |
| 278 | 296 | ||
| 279 | (defconst makefile-var-use-regex | 297 | (defconst makefile-var-use-regex |
| @@ -420,7 +438,7 @@ not be enclosed in { } or ( )." | |||
| 420 | nil | 438 | nil |
| 421 | "^\\(?: [ \t]*\\)?\\(?:and[ \t]+\\|else[ \t]+\\|or[ \t]+\\)?if\\(n\\)\\(?:def\\|eq\\|sys\\)\\>" | 439 | "^\\(?: [ \t]*\\)?\\(?:and[ \t]+\\|else[ \t]+\\|or[ \t]+\\)?if\\(n\\)\\(?:def\\|eq\\|sys\\)\\>" |
| 422 | 440 | ||
| 423 | '("[^$]\\(\\$[({]\\(?:target\\|output\\)s?\\_>.*?[})]\\)" | 441 | '("[^$]\\(\\$[({]\\(?:output\\|stem\\|target\\)s?\\_>.*?[})]\\)" |
| 424 | 1 'makefile-targets-face prepend) | 442 | 1 'makefile-targets-face prepend) |
| 425 | 443 | ||
| 426 | ;; Colon modifier keywords. | 444 | ;; Colon modifier keywords. |
| @@ -849,10 +867,8 @@ Makefile mode can be configured by modifying the following variables: | |||
| 849 | ;;;###autoload | 867 | ;;;###autoload |
| 850 | (define-derived-mode makefile-makepp-mode makefile-mode "Makeppfile" | 868 | (define-derived-mode makefile-makepp-mode makefile-mode "Makeppfile" |
| 851 | "An adapted `makefile-mode' that knows about makepp." | 869 | "An adapted `makefile-mode' that knows about makepp." |
| 852 | (set (make-local-variable 'makefile-rule-action-regex) | 870 | (set (make-local-variable 'makefile-rule-action-regex) |
| 853 | ;; Don't care about initial tab, but I don't know how to font-lock correctly without. | 871 | makefile-makepp-rule-action-regex) |
| 854 | "^\t[ \t]*\\(\\(?:\\(?:noecho\\|ignore[-_]error\\|[-@]+\\)[ \t]*\\)*\\)\\(\\(&\\S +\\)?\\(?:.+\\\\\n\\)*.+\\)") | ||
| 855 | |||
| 856 | (setq font-lock-defaults | 872 | (setq font-lock-defaults |
| 857 | `(makefile-makepp-font-lock-keywords ,@(cdr font-lock-defaults)) | 873 | `(makefile-makepp-font-lock-keywords ,@(cdr font-lock-defaults)) |
| 858 | imenu-generic-expression | 874 | imenu-generic-expression |
| @@ -863,11 +879,10 @@ Makefile mode can be configured by modifying the following variables: | |||
| 863 | (define-derived-mode makefile-bsdmake-mode makefile-mode "BSDmakefile" | 879 | (define-derived-mode makefile-bsdmake-mode makefile-mode "BSDmakefile" |
| 864 | "An adapted `makefile-mode' that knows about BSD make." | 880 | "An adapted `makefile-mode' that knows about BSD make." |
| 865 | (set (make-local-variable 'makefile-dependency-regex) | 881 | (set (make-local-variable 'makefile-dependency-regex) |
| 866 | ;; Identical to default, except allows `!' instead of `:'. | 882 | makefile-bsdmake-dependency-regex) |
| 867 | "^ *\\(\\(?: *\\$\\(?:[({]\\(?:\\$\\(?:[({]\\(?:\\$\\(?:[^({]\\|.[^\n$#})]+?[})]\\)\\|[^\n$#)}]\\)+?[})]\\|[^({]\\)\\|[^\n$#)}]\\)+?[})]\\|[^({]\\)\\| *[^ \n$#:=]+\\)+?\\)[ \t]*\\([:!]\\)\\(?:[ \t]*$\\|[^=\n]\\(?:[^#\n]*?;[ \t]*\\(.+\\)\\)?\\)") | ||
| 868 | (set (make-local-variable 'makefile-dependency-skip) "^:!") | 883 | (set (make-local-variable 'makefile-dependency-skip) "^:!") |
| 869 | (set (make-local-variable 'makefile-rule-action-regex) | 884 | (set (make-local-variable 'makefile-rule-action-regex) |
| 870 | "^\t[ \t]*\\([-+@]*\\)[ \t]*\\(\\(?:.+\\\\\n\\)*.+\\)") | 885 | makefile-bsdmake-rule-action-regex) |
| 871 | (setq font-lock-defaults | 886 | (setq font-lock-defaults |
| 872 | `(makefile-bsdmake-font-lock-keywords ,@(cdr font-lock-defaults)))) | 887 | `(makefile-bsdmake-font-lock-keywords ,@(cdr font-lock-defaults)))) |
| 873 | 888 | ||
diff --git a/lisp/progmodes/meta-mode.el b/lisp/progmodes/meta-mode.el index 7bf9921b2ee..3d77de8f182 100644 --- a/lisp/progmodes/meta-mode.el +++ b/lisp/progmodes/meta-mode.el | |||
| @@ -998,7 +998,7 @@ Turning on Metafont mode calls the value of the variables | |||
| 998 | (setq meta-complete-list | 998 | (setq meta-complete-list |
| 999 | (list (list "\\<\\(\\sw+\\)" 1 'meta-symbol-list) | 999 | (list (list "\\<\\(\\sw+\\)" 1 'meta-symbol-list) |
| 1000 | (list "" 'ispell-complete-word))) | 1000 | (list "" 'ispell-complete-word))) |
| 1001 | (run-hooks 'meta-common-mode-hook 'metafont-mode-hook)) | 1001 | (run-mode-hooks 'meta-common-mode-hook 'metafont-mode-hook)) |
| 1002 | 1002 | ||
| 1003 | ;;;###autoload | 1003 | ;;;###autoload |
| 1004 | (defun metapost-mode () | 1004 | (defun metapost-mode () |
| @@ -1023,7 +1023,7 @@ Turning on MetaPost mode calls the value of the variable | |||
| 1023 | (setq meta-complete-list | 1023 | (setq meta-complete-list |
| 1024 | (list (list "\\<\\(\\sw+\\)" 1 'meta-symbol-list) | 1024 | (list (list "\\<\\(\\sw+\\)" 1 'meta-symbol-list) |
| 1025 | (list "" 'ispell-complete-word))) | 1025 | (list "" 'ispell-complete-word))) |
| 1026 | (run-hooks 'meta-common-mode-hook 'metapost-mode-hook)) | 1026 | (run-mode-hooks 'meta-common-mode-hook 'metapost-mode-hook)) |
| 1027 | 1027 | ||
| 1028 | 1028 | ||
| 1029 | ;;; Just in case ... | 1029 | ;;; Just in case ... |
diff --git a/lisp/progmodes/modula2.el b/lisp/progmodes/modula2.el index 0fa46bee0f9..5fd3dbcb11b 100644 --- a/lisp/progmodes/modula2.el +++ b/lisp/progmodes/modula2.el | |||
| @@ -172,7 +172,7 @@ followed by the first character of the construct. | |||
| 172 | ;; Obsoleted by Emacs 19.35 parse-partial-sexp's COMMENTSTOP. | 172 | ;; Obsoleted by Emacs 19.35 parse-partial-sexp's COMMENTSTOP. |
| 173 | ;(font-lock-comment-start-regexp . "(\\*") | 173 | ;(font-lock-comment-start-regexp . "(\\*") |
| 174 | )) | 174 | )) |
| 175 | (run-hooks 'm2-mode-hook)) | 175 | (run-mode-hooks 'm2-mode-hook)) |
| 176 | 176 | ||
| 177 | ;; Regexps written with help from Ron Forrester <ron@orcad.com> | 177 | ;; Regexps written with help from Ron Forrester <ron@orcad.com> |
| 178 | ;; and Spencer Allain <sallain@teknowledge.com>. | 178 | ;; and Spencer Allain <sallain@teknowledge.com>. |
diff --git a/lisp/progmodes/octave-inf.el b/lisp/progmodes/octave-inf.el index 265cf6c049b..250d00171f2 100644 --- a/lisp/progmodes/octave-inf.el +++ b/lisp/progmodes/octave-inf.el | |||
| @@ -158,7 +158,7 @@ Entry to this mode successively runs the hooks `comint-mode-hook' and | |||
| 158 | inferior-octave-dynamic-complete-functions) | 158 | inferior-octave-dynamic-complete-functions) |
| 159 | (comint-read-input-ring t) | 159 | (comint-read-input-ring t) |
| 160 | 160 | ||
| 161 | (run-hooks 'inferior-octave-mode-hook)) | 161 | (run-mode-hooks 'inferior-octave-mode-hook)) |
| 162 | 162 | ||
| 163 | ;;;###autoload | 163 | ;;;###autoload |
| 164 | (defun inferior-octave (&optional arg) | 164 | (defun inferior-octave (&optional arg) |
diff --git a/lisp/progmodes/octave-mod.el b/lisp/progmodes/octave-mod.el index 281edfd693e..35d5bd897c9 100644 --- a/lisp/progmodes/octave-mod.el +++ b/lisp/progmodes/octave-mod.el | |||
| @@ -555,7 +555,7 @@ including a reproducible test case and send the message." | |||
| 555 | 555 | ||
| 556 | (octave-add-octave-menu) | 556 | (octave-add-octave-menu) |
| 557 | (octave-initialize-completions) | 557 | (octave-initialize-completions) |
| 558 | (run-hooks 'octave-mode-hook)) | 558 | (run-mode-hooks 'octave-mode-hook)) |
| 559 | 559 | ||
| 560 | ;;; Miscellaneous useful functions | 560 | ;;; Miscellaneous useful functions |
| 561 | (defun octave-describe-major-mode () | 561 | (defun octave-describe-major-mode () |
diff --git a/lisp/progmodes/pascal.el b/lisp/progmodes/pascal.el index 6292fd36a67..e4d36244537 100644 --- a/lisp/progmodes/pascal.el +++ b/lisp/progmodes/pascal.el | |||
| @@ -383,7 +383,7 @@ no args, if that value is non-nil." | |||
| 383 | (make-local-variable 'imenu-generic-expression) | 383 | (make-local-variable 'imenu-generic-expression) |
| 384 | (setq imenu-generic-expression pascal-imenu-generic-expression) | 384 | (setq imenu-generic-expression pascal-imenu-generic-expression) |
| 385 | (setq imenu-case-fold-search t) | 385 | (setq imenu-case-fold-search t) |
| 386 | (run-hooks 'pascal-mode-hook)) | 386 | (run-mode-hooks 'pascal-mode-hook)) |
| 387 | 387 | ||
| 388 | 388 | ||
| 389 | 389 | ||
diff --git a/lisp/progmodes/sh-script.el b/lisp/progmodes/sh-script.el index 87915933862..7dc695f24bf 100644 --- a/lisp/progmodes/sh-script.el +++ b/lisp/progmodes/sh-script.el | |||
| @@ -1392,7 +1392,7 @@ with your script for an edit-interpret-debug cycle." | |||
| 1392 | (string-match "\\.m?spec\\'" buffer-file-name)) | 1392 | (string-match "\\.m?spec\\'" buffer-file-name)) |
| 1393 | "rpm"))))) | 1393 | "rpm"))))) |
| 1394 | (sh-set-shell (or interpreter sh-shell-file) nil nil)) | 1394 | (sh-set-shell (or interpreter sh-shell-file) nil nil)) |
| 1395 | (run-hooks 'sh-mode-hook)) | 1395 | (run-mode-hooks 'sh-mode-hook)) |
| 1396 | 1396 | ||
| 1397 | ;;;###autoload | 1397 | ;;;###autoload |
| 1398 | (defalias 'shell-script-mode 'sh-mode) | 1398 | (defalias 'shell-script-mode 'sh-mode) |
diff --git a/lisp/progmodes/sql.el b/lisp/progmodes/sql.el index 902cd920ead..add4493e5f8 100644 --- a/lisp/progmodes/sql.el +++ b/lisp/progmodes/sql.el | |||
| @@ -2249,7 +2249,7 @@ you must tell Emacs. Here's how to do that in your `~/.emacs' file: | |||
| 2249 | (setq local-abbrev-table sql-mode-abbrev-table) | 2249 | (setq local-abbrev-table sql-mode-abbrev-table) |
| 2250 | (setq abbrev-all-caps 1) | 2250 | (setq abbrev-all-caps 1) |
| 2251 | ;; Run hook | 2251 | ;; Run hook |
| 2252 | (run-hooks 'sql-mode-hook) | 2252 | (run-mode-hooks 'sql-mode-hook) |
| 2253 | ;; Catch changes to sql-product and highlight accordingly | 2253 | ;; Catch changes to sql-product and highlight accordingly |
| 2254 | (sql-highlight-product) | 2254 | (sql-highlight-product) |
| 2255 | (add-hook 'hack-local-variables-hook 'sql-highlight-product t t)) | 2255 | (add-hook 'hack-local-variables-hook 'sql-highlight-product t t)) |
| @@ -2367,7 +2367,7 @@ you entered, right above the output it created. | |||
| 2367 | (make-local-variable 'sql-input-ring-separator) | 2367 | (make-local-variable 'sql-input-ring-separator) |
| 2368 | (make-local-variable 'sql-input-ring-file-name) | 2368 | (make-local-variable 'sql-input-ring-file-name) |
| 2369 | ;; Run hook. | 2369 | ;; Run hook. |
| 2370 | (run-hooks 'sql-interactive-mode-hook) | 2370 | (run-mode-hooks 'sql-interactive-mode-hook) |
| 2371 | ;; Set comint based on user overrides. | 2371 | ;; Set comint based on user overrides. |
| 2372 | (setq comint-prompt-regexp sql-prompt-regexp) | 2372 | (setq comint-prompt-regexp sql-prompt-regexp) |
| 2373 | (setq left-margin sql-prompt-length) | 2373 | (setq left-margin sql-prompt-length) |
diff --git a/lisp/progmodes/vhdl-mode.el b/lisp/progmodes/vhdl-mode.el index f840ef356d9..ebccb1bf5bf 100644 --- a/lisp/progmodes/vhdl-mode.el +++ b/lisp/progmodes/vhdl-mode.el | |||
| @@ -127,7 +127,7 @@ | |||
| 127 | "Non-nil if XEmacs is used.") | 127 | "Non-nil if XEmacs is used.") |
| 128 | ;; Emacs 21 handling | 128 | ;; Emacs 21 handling |
| 129 | (defconst vhdl-emacs-21 (and (= emacs-major-version 21) (not vhdl-xemacs)) | 129 | (defconst vhdl-emacs-21 (and (= emacs-major-version 21) (not vhdl-xemacs)) |
| 130 | "Non-nil if GNU Emacs 21 is used.") | 130 | "Non-nil if Emacs 21 is used.") |
| 131 | 131 | ||
| 132 | 132 | ||
| 133 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | 133 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
| @@ -4568,8 +4568,7 @@ Key bindings: | |||
| 4568 | (set (make-local-variable 'indent-line-function) 'vhdl-indent-line) | 4568 | (set (make-local-variable 'indent-line-function) 'vhdl-indent-line) |
| 4569 | (set (make-local-variable 'comment-start) "--") | 4569 | (set (make-local-variable 'comment-start) "--") |
| 4570 | (set (make-local-variable 'comment-end) "") | 4570 | (set (make-local-variable 'comment-end) "") |
| 4571 | (when vhdl-emacs-21 | 4571 | (set (make-local-variable 'comment-padding) "") |
| 4572 | (set (make-local-variable 'comment-padding) "")) | ||
| 4573 | (set (make-local-variable 'comment-column) vhdl-inline-comment-column) | 4572 | (set (make-local-variable 'comment-column) vhdl-inline-comment-column) |
| 4574 | (set (make-local-variable 'end-comment-column) vhdl-end-comment-column) | 4573 | (set (make-local-variable 'end-comment-column) vhdl-end-comment-column) |
| 4575 | (set (make-local-variable 'comment-start-skip) "--+\\s-*") | 4574 | (set (make-local-variable 'comment-start-skip) "--+\\s-*") |
| @@ -4622,7 +4621,7 @@ Key bindings: | |||
| 4622 | (if noninteractive "" " See menu for documentation and release notes.")) | 4621 | (if noninteractive "" " See menu for documentation and release notes.")) |
| 4623 | 4622 | ||
| 4624 | ;; run hooks | 4623 | ;; run hooks |
| 4625 | (run-hooks 'vhdl-mode-hook)) | 4624 | (run-mode-hooks 'vhdl-mode-hook)) |
| 4626 | 4625 | ||
| 4627 | (defun vhdl-activate-customizations () | 4626 | (defun vhdl-activate-customizations () |
| 4628 | "Activate all customizations on local variables." | 4627 | "Activate all customizations on local variables." |
| @@ -7484,7 +7483,13 @@ end of line, do nothing in comments and strings." | |||
| 7484 | (while (re-search-forward "\\(--.*\n\\|\"[^\"\n]*[\"\n]\\)\\|\\(\\([^/:<>=]\\)\\(:\\|=\\|<\\|>\\|:=\\|<=\\|>=\\|=>\\|/=\\)\\([^=>]\\|$\\)\\)" end t) | 7483 | (while (re-search-forward "\\(--.*\n\\|\"[^\"\n]*[\"\n]\\)\\|\\(\\([^/:<>=]\\)\\(:\\|=\\|<\\|>\\|:=\\|<=\\|>=\\|=>\\|/=\\)\\([^=>]\\|$\\)\\)" end t) |
| 7485 | (if (match-string 1) | 7484 | (if (match-string 1) |
| 7486 | (goto-char (match-end 1)) | 7485 | (goto-char (match-end 1)) |
| 7487 | (replace-match "\\3 \\4 \\5") | 7486 | (save-excursion |
| 7487 | (goto-char (match-beginning 4)) | ||
| 7488 | (unless (eq (preceding-char) ?\ ) | ||
| 7489 | (insert " ")) | ||
| 7490 | (goto-char (match-end 4)) | ||
| 7491 | (unless (eq (following-char) ?\ ) | ||
| 7492 | (insert " "))) | ||
| 7488 | (goto-char (match-end 4)))) | 7493 | (goto-char (match-end 4)))) |
| 7489 | ;; eliminate multiple spaces and spaces at end of line | 7494 | ;; eliminate multiple spaces and spaces at end of line |
| 7490 | (goto-char beg) | 7495 | (goto-char beg) |
| @@ -7540,7 +7545,7 @@ buffer." | |||
| 7540 | (interactive "r\np") | 7545 | (interactive "r\np") |
| 7541 | (save-excursion | 7546 | (save-excursion |
| 7542 | (goto-char beg) | 7547 | (goto-char beg) |
| 7543 | (let ((margin (if interactive (current-indentation) (current-column)))) | 7548 | (let ((margin (if arg (current-indentation) (current-column)))) |
| 7544 | (goto-char end) | 7549 | (goto-char end) |
| 7545 | (setq end (point-marker)) | 7550 | (setq end (point-marker)) |
| 7546 | ;; remove inline comments, newlines and whitespace | 7551 | ;; remove inline comments, newlines and whitespace |
| @@ -12055,8 +12060,7 @@ File statistics: \"%s\"\n\ | |||
| 12055 | # statements : %5d\n\ | 12060 | # statements : %5d\n\ |
| 12056 | # code lines : %5d\n\ | 12061 | # code lines : %5d\n\ |
| 12057 | # total lines : %5d\n\ " | 12062 | # total lines : %5d\n\ " |
| 12058 | (buffer-file-name) no-stats no-code-lines no-lines) | 12063 | (buffer-file-name) no-stats no-code-lines no-lines))) |
| 12059 | (unless vhdl-emacs-21 (vhdl-show-messages)))) | ||
| 12060 | 12064 | ||
| 12061 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | 12065 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
| 12062 | ;; Help functions | 12066 | ;; Help functions |
diff --git a/lisp/progmodes/which-func.el b/lisp/progmodes/which-func.el index d329e234025..1fa37532ab0 100644 --- a/lisp/progmodes/which-func.el +++ b/lisp/progmodes/which-func.el | |||
| @@ -196,7 +196,7 @@ It creates the Imenu index for the buffer, if necessary." | |||
| 196 | (puthash window current which-func-table) | 196 | (puthash window current which-func-table) |
| 197 | (force-mode-line-update))) | 197 | (force-mode-line-update))) |
| 198 | (error | 198 | (error |
| 199 | (which-func-mode -1) | 199 | (setq which-func-mode nil) |
| 200 | (error "Error in which-func-update: %s" info)))))) | 200 | (error "Error in which-func-update: %s" info)))))) |
| 201 | 201 | ||
| 202 | ;;;###autoload | 202 | ;;;###autoload |
diff --git a/lisp/progmodes/xscheme.el b/lisp/progmodes/xscheme.el index bf1279da8a0..8ee791affe1 100644 --- a/lisp/progmodes/xscheme.el +++ b/lisp/progmodes/xscheme.el | |||
| @@ -338,7 +338,7 @@ with no args, if that value is non-nil. | |||
| 338 | (setq xscheme-previous-process-state (cons nil nil))))))) | 338 | (setq xscheme-previous-process-state (cons nil nil))))))) |
| 339 | (scheme-interaction-mode-initialize) | 339 | (scheme-interaction-mode-initialize) |
| 340 | (scheme-mode-variables) | 340 | (scheme-mode-variables) |
| 341 | (run-hooks 'scheme-mode-hook 'scheme-interaction-mode-hook)) | 341 | (run-mode-hooks 'scheme-mode-hook 'scheme-interaction-mode-hook)) |
| 342 | 342 | ||
| 343 | (defun exit-scheme-interaction-mode () | 343 | (defun exit-scheme-interaction-mode () |
| 344 | "Take buffer out of scheme interaction mode" | 344 | "Take buffer out of scheme interaction mode" |
diff --git a/lisp/recentf.el b/lisp/recentf.el index cf61b688eb5..bb462bc71d7 100644 --- a/lisp/recentf.el +++ b/lisp/recentf.el | |||
| @@ -76,7 +76,7 @@ See the command `recentf-save-list'." | |||
| 76 | :type 'file) | 76 | :type 'file) |
| 77 | 77 | ||
| 78 | (defcustom recentf-exclude nil | 78 | (defcustom recentf-exclude nil |
| 79 | "*List of regexps and predicates for filenames excluded from the recent list. | 79 | "*List of regexps and predicates for filenames excluded from the recent list. |
| 80 | When a filename matches any of the regexps or satisfies any of the | 80 | When a filename matches any of the regexps or satisfies any of the |
| 81 | predicates it is excluded from the recent list. | 81 | predicates it is excluded from the recent list. |
| 82 | A predicate is a function that is passed a filename to check and that | 82 | A predicate is a function that is passed a filename to check and that |
diff --git a/lisp/replace.el b/lisp/replace.el index c9c70b59de5..ba3d5fcfbf4 100644 --- a/lisp/replace.el +++ b/lisp/replace.el | |||
| @@ -693,7 +693,7 @@ Alternatively, click \\[occur-mode-mouse-goto] on an item to go to it. | |||
| 693 | (make-local-variable 'occur-revert-arguments) | 693 | (make-local-variable 'occur-revert-arguments) |
| 694 | (add-hook 'change-major-mode-hook 'font-lock-defontify nil t) | 694 | (add-hook 'change-major-mode-hook 'font-lock-defontify nil t) |
| 695 | (setq next-error-function 'occur-next-error) | 695 | (setq next-error-function 'occur-next-error) |
| 696 | (run-hooks 'occur-mode-hook)) | 696 | (run-mode-hooks 'occur-mode-hook)) |
| 697 | 697 | ||
| 698 | (defun occur-revert-function (ignore1 ignore2) | 698 | (defun occur-revert-function (ignore1 ignore2) |
| 699 | "Handle `revert-buffer' for Occur mode buffers." | 699 | "Handle `revert-buffer' for Occur mode buffers." |
diff --git a/lisp/saveplace.el b/lisp/saveplace.el index 9dc7b858e37..34c88a89948 100644 --- a/lisp/saveplace.el +++ b/lisp/saveplace.el | |||
| @@ -222,7 +222,8 @@ may have changed\) back to `save-place-alist'." | |||
| 222 | (t | 222 | (t |
| 223 | t)))) | 223 | t)))) |
| 224 | (condition-case nil | 224 | (condition-case nil |
| 225 | (write-file file) | 225 | ;; Don't use write-file; we don't want this buffer to visit it. |
| 226 | (write-region (point-min) (point-max) file) | ||
| 226 | (file-error (message "Can't write %s" file))) | 227 | (file-error (message "Can't write %s" file))) |
| 227 | (kill-buffer (current-buffer)) | 228 | (kill-buffer (current-buffer)) |
| 228 | (message "Saving places to %s...done" file))))) | 229 | (message "Saving places to %s...done" file))))) |
diff --git a/lisp/ses.el b/lisp/ses.el index 502acf868dc..d01a8307ffd 100644 --- a/lisp/ses.el +++ b/lisp/ses.el | |||
| @@ -1552,7 +1552,7 @@ These are active only in the minibuffer, when entering or editing a formula: | |||
| 1552 | (setq ses--deferred-narrow 'ses-mode) | 1552 | (setq ses--deferred-narrow 'ses-mode) |
| 1553 | (1value (add-hook 'post-command-hook 'ses-command-hook nil t)) | 1553 | (1value (add-hook 'post-command-hook 'ses-command-hook nil t)) |
| 1554 | (run-with-idle-timer 0.01 nil 'ses-command-hook) | 1554 | (run-with-idle-timer 0.01 nil 'ses-command-hook) |
| 1555 | (run-hooks 'ses-mode-hook))) | 1555 | (run-mode-hooks 'ses-mode-hook))) |
| 1556 | 1556 | ||
| 1557 | (put 'ses-mode 'mode-class 'special) | 1557 | (put 'ses-mode 'mode-class 'special) |
| 1558 | 1558 | ||
diff --git a/lisp/simple.el b/lisp/simple.el index 240896b5eef..016c48924e0 100644 --- a/lisp/simple.el +++ b/lisp/simple.el | |||
| @@ -920,21 +920,21 @@ in *Help* buffer. See also the command `describe-char'." | |||
| 920 | (defvar read-expression-history nil) | 920 | (defvar read-expression-history nil) |
| 921 | 921 | ||
| 922 | (defcustom eval-expression-print-level 4 | 922 | (defcustom eval-expression-print-level 4 |
| 923 | "*Value to use for `print-level' when printing value in `eval-expression'. | 923 | "Value for `print-level' while printing value in `eval-expression'. |
| 924 | A value of nil means no limit." | 924 | A value of nil means no limit." |
| 925 | :group 'lisp | 925 | :group 'lisp |
| 926 | :type '(choice (const :tag "No Limit" nil) integer) | 926 | :type '(choice (const :tag "No Limit" nil) integer) |
| 927 | :version "21.1") | 927 | :version "21.1") |
| 928 | 928 | ||
| 929 | (defcustom eval-expression-print-length 12 | 929 | (defcustom eval-expression-print-length 12 |
| 930 | "*Value to use for `print-length' when printing value in `eval-expression'. | 930 | "Value for `print-length' while printing value in `eval-expression'. |
| 931 | A value of nil means no limit." | 931 | A value of nil means no limit." |
| 932 | :group 'lisp | 932 | :group 'lisp |
| 933 | :type '(choice (const :tag "No Limit" nil) integer) | 933 | :type '(choice (const :tag "No Limit" nil) integer) |
| 934 | :version "21.1") | 934 | :version "21.1") |
| 935 | 935 | ||
| 936 | (defcustom eval-expression-debug-on-error t | 936 | (defcustom eval-expression-debug-on-error t |
| 937 | "*Non-nil means set `debug-on-error' when evaluating in `eval-expression'. | 937 | "If non-nil set `debug-on-error' to t in `eval-expression'. |
| 938 | If nil, don't change the value of `debug-on-error'." | 938 | If nil, don't change the value of `debug-on-error'." |
| 939 | :group 'lisp | 939 | :group 'lisp |
| 940 | :type 'boolean | 940 | :type 'boolean |
| @@ -2247,7 +2247,7 @@ is nil, the buffer substring is returned unaltered. | |||
| 2247 | If DELETE is non-nil, the text between BEG and END is deleted | 2247 | If DELETE is non-nil, the text between BEG and END is deleted |
| 2248 | from the buffer. | 2248 | from the buffer. |
| 2249 | 2249 | ||
| 2250 | Point is temporarily set to BEG before caling | 2250 | Point is temporarily set to BEG before calling |
| 2251 | `buffer-substring-filters', in case the functions need to know | 2251 | `buffer-substring-filters', in case the functions need to know |
| 2252 | where the text came from. | 2252 | where the text came from. |
| 2253 | 2253 | ||
| @@ -3351,25 +3351,27 @@ Outline mode sets this." | |||
| 3351 | (let ((forward (> arg 0)) | 3351 | (let ((forward (> arg 0)) |
| 3352 | (part (nth 2 (pos-visible-in-window-p (point) nil t)))) | 3352 | (part (nth 2 (pos-visible-in-window-p (point) nil t)))) |
| 3353 | (if (and (consp part) | 3353 | (if (and (consp part) |
| 3354 | (> (setq part (if forward (cdr part) (car part))) 0)) | 3354 | (> (if forward (cdr part) (car part)) 0)) |
| 3355 | (set-window-vscroll nil | 3355 | (set-window-vscroll nil |
| 3356 | (if forward | 3356 | (if forward |
| 3357 | (+ (window-vscroll nil t) | 3357 | (+ (window-vscroll nil t) |
| 3358 | (min part | 3358 | (min (cdr part) |
| 3359 | (* (frame-char-height) arg))) | 3359 | (* (frame-char-height) arg))) |
| 3360 | (max 0 | 3360 | (max 0 |
| 3361 | (- (window-vscroll nil t) | 3361 | (- (window-vscroll nil t) |
| 3362 | (min part | 3362 | (min (car part) |
| 3363 | (* (frame-char-height) (- arg)))))) | 3363 | (* (frame-char-height) (- arg)))))) |
| 3364 | t) | 3364 | t) |
| 3365 | (set-window-vscroll nil 0) | 3365 | (set-window-vscroll nil 0) |
| 3366 | (when (line-move-1 arg noerror to-end) | 3366 | (when (line-move-1 arg noerror to-end) |
| 3367 | (sit-for 0) | 3367 | (when (not forward) |
| 3368 | (if (and (not forward) | 3368 | ;; Update display before calling pos-visible-in-window-p, |
| 3369 | (setq part (nth 2 (pos-visible-in-window-p | 3369 | ;; because it depends on window-start being up-to-date. |
| 3370 | (line-beginning-position) nil t))) | 3370 | (sit-for 0) |
| 3371 | (> (cdr part) 0)) | 3371 | (if (and (setq part (nth 2 (pos-visible-in-window-p |
| 3372 | (set-window-vscroll nil (cdr part) t)) | 3372 | (line-beginning-position) nil t))) |
| 3373 | (> (cdr part) 0)) | ||
| 3374 | (set-window-vscroll nil (cdr part) t))) | ||
| 3373 | t))) | 3375 | t))) |
| 3374 | (line-move-1 arg noerror to-end))) | 3376 | (line-move-1 arg noerror to-end))) |
| 3375 | 3377 | ||
| @@ -4762,7 +4764,7 @@ Use \\<completion-list-mode-map>\\[mouse-choose-completion] to select one\ | |||
| 4762 | (setq major-mode 'completion-list-mode) | 4764 | (setq major-mode 'completion-list-mode) |
| 4763 | (make-local-variable 'completion-base-size) | 4765 | (make-local-variable 'completion-base-size) |
| 4764 | (setq completion-base-size nil) | 4766 | (setq completion-base-size nil) |
| 4765 | (run-hooks 'completion-list-mode-hook)) | 4767 | (run-mode-hooks 'completion-list-mode-hook)) |
| 4766 | 4768 | ||
| 4767 | (defun completion-list-mode-finish () | 4769 | (defun completion-list-mode-finish () |
| 4768 | "Finish setup of the completions buffer. | 4770 | "Finish setup of the completions buffer. |
diff --git a/lisp/skeleton.el b/lisp/skeleton.el index e843ef9f02d..d4caca3ca42 100644 --- a/lisp/skeleton.el +++ b/lisp/skeleton.el | |||
| @@ -557,7 +557,7 @@ symmetrical ones, and the same character twice for the others." | |||
| 557 | ;; (aset map i nil) | 557 | ;; (aset map i nil) |
| 558 | ;; (aset map (+ i 128) nil) | 558 | ;; (aset map (+ i 128) nil) |
| 559 | ;; (setq i (1+ i)))) | 559 | ;; (setq i (1+ i)))) |
| 560 | ;; (run-hooks 'mirror-mode-hook)) | 560 | ;; (run-mode-hooks 'mirror-mode-hook)) |
| 561 | 561 | ||
| 562 | (provide 'skeleton) | 562 | (provide 'skeleton) |
| 563 | 563 | ||
diff --git a/lisp/speedbar.el b/lisp/speedbar.el index 7a6e01f2859..a01b9ddb47e 100644 --- a/lisp/speedbar.el +++ b/lisp/speedbar.el | |||
| @@ -1306,7 +1306,7 @@ in the selected file. | |||
| 1306 | (if speedbar-track-mouse-flag | 1306 | (if speedbar-track-mouse-flag |
| 1307 | (set (make-local-variable 'track-mouse) t)) ;this could be messy. | 1307 | (set (make-local-variable 'track-mouse) t)) ;this could be messy. |
| 1308 | (setq auto-show-mode nil)) ;no auto-show for Emacs | 1308 | (setq auto-show-mode nil)) ;no auto-show for Emacs |
| 1309 | (run-hooks 'speedbar-mode-hook)) | 1309 | (run-mode-hooks 'speedbar-mode-hook)) |
| 1310 | (speedbar-update-contents) | 1310 | (speedbar-update-contents) |
| 1311 | speedbar-buffer) | 1311 | speedbar-buffer) |
| 1312 | 1312 | ||
diff --git a/lisp/subr.el b/lisp/subr.el index f284c18ce5e..2fe94e2a3c5 100644 --- a/lisp/subr.el +++ b/lisp/subr.el | |||
| @@ -1853,7 +1853,7 @@ Major mode functions should use this." | |||
| 1853 | These hooks will be executed by the first following call to | 1853 | These hooks will be executed by the first following call to |
| 1854 | `run-mode-hooks' that occurs outside any `delayed-mode-hooks' form. | 1854 | `run-mode-hooks' that occurs outside any `delayed-mode-hooks' form. |
| 1855 | Only affects hooks run in the current buffer." | 1855 | Only affects hooks run in the current buffer." |
| 1856 | (declare (debug t)) | 1856 | (declare (debug t) (indent 0)) |
| 1857 | `(progn | 1857 | `(progn |
| 1858 | (make-local-variable 'delay-mode-hooks) | 1858 | (make-local-variable 'delay-mode-hooks) |
| 1859 | (let ((delay-mode-hooks t)) | 1859 | (let ((delay-mode-hooks t)) |
| @@ -1996,14 +1996,34 @@ STRING should be given if the last search was by `string-match' on STRING." | |||
| 1996 | (buffer-substring-no-properties (match-beginning num) | 1996 | (buffer-substring-no-properties (match-beginning num) |
| 1997 | (match-end num))))) | 1997 | (match-end num))))) |
| 1998 | 1998 | ||
| 1999 | (defun looking-back (regexp &optional limit) | 1999 | (defun looking-back (regexp &optional limit greedy) |
| 2000 | "Return non-nil if text before point matches regular expression REGEXP. | 2000 | "Return non-nil if text before point matches regular expression REGEXP. |
| 2001 | Like `looking-at' except matches before point, and is slower. | 2001 | Like `looking-at' except matches before point, and is slower. |
| 2002 | LIMIT if non-nil speeds up the search by specifying how far back the | 2002 | LIMIT if non-nil speeds up the search by specifying how far back the |
| 2003 | match can start." | 2003 | match can start. |
| 2004 | (not (null | 2004 | |
| 2005 | (save-excursion | 2005 | If GREEDY is non-nil, extend the match backwards as far as possible, |
| 2006 | (re-search-backward (concat "\\(?:" regexp "\\)\\=") limit t))))) | 2006 | stopping when a single additional previous character cannot be part |
| 2007 | of a match for REGEXP." | ||
| 2008 | (let ((start (point)) | ||
| 2009 | (pos | ||
| 2010 | (save-excursion | ||
| 2011 | (and (re-search-backward (concat "\\(?:" regexp "\\)\\=") limit t) | ||
| 2012 | (point))))) | ||
| 2013 | (if (and greedy pos) | ||
| 2014 | (save-restriction | ||
| 2015 | (narrow-to-region (point-min) start) | ||
| 2016 | (while (and (> pos (point-min)) | ||
| 2017 | (save-excursion | ||
| 2018 | (goto-char pos) | ||
| 2019 | (backward-char 1) | ||
| 2020 | (looking-at (concat "\\(?:" regexp "\\)\\'")))) | ||
| 2021 | (setq pos (1- pos))) | ||
| 2022 | (save-excursion | ||
| 2023 | (goto-char pos) | ||
| 2024 | (looking-at (concat "\\(?:" regexp "\\)\\'"))))) | ||
| 2025 | (not (null pos)))) | ||
| 2026 | |||
| 2007 | 2027 | ||
| 2008 | (defconst split-string-default-separators "[ \f\t\n\r\v]+" | 2028 | (defconst split-string-default-separators "[ \f\t\n\r\v]+" |
| 2009 | "The default value of separators for `split-string'. | 2029 | "The default value of separators for `split-string'. |
diff --git a/lisp/term.el b/lisp/term.el index 7f8347a986d..48460b3833d 100644 --- a/lisp/term.el +++ b/lisp/term.el | |||
| @@ -1100,7 +1100,7 @@ Entry to this mode runs the hooks on `term-mode-hook'." | |||
| 1100 | (make-local-variable 'term-current-face) | 1100 | (make-local-variable 'term-current-face) |
| 1101 | (make-local-variable 'term-pending-frame) | 1101 | (make-local-variable 'term-pending-frame) |
| 1102 | (setq term-pending-frame nil) | 1102 | (setq term-pending-frame nil) |
| 1103 | (run-hooks 'term-mode-hook) | 1103 | (run-mode-hooks 'term-mode-hook) |
| 1104 | (term-if-xemacs | 1104 | (term-if-xemacs |
| 1105 | (set-buffer-menubar | 1105 | (set-buffer-menubar |
| 1106 | (append current-menubar (list term-terminal-menu)))) | 1106 | (append current-menubar (list term-terminal-menu)))) |
| @@ -4177,7 +4177,7 @@ the process. Any more args are arguments to PROGRAM." | |||
| 4177 | ;;; (make-local-variable 'shell-directory-stack) | 4177 | ;;; (make-local-variable 'shell-directory-stack) |
| 4178 | ;;; (setq shell-directory-stack nil) | 4178 | ;;; (setq shell-directory-stack nil) |
| 4179 | ;;; (add-hook 'term-input-filter-functions 'shell-directory-tracker) | 4179 | ;;; (add-hook 'term-input-filter-functions 'shell-directory-tracker) |
| 4180 | ;;; (run-hooks 'shell-mode-hook)) | 4180 | ;;; (run-mode-hooks 'shell-mode-hook)) |
| 4181 | ;;; | 4181 | ;;; |
| 4182 | ;;; | 4182 | ;;; |
| 4183 | ;;; Completion for term-mode users | 4183 | ;;; Completion for term-mode users |
diff --git a/lisp/terminal.el b/lisp/terminal.el index b84b1b6ed00..6b055200359 100644 --- a/lisp/terminal.el +++ b/lisp/terminal.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; terminal.el --- terminal emulator for GNU Emacs | 1 | ;;; terminal.el --- terminal emulator for GNU Emacs |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1986,87,88,89,93,94 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 1986, 1987, 1988, 1989, 1993, 1994 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Richard Mlynarik <mly@eddie.mit.edu> | 5 | ;; Author: Richard Mlynarik <mly@eddie.mit.edu> |
| 6 | ;; Maintainer: FSF | 6 | ;; Maintainer: FSF |
| @@ -537,7 +537,7 @@ together with a command \\<terminal-edit-map>to return to terminal emulation: \\ | |||
| 537 | (setq mode-name "Terminal Edit") | 537 | (setq mode-name "Terminal Edit") |
| 538 | (setq mode-line-modified (default-value 'mode-line-modified)) | 538 | (setq mode-line-modified (default-value 'mode-line-modified)) |
| 539 | (setq mode-line-process nil) | 539 | (setq mode-line-process nil) |
| 540 | (run-hooks 'terminal-edit-mode-hook)) | 540 | (run-mode-hooks 'terminal-edit-mode-hook)) |
| 541 | 541 | ||
| 542 | (defun te-edit () | 542 | (defun te-edit () |
| 543 | "Start editing the terminal emulator buffer with ordinary Emacs commands." | 543 | "Start editing the terminal emulator buffer with ordinary Emacs commands." |
diff --git a/lisp/textmodes/dns-mode.el b/lisp/textmodes/dns-mode.el index 400f87205c4..ac32eccd9ec 100644 --- a/lisp/textmodes/dns-mode.el +++ b/lisp/textmodes/dns-mode.el | |||
| @@ -48,7 +48,8 @@ | |||
| 48 | ;;; Code: | 48 | ;;; Code: |
| 49 | 49 | ||
| 50 | (defgroup dns-mode nil | 50 | (defgroup dns-mode nil |
| 51 | "DNS master file mode configuration.") | 51 | "DNS master file mode configuration." |
| 52 | :group 'data) | ||
| 52 | 53 | ||
| 53 | (defconst dns-mode-classes '("IN" "CS" "CH" "HS") | 54 | (defconst dns-mode-classes '("IN" "CS" "CH" "HS") |
| 54 | "List of strings with known DNS classes.") | 55 | "List of strings with known DNS classes.") |
diff --git a/lisp/textmodes/flyspell.el b/lisp/textmodes/flyspell.el index dbe8b1cfbc6..500c9c4e113 100644 --- a/lisp/textmodes/flyspell.el +++ b/lisp/textmodes/flyspell.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; flyspell.el --- on-the-fly spell checker | 1 | ;;; flyspell.el --- on-the-fly spell checker |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1998, 2000, 2001, 2002, 2004 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 1998, 2000, 2003, 2004, 2005 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Manuel Serrano <Manuel.Serrano@sophia.inria.fr> | 5 | ;; Author: Manuel Serrano <Manuel.Serrano@sophia.inria.fr> |
| 6 | ;; Maintainer: FSF | 6 | ;; Maintainer: FSF |
| @@ -56,6 +56,21 @@ | |||
| 56 | :group 'processes) | 56 | :group 'processes) |
| 57 | 57 | ||
| 58 | ;*---------------------------------------------------------------------*/ | 58 | ;*---------------------------------------------------------------------*/ |
| 59 | ;* Which emacs are we currently running */ | ||
| 60 | ;*---------------------------------------------------------------------*/ | ||
| 61 | (defvar flyspell-emacs | ||
| 62 | (cond | ||
| 63 | ((string-match "XEmacs" emacs-version) | ||
| 64 | 'xemacs) | ||
| 65 | (t | ||
| 66 | 'emacs)) | ||
| 67 | "The type of Emacs we are currently running.") | ||
| 68 | |||
| 69 | (defvar flyspell-use-local-map | ||
| 70 | (or (eq flyspell-emacs 'xemacs) | ||
| 71 | (not (string< emacs-version "20")))) | ||
| 72 | |||
| 73 | ;*---------------------------------------------------------------------*/ | ||
| 59 | ;* User configuration ... */ | 74 | ;* User configuration ... */ |
| 60 | ;*---------------------------------------------------------------------*/ | 75 | ;*---------------------------------------------------------------------*/ |
| 61 | (defcustom flyspell-highlight-flag t | 76 | (defcustom flyspell-highlight-flag t |
| @@ -109,7 +124,8 @@ is highlighted." | |||
| 109 | delete-backward-char | 124 | delete-backward-char |
| 110 | backward-or-forward-delete-char | 125 | backward-or-forward-delete-char |
| 111 | delete-char | 126 | delete-char |
| 112 | scrollbar-vertical-drag) | 127 | scrollbar-vertical-drag |
| 128 | backward-delete-char-untabify) | ||
| 113 | "The standard list of delayed commands for Flyspell. | 129 | "The standard list of delayed commands for Flyspell. |
| 114 | See `flyspell-delayed-commands'." | 130 | See `flyspell-delayed-commands'." |
| 115 | :group 'flyspell | 131 | :group 'flyspell |
| @@ -199,15 +215,15 @@ http://strw.leidenuniv.nl/~dominik/Tools" | |||
| 199 | :type '(repeat (string))) | 215 | :type '(repeat (string))) |
| 200 | 216 | ||
| 201 | (defcustom flyspell-abbrev-p | 217 | (defcustom flyspell-abbrev-p |
| 202 | t | 218 | nil |
| 203 | "*If true, add correction to abbreviation table." | 219 | "*If non-nil, add correction to abbreviation table." |
| 204 | :group 'flyspell | 220 | :group 'flyspell |
| 205 | :version "21.1" | 221 | :version "21.1" |
| 206 | :type 'boolean) | 222 | :type 'boolean) |
| 207 | 223 | ||
| 208 | (defcustom flyspell-use-global-abbrev-table-p | 224 | (defcustom flyspell-use-global-abbrev-table-p |
| 209 | nil | 225 | nil |
| 210 | "*If true, prefer global abbrev table to local abbrev table." | 226 | "*If non-nil, prefer global abbrev table to local abbrev table." |
| 211 | :group 'flyspell | 227 | :group 'flyspell |
| 212 | :version "21.1" | 228 | :version "21.1" |
| 213 | :type 'boolean) | 229 | :type 'boolean) |
| @@ -224,10 +240,12 @@ Set this to nil if you don't want a modeline indicator." | |||
| 224 | If the region is smaller than this number of characters, | 240 | If the region is smaller than this number of characters, |
| 225 | `flyspell-region' checks the words sequentially using regular | 241 | `flyspell-region' checks the words sequentially using regular |
| 226 | flyspell methods. Else, if the region is large, a new Ispell process is | 242 | flyspell methods. Else, if the region is large, a new Ispell process is |
| 227 | spawned for speed." | 243 | spawned for speed. |
| 244 | |||
| 245 | If `flyspell-large-region' is nil, all regions are treated as small." | ||
| 228 | :group 'flyspell | 246 | :group 'flyspell |
| 229 | :version "21.1" | 247 | :version "21.1" |
| 230 | :type 'number) | 248 | :type '(choice number boolean)) |
| 231 | 249 | ||
| 232 | (defcustom flyspell-insert-function (function insert) | 250 | (defcustom flyspell-insert-function (function insert) |
| 233 | "*Function for inserting word by flyspell upon correction." | 251 | "*Function for inserting word by flyspell upon correction." |
| @@ -244,6 +262,20 @@ spawned for speed." | |||
| 244 | :group 'flyspell | 262 | :group 'flyspell |
| 245 | :type '(choice string (const nil))) | 263 | :type '(choice string (const nil))) |
| 246 | 264 | ||
| 265 | (defcustom flyspell-use-meta-tab t | ||
| 266 | "*Non-nil means that flyspell uses META-TAB to correct word." | ||
| 267 | :group 'flyspell | ||
| 268 | :type 'boolean) | ||
| 269 | |||
| 270 | (defcustom flyspell-auto-correct-binding | ||
| 271 | (cond | ||
| 272 | ((eq flyspell-emacs 'xemacs) | ||
| 273 | [(control \;)]) | ||
| 274 | (t | ||
| 275 | [?\C-\;])) | ||
| 276 | "The key binding for flyspell auto correction." | ||
| 277 | :group 'flyspell) | ||
| 278 | |||
| 247 | ;*---------------------------------------------------------------------*/ | 279 | ;*---------------------------------------------------------------------*/ |
| 248 | ;* Mode specific options */ | 280 | ;* Mode specific options */ |
| 249 | ;* ------------------------------------------------------------- */ | 281 | ;* ------------------------------------------------------------- */ |
| @@ -267,17 +299,24 @@ property of the major mode name.") | |||
| 267 | (put 'message-mode 'flyspell-mode-predicate 'mail-mode-flyspell-verify) | 299 | (put 'message-mode 'flyspell-mode-predicate 'mail-mode-flyspell-verify) |
| 268 | (defun mail-mode-flyspell-verify () | 300 | (defun mail-mode-flyspell-verify () |
| 269 | "This function is used for `flyspell-generic-check-word-p' in Mail mode." | 301 | "This function is used for `flyspell-generic-check-word-p' in Mail mode." |
| 270 | (let ((in-headers (save-excursion | 302 | (let ((header-end (save-excursion |
| 271 | ;; When mail-header-separator is "", | 303 | (goto-char (point-min)) |
| 272 | ;; it is likely to be found in both directions. | 304 | (re-search-forward |
| 273 | (not (re-search-backward (concat "^" (regexp-quote mail-header-separator) "$") nil t)))) | 305 | (concat "^" |
| 274 | (in-signature (save-excursion | 306 | (regexp-quote mail-header-separator) |
| 275 | (re-search-backward message-signature-separator nil t)))) | 307 | "$") |
| 276 | (cond (in-headers | 308 | nil t) |
| 309 | (point))) | ||
| 310 | (signature-begin (save-excursion | ||
| 311 | (goto-char (point-max)) | ||
| 312 | (re-search-backward message-signature-separator | ||
| 313 | nil t) | ||
| 314 | (point)))) | ||
| 315 | (cond ((< (point) header-end) | ||
| 277 | (and (save-excursion (beginning-of-line) | 316 | (and (save-excursion (beginning-of-line) |
| 278 | (looking-at "^Subject:")) | 317 | (looking-at "^Subject:")) |
| 279 | (> (point) (match-end 0)))) | 318 | (> (point) (match-end 0)))) |
| 280 | (in-signature | 319 | ((> (point) signature-begin) |
| 281 | nil) | 320 | nil) |
| 282 | (t | 321 | (t |
| 283 | (save-excursion | 322 | (save-excursion |
| @@ -351,7 +390,8 @@ property of the major mode name.") | |||
| 351 | "Turn on `flyspell-mode' for comments and strings." | 390 | "Turn on `flyspell-mode' for comments and strings." |
| 352 | (interactive) | 391 | (interactive) |
| 353 | (setq flyspell-generic-check-word-p 'flyspell-generic-progmode-verify) | 392 | (setq flyspell-generic-check-word-p 'flyspell-generic-progmode-verify) |
| 354 | (flyspell-mode 1)) | 393 | (flyspell-mode 1) |
| 394 | (run-hooks 'flyspell-prog-mode-hook)) | ||
| 355 | 395 | ||
| 356 | ;*---------------------------------------------------------------------*/ | 396 | ;*---------------------------------------------------------------------*/ |
| 357 | ;* Overlay compatibility */ | 397 | ;* Overlay compatibility */ |
| @@ -366,21 +406,6 @@ property of the major mode name.") | |||
| 366 | (autoload 'previous-overlay-change "overlay" "Overlay compatibility kit." t) | 406 | (autoload 'previous-overlay-change "overlay" "Overlay compatibility kit." t) |
| 367 | 407 | ||
| 368 | ;*---------------------------------------------------------------------*/ | 408 | ;*---------------------------------------------------------------------*/ |
| 369 | ;* Which emacs are we currently running */ | ||
| 370 | ;*---------------------------------------------------------------------*/ | ||
| 371 | (defvar flyspell-emacs | ||
| 372 | (cond | ||
| 373 | ((string-match "XEmacs" emacs-version) | ||
| 374 | 'xemacs) | ||
| 375 | (t | ||
| 376 | 'emacs)) | ||
| 377 | "The type of Emacs we are currently running.") | ||
| 378 | |||
| 379 | (defvar flyspell-use-local-map | ||
| 380 | (or (eq flyspell-emacs 'xemacs) | ||
| 381 | (not (string< emacs-version "20")))) | ||
| 382 | |||
| 383 | ;*---------------------------------------------------------------------*/ | ||
| 384 | ;* The minor mode declaration. */ | 409 | ;* The minor mode declaration. */ |
| 385 | ;*---------------------------------------------------------------------*/ | 410 | ;*---------------------------------------------------------------------*/ |
| 386 | (eval-when-compile (defvar flyspell-local-mouse-map)) | 411 | (eval-when-compile (defvar flyspell-local-mouse-map)) |
| @@ -391,9 +416,13 @@ property of the major mode name.") | |||
| 391 | 416 | ||
| 392 | (defvar flyspell-mouse-map | 417 | (defvar flyspell-mouse-map |
| 393 | (let ((map (make-sparse-keymap))) | 418 | (let ((map (make-sparse-keymap))) |
| 419 | (if flyspell-use-meta-tab | ||
| 420 | (define-key map "\M-\t" #'flyspell-auto-correct-word)) | ||
| 394 | (define-key map (if (featurep 'xemacs) [button2] [down-mouse-2]) | 421 | (define-key map (if (featurep 'xemacs) [button2] [down-mouse-2]) |
| 395 | #'flyspell-correct-word) | 422 | #'flyspell-correct-word) |
| 396 | (define-key map "\M-\t" #'flyspell-auto-correct-word) | 423 | (define-key map flyspell-auto-correct-binding 'flyspell-auto-correct-previous-word) |
| 424 | (define-key map [(control \,)] 'flyspell-goto-next-error) | ||
| 425 | (define-key map [(control \.)] 'flyspell-auto-correct-word) | ||
| 397 | map)) | 426 | map)) |
| 398 | 427 | ||
| 399 | ;;;###autoload | 428 | ;;;###autoload |
| @@ -404,7 +433,18 @@ property of the major mode name.") | |||
| 404 | (setq minor-mode-map-alist | 433 | (setq minor-mode-map-alist |
| 405 | (cons (cons 'flyspell-mode flyspell-mode-map) | 434 | (cons (cons 'flyspell-mode flyspell-mode-map) |
| 406 | minor-mode-map-alist))) | 435 | minor-mode-map-alist))) |
| 407 | (define-key flyspell-mode-map "\M-\t" 'flyspell-auto-correct-word)) | 436 | (if flyspell-use-meta-tab |
| 437 | (define-key flyspell-mode-map "\M-\t" 'flyspell-auto-correct-word)) | ||
| 438 | (cond | ||
| 439 | ((eq flyspell-emacs 'xemacs) | ||
| 440 | (define-key flyspell-mode-map flyspell-auto-correct-binding 'flyspell-auto-correct-previous-word) | ||
| 441 | (define-key flyspell-mode-map [(control \,)] 'flyspell-goto-next-error) | ||
| 442 | (define-key flyspell-mode-map [(control \.)] 'flyspell-auto-correct-word)) | ||
| 443 | (flyspell-use-local-map | ||
| 444 | (define-key flyspell-mode-map flyspell-auto-correct-binding 'flyspell-auto-correct-previous-word) | ||
| 445 | (define-key flyspell-mode-map [?\C-\,] 'flyspell-goto-next-error) | ||
| 446 | (define-key flyspell-mode-map [?\C-\.] 'flyspell-auto-correct-word)))) | ||
| 447 | |||
| 408 | 448 | ||
| 409 | ;; the name of the overlay property that defines the keymap | 449 | ;; the name of the overlay property that defines the keymap |
| 410 | (defvar flyspell-overlay-keymap-property-name 'keymap) | 450 | (defvar flyspell-overlay-keymap-property-name 'keymap) |
| @@ -456,7 +496,8 @@ With a prefix argument ARG, turn Flyspell minor mode on iff ARG is positive. | |||
| 456 | Bindings: | 496 | Bindings: |
| 457 | \\[ispell-word]: correct words (using Ispell). | 497 | \\[ispell-word]: correct words (using Ispell). |
| 458 | \\[flyspell-auto-correct-word]: automatically correct word. | 498 | \\[flyspell-auto-correct-word]: automatically correct word. |
| 459 | \\[flyspell-correct-word] (or mouse-2): popup correct words. | 499 | \\[flyspell-auto-correct-previous-word]: automatically correct the last misspelled word. |
| 500 | \\[flyspell-correct-word] (or down-mouse-2): popup correct words. | ||
| 460 | 501 | ||
| 461 | Hooks: | 502 | Hooks: |
| 462 | This runs `flyspell-mode-hook' after flyspell is entered. | 503 | This runs `flyspell-mode-hook' after flyspell is entered. |
| @@ -512,22 +553,19 @@ in your .emacs file. | |||
| 512 | (and (consp ws) (window-minibuffer-p (car ws))))) | 553 | (and (consp ws) (window-minibuffer-p (car ws))))) |
| 513 | 554 | ||
| 514 | ;*---------------------------------------------------------------------*/ | 555 | ;*---------------------------------------------------------------------*/ |
| 515 | ;* flyspell-version ... */ | ||
| 516 | ;*---------------------------------------------------------------------*/ | ||
| 517 | ;;;###autoload | ||
| 518 | (defun flyspell-version () | ||
| 519 | "The flyspell version" | ||
| 520 | (interactive) | ||
| 521 | "1.6h") | ||
| 522 | |||
| 523 | ;*---------------------------------------------------------------------*/ | ||
| 524 | ;* flyspell-accept-buffer-local-defs ... */ | 556 | ;* flyspell-accept-buffer-local-defs ... */ |
| 525 | ;*---------------------------------------------------------------------*/ | 557 | ;*---------------------------------------------------------------------*/ |
| 526 | (defun flyspell-accept-buffer-local-defs () | 558 | (defun flyspell-accept-buffer-local-defs () |
| 527 | (ispell-accept-buffer-local-defs) | 559 | ;; strange problem. If buffer in current window has font-lock turned on, |
| 560 | ;; but SET-BUFFER was called to point to an invisible buffer, this ispell | ||
| 561 | ;; call will reset the buffer to the buffer in the current window. However, | ||
| 562 | ;; it only happens at startup (fix by Albert L. Ting). | ||
| 563 | (let ((buf (current-buffer))) | ||
| 564 | (ispell-accept-buffer-local-defs) | ||
| 565 | (set-buffer buf)) | ||
| 528 | (if (not (and (eq flyspell-dash-dictionary ispell-dictionary) | 566 | (if (not (and (eq flyspell-dash-dictionary ispell-dictionary) |
| 529 | (eq flyspell-dash-local-dictionary ispell-local-dictionary))) | 567 | (eq flyspell-dash-local-dictionary ispell-local-dictionary))) |
| 530 | ;; the dictionary has changed | 568 | ;; The dictionary has changed |
| 531 | (progn | 569 | (progn |
| 532 | (setq flyspell-dash-dictionary ispell-dictionary) | 570 | (setq flyspell-dash-dictionary ispell-dictionary) |
| 533 | (setq flyspell-dash-local-dictionary ispell-local-dictionary) | 571 | (setq flyspell-dash-local-dictionary ispell-local-dictionary) |
| @@ -566,6 +604,22 @@ in your .emacs file. | |||
| 566 | (let ((mode-predicate (get major-mode 'flyspell-mode-predicate))) | 604 | (let ((mode-predicate (get major-mode 'flyspell-mode-predicate))) |
| 567 | (if mode-predicate | 605 | (if mode-predicate |
| 568 | (setq flyspell-generic-check-word-p mode-predicate))) | 606 | (setq flyspell-generic-check-word-p mode-predicate))) |
| 607 | ;; work around the fact that the `local-map' text-property replaces the | ||
| 608 | ;; buffer's local map rather than shadowing it. | ||
| 609 | (set (make-local-variable 'flyspell-mouse-map) | ||
| 610 | (let ((map (copy-keymap flyspell-mouse-map))) | ||
| 611 | (set-keymap-parent map (current-local-map)) | ||
| 612 | (if (and (eq flyspell-emacs 'emacs) | ||
| 613 | (not (string< emacs-version "20"))) | ||
| 614 | (define-key map '[tool-bar] nil)) | ||
| 615 | map)) | ||
| 616 | (set (make-local-variable 'flyspell-mode-map) | ||
| 617 | (let ((map (copy-keymap flyspell-mode-map))) | ||
| 618 | (set-keymap-parent map (current-local-map)) | ||
| 619 | (if (and (eq flyspell-emacs 'emacs) | ||
| 620 | (not (string< emacs-version "20"))) | ||
| 621 | (define-key map '[tool-bar] nil)) | ||
| 622 | map)) | ||
| 569 | ;; the welcome message | 623 | ;; the welcome message |
| 570 | (if (and flyspell-issue-message-flag | 624 | (if (and flyspell-issue-message-flag |
| 571 | flyspell-issue-welcome-flag | 625 | flyspell-issue-welcome-flag |
| @@ -624,9 +678,11 @@ not the very same deplacement command." | |||
| 624 | (defvar flyspell-word-cache-start nil) | 678 | (defvar flyspell-word-cache-start nil) |
| 625 | (defvar flyspell-word-cache-end nil) | 679 | (defvar flyspell-word-cache-end nil) |
| 626 | (defvar flyspell-word-cache-word nil) | 680 | (defvar flyspell-word-cache-word nil) |
| 681 | (defvar flyspell-word-cache-result '_) | ||
| 627 | (make-variable-buffer-local 'flyspell-word-cache-start) | 682 | (make-variable-buffer-local 'flyspell-word-cache-start) |
| 628 | (make-variable-buffer-local 'flyspell-word-cache-end) | 683 | (make-variable-buffer-local 'flyspell-word-cache-end) |
| 629 | (make-variable-buffer-local 'flyspell-word-cache-word) | 684 | (make-variable-buffer-local 'flyspell-word-cache-word) |
| 685 | (make-variable-buffer-local 'flyspell-word-cache-result) | ||
| 630 | 686 | ||
| 631 | ;*---------------------------------------------------------------------*/ | 687 | ;*---------------------------------------------------------------------*/ |
| 632 | ;* The flyspell pre-hook, store the current position. In the */ | 688 | ;* The flyspell pre-hook, store the current position. In the */ |
| @@ -678,7 +734,7 @@ not the very same deplacement command." | |||
| 678 | ;* flyspell-check-pre-word-p ... */ | 734 | ;* flyspell-check-pre-word-p ... */ |
| 679 | ;*---------------------------------------------------------------------*/ | 735 | ;*---------------------------------------------------------------------*/ |
| 680 | (defun flyspell-check-pre-word-p () | 736 | (defun flyspell-check-pre-word-p () |
| 681 | "Return non-nil if we should to check the word before point. | 737 | "Return non-nil if we should check the word before point. |
| 682 | More precisely, it applies to the word that was before point | 738 | More precisely, it applies to the word that was before point |
| 683 | before the current command." | 739 | before the current command." |
| 684 | (cond | 740 | (cond |
| @@ -735,7 +791,7 @@ before the current command." | |||
| 735 | The answer depends of several criteria. | 791 | The answer depends of several criteria. |
| 736 | Mostly we check word delimiters." | 792 | Mostly we check word delimiters." |
| 737 | (cond | 793 | (cond |
| 738 | ((and (eq (char-after start) ?\n) (> stop start)) | 794 | ((and (memq (char-after start) '(?\n ? )) (> stop start)) |
| 739 | t) | 795 | t) |
| 740 | ((not (numberp flyspell-pre-point)) | 796 | ((not (numberp flyspell-pre-point)) |
| 741 | t) | 797 | t) |
| @@ -774,9 +830,7 @@ Mostly we check word delimiters." | |||
| 774 | ((get this-command 'flyspell-delayed) | 830 | ((get this-command 'flyspell-delayed) |
| 775 | ;; the current command is not delayed, that | 831 | ;; the current command is not delayed, that |
| 776 | ;; is that we must check the word now | 832 | ;; is that we must check the word now |
| 777 | (if (fboundp 'about-xemacs) | 833 | (sit-for flyspell-delay)) |
| 778 | (sit-for flyspell-delay nil) | ||
| 779 | (sit-for flyspell-delay 0 nil))) | ||
| 780 | (t t))) | 834 | (t t))) |
| 781 | (t t))) | 835 | (t t))) |
| 782 | 836 | ||
| @@ -924,7 +978,9 @@ Mostly we check word delimiters." | |||
| 924 | ;; when a word is not checked because of a delayed command | 978 | ;; when a word is not checked because of a delayed command |
| 925 | ;; we do not disable the ispell cache. | 979 | ;; we do not disable the ispell cache. |
| 926 | (if (and (symbolp this-command) (get this-command 'flyspell-delayed)) | 980 | (if (and (symbolp this-command) (get this-command 'flyspell-delayed)) |
| 927 | (setq flyspell-word-cache-end -1)))) | 981 | (progn |
| 982 | (setq flyspell-word-cache-end -1) | ||
| 983 | (setq flyspell-word-cache-result '_))))) | ||
| 928 | (while (consp flyspell-changes) | 984 | (while (consp flyspell-changes) |
| 929 | (let ((start (car (car flyspell-changes))) | 985 | (let ((start (car (car flyspell-changes))) |
| 930 | (stop (cdr (car flyspell-changes)))) | 986 | (stop (cdr (car flyspell-changes)))) |
| @@ -949,6 +1005,34 @@ Mostly we check word delimiters." | |||
| 949 | (message (format "mispelling `%s' %S" word replacements))))) | 1005 | (message (format "mispelling `%s' %S" word replacements))))) |
| 950 | 1006 | ||
| 951 | ;*---------------------------------------------------------------------*/ | 1007 | ;*---------------------------------------------------------------------*/ |
| 1008 | ;* flyspell-word-search-backward ... */ | ||
| 1009 | ;*---------------------------------------------------------------------*/ | ||
| 1010 | (defun flyspell-word-search-backward (word bound) | ||
| 1011 | (save-excursion | ||
| 1012 | (let ((r '()) | ||
| 1013 | p) | ||
| 1014 | (while (and (not r) (setq p (search-backward word bound t))) | ||
| 1015 | (let ((lw (flyspell-get-word '()))) | ||
| 1016 | (if (and (consp lw) (string-equal (car lw) word)) | ||
| 1017 | (setq r p) | ||
| 1018 | (goto-char p)))) | ||
| 1019 | r))) | ||
| 1020 | |||
| 1021 | ;*---------------------------------------------------------------------*/ | ||
| 1022 | ;* flyspell-word-search-forward ... */ | ||
| 1023 | ;*---------------------------------------------------------------------*/ | ||
| 1024 | (defun flyspell-word-search-forward (word bound) | ||
| 1025 | (save-excursion | ||
| 1026 | (let ((r '()) | ||
| 1027 | p) | ||
| 1028 | (while (and (not r) (setq p (search-forward word bound t))) | ||
| 1029 | (let ((lw (flyspell-get-word '()))) | ||
| 1030 | (if (and (consp lw) (string-equal (car lw) word)) | ||
| 1031 | (setq r p) | ||
| 1032 | (goto-char (1+ p))))) | ||
| 1033 | r))) | ||
| 1034 | |||
| 1035 | ;*---------------------------------------------------------------------*/ | ||
| 952 | ;* flyspell-word ... */ | 1036 | ;* flyspell-word ... */ |
| 953 | ;*---------------------------------------------------------------------*/ | 1037 | ;*---------------------------------------------------------------------*/ |
| 954 | (defun flyspell-word (&optional following) | 1038 | (defun flyspell-word (&optional following) |
| @@ -963,7 +1047,7 @@ Mostly we check word delimiters." | |||
| 963 | (if (or (eq flyspell-word nil) | 1047 | (if (or (eq flyspell-word nil) |
| 964 | (and (fboundp flyspell-generic-check-word-p) | 1048 | (and (fboundp flyspell-generic-check-word-p) |
| 965 | (not (funcall flyspell-generic-check-word-p)))) | 1049 | (not (funcall flyspell-generic-check-word-p)))) |
| 966 | '() | 1050 | t |
| 967 | (progn | 1051 | (progn |
| 968 | ;; destructure return flyspell-word info list. | 1052 | ;; destructure return flyspell-word info list. |
| 969 | (setq start (car (cdr flyspell-word)) | 1053 | (setq start (car (cdr flyspell-word)) |
| @@ -972,21 +1056,24 @@ Mostly we check word delimiters." | |||
| 972 | ;; before checking in the directory, we check for doublons. | 1056 | ;; before checking in the directory, we check for doublons. |
| 973 | (cond | 1057 | (cond |
| 974 | ((and (or (not (eq ispell-parser 'tex)) | 1058 | ((and (or (not (eq ispell-parser 'tex)) |
| 975 | (not (eq (char-after start) ?\\))) | 1059 | (and (> start (point-min)) |
| 1060 | (not (eq (char-after (1- start)) ?})) | ||
| 1061 | (not (eq (char-after (1- start)) ?\\)))) | ||
| 976 | flyspell-mark-duplications-flag | 1062 | flyspell-mark-duplications-flag |
| 977 | (save-excursion | 1063 | (save-excursion |
| 978 | (goto-char start) | 1064 | (goto-char (1- start)) |
| 979 | (word-search-backward word | 1065 | (let ((p (flyspell-word-search-backward |
| 980 | (- start | 1066 | word |
| 981 | (+ 1 (- end start))) | 1067 | (- start (1+ (- end start)))))) |
| 982 | t))) | 1068 | (and p (/= p (1- start)))))) |
| 983 | ;; yes, this is a doublon | 1069 | ;; yes, this is a doublon |
| 984 | (flyspell-highlight-incorrect-region start end 'doublon)) | 1070 | (flyspell-highlight-incorrect-region start end 'doublon) |
| 1071 | nil) | ||
| 985 | ((and (eq flyspell-word-cache-start start) | 1072 | ((and (eq flyspell-word-cache-start start) |
| 986 | (eq flyspell-word-cache-end end) | 1073 | (eq flyspell-word-cache-end end) |
| 987 | (string-equal flyspell-word-cache-word word)) | 1074 | (string-equal flyspell-word-cache-word word)) |
| 988 | ;; this word had been already checked, we skip | 1075 | ;; this word had been already checked, we skip |
| 989 | nil) | 1076 | flyspell-word-cache-result) |
| 990 | ((and (eq ispell-parser 'tex) | 1077 | ((and (eq ispell-parser 'tex) |
| 991 | (flyspell-tex-command-p flyspell-word)) | 1078 | (flyspell-tex-command-p flyspell-word)) |
| 992 | ;; this is a correct word (because a tex command) | 1079 | ;; this is a correct word (because a tex command) |
| @@ -1016,59 +1103,68 @@ Mostly we check word delimiters." | |||
| 1016 | (setq ispell-filter (cdr ispell-filter)) | 1103 | (setq ispell-filter (cdr ispell-filter)) |
| 1017 | (if (consp ispell-filter) | 1104 | (if (consp ispell-filter) |
| 1018 | (setq poss (ispell-parse-output (car ispell-filter)))) | 1105 | (setq poss (ispell-parse-output (car ispell-filter)))) |
| 1019 | (cond ((eq poss t) | 1106 | (let ((res (cond ((eq poss t) |
| 1020 | ;; correct | 1107 | ;; correct |
| 1021 | (flyspell-unhighlight-at start) | 1108 | (setq flyspell-word-cache-result t) |
| 1022 | (if (> end start) | 1109 | (flyspell-unhighlight-at start) |
| 1023 | (flyspell-unhighlight-at (- end 1))) | 1110 | (if (> end start) |
| 1024 | t) | 1111 | (flyspell-unhighlight-at (- end 1))) |
| 1025 | ((and (stringp poss) flyspell-highlight-flag) | 1112 | t) |
| 1026 | ;; correct | 1113 | ((and (stringp poss) flyspell-highlight-flag) |
| 1027 | (flyspell-unhighlight-at start) | 1114 | ;; correct |
| 1028 | (if (> end start) | 1115 | (setq flyspell-word-cache-result t) |
| 1029 | (flyspell-unhighlight-at (- end 1))) | 1116 | (flyspell-unhighlight-at start) |
| 1030 | t) | 1117 | (if (> end start) |
| 1031 | ((null poss) | 1118 | (flyspell-unhighlight-at (- end 1))) |
| 1032 | (flyspell-unhighlight-at start) | 1119 | t) |
| 1033 | (if (> end start) | 1120 | ((null poss) |
| 1034 | (flyspell-unhighlight-at (- end 1)))) | 1121 | (setq flyspell-word-cache-result t) |
| 1035 | ((or (and (< flyspell-duplicate-distance 0) | 1122 | (flyspell-unhighlight-at start) |
| 1036 | (or (save-excursion | 1123 | (if (> end start) |
| 1037 | (goto-char start) | 1124 | (flyspell-unhighlight-at (- end 1))) |
| 1038 | (word-search-backward word | 1125 | t) |
| 1039 | (point-min) | 1126 | ((or (and (< flyspell-duplicate-distance 0) |
| 1040 | t)) | 1127 | (or (save-excursion |
| 1041 | (save-excursion | 1128 | (goto-char start) |
| 1042 | (goto-char end) | 1129 | (flyspell-word-search-backward |
| 1043 | (word-search-forward word | 1130 | word |
| 1044 | (point-max) | 1131 | (point-min))) |
| 1045 | t)))) | 1132 | (save-excursion |
| 1046 | (and (> flyspell-duplicate-distance 0) | 1133 | (goto-char end) |
| 1047 | (or (save-excursion | 1134 | (flyspell-word-search-forward |
| 1048 | (goto-char start) | 1135 | word |
| 1049 | (word-search-backward | 1136 | (point-max))))) |
| 1050 | word | 1137 | (and (> flyspell-duplicate-distance 0) |
| 1051 | (- start | 1138 | (or (save-excursion |
| 1052 | flyspell-duplicate-distance) | 1139 | (goto-char start) |
| 1053 | t)) | 1140 | (flyspell-word-search-backward |
| 1054 | (save-excursion | 1141 | word |
| 1055 | (goto-char end) | 1142 | (- start |
| 1056 | (word-search-forward | 1143 | flyspell-duplicate-distance))) |
| 1057 | word | 1144 | (save-excursion |
| 1058 | (+ end | 1145 | (goto-char end) |
| 1059 | flyspell-duplicate-distance) | 1146 | (flyspell-word-search-forward |
| 1060 | t))))) | 1147 | word |
| 1061 | (if flyspell-highlight-flag | 1148 | (+ end |
| 1062 | (flyspell-highlight-duplicate-region start end poss) | 1149 | flyspell-duplicate-distance)))))) |
| 1063 | (message (format "duplicate `%s'" word)))) | 1150 | (setq flyspell-word-cache-result nil) |
| 1064 | (t | 1151 | (if flyspell-highlight-flag |
| 1065 | ;; incorrect highlight the location | 1152 | (flyspell-highlight-duplicate-region |
| 1066 | (if flyspell-highlight-flag | 1153 | start end poss) |
| 1067 | (flyspell-highlight-incorrect-region start end poss) | 1154 | (message (format "duplicate `%s'" word))) |
| 1068 | (flyspell-notify-misspell start end word poss)))) | 1155 | nil) |
| 1069 | ;; return to original location | 1156 | (t |
| 1070 | (goto-char cursor-location) | 1157 | (setq flyspell-word-cache-result nil) |
| 1071 | (if ispell-quit (setq ispell-quit nil))))))))) | 1158 | ;; incorrect highlight the location |
| 1159 | (if flyspell-highlight-flag | ||
| 1160 | (flyspell-highlight-incorrect-region | ||
| 1161 | start end poss) | ||
| 1162 | (flyspell-notify-misspell start end word poss)) | ||
| 1163 | nil)))) | ||
| 1164 | ;; return to original location | ||
| 1165 | (goto-char cursor-location) | ||
| 1166 | (if ispell-quit (setq ispell-quit nil)) | ||
| 1167 | res)))))))) | ||
| 1072 | 1168 | ||
| 1073 | ;*---------------------------------------------------------------------*/ | 1169 | ;*---------------------------------------------------------------------*/ |
| 1074 | ;* flyspell-tex-math-initialized ... */ | 1170 | ;* flyspell-tex-math-initialized ... */ |
| @@ -1175,30 +1271,31 @@ this function changes the last char of the `ispell-casechars' string." | |||
| 1175 | ;*---------------------------------------------------------------------*/ | 1271 | ;*---------------------------------------------------------------------*/ |
| 1176 | ;* flyspell-get-word ... */ | 1272 | ;* flyspell-get-word ... */ |
| 1177 | ;*---------------------------------------------------------------------*/ | 1273 | ;*---------------------------------------------------------------------*/ |
| 1178 | (defun flyspell-get-word (following) | 1274 | (defun flyspell-get-word (following &optional extra-otherchars) |
| 1179 | "Return the word for spell-checking according to Ispell syntax. | 1275 | "Return the word for spell-checking according to Ispell syntax. |
| 1180 | If argument FOLLOWING is non-nil or if `ispell-following-word' | 1276 | If optional argument FOLLOWING is non-nil or if `flyspell-following-word' |
| 1181 | is non-nil when called interactively, then the following word | 1277 | is non-nil when called interactively, then the following word |
| 1182 | \(rather than preceding\) is checked when the cursor is not over a word. | 1278 | \(rather than preceding\) is checked when the cursor is not over a word. |
| 1183 | Optional second argument contains other chars that can be included in word | 1279 | Optional second argument contains otherchars that can be included in word |
| 1184 | many times. | 1280 | many times. |
| 1185 | 1281 | ||
| 1186 | Word syntax described by `ispell-dictionary-alist' (which see)." | 1282 | Word syntax described by `flyspell-dictionary-alist' (which see)." |
| 1187 | (let* ((flyspell-casechars (flyspell-get-casechars)) | 1283 | (let* ((flyspell-casechars (flyspell-get-casechars)) |
| 1188 | (flyspell-not-casechars (flyspell-get-not-casechars)) | 1284 | (flyspell-not-casechars (flyspell-get-not-casechars)) |
| 1189 | (ispell-otherchars (ispell-get-otherchars)) | 1285 | (ispell-otherchars (ispell-get-otherchars)) |
| 1190 | (ispell-many-otherchars-p (ispell-get-many-otherchars-p)) | 1286 | (ispell-many-otherchars-p (ispell-get-many-otherchars-p)) |
| 1191 | (word-regexp (if (string< "" ispell-otherchars) | 1287 | (word-regexp (concat flyspell-casechars |
| 1192 | (concat flyspell-casechars | 1288 | "+\\(" |
| 1193 | "+\\(" | 1289 | (if (not (string= "" ispell-otherchars)) |
| 1194 | ispell-otherchars | 1290 | (concat ispell-otherchars "?")) |
| 1195 | "?" | 1291 | (if extra-otherchars |
| 1196 | flyspell-casechars | 1292 | (concat extra-otherchars "?")) |
| 1197 | "+\\)" | 1293 | flyspell-casechars |
| 1198 | (if ispell-many-otherchars-p | 1294 | "+\\)" |
| 1199 | "*" "?")) | 1295 | (if (or ispell-many-otherchars-p |
| 1200 | (concat flyspell-casechars "+"))) | 1296 | extra-otherchars) |
| 1201 | did-it-once | 1297 | "*" "?"))) |
| 1298 | did-it-once prevpt | ||
| 1202 | start end word) | 1299 | start end word) |
| 1203 | ;; find the word | 1300 | ;; find the word |
| 1204 | (if (not (looking-at flyspell-casechars)) | 1301 | (if (not (looking-at flyspell-casechars)) |
| @@ -1207,21 +1304,26 @@ Word syntax described by `ispell-dictionary-alist' (which see)." | |||
| 1207 | (re-search-backward flyspell-casechars (point-min) t))) | 1304 | (re-search-backward flyspell-casechars (point-min) t))) |
| 1208 | ;; move to front of word | 1305 | ;; move to front of word |
| 1209 | (re-search-backward flyspell-not-casechars (point-min) 'start) | 1306 | (re-search-backward flyspell-not-casechars (point-min) 'start) |
| 1210 | (let ((pos nil)) | 1307 | (while (and (or (and (not (string= "" ispell-otherchars)) |
| 1211 | (if (string< "" ispell-otherchars) | 1308 | (looking-at ispell-otherchars)) |
| 1212 | (while (and (looking-at ispell-otherchars) | 1309 | (and extra-otherchars (looking-at extra-otherchars))) |
| 1213 | (not (bobp)) | 1310 | (not (bobp)) |
| 1214 | (or (not did-it-once) | 1311 | (or (not did-it-once) |
| 1215 | ispell-many-otherchars-p) | 1312 | ispell-many-otherchars-p) |
| 1216 | (not (eq pos (point)))) | 1313 | (not (eq prevpt (point)))) |
| 1217 | (setq pos (point)) | 1314 | (if (and extra-otherchars (looking-at extra-otherchars)) |
| 1218 | (setq did-it-once t) | 1315 | (progn |
| 1219 | (backward-char 1) | 1316 | (backward-char 1) |
| 1220 | (if (looking-at flyspell-casechars) | 1317 | (if (looking-at flyspell-casechars) |
| 1221 | (re-search-backward flyspell-not-casechars (point-min) 'move) | 1318 | (re-search-backward flyspell-not-casechars (point-min) 'move))) |
| 1222 | (backward-char -1))))) | 1319 | (setq did-it-once t |
| 1320 | prevpt (point)) | ||
| 1321 | (backward-char 1) | ||
| 1322 | (if (looking-at flyspell-casechars) | ||
| 1323 | (re-search-backward flyspell-not-casechars (point-min) 'move) | ||
| 1324 | (backward-char -1)))) | ||
| 1223 | ;; Now mark the word and save to string. | 1325 | ;; Now mark the word and save to string. |
| 1224 | (if (eq (re-search-forward word-regexp (point-max) t) nil) | 1326 | (if (not (re-search-forward word-regexp (point-max) t)) |
| 1225 | nil | 1327 | nil |
| 1226 | (progn | 1328 | (progn |
| 1227 | (setq start (match-beginning 0) | 1329 | (setq start (match-beginning 0) |
| @@ -1280,25 +1382,37 @@ Word syntax described by `ispell-dictionary-alist' (which see)." | |||
| 1280 | (set-buffer buffer) | 1382 | (set-buffer buffer) |
| 1281 | (goto-char (point-min)) | 1383 | (goto-char (point-min)) |
| 1282 | (let ((size (- flyspell-large-region-end flyspell-large-region-beg)) | 1384 | (let ((size (- flyspell-large-region-end flyspell-large-region-beg)) |
| 1283 | (start flyspell-large-region-beg)) | 1385 | (start flyspell-large-region-beg) |
| 1386 | (pword "") | ||
| 1387 | (pcount 1)) | ||
| 1284 | ;; now we are done with ispell, we have to find the word in | 1388 | ;; now we are done with ispell, we have to find the word in |
| 1285 | ;; the initial buffer | 1389 | ;; the initial buffer |
| 1286 | (while (< (point) (- (point-max) 1)) | 1390 | (while (< (point) (- (point-max) 1)) |
| 1287 | ;; we have to fetch the incorrect word | 1391 | ;; we have to fetch the incorrect word |
| 1288 | (if (re-search-forward "\\([^\n]+\\)\n" (point-max) t) | 1392 | (if (re-search-forward "\\([^\n]+\\)\n" (point-max) t) |
| 1289 | (let ((word (match-string 1))) | 1393 | (let ((word (match-string 1))) |
| 1394 | (if (string= word pword) | ||
| 1395 | (setq pcount (1+ pcount)) | ||
| 1396 | (progn | ||
| 1397 | (setq pword word) | ||
| 1398 | (setq pcount 1))) | ||
| 1290 | (goto-char (match-end 0)) | 1399 | (goto-char (match-end 0)) |
| 1291 | (set-buffer flyspell-large-region-buffer) | ||
| 1292 | (goto-char flyspell-large-region-beg) | ||
| 1293 | (if flyspell-issue-message-flag | 1400 | (if flyspell-issue-message-flag |
| 1294 | (message "Spell Checking...%d%% [%s]" | 1401 | (message "Spell Checking...%d%% [%s]" |
| 1295 | (* 100 (/ (float (- (point) start)) size)) | 1402 | (* 100 (/ (float (point)) (point-max))) |
| 1296 | word)) | 1403 | word)) |
| 1297 | (if (search-forward word flyspell-large-region-end t) | 1404 | (set-buffer flyspell-large-region-buffer) |
| 1405 | (goto-char flyspell-large-region-beg) | ||
| 1406 | (let ((keep t) | ||
| 1407 | (n 0)) | ||
| 1408 | (while (and (or (< n pcount) keep) | ||
| 1409 | (search-forward word flyspell-large-region-end t)) | ||
| 1298 | (progn | 1410 | (progn |
| 1299 | (setq flyspell-large-region-beg (point)) | ||
| 1300 | (goto-char (- (point) 1)) | 1411 | (goto-char (- (point) 1)) |
| 1301 | (flyspell-word))) | 1412 | (setq n (1+ n)) |
| 1413 | (setq keep (flyspell-word)))) | ||
| 1414 | (if (= n pcount) | ||
| 1415 | (setq flyspell-large-region-beg (point)))) | ||
| 1302 | (set-buffer buffer)) | 1416 | (set-buffer buffer)) |
| 1303 | (goto-char (point-max))))) | 1417 | (goto-char (point-max))))) |
| 1304 | ;; we are done | 1418 | ;; we are done |
| @@ -1370,7 +1484,7 @@ Word syntax described by `ispell-dictionary-alist' (which see)." | |||
| 1370 | (let ((old beg)) | 1484 | (let ((old beg)) |
| 1371 | (setq beg end) | 1485 | (setq beg end) |
| 1372 | (setq end old))) | 1486 | (setq end old))) |
| 1373 | (if (> (- end beg) flyspell-large-region) | 1487 | (if (and flyspell-large-region (> (- end beg) flyspell-large-region)) |
| 1374 | (flyspell-large-region beg end) | 1488 | (flyspell-large-region beg end) |
| 1375 | (flyspell-small-region beg end))))) | 1489 | (flyspell-small-region beg end))))) |
| 1376 | 1490 | ||
| @@ -1517,15 +1631,23 @@ for the overlay." | |||
| 1517 | (if (or flyspell-highlight-properties | 1631 | (if (or flyspell-highlight-properties |
| 1518 | (not (flyspell-properties-at-p beg))) | 1632 | (not (flyspell-properties-at-p beg))) |
| 1519 | (progn | 1633 | (progn |
| 1634 | ;; we cleanup all the overlay that are in the region, not | ||
| 1635 | ;; beginning at the word start position | ||
| 1636 | (if (< (1+ beg) end) | ||
| 1637 | (let ((os (overlays-in (1+ beg) end))) | ||
| 1638 | (while (consp os) | ||
| 1639 | (if (flyspell-overlay-p (car os)) | ||
| 1640 | (delete-overlay (car os))) | ||
| 1641 | (setq os (cdr os))))) | ||
| 1520 | ;; we cleanup current overlay at the same position | 1642 | ;; we cleanup current overlay at the same position |
| 1521 | (if (and (not flyspell-persistent-highlight) | 1643 | (if (and (not flyspell-persistent-highlight) |
| 1522 | (overlayp flyspell-overlay)) | 1644 | (overlayp flyspell-overlay)) |
| 1523 | (delete-overlay flyspell-overlay) | 1645 | (delete-overlay flyspell-overlay) |
| 1524 | (let ((overlays (overlays-at beg))) | 1646 | (let ((os (overlays-at beg))) |
| 1525 | (while (consp overlays) | 1647 | (while (consp os) |
| 1526 | (if (flyspell-overlay-p (car overlays)) | 1648 | (if (flyspell-overlay-p (car os)) |
| 1527 | (delete-overlay (car overlays))) | 1649 | (delete-overlay (car os))) |
| 1528 | (setq overlays (cdr overlays))))) | 1650 | (setq os (cdr os))))) |
| 1529 | ;; now we can use a new overlay | 1651 | ;; now we can use a new overlay |
| 1530 | (setq flyspell-overlay | 1652 | (setq flyspell-overlay |
| 1531 | (make-flyspell-overlay | 1653 | (make-flyspell-overlay |
| @@ -1677,69 +1799,71 @@ This command proposes various successive corrections for the current word." | |||
| 1677 | (flyspell-ajust-cursor-point pos (point) old-max) | 1799 | (flyspell-ajust-cursor-point pos (point) old-max) |
| 1678 | (setq flyspell-auto-correct-pos (point))) | 1800 | (setq flyspell-auto-correct-pos (point))) |
| 1679 | ;; fetch the word to be checked | 1801 | ;; fetch the word to be checked |
| 1680 | (let ((word (flyspell-get-word nil)) | 1802 | (let ((word (flyspell-get-word nil))) |
| 1681 | start end poss) | 1803 | (if (consp word) |
| 1682 | ;; destructure return word info list. | 1804 | (let ((start (car (cdr word))) |
| 1683 | (setq start (car (cdr word)) | 1805 | (end (car (cdr (cdr word)))) |
| 1684 | end (car (cdr (cdr word))) | 1806 | (word (car word)) |
| 1685 | word (car word)) | 1807 | poss) |
| 1686 | (setq flyspell-auto-correct-word word) | 1808 | (setq flyspell-auto-correct-word word) |
| 1687 | ;; now check spelling of word. | 1809 | ;; now check spelling of word. |
| 1688 | (process-send-string ispell-process "%\n") ;put in verbose mode | 1810 | (process-send-string ispell-process "%\n") ;put in verbose mode |
| 1689 | (process-send-string ispell-process (concat "^" word "\n")) | 1811 | (process-send-string ispell-process (concat "^" word "\n")) |
| 1690 | ;; wait until ispell has processed word | 1812 | ;; wait until ispell has processed word |
| 1691 | (while (progn | 1813 | (while (progn |
| 1692 | (accept-process-output ispell-process) | 1814 | (accept-process-output ispell-process) |
| 1693 | (not (string= "" (car ispell-filter))))) | 1815 | (not (string= "" (car ispell-filter))))) |
| 1694 | (setq ispell-filter (cdr ispell-filter)) | 1816 | (setq ispell-filter (cdr ispell-filter)) |
| 1695 | (if (consp ispell-filter) | 1817 | (if (consp ispell-filter) |
| 1696 | (setq poss (ispell-parse-output (car ispell-filter)))) | 1818 | (setq poss (ispell-parse-output (car ispell-filter)))) |
| 1697 | (cond ((or (eq poss t) (stringp poss)) | 1819 | (cond |
| 1698 | ;; don't correct word | 1820 | ((or (eq poss t) (stringp poss)) |
| 1699 | t) | 1821 | ;; don't correct word |
| 1700 | ((null poss) | 1822 | t) |
| 1701 | ;; ispell error | 1823 | ((null poss) |
| 1702 | (error "Ispell: error in Ispell process")) | 1824 | ;; ispell error |
| 1703 | (t | 1825 | (error "Ispell: error in Ispell process")) |
| 1704 | ;; the word is incorrect, we have to propose a replacement | 1826 | (t |
| 1705 | (let ((replacements (if flyspell-sort-corrections | 1827 | ;; the word is incorrect, we have to propose a replacement |
| 1706 | (sort (car (cdr (cdr poss))) 'string<) | 1828 | (let ((replacements (if flyspell-sort-corrections |
| 1707 | (car (cdr (cdr poss)))))) | 1829 | (sort (car (cdr (cdr poss))) 'string<) |
| 1708 | (setq flyspell-auto-correct-region nil) | 1830 | (car (cdr (cdr poss)))))) |
| 1709 | (if (consp replacements) | 1831 | (setq flyspell-auto-correct-region nil) |
| 1710 | (progn | 1832 | (if (consp replacements) |
| 1711 | (let ((replace (car replacements))) | 1833 | (progn |
| 1712 | (let ((new-word replace)) | 1834 | (let ((replace (car replacements))) |
| 1713 | (if (not (equal new-word (car poss))) | 1835 | (let ((new-word replace)) |
| 1714 | (progn | 1836 | (if (not (equal new-word (car poss))) |
| 1715 | ;; the save the current replacements | 1837 | (progn |
| 1716 | (setq flyspell-auto-correct-region | 1838 | ;; the save the current replacements |
| 1717 | (cons start (length new-word))) | 1839 | (setq flyspell-auto-correct-region |
| 1718 | (let ((l replacements)) | 1840 | (cons start (length new-word))) |
| 1719 | (while (consp (cdr l)) | 1841 | (let ((l replacements)) |
| 1720 | (setq l (cdr l))) | 1842 | (while (consp (cdr l)) |
| 1721 | (rplacd l (cons (car poss) replacements))) | 1843 | (setq l (cdr l))) |
| 1722 | (setq flyspell-auto-correct-ring | 1844 | (rplacd l (cons (car poss) replacements))) |
| 1723 | replacements) | 1845 | (setq flyspell-auto-correct-ring |
| 1724 | (flyspell-unhighlight-at start) | 1846 | replacements) |
| 1725 | (delete-region start end) | 1847 | (flyspell-unhighlight-at start) |
| 1726 | (funcall flyspell-insert-function new-word) | 1848 | (delete-region start end) |
| 1727 | (if flyspell-abbrev-p | 1849 | (funcall flyspell-insert-function new-word) |
| 1728 | (if (flyspell-already-abbrevp | 1850 | (if flyspell-abbrev-p |
| 1729 | (flyspell-abbrev-table) word) | 1851 | (if (flyspell-already-abbrevp |
| 1730 | (flyspell-change-abbrev | 1852 | (flyspell-abbrev-table) word) |
| 1731 | (flyspell-abbrev-table) | 1853 | (flyspell-change-abbrev |
| 1732 | word | 1854 | (flyspell-abbrev-table) |
| 1733 | new-word) | 1855 | word |
| 1734 | (flyspell-define-abbrev word new-word))) | 1856 | new-word) |
| 1735 | (flyspell-word) | 1857 | (flyspell-define-abbrev word |
| 1736 | (flyspell-display-next-corrections | 1858 | new-word))) |
| 1737 | (cons new-word flyspell-auto-correct-ring)) | 1859 | (flyspell-word) |
| 1738 | (flyspell-ajust-cursor-point pos | 1860 | (flyspell-display-next-corrections |
| 1739 | (point) | 1861 | (cons new-word flyspell-auto-correct-ring)) |
| 1740 | old-max)))))))))) | 1862 | (flyspell-ajust-cursor-point pos |
| 1741 | (setq flyspell-auto-correct-pos (point)) | 1863 | (point) |
| 1742 | (ispell-pdict-save t))))) | 1864 | old-max)))))))))) |
| 1865 | (setq flyspell-auto-correct-pos (point)) | ||
| 1866 | (ispell-pdict-save t))))))) | ||
| 1743 | 1867 | ||
| 1744 | ;*---------------------------------------------------------------------*/ | 1868 | ;*---------------------------------------------------------------------*/ |
| 1745 | ;* flyspell-auto-correct-previous-pos ... */ | 1869 | ;* flyspell-auto-correct-previous-pos ... */ |
| @@ -1752,8 +1876,8 @@ This command proposes various successive corrections for the current word." | |||
| 1752 | ;*---------------------------------------------------------------------*/ | 1876 | ;*---------------------------------------------------------------------*/ |
| 1753 | (defun flyspell-auto-correct-previous-hook () | 1877 | (defun flyspell-auto-correct-previous-hook () |
| 1754 | "Hook to track successive calls to `flyspell-auto-correct-previous-word'. | 1878 | "Hook to track successive calls to `flyspell-auto-correct-previous-word'. |
| 1755 | Sets flyspell-auto-correct-previous-pos to nil" | 1879 | Sets `flyspell-auto-correct-previous-pos' to nil" |
| 1756 | (interactive) | 1880 | (interactive) |
| 1757 | (remove-hook 'pre-command-hook (function flyspell-auto-correct-previous-hook) t) | 1881 | (remove-hook 'pre-command-hook (function flyspell-auto-correct-previous-hook) t) |
| 1758 | (unless (eq this-command (function flyspell-auto-correct-previous-word)) | 1882 | (unless (eq this-command (function flyspell-auto-correct-previous-word)) |
| 1759 | (setq flyspell-auto-correct-previous-pos nil))) | 1883 | (setq flyspell-auto-correct-previous-pos nil))) |
| @@ -1761,45 +1885,56 @@ Sets flyspell-auto-correct-previous-pos to nil" | |||
| 1761 | ;*---------------------------------------------------------------------*/ | 1885 | ;*---------------------------------------------------------------------*/ |
| 1762 | ;* flyspell-auto-correct-previous-word ... */ | 1886 | ;* flyspell-auto-correct-previous-word ... */ |
| 1763 | ;*---------------------------------------------------------------------*/ | 1887 | ;*---------------------------------------------------------------------*/ |
| 1764 | (defun flyspell-auto-correct-previous-word (position) | 1888 | (defun flyspell-auto-correct-previous-word (position) |
| 1765 | "*Auto correct the first mispelled word that occurs before point." | 1889 | "*Auto correct the first mispelled word that occurs before point. |
| 1890 | But don't look beyond what's visible on the screen." | ||
| 1766 | (interactive "d") | 1891 | (interactive "d") |
| 1767 | 1892 | ||
| 1768 | (add-hook 'pre-command-hook | 1893 | (let (top bot) |
| 1769 | (function flyspell-auto-correct-previous-hook) t t) | 1894 | (save-excursion |
| 1770 | 1895 | (move-to-window-line 0) | |
| 1771 | (save-excursion | 1896 | (setq top (point)) |
| 1772 | (unless flyspell-auto-correct-previous-pos | 1897 | (move-to-window-line -1) |
| 1773 | ;; only reset if a new overlay exists | 1898 | (setq bot (point))) |
| 1774 | (setq flyspell-auto-correct-previous-pos nil) | 1899 | (save-excursion |
| 1775 | 1900 | (save-restriction | |
| 1776 | (let ((overlay-list (overlays-in (point-min) position)) | 1901 | (narrow-to-region top bot) |
| 1777 | (new-overlay 'dummy-value)) | 1902 | (overlay-recenter (point)) |
| 1778 | 1903 | ||
| 1779 | ;; search for previous (new) flyspell overlay | 1904 | (add-hook 'pre-command-hook |
| 1780 | (while (and new-overlay | 1905 | (function flyspell-auto-correct-previous-hook) t t) |
| 1781 | (or (not (flyspell-overlay-p new-overlay)) | 1906 | |
| 1782 | ;; check if its face has changed | 1907 | (unless flyspell-auto-correct-previous-pos |
| 1783 | (not (eq (get-char-property | 1908 | ;; only reset if a new overlay exists |
| 1784 | (overlay-start new-overlay) 'face) | 1909 | (setq flyspell-auto-correct-previous-pos nil) |
| 1785 | 'flyspell-incorrect-face)))) | 1910 | |
| 1786 | (setq new-overlay (car-safe overlay-list)) | 1911 | (let ((overlay-list (overlays-in (point-min) position)) |
| 1787 | (setq overlay-list (cdr-safe overlay-list))) | 1912 | (new-overlay 'dummy-value)) |
| 1788 | 1913 | ||
| 1789 | ;; if nothing new exits new-overlay should be nil | 1914 | ;; search for previous (new) flyspell overlay |
| 1790 | (if new-overlay;; the length of the word may change so go to the start | 1915 | (while (and new-overlay |
| 1791 | (setq flyspell-auto-correct-previous-pos | 1916 | (or (not (flyspell-overlay-p new-overlay)) |
| 1792 | (overlay-start new-overlay))))) | 1917 | ;; check if its face has changed |
| 1793 | 1918 | (not (eq (get-char-property | |
| 1794 | (when flyspell-auto-correct-previous-pos | 1919 | (overlay-start new-overlay) 'face) |
| 1795 | (save-excursion | 1920 | 'flyspell-incorrect-face)))) |
| 1796 | (goto-char flyspell-auto-correct-previous-pos) | 1921 | (setq new-overlay (car-safe overlay-list)) |
| 1797 | (let ((ispell-following-word t));; point is at start | 1922 | (setq overlay-list (cdr-safe overlay-list))) |
| 1798 | (if (numberp flyspell-auto-correct-previous-pos) | 1923 | |
| 1799 | (goto-char flyspell-auto-correct-previous-pos)) | 1924 | ;; if nothing new exits new-overlay should be nil |
| 1800 | (flyspell-auto-correct-word)) | 1925 | (if new-overlay ;; the length of the word may change so go to the start |
| 1801 | ;; the point may have moved so reset this | 1926 | (setq flyspell-auto-correct-previous-pos |
| 1802 | (setq flyspell-auto-correct-previous-pos (point)))))) | 1927 | (overlay-start new-overlay))))) |
| 1928 | |||
| 1929 | (when flyspell-auto-correct-previous-pos | ||
| 1930 | (save-excursion | ||
| 1931 | (goto-char flyspell-auto-correct-previous-pos) | ||
| 1932 | (let ((ispell-following-word t)) ;; point is at start | ||
| 1933 | (if (numberp flyspell-auto-correct-previous-pos) | ||
| 1934 | (goto-char flyspell-auto-correct-previous-pos)) | ||
| 1935 | (flyspell-auto-correct-word)) | ||
| 1936 | ;; the point may have moved so reset this | ||
| 1937 | (setq flyspell-auto-correct-previous-pos (point)))))))) | ||
| 1803 | 1938 | ||
| 1804 | ;*---------------------------------------------------------------------*/ | 1939 | ;*---------------------------------------------------------------------*/ |
| 1805 | ;* flyspell-correct-word ... */ | 1940 | ;* flyspell-correct-word ... */ |
| @@ -1814,72 +1949,76 @@ The word checked is the word at the mouse position." | |||
| 1814 | (let ((save (point))) | 1949 | (let ((save (point))) |
| 1815 | (mouse-set-point event) | 1950 | (mouse-set-point event) |
| 1816 | (let ((cursor-location (point)) | 1951 | (let ((cursor-location (point)) |
| 1817 | (word (flyspell-get-word nil)) | 1952 | (word (flyspell-get-word nil))) |
| 1818 | start end poss replace) | 1953 | (if (consp word) |
| 1819 | ;; destructure return word info list. | 1954 | (let ((start (car (cdr word))) |
| 1820 | (setq start (car (cdr word)) | 1955 | (end (car (cdr (cdr word)))) |
| 1821 | end (car (cdr (cdr word))) | 1956 | (word (car word)) |
| 1822 | word (car word)) | 1957 | poss replace) |
| 1823 | ;; now check spelling of word. | 1958 | ;; now check spelling of word. |
| 1824 | (process-send-string ispell-process "%\n") ;put in verbose mode | 1959 | (process-send-string ispell-process "%\n") ;put in verbose mode |
| 1825 | (process-send-string ispell-process (concat "^" word "\n")) | 1960 | (process-send-string ispell-process (concat "^" word "\n")) |
| 1826 | ;; wait until ispell has processed word | 1961 | ;; wait until ispell has processed word |
| 1827 | (while (progn | 1962 | (while (progn |
| 1828 | (accept-process-output ispell-process) | 1963 | (accept-process-output ispell-process) |
| 1829 | (not (string= "" (car ispell-filter))))) | 1964 | (not (string= "" (car ispell-filter))))) |
| 1830 | (setq ispell-filter (cdr ispell-filter)) | 1965 | (setq ispell-filter (cdr ispell-filter)) |
| 1831 | (if (consp ispell-filter) | 1966 | (if (consp ispell-filter) |
| 1832 | (setq poss (ispell-parse-output (car ispell-filter)))) | 1967 | (setq poss (ispell-parse-output (car ispell-filter)))) |
| 1833 | (cond ((or (eq poss t) (stringp poss)) | 1968 | (cond |
| 1834 | ;; don't correct word | 1969 | ((or (eq poss t) (stringp poss)) |
| 1835 | t) | 1970 | ;; don't correct word |
| 1836 | ((null poss) | 1971 | t) |
| 1837 | ;; ispell error | 1972 | ((null poss) |
| 1838 | (error "Ispell: error in Ispell process")) | 1973 | ;; ispell error |
| 1839 | ((string-match "GNU" (emacs-version)) | 1974 | (error "Ispell: error in Ispell process")) |
| 1840 | ;; the word is incorrect, we have to propose a replacement | 1975 | ((string-match "GNU" (emacs-version)) |
| 1841 | (setq replace (flyspell-emacs-popup event poss word)) | 1976 | ;; the word is incorrect, we have to propose a replacement |
| 1842 | (cond ((eq replace 'ignore) | 1977 | (setq replace (flyspell-emacs-popup event poss word)) |
| 1843 | (goto-char save) | 1978 | (cond ((eq replace 'ignore) |
| 1844 | nil) | 1979 | (goto-char save) |
| 1845 | ((eq replace 'save) | 1980 | nil) |
| 1846 | (goto-char save) | 1981 | ((eq replace 'save) |
| 1847 | (process-send-string ispell-process (concat "*" word "\n")) | 1982 | (goto-char save) |
| 1848 | (flyspell-unhighlight-at cursor-location) | 1983 | (process-send-string ispell-process |
| 1849 | (setq ispell-pdict-modified-p '(t))) | 1984 | (concat "*" word "\n")) |
| 1850 | ((or (eq replace 'buffer) (eq replace 'session)) | 1985 | (flyspell-unhighlight-at cursor-location) |
| 1851 | (process-send-string ispell-process (concat "@" word "\n")) | 1986 | (setq ispell-pdict-modified-p '(t))) |
| 1852 | (if (null ispell-pdict-modified-p) | 1987 | ((or (eq replace 'buffer) (eq replace 'session)) |
| 1853 | (setq ispell-pdict-modified-p | 1988 | (process-send-string ispell-process |
| 1854 | (list ispell-pdict-modified-p))) | 1989 | (concat "@" word "\n")) |
| 1855 | (flyspell-unhighlight-at cursor-location) | 1990 | (if (null ispell-pdict-modified-p) |
| 1856 | (goto-char save) | 1991 | (setq ispell-pdict-modified-p |
| 1857 | (if (eq replace 'buffer) | 1992 | (list ispell-pdict-modified-p))) |
| 1858 | (ispell-add-per-file-word-list word))) | 1993 | (flyspell-unhighlight-at cursor-location) |
| 1859 | (replace | 1994 | (goto-char save) |
| 1860 | (flyspell-unhighlight-at cursor-location) | 1995 | (if (eq replace 'buffer) |
| 1861 | (let ((new-word (if (atom replace) | 1996 | (ispell-add-per-file-word-list word))) |
| 1862 | replace | 1997 | (replace |
| 1863 | (car replace))) | 1998 | (flyspell-unhighlight-at cursor-location) |
| 1864 | (cursor-location (+ (- (length word) (- end start)) | 1999 | (let ((new-word (if (atom replace) |
| 1865 | cursor-location))) | 2000 | replace |
| 1866 | (if (not (equal new-word (car poss))) | 2001 | (car replace))) |
| 1867 | (let ((old-max (point-max))) | 2002 | (cursor-location |
| 1868 | (delete-region start end) | 2003 | (+ (- (length word) (- end start)) |
| 1869 | (funcall flyspell-insert-function new-word) | 2004 | cursor-location))) |
| 1870 | (if flyspell-abbrev-p | 2005 | (if (not (equal new-word (car poss))) |
| 1871 | (flyspell-define-abbrev word new-word)) | 2006 | (let ((old-max (point-max))) |
| 1872 | (flyspell-ajust-cursor-point save | 2007 | (delete-region start end) |
| 1873 | cursor-location | 2008 | (funcall flyspell-insert-function new-word) |
| 1874 | old-max))))) | 2009 | (if flyspell-abbrev-p |
| 1875 | (t | 2010 | (flyspell-define-abbrev word new-word)) |
| 1876 | (goto-char save) | 2011 | (flyspell-ajust-cursor-point save |
| 1877 | nil))) | 2012 | cursor-location |
| 1878 | ((eq flyspell-emacs 'xemacs) | 2013 | old-max))))) |
| 1879 | (flyspell-xemacs-popup | 2014 | (t |
| 1880 | event poss word cursor-location start end save) | 2015 | (goto-char save) |
| 1881 | (goto-char save))) | 2016 | nil))) |
| 1882 | (ispell-pdict-save t)))) | 2017 | ((eq flyspell-emacs 'xemacs) |
| 2018 | (flyspell-xemacs-popup | ||
| 2019 | event poss word cursor-location start end save) | ||
| 2020 | (goto-char save))) | ||
| 2021 | (ispell-pdict-save t)))))) | ||
| 1883 | 2022 | ||
| 1884 | ;*---------------------------------------------------------------------*/ | 2023 | ;*---------------------------------------------------------------------*/ |
| 1885 | ;* flyspell-xemacs-correct ... */ | 2024 | ;* flyspell-xemacs-correct ... */ |
diff --git a/lisp/textmodes/org.el b/lisp/textmodes/org.el index bd81f97138c..bbc59768aaf 100644 --- a/lisp/textmodes/org.el +++ b/lisp/textmodes/org.el | |||
| @@ -5,7 +5,7 @@ | |||
| 5 | ;; Author: Carsten Dominik <dominik at science dot uva dot nl> | 5 | ;; Author: Carsten Dominik <dominik at science dot uva dot nl> |
| 6 | ;; Keywords: outlines, hypermedia, calendar | 6 | ;; Keywords: outlines, hypermedia, calendar |
| 7 | ;; Homepage: http://www.astro.uva.nl/~dominik/Tools/org/ | 7 | ;; Homepage: http://www.astro.uva.nl/~dominik/Tools/org/ |
| 8 | ;; Version: 3.09 | 8 | ;; Version: 3.10 |
| 9 | ;; | 9 | ;; |
| 10 | ;; This file is part of GNU Emacs. | 10 | ;; This file is part of GNU Emacs. |
| 11 | ;; | 11 | ;; |
| @@ -80,6 +80,9 @@ | |||
| 80 | ;; | 80 | ;; |
| 81 | ;; Changes: | 81 | ;; Changes: |
| 82 | ;; ------- | 82 | ;; ------- |
| 83 | ;; Version 3.10 | ||
| 84 | ;; - Using `define-derived-mode' to derive `org-mode' from `outline-mode'. | ||
| 85 | ;; | ||
| 83 | ;; Version 3.09 | 86 | ;; Version 3.09 |
| 84 | ;; - Time-of-day specifications in agenda are extracted and placed | 87 | ;; - Time-of-day specifications in agenda are extracted and placed |
| 85 | ;; into the prefix. Timed entries can be placed into a time grid for | 88 | ;; into the prefix. Timed entries can be placed into a time grid for |
| @@ -151,10 +154,12 @@ | |||
| 151 | (require 'outline) | 154 | (require 'outline) |
| 152 | (require 'time-date) | 155 | (require 'time-date) |
| 153 | (require 'easymenu) | 156 | (require 'easymenu) |
| 157 | (or (fboundp 'run-mode-hooks) | ||
| 158 | (defalias 'run-mode-hooks 'run-hooks)) | ||
| 154 | 159 | ||
| 155 | ;;; Customization variables | 160 | ;;; Customization variables |
| 156 | 161 | ||
| 157 | (defvar org-version "3.09" | 162 | (defvar org-version "3.10" |
| 158 | "The version number of the file org.el.") | 163 | "The version number of the file org.el.") |
| 159 | (defun org-version () | 164 | (defun org-version () |
| 160 | (interactive) | 165 | (interactive) |
| @@ -372,7 +377,11 @@ Such files should use a file variable to set it, for example | |||
| 372 | 377 | ||
| 373 | -*- mode: org; org-category: \"ELisp\" | 378 | -*- mode: org; org-category: \"ELisp\" |
| 374 | 379 | ||
| 375 | If the file does not specify a category, the file's base name | 380 | or contain a special line |
| 381 | |||
| 382 | #+CATEGORY: ELisp | ||
| 383 | |||
| 384 | If the file does not specify a category, then file's base name | ||
| 376 | is used instead.") | 385 | is used instead.") |
| 377 | 386 | ||
| 378 | (defun org-set-regexps-and-options () | 387 | (defun org-set-regexps-and-options () |
| @@ -1525,7 +1534,7 @@ sets it back to nil.") | |||
| 1525 | 1534 | ||
| 1526 | 1535 | ||
| 1527 | ;;;###autoload | 1536 | ;;;###autoload |
| 1528 | (defun org-mode (&optional arg) | 1537 | (define-derived-mode org-mode outline-mode "Org" |
| 1529 | "Outline-based notes management and organizer, alias | 1538 | "Outline-based notes management and organizer, alias |
| 1530 | \"Carstens outline-mode for keeping track of everything.\" | 1539 | \"Carstens outline-mode for keeping track of everything.\" |
| 1531 | 1540 | ||
| @@ -1538,16 +1547,11 @@ calendar. Tables are easily created with a built-in table editor. | |||
| 1538 | Plain text URL-like links connect to websites, emails (VM), Usenet | 1547 | Plain text URL-like links connect to websites, emails (VM), Usenet |
| 1539 | messages (Gnus), BBDB entries, and any files related to the project. | 1548 | messages (Gnus), BBDB entries, and any files related to the project. |
| 1540 | For printing and sharing of notes, an Org-mode file (or a part of it) | 1549 | For printing and sharing of notes, an Org-mode file (or a part of it) |
| 1541 | can be exported as a well-structured ASCII or HTML file. | 1550 | can be exported as a structured ASCII or HTML file. |
| 1542 | 1551 | ||
| 1543 | The following commands are available: | 1552 | The following commands are available: |
| 1544 | 1553 | ||
| 1545 | \\{org-mode-map}" | 1554 | \\{org-mode-map}" |
| 1546 | (interactive "P") | ||
| 1547 | (outline-mode) | ||
| 1548 | (setq major-mode 'org-mode) | ||
| 1549 | (setq mode-name "Org") | ||
| 1550 | (use-local-map org-mode-map) | ||
| 1551 | (easy-menu-add org-org-menu) | 1555 | (easy-menu-add org-org-menu) |
| 1552 | (org-install-agenda-files-menu) | 1556 | (org-install-agenda-files-menu) |
| 1553 | (setq outline-regexp "\\*+") | 1557 | (setq outline-regexp "\\*+") |
| @@ -1569,15 +1573,10 @@ The following commands are available: | |||
| 1569 | (if org-enable-table-editor "|" "") | 1573 | (if org-enable-table-editor "|" "") |
| 1570 | (if org-enable-fixed-width-editor ":" "") | 1574 | (if org-enable-fixed-width-editor ":" "") |
| 1571 | "]")))) | 1575 | "]")))) |
| 1572 | ;; Hook, and startup actions | 1576 | (if (and org-insert-mode-line-in-empty-file |
| 1573 | (if (or arg | 1577 | (interactive-p) |
| 1574 | (and org-insert-mode-line-in-empty-file | 1578 | (= (point-min) (point-max))) |
| 1575 | (interactive-p) | 1579 | (insert " -*- mode: org -*-\n\n")) |
| 1576 | (= (point-min) (point-max)))) | ||
| 1577 | (save-excursion | ||
| 1578 | (goto-char (point-min)) | ||
| 1579 | (insert " -*- mode: org -*-\n\n"))) | ||
| 1580 | (run-hooks 'org-mode-hook) | ||
| 1581 | (unless org-inhibit-startup | 1580 | (unless org-inhibit-startup |
| 1582 | (if org-startup-with-deadline-check | 1581 | (if org-startup-with-deadline-check |
| 1583 | (call-interactively 'org-check-deadlines) | 1582 | (call-interactively 'org-check-deadlines) |
| @@ -1641,7 +1640,6 @@ The following commands are available: | |||
| 1641 | 'keymap org-mouse-map)) | 1640 | 'keymap org-mouse-map)) |
| 1642 | t))) | 1641 | t))) |
| 1643 | 1642 | ||
| 1644 | |||
| 1645 | (defun org-font-lock-level () | 1643 | (defun org-font-lock-level () |
| 1646 | (save-excursion | 1644 | (save-excursion |
| 1647 | (org-back-to-heading t) | 1645 | (org-back-to-heading t) |
| @@ -3120,7 +3118,7 @@ The following commands are available: | |||
| 3120 | "--") | 3118 | "--") |
| 3121 | (mapcar 'org-file-menu-entry org-agenda-files))) | 3119 | (mapcar 'org-file-menu-entry org-agenda-files))) |
| 3122 | (org-agenda-set-mode-name) | 3120 | (org-agenda-set-mode-name) |
| 3123 | (run-hooks 'org-agenda-mode-hook)) | 3121 | (run-mode-hooks 'org-agenda-mode-hook)) |
| 3124 | 3122 | ||
| 3125 | (define-key org-agenda-mode-map [(tab)] 'org-agenda-goto) | 3123 | (define-key org-agenda-mode-map [(tab)] 'org-agenda-goto) |
| 3126 | (define-key org-agenda-mode-map [(return)] 'org-agenda-switch-to) | 3124 | (define-key org-agenda-mode-map [(return)] 'org-agenda-switch-to) |
| @@ -6700,7 +6698,7 @@ table editor in arbitrary modes.") | |||
| 6700 | (concat "\\([ \t]*|\\|" auto-fill-inhibit-regexp) | 6698 | (concat "\\([ \t]*|\\|" auto-fill-inhibit-regexp) |
| 6701 | "[ \t]*|")) | 6699 | "[ \t]*|")) |
| 6702 | (easy-menu-add orgtbl-mode-menu) | 6700 | (easy-menu-add orgtbl-mode-menu) |
| 6703 | (run-hooks (quote orgtbl-mode-hook))) | 6701 | (run-hooks 'orgtbl-mode-hook)) |
| 6704 | (setq auto-fill-inhibit-regexp org-old-auto-fill-inhibit-regexp) | 6702 | (setq auto-fill-inhibit-regexp org-old-auto-fill-inhibit-regexp) |
| 6705 | (remove-hook 'before-change-functions 'org-before-change-function t) | 6703 | (remove-hook 'before-change-functions 'org-before-change-function t) |
| 6706 | (easy-menu-remove orgtbl-mode-menu) | 6704 | (easy-menu-remove orgtbl-mode-menu) |
| @@ -8433,7 +8431,7 @@ the automatic table editor has been turned off." | |||
| 8433 | 8431 | ||
| 8434 | ;;; Menu entries | 8432 | ;;; Menu entries |
| 8435 | 8433 | ||
| 8436 | ;; First, remove the outline menus. | 8434 | ;; First, remove the outline menus. Org-mode does not neede these commands. |
| 8437 | (if org-xemacs-p | 8435 | (if org-xemacs-p |
| 8438 | (add-hook 'org-mode-hook | 8436 | (add-hook 'org-mode-hook |
| 8439 | (lambda () | 8437 | (lambda () |
| @@ -8442,7 +8440,7 @@ the automatic table editor has been turned off." | |||
| 8442 | (delete-menu-item '("Hide")) | 8440 | (delete-menu-item '("Hide")) |
| 8443 | (set-menubar-dirty-flag))) | 8441 | (set-menubar-dirty-flag))) |
| 8444 | (setq org-mode-map (delq (assoc 'menu-bar (cdr org-mode-map)) | 8442 | (setq org-mode-map (delq (assoc 'menu-bar (cdr org-mode-map)) |
| 8445 | org-mode-map))) | 8443 | org-mode-map))) |
| 8446 | 8444 | ||
| 8447 | ;; Define the Org-mode menus | 8445 | ;; Define the Org-mode menus |
| 8448 | (easy-menu-define org-org-menu org-mode-map "Org menu" | 8446 | (easy-menu-define org-org-menu org-mode-map "Org menu" |
diff --git a/lisp/textmodes/reftex-index.el b/lisp/textmodes/reftex-index.el index ff2ea70a011..43e56df6685 100644 --- a/lisp/textmodes/reftex-index.el +++ b/lisp/textmodes/reftex-index.el | |||
| @@ -310,7 +310,7 @@ Here are all local bindings. | |||
| 310 | (easy-menu-add reftex-index-menu reftex-index-map) | 310 | (easy-menu-add reftex-index-menu reftex-index-map) |
| 311 | (add-hook 'post-command-hook 'reftex-index-post-command-hook nil t) | 311 | (add-hook 'post-command-hook 'reftex-index-post-command-hook nil t) |
| 312 | (add-hook 'pre-command-hook 'reftex-index-pre-command-hook nil t) | 312 | (add-hook 'pre-command-hook 'reftex-index-pre-command-hook nil t) |
| 313 | (run-hooks 'reftex-index-mode-hook)) | 313 | (run-mode-hooks 'reftex-index-mode-hook)) |
| 314 | 314 | ||
| 315 | (defconst reftex-index-help | 315 | (defconst reftex-index-help |
| 316 | " AVAILABLE KEYS IN INDEX BUFFER | 316 | " AVAILABLE KEYS IN INDEX BUFFER |
| @@ -1308,7 +1308,7 @@ Here are all local bindings. | |||
| 1308 | reftex-index-phrases-font-lock-defaults) | 1308 | reftex-index-phrases-font-lock-defaults) |
| 1309 | (easy-menu-add reftex-index-phrases-menu reftex-index-phrases-map) | 1309 | (easy-menu-add reftex-index-phrases-menu reftex-index-phrases-map) |
| 1310 | (set (make-local-variable 'reftex-index-phrases-marker) (make-marker)) | 1310 | (set (make-local-variable 'reftex-index-phrases-marker) (make-marker)) |
| 1311 | (run-hooks 'reftex-index-phrases-mode-hook)) | 1311 | (run-mode-hooks 'reftex-index-phrases-mode-hook)) |
| 1312 | (add-hook 'reftex-index-phrases-mode-hook 'turn-on-font-lock) | 1312 | (add-hook 'reftex-index-phrases-mode-hook 'turn-on-font-lock) |
| 1313 | 1313 | ||
| 1314 | ;; Font Locking stuff | 1314 | ;; Font Locking stuff |
diff --git a/lisp/textmodes/reftex-sel.el b/lisp/textmodes/reftex-sel.el index eb8c3035c90..725c5122a0b 100644 --- a/lisp/textmodes/reftex-sel.el +++ b/lisp/textmodes/reftex-sel.el | |||
| @@ -60,7 +60,7 @@ During a selection process, these are the local bindings. | |||
| 60 | (when (syntax-table-p reftex-latex-syntax-table) | 60 | (when (syntax-table-p reftex-latex-syntax-table) |
| 61 | (set-syntax-table reftex-latex-syntax-table)) | 61 | (set-syntax-table reftex-latex-syntax-table)) |
| 62 | ;; We do not set a local map - reftex-select-item does this. | 62 | ;; We do not set a local map - reftex-select-item does this. |
| 63 | (run-hooks 'reftex-select-label-mode-hook)) | 63 | (run-mode-hooks 'reftex-select-label-mode-hook)) |
| 64 | 64 | ||
| 65 | (defvar reftex-select-bib-map nil | 65 | (defvar reftex-select-bib-map nil |
| 66 | "Keymap used for *RefTeX Select* buffer, when selecting a BibTeX entry. | 66 | "Keymap used for *RefTeX Select* buffer, when selecting a BibTeX entry. |
| @@ -88,7 +88,7 @@ During a selection process, these are the local bindings. | |||
| 88 | mode-name "BSelect") | 88 | mode-name "BSelect") |
| 89 | (set (make-local-variable 'reftex-select-marked) nil) | 89 | (set (make-local-variable 'reftex-select-marked) nil) |
| 90 | ;; We do not set a local map - reftex-select-item does this. | 90 | ;; We do not set a local map - reftex-select-item does this. |
| 91 | (run-hooks 'reftex-select-bib-mode-hook)) | 91 | (run-mode-hooks 'reftex-select-bib-mode-hook)) |
| 92 | 92 | ||
| 93 | ;;; (defun reftex-get-offset (buf here-am-I &optional typekey toc index file) | 93 | ;;; (defun reftex-get-offset (buf here-am-I &optional typekey toc index file) |
| 94 | ;;; ;; Find the correct offset data, like insert-docstruct would, but faster. | 94 | ;;; ;; Find the correct offset data, like insert-docstruct would, but faster. |
diff --git a/lisp/textmodes/reftex-toc.el b/lisp/textmodes/reftex-toc.el index 8ad811391c7..b5edba97f4b 100644 --- a/lisp/textmodes/reftex-toc.el +++ b/lisp/textmodes/reftex-toc.el | |||
| @@ -73,7 +73,7 @@ Here are all local bindings. | |||
| 73 | (add-hook 'post-command-hook 'reftex-toc-post-command-hook nil t) | 73 | (add-hook 'post-command-hook 'reftex-toc-post-command-hook nil t) |
| 74 | (add-hook 'pre-command-hook 'reftex-toc-pre-command-hook nil t) | 74 | (add-hook 'pre-command-hook 'reftex-toc-pre-command-hook nil t) |
| 75 | (easy-menu-add reftex-toc-menu reftex-toc-map) | 75 | (easy-menu-add reftex-toc-menu reftex-toc-map) |
| 76 | (run-hooks 'reftex-toc-mode-hook)) | 76 | (run-mode-hooks 'reftex-toc-mode-hook)) |
| 77 | 77 | ||
| 78 | (defvar reftex-last-toc-file nil | 78 | (defvar reftex-last-toc-file nil |
| 79 | "Stores the file name from which `reftex-toc' was called. For redo command.") | 79 | "Stores the file name from which `reftex-toc' was called. For redo command.") |
diff --git a/lisp/textmodes/sgml-mode.el b/lisp/textmodes/sgml-mode.el index 34d39807d2d..21259ee0ccf 100644 --- a/lisp/textmodes/sgml-mode.el +++ b/lisp/textmodes/sgml-mode.el | |||
| @@ -248,7 +248,8 @@ Any terminating `>' or `/' is not matched.") | |||
| 248 | 248 | ||
| 249 | (defface sgml-namespace-face | 249 | (defface sgml-namespace-face |
| 250 | '((t (:inherit font-lock-builtin-face))) | 250 | '((t (:inherit font-lock-builtin-face))) |
| 251 | "`sgml-mode' face used to highlight the namespace part of identifiers.") | 251 | "`sgml-mode' face used to highlight the namespace part of identifiers." |
| 252 | :group 'sgml) | ||
| 252 | (defvar sgml-namespace-face 'sgml-namespace-face) | 253 | (defvar sgml-namespace-face 'sgml-namespace-face) |
| 253 | 254 | ||
| 254 | ;; internal | 255 | ;; internal |
diff --git a/lisp/textmodes/tex-mode.el b/lisp/textmodes/tex-mode.el index 04507fbc5e4..3b5bab5b4dc 100644 --- a/lisp/textmodes/tex-mode.el +++ b/lisp/textmodes/tex-mode.el | |||
| @@ -643,19 +643,23 @@ An alternative value is \" . \", if you use a font with a narrow period." | |||
| 643 | 643 | ||
| 644 | (defface superscript | 644 | (defface superscript |
| 645 | '((t :height 0.8)) ;; :raise 0.3 | 645 | '((t :height 0.8)) ;; :raise 0.3 |
| 646 | "Face used for superscripts.") | 646 | "Face used for superscripts." |
| 647 | :group 'tex) | ||
| 647 | (defface subscript | 648 | (defface subscript |
| 648 | '((t :height 0.8)) ;; :raise -0.3 | 649 | '((t :height 0.8)) ;; :raise -0.3 |
| 649 | "Face used for subscripts.") | 650 | "Face used for subscripts." |
| 651 | :group 'tex) | ||
| 650 | 652 | ||
| 651 | (defface tex-math-face | 653 | (defface tex-math-face |
| 652 | '((t :inherit font-lock-string-face)) | 654 | '((t :inherit font-lock-string-face)) |
| 653 | "Face used to highlight TeX math expressions.") | 655 | "Face used to highlight TeX math expressions." |
| 656 | :group 'tex) | ||
| 654 | (defvar tex-math-face 'tex-math-face) | 657 | (defvar tex-math-face 'tex-math-face) |
| 655 | (defface tex-verbatim-face | 658 | (defface tex-verbatim-face |
| 656 | ;; '((t :inherit font-lock-string-face)) | 659 | ;; '((t :inherit font-lock-string-face)) |
| 657 | '((t :family "courier")) | 660 | '((t :family "courier")) |
| 658 | "Face used to highlight TeX verbatim environments.") | 661 | "Face used to highlight TeX verbatim environments." |
| 662 | :group 'tex) | ||
| 659 | (defvar tex-verbatim-face 'tex-verbatim-face) | 663 | (defvar tex-verbatim-face 'tex-verbatim-face) |
| 660 | 664 | ||
| 661 | ;; Use string syntax but math face for $...$. | 665 | ;; Use string syntax but math face for $...$. |
| @@ -1623,7 +1627,8 @@ If NOT-ALL is non-nil, save the `.dvi' file." | |||
| 1623 | 1627 | ||
| 1624 | (defcustom tex-use-reftex t | 1628 | (defcustom tex-use-reftex t |
| 1625 | "If non-nil, use RefTeX's list of files to determine what command to use." | 1629 | "If non-nil, use RefTeX's list of files to determine what command to use." |
| 1626 | :type 'boolean) | 1630 | :type 'boolean |
| 1631 | :group 'tex) | ||
| 1627 | 1632 | ||
| 1628 | (defvar tex-compile-commands | 1633 | (defvar tex-compile-commands |
| 1629 | '(((concat "pdf" tex-command | 1634 | '(((concat "pdf" tex-command |
| @@ -2227,8 +2232,7 @@ is provided, use the alternative command, `tex-alt-dvi-print-command'." | |||
| 2227 | (tex-start-shell)) | 2232 | (tex-start-shell)) |
| 2228 | (tex-send-command | 2233 | (tex-send-command |
| 2229 | (if alt tex-alt-dvi-print-command tex-dvi-print-command) | 2234 | (if alt tex-alt-dvi-print-command tex-dvi-print-command) |
| 2230 | (shell-quote-argument | 2235 | print-file-name-dvi |
| 2231 | print-file-name-dvi) | ||
| 2232 | t)))) | 2236 | t)))) |
| 2233 | 2237 | ||
| 2234 | (defun tex-alt-print () | 2238 | (defun tex-alt-print () |
diff --git a/lisp/textmodes/texinfo.el b/lisp/textmodes/texinfo.el index ec983077d26..bd14c658379 100644 --- a/lisp/textmodes/texinfo.el +++ b/lisp/textmodes/texinfo.el | |||
| @@ -345,7 +345,8 @@ Subexpression 1 is what goes into the corresponding `@end' statement.") | |||
| 345 | 345 | ||
| 346 | (defface texinfo-heading-face | 346 | (defface texinfo-heading-face |
| 347 | '((t (:inherit font-lock-function-name-face))) | 347 | '((t (:inherit font-lock-function-name-face))) |
| 348 | "Face used for section headings in `texinfo-mode'.") | 348 | "Face used for section headings in `texinfo-mode'." |
| 349 | :group 'texinfo) | ||
| 349 | (defvar texinfo-heading-face 'texinfo-heading-face) | 350 | (defvar texinfo-heading-face 'texinfo-heading-face) |
| 350 | 351 | ||
| 351 | (defvar texinfo-font-lock-keywords | 352 | (defvar texinfo-font-lock-keywords |
diff --git a/lisp/thumbs.el b/lisp/thumbs.el index 1657c4b01a9..321fe7266cc 100644 --- a/lisp/thumbs.el +++ b/lisp/thumbs.el | |||
| @@ -302,18 +302,21 @@ Or, alternatively, a SIZE may be specified." | |||
| 302 | 302 | ||
| 303 | (defun thumbs-thumbname (img) | 303 | (defun thumbs-thumbname (img) |
| 304 | "Return a thumbnail name for the image IMG." | 304 | "Return a thumbnail name for the image IMG." |
| 305 | (concat thumbs-thumbsdir "/" | 305 | (convert-standard-filename |
| 306 | (subst-char-in-string | 306 | (let ((filename (expand-file-name img))) |
| 307 | ?\ ?\_ | 307 | (format "%s/%08x-%s.jpg" |
| 308 | (apply | 308 | thumbs-thumbsdir |
| 309 | 'concat | 309 | (sxhash filename) |
| 310 | (split-string | 310 | (subst-char-in-string |
| 311 | (expand-file-name img) "/"))))) | 311 | ?\s ?\_ |
| 312 | (apply | ||
| 313 | 'concat | ||
| 314 | (split-string filename "/"))))))) | ||
| 312 | 315 | ||
| 313 | (defun thumbs-make-thumb (img) | 316 | (defun thumbs-make-thumb (img) |
| 314 | "Create the thumbnail for IMG." | 317 | "Create the thumbnail for IMG." |
| 315 | (let* ((fn (expand-file-name img)) | 318 | (let ((fn (expand-file-name img)) |
| 316 | (tn (thumbs-thumbname img))) | 319 | (tn (thumbs-thumbname img))) |
| 317 | (if (or (not (file-exists-p tn)) | 320 | (if (or (not (file-exists-p tn)) |
| 318 | ;; This is not the right fix, but I don't understand | 321 | ;; This is not the right fix, but I don't understand |
| 319 | ;; the external program or why it produces a geometry | 322 | ;; the external program or why it produces a geometry |
| @@ -378,8 +381,9 @@ If MARKED is non-nil, the image is marked." | |||
| 378 | (unless (bobp) (newline)))) | 381 | (unless (bobp) (newline)))) |
| 379 | 382 | ||
| 380 | (defun thumbs-show-thumbs-list (L &optional buffer-name same-window) | 383 | (defun thumbs-show-thumbs-list (L &optional buffer-name same-window) |
| 381 | (when (not (display-images-p)) | 384 | (unless (and (display-images-p) |
| 382 | (error "Images are not supported in this Emacs session")) | 385 | (image-type-available-p 'jpeg)) |
| 386 | (error "Required image type is not supported in this Emacs session")) | ||
| 383 | (funcall (if same-window 'switch-to-buffer 'pop-to-buffer) | 387 | (funcall (if same-window 'switch-to-buffer 'pop-to-buffer) |
| 384 | (or buffer-name "*THUMB-View*")) | 388 | (or buffer-name "*THUMB-View*")) |
| 385 | (let ((inhibit-read-only t)) | 389 | (let ((inhibit-read-only t)) |
| @@ -754,9 +758,8 @@ ACTION and ARG should be a valid convert command." | |||
| 754 | (define-derived-mode thumbs-mode | 758 | (define-derived-mode thumbs-mode |
| 755 | fundamental-mode "thumbs" | 759 | fundamental-mode "thumbs" |
| 756 | "Preview images in a thumbnails buffer" | 760 | "Preview images in a thumbnails buffer" |
| 757 | (make-variable-buffer-local 'thumbs-markedL) | ||
| 758 | (setq buffer-read-only t) | 761 | (setq buffer-read-only t) |
| 759 | (setq thumbs-markedL nil)) | 762 | (set (make-local-variable 'thumbs-markedL) nil)) |
| 760 | 763 | ||
| 761 | (defvar thumbs-view-image-mode-map | 764 | (defvar thumbs-view-image-mode-map |
| 762 | (let ((map (make-sparse-keymap))) | 765 | (let ((map (make-sparse-keymap))) |
| @@ -793,7 +796,5 @@ ACTION and ARG should be a valid convert command." | |||
| 793 | 796 | ||
| 794 | (provide 'thumbs) | 797 | (provide 'thumbs) |
| 795 | 798 | ||
| 799 | ;; arch-tag: f9ac1ef8-83fc-42c0-8069-1fae43fd2e5c | ||
| 796 | ;;; thumbs.el ends here | 800 | ;;; thumbs.el ends here |
| 797 | |||
| 798 | |||
| 799 | ;;; arch-tag: f9ac1ef8-83fc-42c0-8069-1fae43fd2e5c | ||
diff --git a/lisp/time.el b/lisp/time.el index ddf0d932733..180d7c44cf3 100644 --- a/lisp/time.el +++ b/lisp/time.el | |||
| @@ -200,6 +200,7 @@ depend on `display-time-day-and-date' and `display-time-24hr-format'." | |||
| 200 | (list :background bg))))) | 200 | (list :background bg))))) |
| 201 | 'face display-time-mail-face | 201 | 'face display-time-mail-face |
| 202 | 'help-echo "You have new mail; mouse-2: Read mail" | 202 | 'help-echo "You have new mail; mouse-2: Read mail" |
| 203 | 'mouse-face 'mode-line-highlight | ||
| 203 | 'local-map (make-mode-line-mouse-map 'mouse-2 | 204 | 'local-map (make-mode-line-mouse-map 'mouse-2 |
| 204 | read-mail-command))) | 205 | read-mail-command))) |
| 205 | "")) | 206 | "")) |
| @@ -293,6 +294,7 @@ update which can wait for the next redisplay." | |||
| 293 | (concat (substring str 0 -2) "." (substring str -2)) | 294 | (concat (substring str 0 -2) "." (substring str -2)) |
| 294 | 'local-map (make-mode-line-mouse-map | 295 | 'local-map (make-mode-line-mouse-map |
| 295 | 'mouse-2 'display-time-next-load-average) | 296 | 'mouse-2 'display-time-next-load-average) |
| 297 | 'mouse-face 'mode-line-highlight | ||
| 296 | 'help-echo (concat | 298 | 'help-echo (concat |
| 297 | "System load average for past " | 299 | "System load average for past " |
| 298 | (if (= 0 display-time-load-average) | 300 | (if (= 0 display-time-load-average) |
diff --git a/lisp/tmm.el b/lisp/tmm.el index 168dbdd14dc..51e04941730 100644 --- a/lisp/tmm.el +++ b/lisp/tmm.el | |||
| @@ -133,6 +133,12 @@ specify nil for this variable." | |||
| 133 | :type '(choice integer (const nil)) | 133 | :type '(choice integer (const nil)) |
| 134 | :group 'tmm) | 134 | :group 'tmm) |
| 135 | 135 | ||
| 136 | (require 'font-lock) | ||
| 137 | (defface tmm-inactive-face | ||
| 138 | '((t :inherit font-lock-comment-face)) | ||
| 139 | "Face used for inactive menu items." | ||
| 140 | :group 'tmm) | ||
| 141 | |||
| 136 | ;;;###autoload | 142 | ;;;###autoload |
| 137 | (defun tmm-prompt (menu &optional in-popup default-item) | 143 | (defun tmm-prompt (menu &optional in-popup default-item) |
| 138 | "Text-mode emulation of calling the bindings in keymap. | 144 | "Text-mode emulation of calling the bindings in keymap. |
| @@ -193,7 +199,14 @@ Its value should be an event that has a binding in MENU." | |||
| 193 | (eq (car-safe (cdr (car tail))) 'menu-item))) | 199 | (eq (car-safe (cdr (car tail))) 'menu-item))) |
| 194 | (setq index-of-default (1+ index-of-default))) | 200 | (setq index-of-default (1+ index-of-default))) |
| 195 | (setq tail (cdr tail))))) | 201 | (setq tail (cdr tail))))) |
| 196 | (setq history (reverse (mapcar 'car tmm-km-list))) | 202 | (let ((prompt (concat "^." (regexp-quote tmm-mid-prompt)))) |
| 203 | (setq history | ||
| 204 | (reverse (delq nil | ||
| 205 | (mapcar | ||
| 206 | (lambda (elt) | ||
| 207 | (if (string-match prompt (car elt)) | ||
| 208 | (car elt))) | ||
| 209 | tmm-km-list))))) | ||
| 197 | (setq history-len (length history)) | 210 | (setq history-len (length history)) |
| 198 | (setq history (append history history history history)) | 211 | (setq history (append history history history history)) |
| 199 | (setq tmm-c-prompt (nth (- history-len 1 index-of-default) history)) | 212 | (setq tmm-c-prompt (nth (- history-len 1 index-of-default) history)) |
| @@ -259,37 +272,43 @@ Stores a list of all the shortcuts in the free variable `tmm-short-cuts'." | |||
| 259 | 272 | ||
| 260 | (defsubst tmm-add-one-shortcut (elt) | 273 | (defsubst tmm-add-one-shortcut (elt) |
| 261 | ;; uses the free vars tmm-next-shortcut-digit and tmm-short-cuts | 274 | ;; uses the free vars tmm-next-shortcut-digit and tmm-short-cuts |
| 262 | (let* ((str (car elt)) | 275 | (cond |
| 263 | (paren (string-match "(" str)) | 276 | ((eq (cddr elt) 'ignore) |
| 264 | (pos 0) (word 0) char) | 277 | (cons (concat " " (make-string (length tmm-mid-prompt) ?\-) |
| 265 | (catch 'done ; ??? is this slow? | 278 | (car elt)) |
| 266 | (while (and (or (not tmm-shortcut-words) ; no limit on words | 279 | (cdr elt))) |
| 267 | (< word tmm-shortcut-words)) ; try n words | 280 | (t |
| 268 | (setq pos (string-match "\\w+" str pos)) ; get next word | 281 | (let* ((str (car elt)) |
| 269 | (not (and paren (> pos paren)))) ; don't go past "(binding.." | 282 | (paren (string-match "(" str)) |
| 270 | (if (or (= pos 0) | 283 | (pos 0) (word 0) char) |
| 271 | (/= (aref str (1- pos)) ?.)) ; avoid file extensions | 284 | (catch 'done ; ??? is this slow? |
| 272 | (let ((shortcut-style | 285 | (while (and (or (not tmm-shortcut-words) ; no limit on words |
| 273 | (if (listp tmm-shortcut-style) ; convert to list | 286 | (< word tmm-shortcut-words)) ; try n words |
| 274 | tmm-shortcut-style | 287 | (setq pos (string-match "\\w+" str pos)) ; get next word |
| 275 | (list tmm-shortcut-style)))) | 288 | (not (and paren (> pos paren)))) ; don't go past "(binding.." |
| 276 | (while shortcut-style ; try upcase and downcase variants | 289 | (if (or (= pos 0) |
| 277 | (setq char (funcall (car shortcut-style) (aref str pos))) | 290 | (/= (aref str (1- pos)) ?.)) ; avoid file extensions |
| 278 | (if (not (memq char tmm-short-cuts)) (throw 'done char)) | 291 | (let ((shortcut-style |
| 279 | (setq shortcut-style (cdr shortcut-style))))) | 292 | (if (listp tmm-shortcut-style) ; convert to list |
| 280 | (setq word (1+ word)) | 293 | tmm-shortcut-style |
| 281 | (setq pos (match-end 0))) | 294 | (list tmm-shortcut-style)))) |
| 282 | (while (<= tmm-next-shortcut-digit ?9) ; no letter shortcut, pick a digit | 295 | (while shortcut-style ; try upcase and downcase variants |
| 283 | (setq char tmm-next-shortcut-digit) | 296 | (setq char (funcall (car shortcut-style) (aref str pos))) |
| 284 | (setq tmm-next-shortcut-digit (1+ tmm-next-shortcut-digit)) | 297 | (if (not (memq char tmm-short-cuts)) (throw 'done char)) |
| 285 | (if (not (memq char tmm-short-cuts)) (throw 'done char))) | 298 | (setq shortcut-style (cdr shortcut-style))))) |
| 286 | (setq char nil)) | 299 | (setq word (1+ word)) |
| 287 | (if char (setq tmm-short-cuts (cons char tmm-short-cuts))) | 300 | (setq pos (match-end 0))) |
| 288 | (cons (concat (if char (concat (char-to-string char) tmm-mid-prompt) | 301 | (while (<= tmm-next-shortcut-digit ?9) ; no letter shortcut, pick a digit |
| 289 | ;; keep them lined up in columns | 302 | (setq char tmm-next-shortcut-digit) |
| 290 | (make-string (1+ (length tmm-mid-prompt)) ?\ )) | 303 | (setq tmm-next-shortcut-digit (1+ tmm-next-shortcut-digit)) |
| 291 | str) | 304 | (if (not (memq char tmm-short-cuts)) (throw 'done char))) |
| 292 | (cdr elt)))) | 305 | (setq char nil)) |
| 306 | (if char (setq tmm-short-cuts (cons char tmm-short-cuts))) | ||
| 307 | (cons (concat (if char (concat (char-to-string char) tmm-mid-prompt) | ||
| 308 | ;; keep them lined up in columns | ||
| 309 | (make-string (1+ (length tmm-mid-prompt)) ?\ )) | ||
| 310 | str) | ||
| 311 | (cdr elt)))))) | ||
| 293 | 312 | ||
| 294 | ;; This returns the old map. | 313 | ;; This returns the old map. |
| 295 | (defun tmm-define-keys (minibuffer) | 314 | (defun tmm-define-keys (minibuffer) |
| @@ -319,9 +338,27 @@ Stores a list of all the shortcuts in the free variable `tmm-short-cuts'." | |||
| 319 | (goto-char 1) | 338 | (goto-char 1) |
| 320 | (delete-region 1 (search-forward "Possible completions are:\n"))) | 339 | (delete-region 1 (search-forward "Possible completions are:\n"))) |
| 321 | 340 | ||
| 341 | (defun tmm-remove-inactive-mouse-face () | ||
| 342 | "Remove the mouse-face property from inactive menu items." | ||
| 343 | (let ((inhibit-read-only t) | ||
| 344 | (inactive-string | ||
| 345 | (concat " " (make-string (length tmm-mid-prompt) ?\-))) | ||
| 346 | next) | ||
| 347 | (save-excursion | ||
| 348 | (goto-char (point-min)) | ||
| 349 | (while (not (eobp)) | ||
| 350 | (setq next (next-single-char-property-change (point) 'mouse-face)) | ||
| 351 | (when (looking-at inactive-string) | ||
| 352 | (remove-text-properties (point) next '(mouse-face)) | ||
| 353 | (add-text-properties (point) next '(face tmm-inactive-face))) | ||
| 354 | (goto-char next))) | ||
| 355 | (set-buffer-modified-p nil))) | ||
| 356 | |||
| 322 | (defun tmm-add-prompt () | 357 | (defun tmm-add-prompt () |
| 323 | (remove-hook 'minibuffer-setup-hook 'tmm-add-prompt) | 358 | (remove-hook 'minibuffer-setup-hook 'tmm-add-prompt) |
| 324 | (add-hook 'minibuffer-exit-hook 'tmm-delete-map nil t) | 359 | (add-hook 'minibuffer-exit-hook 'tmm-delete-map nil t) |
| 360 | (unless tmm-c-prompt | ||
| 361 | (error "No active menu entries")) | ||
| 325 | (let ((win (selected-window))) | 362 | (let ((win (selected-window))) |
| 326 | (setq tmm-old-mb-map (tmm-define-keys t)) | 363 | (setq tmm-old-mb-map (tmm-define-keys t)) |
| 327 | ;; Get window and hide it for electric mode to get correct size | 364 | ;; Get window and hide it for electric mode to get correct size |
| @@ -334,8 +371,9 @@ Stores a list of all the shortcuts in the free variable `tmm-short-cuts'." | |||
| 334 | (with-output-to-temp-buffer "*Completions*" | 371 | (with-output-to-temp-buffer "*Completions*" |
| 335 | (display-completion-list completions)) | 372 | (display-completion-list completions)) |
| 336 | (remove-hook 'completion-setup-hook 'tmm-completion-delete-prompt)) | 373 | (remove-hook 'completion-setup-hook 'tmm-completion-delete-prompt)) |
| 374 | (set-buffer "*Completions*") | ||
| 375 | (tmm-remove-inactive-mouse-face) | ||
| 337 | (when tmm-completion-prompt | 376 | (when tmm-completion-prompt |
| 338 | (set-buffer "*Completions*") | ||
| 339 | (let ((buffer-read-only nil)) | 377 | (let ((buffer-read-only nil)) |
| 340 | (goto-char (point-min)) | 378 | (goto-char (point-min)) |
| 341 | (insert tmm-completion-prompt)))) | 379 | (insert tmm-completion-prompt)))) |
| @@ -345,7 +383,6 @@ Stores a list of all the shortcuts in the free variable `tmm-short-cuts'." | |||
| 345 | (Electric-pop-up-window "*Completions*") | 383 | (Electric-pop-up-window "*Completions*") |
| 346 | (with-current-buffer "*Completions*" | 384 | (with-current-buffer "*Completions*" |
| 347 | (setq tmm-old-comp-map (tmm-define-keys nil)))) | 385 | (setq tmm-old-comp-map (tmm-define-keys nil)))) |
| 348 | |||
| 349 | (insert tmm-c-prompt))) | 386 | (insert tmm-c-prompt))) |
| 350 | 387 | ||
| 351 | (defun tmm-delete-map () | 388 | (defun tmm-delete-map () |
| @@ -438,7 +475,7 @@ It uses the free variable `tmm-table-undef' to keep undefined keys." | |||
| 438 | (setq km (and (eval visible) km))) | 475 | (setq km (and (eval visible) km))) |
| 439 | (setq enable (plist-get plist :enable)) | 476 | (setq enable (plist-get plist :enable)) |
| 440 | (if enable | 477 | (if enable |
| 441 | (setq km (and (eval enable) km))) | 478 | (setq km (if (eval enable) km 'ignore))) |
| 442 | (and str | 479 | (and str |
| 443 | (consp (nth 3 elt)) | 480 | (consp (nth 3 elt)) |
| 444 | (stringp (cdr (nth 3 elt))) ; keyseq cache | 481 | (stringp (cdr (nth 3 elt))) ; keyseq cache |
| @@ -467,8 +504,7 @@ It uses the free variable `tmm-table-undef' to keep undefined keys." | |||
| 467 | ;; Verify that the command is enabled; | 504 | ;; Verify that the command is enabled; |
| 468 | ;; if not, don't mention it. | 505 | ;; if not, don't mention it. |
| 469 | (when (and km (symbolp km) (get km 'menu-enable)) | 506 | (when (and km (symbolp km) (get km 'menu-enable)) |
| 470 | (unless (eval (get km 'menu-enable)) | 507 | (setq km (if (eval (get km 'menu-enable)) km 'ignore))) |
| 471 | (setq km nil))) | ||
| 472 | (and km str | 508 | (and km str |
| 473 | (or (assoc str tmm-km-list) | 509 | (or (assoc str tmm-km-list) |
| 474 | (push (cons str (cons event km)) tmm-km-list)))))) | 510 | (push (cons str (cons event km)) tmm-km-list)))))) |
diff --git a/lisp/toolbar/gud-break.xpm b/lisp/toolbar/gud-break.xpm index 419955dd109..2ffc2748271 100644 --- a/lisp/toolbar/gud-break.xpm +++ b/lisp/toolbar/gud-break.xpm | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | /* XPM */ | 1 | /* XPM */ |
| 2 | static char * stop_xpm[] = { | 2 | static char * stop_xpm[] = { |
| 3 | "24 24 3 1", | 3 | "24 24 3 1", |
| 4 | " c #C0C0C0C0C0C0", | 4 | " c None", |
| 5 | ". c #F8F810104040", | 5 | ". c #F8F810104040", |
| 6 | "X c #F8F8FCFCF8F8", | 6 | "X c #F8F8FCFCF8F8", |
| 7 | " ", | 7 | " ", |
diff --git a/lisp/toolbar/gud-cont.xpm b/lisp/toolbar/gud-cont.xpm index 4863a955bec..9da91af994f 100644 --- a/lisp/toolbar/gud-cont.xpm +++ b/lisp/toolbar/gud-cont.xpm | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | /* XPM */ | 1 | /* XPM */ |
| 2 | static char * continue_xpm[] = { | 2 | static char * continue_xpm[] = { |
| 3 | "24 24 6 1", | 3 | "24 24 6 1", |
| 4 | " c #c0c0c0", | 4 | " c None", |
| 5 | ". c #cc0033", | 5 | ". c #cc0033", |
| 6 | "X c #d99faa", | 6 | "X c #d99faa", |
| 7 | "o c #616161", | 7 | "o c #616161", |
diff --git a/lisp/toolbar/gud-down.xpm b/lisp/toolbar/gud-down.xpm index 77e93fdfa19..30f3af89cce 100644 --- a/lisp/toolbar/gud-down.xpm +++ b/lisp/toolbar/gud-down.xpm | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | /* XPM */ | 1 | /* XPM */ |
| 2 | static char * down_xpm[] = { | 2 | static char * down_xpm[] = { |
| 3 | "24 24 14 1", | 3 | "24 24 14 1", |
| 4 | " c #C0C0C0C0C0C0", | 4 | " c None", |
| 5 | ". c #000000000000", | 5 | ". c #000000000000", |
| 6 | "X c #7F7F7F7F7F7F", | 6 | "X c #7F7F7F7F7F7F", |
| 7 | "o c #2D2D2D2D2D2D", | 7 | "o c #2D2D2D2D2D2D", |
diff --git a/lisp/toolbar/gud-finish.xpm b/lisp/toolbar/gud-finish.xpm index 59066450ee3..0310f07e8da 100644 --- a/lisp/toolbar/gud-finish.xpm +++ b/lisp/toolbar/gud-finish.xpm | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | /* XPM */ | 1 | /* XPM */ |
| 2 | static char * finish_xpm[] = { | 2 | static char * finish_xpm[] = { |
| 3 | "24 24 7 1", | 3 | "24 24 7 1", |
| 4 | " c #c0c0c0", | 4 | " c None", |
| 5 | ". c #cc0033", | 5 | ". c #cc0033", |
| 6 | "X c #616161", | 6 | "X c #616161", |
| 7 | "o c #2a1f55", | 7 | "o c #2a1f55", |
diff --git a/lisp/toolbar/gud-n.xpm b/lisp/toolbar/gud-n.xpm index 0e631de18e1..f0257da5cf0 100644 --- a/lisp/toolbar/gud-n.xpm +++ b/lisp/toolbar/gud-n.xpm | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | /* XPM */ | 1 | /* XPM */ |
| 2 | static char * next_xpm[] = { | 2 | static char * next_xpm[] = { |
| 3 | "24 24 7 1", | 3 | "24 24 7 1", |
| 4 | " c #c0c0c0", | 4 | " c None", |
| 5 | ". c #cc0033", | 5 | ". c #cc0033", |
| 6 | "X c #616161", | 6 | "X c #616161", |
| 7 | "o c #2a1f55", | 7 | "o c #2a1f55", |
diff --git a/lisp/toolbar/gud-ni.xpm b/lisp/toolbar/gud-ni.xpm index cdb8c38e8d4..bd4f02db12e 100644 --- a/lisp/toolbar/gud-ni.xpm +++ b/lisp/toolbar/gud-ni.xpm | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | /* XPM */ | 1 | /* XPM */ |
| 2 | static char * gud_nexti_xpm[] = { | 2 | static char * gud_nexti_xpm[] = { |
| 3 | "24 24 6 1", | 3 | "24 24 6 1", |
| 4 | " c #C0C0C0C0C0C0", | 4 | " c None", |
| 5 | ". c #CCCC00003333", | 5 | ". c #CCCC00003333", |
| 6 | "X c #616161616161", | 6 | "X c #616161616161", |
| 7 | "o c #D4D400000000", | 7 | "o c #D4D400000000", |
diff --git a/lisp/toolbar/gud-print.xpm b/lisp/toolbar/gud-print.xpm index cab2b7d6109..e1e7c623355 100644 --- a/lisp/toolbar/gud-print.xpm +++ b/lisp/toolbar/gud-print.xpm | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | /* XPM */ | 1 | /* XPM */ |
| 2 | static char * print_xpm[] = { | 2 | static char * print_xpm[] = { |
| 3 | "24 24 2 1", | 3 | "24 24 2 1", |
| 4 | " c #C0C0C0C0C0C0", | 4 | " c None", |
| 5 | ". c #000000000000", | 5 | ". c #000000000000", |
| 6 | " ", | 6 | " ", |
| 7 | " ", | 7 | " ", |
diff --git a/lisp/toolbar/gud-pstar.pbm b/lisp/toolbar/gud-pstar.pbm new file mode 100644 index 00000000000..1f5967107a0 --- /dev/null +++ b/lisp/toolbar/gud-pstar.pbm | |||
| Binary files differ | |||
diff --git a/lisp/toolbar/gud-pstar.xpm b/lisp/toolbar/gud-pstar.xpm new file mode 100644 index 00000000000..6edc603db14 --- /dev/null +++ b/lisp/toolbar/gud-pstar.xpm | |||
| @@ -0,0 +1,29 @@ | |||
| 1 | /* XPM */ | ||
| 2 | static char * gud_pstar_xpm[] = { | ||
| 3 | "24 24 2 1", | ||
| 4 | " c #BDBDBEBEBDBD", | ||
| 5 | ". c #000000000000", | ||
| 6 | " ", | ||
| 7 | " ", | ||
| 8 | " ", | ||
| 9 | " ", | ||
| 10 | " ", | ||
| 11 | " ", | ||
| 12 | " ", | ||
| 13 | " ", | ||
| 14 | " ... ... ", | ||
| 15 | " ... ... ", | ||
| 16 | " .. .. . ", | ||
| 17 | " .. .. . . . ", | ||
| 18 | " .. .. ... ", | ||
| 19 | " .. .. . . . ", | ||
| 20 | " .. .. . ", | ||
| 21 | " ... .. ", | ||
| 22 | " .. .. ", | ||
| 23 | " .. ", | ||
| 24 | " .. ", | ||
| 25 | " .. ", | ||
| 26 | " .... ", | ||
| 27 | " ", | ||
| 28 | " ", | ||
| 29 | " "}; | ||
diff --git a/lisp/toolbar/gud-remove.xpm b/lisp/toolbar/gud-remove.xpm index c61b6b2b8f3..5f38bd416ed 100644 --- a/lisp/toolbar/gud-remove.xpm +++ b/lisp/toolbar/gud-remove.xpm | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | /* XPM */ | 1 | /* XPM */ |
| 2 | static char * go_xpm[] = { | 2 | static char * go_xpm[] = { |
| 3 | "24 24 4 1", | 3 | "24 24 4 1", |
| 4 | " c #C0C0C0C0C0C0", | 4 | " c None", |
| 5 | ". c #000080800000", | 5 | ". c #000080800000", |
| 6 | "X c #FFFFFFFFFFFF", | 6 | "X c #FFFFFFFFFFFF", |
| 7 | "o c #F8F8FCFCF8F8", | 7 | "o c #F8F8FCFCF8F8", |
diff --git a/lisp/toolbar/gud-run.xpm b/lisp/toolbar/gud-run.xpm index 6e077a11659..ef29662ed24 100644 --- a/lisp/toolbar/gud-run.xpm +++ b/lisp/toolbar/gud-run.xpm | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | /* XPM */ | 1 | /* XPM */ |
| 2 | static char * run_xpm[] = { | 2 | static char * run_xpm[] = { |
| 3 | "24 24 9 1", | 3 | "24 24 9 1", |
| 4 | " c #c0c0c0", | 4 | " c None", |
| 5 | ". c #000080", | 5 | ". c #000080", |
| 6 | "X c #aa9faa", | 6 | "X c #aa9faa", |
| 7 | "o c #b5b9b5", | 7 | "o c #b5b9b5", |
diff --git a/lisp/toolbar/gud-s.xpm b/lisp/toolbar/gud-s.xpm index 7b4eb876235..4ee3eccaee2 100644 --- a/lisp/toolbar/gud-s.xpm +++ b/lisp/toolbar/gud-s.xpm | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | /* XPM */ | 1 | /* XPM */ |
| 2 | static char * step_xpm[] = { | 2 | static char * step_xpm[] = { |
| 3 | "24 24 6 1", | 3 | "24 24 6 1", |
| 4 | " c #c0c0c0", | 4 | " c None", |
| 5 | ". c #d40000", | 5 | ". c #d40000", |
| 6 | "X c #616161", | 6 | "X c #616161", |
| 7 | "o c #2a1f55", | 7 | "o c #2a1f55", |
diff --git a/lisp/toolbar/gud-si.xpm b/lisp/toolbar/gud-si.xpm index d2667fc70b6..b20eb6243f7 100644 --- a/lisp/toolbar/gud-si.xpm +++ b/lisp/toolbar/gud-si.xpm | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | /* XPM */ | 1 | /* XPM */ |
| 2 | static char * gud_stepi_xpm[] = { | 2 | static char * gud_stepi_xpm[] = { |
| 3 | "24 24 5 1", | 3 | "24 24 5 1", |
| 4 | " c #C0C0C0C0C0C0", | 4 | " c None", |
| 5 | ". c #D4D400000000", | 5 | ". c #D4D400000000", |
| 6 | "X c #616161616161", | 6 | "X c #616161616161", |
| 7 | "o c #2A2A1F1F5555", | 7 | "o c #2A2A1F1F5555", |
diff --git a/lisp/toolbar/gud-until.xpm b/lisp/toolbar/gud-until.xpm index 8801320a2d1..f82da6700b2 100644 --- a/lisp/toolbar/gud-until.xpm +++ b/lisp/toolbar/gud-until.xpm | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | /* XPM */ | 1 | /* XPM */ |
| 2 | static char * goto_xpm[] = { | 2 | static char * goto_xpm[] = { |
| 3 | "24 24 6 1", | 3 | "24 24 6 1", |
| 4 | " c #c0c0c0", | 4 | " c None", |
| 5 | ". c #ff0000", | 5 | ". c #ff0000", |
| 6 | "X c #616161", | 6 | "X c #616161", |
| 7 | "o c #2a1f55", | 7 | "o c #2a1f55", |
diff --git a/lisp/toolbar/gud-up.xpm b/lisp/toolbar/gud-up.xpm index 10d8c1278c9..c2e4c9f8ff4 100644 --- a/lisp/toolbar/gud-up.xpm +++ b/lisp/toolbar/gud-up.xpm | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | /* XPM */ | 1 | /* XPM */ |
| 2 | static char * up_xpm[] = { | 2 | static char * up_xpm[] = { |
| 3 | "24 24 14 1", | 3 | "24 24 14 1", |
| 4 | " c #C0C0C0C0C0C0", | 4 | " c None", |
| 5 | ". c #000000000000", | 5 | ". c #000000000000", |
| 6 | "X c #7F7F7F7F7F7F", | 6 | "X c #7F7F7F7F7F7F", |
| 7 | "o c #2D2D2D2D2D2D", | 7 | "o c #2D2D2D2D2D2D", |
diff --git a/lisp/toolbar/gud-watch.xpm b/lisp/toolbar/gud-watch.xpm index 41361dc32b2..52052212390 100644 --- a/lisp/toolbar/gud-watch.xpm +++ b/lisp/toolbar/gud-watch.xpm | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | /* XPM */ | 1 | /* XPM */ |
| 2 | static char * watch_xpm[] = { | 2 | static char * watch_xpm[] = { |
| 3 | "24 24 11 1", | 3 | "24 24 11 1", |
| 4 | " c #C0C0C0C0C0C0", | 4 | " c None", |
| 5 | ". c #808080808080", | 5 | ". c #808080808080", |
| 6 | "X c #000000000000", | 6 | "X c #000000000000", |
| 7 | "o c #A5A59F9FA3A3", | 7 | "o c #A5A59F9FA3A3", |
diff --git a/lisp/url/url-http.el b/lisp/url/url-http.el index 16d51a0258c..f5bbf4a7bf4 100644 --- a/lisp/url/url-http.el +++ b/lisp/url/url-http.el | |||
| @@ -500,7 +500,8 @@ should be shown to the user." | |||
| 500 | (url-request-data url-http-data) | 500 | (url-request-data url-http-data) |
| 501 | (url-request-extra-headers url-http-extra-headers)) | 501 | (url-request-extra-headers url-http-extra-headers)) |
| 502 | (url-retrieve redirect-uri url-callback-function | 502 | (url-retrieve redirect-uri url-callback-function |
| 503 | url-callback-arguments) | 503 | (cons redirect-uri |
| 504 | (cdr url-callback-arguments))) | ||
| 504 | (url-mark-buffer-as-dead (current-buffer)))))) | 505 | (url-mark-buffer-as-dead (current-buffer)))))) |
| 505 | (4 ; Client error | 506 | (4 ; Client error |
| 506 | ;; 400 Bad Request | 507 | ;; 400 Bad Request |
| @@ -849,7 +850,7 @@ the end of the document." | |||
| 849 | (url-display-percentage nil nil) | 850 | (url-display-percentage nil nil) |
| 850 | (goto-char (match-end 1)) | 851 | (goto-char (match-end 1)) |
| 851 | (if (re-search-forward "^\r*$" nil t) | 852 | (if (re-search-forward "^\r*$" nil t) |
| 852 | (message "Saw end of trailers...")) | 853 | (url-http-debug "Saw end of trailers...")) |
| 853 | (if (url-http-parse-headers) | 854 | (if (url-http-parse-headers) |
| 854 | (url-http-activate-callback)))))))))) | 855 | (url-http-activate-callback)))))))))) |
| 855 | 856 | ||
diff --git a/lisp/wdired.el b/lisp/wdired.el index 3941fd681df..a82176af5e8 100644 --- a/lisp/wdired.el +++ b/lisp/wdired.el | |||
| @@ -263,7 +263,7 @@ See `wdired-mode'." | |||
| 263 | (buffer-enable-undo) ; Performance hack. See above. | 263 | (buffer-enable-undo) ; Performance hack. See above. |
| 264 | (set-buffer-modified-p nil) | 264 | (set-buffer-modified-p nil) |
| 265 | (setq buffer-undo-list nil) | 265 | (setq buffer-undo-list nil) |
| 266 | (run-hooks 'wdired-mode-hook) | 266 | (run-mode-hooks 'wdired-mode-hook) |
| 267 | (message (substitute-command-keys "Press \\[wdired-finish-edit] when finished \ | 267 | (message (substitute-command-keys "Press \\[wdired-finish-edit] when finished \ |
| 268 | or \\[wdired-abort-changes] to abort changes"))) | 268 | or \\[wdired-abort-changes] to abort changes"))) |
| 269 | 269 | ||
diff --git a/lisp/wid-browse.el b/lisp/wid-browse.el index 3878289b467..57c4ebdb548 100644 --- a/lisp/wid-browse.el +++ b/lisp/wid-browse.el | |||
| @@ -82,7 +82,7 @@ if that value is non-nil." | |||
| 82 | (use-local-map widget-browse-mode-map) | 82 | (use-local-map widget-browse-mode-map) |
| 83 | (easy-menu-add widget-browse-mode-customize-menu) | 83 | (easy-menu-add widget-browse-mode-customize-menu) |
| 84 | (easy-menu-add widget-browse-mode-menu) | 84 | (easy-menu-add widget-browse-mode-menu) |
| 85 | (run-hooks 'widget-browse-mode-hook)) | 85 | (run-mode-hooks 'widget-browse-mode-hook)) |
| 86 | 86 | ||
| 87 | (put 'widget-browse-mode 'mode-class 'special) | 87 | (put 'widget-browse-mode 'mode-class 'special) |
| 88 | 88 | ||
diff --git a/lisp/xml.el b/lisp/xml.el index daf5689c18b..f9527a276b1 100644 --- a/lisp/xml.el +++ b/lisp/xml.el | |||
| @@ -84,6 +84,9 @@ | |||
| 84 | ;;** | 84 | ;;** |
| 85 | ;;******************************************************************* | 85 | ;;******************************************************************* |
| 86 | 86 | ||
| 87 | (defconst xml-undefined-entity "?" | ||
| 88 | "What to substitute for undefined entities") | ||
| 89 | |||
| 87 | (defvar xml-entity-alist | 90 | (defvar xml-entity-alist |
| 88 | '(("lt" . "<") | 91 | '(("lt" . "<") |
| 89 | ("gt" . ">") | 92 | ("gt" . ">") |
| @@ -745,9 +748,10 @@ This follows the rule [28] in the XML specifications." | |||
| 745 | ((eq (length this-part) 0) | 748 | ((eq (length this-part) 0) |
| 746 | (error "XML: (Not Well-Formed) No entity given")) | 749 | (error "XML: (Not Well-Formed) No entity given")) |
| 747 | (t | 750 | (t |
| 748 | (when xml-validating-parser | 751 | (if xml-validating-parser |
| 749 | (error "XML: (Validity) Undefined entity `%s'" | 752 | (error "XML: (Validity) Undefined entity `%s'" |
| 750 | this-part)))))) | 753 | this-part) |
| 754 | xml-undefined-entity))))) | ||
| 751 | 755 | ||
| 752 | (cond ((null children) | 756 | (cond ((null children) |
| 753 | ;; FIXME: If we have an entity that expands into XML, this won't work. | 757 | ;; FIXME: If we have an entity that expands into XML, this won't work. |
diff --git a/lispref/ChangeLog b/lispref/ChangeLog index 25909586102..6077deea9bb 100644 --- a/lispref/ChangeLog +++ b/lispref/ChangeLog | |||
| @@ -1,3 +1,23 @@ | |||
| 1 | 2005-05-29 Luc Teirlinck <teirllm@auburn.edu> | ||
| 2 | |||
| 3 | * modes.texi (Major Mode Conventions): A derived mode only needs | ||
| 4 | to put the call to the parent mode inside `delay-mode-hooks'. | ||
| 5 | |||
| 6 | 2005-05-29 Richard M. Stallman <rms@gnu.org> | ||
| 7 | |||
| 8 | * modes.texi (Mode Hooks): Explain that after-change-major-mode-hook is | ||
| 9 | new, and what that implies. Clarify. | ||
| 10 | |||
| 11 | * files.texi (Locating Files): Clean up the text. | ||
| 12 | |||
| 13 | * frames.texi (Window Frame Parameters): Document user-size. | ||
| 14 | Shorten entry for top by referring to left. | ||
| 15 | |||
| 16 | 2005-05-26 Richard M. Stallman <rms@gnu.org> | ||
| 17 | |||
| 18 | * modes.texi (Mode Hooks): Explain that after-change-major-mode-hook | ||
| 19 | is new, and what the implications are. Other clarifications. | ||
| 20 | |||
| 1 | 2005-05-24 Richard M. Stallman <rms@gnu.org> | 21 | 2005-05-24 Richard M. Stallman <rms@gnu.org> |
| 2 | 22 | ||
| 3 | * frames.texi (Dialog Boxes): Minor fixes. | 23 | * frames.texi (Dialog Boxes): Minor fixes. |
diff --git a/lispref/files.texi b/lispref/files.texi index 25c4dfeb0d0..766220aa882 100644 --- a/lispref/files.texi +++ b/lispref/files.texi | |||
| @@ -1261,36 +1261,36 @@ is on file system number -32252. | |||
| 1261 | @cindex locate files | 1261 | @cindex locate files |
| 1262 | @cindex find files | 1262 | @cindex find files |
| 1263 | 1263 | ||
| 1264 | Sometimes, you need to find a file that could reside in one of the | 1264 | This section explains how to search for a file in a list of |
| 1265 | standard directories. One example is when you need to look for a | 1265 | directories. One example is when you need to look for a program's |
| 1266 | program's executable file, e.g., to find out whether a given program | 1266 | executable file, e.g., to find out whether a given program is |
| 1267 | is installed on the user's system. Another example is the search for | 1267 | installed on the user's system. Another example is the search for |
| 1268 | Lisp libraries (@pxref{Library Search}). Such searches generally need | 1268 | Lisp libraries (@pxref{Library Search}). Such searches generally need |
| 1269 | to try several alternative file name extensions, in addition to | 1269 | to try various possible file name extensions, in addition to various |
| 1270 | looking in every standard directory where the file could be found. | 1270 | possible directories. Emacs provides a function for such a |
| 1271 | Emacs provides a function for such a generalized search for a file. | 1271 | generalized search for a file. |
| 1272 | 1272 | ||
| 1273 | @defun locate-file filename path &optional suffixes predicate | 1273 | @defun locate-file filename path &optional suffixes predicate |
| 1274 | This function searches for the file whose name is @var{filename} in | 1274 | This function searches for a file whose name is @var{filename} in a |
| 1275 | a list of directories given by @var{path}. If it finds the file, it | 1275 | list of directories given by @var{path}, trying the suffixes in |
| 1276 | returns its full @dfn{absolute file name} (@pxref{Relative File | 1276 | @var{suffixes}. If it finds such a file, it returns the full |
| 1277 | Names}); if the file is not found, the function returns @code{nil}. | 1277 | @dfn{absolute file name} of the file (@pxref{Relative File Names}); |
| 1278 | otherwise it returns @code{nil}. | ||
| 1278 | 1279 | ||
| 1279 | The optional argument @var{suffixes} gives the list of file-name | 1280 | The optional argument @var{suffixes} gives the list of file-name |
| 1280 | suffixes to append to @var{filename} when searching. If | 1281 | suffixes to append to @var{filename} when searching. |
| 1281 | @var{suffixes} is @code{nil}, it's equivalent to passing a list with a | 1282 | @code{locate-file} tries each possible directory with each of these |
| 1282 | single element that is an empty string @code{""}. | 1283 | suffixes. If @var{suffixes} is @code{nil}, or @code{("")}, then there |
| 1283 | 1284 | are no suffixes, and @var{filename} is used only as-is. Typical | |
| 1284 | Typical values of @var{path} are @code{exec-path} (@pxref{Subprocess | 1285 | values of @var{suffixes} are @code{exec-suffixes} (@pxref{Subprocess |
| 1286 | Creation, exec-suffixes}) and @code{load-suffixes} (@pxref{Library | ||
| 1287 | Search, load-suffixes}). | ||
| 1288 | |||
| 1289 | Typical values for @var{path} are @code{exec-path} (@pxref{Subprocess | ||
| 1285 | Creation, exec-path}) when looking for executable programs or | 1290 | Creation, exec-path}) when looking for executable programs or |
| 1286 | @code{load-path} (@pxref{Library Search, load-path}) when looking for | 1291 | @code{load-path} (@pxref{Library Search, load-path}) when looking for |
| 1287 | Lisp files. Use @code{("/")} to disable the path search (e.g., if | 1292 | Lisp files. If @var{filename} is absolute, @var{path} has no effect, |
| 1288 | @var{filename} already includes the leading directories), but still | 1293 | but the suffixes in @var{suffixes} are still tried. |
| 1289 | try the extensions in @var{suffixes}. | ||
| 1290 | |||
| 1291 | Typical values of @var{suffixes} are @code{exec-suffixes} | ||
| 1292 | (@pxref{Subprocess Creation, exec-suffixes}) and @code{load-suffixes} | ||
| 1293 | (@pxref{Library Search, load-suffixes}). | ||
| 1294 | 1294 | ||
| 1295 | The optional argument @var{predicate}, if non-@code{nil}, specifies | 1295 | The optional argument @var{predicate}, if non-@code{nil}, specifies |
| 1296 | the predicate function to use for testing whether a candidate file is | 1296 | the predicate function to use for testing whether a candidate file is |
| @@ -1316,7 +1316,6 @@ in @code{exec-path} and tries all the file-name extensions in | |||
| 1316 | @code{exec-suffixes}. | 1316 | @code{exec-suffixes}. |
| 1317 | @end defun | 1317 | @end defun |
| 1318 | 1318 | ||
| 1319 | |||
| 1320 | @node Changing Files | 1319 | @node Changing Files |
| 1321 | @section Changing File Names and Attributes | 1320 | @section Changing File Names and Attributes |
| 1322 | @cindex renaming files | 1321 | @cindex renaming files |
diff --git a/lispref/frames.texi b/lispref/frames.texi index 77694c87130..ffcc16f6289 100644 --- a/lispref/frames.texi +++ b/lispref/frames.texi | |||
| @@ -362,20 +362,8 @@ non-@code{nil} value for the @code{user-position} parameter as well. | |||
| 362 | 362 | ||
| 363 | @item top | 363 | @item top |
| 364 | The screen position of the top edge, in pixels, with respect to the | 364 | The screen position of the top edge, in pixels, with respect to the |
| 365 | top edge of the screen. The value may be a positive number @var{pos}, | 365 | top edge of the screen. It works just like @code{left}, except vertically |
| 366 | or a list of the form @code{(+ @var{pos})} which permits specifying a | 366 | instead of horizontally. |
| 367 | negative @var{pos} value. | ||
| 368 | |||
| 369 | A negative number @minus{}@var{pos}, or a list of the form @code{(- | ||
| 370 | @var{pos})}, actually specifies the position of the bottom edge of the | ||
| 371 | window with respect to the bottom edge of the screen. A positive value | ||
| 372 | of @var{pos} counts toward the top. @strong{Reminder:} if the | ||
| 373 | parameter is a negative integer @minus{}@var{pos}, then @var{pos} is | ||
| 374 | positive. | ||
| 375 | |||
| 376 | Some window managers ignore program-specified positions. If you want to | ||
| 377 | be sure the position you specify is not ignored, specify a | ||
| 378 | non-@code{nil} value for the @code{user-position} parameter as well. | ||
| 379 | 367 | ||
| 380 | @item icon-left | 368 | @item icon-left |
| 381 | The screen position of the left edge @emph{of the frame's icon}, in | 369 | The screen position of the left edge @emph{of the frame's icon}, in |
| @@ -418,6 +406,11 @@ pixels, call @code{frame-pixel-height}; see @ref{Size and Position}.) | |||
| 418 | The width of the frame contents, in characters. (To get the height in | 406 | The width of the frame contents, in characters. (To get the height in |
| 419 | pixels, call @code{frame-pixel-width}; see @ref{Size and Position}.) | 407 | pixels, call @code{frame-pixel-width}; see @ref{Size and Position}.) |
| 420 | 408 | ||
| 409 | @item user-size | ||
| 410 | This does for the size parameters @code{height} and @code{width} what | ||
| 411 | the @code{user-position} parameter (see above) does for the position | ||
| 412 | parameters @code{top} and @code{left}. | ||
| 413 | |||
| 421 | @item fullscreen | 414 | @item fullscreen |
| 422 | Specify that width, height or both shall be set to the size of the screen. | 415 | Specify that width, height or both shall be set to the size of the screen. |
| 423 | The value @code{fullwidth} specifies that width shall be the size of the | 416 | The value @code{fullwidth} specifies that width shall be the size of the |
diff --git a/lispref/modes.texi b/lispref/modes.texi index 61bc878b581..f8c1ae82a4e 100644 --- a/lispref/modes.texi +++ b/lispref/modes.texi | |||
| @@ -437,10 +437,8 @@ The major mode command may start by calling some other major mode | |||
| 437 | command (called the @dfn{parent mode}) and then alter some of its | 437 | command (called the @dfn{parent mode}) and then alter some of its |
| 438 | settings. A mode that does this is called a @dfn{derived mode}. The | 438 | settings. A mode that does this is called a @dfn{derived mode}. The |
| 439 | recommended way to define one is to use @code{define-derived-mode}, | 439 | recommended way to define one is to use @code{define-derived-mode}, |
| 440 | but this is not required. Such a mode should use | 440 | but this is not required. Such a mode should call the parent mode |
| 441 | @code{delay-mode-hooks} around its entire body (including the call to | 441 | command inside a @code{delay-mode-hooks} form. (Using |
| 442 | the parent mode command) @emph{except} for the final call to | ||
| 443 | @code{run-mode-hooks}, which runs the derived mode's hook. (Using | ||
| 444 | @code{define-derived-mode} does this automatically.) @xref{Derived | 442 | @code{define-derived-mode} does this automatically.) @xref{Derived |
| 445 | Modes}, and @ref{Mode Hooks}. | 443 | Modes}, and @ref{Mode Hooks}. |
| 446 | 444 | ||
| @@ -1117,7 +1115,7 @@ it runs the mode hook variable @code{@var{mode}-hook}. | |||
| 1117 | @node Mode Hooks | 1115 | @node Mode Hooks |
| 1118 | @subsection Mode Hooks | 1116 | @subsection Mode Hooks |
| 1119 | 1117 | ||
| 1120 | The two last things a major mode function does is to run its mode | 1118 | The two last things a major mode function should do is run its mode |
| 1121 | hook and finally the mode independent normal hook | 1119 | hook and finally the mode independent normal hook |
| 1122 | @code{after-change-major-mode-hook}. If the major mode is a derived | 1120 | @code{after-change-major-mode-hook}. If the major mode is a derived |
| 1123 | mode, that is if it calls another major mode (the parent mode) in its | 1121 | mode, that is if it calls another major mode (the parent mode) in its |
| @@ -1125,45 +1123,53 @@ body, then the parent's mode hook is run just before the derived | |||
| 1125 | mode's hook. Neither the parent's mode hook nor | 1123 | mode's hook. Neither the parent's mode hook nor |
| 1126 | @code{after-change-major-mode-hook} are run at the end of the actual | 1124 | @code{after-change-major-mode-hook} are run at the end of the actual |
| 1127 | call to the parent mode. This applies recursively if the parent mode | 1125 | call to the parent mode. This applies recursively if the parent mode |
| 1128 | has itself a parent. That is, the mode hooks of all major modes called | 1126 | has itself a parent. That is, the mode hooks of all major modes |
| 1129 | directly or indirectly by the major mode function are all run in | 1127 | called directly or indirectly by the major mode function are all run |
| 1130 | sequence at the end, just before @code{after-change-major-mode-hook}. | 1128 | in sequence at the end, just before |
| 1131 | 1129 | @code{after-change-major-mode-hook}. | |
| 1132 | If you are customizing a major mode, rather than defining one, the | 1130 | |
| 1133 | above is all you need to know about the hooks run at the end of a | 1131 | These conventions are new in Emacs 22, and some major modes |
| 1134 | major mode. This also applies if you use @code{define-derived-mode} | 1132 | implemented by users do not follow them yet. So if you put a function |
| 1135 | to define a major mode, because that macro will automatically | 1133 | onto @code{after-change-major-mode-hook}, keep in mind that some modes |
| 1136 | implement the above for you. | 1134 | will fail to run it. If a user complains about that, you can respond, |
| 1137 | 1135 | ``That major mode fails to follow Emacs conventions, and that's why it | |
| 1138 | Programmers wishing to define a major mode without using | 1136 | fails to work. Please fix the major mode.'' In most cases, that is |
| 1139 | @code{define-derived-mode}, should make sure that their major mode | 1137 | good enough, so go ahead and use @code{after-change-major-mode-hook}. |
| 1140 | follows the above conventions. @xref{Major Mode Conventions}, for how | 1138 | However, if a certain feature needs to be completely reliable, |
| 1141 | this should be accomplished. Below, we give some implementation | 1139 | it should not use @code{after-change-major-mode-hook} as of yet. |
| 1142 | details. | 1140 | |
| 1141 | When you defined a major mode using @code{define-derived-mode}, it | ||
| 1142 | automatically makes sure these conventions are followed. If you | ||
| 1143 | define a major mode ``from scratch'', not using | ||
| 1144 | @code{define-derived-mode}, make sure the major mode command follows | ||
| 1145 | these and other conventions. @xref{Major Mode Conventions}. You use | ||
| 1146 | these functions to do it properly. | ||
| 1143 | 1147 | ||
| 1144 | @defun run-mode-hooks &rest hookvars | 1148 | @defun run-mode-hooks &rest hookvars |
| 1145 | Major modes should run their mode hook using this function. It is | 1149 | Major modes should run their mode hook using this function. It is |
| 1146 | similar to @code{run-hooks} (@pxref{Hooks}), but if run inside a | 1150 | similar to @code{run-hooks} (@pxref{Hooks}), but it also runs |
| 1147 | @code{delay-mode-hooks} form, this function does not run any hooks. | ||
| 1148 | Instead, it arranges for @var{hookvars} to be run at a later call to | ||
| 1149 | the function. Otherwise, @code{run-mode-hooks} runs any delayed hooks | ||
| 1150 | in order, then @var{hookvars} and finally | ||
| 1151 | @code{after-change-major-mode-hook}. | 1151 | @code{after-change-major-mode-hook}. |
| 1152 | |||
| 1153 | When the call to this function is dynamically inside a | ||
| 1154 | @code{delay-mode-hooks} form, this function does not run any hooks. | ||
| 1155 | Instead, it arranges for the next call to @code{run-mode-hooks} to run | ||
| 1156 | @var{hookvars}. | ||
| 1152 | @end defun | 1157 | @end defun |
| 1153 | 1158 | ||
| 1154 | @defmac delay-mode-hooks body... | 1159 | @defmac delay-mode-hooks body... |
| 1155 | This macro executes @var{body} like @code{progn}, but all calls to | 1160 | This macro executes @var{body} like @code{progn}, but all calls to |
| 1156 | @code{run-mode-hooks} inside @var{body} delay running their hooks. | 1161 | @code{run-mode-hooks} inside @var{body} delay running their hooks. |
| 1157 | They will be run by the first call to @code{run-mode-hooks} after exit | 1162 | They will be run by the first call to @code{run-mode-hooks} after exit |
| 1158 | from @code{delay-mode-hooks}. | 1163 | from @code{delay-mode-hooks}. This is the proper way for a major mode |
| 1164 | command to invoke its parent mode. | ||
| 1159 | @end defmac | 1165 | @end defmac |
| 1160 | 1166 | ||
| 1161 | @defvar after-change-major-mode-hook | 1167 | @defvar after-change-major-mode-hook |
| 1162 | Every major mode function should run this normal hook at its very end. | 1168 | Every major mode function should run this normal hook at its very end. |
| 1163 | It normally does not need to do so explicitly. Indeed, a major mode | 1169 | It normally does not need to do so explicitly. Indeed, a major mode |
| 1164 | function should normally run its mode hook with @code{run-mode-hooks} | 1170 | function should normally run its mode hook with @code{run-mode-hooks} |
| 1165 | as the very last thing it does and @code{run-mode-hooks} runs | 1171 | as the very last thing it does, and the last thing |
| 1166 | @code{after-change-major-mode-hook} at its very end. | 1172 | @code{run-mode-hooks} does is run @code{after-change-major-mode-hook}. |
| 1167 | @end defvar | 1173 | @end defvar |
| 1168 | 1174 | ||
| 1169 | @node Minor Modes | 1175 | @node Minor Modes |
diff --git a/man/ChangeLog b/man/ChangeLog index 26e9aad20bd..74b6e19d0ed 100644 --- a/man/ChangeLog +++ b/man/ChangeLog | |||
| @@ -1,3 +1,78 @@ | |||
| 1 | 2005-06-05 Chong Yidong <cyd@stupidchicken.com> | ||
| 2 | |||
| 3 | * emacs.texi: Rename Hardcopy to Printing. | ||
| 4 | Make PostScript and PostScript Variables subnodes of it. | ||
| 5 | |||
| 6 | * misc.texi (Printing): Rename node from Hardcopy. | ||
| 7 | Mention menu bar options. | ||
| 8 | Move PostScript and PostScript Variables to submenu. | ||
| 9 | (Printing package): New node. | ||
| 10 | |||
| 11 | * mark.texi (Using Region): Change Hardcopy xref to Printing. | ||
| 12 | |||
| 13 | * dired.texi (Operating on Files): Likewise. | ||
| 14 | |||
| 15 | * calendar.texi (Displaying the Diary): Likewise. | ||
| 16 | |||
| 17 | * msdog.texi (MS-DOS Printing, MS-DOS Processes): Likewise. | ||
| 18 | |||
| 19 | * glossary.texi (Glossary): Likewise. | ||
| 20 | |||
| 21 | * frames.texi (Mode Line Mouse): Mention mode-line-highlight | ||
| 22 | effect. | ||
| 23 | |||
| 24 | 2005-06-04 Richard M. Stallman <rms@gnu.org> | ||
| 25 | |||
| 26 | * trouble.texi (After a Crash): Polish previous change. | ||
| 27 | |||
| 28 | 2005-05-31 Jay Belanger <belanger@truman.edu> | ||
| 29 | |||
| 30 | * calc.texi (Notations Used in This Manual): Use @kbd for key | ||
| 31 | sequence. | ||
| 32 | (Demonstration of Calc): Mention another way of starting Calc. | ||
| 33 | (Starting Calc): Mention long name of M-#. | ||
| 34 | (Embedded Mode Overview): Remove unnecessary instruction. | ||
| 35 | (Other M-# commands): Rephrase `M-# 0' explanation. | ||
| 36 | (Basic Embedded Mode): Rewrite discussion of prefix arguments to | ||
| 37 | reflect current behavior. | ||
| 38 | |||
| 39 | 2005-05-30 Jay Belanger <belanger@truman.edu> | ||
| 40 | |||
| 41 | * calc.texi (Hooks): Change description of calc-window-hook and | ||
| 42 | calc-trail-window-hook to match usage. | ||
| 43 | (Computational Functions): Add more constant-generating functions. | ||
| 44 | (Customizable Variables): Use defvar. | ||
| 45 | |||
| 46 | 2005-05-30 Noah Friedman <friedman@splode.com> | ||
| 47 | |||
| 48 | * trouble.texi (After a Crash): Mention emacs-buffer.gdb as a | ||
| 49 | recovery mechanism. | ||
| 50 | |||
| 51 | 2005-05-28 Jay Belanger <belanger@truman.edu> | ||
| 52 | |||
| 53 | * calc.texi (Assignments in Embedded Mode): Fix variable name. | ||
| 54 | (Basic Embedded Mode): Explain behavior of arguments to | ||
| 55 | calc-embedded-mode. | ||
| 56 | |||
| 57 | 2005-05-28 Nick Roberts <nickrob@snap.net.nz> | ||
| 58 | |||
| 59 | * building.texi (Other Buffers): SPC toggles display of | ||
| 60 | floating point registers. | ||
| 61 | |||
| 62 | 2005-05-27 Jay Belanger <belanger@truman.edu> | ||
| 63 | |||
| 64 | * calc.texi (Queries in Keyboard Macros): Rewrite to reflect | ||
| 65 | current behavior. | ||
| 66 | |||
| 67 | 2005-05-27 Nick Roberts <nickrob@snap.net.nz> | ||
| 68 | |||
| 69 | * files.texi (Log Buffer): Merge in description of Log Edit | ||
| 70 | mode from pcl-cvs.texi. | ||
| 71 | |||
| 72 | 2005-05-26 Richard M. Stallman <rms@gnu.org> | ||
| 73 | |||
| 74 | * building.texi (Lisp Eval): C-M-x with arg runs Edebug. | ||
| 75 | |||
| 1 | 2005-05-25 Jay Belanger <belanger@truman.edu> | 76 | 2005-05-25 Jay Belanger <belanger@truman.edu> |
| 2 | 77 | ||
| 3 | * calc.texi: Change Calc version number throughout. | 78 | * calc.texi: Change Calc version number throughout. |
diff --git a/man/building.texi b/man/building.texi index c362b817034..f98136f9db1 100644 --- a/man/building.texi +++ b/man/building.texi | |||
| @@ -932,7 +932,8 @@ separately to examine their values. @xref{Watch Expressions}. | |||
| 932 | 932 | ||
| 933 | @item Registers Buffer | 933 | @item Registers Buffer |
| 934 | The registers buffer displays the values held by the registers | 934 | The registers buffer displays the values held by the registers |
| 935 | (@pxref{Registers,,, gdb, The GNU debugger}). | 935 | (@pxref{Registers,,, gdb, The GNU debugger}). Press @key{SPC} to |
| 936 | toggle the display of floating point registers. | ||
| 936 | 937 | ||
| 937 | @item Assembler Buffer | 938 | @item Assembler Buffer |
| 938 | The assembler buffer displays the current frame as machine code. An | 939 | The assembler buffer displays the current frame as machine code. An |
| @@ -944,7 +945,7 @@ appear in the fringe or margin. | |||
| 944 | 945 | ||
| 945 | The threads buffer displays a summary of all threads currently in your | 946 | The threads buffer displays a summary of all threads currently in your |
| 946 | program (@pxref{Threads,,, gdb, The GNU debugger}). Move point to | 947 | program (@pxref{Threads,,, gdb, The GNU debugger}). Move point to |
| 947 | any thread in the list and type @key{RET} to make it become the | 948 | any thread in the list and press @key{RET} to make it become the |
| 948 | current thread (@code{gdb-threads-select}) and display the associated | 949 | current thread (@code{gdb-threads-select}) and display the associated |
| 949 | source in the source buffer. Alternatively, click @kbd{Mouse-2} to | 950 | source in the source buffer. Alternatively, click @kbd{Mouse-2} to |
| 950 | make the selected thread become the current one. | 951 | make the selected thread become the current one. |
| @@ -1149,10 +1150,11 @@ mode. It does not treat @code{defvar} specially. | |||
| 1149 | @kbd{C-x C-e} a second time to display the value of the integer result | 1150 | @kbd{C-x C-e} a second time to display the value of the integer result |
| 1150 | in additional formats (octal, hexadecimal, and character). | 1151 | in additional formats (octal, hexadecimal, and character). |
| 1151 | 1152 | ||
| 1152 | If @kbd{C-M-x}, @kbd{C-x C-e}, or @kbd{M-:} is given a numeric | 1153 | If @kbd{C-x C-e}, or @kbd{M-:} is given a numeric argument, it |
| 1153 | argument, it inserts the value into the current buffer at point, rather | 1154 | inserts the value into the current buffer at point, rather than |
| 1154 | than displaying it in the echo area. The argument's value does not | 1155 | displaying it in the echo area. The argument's value does not matter. |
| 1155 | matter. | 1156 | @kbd{C-M-x} with a numeric argument instruments the function |
| 1157 | definition for Edebug (@pxref{Instrumenting, Instrumenting for Edebug,, elisp, the Emacs Lisp Reference Manual}). | ||
| 1156 | 1158 | ||
| 1157 | @findex eval-region | 1159 | @findex eval-region |
| 1158 | @findex eval-current-buffer | 1160 | @findex eval-current-buffer |
diff --git a/man/calc.texi b/man/calc.texi index 9e9eeee68a5..6e947050107 100644 --- a/man/calc.texi +++ b/man/calc.texi | |||
| @@ -583,6 +583,7 @@ and what are the various ways that it can be used. | |||
| 583 | * What is Calc:: | 583 | * What is Calc:: |
| 584 | * About This Manual:: | 584 | * About This Manual:: |
| 585 | * Notations Used in This Manual:: | 585 | * Notations Used in This Manual:: |
| 586 | * Demonstration of Calc:: | ||
| 586 | * Using Calc:: | 587 | * Using Calc:: |
| 587 | * Demonstration of Calc:: | 588 | * Demonstration of Calc:: |
| 588 | * History and Acknowledgements:: | 589 | * History and Acknowledgements:: |
| @@ -764,7 +765,7 @@ regularly using Emacs. | |||
| 764 | (If you don't have the @key{LFD} or @key{TAB} keys on your keyboard, | 765 | (If you don't have the @key{LFD} or @key{TAB} keys on your keyboard, |
| 765 | the @kbd{C-j} and @kbd{C-i} keys are equivalent to them, respectively. | 766 | the @kbd{C-j} and @kbd{C-i} keys are equivalent to them, respectively. |
| 766 | If you don't have a Meta key, look for Alt or Extend Char. You can | 767 | If you don't have a Meta key, look for Alt or Extend Char. You can |
| 767 | also press @key{ESC} or @key{C-[} first to get the same effect, so | 768 | also press @key{ESC} or @kbd{C-[} first to get the same effect, so |
| 768 | that @kbd{M-x}, @kbd{@key{ESC} x}, and @kbd{C-[ x} are all equivalent.) | 769 | that @kbd{M-x}, @kbd{@key{ESC} x}, and @kbd{C-[ x} are all equivalent.) |
| 769 | 770 | ||
| 770 | Sometimes the @key{RET} key is not shown when it is ``obvious'' | 771 | Sometimes the @key{RET} key is not shown when it is ``obvious'' |
| @@ -797,7 +798,8 @@ Tutorial. | |||
| 797 | 798 | ||
| 798 | To begin, start Emacs if necessary (usually the command @code{emacs} | 799 | To begin, start Emacs if necessary (usually the command @code{emacs} |
| 799 | does this), and type @kbd{M-# c} (or @kbd{@key{ESC} # c}) to start the | 800 | does this), and type @kbd{M-# c} (or @kbd{@key{ESC} # c}) to start the |
| 800 | Calculator. (@xref{Starting Calc}, if this doesn't work for you.) | 801 | Calculator. (You can also use @kbd{M-x calc} if this doesn't work. |
| 802 | @xref{Starting Calc}, for various ways of starting the Calculator.) | ||
| 801 | 803 | ||
| 802 | Be sure to type all the sample input exactly, especially noting the | 804 | Be sure to type all the sample input exactly, especially noting the |
| 803 | difference between lower-case and upper-case letters. Remember, | 805 | difference between lower-case and upper-case letters. Remember, |
| @@ -987,11 +989,15 @@ don't even have an @key{ESC} key, you can fake it by holding down | |||
| 987 | Control or @key{CTRL} while typing a left square bracket | 989 | Control or @key{CTRL} while typing a left square bracket |
| 988 | (that's @kbd{C-[} in Emacs notation). | 990 | (that's @kbd{C-[} in Emacs notation). |
| 989 | 991 | ||
| 990 | @kbd{M-#} is a @dfn{prefix key}; when you press it, Emacs waits for | 992 | The key @kbd{M-#} is bound to the command @code{calc-dispatch}, |
| 991 | you to press a second key to complete the command. In this case, | 993 | which can be rebound if convenient. |
| 992 | you will follow @kbd{M-#} with a letter (upper- or lower-case, it | 994 | (@xref{Key Bindings,,Customizing Key Bindings,emacs, |
| 993 | doesn't matter for @kbd{M-#}) that says which Calc interface you | 995 | The GNU Emacs Manual}.) |
| 994 | want to use. | 996 | |
| 997 | When you press @kbd{M-#}, Emacs waits for you to press a second key to | ||
| 998 | complete the command. In this case, you will follow @kbd{M-#} with a | ||
| 999 | letter (upper- or lower-case, it doesn't matter for @kbd{M-#}) that says | ||
| 1000 | which Calc interface you want to use. | ||
| 995 | 1001 | ||
| 996 | To get Calc's standard interface, type @kbd{M-# c}. To get | 1002 | To get Calc's standard interface, type @kbd{M-# c}. To get |
| 997 | Keypad mode, type @kbd{M-# k}. Type @kbd{M-# ?} to get a brief | 1003 | Keypad mode, type @kbd{M-# k}. Type @kbd{M-# ?} to get a brief |
| @@ -1335,9 +1341,7 @@ righthand label: Type @kbd{d @} (1) @key{RET}}. | |||
| 1335 | @end smallexample | 1341 | @end smallexample |
| 1336 | 1342 | ||
| 1337 | To leave Embedded mode, type @kbd{M-# e} again. The mode line | 1343 | To leave Embedded mode, type @kbd{M-# e} again. The mode line |
| 1338 | and keyboard will revert to the way they were before. (If you have | 1344 | and keyboard will revert to the way they were before. |
| 1339 | actually been trying this as you read along, you'll want to press | ||
| 1340 | @kbd{M-# 0} [with the digit zero] now to reset the modes you changed.) | ||
| 1341 | 1345 | ||
| 1342 | The related command @kbd{M-# w} operates on a single word, which | 1346 | The related command @kbd{M-# w} operates on a single word, which |
| 1343 | generally means a single number, inside text. It uses any | 1347 | generally means a single number, inside text. It uses any |
| @@ -1520,8 +1524,7 @@ and record them as the current keyboard macro. | |||
| 1520 | 1524 | ||
| 1521 | @item 0 | 1525 | @item 0 |
| 1522 | (This is the ``zero'' digit key.) Reset the Calculator to | 1526 | (This is the ``zero'' digit key.) Reset the Calculator to |
| 1523 | its default state: Empty stack, and default mode settings. | 1527 | its initial state: Empty stack, and initial mode settings. |
| 1524 | With any prefix argument, reset everything but the stack. | ||
| 1525 | @end table | 1528 | @end table |
| 1526 | 1529 | ||
| 1527 | @node History and Acknowledgements, , Using Calc, Getting Started | 1530 | @node History and Acknowledgements, , Using Calc, Getting Started |
| @@ -1589,7 +1592,7 @@ Many people have contributed to Calc by reporting bugs and suggesting | |||
| 1589 | features, large and small. A few deserve special mention: Tim Peters, | 1592 | features, large and small. A few deserve special mention: Tim Peters, |
| 1590 | who helped develop the ideas that led to the selection commands, rewrite | 1593 | who helped develop the ideas that led to the selection commands, rewrite |
| 1591 | rules, and many other algebra features; | 1594 | rules, and many other algebra features; |
| 1592 | @texline Fran\c cois | 1595 | @texline Fran\c{c}ois |
| 1593 | @infoline Francois | 1596 | @infoline Francois |
| 1594 | Pinard, who contributed an early prototype of the Calc Summary appendix | 1597 | Pinard, who contributed an early prototype of the Calc Summary appendix |
| 1595 | as well as providing valuable suggestions in many other areas of Calc; | 1598 | as well as providing valuable suggestions in many other areas of Calc; |
| @@ -30113,20 +30116,21 @@ your own favorite delimiters. Delimiters like @samp{$ $} can appear | |||
| 30113 | on their own separate lines or in-line with the formula. | 30116 | on their own separate lines or in-line with the formula. |
| 30114 | 30117 | ||
| 30115 | If you give a positive or negative numeric prefix argument, Calc | 30118 | If you give a positive or negative numeric prefix argument, Calc |
| 30116 | instead uses the current point as one end of the formula, and moves | 30119 | instead uses the current point as one end of the formula, and includes |
| 30117 | forward or backward (respectively) by that many lines to find the | 30120 | that many lines forward or backward (respectively, including the current |
| 30118 | other end. Explicit delimiters are not necessary in this case. | 30121 | line). Explicit delimiters are not necessary in this case. |
| 30119 | 30122 | ||
| 30120 | With a prefix argument of zero, Calc uses the current region | 30123 | With a prefix argument of zero, Calc uses the current region (delimited |
| 30121 | (delimited by point and mark) instead of formula delimiters. | 30124 | by point and mark) instead of formula delimiters. With a prefix |
| 30125 | argument of @kbd{C-u} only, Calc uses the current line as the formula. | ||
| 30122 | 30126 | ||
| 30123 | @kindex M-# w | 30127 | @kindex M-# w |
| 30124 | @pindex calc-embedded-word | 30128 | @pindex calc-embedded-word |
| 30125 | With a prefix argument of @kbd{C-u} only, Calc scans for the first | 30129 | The @kbd{M-# w} (@code{calc-embedded-word}) command will start Embedded |
| 30126 | non-numeric character (i.e., the first character that is not a | 30130 | mode on the current ``word''; in this case Calc will scan for the first |
| 30127 | digit, sign, decimal point, or upper- or lower-case @samp{e}) | 30131 | non-numeric character (i.e., the first character that is not a digit, |
| 30128 | forward and backward to delimit the formula. @kbd{M-# w} | 30132 | sign, decimal point, or upper- or lower-case @samp{e}) forward and |
| 30129 | (@code{calc-embedded-word}) is equivalent to @kbd{C-u M-# e}. | 30133 | backward to delimit the formula. |
| 30130 | 30134 | ||
| 30131 | When you enable Embedded mode for a formula, Calc reads the text | 30135 | When you enable Embedded mode for a formula, Calc reads the text |
| 30132 | between the delimiters and tries to interpret it as a Calc formula. | 30136 | between the delimiters and tries to interpret it as a Calc formula. |
| @@ -30495,7 +30499,7 @@ mode. | |||
| 30495 | 30499 | ||
| 30496 | @kindex M-# u | 30500 | @kindex M-# u |
| 30497 | @kindex M-# = | 30501 | @kindex M-# = |
| 30498 | @pindex calc-embedded-update | 30502 | @pindex calc-embedded-update-formula |
| 30499 | Another way to change the assignment to @code{foo} would simply be | 30503 | Another way to change the assignment to @code{foo} would simply be |
| 30500 | to edit the number using regular Emacs editing rather than Embedded | 30504 | to edit the number using regular Emacs editing rather than Embedded |
| 30501 | mode. Then, we have to find a way to get Embedded mode to notice | 30505 | mode. Then, we have to find a way to get Embedded mode to notice |
| @@ -31395,23 +31399,35 @@ are @emph{not} affected by @kbd{Z `} and @kbd{Z '}. | |||
| 31395 | @node Queries in Macros, , Local Values in Macros, Keyboard Macros | 31399 | @node Queries in Macros, , Local Values in Macros, Keyboard Macros |
| 31396 | @subsection Queries in Keyboard Macros | 31400 | @subsection Queries in Keyboard Macros |
| 31397 | 31401 | ||
| 31398 | @noindent | 31402 | @c @noindent |
| 31399 | @kindex Z = | 31403 | @c @kindex Z = |
| 31400 | @pindex calc-kbd-report | 31404 | @c @pindex calc-kbd-report |
| 31401 | The @kbd{Z =} (@code{calc-kbd-report}) command displays an informative | 31405 | @c The @kbd{Z =} (@code{calc-kbd-report}) command displays an informative |
| 31402 | message including the value on the top of the stack. You are prompted | 31406 | @c message including the value on the top of the stack. You are prompted |
| 31403 | to enter a string. That string, along with the top-of-stack value, | 31407 | @c to enter a string. That string, along with the top-of-stack value, |
| 31404 | is displayed unless @kbd{m w} (@code{calc-working}) has been used | 31408 | @c is displayed unless @kbd{m w} (@code{calc-working}) has been used |
| 31405 | to turn such messages off. | 31409 | @c to turn such messages off. |
| 31406 | 31410 | ||
| 31411 | @noindent | ||
| 31407 | @kindex Z # | 31412 | @kindex Z # |
| 31408 | @pindex calc-kbd-query | 31413 | @pindex calc-kbd-query |
| 31409 | The @kbd{Z #} (@code{calc-kbd-query}) command displays a prompt message | 31414 | The @kbd{Z #} (@code{calc-kbd-query}) command prompts for an algebraic |
| 31410 | (which you enter during macro definition), then does an algebraic entry | 31415 | entry which takes its input from the keyboard, even during macro |
| 31411 | which takes its input from the keyboard, even during macro execution. | 31416 | execution. All the normal conventions of algebraic input, including the |
| 31412 | This command allows your keyboard macros to accept numbers or formulas | 31417 | use of @kbd{$} characters, are supported. The prompt message itself is |
| 31413 | as interactive input. All the normal conventions of algebraic input, | 31418 | taken from the top of the stack, and so must be entered (as a string) |
| 31414 | including the use of @kbd{$} characters, are supported. | 31419 | before the @kbd{Z #} command. (Recall, as a string it can be entered by |
| 31420 | pressing the @kbd{"} key and will appear as a vector when it is put on | ||
| 31421 | the stack. The prompt message is only put on the stack to provide a | ||
| 31422 | prompt for the @kbd{Z #} command; it will not play any role in any | ||
| 31423 | subsequent calculations.) This command allows your keyboard macros to | ||
| 31424 | accept numbers or formulas as interactive input. | ||
| 31425 | |||
| 31426 | As an example, | ||
| 31427 | @kbd{2 @key{RET} "Power: " @key{RET} Z # 3 @key{RET} ^} will prompt for | ||
| 31428 | input with ``Power: '' in the minibuffer, then return 2 to the provided | ||
| 31429 | power. (The response to the prompt that's given, 3 in this example, | ||
| 31430 | will not be part of the macro.) | ||
| 31415 | 31431 | ||
| 31416 | @xref{Keyboard Macro Query, , , emacs, the Emacs Manual}, for a description of | 31432 | @xref{Keyboard Macro Query, , , emacs, the Emacs Manual}, for a description of |
| 31417 | @kbd{C-x q} (@code{kbd-macro-query}), the standard Emacs way to accept | 31433 | @kbd{C-x q} (@code{kbd-macro-query}), the standard Emacs way to accept |
| @@ -33628,22 +33644,25 @@ example, for a rectangular complex number the result is the sum of | |||
| 33628 | the absolute values of the components. | 33644 | the absolute values of the components. |
| 33629 | @end defun | 33645 | @end defun |
| 33630 | 33646 | ||
| 33631 | @findex two-pi | 33647 | @findex e |
| 33648 | @findex gamma-const | ||
| 33649 | @findex ln-2 | ||
| 33650 | @findex ln-10 | ||
| 33651 | @findex phi | ||
| 33632 | @findex pi-over-2 | 33652 | @findex pi-over-2 |
| 33633 | @findex pi-over-4 | 33653 | @findex pi-over-4 |
| 33634 | @findex pi-over-180 | 33654 | @findex pi-over-180 |
| 33635 | @findex sqrt-two-pi | 33655 | @findex sqrt-two-pi |
| 33636 | @findex sqrt-e | 33656 | @findex sqrt-e |
| 33637 | @findex e | 33657 | @findex two-pi |
| 33638 | @findex ln-2 | ||
| 33639 | @findex ln-10 | ||
| 33640 | @defun pi | 33658 | @defun pi |
| 33641 | The function @samp{(pi)} computes @samp{pi} to the current precision. | 33659 | The function @samp{(pi)} computes @samp{pi} to the current precision. |
| 33642 | Other related constant-generating functions are @code{two-pi}, | 33660 | Other related constant-generating functions are @code{two-pi}, |
| 33643 | @code{pi-over-2}, @code{pi-over-4}, @code{pi-over-180}, @code{sqrt-two-pi}, | 33661 | @code{pi-over-2}, @code{pi-over-4}, @code{pi-over-180}, @code{sqrt-two-pi}, |
| 33644 | @code{e}, @code{sqrt-e}, @code{ln-2}, and @code{ln-10}. Each function | 33662 | @code{e}, @code{sqrt-e}, @code{ln-2}, @code{ln-10}, @code{phi} and |
| 33645 | returns a floating-point value in the current precision, and each uses | 33663 | @code{gamma-const}. Each function returns a floating-point value in the |
| 33646 | caching so that all calls after the first are essentially free. | 33664 | current precision, and each uses caching so that all calls after the |
| 33665 | first are essentially free. | ||
| 33647 | @end defun | 33666 | @end defun |
| 33648 | 33667 | ||
| 33649 | @defmac math-defcache @var{func} @var{initial} @var{form} | 33668 | @defmac math-defcache @var{func} @var{initial} @var{form} |
| @@ -34692,7 +34711,7 @@ step, before the Calc window is destroyed. | |||
| 34692 | @end defvar | 34711 | @end defvar |
| 34693 | 34712 | ||
| 34694 | @defvar calc-window-hook | 34713 | @defvar calc-window-hook |
| 34695 | If this hook exists, it is called to create the Calc window. | 34714 | If this hook is non-@code{nil}, it is called to create the Calc window. |
| 34696 | Upon return, this new Calc window should be the current window. | 34715 | Upon return, this new Calc window should be the current window. |
| 34697 | (The Calc buffer will already be the current buffer when the | 34716 | (The Calc buffer will already be the current buffer when the |
| 34698 | hook is called.) If the hook is not defined, Calc will | 34717 | hook is called.) If the hook is not defined, Calc will |
| @@ -34701,10 +34720,10 @@ and @code{select-window} to create the Calc window. | |||
| 34701 | @end defvar | 34720 | @end defvar |
| 34702 | 34721 | ||
| 34703 | @defvar calc-trail-window-hook | 34722 | @defvar calc-trail-window-hook |
| 34704 | If this hook exists, it is called to create the Calc Trail window. | 34723 | If this hook is non-@code{nil}, it is called to create the Calc Trail |
| 34705 | The variable @code{calc-trail-buffer} will contain the buffer | 34724 | window. The variable @code{calc-trail-buffer} will contain the buffer |
| 34706 | which the window should use. Unlike @code{calc-window-hook}, | 34725 | which the window should use. Unlike @code{calc-window-hook}, this hook |
| 34707 | this hook must @emph{not} switch into the new window. | 34726 | must @emph{not} switch into the new window. |
| 34708 | @end defvar | 34727 | @end defvar |
| 34709 | 34728 | ||
| 34710 | @defvar calc-edit-mode-hook | 34729 | @defvar calc-edit-mode-hook |
| @@ -34808,11 +34827,7 @@ expression is basically a pattern that Calc can search for. | |||
| 34808 | See @ref{Regexp Search,, Regular Expression Search, emacs, The GNU Emacs Manual} | 34827 | See @ref{Regexp Search,, Regular Expression Search, emacs, The GNU Emacs Manual} |
| 34809 | to see how regular expressions work. | 34828 | to see how regular expressions work. |
| 34810 | 34829 | ||
| 34811 | @table @code | 34830 | @defvar calc-settings-file |
| 34812 | |||
| 34813 | @item calc-settings-file | ||
| 34814 | |||
| 34815 | @vindex calc-settings-file | ||
| 34816 | The variable @code{calc-settings-file} holds the file name in | 34831 | The variable @code{calc-settings-file} holds the file name in |
| 34817 | which commands like @kbd{m m} and @kbd{Z P} store ``permanent'' | 34832 | which commands like @kbd{m m} and @kbd{Z P} store ``permanent'' |
| 34818 | definitions. | 34833 | definitions. |
| @@ -34822,9 +34837,9 @@ If @code{calc-settings-file} is not your user init file (typically | |||
| 34822 | exists) the first time Calc is invoked. | 34837 | exists) the first time Calc is invoked. |
| 34823 | 34838 | ||
| 34824 | The default value for this variable is @code{"~/.calc.el"}. | 34839 | The default value for this variable is @code{"~/.calc.el"}. |
| 34840 | @end defvar | ||
| 34825 | 34841 | ||
| 34826 | @item calc-gnuplot-name | 34842 | @defvar calc-gnuplot-name |
| 34827 | |||
| 34828 | See @ref{Graphics}.@* | 34843 | See @ref{Graphics}.@* |
| 34829 | The variable @code{calc-gnuplot-name} should be the name of the | 34844 | The variable @code{calc-gnuplot-name} should be the name of the |
| 34830 | GNUPLOT program (a string). If you have GNUPLOT installed on your | 34845 | GNUPLOT program (a string). If you have GNUPLOT installed on your |
| @@ -34833,10 +34848,10 @@ variable. (@pxref{Customizable Variables}) | |||
| 34833 | You may also need to set some Lisp variables to show Calc how to run | 34848 | You may also need to set some Lisp variables to show Calc how to run |
| 34834 | GNUPLOT on your system, see @ref{Devices, ,Graphical Devices} . The default value | 34849 | GNUPLOT on your system, see @ref{Devices, ,Graphical Devices} . The default value |
| 34835 | of @code{calc-gnuplot-name} is @code{"gnuplot"}. | 34850 | of @code{calc-gnuplot-name} is @code{"gnuplot"}. |
| 34851 | @end defvar | ||
| 34836 | 34852 | ||
| 34837 | @item calc-gnuplot-plot-command | 34853 | @defvar calc-gnuplot-plot-command |
| 34838 | @itemx calc-gnuplot-print-command | 34854 | @defvarx calc-gnuplot-print-command |
| 34839 | |||
| 34840 | See @ref{Devices, ,Graphical Devices}.@* | 34855 | See @ref{Devices, ,Graphical Devices}.@* |
| 34841 | The variables @code{calc-gnuplot-plot-command} and | 34856 | The variables @code{calc-gnuplot-plot-command} and |
| 34842 | @code{calc-gnuplot-print-command} represent system commands to | 34857 | @code{calc-gnuplot-print-command} represent system commands to |
| @@ -34849,9 +34864,9 @@ to display or print the output. | |||
| 34849 | The default value of @code{calc-gnuplot-plot-command} is @code{nil}, | 34864 | The default value of @code{calc-gnuplot-plot-command} is @code{nil}, |
| 34850 | and the default value of @code{calc-gnuplot-print-command} is | 34865 | and the default value of @code{calc-gnuplot-print-command} is |
| 34851 | @code{"lp %s"}. | 34866 | @code{"lp %s"}. |
| 34867 | @end defvar | ||
| 34852 | 34868 | ||
| 34853 | @item calc-language-alist | 34869 | @defvar calc-language-alist |
| 34854 | |||
| 34855 | See @ref{Basic Embedded Mode}.@* | 34870 | See @ref{Basic Embedded Mode}.@* |
| 34856 | The variable @code{calc-language-alist} controls the languages that | 34871 | The variable @code{calc-language-alist} controls the languages that |
| 34857 | Calc will associate with major modes. When Calc embedded mode is | 34872 | Calc will associate with major modes. When Calc embedded mode is |
| @@ -34877,9 +34892,9 @@ The default value of @code{calc-language-alist} is | |||
| 34877 | (fortran-mode . fortran) | 34892 | (fortran-mode . fortran) |
| 34878 | (f90-mode . fortran)) | 34893 | (f90-mode . fortran)) |
| 34879 | @end example | 34894 | @end example |
| 34895 | @end defvar | ||
| 34880 | 34896 | ||
| 34881 | @item calc-embedded-announce-formula | 34897 | @defvar calc-embedded-announce-formula |
| 34882 | |||
| 34883 | See @ref{Customizing Embedded Mode}.@* | 34898 | See @ref{Customizing Embedded Mode}.@* |
| 34884 | The variable @code{calc-embedded-announce-formula} helps determine | 34899 | The variable @code{calc-embedded-announce-formula} helps determine |
| 34885 | what formulas @kbd{M-# a} will activate in a buffer. It is a | 34900 | what formulas @kbd{M-# a} will activate in a buffer. It is a |
| @@ -34891,10 +34906,10 @@ activated. (Calc also uses other patterns to find formulas, such as | |||
| 34891 | The default pattern is @code{"%Embed\n\\(% .*\n\\)*"}, which checks | 34906 | The default pattern is @code{"%Embed\n\\(% .*\n\\)*"}, which checks |
| 34892 | for @samp{%Embed} followed by any number of lines beginning with | 34907 | for @samp{%Embed} followed by any number of lines beginning with |
| 34893 | @samp{%} and a space. | 34908 | @samp{%} and a space. |
| 34909 | @end defvar | ||
| 34894 | 34910 | ||
| 34895 | @item calc-embedded-open-formula | 34911 | @defvar calc-embedded-open-formula |
| 34896 | @itemx calc-embedded-close-formula | 34912 | @defvarx calc-embedded-close-formula |
| 34897 | |||
| 34898 | See @ref{Customizing Embedded Mode}.@* | 34913 | See @ref{Customizing Embedded Mode}.@* |
| 34899 | The variables @code{calc-embedded-open-formula} and | 34914 | The variables @code{calc-embedded-open-formula} and |
| 34900 | @code{calc-embedded-open-formula} control the region that Calc will | 34915 | @code{calc-embedded-open-formula} control the region that Calc will |
| @@ -34919,10 +34934,10 @@ Lines beginning with @samp{.EQ} and @samp{.EN} (@dfn{eqn} delimiters); | |||
| 34919 | @item | 34934 | @item |
| 34920 | Lines containing a single @samp{%} or @samp{.\"} symbol and nothing else. | 34935 | Lines containing a single @samp{%} or @samp{.\"} symbol and nothing else. |
| 34921 | @end enumerate | 34936 | @end enumerate |
| 34937 | @end defvar | ||
| 34922 | 34938 | ||
| 34923 | @item calc-embedded-open-word | 34939 | @defvar calc-embedded-open-word |
| 34924 | @itemx calc-embedded-close-word | 34940 | @defvarx calc-embedded-close-word |
| 34925 | |||
| 34926 | See @ref{Customizing Embedded Mode}.@* | 34941 | See @ref{Customizing Embedded Mode}.@* |
| 34927 | The variables @code{calc-embedded-open-word} and | 34942 | The variables @code{calc-embedded-open-word} and |
| 34928 | @code{calc-embedded-close-word} control the region that Calc will | 34943 | @code{calc-embedded-close-word} control the region that Calc will |
| @@ -34932,10 +34947,10 @@ regular expressions. | |||
| 34932 | The default values of @code{calc-embedded-open-word} and | 34947 | The default values of @code{calc-embedded-open-word} and |
| 34933 | @code{calc-embedded-close-word} are @code{"^\\|[^-+0-9.eE]"} and | 34948 | @code{calc-embedded-close-word} are @code{"^\\|[^-+0-9.eE]"} and |
| 34934 | @code{"$\\|[^-+0-9.eE]"} respectively. | 34949 | @code{"$\\|[^-+0-9.eE]"} respectively. |
| 34950 | @end defvar | ||
| 34935 | 34951 | ||
| 34936 | @item calc-embedded-open-plain | 34952 | @defvar calc-embedded-open-plain |
| 34937 | @itemx calc-embedded-close-plain | 34953 | @defvarx calc-embedded-close-plain |
| 34938 | |||
| 34939 | See @ref{Customizing Embedded Mode}.@* | 34954 | See @ref{Customizing Embedded Mode}.@* |
| 34940 | The variables @code{calc-embedded-open-plain} and | 34955 | The variables @code{calc-embedded-open-plain} and |
| 34941 | @code{calc-embedded-open-plain} are used to delimit ``plain'' | 34956 | @code{calc-embedded-open-plain} are used to delimit ``plain'' |
| @@ -34948,10 +34963,10 @@ The default string for @code{calc-embedded-open-plain} is | |||
| 34948 | @code{calc-embedded-close-plain} is @code{" %%%\n"}, without | 34963 | @code{calc-embedded-close-plain} is @code{" %%%\n"}, without |
| 34949 | the trailing newline here, the first line of a Big mode formula | 34964 | the trailing newline here, the first line of a Big mode formula |
| 34950 | that followed might be shifted over with respect to the other lines. | 34965 | that followed might be shifted over with respect to the other lines. |
| 34966 | @end defvar | ||
| 34951 | 34967 | ||
| 34952 | @item calc-embedded-open-new-formula | 34968 | @defvar calc-embedded-open-new-formula |
| 34953 | @itemx calc-embedded-close-new-formula | 34969 | @defvarx calc-embedded-close-new-formula |
| 34954 | |||
| 34955 | See @ref{Customizing Embedded Mode}.@* | 34970 | See @ref{Customizing Embedded Mode}.@* |
| 34956 | The variables @code{calc-embedded-open-new-formula} and | 34971 | The variables @code{calc-embedded-open-new-formula} and |
| 34957 | @code{calc-embedded-close-new-formula} are strings which are | 34972 | @code{calc-embedded-close-new-formula} are strings which are |
| @@ -34966,10 +34981,10 @@ also @code{"\n\n"}. The final newline is omitted by @w{@kbd{M-# f}} | |||
| 34966 | if typed at the end of a line. (It follows that if @kbd{M-# f} is | 34981 | if typed at the end of a line. (It follows that if @kbd{M-# f} is |
| 34967 | typed on a blank line, both a leading opening newline and a trailing | 34982 | typed on a blank line, both a leading opening newline and a trailing |
| 34968 | closing newline are omitted.) | 34983 | closing newline are omitted.) |
| 34984 | @end defvar | ||
| 34969 | 34985 | ||
| 34970 | @item calc-embedded-open-mode | 34986 | @defvar calc-embedded-open-mode |
| 34971 | @itemx calc-embedded-close-mode | 34987 | @defvarx calc-embedded-close-mode |
| 34972 | |||
| 34973 | See @ref{Customizing Embedded Mode}.@* | 34988 | See @ref{Customizing Embedded Mode}.@* |
| 34974 | The variables @code{calc-embedded-open-mode} and | 34989 | The variables @code{calc-embedded-open-mode} and |
| 34975 | @code{calc-embedded-close-mode} are strings which Calc will place before | 34990 | @code{calc-embedded-close-mode} are strings which Calc will place before |
| @@ -34983,8 +34998,7 @@ and the default value of @code{calc-embedded-close-mode} is | |||
| 34983 | If you change the value of @code{calc-embedded-close-mode}, it is a good | 34998 | If you change the value of @code{calc-embedded-close-mode}, it is a good |
| 34984 | idea still to end with a newline so that mode annotations will appear on | 34999 | idea still to end with a newline so that mode annotations will appear on |
| 34985 | lines by themselves. | 35000 | lines by themselves. |
| 34986 | 35001 | @end defvar | |
| 34987 | @end table | ||
| 34988 | 35002 | ||
| 34989 | @node Reporting Bugs, Summary, Customizable Variables, Top | 35003 | @node Reporting Bugs, Summary, Customizable Variables, Top |
| 34990 | @appendix Reporting Bugs | 35004 | @appendix Reporting Bugs |
| @@ -35089,11 +35103,12 @@ keystrokes are not listed in this summary. | |||
| 35089 | @r{ @: M-# r @: @: 36 @:calc-grab-rectangle@:} | 35103 | @r{ @: M-# r @: @: 36 @:calc-grab-rectangle@:} |
| 35090 | @r{ @: M-# s @: @: @:calc-info-summary@:} | 35104 | @r{ @: M-# s @: @: @:calc-info-summary@:} |
| 35091 | @r{ @: M-# t @: @: @:calc-tutorial@:} | 35105 | @r{ @: M-# t @: @: @:calc-tutorial@:} |
| 35092 | @r{ @: M-# u @: @: @:calc-embedded-update@:} | 35106 | @r{ @: M-# u @: @: @:calc-embedded-update-formula@:} |
| 35093 | @r{ @: M-# w @: @: @:calc-embedded-word@:} | 35107 | @r{ @: M-# w @: @: @:calc-embedded-word@:} |
| 35094 | @r{ @: M-# x @: @: @:calc-quit@:} | 35108 | @r{ @: M-# x @: @: @:calc-quit@:} |
| 35095 | @r{ @: M-# y @: @:1,28,49 @:calc-copy-to-buffer@:} | 35109 | @r{ @: M-# y @: @:1,28,49 @:calc-copy-to-buffer@:} |
| 35096 | @r{ @: M-# z @: @: @:calc-user-invocation@:} | 35110 | @r{ @: M-# z @: @: @:calc-user-invocation@:} |
| 35111 | @r{ @: M-# = @: @: @:calc-embedded-update-formula@:} | ||
| 35097 | @r{ @: M-# : @: @: 36 @:calc-grab-sum-down@:} | 35112 | @r{ @: M-# : @: @: 36 @:calc-grab-sum-down@:} |
| 35098 | @r{ @: M-# _ @: @: 36 @:calc-grab-sum-across@:} | 35113 | @r{ @: M-# _ @: @: 36 @:calc-grab-sum-across@:} |
| 35099 | @r{ @: M-# ` @:editing @: 30 @:calc-embedded-edit@:} | 35114 | @r{ @: M-# ` @:editing @: 30 @:calc-embedded-edit@:} |
| @@ -35869,8 +35884,7 @@ keystrokes are not listed in this summary. | |||
| 35869 | @c | 35884 | @c |
| 35870 | @r{ @: Z ` @: @: @:calc-kbd-push@:} | 35885 | @r{ @: Z ` @: @: @:calc-kbd-push@:} |
| 35871 | @r{ @: Z ' @: @: @:calc-kbd-pop@:} | 35886 | @r{ @: Z ' @: @: @:calc-kbd-pop@:} |
| 35872 | @r{ a@: Z = @:message @: 28 @:calc-kbd-report@:} | 35887 | @r{ @: Z # @: @: @:calc-kbd-query@:} |
| 35873 | @r{ @: Z # @:prompt @: @:calc-kbd-query@:} | ||
| 35874 | 35888 | ||
| 35875 | @c | 35889 | @c |
| 35876 | @r{ comp@: Z C @:func, args @: 50 @:calc-user-define-composition@:} | 35890 | @r{ comp@: Z C @:func, args @: 50 @:calc-user-define-composition@:} |
diff --git a/man/calendar.texi b/man/calendar.texi index cf02377f1d9..1ef4aef09d4 100644 --- a/man/calendar.texi +++ b/man/calendar.texi | |||
| @@ -1046,7 +1046,7 @@ an illusion, so simply printing the buffer does not print what you see | |||
| 1046 | on your screen. There is a special command to print hard copy of the | 1046 | on your screen. There is a special command to print hard copy of the |
| 1047 | diary buffer @emph{as it appears}; this command is @kbd{M-x | 1047 | diary buffer @emph{as it appears}; this command is @kbd{M-x |
| 1048 | print-diary-entries}. It sends the data directly to the printer. You | 1048 | print-diary-entries}. It sends the data directly to the printer. You |
| 1049 | can customize it like @code{lpr-region} (@pxref{Hardcopy}). | 1049 | can customize it like @code{lpr-region} (@pxref{Printing}). |
| 1050 | 1050 | ||
| 1051 | @findex diary | 1051 | @findex diary |
| 1052 | The command @kbd{M-x diary} displays the diary entries for the current | 1052 | The command @kbd{M-x diary} displays the diary entries for the current |
diff --git a/man/dired.texi b/man/dired.texi index f2699cfde07..8cb4646075e 100644 --- a/man/dired.texi +++ b/man/dired.texi | |||
| @@ -616,7 +616,7 @@ Print the specified files (@code{dired-do-print}). You must specify the | |||
| 616 | command to print them with, but the minibuffer starts out with a | 616 | command to print them with, but the minibuffer starts out with a |
| 617 | suitable guess made using the variables @code{lpr-command} and | 617 | suitable guess made using the variables @code{lpr-command} and |
| 618 | @code{lpr-switches} (the same variables that @code{lpr-buffer} uses; | 618 | @code{lpr-switches} (the same variables that @code{lpr-buffer} uses; |
| 619 | @pxref{Hardcopy}). | 619 | @pxref{Printing}). |
| 620 | 620 | ||
| 621 | @findex dired-do-compress | 621 | @findex dired-do-compress |
| 622 | @kindex Z @r{(Dired)} | 622 | @kindex Z @r{(Dired)} |
diff --git a/man/emacs.texi b/man/emacs.texi index 345d54ce0c5..69081b2c02b 100644 --- a/man/emacs.texi +++ b/man/emacs.texi | |||
| @@ -191,9 +191,7 @@ Advanced Features | |||
| 191 | * Gnus:: How to read netnews with Emacs. | 191 | * Gnus:: How to read netnews with Emacs. |
| 192 | * Shell:: Executing shell commands from Emacs. | 192 | * Shell:: Executing shell commands from Emacs. |
| 193 | * Emacs Server:: Using Emacs as an editing server for @code{mail}, etc. | 193 | * Emacs Server:: Using Emacs as an editing server for @code{mail}, etc. |
| 194 | * Hardcopy:: Printing buffers or regions. | 194 | * Printing:: Printing hardcopies of buffers or regions. |
| 195 | * PostScript:: Printing buffers or regions as PostScript. | ||
| 196 | * PostScript Variables::Customizing the PostScript printing commands. | ||
| 197 | * Sorting:: Sorting lines, paragraphs or pages within Emacs. | 195 | * Sorting:: Sorting lines, paragraphs or pages within Emacs. |
| 198 | * Narrowing:: Restricting display and editing to a portion | 196 | * Narrowing:: Restricting display and editing to a portion |
| 199 | of the buffer. | 197 | of the buffer. |
diff --git a/man/files.texi b/man/files.texi index 6be4d0f467d..c83572a8550 100644 --- a/man/files.texi +++ b/man/files.texi | |||
| @@ -1526,8 +1526,29 @@ Version Control}). | |||
| 1526 | 1526 | ||
| 1527 | When you check in changes, @kbd{C-x v v} first reads a log entry. It | 1527 | When you check in changes, @kbd{C-x v v} first reads a log entry. It |
| 1528 | pops up a buffer called @samp{*VC-Log*} for you to enter the log entry. | 1528 | pops up a buffer called @samp{*VC-Log*} for you to enter the log entry. |
| 1529 | When you are finished, type @kbd{C-c C-c} in the @samp{*VC-Log*} buffer. | 1529 | |
| 1530 | That is when check-in really happens. | 1530 | Sometimes the @samp{*VC-Log*} buffer contains default text when you enter it, |
| 1531 | typically the last log message entered. If it does, mark and point | ||
| 1532 | are set around the entire contents of the buffer so that it is easy to | ||
| 1533 | kill the contents of the buffer with @kbd{C-w}. | ||
| 1534 | |||
| 1535 | @findex log-edit-insert-changelog | ||
| 1536 | If you work by writing entries in the @file{ChangeLog} | ||
| 1537 | (@pxref{Change Log}) and then commit the change under revision | ||
| 1538 | control, you can generate the Log Edit text from the ChangeLog using | ||
| 1539 | @kbd{C-c C-a} (@kbd{log-edit-insert-changelog}). This looks for | ||
| 1540 | entries for the file(s) concerned in the top entry in the ChangeLog | ||
| 1541 | and uses those paragraphs as the log text. This text is only inserted | ||
| 1542 | if the top entry was made under your user name on the current date. | ||
| 1543 | @xref{Change Logs and VC}, for the opposite way of | ||
| 1544 | working---generating ChangeLog entries from the revision control log. | ||
| 1545 | |||
| 1546 | In the @samp{*VC-Log*} buffer, @kbd{C-c C-f} (@kbd{M-x log-edit-show-files}) | ||
| 1547 | shows the list of files to be committed in case you need to check | ||
| 1548 | that. | ||
| 1549 | |||
| 1550 | When you have finished editing the log message, type @kbd{C-c C-c} to | ||
| 1551 | exit the buffer and commit the change. | ||
| 1531 | 1552 | ||
| 1532 | To abort check-in, just @strong{don't} type @kbd{C-c C-c} in that | 1553 | To abort check-in, just @strong{don't} type @kbd{C-c C-c} in that |
| 1533 | buffer. You can switch buffers and do other editing. As long as you | 1554 | buffer. You can switch buffers and do other editing. As long as you |
diff --git a/man/frames.texi b/man/frames.texi index 2b2c61af133..e5bada851ad 100644 --- a/man/frames.texi +++ b/man/frames.texi | |||
| @@ -393,6 +393,14 @@ This menu is for specifying the frame's principal font. | |||
| 393 | You can use mouse clicks on window mode lines to select and manipulate | 393 | You can use mouse clicks on window mode lines to select and manipulate |
| 394 | windows. | 394 | windows. |
| 395 | 395 | ||
| 396 | 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 | ||
| 398 | highlighted when you hold the mouse over them, and information about | ||
| 399 | the special bindings will be displayed (@pxref{Tooltips}). | ||
| 400 | |||
| 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 | |||
| 396 | @table @kbd | 404 | @table @kbd |
| 397 | @item Mouse-1 | 405 | @item Mouse-1 |
| 398 | @kindex Mouse-1 @r{(mode line)} | 406 | @kindex Mouse-1 @r{(mode line)} |
| @@ -420,12 +428,6 @@ horizontally, above the place in the mode line where you click. | |||
| 420 | @kbd{C-Mouse-2} on a scroll bar splits the corresponding window | 428 | @kbd{C-Mouse-2} on a scroll bar splits the corresponding window |
| 421 | vertically. @xref{Split Window}. | 429 | vertically. @xref{Split Window}. |
| 422 | 430 | ||
| 423 | The commands above apply to areas of the mode line which do not have | ||
| 424 | special mouse bindings of their own. Some areas, such as the buffer | ||
| 425 | name and the major mode name, have their own special mouse bindings. | ||
| 426 | Emacs displays information about these bindings when you hold the | ||
| 427 | mouse over such a place (@pxref{Tooltips}). | ||
| 428 | |||
| 429 | @node Creating Frames | 431 | @node Creating Frames |
| 430 | @section Creating Frames | 432 | @section Creating Frames |
| 431 | @cindex creating frames | 433 | @cindex creating frames |
diff --git a/man/glossary.texi b/man/glossary.texi index f75ba725a18..78abbfb30b7 100644 --- a/man/glossary.texi +++ b/man/glossary.texi | |||
| @@ -573,7 +573,7 @@ Search}). See also `font lock'. | |||
| 573 | 573 | ||
| 574 | @item Hardcopy | 574 | @item Hardcopy |
| 575 | Hardcopy means printed output. Emacs has commands for making printed | 575 | Hardcopy means printed output. Emacs has commands for making printed |
| 576 | listings of text in Emacs buffers. @xref{Hardcopy}. | 576 | listings of text in Emacs buffers. @xref{Printing}. |
| 577 | 577 | ||
| 578 | @item @key{HELP} | 578 | @item @key{HELP} |
| 579 | @key{HELP} is the Emacs name for @kbd{C-h} or @key{F1}. You can type | 579 | @key{HELP} is the Emacs name for @kbd{C-h} or @key{F1}. You can type |
diff --git a/man/mark.texi b/man/mark.texi index f609472bca7..5f4c44de9e1 100644 --- a/man/mark.texi +++ b/man/mark.texi | |||
| @@ -293,7 +293,7 @@ Indent it with @kbd{C-x @key{TAB}} or @kbd{C-M-\} (@pxref{Indentation}). | |||
| 293 | @item | 293 | @item |
| 294 | Fill it as text with @kbd{M-x fill-region} (@pxref{Filling}). | 294 | Fill it as text with @kbd{M-x fill-region} (@pxref{Filling}). |
| 295 | @item | 295 | @item |
| 296 | Print hardcopy with @kbd{M-x print-region} (@pxref{Hardcopy}). | 296 | Print hardcopy with @kbd{M-x print-region} (@pxref{Printing}). |
| 297 | @item | 297 | @item |
| 298 | Evaluate it as Lisp code with @kbd{M-x eval-region} (@pxref{Lisp Eval}). | 298 | Evaluate it as Lisp code with @kbd{M-x eval-region} (@pxref{Lisp Eval}). |
| 299 | @end itemize | 299 | @end itemize |
diff --git a/man/misc.texi b/man/misc.texi index 68dd7356479..cf2fa5ff28d 100644 --- a/man/misc.texi +++ b/man/misc.texi | |||
| @@ -1214,7 +1214,7 @@ off directory tracking. | |||
| 1214 | 1214 | ||
| 1215 | @end ignore | 1215 | @end ignore |
| 1216 | 1216 | ||
| 1217 | @node Emacs Server, Hardcopy, Shell, Top | 1217 | @node Emacs Server, Printing, Shell, Top |
| 1218 | @section Using Emacs as a Server | 1218 | @section Using Emacs as a Server |
| 1219 | @pindex emacsclient | 1219 | @pindex emacsclient |
| 1220 | @cindex Emacs as a server | 1220 | @cindex Emacs as a server |
| @@ -1374,14 +1374,17 @@ code, using the option @samp{--eval}. When this option is given, the | |||
| 1374 | rest of the arguments is not taken as a list of files to visit but as | 1374 | rest of the arguments is not taken as a list of files to visit but as |
| 1375 | a list of expressions to evaluate. | 1375 | a list of expressions to evaluate. |
| 1376 | 1376 | ||
| 1377 | @node Hardcopy, PostScript, Emacs Server, Top | 1377 | @node Printing, Sorting, Emacs Server, Top |
| 1378 | @section Hardcopy Output | 1378 | @section Printing Hard Copies |
| 1379 | @cindex hardcopy | 1379 | @cindex hardcopy |
| 1380 | @cindex printing | ||
| 1380 | 1381 | ||
| 1381 | The Emacs commands for making hardcopy let you print either an entire | 1382 | Emacs provides commands for printing hard copies of either an entire |
| 1382 | buffer or just part of one, either with or without page headers. | 1383 | buffer or just part of one, with or without page headers. You can |
| 1383 | See also the hardcopy commands of Dired (@pxref{Misc File Ops}) | 1384 | invoke the printing commands directly, as detailed in the following |
| 1384 | and the diary (@pxref{Displaying the Diary}). | 1385 | section, or using the @samp{File} menu on the menu bar. See also the |
| 1386 | hardcopy commands of Dired (@pxref{Misc File Ops}) and the diary | ||
| 1387 | (@pxref{Displaying the Diary}). | ||
| 1385 | 1388 | ||
| 1386 | @table @kbd | 1389 | @table @kbd |
| 1387 | @item M-x print-buffer | 1390 | @item M-x print-buffer |
| @@ -1428,7 +1431,13 @@ whether to supply @samp{-T} and @samp{-J} options (suitable for | |||
| 1428 | @code{lpr-add-switches} should be @code{nil} if your printer program is | 1431 | @code{lpr-add-switches} should be @code{nil} if your printer program is |
| 1429 | not compatible with @code{lpr}. | 1432 | not compatible with @code{lpr}. |
| 1430 | 1433 | ||
| 1431 | @node PostScript, PostScript Variables, Hardcopy, Top | 1434 | @menu |
| 1435 | * PostScript:: Printing buffers or regions as PostScript. | ||
| 1436 | * PostScript Variables:: Customizing the PostScript printing commands. | ||
| 1437 | * Printing Package:: An optional advanced printing interface. | ||
| 1438 | @end menu | ||
| 1439 | |||
| 1440 | @node PostScript, PostScript Variables,, Printing | ||
| 1432 | @section PostScript Hardcopy | 1441 | @section PostScript Hardcopy |
| 1433 | 1442 | ||
| 1434 | These commands convert buffer contents to PostScript, | 1443 | These commands convert buffer contents to PostScript, |
| @@ -1492,7 +1501,7 @@ supports ISO 8859-1 characters. | |||
| 1492 | The following section describes variables for customizing these commands. | 1501 | The following section describes variables for customizing these commands. |
| 1493 | @end ifinfo | 1502 | @end ifinfo |
| 1494 | 1503 | ||
| 1495 | @node PostScript Variables, Sorting, PostScript, Top | 1504 | @node PostScript Variables, Printing Package, PostScript, Printing |
| 1496 | @section Variables for PostScript Hardcopy | 1505 | @section Variables for PostScript Hardcopy |
| 1497 | 1506 | ||
| 1498 | @vindex ps-lpr-command | 1507 | @vindex ps-lpr-command |
| @@ -1584,7 +1593,33 @@ includes a single directory @file{/usr/local/share/emacs/fonts/bdf}. | |||
| 1584 | Many other customization variables for these commands are defined and | 1593 | Many other customization variables for these commands are defined and |
| 1585 | described in the Lisp files @file{ps-print.el} and @file{ps-mule.el}. | 1594 | described in the Lisp files @file{ps-print.el} and @file{ps-mule.el}. |
| 1586 | 1595 | ||
| 1587 | @node Sorting, Narrowing, PostScript Variables, Top | 1596 | @node Printing Package,, PostScript Variables, Printing |
| 1597 | @section Printing Package | ||
| 1598 | @cindex Printing package | ||
| 1599 | |||
| 1600 | The basic Emacs facilities for printing hardcopy can be extended | ||
| 1601 | using the Printing package. This provides an easy-to-use interface | ||
| 1602 | for choosing what to print, previewing PostScript files before | ||
| 1603 | printing, and setting various printing options such as print headers, | ||
| 1604 | landscape or portrait modes, duplex modes, and so forth. On GNU/Linux | ||
| 1605 | or Unix systems, the Printing package relies on the @file{gs} and | ||
| 1606 | @file{gv} utilities, which are distributed as part of the GhostScript | ||
| 1607 | program. On MS-Windows, the @file{gstools} port of Ghostscript can be | ||
| 1608 | used. | ||
| 1609 | |||
| 1610 | @findex pr-interface | ||
| 1611 | To use the Printing package, add @code{(require 'printing)} to your | ||
| 1612 | init file (@pxref{Init File}). The usual printing options in the menu | ||
| 1613 | bar will be replaced with a @samp{Printing} submenu, containing | ||
| 1614 | various printing options. You can also type @kbd{M-x pr-interface | ||
| 1615 | RET}; this creates a @samp{*Printing Interface*} buffer, similar to a | ||
| 1616 | customization buffer , where you can set the printing options. After | ||
| 1617 | selecting what and how to print, start the print job using the | ||
| 1618 | @samp{Print} button (click @kbd{mouse-2} on it, or move point over it | ||
| 1619 | and type @kbd{RET}). For further information on the various options, | ||
| 1620 | use the @samp{Interface Help} button. | ||
| 1621 | |||
| 1622 | @node Sorting, Narrowing, Printing, Top | ||
| 1588 | @section Sorting Text | 1623 | @section Sorting Text |
| 1589 | @cindex sorting | 1624 | @cindex sorting |
| 1590 | 1625 | ||
diff --git a/man/msdog.texi b/man/msdog.texi index a1d7647a95d..a5aea27f161 100644 --- a/man/msdog.texi +++ b/man/msdog.texi | |||
| @@ -419,13 +419,12 @@ EOL conversion is determined by @code{file-name-buffer-file-type-alist}. | |||
| 419 | @node MS-DOS Printing | 419 | @node MS-DOS Printing |
| 420 | @section Printing and MS-DOS | 420 | @section Printing and MS-DOS |
| 421 | 421 | ||
| 422 | Printing commands, such as @code{lpr-buffer} (@pxref{Hardcopy}) and | 422 | Printing commands, such as @code{lpr-buffer} (@pxref{Printing}) and |
| 423 | @code{ps-print-buffer} (@pxref{PostScript}) can work in MS-DOS and | 423 | @code{ps-print-buffer} (@pxref{PostScript}) can work in MS-DOS and |
| 424 | MS-Windows by sending the output to one of the printer ports, if a | 424 | MS-Windows by sending the output to one of the printer ports, if a |
| 425 | Posix-style @code{lpr} program is unavailable. The same Emacs | 425 | Posix-style @code{lpr} program is unavailable. The same Emacs |
| 426 | variables control printing on all systems (@pxref{Hardcopy}), but in | 426 | variables control printing on all systems, but in some cases they have |
| 427 | some cases they have different default values on MS-DOS and | 427 | different default values on MS-DOS and MS-Windows. |
| 428 | MS-Windows. | ||
| 429 | 428 | ||
| 430 | @vindex printer-name @r{(MS-DOS)} | 429 | @vindex printer-name @r{(MS-DOS)} |
| 431 | If you want to use your local printer, printing on it in the usual DOS | 430 | If you want to use your local printer, printing on it in the usual DOS |
| @@ -758,7 +757,7 @@ implements a Posix-like shell entirely in Emacs Lisp. | |||
| 758 | Processes}. | 757 | Processes}. |
| 759 | 758 | ||
| 760 | @cindex printing under MS-DOS | 759 | @cindex printing under MS-DOS |
| 761 | Printing commands, such as @code{lpr-buffer} (@pxref{Hardcopy}) and | 760 | Printing commands, such as @code{lpr-buffer} (@pxref{Printing}) and |
| 762 | @code{ps-print-buffer} (@pxref{PostScript}), work in MS-DOS by sending | 761 | @code{ps-print-buffer} (@pxref{PostScript}), work in MS-DOS by sending |
| 763 | the output to one of the printer ports. @xref{MS-DOS Printing}. | 762 | the output to one of the printer ports. @xref{MS-DOS Printing}. |
| 764 | 763 | ||
diff --git a/man/org.texi b/man/org.texi index 444256762b8..4f3576d57c4 100644 --- a/man/org.texi +++ b/man/org.texi | |||
| @@ -4,7 +4,7 @@ | |||
| 4 | @setfilename ../info/org | 4 | @setfilename ../info/org |
| 5 | @settitle Org Mode Manual | 5 | @settitle Org Mode Manual |
| 6 | 6 | ||
| 7 | @set VERSION 3.09 | 7 | @set VERSION 3.10 |
| 8 | @set DATE May 2005 | 8 | @set DATE May 2005 |
| 9 | 9 | ||
| 10 | @dircategory Emacs | 10 | @dircategory Emacs |
diff --git a/man/trouble.texi b/man/trouble.texi index df6a2763f3f..da14f25568f 100644 --- a/man/trouble.texi +++ b/man/trouble.texi | |||
| @@ -351,6 +351,25 @@ visits the file but gets the text from the auto-save file. | |||
| 351 | recover are present in Emacs buffers. You should then save them. Only | 351 | recover are present in Emacs buffers. You should then save them. Only |
| 352 | this---saving them---updates the files themselves. | 352 | this---saving them---updates the files themselves. |
| 353 | 353 | ||
| 354 | As a last resort, if you had buffers with content which were not | ||
| 355 | associated with any files, or if the autosave was not recent enough to | ||
| 356 | have recorded important changes, you can use the | ||
| 357 | @file{etc/emacs-buffer.gdb} script with GDB (the GNU Debugger) to | ||
| 358 | retrieve them from a core dump--provided that a core dump was saved, | ||
| 359 | and that the Emacs executable was not stripped of its debugging | ||
| 360 | symbols. | ||
| 361 | |||
| 362 | To use this script, run @code{gdb} with the file name of your Emacs | ||
| 363 | executable and the file name of the core dump, e.g. @samp{gdb | ||
| 364 | /usr/bin/emacs core.emacs}. At the @code{(gdb)} prompt, load the | ||
| 365 | recovery script: @samp{source /usr/src/emacs/etc/emacs-buffer.gdb}. | ||
| 366 | Then type the command @code{ybuffer-list} to see which buffers are | ||
| 367 | available. For each buffer, it lists a buffer number. To save a | ||
| 368 | buffer, use @code{ysave-buffer}; you specify the buffer number, and | ||
| 369 | the file name to write that buffer into. You should use a file name | ||
| 370 | which does not already exist; if the file does exist, the script does | ||
| 371 | not make make a backup of its old contents. | ||
| 372 | |||
| 354 | @node Emergency Escape | 373 | @node Emergency Escape |
| 355 | @subsection Emergency Escape | 374 | @subsection Emergency Escape |
| 356 | 375 | ||
diff --git a/nt/ChangeLog b/nt/ChangeLog index 33507ef581d..cfc93422a69 100644 --- a/nt/ChangeLog +++ b/nt/ChangeLog | |||
| @@ -1,3 +1,12 @@ | |||
| 1 | 2005-06-05 Eli Zaretskii <eliz@gnu.org> | ||
| 2 | |||
| 3 | * inc/sys/socket.h: Change arg 4 of sys_setsockopt to | ||
| 4 | `const void *', for consistency with Posix. | ||
| 5 | |||
| 6 | 2005-06-04 Eli Zaretskii <eliz@gnu.org> | ||
| 7 | |||
| 8 | * inc/pwd.h (getpwnam, getpwuid): Add prototypes. | ||
| 9 | |||
| 1 | 2005-05-24 Juanma Barranquero <lekktu@gmail.com> | 10 | 2005-05-24 Juanma Barranquero <lekktu@gmail.com> |
| 2 | 11 | ||
| 3 | * INSTALL: Add more pointers to ports of Unix tools to Windows, | 12 | * INSTALL: Add more pointers to ports of Unix tools to Windows, |
diff --git a/nt/inc/pwd.h b/nt/inc/pwd.h index 11f5669b0f0..31c0df7ec30 100644 --- a/nt/inc/pwd.h +++ b/nt/inc/pwd.h | |||
| @@ -18,6 +18,10 @@ struct passwd { | |||
| 18 | typedef int uid_t; | 18 | typedef int uid_t; |
| 19 | typedef uid_t gid_t; | 19 | typedef uid_t gid_t; |
| 20 | 20 | ||
| 21 | struct passwd * getpwnam (char *); | ||
| 22 | struct passwd * getpwuid (int); | ||
| 23 | |||
| 24 | |||
| 21 | #endif /* _PWD_H_ */ | 25 | #endif /* _PWD_H_ */ |
| 22 | 26 | ||
| 23 | /* arch-tag: 68308424-cb2b-49ed-bb52-b347fee416bf | 27 | /* arch-tag: 68308424-cb2b-49ed-bb52-b347fee416bf |
diff --git a/nt/inc/sys/socket.h b/nt/inc/sys/socket.h index 422a27d1b52..d3936da2a4d 100644 --- a/nt/inc/sys/socket.h +++ b/nt/inc/sys/socket.h | |||
| @@ -102,7 +102,7 @@ struct hostent * sys_gethostbyname (const char * name); | |||
| 102 | struct servent * sys_getservbyname (const char * name, const char * proto); | 102 | struct servent * sys_getservbyname (const char * name, const char * proto); |
| 103 | int sys_getpeername (int s, struct sockaddr *addr, int * namelen); | 103 | int sys_getpeername (int s, struct sockaddr *addr, int * namelen); |
| 104 | int sys_shutdown (int socket, int how); | 104 | int sys_shutdown (int socket, int how); |
| 105 | int sys_setsockopt (int s, int level, int oname, const char * oval, int olen); | 105 | int sys_setsockopt (int s, int level, int oname, const void * oval, int olen); |
| 106 | int sys_listen (int s, int backlog); | 106 | int sys_listen (int s, int backlog); |
| 107 | int sys_getsockname (int s, struct sockaddr * name, int * namelen); | 107 | int sys_getsockname (int s, struct sockaddr * name, int * namelen); |
| 108 | int sys_accept (int s, struct sockaddr *addr, int *addrlen); | 108 | int sys_accept (int s, struct sockaddr *addr, int *addrlen); |
diff --git a/src/ChangeLog b/src/ChangeLog index c2cd2dde5f7..6eeb4fc09f5 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,153 @@ | |||
| 1 | 2005-06-05 Eli Zaretskii <eliz@gnu.org> | ||
| 2 | |||
| 3 | * w32.c (sys_setsockopt): Change arg 4 to `const void *'. In the | ||
| 4 | call to pfn_setsockopt, cast optval to `const char *'. | ||
| 5 | |||
| 6 | 2005-06-04 Eli Zaretskii <eliz@gnu.org> | ||
| 7 | |||
| 8 | * w32.c (gettimeofday): Use struct _timeb, not struct timeb. | ||
| 9 | (open_unc_volume): Cast return value of map_w32_filename, to avoid | ||
| 10 | compiler warnings. | ||
| 11 | |||
| 12 | * s/ms-w32.h (fileno): Don't define if already defined. | ||
| 13 | |||
| 14 | * emacs.c: Include w32heap.h, to avoid compiler warning about sbrk. | ||
| 15 | |||
| 16 | * makefile.w32-in (DOC): Define to point to the generated DOC-X. | ||
| 17 | |||
| 18 | 2005-06-04 Richard M. Stallman <rms@gnu.org> | ||
| 19 | |||
| 20 | * xmenu.c (popup_get_selection): Click not in menu deactivates menu. | ||
| 21 | |||
| 22 | 2005-06-04 Jan Dj,Ad(Brv <jan.h.d@swipnet.se> | ||
| 23 | |||
| 24 | * macmenu.c (cleanup_popup_menu): New function. | ||
| 25 | (Fx_popup_menu): unwind protect cleanup_popup_menu in case | ||
| 26 | mac_menu_show Quit:s. | ||
| 27 | (mac_menu_show): Quit on cancel if not popped up on click (i.e. | ||
| 28 | a dialog). | ||
| 29 | |||
| 30 | 2005-06-04 Kim F. Storm <storm@cua.dk> | ||
| 31 | |||
| 32 | * coding.c (decode_coding_string): Handle CODING_FINISH_INTERRUPT. | ||
| 33 | |||
| 34 | * callproc.c (Fcall_process): Don't use alloca to gradually | ||
| 35 | increase size of buf, as it effectively uses twice the necessary | ||
| 36 | space on the stack. Instead, pre-allocate buf of full size, and | ||
| 37 | gradually increase the read size. | ||
| 38 | |||
| 39 | * bytecode.c (BYTE_CODE_QUIT): Check Vthrow_on_input. | ||
| 40 | |||
| 41 | * eval.c (unbind_to): Preserve value of Vquit_flag. | ||
| 42 | |||
| 43 | * xterm.c (handle_one_xevent): Also ignore mouse motion just | ||
| 44 | before a button release event. | ||
| 45 | |||
| 46 | 2005-06-03 Juanma Barranquero <lekktu@gmail.com> | ||
| 47 | |||
| 48 | * xfaces.c (Finternal_lisp_face_equal_p): Really report | ||
| 49 | on faces in a frame, if the argument FRAME is non-nil. | ||
| 50 | Improve argument/docstring consistency. | ||
| 51 | |||
| 52 | 2005-06-02 Kim F. Storm <storm@cua.dk> | ||
| 53 | |||
| 54 | * xdisp.c (MODE_LINE_NOPROP_LEN): New macro. | ||
| 55 | (x_consider_frame_title, Fformat_mode_line): Save offset into | ||
| 56 | mode_line_noprop_buf rather than pointer, in case buffer is relocated. | ||
| 57 | |||
| 58 | 2005-06-01 Kim F. Storm <storm@cua.dk> | ||
| 59 | |||
| 60 | * fns.c (mapcar1): Maybe exit loop if original sequence was modified. | ||
| 61 | |||
| 62 | 2005-06-01 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> | ||
| 63 | |||
| 64 | * macterm.c (mac_to_x_fontname, mac_do_list_fonts): Set XLFD | ||
| 65 | resolution fields for scalable fonts to 0. | ||
| 66 | |||
| 67 | * xfaces.c (build_scalable_font_name): Round pixel size to the | ||
| 68 | nearest integer. | ||
| 69 | |||
| 70 | 2005-06-01 Kim F. Storm <storm@cua.dk> | ||
| 71 | |||
| 72 | * xdisp.c (display_mode_line): Support nested calls to redisplay | ||
| 73 | and format-mode-line. Set mode_line_target to MODE_LINE_DISPLAY. | ||
| 74 | |||
| 75 | 2005-05-31 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 76 | |||
| 77 | * fileio.c (Finsert_file_contents): | ||
| 78 | * xdisp.c (note_mode_line_or_margin_highlight): Lisp_Object/int mixup. | ||
| 79 | |||
| 80 | 2005-05-31 Kim F. Storm <storm@cua.dk> | ||
| 81 | |||
| 82 | * xdisp.c (mode_line_noprop_buf, mode_line_noprop_buf_end) | ||
| 83 | (mode_line_noprop_ptr): Rename from frame_title_*. | ||
| 84 | (store_mode_line_noprop_char): Rename from store_frame_title_char. | ||
| 85 | (store_mode_line_noprop): Rename from store_frame_title. | ||
| 86 | (mode_line_target): New enum to specify current output target | ||
| 87 | for mode line formatting. | ||
| 88 | (display_mode_element): Test it rather than frame_title_ptr and | ||
| 89 | mode_line_string_list to determine where output should go. | ||
| 90 | (mode_line_proptrans_alist, mode_line_string_alist): Make static. | ||
| 91 | (Vmode_line_unwind_vector): New variable. | ||
| 92 | (format_mode_line_unwind_data, unwind_format_mode_line): | ||
| 93 | New functions for unwind protection in mode line formatting. | ||
| 94 | (x_consider_frame_title): Use them and new local var 'title_start' | ||
| 95 | to support nested calls to format-mode-line and redisplay. Set | ||
| 96 | mode_line_target to MODE_LINE_TITLE. | ||
| 97 | (Fformat_mode_line): Use them and new local var 'string_start' to | ||
| 98 | support nested calls to format-mode-line and redisplay. Set | ||
| 99 | mode_line_target to MODE_LINE_NOPROP or MODE_LINE_STRING. | ||
| 100 | Don't trim trailing dashes. | ||
| 101 | (decode_mode_spec): Don't make infinite number of trailing dashes | ||
| 102 | for MODE_LINE_NOPROP and MODE_LINE_STRING targets. | ||
| 103 | (syms_of_xdisp): Initialize and staticpro mode_line_string_face, | ||
| 104 | mode_line_string_face_prop, and Vmode_line_unwind_vector. | ||
| 105 | (init_xdisp): Initialize mode_line_noprop_ptr to start of _buf. | ||
| 106 | Initialize mode_line_target to MODE_LINE_DISPLAY. | ||
| 107 | |||
| 108 | 2005-05-29 Richard M. Stallman <rms@gnu.org> | ||
| 109 | |||
| 110 | * buffer.c (Fbuffer_local_value): Call indirect_variable. | ||
| 111 | |||
| 112 | 2005-05-28 Masatake YAMATO <jet@gyve.org> | ||
| 113 | |||
| 114 | * xdisp.c (note_mode_line_or_margin_highlight): Change the | ||
| 115 | pointer to a hand cursor when hoovering over a mouse-face. | ||
| 116 | |||
| 117 | 2005-05-27 Kenichi Handa <handa@m17n.org> | ||
| 118 | |||
| 119 | * xterm.c (x_encode_char): Call check_ccl_update in advance. | ||
| 120 | |||
| 121 | * ccl.c: Now an element of Vccl_program_table is a vector of | ||
| 122 | length 4, not 3. | ||
| 123 | (ccl_get_compiled_code): New arg idx. Caller changed. | ||
| 124 | Adjust for the change of Vccl_program_table. | ||
| 125 | (setup_ccl_program): Adjust for the change of Vccl_program_table. | ||
| 126 | (check_ccl_update): New function. | ||
| 127 | (Fregister_ccl_program): Use ASET to set an element of a vector. | ||
| 128 | Adjusted for the change of Vccl_program_table. | ||
| 129 | |||
| 130 | * ccl.h (struct ccl_program): New member idx. | ||
| 131 | (check_ccl_update): Extern it. | ||
| 132 | |||
| 133 | 2005-05-27 Juanma Barranquero <lekktu@gmail.com> | ||
| 134 | |||
| 135 | * image.c (Vimage_library_alist): Move from image.el. | ||
| 136 | (syms_of_image): Defvar it. | ||
| 137 | (lookup_image_type): Use it. | ||
| 138 | |||
| 139 | * buffer.c (Fbuffer_local_value): Make argument name match its use | ||
| 140 | in docstring. | ||
| 141 | |||
| 142 | 2005-05-26 Juanma Barranquero <lekktu@gmail.com> | ||
| 143 | |||
| 144 | * keyboard.c (Frecursive_edit): Fix typo in docstring. | ||
| 145 | (Fposn_at_x_y): Make argument name match its use in docstring. | ||
| 146 | |||
| 147 | 2005-05-26 Lute Kamstra <lute@gnu.org> | ||
| 148 | |||
| 149 | * eval.c (Frun_hooks): Mention run-mode-hooks in docstring. | ||
| 150 | |||
| 1 | 2005-05-24 Masatake YAMATO <jet@gyve.org> | 151 | 2005-05-24 Masatake YAMATO <jet@gyve.org> |
| 2 | 152 | ||
| 3 | * xdisp.c (note_mode_line_or_margin_highlight): Use b and e | 153 | * xdisp.c (note_mode_line_or_margin_highlight): Use b and e |
| @@ -26,9 +176,9 @@ | |||
| 26 | 176 | ||
| 27 | 2005-05-23 Masatake YAMATO <jet@gyve.org> | 177 | 2005-05-23 Masatake YAMATO <jet@gyve.org> |
| 28 | 178 | ||
| 29 | * xdisp.c (note_mode_line_or_margin_highlight): Added code | 179 | * xdisp.c (note_mode_line_or_margin_highlight): Add code |
| 30 | for mouse-face. Change the type of the first argument from `window' | 180 | for mouse-face. Change the type of the first argument from `window' |
| 31 | to `List_Object'. | 181 | to `Lisp_Object'. |
| 32 | (note_mouse_highlight): Call note_mode_line_or_margin_highlight with | 182 | (note_mouse_highlight): Call note_mode_line_or_margin_highlight with |
| 33 | window instead of w. | 183 | window instead of w. |
| 34 | 184 | ||
| @@ -79,8 +229,7 @@ | |||
| 79 | 229 | ||
| 80 | 2005-05-16 Andreas Schwab <schwab@suse.de> | 230 | 2005-05-16 Andreas Schwab <schwab@suse.de> |
| 81 | 231 | ||
| 82 | * unexmacosx.c (unexec_realloc): Move declarations before | 232 | * unexmacosx.c (unexec_realloc): Move declarations before statements. |
| 83 | statements. | ||
| 84 | 233 | ||
| 85 | 2005-05-14 Richard M. Stallman <rms@gnu.org> | 234 | 2005-05-14 Richard M. Stallman <rms@gnu.org> |
| 86 | 235 | ||
| @@ -108,8 +257,8 @@ | |||
| 108 | 257 | ||
| 109 | * emacs.c (main) [MAC_OS8]: Call init_atimer before mac_term_init. | 258 | * emacs.c (main) [MAC_OS8]: Call init_atimer before mac_term_init. |
| 110 | 259 | ||
| 111 | * keyboard.c (readable_events) [USE_TOOLKIT_SCROLL_BARS]: Regard | 260 | * keyboard.c (readable_events) [USE_TOOLKIT_SCROLL_BARS]: |
| 112 | toolkit scroll bar thumb drag events as squeezable and prevent | 261 | Regard toolkit scroll bar thumb drag events as squeezable and prevent |
| 113 | redisplay from being paused by them. | 262 | redisplay from being paused by them. |
| 114 | 263 | ||
| 115 | * mac.c [!MAC_OSX]: Include keyboard.h and syssignal.h. | 264 | * mac.c [!MAC_OSX]: Include keyboard.h and syssignal.h. |
| @@ -117,12 +266,11 @@ | |||
| 117 | [!MAC_OSX] (check_alarm, pause, index): Remove functions. | 266 | [!MAC_OSX] (check_alarm, pause, index): Remove functions. |
| 118 | [!MAC_OSX && __MRC__] (sys_strftime): Likewise. | 267 | [!MAC_OSX && __MRC__] (sys_strftime): Likewise. |
| 119 | [!MAC_OSX] (select): If fd 0 is not set in rfds and some input | 268 | [!MAC_OSX] (select): If fd 0 is not set in rfds and some input |
| 120 | event occurs before timeout, behave as if the function were | 269 | event occurs before timeout, behave as if the function were interrupted. |
| 121 | interrupted. | ||
| 122 | [!MAC_OSX] (sigblock, sigsetmask, alarm): Simulate SIGALRM | 270 | [!MAC_OSX] (sigblock, sigsetmask, alarm): Simulate SIGALRM |
| 123 | handling using Time Manager routines. | 271 | handling using Time Manager routines. |
| 124 | [!MAC_OSX] (mac_atimer_task, mac_atimer_qlink, signal_mask): New | 272 | [!MAC_OSX] (mac_atimer_task, mac_atimer_qlink, signal_mask): |
| 125 | variables. | 273 | New variables. |
| 126 | [!MAC_OSX] (mac_atimer_handler, set_mac_atimer, remove_mac_atimer) | 274 | [!MAC_OSX] (mac_atimer_handler, set_mac_atimer, remove_mac_atimer) |
| 127 | (setitimer): New functions. | 275 | (setitimer): New functions. |
| 128 | 276 | ||
| @@ -136,8 +284,8 @@ | |||
| 136 | (x_scroll_bar_handle_click): Change type of second argument from | 284 | (x_scroll_bar_handle_click): Change type of second argument from |
| 137 | int to ControlPartCode. | 285 | int to ControlPartCode. |
| 138 | (check_alarm): Remove declaration. | 286 | (check_alarm): Remove declaration. |
| 139 | (XTread_Socket) [!TARGET_API_MAC_CARBON]: Don't call it. | 287 | (XTread_socket) [!TARGET_API_MAC_CARBON]: Don't call it. |
| 140 | (XTread_Socket): Use ControlPartCode instead of SInt16. | 288 | (XTread_socket): Use ControlPartCode instead of SInt16. |
| 141 | 289 | ||
| 142 | 2005-05-13 Nozomu Ando <nand@mac.com> | 290 | 2005-05-13 Nozomu Ando <nand@mac.com> |
| 143 | 291 | ||
| @@ -1941,7 +2089,7 @@ | |||
| 1941 | 2005-01-13 Kim F. Storm <storm@cua.dk> | 2089 | 2005-01-13 Kim F. Storm <storm@cua.dk> |
| 1942 | 2090 | ||
| 1943 | * xdisp.c (Fformat_mode_line): Fix last change. Remove NO_PROPS arg | 2091 | * xdisp.c (Fformat_mode_line): Fix last change. Remove NO_PROPS arg |
| 1944 | (specify 0 for FACE instead). Reorder arg list. Doc fix. | 2092 | (specify 0 for FACE instead). Reorder arg list. Doc fix. |
| 1945 | 2093 | ||
| 1946 | 2005-01-12 Richard M. Stallman <rms@gnu.org> | 2094 | 2005-01-12 Richard M. Stallman <rms@gnu.org> |
| 1947 | 2095 | ||
| @@ -2092,7 +2240,7 @@ | |||
| 2092 | fontp->space_width to FONT_WIDTH so they are valid. | 2240 | fontp->space_width to FONT_WIDTH so they are valid. |
| 2093 | 2241 | ||
| 2094 | * w32fns.c (w32_load_system_font): Set FONT_WIDTH to maximum, not | 2242 | * w32fns.c (w32_load_system_font): Set FONT_WIDTH to maximum, not |
| 2095 | average width. Set fontp->average_width and fontp->space_width to | 2243 | average width. Set fontp->average_width and fontp->space_width to |
| 2096 | their appropriate values. | 2244 | their appropriate values. |
| 2097 | 2245 | ||
| 2098 | * w32term.c (x_new_font): Set FRAME_COLUMN_WIDTH to | 2246 | * w32term.c (x_new_font): Set FRAME_COLUMN_WIDTH to |
| @@ -2119,7 +2267,7 @@ | |||
| 2119 | * xdisp.c (setup_for_ellipsis, get_next_display_element): | 2267 | * xdisp.c (setup_for_ellipsis, get_next_display_element): |
| 2120 | Set it->ellipsis_p to 1 or 0. | 2268 | Set it->ellipsis_p to 1 or 0. |
| 2121 | (display_line): Record whether row ends in mid-ellipsis. | 2269 | (display_line): Record whether row ends in mid-ellipsis. |
| 2122 | (set_cursor_from_row): If ends in ellipsis. find start of it. | 2270 | (set_cursor_from_row): If ends in ellipsis, find start of it. |
| 2123 | (cursor_row_p): If PT's at the end of the ellipsis the row | 2271 | (cursor_row_p): If PT's at the end of the ellipsis the row |
| 2124 | ends within, don't display cursor on this row. | 2272 | ends within, don't display cursor on this row. |
| 2125 | 2273 | ||
| @@ -2822,7 +2970,7 @@ | |||
| 2822 | * fringe.c (update_window_fringes): Prefer truncation bitmaps over | 2970 | * fringe.c (update_window_fringes): Prefer truncation bitmaps over |
| 2823 | angle bitmaps at top/bottom line. | 2971 | angle bitmaps at top/bottom line. |
| 2824 | 2972 | ||
| 2825 | * xdisp.c: Undo recent changes for restoring saved_face_id. Instead, | 2973 | * xdisp.c: Undo recent changes for restoring saved_face_id. Instead, |
| 2826 | set it when it->method is set to next_element_from_display_vector. | 2974 | set it when it->method is set to next_element_from_display_vector. |
| 2827 | (setup_for_ellipsis): Add LEN argument. Callers changed. | 2975 | (setup_for_ellipsis): Add LEN argument. Callers changed. |
| 2828 | Set it->saved_face_id. | 2976 | Set it->saved_face_id. |
| @@ -3018,7 +3166,7 @@ | |||
| 3018 | * xfns.c (Fx_file_dialog): Call popup_activated instead of | 3166 | * xfns.c (Fx_file_dialog): Call popup_activated instead of |
| 3019 | x_menu_in_use. Call x_menu_set_in_use in Motif version also. | 3167 | x_menu_in_use. Call x_menu_set_in_use in Motif version also. |
| 3020 | 3168 | ||
| 3021 | * xterm.h: (x_menu_in_use): Remove. | 3169 | * xterm.h (x_menu_in_use): Remove. |
| 3022 | 3170 | ||
| 3023 | 2004-11-16 Richard M. Stallman <rms@gnu.org> | 3171 | 2004-11-16 Richard M. Stallman <rms@gnu.org> |
| 3024 | 3172 | ||
| @@ -3152,7 +3300,7 @@ | |||
| 3152 | (MR_PARTIALLY_VISIBLE_AT_BOTTOM): New helper macros. | 3300 | (MR_PARTIALLY_VISIBLE_AT_BOTTOM): New helper macros. |
| 3153 | (MATRIX_ROW_PARTIALLY_VISIBLE_P): Fix to return false if invisible | 3301 | (MATRIX_ROW_PARTIALLY_VISIBLE_P): Fix to return false if invisible |
| 3154 | part of last line is only extra line spacing (so the text on the | 3302 | part of last line is only extra line spacing (so the text on the |
| 3155 | line is fully visible). Use helper macros. | 3303 | line is fully visible). Use helper macros. |
| 3156 | Add W arg (to use them). All callers changed. | 3304 | Add W arg (to use them). All callers changed. |
| 3157 | (MATRIX_ROW_PARTIALLY_VISIBLE_AT_TOP_P) | 3305 | (MATRIX_ROW_PARTIALLY_VISIBLE_AT_TOP_P) |
| 3158 | (MATRIX_ROW_PARTIALLY_VISIBLE_AT_BOTTOM_P): Use helper macros. | 3306 | (MATRIX_ROW_PARTIALLY_VISIBLE_AT_BOTTOM_P): Use helper macros. |
| @@ -3833,7 +3981,7 @@ | |||
| 3833 | 3981 | ||
| 3834 | * keyboard.c (timer_resume_idle): New function to resume idle | 3982 | * keyboard.c (timer_resume_idle): New function to resume idle |
| 3835 | timer without resetting timers on the idle list. | 3983 | timer without resetting timers on the idle list. |
| 3836 | (read_char): Use timer_resume_idle. Remove local var last_idle_start. | 3984 | (read_char): Use timer_resume_idle. Remove local var last_idle_start. |
| 3837 | (timer_start_idle, timer_stop_idle): Declare static. | 3985 | (timer_start_idle, timer_stop_idle): Declare static. |
| 3838 | (read_key_sequence): Use timer_resume_idle instead of timer_start_idle. | 3986 | (read_key_sequence): Use timer_resume_idle instead of timer_start_idle. |
| 3839 | 3987 | ||
| @@ -4976,7 +5124,7 @@ | |||
| 4976 | 5124 | ||
| 4977 | 2004-06-11 Kenichi Handa <handa@m17n.org> | 5125 | 2004-06-11 Kenichi Handa <handa@m17n.org> |
| 4978 | 5126 | ||
| 4979 | * coding.c (decode_coding_string): Check CODING_FINISH_INTERRUPT. | 5127 | * coding.c (encode_coding_string): Check CODING_FINISH_INTERRUPT. |
| 4980 | 5128 | ||
| 4981 | 2004-06-11 Kim F. Storm <storm@cua.dk> | 5129 | 2004-06-11 Kim F. Storm <storm@cua.dk> |
| 4982 | 5130 | ||
| @@ -5907,7 +6055,7 @@ | |||
| 5907 | elt_prefix combined with Fsingle_key_description. | 6055 | elt_prefix combined with Fsingle_key_description. |
| 5908 | (describe_vector): Declare static. Replace arg `elt_prefix' with | 6056 | (describe_vector): Declare static. Replace arg `elt_prefix' with |
| 5909 | `prefix'. Add KEYMAP_P arg. Add local var `elt_prefix'; use it | 6057 | `prefix'. Add KEYMAP_P arg. Add local var `elt_prefix'; use it |
| 5910 | if !KEYMAP_P. Use Fkey_description with prefix instead of | 6058 | if !KEYMAP_P. Use Fkey_description with prefix instead of |
| 5911 | Fsingle_key_description. | 6059 | Fsingle_key_description. |
| 5912 | 6060 | ||
| 5913 | * keymap.h (Fkey_description): Fix prototype. | 6061 | * keymap.h (Fkey_description): Fix prototype. |
| @@ -6122,7 +6270,7 @@ | |||
| 6122 | (display_mode_line): Set mode_line_p before displaying line. | 6270 | (display_mode_line): Set mode_line_p before displaying line. |
| 6123 | (calc_pixel_width_or_height): Declare extern. Add separate :align-to | 6271 | (calc_pixel_width_or_height): Declare extern. Add separate :align-to |
| 6124 | handling. Remove complex cases for fringes and scroll-bars. | 6272 | handling. Remove complex cases for fringes and scroll-bars. |
| 6125 | Add left, right, and center alignment positions. Add text (area) | 6273 | Add left, right, and center alignment positions. Add text (area) |
| 6126 | width/height. Return width or height for image specs. | 6274 | width/height. Return width or height for image specs. |
| 6127 | (produce_stretch_glyph): Improve handling of :align-to. Is now | 6275 | (produce_stretch_glyph): Improve handling of :align-to. Is now |
| 6128 | relative to left of text area by default, but other base offsets | 6276 | relative to left of text area by default, but other base offsets |
| @@ -10430,7 +10578,7 @@ | |||
| 10430 | * intervals.h (CHECK_TOTAL_LENGTH): New macro. | 10578 | * intervals.h (CHECK_TOTAL_LENGTH): New macro. |
| 10431 | * intervals.c: Add many calls to CHECK_TOTAL_LENGTH. | 10579 | * intervals.c: Add many calls to CHECK_TOTAL_LENGTH. |
| 10432 | 10580 | ||
| 10433 | * alloc.c: (VALIDATE_LISP_STORAGE): Macro deleted. | 10581 | * alloc.c (VALIDATE_LISP_STORAGE): Macro deleted. |
| 10434 | All calls deleted. | 10582 | All calls deleted. |
| 10435 | (lisp_malloc): Do the work here directly. | 10583 | (lisp_malloc): Do the work here directly. |
| 10436 | 10584 | ||
| @@ -10589,7 +10737,7 @@ | |||
| 10589 | (syms_of_w32fns): Don't intern/staticpro removed vars. | 10737 | (syms_of_w32fns): Don't intern/staticpro removed vars. |
| 10590 | 10738 | ||
| 10591 | * w32term.c: Remove unnecessary extern declarations. | 10739 | * w32term.c: Remove unnecessary extern declarations. |
| 10592 | (x_fullscreen_adjust): Remove. Use generic instead. | 10740 | (x_fullscreen_adjust): Remove. Use generic instead. |
| 10593 | (x_redisplay_interface): Add w32_frame_parm_handlers member. | 10741 | (x_redisplay_interface): Add w32_frame_parm_handlers member. |
| 10594 | 10742 | ||
| 10595 | * w32reg.c (x_get_string_resource): Use XrmDatabase. | 10743 | * w32reg.c (x_get_string_resource): Use XrmDatabase. |
| @@ -11815,9 +11963,9 @@ | |||
| 11815 | 2003-01-21 David Ponce <david@dponce.com> | 11963 | 2003-01-21 David Ponce <david@dponce.com> |
| 11816 | 11964 | ||
| 11817 | * w32term.c (w32_encode_char): For DIM=1 charset, set | 11965 | * w32term.c (w32_encode_char): For DIM=1 charset, set |
| 11818 | ccl->reg[2] to -1 before calling ccl_driver. (Sync. with xterm.c | 11966 | ccl->reg[2] to -1 before calling ccl_driver. |
| 11819 | x_encode_char change by Kenichi Handa <handa@m17n.org> on | 11967 | (Sync. with xterm.c x_encode_char change by Kenichi Handa |
| 11820 | 2002-09-30.) | 11968 | <handa@m17n.org> on 2002-09-30.) |
| 11821 | (w32_draw_relief_rect): Declare all args. | 11969 | (w32_draw_relief_rect): Declare all args. |
| 11822 | (w32_define_cursor): New. | 11970 | (w32_define_cursor): New. |
| 11823 | 11971 | ||
| @@ -14500,7 +14648,7 @@ | |||
| 14500 | 14648 | ||
| 14501 | 2002-06-27 Kim F. Storm <storm@cua.dk> | 14649 | 2002-06-27 Kim F. Storm <storm@cua.dk> |
| 14502 | 14650 | ||
| 14503 | * xdisp.c: (mode_line_string_list, mode_line_string_face) | 14651 | * xdisp.c (mode_line_string_list, mode_line_string_face) |
| 14504 | (mode_line_string_face_prop): New variables. | 14652 | (mode_line_string_face_prop): New variables. |
| 14505 | (store_mode_line_string): New function. | 14653 | (store_mode_line_string): New function. |
| 14506 | (display_mode_element): Use store_mode_line_string to | 14654 | (display_mode_element): Use store_mode_line_string to |
| @@ -14543,7 +14691,7 @@ | |||
| 14543 | 14691 | ||
| 14544 | 2002-06-24 Juanma Barranquero <lektu@terra.es> | 14692 | 2002-06-24 Juanma Barranquero <lektu@terra.es> |
| 14545 | 14693 | ||
| 14546 | * w32select.c: Include composite.h | 14694 | * w32select.c: Include composite.h. |
| 14547 | 14695 | ||
| 14548 | * w16select.c: Likewise. | 14696 | * w16select.c: Likewise. |
| 14549 | 14697 | ||
| @@ -15534,7 +15682,7 @@ | |||
| 15534 | 15682 | ||
| 15535 | * config.in: Add HAVE_SHARED_GAME_DIR. | 15683 | * config.in: Add HAVE_SHARED_GAME_DIR. |
| 15536 | 15684 | ||
| 15537 | * callproc.c: (Vgame_score_directory): New variable. | 15685 | * callproc.c (Vgame_score_directory): New variable. |
| 15538 | (syms_of_callproc) <Vgame_score_directory>: DEFVAR_LISP. | 15686 | (syms_of_callproc) <Vgame_score_directory>: DEFVAR_LISP. |
| 15539 | 15687 | ||
| 15540 | 2002-04-10 Richard M. Stallman <rms@gnu.org> | 15688 | 2002-04-10 Richard M. Stallman <rms@gnu.org> |
| @@ -16082,7 +16230,7 @@ | |||
| 16082 | 16230 | ||
| 16083 | * xterm.h (x_session_check_input, x_session_initialize): Declare. | 16231 | * xterm.h (x_session_check_input, x_session_initialize): Declare. |
| 16084 | 16232 | ||
| 16085 | * xterm.c: (XTread_socket): Add call to x_session_check_input and | 16233 | * xterm.c (XTread_socket): Add call to x_session_check_input and |
| 16086 | x_session_have_connection. | 16234 | x_session_have_connection. |
| 16087 | (x_initialize): Add call to x_session_initialize. | 16235 | (x_initialize): Add call to x_session_initialize. |
| 16088 | 16236 | ||
| @@ -16499,10 +16647,10 @@ | |||
| 16499 | 16647 | ||
| 16500 | 2002-02-17 Kim F. Storm <storm@cua.dk> | 16648 | 2002-02-17 Kim F. Storm <storm@cua.dk> |
| 16501 | 16649 | ||
| 16502 | * frame.c: (Vmouse_highlight): New variable. | 16650 | * frame.c (Vmouse_highlight): New variable. |
| 16503 | (syms_of_frame): DEFVAR_LISP it. | 16651 | (syms_of_frame): DEFVAR_LISP it. |
| 16504 | 16652 | ||
| 16505 | * frame.h: (Vmouse_highlight): Declare extern. | 16653 | * frame.h (Vmouse_highlight): Declare extern. |
| 16506 | 16654 | ||
| 16507 | * xterm.h (struct x_display_info): Add mouse_face_hidden. | 16655 | * xterm.h (struct x_display_info): Add mouse_face_hidden. |
| 16508 | 16656 | ||
| @@ -18027,7 +18175,7 @@ | |||
| 18027 | 18175 | ||
| 18028 | 2001-11-16 Eli Zaretskii <eliz@is.elta.co.il> | 18176 | 2001-11-16 Eli Zaretskii <eliz@is.elta.co.il> |
| 18029 | 18177 | ||
| 18030 | * syswait.h: (HAVE_SYS_WAIT_H): Undef for ISC 4.1. Reported by | 18178 | * syswait.h (HAVE_SYS_WAIT_H): Undef for ISC 4.1. Reported by |
| 18031 | Andrew Wiseman <a.wiseman@btclick.com>. | 18179 | Andrew Wiseman <a.wiseman@btclick.com>. |
| 18032 | 18180 | ||
| 18033 | 2001-11-16 Kim F. Storm <storm@cua.dk> | 18181 | 2001-11-16 Kim F. Storm <storm@cua.dk> |
| @@ -18715,7 +18863,7 @@ | |||
| 18715 | 18863 | ||
| 18716 | * xterm.c: Fix typo in a comment. | 18864 | * xterm.c: Fix typo in a comment. |
| 18717 | 18865 | ||
| 18718 | * lisp.h: (gdb_lisp_params): Remove code in #if 0 which is now in | 18866 | * lisp.h (gdb_lisp_params): Remove code in #if 0 which is now in |
| 18719 | emacs.c. | 18867 | emacs.c. |
| 18720 | 18868 | ||
| 18721 | 2001-10-27 Gerd Moellmann <gerd@gnu.org> | 18869 | 2001-10-27 Gerd Moellmann <gerd@gnu.org> |
| @@ -18839,7 +18987,7 @@ | |||
| 18839 | 18987 | ||
| 18840 | 2001-10-24 Pavel Jan,Am(Bk <Pavel@Janik.cz> | 18988 | 2001-10-24 Pavel Jan,Am(Bk <Pavel@Janik.cz> |
| 18841 | 18989 | ||
| 18842 | * xterm.c: (x_insert_glyphs): Remove unused variables `real_end' | 18990 | * xterm.c (x_insert_glyphs): Remove unused variables `real_end' |
| 18843 | and `real_start'. | 18991 | and `real_start'. |
| 18844 | (x_draw_image_foreground): Remove unused variables `mask' and `xgcv'. | 18992 | (x_draw_image_foreground): Remove unused variables `mask' and `xgcv'. |
| 18845 | (glyph_rect): Remove unused variable `area'. | 18993 | (glyph_rect): Remove unused variable `area'. |
| @@ -18871,7 +19019,7 @@ | |||
| 18871 | (HAVE_BOXES): Fix typo in comment. | 19019 | (HAVE_BOXES): Fix typo in comment. |
| 18872 | (push_menu_pane): Fix typo in comment. | 19020 | (push_menu_pane): Fix typo in comment. |
| 18873 | 19021 | ||
| 18874 | * xdisp.c: (display_prop_string_p): Remove unused local declaration | 19022 | * xdisp.c (display_prop_string_p): Remove unused local declaration |
| 18875 | of `Qwhen'. | 19023 | of `Qwhen'. |
| 18876 | (single_display_prop_string_p): Remove unused local declarations | 19024 | (single_display_prop_string_p): Remove unused local declarations |
| 18877 | of `Qwhen' and `Qmargin'. | 19025 | of `Qwhen' and `Qmargin'. |
diff --git a/src/buffer.c b/src/buffer.c index d9769ce10ab..a8daebc3088 100644 --- a/src/buffer.c +++ b/src/buffer.c | |||
| @@ -878,20 +878,23 @@ DEFUN ("buffer-local-value", Fbuffer_local_value, | |||
| 878 | Sbuffer_local_value, 2, 2, 0, | 878 | Sbuffer_local_value, 2, 2, 0, |
| 879 | doc: /* Return the value of VARIABLE in BUFFER. | 879 | doc: /* Return the value of VARIABLE in BUFFER. |
| 880 | If VARIABLE does not have a buffer-local binding in BUFFER, the value | 880 | If VARIABLE does not have a buffer-local binding in BUFFER, the value |
| 881 | is the default binding of variable. */) | 881 | is the default binding of the variable. */) |
| 882 | (symbol, buffer) | 882 | (variable, buffer) |
| 883 | register Lisp_Object symbol; | 883 | register Lisp_Object variable; |
| 884 | register Lisp_Object buffer; | 884 | register Lisp_Object buffer; |
| 885 | { | 885 | { |
| 886 | register struct buffer *buf; | 886 | register struct buffer *buf; |
| 887 | register Lisp_Object result; | 887 | register Lisp_Object result; |
| 888 | 888 | ||
| 889 | CHECK_SYMBOL (symbol); | 889 | CHECK_SYMBOL (variable); |
| 890 | CHECK_BUFFER (buffer); | 890 | CHECK_BUFFER (buffer); |
| 891 | buf = XBUFFER (buffer); | 891 | buf = XBUFFER (buffer); |
| 892 | 892 | ||
| 893 | if (SYMBOLP (variable)) | ||
| 894 | variable = indirect_variable (variable); | ||
| 895 | |||
| 893 | /* Look in local_var_list */ | 896 | /* Look in local_var_list */ |
| 894 | result = Fassoc (symbol, buf->local_var_alist); | 897 | result = Fassoc (variable, buf->local_var_alist); |
| 895 | if (NILP (result)) | 898 | if (NILP (result)) |
| 896 | { | 899 | { |
| 897 | int offset, idx; | 900 | int offset, idx; |
| @@ -906,7 +909,7 @@ is the default binding of variable. */) | |||
| 906 | idx = PER_BUFFER_IDX (offset); | 909 | idx = PER_BUFFER_IDX (offset); |
| 907 | if ((idx == -1 || PER_BUFFER_VALUE_P (buf, idx)) | 910 | if ((idx == -1 || PER_BUFFER_VALUE_P (buf, idx)) |
| 908 | && SYMBOLP (PER_BUFFER_SYMBOL (offset)) | 911 | && SYMBOLP (PER_BUFFER_SYMBOL (offset)) |
| 909 | && EQ (PER_BUFFER_SYMBOL (offset), symbol)) | 912 | && EQ (PER_BUFFER_SYMBOL (offset), variable)) |
| 910 | { | 913 | { |
| 911 | result = PER_BUFFER_VALUE (buf, offset); | 914 | result = PER_BUFFER_VALUE (buf, offset); |
| 912 | found = 1; | 915 | found = 1; |
| @@ -915,7 +918,7 @@ is the default binding of variable. */) | |||
| 915 | } | 918 | } |
| 916 | 919 | ||
| 917 | if (!found) | 920 | if (!found) |
| 918 | result = Fdefault_value (symbol); | 921 | result = Fdefault_value (variable); |
| 919 | } | 922 | } |
| 920 | else | 923 | else |
| 921 | { | 924 | { |
| @@ -923,7 +926,7 @@ is the default binding of variable. */) | |||
| 923 | Lisp_Object current_alist_element; | 926 | Lisp_Object current_alist_element; |
| 924 | 927 | ||
| 925 | /* What binding is loaded right now? */ | 928 | /* What binding is loaded right now? */ |
| 926 | valcontents = SYMBOL_VALUE (symbol); | 929 | valcontents = SYMBOL_VALUE (variable); |
| 927 | current_alist_element | 930 | current_alist_element |
| 928 | = XCAR (XBUFFER_LOCAL_VALUE (valcontents)->cdr); | 931 | = XCAR (XBUFFER_LOCAL_VALUE (valcontents)->cdr); |
| 929 | 932 | ||
| @@ -940,7 +943,7 @@ is the default binding of variable. */) | |||
| 940 | } | 943 | } |
| 941 | 944 | ||
| 942 | if (EQ (result, Qunbound)) | 945 | if (EQ (result, Qunbound)) |
| 943 | return Fsignal (Qvoid_variable, Fcons (symbol, Qnil)); | 946 | return Fsignal (Qvoid_variable, Fcons (variable, Qnil)); |
| 944 | 947 | ||
| 945 | return result; | 948 | return result; |
| 946 | } | 949 | } |
| @@ -5292,19 +5295,19 @@ This is the same as (default-value 'abbrev-mode). */); | |||
| 5292 | doc: /* Default value of `ctl-arrow' for buffers that do not override it. | 5295 | doc: /* Default value of `ctl-arrow' for buffers that do not override it. |
| 5293 | This is the same as (default-value 'ctl-arrow). */); | 5296 | This is the same as (default-value 'ctl-arrow). */); |
| 5294 | 5297 | ||
| 5295 | DEFVAR_LISP_NOPRO ("default-direction-reversed", | 5298 | DEFVAR_LISP_NOPRO ("default-direction-reversed", |
| 5296 | &buffer_defaults.direction_reversed, | 5299 | &buffer_defaults.direction_reversed, |
| 5297 | doc: /* Default value of `direction-reversed' for buffers that do not override it. | 5300 | doc: /* Default value of `direction-reversed' for buffers that do not override it. |
| 5298 | This is the same as (default-value 'direction-reversed). */); | 5301 | This is the same as (default-value 'direction-reversed). */); |
| 5299 | 5302 | ||
| 5300 | DEFVAR_LISP_NOPRO ("default-enable-multibyte-characters", | 5303 | DEFVAR_LISP_NOPRO ("default-enable-multibyte-characters", |
| 5301 | &buffer_defaults.enable_multibyte_characters, | 5304 | &buffer_defaults.enable_multibyte_characters, |
| 5302 | doc: /* *Default value of `enable-multibyte-characters' for buffers not overriding it. | 5305 | doc: /* *Default value of `enable-multibyte-characters' for buffers not overriding it. |
| 5303 | This is the same as (default-value 'enable-multibyte-characters). */); | 5306 | This is the same as (default-value 'enable-multibyte-characters). */); |
| 5304 | 5307 | ||
| 5305 | DEFVAR_LISP_NOPRO ("default-buffer-file-coding-system", | 5308 | DEFVAR_LISP_NOPRO ("default-buffer-file-coding-system", |
| 5306 | &buffer_defaults.buffer_file_coding_system, | 5309 | &buffer_defaults.buffer_file_coding_system, |
| 5307 | doc: /* Default value of `buffer-file-coding-system' for buffers not overriding it. | 5310 | doc: /* Default value of `buffer-file-coding-system' for buffers not overriding it. |
| 5308 | This is the same as (default-value 'buffer-file-coding-system). */); | 5311 | This is the same as (default-value 'buffer-file-coding-system). */); |
| 5309 | 5312 | ||
| 5310 | DEFVAR_LISP_NOPRO ("default-truncate-lines", | 5313 | DEFVAR_LISP_NOPRO ("default-truncate-lines", |
diff --git a/src/bytecode.c b/src/bytecode.c index d130b3b3d42..80fb5e2208e 100644 --- a/src/bytecode.c +++ b/src/bytecode.c | |||
| @@ -384,8 +384,11 @@ unmark_byte_stack () | |||
| 384 | do { \ | 384 | do { \ |
| 385 | if (!NILP (Vquit_flag) && NILP (Vinhibit_quit)) \ | 385 | if (!NILP (Vquit_flag) && NILP (Vinhibit_quit)) \ |
| 386 | { \ | 386 | { \ |
| 387 | Lisp_Object flag = Vquit_flag; \ | ||
| 387 | Vquit_flag = Qnil; \ | 388 | Vquit_flag = Qnil; \ |
| 388 | BEFORE_POTENTIAL_GC (); \ | 389 | BEFORE_POTENTIAL_GC (); \ |
| 390 | if (EQ (Vthrow_on_input, flag)) \ | ||
| 391 | Fthrow (Vthrow_on_input, Qnil); \ | ||
| 389 | Fsignal (Qquit, Qnil); \ | 392 | Fsignal (Qquit, Qnil); \ |
| 390 | AFTER_POTENTIAL_GC (); \ | 393 | AFTER_POTENTIAL_GC (); \ |
| 391 | } \ | 394 | } \ |
diff --git a/src/callproc.c b/src/callproc.c index c410b5a121b..524f6a6a078 100644 --- a/src/callproc.c +++ b/src/callproc.c | |||
| @@ -218,9 +218,10 @@ usage: (call-process PROGRAM &optional INFILE BUFFER DISPLAY &rest ARGS) */) | |||
| 218 | int fd[2]; | 218 | int fd[2]; |
| 219 | int filefd; | 219 | int filefd; |
| 220 | register int pid; | 220 | register int pid; |
| 221 | char buf[16384]; | 221 | #define CALLPROC_BUFFER_SIZE_MIN (16 * 1024) |
| 222 | char *bufptr = buf; | 222 | #define CALLPROC_BUFFER_SIZE_MAX (4 * CALLPROC_BUFFER_SIZE_MIN) |
| 223 | int bufsize = sizeof buf; | 223 | char buf[CALLPROC_BUFFER_SIZE_MAX]; |
| 224 | int bufsize = CALLPROC_BUFFER_SIZE_MIN; | ||
| 224 | int count = SPECPDL_INDEX (); | 225 | int count = SPECPDL_INDEX (); |
| 225 | 226 | ||
| 226 | register const unsigned char **new_argv | 227 | register const unsigned char **new_argv |
| @@ -753,7 +754,7 @@ usage: (call-process PROGRAM &optional INFILE BUFFER DISPLAY &rest ARGS) */) | |||
| 753 | nread = carryover; | 754 | nread = carryover; |
| 754 | while (nread < bufsize - 1024) | 755 | while (nread < bufsize - 1024) |
| 755 | { | 756 | { |
| 756 | int this_read = emacs_read (fd[0], bufptr + nread, | 757 | int this_read = emacs_read (fd[0], buf + nread, |
| 757 | bufsize - nread); | 758 | bufsize - nread); |
| 758 | 759 | ||
| 759 | if (this_read < 0) | 760 | if (this_read < 0) |
| @@ -779,7 +780,7 @@ usage: (call-process PROGRAM &optional INFILE BUFFER DISPLAY &rest ARGS) */) | |||
| 779 | { | 780 | { |
| 780 | if (NILP (current_buffer->enable_multibyte_characters) | 781 | if (NILP (current_buffer->enable_multibyte_characters) |
| 781 | && ! CODING_MAY_REQUIRE_DECODING (&process_coding)) | 782 | && ! CODING_MAY_REQUIRE_DECODING (&process_coding)) |
| 782 | insert_1_both (bufptr, nread, nread, 0, 1, 0); | 783 | insert_1_both (buf, nread, nread, 0, 1, 0); |
| 783 | else | 784 | else |
| 784 | { /* We have to decode the input. */ | 785 | { /* We have to decode the input. */ |
| 785 | Lisp_Object buf; | 786 | Lisp_Object buf; |
| @@ -826,17 +827,13 @@ usage: (call-process PROGRAM &optional INFILE BUFFER DISPLAY &rest ARGS) */) | |||
| 826 | if (process_coding.mode & CODING_MODE_LAST_BLOCK) | 827 | if (process_coding.mode & CODING_MODE_LAST_BLOCK) |
| 827 | break; | 828 | break; |
| 828 | 829 | ||
| 830 | #if (CALLPROC_BUFFER_SIZE_MIN != CALLPROC_BUFFER_SIZE_MAX) | ||
| 829 | /* Make the buffer bigger as we continue to read more data, | 831 | /* Make the buffer bigger as we continue to read more data, |
| 830 | but not past 64k. */ | 832 | but not past CALLPROC_BUFFER_SIZE_MAX. */ |
| 831 | if (bufsize < 64 * 1024 && total_read > 32 * bufsize) | 833 | if (bufsize < CALLPROC_BUFFER_SIZE_MAX && total_read > 32 * bufsize) |
| 832 | { | 834 | if ((bufsize *= 2) > CALLPROC_BUFFER_SIZE_MAX) |
| 833 | char *tempptr; | 835 | bufsize = CALLPROC_BUFFER_SIZE_MAX; |
| 834 | bufsize *= 2; | 836 | #endif |
| 835 | |||
| 836 | tempptr = (char *) alloca (bufsize); | ||
| 837 | bcopy (bufptr, tempptr, bufsize / 2); | ||
| 838 | bufptr = tempptr; | ||
| 839 | } | ||
| 840 | 837 | ||
| 841 | if (display_p) | 838 | if (display_p) |
| 842 | { | 839 | { |
| @@ -55,10 +55,12 @@ Lisp_Object Qcode_conversion_map_id; | |||
| 55 | Lisp_Object Qccl_program_idx; | 55 | Lisp_Object Qccl_program_idx; |
| 56 | 56 | ||
| 57 | /* Table of registered CCL programs. Each element is a vector of | 57 | /* Table of registered CCL programs. Each element is a vector of |
| 58 | NAME, CCL_PROG, and RESOLVEDP where NAME (symbol) is the name of | 58 | NAME, CCL_PROG, RESOLVEDP, and UPDATEDP, where NAME (symbol) is the |
| 59 | the program, CCL_PROG (vector) is the compiled code of the program, | 59 | name of the program, CCL_PROG (vector) is the compiled code of the |
| 60 | RESOLVEDP (t or nil) is the flag to tell if symbols in CCL_PROG is | 60 | program, RESOLVEDP (t or nil) is the flag to tell if symbols in |
| 61 | already resolved to index numbers or not. */ | 61 | CCL_PROG is already resolved to index numbers or not, UPDATEDP (t |
| 62 | or nil) is the flat to tell if the CCL program is updated after it | ||
| 63 | was once used. */ | ||
| 62 | Lisp_Object Vccl_program_table; | 64 | Lisp_Object Vccl_program_table; |
| 63 | 65 | ||
| 64 | /* Vector of registered hash tables for translation. */ | 66 | /* Vector of registered hash tables for translation. */ |
| @@ -1850,14 +1852,16 @@ resolve_symbol_ccl_program (ccl) | |||
| 1850 | symbols, return Qnil. */ | 1852 | symbols, return Qnil. */ |
| 1851 | 1853 | ||
| 1852 | static Lisp_Object | 1854 | static Lisp_Object |
| 1853 | ccl_get_compiled_code (ccl_prog) | 1855 | ccl_get_compiled_code (ccl_prog, idx) |
| 1854 | Lisp_Object ccl_prog; | 1856 | Lisp_Object ccl_prog; |
| 1857 | int *idx; | ||
| 1855 | { | 1858 | { |
| 1856 | Lisp_Object val, slot; | 1859 | Lisp_Object val, slot; |
| 1857 | 1860 | ||
| 1858 | if (VECTORP (ccl_prog)) | 1861 | if (VECTORP (ccl_prog)) |
| 1859 | { | 1862 | { |
| 1860 | val = resolve_symbol_ccl_program (ccl_prog); | 1863 | val = resolve_symbol_ccl_program (ccl_prog); |
| 1864 | *idx = -1; | ||
| 1861 | return (VECTORP (val) ? val : Qnil); | 1865 | return (VECTORP (val) ? val : Qnil); |
| 1862 | } | 1866 | } |
| 1863 | if (!SYMBOLP (ccl_prog)) | 1867 | if (!SYMBOLP (ccl_prog)) |
| @@ -1869,9 +1873,10 @@ ccl_get_compiled_code (ccl_prog) | |||
| 1869 | return Qnil; | 1873 | return Qnil; |
| 1870 | slot = AREF (Vccl_program_table, XINT (val)); | 1874 | slot = AREF (Vccl_program_table, XINT (val)); |
| 1871 | if (! VECTORP (slot) | 1875 | if (! VECTORP (slot) |
| 1872 | || ASIZE (slot) != 3 | 1876 | || ASIZE (slot) != 4 |
| 1873 | || ! VECTORP (AREF (slot, 1))) | 1877 | || ! VECTORP (AREF (slot, 1))) |
| 1874 | return Qnil; | 1878 | return Qnil; |
| 1879 | *idx = XINT (val); | ||
| 1875 | if (NILP (AREF (slot, 2))) | 1880 | if (NILP (AREF (slot, 2))) |
| 1876 | { | 1881 | { |
| 1877 | val = resolve_symbol_ccl_program (AREF (slot, 1)); | 1882 | val = resolve_symbol_ccl_program (AREF (slot, 1)); |
| @@ -1900,7 +1905,7 @@ setup_ccl_program (ccl, ccl_prog) | |||
| 1900 | { | 1905 | { |
| 1901 | struct Lisp_Vector *vp; | 1906 | struct Lisp_Vector *vp; |
| 1902 | 1907 | ||
| 1903 | ccl_prog = ccl_get_compiled_code (ccl_prog); | 1908 | ccl_prog = ccl_get_compiled_code (ccl_prog, &ccl->idx); |
| 1904 | if (! VECTORP (ccl_prog)) | 1909 | if (! VECTORP (ccl_prog)) |
| 1905 | return -1; | 1910 | return -1; |
| 1906 | vp = XVECTOR (ccl_prog); | 1911 | vp = XVECTOR (ccl_prog); |
| @@ -1908,6 +1913,13 @@ setup_ccl_program (ccl, ccl_prog) | |||
| 1908 | ccl->prog = vp->contents; | 1913 | ccl->prog = vp->contents; |
| 1909 | ccl->eof_ic = XINT (vp->contents[CCL_HEADER_EOF]); | 1914 | ccl->eof_ic = XINT (vp->contents[CCL_HEADER_EOF]); |
| 1910 | ccl->buf_magnification = XINT (vp->contents[CCL_HEADER_BUF_MAG]); | 1915 | ccl->buf_magnification = XINT (vp->contents[CCL_HEADER_BUF_MAG]); |
| 1916 | if (ccl->idx >= 0) | ||
| 1917 | { | ||
| 1918 | Lisp_Object slot; | ||
| 1919 | |||
| 1920 | slot = AREF (Vccl_program_table, ccl->idx); | ||
| 1921 | ASET (slot, 3, Qnil); | ||
| 1922 | } | ||
| 1911 | } | 1923 | } |
| 1912 | ccl->ic = CCL_HEADER_MAIN; | 1924 | ccl->ic = CCL_HEADER_MAIN; |
| 1913 | for (i = 0; i < 8; i++) | 1925 | for (i = 0; i < 8; i++) |
| @@ -1921,6 +1933,33 @@ setup_ccl_program (ccl, ccl_prog) | |||
| 1921 | return 0; | 1933 | return 0; |
| 1922 | } | 1934 | } |
| 1923 | 1935 | ||
| 1936 | |||
| 1937 | /* Check if CCL is updated or not. If not, re-setup members of CCL. */ | ||
| 1938 | |||
| 1939 | int | ||
| 1940 | check_ccl_update (ccl) | ||
| 1941 | struct ccl_program *ccl; | ||
| 1942 | { | ||
| 1943 | struct Lisp_Vector *vp; | ||
| 1944 | Lisp_Object slot, ccl_prog; | ||
| 1945 | |||
| 1946 | if (ccl->idx < 0) | ||
| 1947 | return 0; | ||
| 1948 | slot = AREF (Vccl_program_table, ccl->idx); | ||
| 1949 | if (NILP (AREF (slot, 3))) | ||
| 1950 | return 0; | ||
| 1951 | ccl_prog = ccl_get_compiled_code (AREF (slot, 0), &ccl->idx); | ||
| 1952 | if (! VECTORP (ccl_prog)) | ||
| 1953 | return -1; | ||
| 1954 | ccl->size = ASIZE (ccl_prog); | ||
| 1955 | ccl->prog = XVECTOR (ccl_prog)->contents; | ||
| 1956 | ccl->eof_ic = XINT (AREF (ccl_prog, CCL_HEADER_EOF)); | ||
| 1957 | ccl->buf_magnification = XINT (AREF (ccl_prog, CCL_HEADER_BUF_MAG)); | ||
| 1958 | ASET (slot, 3, Qnil); | ||
| 1959 | return 0; | ||
| 1960 | } | ||
| 1961 | |||
| 1962 | |||
| 1924 | DEFUN ("ccl-program-p", Fccl_program_p, Sccl_program_p, 1, 1, 0, | 1963 | DEFUN ("ccl-program-p", Fccl_program_p, Sccl_program_p, 1, 1, 0, |
| 1925 | doc: /* Return t if OBJECT is a CCL program name or a compiled CCL program code. | 1964 | doc: /* Return t if OBJECT is a CCL program name or a compiled CCL program code. |
| 1926 | See the documentation of `define-ccl-program' for the detail of CCL program. */) | 1965 | See the documentation of `define-ccl-program' for the detail of CCL program. */) |
| @@ -2178,8 +2217,9 @@ Return index number of the registered CCL program. */) | |||
| 2178 | if (EQ (name, AREF (slot, 0))) | 2217 | if (EQ (name, AREF (slot, 0))) |
| 2179 | { | 2218 | { |
| 2180 | /* Update this slot. */ | 2219 | /* Update this slot. */ |
| 2181 | AREF (slot, 1) = ccl_prog; | 2220 | ASET (slot, 1, ccl_prog); |
| 2182 | AREF (slot, 2) = resolved; | 2221 | ASET (slot, 2, resolved); |
| 2222 | ASET (slot, 3, Qt); | ||
| 2183 | return make_number (idx); | 2223 | return make_number (idx); |
| 2184 | } | 2224 | } |
| 2185 | } | 2225 | } |
| @@ -2192,19 +2232,19 @@ Return index number of the registered CCL program. */) | |||
| 2192 | 2232 | ||
| 2193 | new_table = Fmake_vector (make_number (len * 2), Qnil); | 2233 | new_table = Fmake_vector (make_number (len * 2), Qnil); |
| 2194 | for (j = 0; j < len; j++) | 2234 | for (j = 0; j < len; j++) |
| 2195 | AREF (new_table, j) | 2235 | ASET (new_table, j, AREF (Vccl_program_table, j)); |
| 2196 | = AREF (Vccl_program_table, j); | ||
| 2197 | Vccl_program_table = new_table; | 2236 | Vccl_program_table = new_table; |
| 2198 | } | 2237 | } |
| 2199 | 2238 | ||
| 2200 | { | 2239 | { |
| 2201 | Lisp_Object elt; | 2240 | Lisp_Object elt; |
| 2202 | 2241 | ||
| 2203 | elt = Fmake_vector (make_number (3), Qnil); | 2242 | elt = Fmake_vector (make_number (4), Qnil); |
| 2204 | AREF (elt, 0) = name; | 2243 | ASET (elt, 0, name); |
| 2205 | AREF (elt, 1) = ccl_prog; | 2244 | ASET (elt, 1, ccl_prog); |
| 2206 | AREF (elt, 2) = resolved; | 2245 | ASET (elt, 2, resolved); |
| 2207 | AREF (Vccl_program_table, idx) = elt; | 2246 | ASET (elt, 3, Qt); |
| 2247 | ASET (Vccl_program_table, idx, elt); | ||
| 2208 | } | 2248 | } |
| 2209 | 2249 | ||
| 2210 | Fput (name, Qccl_program_idx, make_number (idx)); | 2250 | Fput (name, Qccl_program_idx, make_number (idx)); |
| @@ -36,6 +36,10 @@ Boston, MA 02111-1307, USA. */ | |||
| 36 | /* Structure to hold information about running CCL code. Read | 36 | /* Structure to hold information about running CCL code. Read |
| 37 | comments in the file ccl.c for the detail of each field. */ | 37 | comments in the file ccl.c for the detail of each field. */ |
| 38 | struct ccl_program { | 38 | struct ccl_program { |
| 39 | int idx; /* Index number of the CCL program. | ||
| 40 | -1 means that the program was given | ||
| 41 | by a vector, not by a program | ||
| 42 | name. */ | ||
| 39 | int size; /* Size of the compiled code. */ | 43 | int size; /* Size of the compiled code. */ |
| 40 | Lisp_Object *prog; /* Pointer into the compiled code. */ | 44 | Lisp_Object *prog; /* Pointer into the compiled code. */ |
| 41 | int ic; /* Instruction Counter (index for PROG). */ | 45 | int ic; /* Instruction Counter (index for PROG). */ |
| @@ -91,6 +95,9 @@ extern Lisp_Object Vfont_ccl_encoder_alist; | |||
| 91 | execution of ccl program CCL_PROG (symbol or vector). */ | 95 | execution of ccl program CCL_PROG (symbol or vector). */ |
| 92 | extern int setup_ccl_program P_ ((struct ccl_program *, Lisp_Object)); | 96 | extern int setup_ccl_program P_ ((struct ccl_program *, Lisp_Object)); |
| 93 | 97 | ||
| 98 | /* Check if CCL is updated or not. If not, re-setup members of CCL. */ | ||
| 99 | extern int check_ccl_update P_ ((struct ccl_program *)); | ||
| 100 | |||
| 94 | extern void ccl_driver P_ ((struct ccl_program *, int *, int *, int, int, | 101 | extern void ccl_driver P_ ((struct ccl_program *, int *, int *, int, int, |
| 95 | Lisp_Object)); | 102 | Lisp_Object)); |
| 96 | 103 | ||
diff --git a/src/emacs.c b/src/emacs.c index 65a6d549845..013dd1c8918 100644 --- a/src/emacs.c +++ b/src/emacs.c | |||
| @@ -44,6 +44,7 @@ Boston, MA 02111-1307, USA. */ | |||
| 44 | #include <fcntl.h> | 44 | #include <fcntl.h> |
| 45 | #include <windows.h> /* just for w32.h */ | 45 | #include <windows.h> /* just for w32.h */ |
| 46 | #include "w32.h" | 46 | #include "w32.h" |
| 47 | #include "w32heap.h" /* for prototype of sbrk */ | ||
| 47 | #endif | 48 | #endif |
| 48 | 49 | ||
| 49 | #include "lisp.h" | 50 | #include "lisp.h" |
diff --git a/src/eval.c b/src/eval.c index 7f043daa555..0eb1482ee0b 100644 --- a/src/eval.c +++ b/src/eval.c | |||
| @@ -2292,7 +2292,7 @@ static Lisp_Object run_hook_with_args P_ ((int, Lisp_Object *, | |||
| 2292 | enum run_hooks_condition)); | 2292 | enum run_hooks_condition)); |
| 2293 | 2293 | ||
| 2294 | DEFUN ("run-hooks", Frun_hooks, Srun_hooks, 0, MANY, 0, | 2294 | DEFUN ("run-hooks", Frun_hooks, Srun_hooks, 0, MANY, 0, |
| 2295 | doc: /* Run each hook in HOOKS. Major mode functions use this. | 2295 | doc: /* Run each hook in HOOKS. |
| 2296 | Each argument should be a symbol, a hook variable. | 2296 | Each argument should be a symbol, a hook variable. |
| 2297 | These symbols are processed in the order specified. | 2297 | These symbols are processed in the order specified. |
| 2298 | If a hook symbol has a non-nil value, that value may be a function | 2298 | If a hook symbol has a non-nil value, that value may be a function |
| @@ -2300,6 +2300,9 @@ or a list of functions to be called to run the hook. | |||
| 2300 | If the value is a function, it is called with no arguments. | 2300 | If the value is a function, it is called with no arguments. |
| 2301 | If it is a list, the elements are called, in order, with no arguments. | 2301 | If it is a list, the elements are called, in order, with no arguments. |
| 2302 | 2302 | ||
| 2303 | Major modes should not use this function directly to run their mode | ||
| 2304 | hook; they should use `run-mode-hooks' instead. | ||
| 2305 | |||
| 2303 | Do not use `make-local-variable' to make a hook variable buffer-local. | 2306 | Do not use `make-local-variable' to make a hook variable buffer-local. |
| 2304 | Instead, use `add-hook' and specify t for the LOCAL argument. | 2307 | Instead, use `add-hook' and specify t for the LOCAL argument. |
| 2305 | usage: (run-hooks &rest HOOKS) */) | 2308 | usage: (run-hooks &rest HOOKS) */) |
| @@ -3127,10 +3130,10 @@ unbind_to (count, value) | |||
| 3127 | int count; | 3130 | int count; |
| 3128 | Lisp_Object value; | 3131 | Lisp_Object value; |
| 3129 | { | 3132 | { |
| 3130 | int quitf = !NILP (Vquit_flag); | 3133 | Lisp_Object quitf = Vquit_flag; |
| 3131 | struct gcpro gcpro1; | 3134 | struct gcpro gcpro1, gcpro2; |
| 3132 | 3135 | ||
| 3133 | GCPRO1 (value); | 3136 | GCPRO2 (value, quitf); |
| 3134 | Vquit_flag = Qnil; | 3137 | Vquit_flag = Qnil; |
| 3135 | 3138 | ||
| 3136 | while (specpdl_ptr != specpdl + count) | 3139 | while (specpdl_ptr != specpdl + count) |
| @@ -3179,8 +3182,8 @@ unbind_to (count, value) | |||
| 3179 | } | 3182 | } |
| 3180 | } | 3183 | } |
| 3181 | 3184 | ||
| 3182 | if (NILP (Vquit_flag) && quitf) | 3185 | if (NILP (Vquit_flag) && !NILP (quitf)) |
| 3183 | Vquit_flag = Qt; | 3186 | Vquit_flag = quitf; |
| 3184 | 3187 | ||
| 3185 | UNGCPRO; | 3188 | UNGCPRO; |
| 3186 | return value; | 3189 | return value; |
diff --git a/src/fileio.c b/src/fileio.c index 4a22cc0a59e..813c3033d67 100644 --- a/src/fileio.c +++ b/src/fileio.c | |||
| @@ -3750,7 +3750,7 @@ actually used. */) | |||
| 3750 | int set_coding_system = 0; | 3750 | int set_coding_system = 0; |
| 3751 | Lisp_Object coding_system; | 3751 | Lisp_Object coding_system; |
| 3752 | int read_quit = 0; | 3752 | int read_quit = 0; |
| 3753 | int old_Vdeactivate_mark = Vdeactivate_mark; | 3753 | Lisp_Object old_Vdeactivate_mark = Vdeactivate_mark; |
| 3754 | int we_locked_file = 0; | 3754 | int we_locked_file = 0; |
| 3755 | 3755 | ||
| 3756 | if (current_buffer->base_buffer && ! NILP (visit)) | 3756 | if (current_buffer->base_buffer && ! NILP (visit)) |
| @@ -2479,9 +2479,9 @@ mapcar1 (leni, vals, fn, seq) | |||
| 2479 | else /* Must be a list, since Flength did not get an error */ | 2479 | else /* Must be a list, since Flength did not get an error */ |
| 2480 | { | 2480 | { |
| 2481 | tail = seq; | 2481 | tail = seq; |
| 2482 | for (i = 0; i < leni; i++) | 2482 | for (i = 0; i < leni && CONSP (tail); i++) |
| 2483 | { | 2483 | { |
| 2484 | dummy = call1 (fn, Fcar (tail)); | 2484 | dummy = call1 (fn, XCAR (tail)); |
| 2485 | if (vals) | 2485 | if (vals) |
| 2486 | vals[i] = dummy; | 2486 | vals[i] = dummy; |
| 2487 | tail = XCDR (tail); | 2487 | tail = XCDR (tail); |
| @@ -2521,7 +2521,7 @@ SEQUENCE may be a list, a vector, a bool-vector, or a string. */) | |||
| 2521 | mapcar1 (leni, args, function, sequence); | 2521 | mapcar1 (leni, args, function, sequence); |
| 2522 | UNGCPRO; | 2522 | UNGCPRO; |
| 2523 | 2523 | ||
| 2524 | for (i = leni - 1; i >= 0; i--) | 2524 | for (i = leni - 1; i > 0; i--) |
| 2525 | args[i + i] = args[i]; | 2525 | args[i + i] = args[i]; |
| 2526 | 2526 | ||
| 2527 | for (i = 1; i < nargs; i += 2) | 2527 | for (i = 1; i < nargs; i += 2) |
diff --git a/src/image.c b/src/image.c index b61b07876d3..15e835fef3b 100644 --- a/src/image.c +++ b/src/image.c | |||
| @@ -616,6 +616,10 @@ static struct image_type *image_types; | |||
| 616 | 616 | ||
| 617 | Lisp_Object Vimage_types; | 617 | Lisp_Object Vimage_types; |
| 618 | 618 | ||
| 619 | /* An alist of image types and libraries that implement the type. */ | ||
| 620 | |||
| 621 | Lisp_Object Vimage_library_alist; | ||
| 622 | |||
| 619 | /* Cache for delayed-loading image types. */ | 623 | /* Cache for delayed-loading image types. */ |
| 620 | 624 | ||
| 621 | static Lisp_Object Vimage_type_cache; | 625 | static Lisp_Object Vimage_type_cache; |
| @@ -696,7 +700,7 @@ lookup_image_type (symbol) | |||
| 696 | struct image_type *type; | 700 | struct image_type *type; |
| 697 | 701 | ||
| 698 | /* We must initialize the image-type if it hasn't been already. */ | 702 | /* We must initialize the image-type if it hasn't been already. */ |
| 699 | if (NILP (Finit_image_library (symbol, Qnil))) | 703 | if (NILP (Finit_image_library (symbol, Vimage_library_alist))) |
| 700 | return 0; /* unimplemented */ | 704 | return 0; /* unimplemented */ |
| 701 | 705 | ||
| 702 | for (type = image_types; type; type = type->next) | 706 | for (type = image_types; type; type = type->next) |
| @@ -7985,6 +7989,8 @@ of `image-library-alist', which see). */) | |||
| 7985 | void | 7989 | void |
| 7986 | syms_of_image () | 7990 | syms_of_image () |
| 7987 | { | 7991 | { |
| 7992 | extern Lisp_Object Qrisky_local_variable; /* Syms_of_xdisp has already run. */ | ||
| 7993 | |||
| 7988 | /* Must be defined now becase we're going to update it below, while | 7994 | /* Must be defined now becase we're going to update it below, while |
| 7989 | defining the supported image types. */ | 7995 | defining the supported image types. */ |
| 7990 | DEFVAR_LISP ("image-types", &Vimage_types, | 7996 | DEFVAR_LISP ("image-types", &Vimage_types, |
| @@ -7993,6 +7999,20 @@ Each element of the list is a symbol for a image type, like 'jpeg or 'png. | |||
| 7993 | To check whether it is really supported, use `image-type-available-p'. */); | 7999 | To check whether it is really supported, use `image-type-available-p'. */); |
| 7994 | Vimage_types = Qnil; | 8000 | Vimage_types = Qnil; |
| 7995 | 8001 | ||
| 8002 | DEFVAR_LISP ("image-library-alist", &Vimage_library_alist, | ||
| 8003 | doc: /* Alist of image types vs external libraries needed to display them. | ||
| 8004 | |||
| 8005 | Each element is a list (IMAGE-TYPE LIBRARY...), where the car is a symbol | ||
| 8006 | representing a supported image type, and the rest are strings giving | ||
| 8007 | alternate filenames for the corresponding external libraries. | ||
| 8008 | |||
| 8009 | Emacs tries to load the libraries in the order they appear on the | ||
| 8010 | list; if none is loaded, the running session of Emacs won't | ||
| 8011 | support the image type. Types 'pbm and 'xbm don't need to be | ||
| 8012 | listed; they're always supported. */); | ||
| 8013 | Vimage_library_alist = Qnil; | ||
| 8014 | Fput (intern ("image-library-alist"), Qrisky_local_variable, Qt); | ||
| 8015 | |||
| 7996 | Vimage_type_cache = Qnil; | 8016 | Vimage_type_cache = Qnil; |
| 7997 | staticpro (&Vimage_type_cache); | 8017 | staticpro (&Vimage_type_cache); |
| 7998 | 8018 | ||
diff --git a/src/keyboard.c b/src/keyboard.c index 0e7fb1c2719..31c0b5d709c 100644 --- a/src/keyboard.c +++ b/src/keyboard.c | |||
| @@ -1020,7 +1020,7 @@ DEFUN ("recursive-edit", Frecursive_edit, Srecursive_edit, 0, 0, "", | |||
| 1020 | doc: /* Invoke the editor command loop recursively. | 1020 | doc: /* Invoke the editor command loop recursively. |
| 1021 | To get out of the recursive edit, a command can do `(throw 'exit nil)'; | 1021 | To get out of the recursive edit, a command can do `(throw 'exit nil)'; |
| 1022 | that tells this function to return. | 1022 | that tells this function to return. |
| 1023 | Alternately, `(throw 'exit t)' makes this function signal an error. | 1023 | Alternatively, `(throw 'exit t)' makes this function signal an error. |
| 1024 | This function is called by the editor initialization to begin editing. */) | 1024 | This function is called by the editor initialization to begin editing. */) |
| 1025 | () | 1025 | () |
| 1026 | { | 1026 | { |
| @@ -10546,7 +10546,7 @@ The elements of this list correspond to the arguments of | |||
| 10546 | DEFUN ("posn-at-x-y", Fposn_at_x_y, Sposn_at_x_y, 2, 4, 0, | 10546 | DEFUN ("posn-at-x-y", Fposn_at_x_y, Sposn_at_x_y, 2, 4, 0, |
| 10547 | doc: /* Return position information for pixel coordinates X and Y. | 10547 | doc: /* Return position information for pixel coordinates X and Y. |
| 10548 | By default, X and Y are relative to text area of the selected window. | 10548 | By default, X and Y are relative to text area of the selected window. |
| 10549 | Optional third arg FRAME_OR_WINDOW non-nil specifies frame or window. | 10549 | Optional third arg FRAME-OR-WINDOW non-nil specifies frame or window. |
| 10550 | If optional fourth arg WHOLE is non-nil, X is relative to the left | 10550 | If optional fourth arg WHOLE is non-nil, X is relative to the left |
| 10551 | edge of the window. | 10551 | edge of the window. |
| 10552 | 10552 | ||
| @@ -10846,7 +10846,7 @@ syms_of_keyboard () | |||
| 10846 | staticpro (&Qdrag_n_drop); | 10846 | staticpro (&Qdrag_n_drop); |
| 10847 | 10847 | ||
| 10848 | Qsave_session = intern ("save-session"); | 10848 | Qsave_session = intern ("save-session"); |
| 10849 | staticpro(&Qsave_session); | 10849 | staticpro (&Qsave_session); |
| 10850 | 10850 | ||
| 10851 | Qusr1_signal = intern ("usr1-signal"); | 10851 | Qusr1_signal = intern ("usr1-signal"); |
| 10852 | staticpro (&Qusr1_signal); | 10852 | staticpro (&Qusr1_signal); |
diff --git a/src/macmenu.c b/src/macmenu.c index 54393bca594..e97a968d92d 100644 --- a/src/macmenu.c +++ b/src/macmenu.c | |||
| @@ -602,6 +602,13 @@ list_of_items (pane) | |||
| 602 | } | 602 | } |
| 603 | } | 603 | } |
| 604 | 604 | ||
| 605 | static Lisp_Object | ||
| 606 | cleanup_popup_menu (arg) | ||
| 607 | Lisp_Object arg; | ||
| 608 | { | ||
| 609 | discard_menu_items (); | ||
| 610 | } | ||
| 611 | |||
| 605 | DEFUN ("x-popup-menu", Fx_popup_menu, Sx_popup_menu, 2, 2, 0, | 612 | DEFUN ("x-popup-menu", Fx_popup_menu, Sx_popup_menu, 2, 2, 0, |
| 606 | doc: /* Pop up a deck-of-cards menu and return user's selection. | 613 | doc: /* Pop up a deck-of-cards menu and return user's selection. |
| 607 | POSITION is a position specification. This is either a mouse button | 614 | POSITION is a position specification. This is either a mouse button |
| @@ -647,6 +654,8 @@ cached information about equivalent key sequences. */) | |||
| 647 | int keymaps = 0; | 654 | int keymaps = 0; |
| 648 | int for_click = 0; | 655 | int for_click = 0; |
| 649 | struct gcpro gcpro1; | 656 | struct gcpro gcpro1; |
| 657 | int specpdl_count = SPECPDL_INDEX (); | ||
| 658 | |||
| 650 | 659 | ||
| 651 | #ifdef HAVE_MENUS | 660 | #ifdef HAVE_MENUS |
| 652 | if (! NILP (position)) | 661 | if (! NILP (position)) |
| @@ -806,13 +815,13 @@ cached information about equivalent key sequences. */) | |||
| 806 | 815 | ||
| 807 | #ifdef HAVE_MENUS | 816 | #ifdef HAVE_MENUS |
| 808 | /* Display them in a menu. */ | 817 | /* Display them in a menu. */ |
| 818 | record_unwind_protect (cleanup_popup_menu, Qnil); | ||
| 809 | BLOCK_INPUT; | 819 | BLOCK_INPUT; |
| 810 | 820 | ||
| 811 | selection = mac_menu_show (f, xpos, ypos, for_click, | 821 | selection = mac_menu_show (f, xpos, ypos, for_click, |
| 812 | keymaps, title, &error_name); | 822 | keymaps, title, &error_name); |
| 813 | UNBLOCK_INPUT; | 823 | UNBLOCK_INPUT; |
| 814 | 824 | unbind_to (specpdl_count, Qnil); | |
| 815 | discard_menu_items (); | ||
| 816 | 825 | ||
| 817 | UNGCPRO; | 826 | UNGCPRO; |
| 818 | #endif /* HAVE_MENUS */ | 827 | #endif /* HAVE_MENUS */ |
| @@ -1931,6 +1940,9 @@ mac_menu_show (f, x, y, for_click, keymaps, title, error) | |||
| 1931 | } | 1940 | } |
| 1932 | } | 1941 | } |
| 1933 | } | 1942 | } |
| 1943 | else if (!for_click) | ||
| 1944 | /* Make "Cancel" equivalent to C-g. */ | ||
| 1945 | Fsignal (Qquit, Qnil); | ||
| 1934 | 1946 | ||
| 1935 | return Qnil; | 1947 | return Qnil; |
| 1936 | } | 1948 | } |
diff --git a/src/macterm.c b/src/macterm.c index e79803f7c4d..13d8fb455d8 100644 --- a/src/macterm.c +++ b/src/macterm.c | |||
| @@ -6277,9 +6277,10 @@ mac_to_x_fontname (name, size, style, charset) | |||
| 6277 | strcpy(family, name); | 6277 | strcpy(family, name); |
| 6278 | } | 6278 | } |
| 6279 | 6279 | ||
| 6280 | sprintf(xf, "-%s-%s-%s-%c-normal--%d-%d-75-75-m-%d-%s", | 6280 | sprintf(xf, "-%s-%s-%s-%c-normal--%d-%d-%d-%d-m-%d-%s", |
| 6281 | foundry, family, style & bold ? "bold" : "medium", | 6281 | foundry, family, style & bold ? "bold" : "medium", |
| 6282 | style & italic ? 'i' : 'r', size, size * 10, size * 10, charset); | 6282 | style & italic ? 'i' : 'r', size, size * 10, |
| 6283 | size ? 75 : 0, size ? 75 : 0, size * 10, charset); | ||
| 6283 | 6284 | ||
| 6284 | result = (char *) xmalloc (strlen (xf) + 1); | 6285 | result = (char *) xmalloc (strlen (xf) + 1); |
| 6285 | strcpy (result, xf); | 6286 | strcpy (result, xf); |
| @@ -6738,7 +6739,7 @@ mac_do_list_fonts (pattern, maxnames) | |||
| 6738 | break; | 6739 | break; |
| 6739 | } | 6740 | } |
| 6740 | else if (scl_val[XLFD_SCL_PIXEL_SIZE] > 0 | 6741 | else if (scl_val[XLFD_SCL_PIXEL_SIZE] > 0 |
| 6741 | && (ptr = strstr (font_name_table[i], "-0-0-75-75-m-0-"))) | 6742 | && (ptr = strstr (font_name_table[i], "-0-0-0-0-m-0-"))) |
| 6742 | { | 6743 | { |
| 6743 | int former_len = ptr - font_name_table[i]; | 6744 | int former_len = ptr - font_name_table[i]; |
| 6744 | 6745 | ||
| @@ -6748,7 +6749,7 @@ mac_do_list_fonts (pattern, maxnames) | |||
| 6748 | scl_val[XLFD_SCL_PIXEL_SIZE], | 6749 | scl_val[XLFD_SCL_PIXEL_SIZE], |
| 6749 | scl_val[XLFD_SCL_POINT_SIZE], | 6750 | scl_val[XLFD_SCL_POINT_SIZE], |
| 6750 | scl_val[XLFD_SCL_AVGWIDTH], | 6751 | scl_val[XLFD_SCL_AVGWIDTH], |
| 6751 | ptr + sizeof ("-0-0-75-75-m-0-") - 1); | 6752 | ptr + sizeof ("-0-0-0-0-m-0-") - 1); |
| 6752 | fontname = mac_c_string_match (pattern_regex, scaled, | 6753 | fontname = mac_c_string_match (pattern_regex, scaled, |
| 6753 | nonspecial, exact); | 6754 | nonspecial, exact); |
| 6754 | if (!NILP (fontname)) | 6755 | if (!NILP (fontname)) |
diff --git a/src/makefile.w32-in b/src/makefile.w32-in index bd8b3ba1e36..553ebb72abb 100644 --- a/src/makefile.w32-in +++ b/src/makefile.w32-in | |||
| @@ -42,6 +42,8 @@ TOBJ = $(BLD)/firstfile.$(O) | |||
| 42 | TRES = $(BLD)/emacs.res | 42 | TRES = $(BLD)/emacs.res |
| 43 | TLASTLIB = $(BLD)/lastfile.$(A) | 43 | TLASTLIB = $(BLD)/lastfile.$(A) |
| 44 | 44 | ||
| 45 | DOC = $(OBJDIR)/etc/DOC-X | ||
| 46 | |||
| 45 | FULL_LINK_FLAGS = $(LINK_FLAGS) $(TEMACS_EXTRA_LINK) | 47 | FULL_LINK_FLAGS = $(LINK_FLAGS) $(TEMACS_EXTRA_LINK) |
| 46 | 48 | ||
| 47 | # | 49 | # |
diff --git a/src/s/ms-w32.h b/src/s/ms-w32.h index 709b32f1452..998c1f7cf05 100644 --- a/src/s/ms-w32.h +++ b/src/s/ms-w32.h | |||
| @@ -354,7 +354,9 @@ Boston, MA 02111-1307, USA. */ | |||
| 354 | #define fcloseall _fcloseall | 354 | #define fcloseall _fcloseall |
| 355 | #define fdopen _fdopen | 355 | #define fdopen _fdopen |
| 356 | #define fgetchar _fgetchar | 356 | #define fgetchar _fgetchar |
| 357 | #ifndef fileno | ||
| 357 | #define fileno _fileno | 358 | #define fileno _fileno |
| 359 | #endif | ||
| 358 | #define flushall _flushall | 360 | #define flushall _flushall |
| 359 | #define fputchar _fputchar | 361 | #define fputchar _fputchar |
| 360 | #define fsync _commit | 362 | #define fsync _commit |
| @@ -1273,7 +1273,7 @@ get_emacs_configuration_options (void) | |||
| 1273 | void | 1273 | void |
| 1274 | gettimeofday (struct timeval *tv, struct timezone *tz) | 1274 | gettimeofday (struct timeval *tv, struct timezone *tz) |
| 1275 | { | 1275 | { |
| 1276 | struct timeb tb; | 1276 | struct _timeb tb; |
| 1277 | _ftime (&tb); | 1277 | _ftime (&tb); |
| 1278 | 1278 | ||
| 1279 | tv->tv_sec = tb.time; | 1279 | tv->tv_sec = tb.time; |
| @@ -1777,7 +1777,7 @@ open_unc_volume (const char *path) | |||
| 1777 | nr.dwDisplayType = RESOURCEDISPLAYTYPE_SERVER; | 1777 | nr.dwDisplayType = RESOURCEDISPLAYTYPE_SERVER; |
| 1778 | nr.dwUsage = RESOURCEUSAGE_CONTAINER; | 1778 | nr.dwUsage = RESOURCEUSAGE_CONTAINER; |
| 1779 | nr.lpLocalName = NULL; | 1779 | nr.lpLocalName = NULL; |
| 1780 | nr.lpRemoteName = map_w32_filename (path, NULL); | 1780 | nr.lpRemoteName = (LPSTR)map_w32_filename (path, NULL); |
| 1781 | nr.lpComment = NULL; | 1781 | nr.lpComment = NULL; |
| 1782 | nr.lpProvider = NULL; | 1782 | nr.lpProvider = NULL; |
| 1783 | 1783 | ||
| @@ -3207,7 +3207,7 @@ sys_shutdown (int s, int how) | |||
| 3207 | } | 3207 | } |
| 3208 | 3208 | ||
| 3209 | int | 3209 | int |
| 3210 | sys_setsockopt (int s, int level, int optname, const char * optval, int optlen) | 3210 | sys_setsockopt (int s, int level, int optname, const void * optval, int optlen) |
| 3211 | { | 3211 | { |
| 3212 | if (winsock_lib == NULL) | 3212 | if (winsock_lib == NULL) |
| 3213 | { | 3213 | { |
| @@ -3219,7 +3219,7 @@ sys_setsockopt (int s, int level, int optname, const char * optval, int optlen) | |||
| 3219 | if (fd_info[s].flags & FILE_SOCKET) | 3219 | if (fd_info[s].flags & FILE_SOCKET) |
| 3220 | { | 3220 | { |
| 3221 | int rc = pfn_setsockopt (SOCK_HANDLE (s), level, optname, | 3221 | int rc = pfn_setsockopt (SOCK_HANDLE (s), level, optname, |
| 3222 | optval, optlen); | 3222 | (const char *)optval, optlen); |
| 3223 | if (rc == SOCKET_ERROR) | 3223 | if (rc == SOCKET_ERROR) |
| 3224 | set_errno (); | 3224 | set_errno (); |
| 3225 | return rc; | 3225 | return rc; |
diff --git a/src/xdisp.c b/src/xdisp.c index 2781d4a1d2c..6ad0bb9166a 100644 --- a/src/xdisp.c +++ b/src/xdisp.c | |||
| @@ -846,8 +846,8 @@ static struct text_pos run_window_scroll_functions P_ ((Lisp_Object, | |||
| 846 | struct text_pos)); | 846 | struct text_pos)); |
| 847 | static void reconsider_clip_changes P_ ((struct window *, struct buffer *)); | 847 | static void reconsider_clip_changes P_ ((struct window *, struct buffer *)); |
| 848 | static int text_outside_line_unchanged_p P_ ((struct window *, int, int)); | 848 | static int text_outside_line_unchanged_p P_ ((struct window *, int, int)); |
| 849 | static void store_frame_title_char P_ ((char)); | 849 | static void store_mode_line_noprop_char P_ ((char)); |
| 850 | static int store_frame_title P_ ((const unsigned char *, int, int)); | 850 | static int store_mode_line_noprop P_ ((const unsigned char *, int, int)); |
| 851 | static void x_consider_frame_title P_ ((Lisp_Object)); | 851 | static void x_consider_frame_title P_ ((Lisp_Object)); |
| 852 | static void handle_stop P_ ((struct it *)); | 852 | static void handle_stop P_ ((struct it *)); |
| 853 | static int tool_bar_lines_needed P_ ((struct frame *)); | 853 | static int tool_bar_lines_needed P_ ((struct frame *)); |
| @@ -8271,52 +8271,126 @@ echo_area_display (update_frame_p) | |||
| 8271 | 8271 | ||
| 8272 | 8272 | ||
| 8273 | /*********************************************************************** | 8273 | /*********************************************************************** |
| 8274 | Frame Titles | 8274 | Mode Lines and Frame Titles |
| 8275 | ***********************************************************************/ | 8275 | ***********************************************************************/ |
| 8276 | 8276 | ||
| 8277 | /* A buffer for constructing non-propertized mode-line strings and | ||
| 8278 | frame titles in it; allocated from the heap in init_xdisp and | ||
| 8279 | resized as needed in store_mode_line_noprop_char. */ | ||
| 8277 | 8280 | ||
| 8278 | /* The frame title buffering code is also used by Fformat_mode_line. | 8281 | static char *mode_line_noprop_buf; |
| 8279 | So it is not conditioned by HAVE_WINDOW_SYSTEM. */ | ||
| 8280 | 8282 | ||
| 8281 | /* A buffer for constructing frame titles in it; allocated from the | 8283 | /* The buffer's end, and a current output position in it. */ |
| 8282 | heap in init_xdisp and resized as needed in store_frame_title_char. */ | ||
| 8283 | 8284 | ||
| 8284 | static char *frame_title_buf; | 8285 | static char *mode_line_noprop_buf_end; |
| 8286 | static char *mode_line_noprop_ptr; | ||
| 8285 | 8287 | ||
| 8286 | /* The buffer's end, and a current output position in it. */ | 8288 | #define MODE_LINE_NOPROP_LEN(start) \ |
| 8289 | ((mode_line_noprop_ptr - mode_line_noprop_buf) - start) | ||
| 8290 | |||
| 8291 | static enum { | ||
| 8292 | MODE_LINE_DISPLAY = 0, | ||
| 8293 | MODE_LINE_TITLE, | ||
| 8294 | MODE_LINE_NOPROP, | ||
| 8295 | MODE_LINE_STRING | ||
| 8296 | } mode_line_target; | ||
| 8297 | |||
| 8298 | /* Alist that caches the results of :propertize. | ||
| 8299 | Each element is (PROPERTIZED-STRING . PROPERTY-LIST). */ | ||
| 8300 | static Lisp_Object mode_line_proptrans_alist; | ||
| 8301 | |||
| 8302 | /* List of strings making up the mode-line. */ | ||
| 8303 | static Lisp_Object mode_line_string_list; | ||
| 8287 | 8304 | ||
| 8288 | static char *frame_title_buf_end; | 8305 | /* Base face property when building propertized mode line string. */ |
| 8289 | static char *frame_title_ptr; | 8306 | static Lisp_Object mode_line_string_face; |
| 8307 | static Lisp_Object mode_line_string_face_prop; | ||
| 8308 | |||
| 8309 | |||
| 8310 | /* Unwind data for mode line strings */ | ||
| 8290 | 8311 | ||
| 8312 | static Lisp_Object Vmode_line_unwind_vector; | ||
| 8291 | 8313 | ||
| 8292 | /* Store a single character C for the frame title in frame_title_buf. | 8314 | static Lisp_Object |
| 8293 | Re-allocate frame_title_buf if necessary. */ | 8315 | format_mode_line_unwind_data (obuf) |
| 8316 | struct buffer *obuf; | ||
| 8317 | { | ||
| 8318 | int i = 0; | ||
| 8319 | Lisp_Object vector; | ||
| 8320 | |||
| 8321 | /* Reduce consing by keeping one vector in | ||
| 8322 | Vwith_echo_area_save_vector. */ | ||
| 8323 | vector = Vmode_line_unwind_vector; | ||
| 8324 | Vmode_line_unwind_vector = Qnil; | ||
| 8325 | |||
| 8326 | if (NILP (vector)) | ||
| 8327 | vector = Fmake_vector (make_number (7), Qnil); | ||
| 8328 | |||
| 8329 | AREF (vector, 0) = make_number (mode_line_target); | ||
| 8330 | AREF (vector, 1) = make_number (MODE_LINE_NOPROP_LEN (0)); | ||
| 8331 | AREF (vector, 2) = mode_line_string_list; | ||
| 8332 | AREF (vector, 3) = mode_line_proptrans_alist; | ||
| 8333 | AREF (vector, 4) = mode_line_string_face; | ||
| 8334 | AREF (vector, 5) = mode_line_string_face_prop; | ||
| 8335 | |||
| 8336 | if (obuf) | ||
| 8337 | XSETBUFFER (AREF (vector, 6), obuf); | ||
| 8338 | else | ||
| 8339 | AREF (vector, 6) = Qnil; | ||
| 8340 | |||
| 8341 | return vector; | ||
| 8342 | } | ||
| 8343 | |||
| 8344 | static Lisp_Object | ||
| 8345 | unwind_format_mode_line (vector) | ||
| 8346 | Lisp_Object vector; | ||
| 8347 | { | ||
| 8348 | mode_line_target = XINT (AREF (vector, 0)); | ||
| 8349 | mode_line_noprop_ptr = mode_line_noprop_buf + XINT (AREF (vector, 1)); | ||
| 8350 | mode_line_string_list = AREF (vector, 2); | ||
| 8351 | mode_line_proptrans_alist = AREF (vector, 3); | ||
| 8352 | mode_line_string_face = AREF (vector, 4); | ||
| 8353 | mode_line_string_face_prop = AREF (vector, 5); | ||
| 8354 | |||
| 8355 | if (!NILP (AREF (vector, 6))) | ||
| 8356 | { | ||
| 8357 | set_buffer_internal_1 (XBUFFER (AREF (vector, 6))); | ||
| 8358 | AREF (vector, 6) = Qnil; | ||
| 8359 | } | ||
| 8360 | |||
| 8361 | Vmode_line_unwind_vector = vector; | ||
| 8362 | return Qnil; | ||
| 8363 | } | ||
| 8364 | |||
| 8365 | |||
| 8366 | /* Store a single character C for the frame title in mode_line_noprop_buf. | ||
| 8367 | Re-allocate mode_line_noprop_buf if necessary. */ | ||
| 8294 | 8368 | ||
| 8295 | static void | 8369 | static void |
| 8296 | #ifdef PROTOTYPES | 8370 | #ifdef PROTOTYPES |
| 8297 | store_frame_title_char (char c) | 8371 | store_mode_line_noprop_char (char c) |
| 8298 | #else | 8372 | #else |
| 8299 | store_frame_title_char (c) | 8373 | store_mode_line_noprop_char (c) |
| 8300 | char c; | 8374 | char c; |
| 8301 | #endif | 8375 | #endif |
| 8302 | { | 8376 | { |
| 8303 | /* If output position has reached the end of the allocated buffer, | 8377 | /* If output position has reached the end of the allocated buffer, |
| 8304 | double the buffer's size. */ | 8378 | double the buffer's size. */ |
| 8305 | if (frame_title_ptr == frame_title_buf_end) | 8379 | if (mode_line_noprop_ptr == mode_line_noprop_buf_end) |
| 8306 | { | 8380 | { |
| 8307 | int len = frame_title_ptr - frame_title_buf; | 8381 | int len = MODE_LINE_NOPROP_LEN (0); |
| 8308 | int new_size = 2 * len * sizeof *frame_title_buf; | 8382 | int new_size = 2 * len * sizeof *mode_line_noprop_buf; |
| 8309 | frame_title_buf = (char *) xrealloc (frame_title_buf, new_size); | 8383 | mode_line_noprop_buf = (char *) xrealloc (mode_line_noprop_buf, new_size); |
| 8310 | frame_title_buf_end = frame_title_buf + new_size; | 8384 | mode_line_noprop_buf_end = mode_line_noprop_buf + new_size; |
| 8311 | frame_title_ptr = frame_title_buf + len; | 8385 | mode_line_noprop_ptr = mode_line_noprop_buf + len; |
| 8312 | } | 8386 | } |
| 8313 | 8387 | ||
| 8314 | *frame_title_ptr++ = c; | 8388 | *mode_line_noprop_ptr++ = c; |
| 8315 | } | 8389 | } |
| 8316 | 8390 | ||
| 8317 | 8391 | ||
| 8318 | /* Store part of a frame title in frame_title_buf, beginning at | 8392 | /* Store part of a frame title in mode_line_noprop_buf, beginning at |
| 8319 | frame_title_ptr. STR is the string to store. Do not copy | 8393 | mode_line_noprop_ptr. STR is the string to store. Do not copy |
| 8320 | characters that yield more columns than PRECISION; PRECISION <= 0 | 8394 | characters that yield more columns than PRECISION; PRECISION <= 0 |
| 8321 | means copy the whole string. Pad with spaces until FIELD_WIDTH | 8395 | means copy the whole string. Pad with spaces until FIELD_WIDTH |
| 8322 | number of characters have been copied; FIELD_WIDTH <= 0 means don't | 8396 | number of characters have been copied; FIELD_WIDTH <= 0 means don't |
| @@ -8324,7 +8398,7 @@ store_frame_title_char (c) | |||
| 8324 | frame title. */ | 8398 | frame title. */ |
| 8325 | 8399 | ||
| 8326 | static int | 8400 | static int |
| 8327 | store_frame_title (str, field_width, precision) | 8401 | store_mode_line_noprop (str, field_width, precision) |
| 8328 | const unsigned char *str; | 8402 | const unsigned char *str; |
| 8329 | int field_width, precision; | 8403 | int field_width, precision; |
| 8330 | { | 8404 | { |
| @@ -8335,19 +8409,23 @@ store_frame_title (str, field_width, precision) | |||
| 8335 | nbytes = strlen (str); | 8409 | nbytes = strlen (str); |
| 8336 | n += c_string_width (str, nbytes, precision, &dummy, &nbytes); | 8410 | n += c_string_width (str, nbytes, precision, &dummy, &nbytes); |
| 8337 | while (nbytes--) | 8411 | while (nbytes--) |
| 8338 | store_frame_title_char (*str++); | 8412 | store_mode_line_noprop_char (*str++); |
| 8339 | 8413 | ||
| 8340 | /* Fill up with spaces until FIELD_WIDTH reached. */ | 8414 | /* Fill up with spaces until FIELD_WIDTH reached. */ |
| 8341 | while (field_width > 0 | 8415 | while (field_width > 0 |
| 8342 | && n < field_width) | 8416 | && n < field_width) |
| 8343 | { | 8417 | { |
| 8344 | store_frame_title_char (' '); | 8418 | store_mode_line_noprop_char (' '); |
| 8345 | ++n; | 8419 | ++n; |
| 8346 | } | 8420 | } |
| 8347 | 8421 | ||
| 8348 | return n; | 8422 | return n; |
| 8349 | } | 8423 | } |
| 8350 | 8424 | ||
| 8425 | /*********************************************************************** | ||
| 8426 | Frame Titles | ||
| 8427 | ***********************************************************************/ | ||
| 8428 | |||
| 8351 | #ifdef HAVE_WINDOW_SYSTEM | 8429 | #ifdef HAVE_WINDOW_SYSTEM |
| 8352 | 8430 | ||
| 8353 | /* Set the title of FRAME, if it has changed. The title format is | 8431 | /* Set the title of FRAME, if it has changed. The title format is |
| @@ -8367,9 +8445,11 @@ x_consider_frame_title (frame) | |||
| 8367 | /* Do we have more than one visible frame on this X display? */ | 8445 | /* Do we have more than one visible frame on this X display? */ |
| 8368 | Lisp_Object tail; | 8446 | Lisp_Object tail; |
| 8369 | Lisp_Object fmt; | 8447 | Lisp_Object fmt; |
| 8370 | struct buffer *obuf; | 8448 | int title_start; |
| 8449 | char *title; | ||
| 8371 | int len; | 8450 | int len; |
| 8372 | struct it it; | 8451 | struct it it; |
| 8452 | int count = SPECPDL_INDEX (); | ||
| 8373 | 8453 | ||
| 8374 | for (tail = Vframe_list; CONSP (tail); tail = XCDR (tail)) | 8454 | for (tail = Vframe_list; CONSP (tail); tail = XCDR (tail)) |
| 8375 | { | 8455 | { |
| @@ -8388,18 +8468,22 @@ x_consider_frame_title (frame) | |||
| 8388 | multiple_frames = CONSP (tail); | 8468 | multiple_frames = CONSP (tail); |
| 8389 | 8469 | ||
| 8390 | /* Switch to the buffer of selected window of the frame. Set up | 8470 | /* Switch to the buffer of selected window of the frame. Set up |
| 8391 | frame_title_ptr so that display_mode_element will output into it; | 8471 | mode_line_target so that display_mode_element will output into |
| 8392 | then display the title. */ | 8472 | mode_line_noprop_buf; then display the title. */ |
| 8393 | obuf = current_buffer; | 8473 | record_unwind_protect (unwind_format_mode_line, |
| 8474 | format_mode_line_unwind_data (current_buffer)); | ||
| 8475 | |||
| 8394 | set_buffer_internal_1 (XBUFFER (XWINDOW (f->selected_window)->buffer)); | 8476 | set_buffer_internal_1 (XBUFFER (XWINDOW (f->selected_window)->buffer)); |
| 8395 | fmt = FRAME_ICONIFIED_P (f) ? Vicon_title_format : Vframe_title_format; | 8477 | fmt = FRAME_ICONIFIED_P (f) ? Vicon_title_format : Vframe_title_format; |
| 8396 | frame_title_ptr = frame_title_buf; | 8478 | |
| 8479 | mode_line_target = MODE_LINE_TITLE; | ||
| 8480 | title_start = MODE_LINE_NOPROP_LEN (0); | ||
| 8397 | init_iterator (&it, XWINDOW (f->selected_window), -1, -1, | 8481 | init_iterator (&it, XWINDOW (f->selected_window), -1, -1, |
| 8398 | NULL, DEFAULT_FACE_ID); | 8482 | NULL, DEFAULT_FACE_ID); |
| 8399 | display_mode_element (&it, 0, -1, -1, fmt, Qnil, 0); | 8483 | display_mode_element (&it, 0, -1, -1, fmt, Qnil, 0); |
| 8400 | len = frame_title_ptr - frame_title_buf; | 8484 | len = MODE_LINE_NOPROP_LEN (title_start); |
| 8401 | frame_title_ptr = NULL; | 8485 | title = mode_line_noprop_buf + title_start; |
| 8402 | set_buffer_internal_1 (obuf); | 8486 | unbind_to (count, Qnil); |
| 8403 | 8487 | ||
| 8404 | /* Set the title only if it's changed. This avoids consing in | 8488 | /* Set the title only if it's changed. This avoids consing in |
| 8405 | the common case where it hasn't. (If it turns out that we've | 8489 | the common case where it hasn't. (If it turns out that we've |
| @@ -8408,8 +8492,8 @@ x_consider_frame_title (frame) | |||
| 8408 | higher level than this.) */ | 8492 | higher level than this.) */ |
| 8409 | if (! STRINGP (f->name) | 8493 | if (! STRINGP (f->name) |
| 8410 | || SBYTES (f->name) != len | 8494 | || SBYTES (f->name) != len |
| 8411 | || bcmp (frame_title_buf, SDATA (f->name), len) != 0) | 8495 | || bcmp (title, SDATA (f->name), len) != 0) |
| 8412 | x_implicitly_set_name (f, make_string (frame_title_buf, len), Qnil); | 8496 | x_implicitly_set_name (f, make_string (title, len), Qnil); |
| 8413 | } | 8497 | } |
| 8414 | } | 8498 | } |
| 8415 | 8499 | ||
| @@ -15693,6 +15777,7 @@ display_mode_line (w, face_id, format) | |||
| 15693 | { | 15777 | { |
| 15694 | struct it it; | 15778 | struct it it; |
| 15695 | struct face *face; | 15779 | struct face *face; |
| 15780 | int count = SPECPDL_INDEX (); | ||
| 15696 | 15781 | ||
| 15697 | init_iterator (&it, w, -1, -1, NULL, face_id); | 15782 | init_iterator (&it, w, -1, -1, NULL, face_id); |
| 15698 | prepare_desired_row (it.glyph_row); | 15783 | prepare_desired_row (it.glyph_row); |
| @@ -15703,6 +15788,11 @@ display_mode_line (w, face_id, format) | |||
| 15703 | /* Force the mode-line to be displayed in the default face. */ | 15788 | /* Force the mode-line to be displayed in the default face. */ |
| 15704 | it.base_face_id = it.face_id = DEFAULT_FACE_ID; | 15789 | it.base_face_id = it.face_id = DEFAULT_FACE_ID; |
| 15705 | 15790 | ||
| 15791 | record_unwind_protect (unwind_format_mode_line, | ||
| 15792 | format_mode_line_unwind_data (NULL)); | ||
| 15793 | |||
| 15794 | mode_line_target = MODE_LINE_DISPLAY; | ||
| 15795 | |||
| 15706 | /* Temporarily make frame's keyboard the current kboard so that | 15796 | /* Temporarily make frame's keyboard the current kboard so that |
| 15707 | kboard-local variables in the mode_line_format will get the right | 15797 | kboard-local variables in the mode_line_format will get the right |
| 15708 | values. */ | 15798 | values. */ |
| @@ -15710,6 +15800,8 @@ display_mode_line (w, face_id, format) | |||
| 15710 | display_mode_element (&it, 0, 0, 0, format, Qnil, 0); | 15800 | display_mode_element (&it, 0, 0, 0, format, Qnil, 0); |
| 15711 | pop_frame_kboard (); | 15801 | pop_frame_kboard (); |
| 15712 | 15802 | ||
| 15803 | unbind_to (count, Qnil); | ||
| 15804 | |||
| 15713 | /* Fill up with spaces. */ | 15805 | /* Fill up with spaces. */ |
| 15714 | display_string (" ", Qnil, Qnil, 0, 0, &it, 10000, -1, -1, 0); | 15806 | display_string (" ", Qnil, Qnil, 0, 0, &it, 10000, -1, -1, 0); |
| 15715 | 15807 | ||
| @@ -15732,18 +15824,6 @@ display_mode_line (w, face_id, format) | |||
| 15732 | return it.glyph_row->height; | 15824 | return it.glyph_row->height; |
| 15733 | } | 15825 | } |
| 15734 | 15826 | ||
| 15735 | /* Alist that caches the results of :propertize. | ||
| 15736 | Each element is (PROPERTIZED-STRING . PROPERTY-LIST). */ | ||
| 15737 | Lisp_Object mode_line_proptrans_alist; | ||
| 15738 | |||
| 15739 | /* List of strings making up the mode-line. */ | ||
| 15740 | Lisp_Object mode_line_string_list; | ||
| 15741 | |||
| 15742 | /* Base face property when building propertized mode line string. */ | ||
| 15743 | static Lisp_Object mode_line_string_face; | ||
| 15744 | static Lisp_Object mode_line_string_face_prop; | ||
| 15745 | |||
| 15746 | |||
| 15747 | /* Contribute ELT to the mode line for window IT->w. How it | 15827 | /* Contribute ELT to the mode line for window IT->w. How it |
| 15748 | translates into text depends on its data type. | 15828 | translates into text depends on its data type. |
| 15749 | 15829 | ||
| @@ -15764,8 +15844,9 @@ static Lisp_Object mode_line_string_face_prop; | |||
| 15764 | If RISKY is nonzero, remove (disregard) any properties in any string | 15844 | If RISKY is nonzero, remove (disregard) any properties in any string |
| 15765 | we encounter, and ignore :eval and :propertize. | 15845 | we encounter, and ignore :eval and :propertize. |
| 15766 | 15846 | ||
| 15767 | If the global variable `frame_title_ptr' is non-NULL, then the output | 15847 | The global variable `mode_line_target' determines whether the |
| 15768 | is passed to `store_frame_title' instead of `display_string'. */ | 15848 | output is passed to `store_mode_line_noprop', |
| 15849 | `store_mode_line_string', or `display_string'. */ | ||
| 15769 | 15850 | ||
| 15770 | static int | 15851 | static int |
| 15771 | display_mode_element (it, depth, field_width, precision, elt, props, risky) | 15852 | display_mode_element (it, depth, field_width, precision, elt, props, risky) |
| @@ -15854,21 +15935,27 @@ display_mode_element (it, depth, field_width, precision, elt, props, risky) | |||
| 15854 | if (literal) | 15935 | if (literal) |
| 15855 | { | 15936 | { |
| 15856 | prec = precision - n; | 15937 | prec = precision - n; |
| 15857 | if (frame_title_ptr) | 15938 | switch (mode_line_target) |
| 15858 | n += store_frame_title (SDATA (elt), -1, prec); | 15939 | { |
| 15859 | else if (!NILP (mode_line_string_list)) | 15940 | case MODE_LINE_NOPROP: |
| 15860 | n += store_mode_line_string (NULL, elt, 1, 0, prec, Qnil); | 15941 | case MODE_LINE_TITLE: |
| 15861 | else | 15942 | n += store_mode_line_noprop (SDATA (elt), -1, prec); |
| 15862 | n += display_string (NULL, elt, Qnil, 0, 0, it, | 15943 | break; |
| 15863 | 0, prec, 0, STRING_MULTIBYTE (elt)); | 15944 | case MODE_LINE_STRING: |
| 15945 | n += store_mode_line_string (NULL, elt, 1, 0, prec, Qnil); | ||
| 15946 | break; | ||
| 15947 | case MODE_LINE_DISPLAY: | ||
| 15948 | n += display_string (NULL, elt, Qnil, 0, 0, it, | ||
| 15949 | 0, prec, 0, STRING_MULTIBYTE (elt)); | ||
| 15950 | break; | ||
| 15951 | } | ||
| 15864 | 15952 | ||
| 15865 | break; | 15953 | break; |
| 15866 | } | 15954 | } |
| 15867 | 15955 | ||
| 15868 | while ((precision <= 0 || n < precision) | 15956 | while ((precision <= 0 || n < precision) |
| 15869 | && *this | 15957 | && *this |
| 15870 | && (frame_title_ptr | 15958 | && (mode_line_target != MODE_LINE_DISPLAY |
| 15871 | || !NILP (mode_line_string_list) | ||
| 15872 | || it->current_x < it->last_visible_x)) | 15959 | || it->current_x < it->last_visible_x)) |
| 15873 | { | 15960 | { |
| 15874 | const unsigned char *last = this; | 15961 | const unsigned char *last = this; |
| @@ -15889,29 +15976,36 @@ display_mode_element (it, depth, field_width, precision, elt, props, risky) | |||
| 15889 | prec = c_string_width (last, this - last, precision - n, | 15976 | prec = c_string_width (last, this - last, precision - n, |
| 15890 | &nchars, &nbytes); | 15977 | &nchars, &nbytes); |
| 15891 | 15978 | ||
| 15892 | if (frame_title_ptr) | 15979 | switch (mode_line_target) |
| 15893 | n += store_frame_title (last, 0, prec); | ||
| 15894 | else if (!NILP (mode_line_string_list)) | ||
| 15895 | { | 15980 | { |
| 15896 | int bytepos = last - lisp_string; | 15981 | case MODE_LINE_NOPROP: |
| 15897 | int charpos = string_byte_to_char (elt, bytepos); | 15982 | case MODE_LINE_TITLE: |
| 15898 | int endpos = (precision <= 0 | 15983 | n += store_mode_line_noprop (last, 0, prec); |
| 15899 | ? string_byte_to_char (elt, | 15984 | break; |
| 15900 | this - lisp_string) | 15985 | case MODE_LINE_STRING: |
| 15901 | : charpos + nchars); | 15986 | { |
| 15902 | 15987 | int bytepos = last - lisp_string; | |
| 15903 | n += store_mode_line_string (NULL, | 15988 | int charpos = string_byte_to_char (elt, bytepos); |
| 15904 | Fsubstring (elt, make_number (charpos), | 15989 | int endpos = (precision <= 0 |
| 15905 | make_number (endpos)), | 15990 | ? string_byte_to_char (elt, |
| 15906 | 0, 0, 0, Qnil); | 15991 | this - lisp_string) |
| 15907 | } | 15992 | : charpos + nchars); |
| 15908 | else | 15993 | |
| 15909 | { | 15994 | n += store_mode_line_string (NULL, |
| 15910 | int bytepos = last - lisp_string; | 15995 | Fsubstring (elt, make_number (charpos), |
| 15911 | int charpos = string_byte_to_char (elt, bytepos); | 15996 | make_number (endpos)), |
| 15912 | n += display_string (NULL, elt, Qnil, 0, charpos, | 15997 | 0, 0, 0, Qnil); |
| 15913 | it, 0, prec, 0, | 15998 | } |
| 15914 | STRING_MULTIBYTE (elt)); | 15999 | break; |
| 16000 | case MODE_LINE_DISPLAY: | ||
| 16001 | { | ||
| 16002 | int bytepos = last - lisp_string; | ||
| 16003 | int charpos = string_byte_to_char (elt, bytepos); | ||
| 16004 | n += display_string (NULL, elt, Qnil, 0, charpos, | ||
| 16005 | it, 0, prec, 0, | ||
| 16006 | STRING_MULTIBYTE (elt)); | ||
| 16007 | } | ||
| 16008 | break; | ||
| 15915 | } | 16009 | } |
| 15916 | } | 16010 | } |
| 15917 | else /* c == '%' */ | 16011 | else /* c == '%' */ |
| @@ -15949,44 +16043,51 @@ display_mode_element (it, depth, field_width, precision, elt, props, risky) | |||
| 15949 | spec | 16043 | spec |
| 15950 | = decode_mode_spec (it->w, c, field, prec, &multibyte); | 16044 | = decode_mode_spec (it->w, c, field, prec, &multibyte); |
| 15951 | 16045 | ||
| 15952 | if (frame_title_ptr) | 16046 | switch (mode_line_target) |
| 15953 | n += store_frame_title (spec, field, prec); | ||
| 15954 | else if (!NILP (mode_line_string_list)) | ||
| 15955 | { | ||
| 15956 | int len = strlen (spec); | ||
| 15957 | Lisp_Object tem = make_string (spec, len); | ||
| 15958 | props = Ftext_properties_at (make_number (charpos), elt); | ||
| 15959 | /* Should only keep face property in props */ | ||
| 15960 | n += store_mode_line_string (NULL, tem, 0, field, prec, props); | ||
| 15961 | } | ||
| 15962 | else | ||
| 15963 | { | 16047 | { |
| 15964 | int nglyphs_before, nwritten; | 16048 | case MODE_LINE_NOPROP: |
| 15965 | 16049 | case MODE_LINE_TITLE: | |
| 15966 | nglyphs_before = it->glyph_row->used[TEXT_AREA]; | 16050 | n += store_mode_line_noprop (spec, field, prec); |
| 15967 | nwritten = display_string (spec, Qnil, elt, | 16051 | break; |
| 15968 | charpos, 0, it, | 16052 | case MODE_LINE_STRING: |
| 15969 | field, prec, 0, | 16053 | { |
| 15970 | multibyte); | 16054 | int len = strlen (spec); |
| 15971 | 16055 | Lisp_Object tem = make_string (spec, len); | |
| 15972 | /* Assign to the glyphs written above the | 16056 | props = Ftext_properties_at (make_number (charpos), elt); |
| 15973 | string where the `%x' came from, position | 16057 | /* Should only keep face property in props */ |
| 15974 | of the `%'. */ | 16058 | n += store_mode_line_string (NULL, tem, 0, field, prec, props); |
| 15975 | if (nwritten > 0) | 16059 | } |
| 15976 | { | 16060 | break; |
| 15977 | struct glyph *glyph | 16061 | case MODE_LINE_DISPLAY: |
| 15978 | = (it->glyph_row->glyphs[TEXT_AREA] | 16062 | { |
| 15979 | + nglyphs_before); | 16063 | int nglyphs_before, nwritten; |
| 15980 | int i; | 16064 | |
| 15981 | 16065 | nglyphs_before = it->glyph_row->used[TEXT_AREA]; | |
| 15982 | for (i = 0; i < nwritten; ++i) | 16066 | nwritten = display_string (spec, Qnil, elt, |
| 15983 | { | 16067 | charpos, 0, it, |
| 15984 | glyph[i].object = elt; | 16068 | field, prec, 0, |
| 15985 | glyph[i].charpos = charpos; | 16069 | multibyte); |
| 15986 | } | 16070 | |
| 15987 | 16071 | /* Assign to the glyphs written above the | |
| 15988 | n += nwritten; | 16072 | string where the `%x' came from, position |
| 15989 | } | 16073 | of the `%'. */ |
| 16074 | if (nwritten > 0) | ||
| 16075 | { | ||
| 16076 | struct glyph *glyph | ||
| 16077 | = (it->glyph_row->glyphs[TEXT_AREA] | ||
| 16078 | + nglyphs_before); | ||
| 16079 | int i; | ||
| 16080 | |||
| 16081 | for (i = 0; i < nwritten; ++i) | ||
| 16082 | { | ||
| 16083 | glyph[i].object = elt; | ||
| 16084 | glyph[i].charpos = charpos; | ||
| 16085 | } | ||
| 16086 | |||
| 16087 | n += nwritten; | ||
| 16088 | } | ||
| 16089 | } | ||
| 16090 | break; | ||
| 15990 | } | 16091 | } |
| 15991 | } | 16092 | } |
| 15992 | else /* c == 0 */ | 16093 | else /* c == 0 */ |
| @@ -16157,13 +16258,20 @@ display_mode_element (it, depth, field_width, precision, elt, props, risky) | |||
| 16157 | /* Pad to FIELD_WIDTH. */ | 16258 | /* Pad to FIELD_WIDTH. */ |
| 16158 | if (field_width > 0 && n < field_width) | 16259 | if (field_width > 0 && n < field_width) |
| 16159 | { | 16260 | { |
| 16160 | if (frame_title_ptr) | 16261 | switch (mode_line_target) |
| 16161 | n += store_frame_title ("", field_width - n, 0); | 16262 | { |
| 16162 | else if (!NILP (mode_line_string_list)) | 16263 | case MODE_LINE_NOPROP: |
| 16163 | n += store_mode_line_string ("", Qnil, 0, field_width - n, 0, Qnil); | 16264 | case MODE_LINE_TITLE: |
| 16164 | else | 16265 | n += store_mode_line_noprop ("", field_width - n, 0); |
| 16165 | n += display_string ("", Qnil, Qnil, 0, 0, it, field_width - n, | 16266 | break; |
| 16166 | 0, 0, 0); | 16267 | case MODE_LINE_STRING: |
| 16268 | n += store_mode_line_string ("", Qnil, 0, field_width - n, 0, Qnil); | ||
| 16269 | break; | ||
| 16270 | case MODE_LINE_DISPLAY: | ||
| 16271 | n += display_string ("", Qnil, Qnil, 0, 0, it, field_width - n, | ||
| 16272 | 0, 0, 0); | ||
| 16273 | break; | ||
| 16274 | } | ||
| 16167 | } | 16275 | } |
| 16168 | 16276 | ||
| 16169 | return n; | 16277 | return n; |
| @@ -16295,6 +16403,9 @@ are the selected window and the window's buffer). */) | |||
| 16295 | struct buffer *old_buffer = NULL; | 16403 | struct buffer *old_buffer = NULL; |
| 16296 | int face_id = -1; | 16404 | int face_id = -1; |
| 16297 | int no_props = INTEGERP (face); | 16405 | int no_props = INTEGERP (face); |
| 16406 | int count = SPECPDL_INDEX (); | ||
| 16407 | Lisp_Object str; | ||
| 16408 | int string_start = 0; | ||
| 16298 | 16409 | ||
| 16299 | if (NILP (window)) | 16410 | if (NILP (window)) |
| 16300 | window = selected_window; | 16411 | window = selected_window; |
| @@ -16322,64 +16433,50 @@ are the selected window and the window's buffer). */) | |||
| 16322 | face_id = DEFAULT_FACE_ID; | 16433 | face_id = DEFAULT_FACE_ID; |
| 16323 | 16434 | ||
| 16324 | if (XBUFFER (buffer) != current_buffer) | 16435 | if (XBUFFER (buffer) != current_buffer) |
| 16325 | { | 16436 | old_buffer = current_buffer; |
| 16326 | old_buffer = current_buffer; | 16437 | |
| 16327 | set_buffer_internal_1 (XBUFFER (buffer)); | 16438 | record_unwind_protect (unwind_format_mode_line, |
| 16328 | } | 16439 | format_mode_line_unwind_data (old_buffer)); |
| 16440 | |||
| 16441 | if (old_buffer) | ||
| 16442 | set_buffer_internal_1 (XBUFFER (buffer)); | ||
| 16329 | 16443 | ||
| 16330 | init_iterator (&it, w, -1, -1, NULL, face_id); | 16444 | init_iterator (&it, w, -1, -1, NULL, face_id); |
| 16331 | 16445 | ||
| 16332 | if (!no_props) | 16446 | if (no_props) |
| 16333 | { | 16447 | { |
| 16334 | mode_line_string_face = face; | 16448 | mode_line_target = MODE_LINE_NOPROP; |
| 16335 | mode_line_string_face_prop | 16449 | mode_line_string_face_prop = Qnil; |
| 16336 | = (NILP (face) ? Qnil : Fcons (Qface, Fcons (face, Qnil))); | 16450 | mode_line_string_list = Qnil; |
| 16337 | 16451 | string_start = MODE_LINE_NOPROP_LEN (0); | |
| 16338 | /* We need a dummy last element in mode_line_string_list to | ||
| 16339 | indicate we are building the propertized mode-line string. | ||
| 16340 | Using mode_line_string_face_prop here GC protects it. */ | ||
| 16341 | mode_line_string_list | ||
| 16342 | = Fcons (mode_line_string_face_prop, Qnil); | ||
| 16343 | frame_title_ptr = NULL; | ||
| 16344 | } | 16452 | } |
| 16345 | else | 16453 | else |
| 16346 | { | 16454 | { |
| 16347 | mode_line_string_face_prop = Qnil; | 16455 | mode_line_target = MODE_LINE_STRING; |
| 16348 | mode_line_string_list = Qnil; | 16456 | mode_line_string_list = Qnil; |
| 16349 | frame_title_ptr = frame_title_buf; | 16457 | mode_line_string_face = face; |
| 16458 | mode_line_string_face_prop | ||
| 16459 | = (NILP (face) ? Qnil : Fcons (Qface, Fcons (face, Qnil))); | ||
| 16350 | } | 16460 | } |
| 16351 | 16461 | ||
| 16352 | push_frame_kboard (it.f); | 16462 | push_frame_kboard (it.f); |
| 16353 | display_mode_element (&it, 0, 0, 0, format, Qnil, 0); | 16463 | display_mode_element (&it, 0, 0, 0, format, Qnil, 0); |
| 16354 | pop_frame_kboard (); | 16464 | pop_frame_kboard (); |
| 16355 | 16465 | ||
| 16356 | if (old_buffer) | 16466 | if (no_props) |
| 16357 | set_buffer_internal_1 (old_buffer); | ||
| 16358 | |||
| 16359 | if (!no_props) | ||
| 16360 | { | 16467 | { |
| 16361 | Lisp_Object str; | 16468 | len = MODE_LINE_NOPROP_LEN (string_start); |
| 16362 | mode_line_string_list = Fnreverse (mode_line_string_list); | 16469 | str = make_string (mode_line_noprop_buf + string_start, len); |
| 16363 | str = Fmapconcat (intern ("identity"), XCDR (mode_line_string_list), | ||
| 16364 | make_string ("", 0)); | ||
| 16365 | mode_line_string_face_prop = Qnil; | ||
| 16366 | mode_line_string_list = Qnil; | ||
| 16367 | return str; | ||
| 16368 | } | 16470 | } |
| 16369 | 16471 | else | |
| 16370 | len = frame_title_ptr - frame_title_buf; | ||
| 16371 | if (len > 0 && frame_title_ptr[-1] == '-') | ||
| 16372 | { | 16472 | { |
| 16373 | /* Mode lines typically ends with numerous dashes; reduce to two dashes. */ | 16473 | mode_line_string_list = Fnreverse (mode_line_string_list); |
| 16374 | while (frame_title_ptr > frame_title_buf && *--frame_title_ptr == '-') | 16474 | str = Fmapconcat (intern ("identity"), mode_line_string_list, |
| 16375 | ; | 16475 | make_string ("", 0)); |
| 16376 | frame_title_ptr += 3; /* restore last non-dash + two dashes */ | ||
| 16377 | if (len > frame_title_ptr - frame_title_buf) | ||
| 16378 | len = frame_title_ptr - frame_title_buf; | ||
| 16379 | } | 16476 | } |
| 16380 | 16477 | ||
| 16381 | frame_title_ptr = NULL; | 16478 | unbind_to (count, Qnil); |
| 16382 | return make_string (frame_title_buf, len); | 16479 | return str; |
| 16383 | } | 16480 | } |
| 16384 | 16481 | ||
| 16385 | /* Write a null-terminated, right justified decimal representation of | 16482 | /* Write a null-terminated, right justified decimal representation of |
| @@ -16698,7 +16795,8 @@ decode_mode_spec (w, c, field_width, precision, multibyte) | |||
| 16698 | register int i; | 16795 | register int i; |
| 16699 | 16796 | ||
| 16700 | /* Let lots_of_dashes be a string of infinite length. */ | 16797 | /* Let lots_of_dashes be a string of infinite length. */ |
| 16701 | if (!NILP (mode_line_string_list)) | 16798 | if (mode_line_target == MODE_LINE_NOPROP || |
| 16799 | mode_line_target == MODE_LINE_STRING) | ||
| 16702 | return "--"; | 16800 | return "--"; |
| 16703 | if (field_width <= 0 | 16801 | if (field_width <= 0 |
| 16704 | || field_width > sizeof (lots_of_dashes)) | 16802 | || field_width > sizeof (lots_of_dashes)) |
| @@ -21547,7 +21645,7 @@ note_mode_line_or_margin_highlight (window, x, y, area) | |||
| 21547 | tmp_glyph->charpos >= XINT (b); | 21645 | tmp_glyph->charpos >= XINT (b); |
| 21548 | tmp_glyph--, gpos++) | 21646 | tmp_glyph--, gpos++) |
| 21549 | { | 21647 | { |
| 21550 | if (tmp_glyph->object != glyph->object) | 21648 | if (!EQ (tmp_glyph->object, glyph->object)) |
| 21551 | break; | 21649 | break; |
| 21552 | } | 21650 | } |
| 21553 | 21651 | ||
| @@ -21560,7 +21658,7 @@ note_mode_line_or_margin_highlight (window, x, y, area) | |||
| 21560 | tmp_glyph->charpos < XINT (e); | 21658 | tmp_glyph->charpos < XINT (e); |
| 21561 | tmp_glyph++, gseq_length++) | 21659 | tmp_glyph++, gseq_length++) |
| 21562 | { | 21660 | { |
| 21563 | if (tmp_glyph->object != glyph->object) | 21661 | if (!EQ (tmp_glyph->object, glyph->object)) |
| 21564 | break; | 21662 | break; |
| 21565 | } | 21663 | } |
| 21566 | 21664 | ||
| @@ -21590,6 +21688,9 @@ note_mode_line_or_margin_highlight (window, x, y, area) | |||
| 21590 | 0, 0, 0, &ignore, | 21688 | 0, 0, 0, &ignore, |
| 21591 | glyph->face_id, 1); | 21689 | glyph->face_id, 1); |
| 21592 | show_mouse_face (dpyinfo, DRAW_MOUSE_FACE); | 21690 | show_mouse_face (dpyinfo, DRAW_MOUSE_FACE); |
| 21691 | |||
| 21692 | if (NILP (pointer)) | ||
| 21693 | pointer = Qhand; | ||
| 21593 | } | 21694 | } |
| 21594 | } | 21695 | } |
| 21595 | 21696 | ||
| @@ -22833,9 +22934,14 @@ syms_of_xdisp () | |||
| 22833 | 22934 | ||
| 22834 | mode_line_proptrans_alist = Qnil; | 22935 | mode_line_proptrans_alist = Qnil; |
| 22835 | staticpro (&mode_line_proptrans_alist); | 22936 | staticpro (&mode_line_proptrans_alist); |
| 22836 | |||
| 22837 | mode_line_string_list = Qnil; | 22937 | mode_line_string_list = Qnil; |
| 22838 | staticpro (&mode_line_string_list); | 22938 | staticpro (&mode_line_string_list); |
| 22939 | mode_line_string_face = Qnil; | ||
| 22940 | staticpro (&mode_line_string_face); | ||
| 22941 | mode_line_string_face_prop = Qnil; | ||
| 22942 | staticpro (&mode_line_string_face_prop); | ||
| 22943 | Vmode_line_unwind_vector = Qnil; | ||
| 22944 | staticpro (&Vmode_line_unwind_vector); | ||
| 22839 | 22945 | ||
| 22840 | help_echo_string = Qnil; | 22946 | help_echo_string = Qnil; |
| 22841 | staticpro (&help_echo_string); | 22947 | staticpro (&help_echo_string); |
| @@ -23185,9 +23291,10 @@ init_xdisp () | |||
| 23185 | /* Allocate the buffer for frame titles. | 23291 | /* Allocate the buffer for frame titles. |
| 23186 | Also used for `format-mode-line'. */ | 23292 | Also used for `format-mode-line'. */ |
| 23187 | int size = 100; | 23293 | int size = 100; |
| 23188 | frame_title_buf = (char *) xmalloc (size); | 23294 | mode_line_noprop_buf = (char *) xmalloc (size); |
| 23189 | frame_title_buf_end = frame_title_buf + size; | 23295 | mode_line_noprop_buf_end = mode_line_noprop_buf + size; |
| 23190 | frame_title_ptr = NULL; | 23296 | mode_line_noprop_ptr = mode_line_noprop_buf; |
| 23297 | mode_line_target = MODE_LINE_DISPLAY; | ||
| 23191 | } | 23298 | } |
| 23192 | 23299 | ||
| 23193 | help_echo_showing_p = 0; | 23300 | help_echo_showing_p = 0; |
diff --git a/src/xfaces.c b/src/xfaces.c index edff936b08d..97bdd380dee 100644 --- a/src/xfaces.c +++ b/src/xfaces.c | |||
| @@ -5128,8 +5128,8 @@ lface_equal_p (v1, v2) | |||
| 5128 | DEFUN ("internal-lisp-face-equal-p", Finternal_lisp_face_equal_p, | 5128 | DEFUN ("internal-lisp-face-equal-p", Finternal_lisp_face_equal_p, |
| 5129 | Sinternal_lisp_face_equal_p, 2, 3, 0, | 5129 | Sinternal_lisp_face_equal_p, 2, 3, 0, |
| 5130 | doc: /* True if FACE1 and FACE2 are equal. | 5130 | doc: /* True if FACE1 and FACE2 are equal. |
| 5131 | If the optional argument FRAME is given, report on face FACE in that frame. | 5131 | If the optional argument FRAME is given, report on FACE1 and FACE2 in that frame. |
| 5132 | If FRAME is t, report on the defaults for face FACE (for new frames). | 5132 | If FRAME is t, report on the defaults for FACE1 and FACE2 (for new frames). |
| 5133 | If FRAME is omitted or nil, use the selected frame. */) | 5133 | If FRAME is omitted or nil, use the selected frame. */) |
| 5134 | (face1, face2, frame) | 5134 | (face1, face2, frame) |
| 5135 | Lisp_Object face1, face2, frame; | 5135 | Lisp_Object face1, face2, frame; |
| @@ -5137,8 +5137,8 @@ If FRAME is omitted or nil, use the selected frame. */) | |||
| 5137 | int equal_p; | 5137 | int equal_p; |
| 5138 | Lisp_Object lface1, lface2; | 5138 | Lisp_Object lface1, lface2; |
| 5139 | 5139 | ||
| 5140 | lface1 = lface_from_face_name (NULL, face1, 1); | 5140 | lface1 = lface_from_face_name (f, face1, 1); |
| 5141 | lface2 = lface_from_face_name (NULL, face2, 1); | 5141 | lface2 = lface_from_face_name (f, face2, 1); |
| 5142 | equal_p = lface_equal_p (XVECTOR (lface1)->contents, | 5142 | equal_p = lface_equal_p (XVECTOR (lface1)->contents, |
| 5143 | XVECTOR (lface2)->contents); | 5143 | XVECTOR (lface2)->contents); |
| 5144 | return equal_p ? Qt : Qnil; | 5144 | return equal_p ? Qt : Qnil; |
| @@ -6580,12 +6580,12 @@ build_scalable_font_name (f, font, specified_pt) | |||
| 6580 | if (font->numeric[XLFD_RESY] != 0) | 6580 | if (font->numeric[XLFD_RESY] != 0) |
| 6581 | { | 6581 | { |
| 6582 | pt = resy / font->numeric[XLFD_RESY] * specified_pt + 0.5; | 6582 | pt = resy / font->numeric[XLFD_RESY] * specified_pt + 0.5; |
| 6583 | pixel_value = font->numeric[XLFD_RESY] / (PT_PER_INCH * 10.0) * pt; | 6583 | pixel_value = font->numeric[XLFD_RESY] / (PT_PER_INCH * 10.0) * pt + 0.5; |
| 6584 | } | 6584 | } |
| 6585 | else | 6585 | else |
| 6586 | { | 6586 | { |
| 6587 | pt = specified_pt; | 6587 | pt = specified_pt; |
| 6588 | pixel_value = resy / (PT_PER_INCH * 10.0) * pt; | 6588 | pixel_value = resy / (PT_PER_INCH * 10.0) * pt + 0.5; |
| 6589 | } | 6589 | } |
| 6590 | /* We may need a font of the different size. */ | 6590 | /* We may need a font of the different size. */ |
| 6591 | pixel_value *= font->rescale_ratio; | 6591 | pixel_value *= font->rescale_ratio; |
diff --git a/src/xmenu.c b/src/xmenu.c index 9103d32e1c9..826c9330c46 100644 --- a/src/xmenu.c +++ b/src/xmenu.c | |||
| @@ -1235,6 +1235,10 @@ popup_get_selection (initial_event, dpyinfo, id, do_timers) | |||
| 1235 | if (event.type == ButtonRelease | 1235 | if (event.type == ButtonRelease |
| 1236 | && dpyinfo->display == event.xbutton.display) | 1236 | && dpyinfo->display == event.xbutton.display) |
| 1237 | { | 1237 | { |
| 1238 | /* If the click is not on the menu, deactivate the menu. */ | ||
| 1239 | if (x_any_window_to_frame (dpyinfo, event.xexpose.window)) | ||
| 1240 | popup_activated_flag = 0; | ||
| 1241 | |||
| 1238 | dpyinfo->grabbed &= ~(1 << event.xbutton.button); | 1242 | dpyinfo->grabbed &= ~(1 << event.xbutton.button); |
| 1239 | #ifdef USE_MOTIF /* Pretending that the event came from a | 1243 | #ifdef USE_MOTIF /* Pretending that the event came from a |
| 1240 | Btn1Down seems the only way to convince Motif to | 1244 | Btn1Down seems the only way to convince Motif to |
diff --git a/src/xterm.c b/src/xterm.c index 01612d0d0ae..be61c15afdd 100644 --- a/src/xterm.c +++ b/src/xterm.c | |||
| @@ -906,6 +906,7 @@ x_encode_char (c, char2b, font_info, charset, two_byte_p) | |||
| 906 | /* It's a program. */ | 906 | /* It's a program. */ |
| 907 | struct ccl_program *ccl = font_info->font_encoder; | 907 | struct ccl_program *ccl = font_info->font_encoder; |
| 908 | 908 | ||
| 909 | check_ccl_update (ccl); | ||
| 909 | if (CHARSET_DIMENSION (charset) == 1) | 910 | if (CHARSET_DIMENSION (charset) == 1) |
| 910 | { | 911 | { |
| 911 | ccl->reg[0] = CHARSET_ID (charset); | 912 | ccl->reg[0] = CHARSET_ID (charset); |
| @@ -6782,12 +6783,6 @@ handle_one_xevent (dpyinfo, eventp, finish, hold_quit) | |||
| 6782 | { | 6783 | { |
| 6783 | dpyinfo->grabbed |= (1 << event.xbutton.button); | 6784 | dpyinfo->grabbed |= (1 << event.xbutton.button); |
| 6784 | last_mouse_frame = f; | 6785 | last_mouse_frame = f; |
| 6785 | /* Ignore any mouse motion that happened | ||
| 6786 | before this event; any subsequent mouse-movement | ||
| 6787 | Emacs events should reflect only motion after | ||
| 6788 | the ButtonPress. */ | ||
| 6789 | if (f != 0) | ||
| 6790 | f->mouse_moved = 0; | ||
| 6791 | 6786 | ||
| 6792 | if (!tool_bar_p) | 6787 | if (!tool_bar_p) |
| 6793 | last_tool_bar_item = -1; | 6788 | last_tool_bar_item = -1; |
| @@ -6795,6 +6790,12 @@ handle_one_xevent (dpyinfo, eventp, finish, hold_quit) | |||
| 6795 | else | 6790 | else |
| 6796 | dpyinfo->grabbed &= ~(1 << event.xbutton.button); | 6791 | dpyinfo->grabbed &= ~(1 << event.xbutton.button); |
| 6797 | 6792 | ||
| 6793 | /* Ignore any mouse motion that happened before this event; | ||
| 6794 | any subsequent mouse-movement Emacs events should reflect | ||
| 6795 | only motion after the ButtonPress/Release. */ | ||
| 6796 | if (f != 0) | ||
| 6797 | f->mouse_moved = 0; | ||
| 6798 | |||
| 6798 | #if defined (USE_X_TOOLKIT) || defined (USE_GTK) | 6799 | #if defined (USE_X_TOOLKIT) || defined (USE_GTK) |
| 6799 | f = x_menubar_window_to_frame (dpyinfo, event.xbutton.window); | 6800 | f = x_menubar_window_to_frame (dpyinfo, event.xbutton.window); |
| 6800 | /* For a down-event in the menu bar, | 6801 | /* For a down-event in the menu bar, |