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
This commit is contained in:
Miles Bader 2005-06-06 02:39:45 +00:00
commit fdffd34626
296 changed files with 5865 additions and 2954 deletions

View file

@ -1,3 +1,8 @@
2005-06-04 Richard M. Stallman <rms@gnu.org>
* emacs-pretesters: Refer to etc/DEBUG instead of duplicating it.
Other cleanups.
2005-04-19 Lute Kamstra <lute@gnu.org> 2005-04-19 Lute Kamstra <lute@gnu.org>
* make-tarball.txt: Don't commit lisp/loaddefs.el. * make-tarball.txt: Don't commit lisp/loaddefs.el.

View file

@ -30,13 +30,13 @@ noise into long discussions or even arguments, and that can waste a
lot of time. But when you have a reason to ask other pretesters for lot of time. But when you have a reason to ask other pretesters for
help, you can do it that way. help, you can do it that way.
* It is absolutely vital that you tell me about even the smallest * It is absolutely vital that you report even the smallest change or
change or departure from the standard sources and procedure. departure from the standard sources and procedure.
Otherwise, you are not testing the same program that I asked you to Otherwise, you are not testing the same program that we asked you to
test. Testing a different program is usually of no use whatever. It test. Testing a different program is usually of no use whatever. It
can even cause trouble if you fail to tell me that you tested some can even cause trouble, if you fail to tell us that you tested some
other program instead of what I am about to release. I might think other program instead of what we are about to release. We might think
that Emacs works, when in fact it has not even been tried, and might that Emacs works, when in fact it has not even been tried, and might
have a glaring fault. have a glaring fault.
@ -46,8 +46,8 @@ site would use it.
Actually, it does no harm to test Emacs with such customizations *as Actually, it does no harm to test Emacs with such customizations *as
well as* testing it "out of the box". Anything you do that could find well as* testing it "out of the box". Anything you do that could find
a bug is useful, as long as you make sure I know exactly what you did. a bug is useful, as long as you make sure we know exactly what you
The important point is that testing with local changes is no did. The important point is that testing with local changes is no
substitute for testing Emacs exactly as it is distributed. substitute for testing Emacs exactly as it is distributed.
* Even changing the compilation options counts as a change in the * 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
the planned release is that, without changes, it doesn't work on that the planned release is that, without changes, it doesn't work on that
machine. machine.
To make Emacs work on that machine, I would need to install new To make Emacs work on that machine, we would need to install new
configuration files. That is not out of the question, since it is configuration files. That is not out of the question, since it is
safe--it certainly won't break any other machines that already work. safe--it certainly won't break any other machines that already work.
But you will have to rush me the legal papers to give the FSF But you will have to rush in the legal papers to give the FSF
permission to use such a large piece of text. permission to use such a large piece of text.
* Look in the etc/MACHINES file. * Look in the etc/MACHINES file.
@ -92,25 +92,25 @@ recommendations also, for the same reason.
* Send your problem reports to emacs-pretest-bug@gnu.org, not * Send your problem reports to emacs-pretest-bug@gnu.org, not
bug-gnu-emacs. bug-gnu-emacs.
Sometimes I won't know what to do about a system-dependent issue, and Sometimes we won't know what to do about a system-dependent issue, and
I may need people to tell me what happens if you try a certain thing we may need people to say what happens if you try a certain thing on a
on a certain system. When this happens, I'll send out a query. certain system. When this happens, we'll send out a query.
* Don't delay sending information. * Don't delay sending information.
When you test on a system and encounter no problems, please tell me When you test on a system and encounter no problems, please report it
about it right away. That way, I will know that someone has tested right away. That way, we will know that someone has tested Emacs on
Emacs on that kind of system. that kind of system.
Please don't wait for several days "to see if it really works before Please don't wait for several days "to see if it really works before
you say anything." Tell me right away that Emacs seems basically to you say anything." Tell us right away that Emacs seems basically to
work; then, if you notice a problem a few days later, tell me work; then, if you notice a problem a few days later, tell us
immediately about that when you see it. immediately about that when you see it.
It is okay if you double check things before reporting a problem, such It is okay if you double check things before reporting a problem, such
as to see if you can easily fix it. But don't wait very long. A good as to see if you can easily fix it. But don't wait very long. A good
rule to use in pretesting is always to tell me about every problem on rule to use in pretesting is always to report every problem on the
the same day you encounter it, even if that means you can't find a same day you encounter it, even if that means you can't find a
solution before you report the problem. solution before you report the problem.
I'd much rather hear about a problem today and a solution tomorrow 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
the bug to find the other message. This may be difficult, it is the bug to find the other message. This may be difficult, it is
probably time-consuming. probably time-consuming.
To help me save time, simply copy the relevant parts of any previous To help save our time, simply copy the relevant parts of any previous
messages into your own bug report. messages into your own bug report.
In particular, if I ask you for more information because a bug report In particular, if we ask you for more information because a bug report
was incomplete, it is best to send me the *entire* collection of was incomplete, it is best to send me the *entire* collection of
relevant information, all together. If you send just the additional relevant information, all together. If you send just the additional
information, that makes me do extra work. There is even a risk that information, that makes extra work for us. There is even a risk that
I won't remember what question you are sending me the answer to. we won't remember what question you are sending the answer to.
* When you encounter a bug that manifests itself as a Lisp error, * When you encounter a bug that manifests itself as a Lisp error,
try setting debug-on-error to t and making the bug happen again. try setting debug-on-error to t and making the bug happen again.
Then you will get a Lisp backtrace. Including that in your bug report Then you will get a Lisp backtrace. Including that in your bug report
is very useful. is very useful.
* For advice on debugging, see etc/DEBUG.
* Debugging optimized code is possible, if you compile with GCC, but * Debugging optimized code is possible, if you compile with GCC, but
in some cases the optimized code can be confusing. If you are not in some cases the optimized code can be confusing. If you are not
accustomed to that, recompile Emacs without -O. One way to do this is 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
make clean make clean
make CFLAGS=-g make CFLAGS=-g
* If you use X windows, it is a good idea to run Emacs under GDB (or
some other suitable debugger) *all the time*, at least while
pretesting.
Then, when Emacs crashes, you will be able to debug the live process,
not just a core dump. The `pr' command defined in src/.gdbinit is very
useful in this case for examining Lisp_Object values as they would
appear in Lisp.
If you can't use `pr' because Emacs has got a fault already, or
because you have only a core dump, you can use `xtype' to look at the
type of a value, and then choose one of the other commands `xsymbol',
`xstring', `xcons', `xvector' and so on to examine the contents.
I myself *always* run Emacs under GDB so that I can debug conveniently
if the occasion arises.
* To get Lisp-level backtrace information within GDB,
look for stack frames that call Ffuncall. Select them one by one in GDB
and type this:
p *args
pr
This will print the name of the Lisp function called by that level
of function calling.
By printing the remaining elements of args, you can see the argument
values. Here's how to print the first argument:
p args[1]
pr
If you do not have a live process, you can use xtype and the other
x... commands such as xsymbol to get such information, albeit less
conveniently.
* Even with a live process, these x... commands are useful for
examining the fields in a buffer, window, process, frame or marker.
Here's an example using concepts explained in the node "Value History"
of the GDB manual to print the variable frame from this line in
xmenu.c:
buf.frame_or_window = Fcons (frame, prefix);
First, use these commands:
cd src
gdb emacs
b xmenu.c:1209
r -q
Then type C-x 5 2 to create a new frame, and it hits the breakpoint:
(gdb) p frame
$1 = 1077872640
(gdb) xtype
Lisp_Vectorlike
PVEC_FRAME
(gdb) xframe
$2 = (struct frame *) 0x3f0800
(gdb) p *$
$3 = {
size = 536871989,
next = 0x366240,
name = 809661752,
[...]
}
(gdb) p $3->name
$4 = 809661752
Now we can use `pr' to print the name of the frame:
(gdb) pr
"emacs@steenrod.math.nwu.edu"
* The Emacs C code heavily uses macros defined in lisp.h. So suppose
we want the address of the l-value expression near the bottom of
`kbd_buffer_store_event' from keyboard.c:
XVECTOR (kbd_buffer_frame_or_window)->contents[kbd_store_ptr
- kbd_buffer]
= event->frame_or_window);
XVECTOR is a macro, and therefore GDB does not know about it.
GDB cannot evaluate p XVECTOR (kbd_buffer_frame_or_window).
However, you can use the xvector command in GDB to get the same
result. Here is how:
(gdb) p kbd_buffer_frame_or_window
$1 = 1078005760
(gdb) xvector
$2 = (struct Lisp_Vector *) 0x411000
0
(gdb) p $->contents[kbd_store_ptr - kbd_buffer]
$3 = 1077872640
(gdb) p &$
$4 = (int *) 0x411008
* Here's a related example of macros and the GDB `define' command.
There are many Lisp vectors such as `recent_keys', which contains the
last 100 keystrokes. We can print this Lisp vector
p recent_keys
pr
But this may be inconvenient, since `recent_keys' is much more verbose
than `C-h l'. We might want to print only the last 10 elements of
this vector. `recent_keys' is updated in keyboard.c by the command
XVECTOR (recent_keys)->contents[recent_keys_index] = c;
So we define a GDB command `xvector-elts', so the last 10 keystrokes
are printed by
xvector-elts recent_keys recent_keys_index 10
where you can define xvector-elts as follows:
define xvector-elts
set $i = 0
p $arg0
xvector
set $foo = $
while $i < $arg2
p $foo->contents[$arg1-($i++)]
pr
end
document xvector-elts
Prints a range of elements of a Lisp vector.
xvector-elts v n i
prints `i' elements of the vector `v' ending at the index `n'.
end
* To debug what happens while preloading and dumping Emacs,
do `gdb temacs' and start it with `r -batch -l loadup dump'.
If temacs actually succeeds when running under GDB in this way, do not
try to run the dumped Emacs, because it was dumped with the GDB
breakpoints in it.
* If you encounter X protocol errors, try evaluating (x-synchronize t).
That puts Emacs into synchronous mode, where each Xlib call checks for
errors before it returns. This mode is much slower, but when you get
an error, you will see exactly which call really caused the error.
* If the symptom of the bug is that Emacs fails to respond, don't
assume Emacs is `hung'--it may instead be in an infinite loop. To
find out which, make the problem happen under GDB and stop Emacs once
it is not responding. (If Emacs is using X Windows directly, you can
stop Emacs by typing C-z at the GDB job.) Then try stepping with
`step'. If Emacs is hung, the `step' command won't return. If it is
looping, `step' will return.
If this shows Emacs is hung in a system call, stop it again and
examine the arguments of the call. In your bug report, state exactly
where in the source the system call is, and what the arguments are.
If Emacs is in an infinite loop, please determine where the loop
starts and ends. The easiest way to do this is to use the GDB command
`finish'. Each time you use it, Emacs resumes execution until it
exits one stack frame. Keep typing `finish' until it doesn't
return--that means the infinite loop is in the stack frame which you
just tried to finish.
Stop Emacs again, and use `finish' repeatedly again until you get back
to that frame. Then use `next' to step through that frame. By
stepping, you will see where the loop starts and ends. Also please
examine the data being used in the loop and try to determine why the
loop does not exit when it should. Include all of this information in
your bug report.
* If certain operations in Emacs are slower than they used to be, here
is some advice for how to find out why.
Stop Emacs repeatedly during the slow operation, and make a backtrace
each time. Compare the backtraces looking for a pattern--a specific
function that shows up more often than you'd expect.
If you don't see a pattern in the C backtraces, get some Lisp
backtrace information by looking at Ffuncall frames (see above), and
again look for a pattern.
When using X, you can stop Emacs at any time by typing C-z at GDB.
When not using X, you can do this with C-g.
* Configure tries to figure out what kind of system you have by * Configure tries to figure out what kind of system you have by
compiling and linking programs which calls various functions and looks compiling and linking programs which calls various functions and looks
at whether that succeeds. The file config.log contains any messages at whether that succeeds. The file config.log contains any messages
@ -344,6 +159,9 @@ or more simply,
rm config.cache rm config.cache
./configure ./configure
* Don't try changing Emacs *in any way* during pretest unless it fails
to work unchanged.
* Always be precise when talking about changes you have made. Show * Always be precise when talking about changes you have made. Show
things rather than describing them. Use exact filenames (relative to things rather than describing them. Use exact filenames (relative to
the main directory of the distribution), not partial ones. For 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
diff. diff.
* Always use `diff -c' to make diffs. If you don't include context, it * Always use `diff -c' to make diffs. If you don't include context, it
may be hard for me to figure out where you propose to make the may be hard for us to figure out where you propose to make the
changes. So I might have to ignore your patch. changes. So we might ignore your patch.
* When you write a fix, keep in mind that I can't install a change * When you write a fix, keep in mind that we can't install a change
that *might* break other systems without the risk that it will fail to that *might* break other systems without the risk that it will fail to
work and therefore require an additional cycle of pretesting. work and therefore require an additional cycle of pretesting.
People often suggest fixing a problem by changing config.h or People often suggest fixing a problem by changing config.h or
src/ymakefile or even src/Makefile to do something special that a src/ymakefile or even src/Makefile to do something special that a
particular system needs. Sometimes it is totally obvious that such particular system needs. Sometimes it is totally obvious that such
changes would break Emacs for almost all users. I can't possibly make changes would break Emacs for almost all users. We can't possibly
a change like that. All I can do is send it back to you and ask you make a change like that. All we can do is ask you to find a fix that
to find a fix that is safe to install. is safe to install.
Sometimes people send fixes that *might* be an improvement in Sometimes people send fixes that *might* be an improvement in
general--but it is hard to be sure of this. I can install such general--but it is hard to be sure of this. I can install such
changes some of the time, but not during pretest, when I am trying to changes some of the time, but not during pretest, when I am trying to
get a new version to work reliably as quickly as possible. get a new version to work reliably as quickly as possible.
The safest changes for me to install are changes to the s- and m- The safest changes for us to install are changes to the s- and m-
files. At least I know those can't affect most systems. files. At least those can't break other systems.
Another safe kind of change is one that uses a conditional to make Another safe kind of change is one that uses a conditional to make
sure it will apply only to a particular kind of system. Ordinarily, 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
cleaner alternative. But the virtue of safety can make it superior at cleaner alternative. But the virtue of safety can make it superior at
pretest time. pretest time.
* Don't try changing Emacs *in any way* unless it fails to work unchanged. * Don't suggest changes during pretest to add features or make
something cleaner. Every change risks introducing a bug, so I won't
* Don't even suggest changes to add features or make something install a change during pretest unless it is *necessary*.
cleaner. Every change I install could introduce a bug, so I won't
install a change during pretest unless I see it is *necessary*.
* If you would like to suggest changes for purposes other than fixing * If you would like to suggest changes for purposes other than fixing
user-visible bugs, don't wait till pretest time. Instead, send them user-visible bugs, don't wait till pretest time. Instead, send them
after I have made a release that proves to be stable. Then I can give after we have made a release that proves to be stable. That is the
your suggestions proper consideration. If you send them at pretest easiest time to consider such suggestions. If you send them at
time, I will have to defer them till later, and that might mean I pretest time, we will have to defer them till later, and that might
forget all about them. mean we forget all about them.
* In some cases, if you don't follow these guidelines, your * In some cases, if you don't follow these guidelines, your
information might still be useful, but I might have to do more work to information might still be useful, but we would have to do more work
make use of it. Unfortunately, I am so far behind in my work that I to make use of it. That might cause it to fall by the wayside.
just can't keep up unless you help me to do it efficiently.
Some suggestions for debugging on MS Windows:
Marc Fleischeuers, Geoff Voelker and Andrew Innes
To debug emacs with Microsoft Visual C++, you either start emacs from
the debugger or attach the debugger to a running emacs process. To
start emacs from the debugger, you can use the file bin/debug.bat. The
Microsoft Developer studio will start and under Project, Settings,
Debug, General you can set the command-line arguments and emacs'
startup directory. Set breakpoints (Edit, Breakpoints) at Fsignal and
other functions that you want to examine. Run the program (Build,
Start debug). Emacs will start and the debugger will take control as
soon as a breakpoint is hit.
You can also attach the debugger to an already running emacs process.
To do this, start up the Microsoft Developer studio and select Build,
Start debug, Attach to process. Choose the emacs process from the
list. Send a break to the running process (Debug, Break) and you will
find that execution is halted somewhere in user32.dll. Open the stack
trace window and go up the stack to w32_msg_pump. Now you can set
breakpoints in emacs (Edit, Breakpoints). Continue the running emacs
process (Debug, Step out) and control will return to emacs, until a
breakpoint is hit.
To examine the contents of a lisp variable, you can use the function
'debug_print'. Right-click on a variable, select QuickWatch, and
place 'debug_print(' and ')' around the expression. Press
'Recalculate' and the output is sent to the 'Debug' pane in the Output
window. If emacs was started from the debugger, a console window was
opened at emacs' startup; this console window also shows the output of
'debug_print'. It is also possible to keep appropriately masked and
typecast lisp symbols in the Watch window, this is more convenient
when steeping though the code. For instance, on entering
apply_lambda, you can watch (struct Lisp_Symbol *) (0xfffffff &
args[0]).
Local Variables: Local Variables:
mode: text mode: text

View file

@ -1,3 +1,20 @@
2005-05-30 Miles Bader <miles@gnu.org>
* emacs-buffer.gdb: Remove RCS keywords.
2005-05-30 Noah Friedman <friedman@splode.com>
* emacs-buffer.gdb: New file.
* NEWS: Mention it.
2005-05-28 Richard M. Stallman <rms@gnu.org>
* TUTORIAL.fr: Change NBSP to space.
2005-05-28 Bill Wohler <wohler@newt.com>
* NEWS, MH-E-NEWS: Upgraded to MH-E version 7.84.
2005-05-19 Nick Roberts <nickrob@snap.net.nz> 2005-05-19 Nick Roberts <nickrob@snap.net.nz>
* TODO: post-command-idle-hook has gone. * TODO: post-command-idle-hook has gone.

View file

@ -1,16 +1,94 @@
* COPYRIGHT * COPYRIGHT
Copyright (C) 2003, 2004 Free Software Foundation, Inc. Copyright (C) 2003, 2004, 2005 Free Software Foundation, Inc.
Copying and distribution of this file, with or without modification, Copying and distribution of this file, with or without modification,
are permitted in any medium without royalty provided the copyright are permitted in any medium without royalty provided the copyright
notice and this notice are preserved. notice and this notice are preserved.
* Changes in MH-E 7.84
Version 7.84 contains no user-visible changes. This version
incorporates changes made in CVS Emacs such as the removal of some
deprecated software.
* Changes in MH-E 7.83
Version 7.83 fixes a handful of bugs, adds colors to buttons for
signed or encrypted messages, and contains some documentation changes
related to the upcoming release of the manual. Some options were moved
to other customization groups as a result.
While not related to this release, the MH-E mailing lists are now
gatewayed at gmane.org (closes SF #979308).
** New Variables in MH-E 7.83
*** mh-show-pgg-bad-face
Face used to highlight a bad PGG signature.
*** mh-show-pgg-good-face
Face used to highlight a good PGG signature.
*** mh-show-pgg-unknown-face
Face used to highlight a PGG signature whose status is unknown. This
face is also used for a signature when the signer is untrusted.
** Bug Fixes in MH-E 7.83
*** Whitespace in pick Expressions
The "C-u / s RET" command now works. In addition, you can now add
whitespace to any of the limiting (/) commands (closes SF #1122655).
*** auto-mode-alist Updated
MH-E originally updated auto-mode-alist to set the major mode of
drafts. Now that we explicitly set the mode, there is no reason to do
this, and this behavior caused problems for people who didn't use MH-E
who were editing files that looked like MH message files (closes SF
#1032353).
*** mh-show-unquote-From Fails (read-only buffer)
MH-E quotes the "From " header field that is inserted by MTAs.
However, it was trying to do this in a read-only buffer. This has been
fixed (closes SF #1089870).
*** rmmproc Refile Complains No Such Message
MH-E would get confused about which folder to delete messages from if
you were refiling and deleting messages at the same time. This has
been fixed (closes SF #1023959).
*** ! Doesn't Do Regions
Now it does (closes SF #1046330).
*** Swish Fixes
Items in swish indexes that aren't mail messages are now handled more
gracefully.
*** Spamassassin Fixes
If you use spamassassin, there was an error when you tried to junk
mail if the option mh-junk-background was set. This has been fixed.
*** Mairix Support
Indexing now compatible with Mairix version 0.12 and later.
* Changes in MH-E 7.82 * Changes in MH-E 7.82
Version 7.82 continues to address the saga surrounding the use of CL Version 7.82 continues to address the saga surrounding the use of CL
macros in CVS Emacs and fixes the auto-detection of vanilla MH (SF macros in CVS Emacs and fixes the auto-detection of vanilla MH (closes
#1014781). SF #1014781).
* Changes in MH-E 7.81 * Changes in MH-E 7.81
@ -23,6 +101,8 @@ of "default" in `mh-identity-handlers' to avoid problems with
to ":default". This release also corrects the release numbering; the to ":default". This release also corrects the release numbering; the
previous version number was intended to be 7.80. previous version number was intended to be 7.80.
* Changes in MH-E 7.4.80 * Changes in MH-E 7.4.80
Version 7.4.80 now supports GNU mailutils, S/MIME, picons, Version 7.4.80 now supports GNU mailutils, S/MIME, picons,

View file

@ -183,9 +183,15 @@ types any more. Add -DUSE_LISP_UNION_TYPE if you want union types.
--- ---
** When pure storage overflows while dumping, Emacs now prints how ** When pure storage overflows while dumping, Emacs now prints how
much pure storage it will approximately need. much pure storage it will approximately need.
** The script etc/emacs-buffer.gdb can be used with gdb to retrieve the
contents of buffers from a core dump and save them to files easily, should
emacs crash.
* Startup Changes in Emacs 22.1 * Startup Changes in Emacs 22.1
+++
** New command line option -Q or --quick. ** New command line option -Q or --quick.
This is like using -q --no-site-file, but in addition it also disables This is like using -q --no-site-file, but in addition it also disables
the fancy startup screen. the fancy startup screen.
@ -419,6 +425,10 @@ understand two new boolean pseudo-frame-parameters `same-frame' and
** The default for the paper size (variable ps-paper-type) is taken ** The default for the paper size (variable ps-paper-type) is taken
from the locale. from the locale.
** The command `list-faces-display' now accepts a prefix arg.
When passed, the function prompts for a regular expression and lists
only faces matching this regexp.
** Mark command changes: ** Mark command changes:
+++ +++
@ -776,6 +786,7 @@ gives the fraction of the window's width to scroll the window.
The variable `automatic-hscrolling' was renamed to The variable `automatic-hscrolling' was renamed to
`auto-hscroll-mode'. The old name is still available as an alias. `auto-hscroll-mode'. The old name is still available as an alias.
---
*** Moving or scrolling through images (and other lines) taller that *** Moving or scrolling through images (and other lines) taller that
the window now works sensibly, by automatically adjusting the window's the window now works sensibly, by automatically adjusting the window's
vscroll property. vscroll property.
@ -892,8 +903,10 @@ trouble with fontification and/or indentation.
+++ +++
*** New standard font-lock face `font-lock-preprocessor-face'. *** New standard font-lock face `font-lock-preprocessor-face'.
+++
*** New standard font-lock face `font-lock-comment-delimiter-face'. *** New standard font-lock face `font-lock-comment-delimiter-face'.
+++
*** Easy to overlook single character negation can now be font-locked. *** Easy to overlook single character negation can now be font-locked.
You can use the new variable `font-lock-negation-char-face' and the face of You can use the new variable `font-lock-negation-char-face' and the face of
the same name to customize this. Currently the cc-modes, sh-script-mode, 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,
like bash's `ESC .' binding. It is bound by default to `C-c .', but like bash's `ESC .' binding. It is bound by default to `C-c .', but
otherwise behaves quite similarly to the bash version. otherwise behaves quite similarly to the bash version.
+++
*** `comint-use-prompt-regexp-instead-of-fields' has been renamed *** `comint-use-prompt-regexp-instead-of-fields' has been renamed
`comint-use-prompt-regexp'. The old name has been kept as an alias, `comint-use-prompt-regexp'. The old name has been kept as an alias,
but declared obsolete. but declared obsolete.
@ -1358,9 +1372,11 @@ buffer causes automatic display in another window of the corresponding
matches, compilation errors, etc. This minor mode can be toggled with matches, compilation errors, etc. This minor mode can be toggled with
C-c C-f. C-c C-f.
+++
*** When the left fringe is displayed, an arrow points to current message in *** When the left fringe is displayed, an arrow points to current message in
the compilation buffer. the compilation buffer.
+++
*** The new variable `compilation-context-lines' controls lines of leading *** The new variable `compilation-context-lines' controls lines of leading
context before the current message. If nil and the left fringe is displayed, context before the current message. If nil and the left fringe is displayed,
it doesn't scroll the compilation output window. If there is no left fringe, 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
similar to Refill mode, but more reliable. To turn the word wrap similar to Refill mode, but more reliable. To turn the word wrap
feature off, set `longlines-auto-wrap' to nil. feature off, set `longlines-auto-wrap' to nil.
+++
** The printing package is now part of the Emacs distribution. ** The printing package is now part of the Emacs distribution.
If you enable the printing package by including (require 'printing) in 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.
* Changes in Specialized Modes and Packages in Emacs 22.1: * Changes in Specialized Modes and Packages in Emacs 22.1:
---
** Makefile mode has submodes for automake, gmake, makepp and BSD make. ** Makefile mode has submodes for automake, gmake, makepp and BSD make.
The former two couldn't be differentiated before, and the latter two 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.
+++ +++
*** Desktop saving is now a minor mode, `desktop-save-mode'. *** Desktop saving is now a minor mode, `desktop-save-mode'.
+++
*** The variable `desktop-enable' is obsolete. *** The variable `desktop-enable' is obsolete.
Customize `desktop-save-mode' to enable desktop saving. Customize `desktop-save-mode' to enable desktop saving.
@ -2537,6 +2556,7 @@ currently highlighted regions in an inferior Ediff session. If you answer 'n'
then it reverts to the old behavior and asks the user to select regions for then it reverts to the old behavior and asks the user to select regions for
comparison. comparison.
+++
*** The new command `ediff-backup' compares a file with its most recent *** The new command `ediff-backup' compares a file with its most recent
backup using `ediff'. If you specify the name of a backup file, backup using `ediff'. If you specify the name of a backup file,
`ediff-backup' compares it with the file of which it is a backup. `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.
--- ---
** MH-E changes. ** MH-E changes.
Upgraded to MH-E version 7.82. There have been major changes since Upgraded to MH-E version 7.84. There have been major changes since
version 5.0.2; see MH-E-NEWS for details. version 5.0.2; see MH-E-NEWS for details.
** Calendar changes: ** Calendar changes:
@ -3207,6 +3227,10 @@ It returns nil if the given Lisp form can't possibly do anything
dangerous; otherwise it returns a reason why the form might be unsafe dangerous; otherwise it returns a reason why the form might be unsafe
(calls unknown function, alters global variable, etc). (calls unknown function, alters global variable, etc).
*** `list-faces-display' takes an optional argument, REGEXP.
If it is non-nil, the function lists only faces matching this regexp.
** Lisp code indentation features: ** Lisp code indentation features:
+++ +++
@ -4846,6 +4870,7 @@ used to add text properties to mode-line elements.
to display the size of the accessible part of the buffer on the mode to display the size of the accessible part of the buffer on the mode
line. line.
+++
*** Mouse-face on mode-line (and header-line) is now supported. *** Mouse-face on mode-line (and header-line) is now supported.
`mode-line-highlight' is the standard face indicating mouse sensitive `mode-line-highlight' is the standard face indicating mouse sensitive
elements on mode-line (and header-line) like `highlight' face on text elements on mode-line (and header-line) like `highlight' face on text

View file

@ -746,14 +746,14 @@ syst
périodiquement un fichier de « sauvegarde automatique » pour chaque périodiquement un fichier de « sauvegarde automatique » pour chaque
fichier en cours d'édition. Le nom de ce fichier commence et se fichier en cours d'édition. Le nom de ce fichier commence et se
termine par un # : si, par exemple, votre fichier s'appelle termine par un # : si, par exemple, votre fichier s'appelle
« hello.c », son fichier de sauvegarde automatique s'appellera « hello.c », son fichier de sauvegarde automatique s'appellera
« #hello.c# ». Lorsque vous sauvegardez le fichier de la façon « #hello.c# ». Lorsque vous sauvegardez le fichier de la façon
habituelle, Emacs détruit son fichier de sauvegarde automatique. habituelle, Emacs détruit son fichier de sauvegarde automatique.
Si l'ordinateur se plante, vous pouvez récupérer ce qui a été Si l'ordinateur se plante, vous pouvez récupérer ce qui a été
sauvegardé automatiquement en ouvrant normalement le fichier (celui sauvegardé automatiquement en ouvrant normalement le fichier (celui
que vous éditiez, pas la sauvegarde automatique), puis en faisant que vous éditiez, pas la sauvegarde automatique), puis en faisant
M-x recover file<Entrée>. Lorsqu'Emacs vous demande de confirmer, M-x recover file<Entrée>. Lorsqu'Emacs vous demande de confirmer,
tapez yes<Entrée> pour continuer et récupérer ainsi les données tapez yes<Entrée> pour continuer et récupérer ainsi les données
sauvées par la sauvegarde automatique. sauvées par la sauvegarde automatique.
@ -847,7 +847,7 @@ et que la ligne est trop longue.
Vous pouvez activer le mode Auto Fill en faisant M-x auto fill Vous pouvez activer le mode Auto Fill en faisant M-x auto fill
mode<Entrée>. Lorsqu'il est activé, vous pouvez le désactiver en mode<Entrée>. Lorsqu'il est activé, vous pouvez le désactiver en
faisant à nouveau M-x auto fill mode<Entrée>. Si le mode est faisant à nouveau M-x auto fill mode<Entrée>. Si le mode est
désactivé, cette commande l'active et, s'il est activé, elle le désactivé, cette commande l'active et, s'il est activé, elle le
désactive : on dit que la commande « fait basculer le mode ». désactive : on dit que la commande « fait basculer le mode ».
@ -913,10 +913,10 @@ de mettre fin
REMARQUE : Sur certains systèmes, C-s gèlera l'écran et vous ne verrez REMARQUE : Sur certains systèmes, C-s gèlera l'écran et vous ne verrez
plus rien se produire dans Emacs. Cela indique qu'une plus rien se produire dans Emacs. Cela indique qu'une
« fonctionnalité » du système d'exploitation, appelée « contrôle de « fonctionnalité » du système d'exploitation, appelée « contrôle de
flux », a intercepté le C-s et ne lui permet pas de parvenir à flux », a intercepté le C-s et ne lui permet pas de parvenir à
Emacs. Pour décoincer l'écran, faites C-q puis consultez la section Emacs. Pour décoincer l'écran, faites C-q puis consultez la section
« Spontaneous Entry to Incremental Search » dans le manuel d'Emacs « Spontaneous Entry to Incremental Search » dans le manuel d'Emacs
pour avoir des avis sur la gestion de cette « fonctionnalité ». pour avoir des avis sur la gestion de cette « fonctionnalité ».
Si vous vous trouvez au milieu d'une recherche incrémentale et que 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
caractère de la chaîne recherchée et que la recherche reprend à caractère de la chaîne recherchée et que la recherche reprend à
l'endroit où elle se trouvait précédemment. Supposons, par exemple, l'endroit où elle se trouvait précédemment. Supposons, par exemple,
que vous ayiez tapé « c » pour trouver la première occurrence de que vous ayiez tapé « c » pour trouver la première occurrence de
« c ». Si vous tapez maintenant « u », le curseur ira sur la première « c ». Si vous tapez maintenant « u », le curseur ira sur la première
occurrence de « cu ». Faites <Delback> : cela supprime le « u » de la occurrence de « cu ». Faites <Delback> : cela supprime le « u » de la
chaîne de recherche et le curseur revient à la première occurrence de chaîne de recherche et le curseur revient à la première occurrence de
« c ». « c ».
@ -1038,7 +1038,7 @@ de possibilit
ici. Cependant, vous pouvez vouloir en apprendre plus, car il a bien ici. Cependant, vous pouvez vouloir en apprendre plus, car il a bien
d'autres fonctionnalités utiles. Emacs dispose de commandes pour lire d'autres fonctionnalités utiles. Emacs dispose de commandes pour lire
la documentation sur ses commandes. Ces commandes d'« aide » la documentation sur ses commandes. Ces commandes d'« aide »
commencent toutes par le caractère C-h, le « caractère d'aide ». commencent toutes par le caractère C-h, le « caractère d'aide ».
Pour utiliser l'aide, tapez C-h suivi d'un caractère indiquant le type Pour utiliser l'aide, tapez C-h suivi d'un caractère indiquant le type
d'aide que vous souhaitez. Si vous êtes VRAIMENT perdu, faites C-h ? d'aide que vous souhaitez. Si vous êtes VRAIMENT perdu, faites C-h ?
@ -1113,7 +1113,7 @@ leur correspondent, comme find-file.
C-h i Manuels en ligne (alias Info). Cette commande vous place dans C-h i Manuels en ligne (alias Info). Cette commande vous place dans
un tampon spéciale, appelé « *info* », où vous pouvez un tampon spéciale, appelé « *info* », où vous pouvez
lire les manuels en ligne des paquetages installés sur lire les manuels en ligne des paquetages installés sur
votre système. Faites m emacs <Entrée> pour lire le votre système. Faites m emacs <Entrée> pour lire le
manuel d'Emacs. Si vous n'avez jamais utilisé Info manuel d'Emacs. Si vous n'avez jamais utilisé Info
auparavant, tapez ? et Emacs vous fera faire une visite auparavant, tapez ? et Emacs vous fera faire une visite
guidée des fonctionnalités du mode Info. Lorsque vous guidée des fonctionnalités du mode Info. Lorsque vous
@ -1133,7 +1133,7 @@ frappe, et dired, qui simplifie la manipulation des fichiers.
La complétion permet d'éviter les frappes inutiles. Si, par exemple, La complétion permet d'éviter les frappes inutiles. Si, par exemple,
vous voulez basculer vers le tampon *Messages*, tapez simplement vous voulez basculer vers le tampon *Messages*, tapez simplement
C-x b *M<Tab> et Emacs complètera le nom du tampon s'il peut le C-x b *M<Tab> et Emacs complètera le nom du tampon s'il peut le
déterminer à partir de ce que vous avez saisi avant la tabulation. La déterminer à partir de ce que vous avez saisi avant la tabulation. La
complétion est décrite dans la version Info du manuel Emacs, à la complétion est décrite dans la version Info du manuel Emacs, à la
rubrique "Completion". rubrique "Completion".

270
etc/emacs-buffer.gdb Normal file
View file

@ -0,0 +1,270 @@
# emacs-buffer.gdb --- gdb macros for recovering buffers from emacs coredumps
# Copyright (C) 2005 Free Software Foundation, Inc.
# Maintainer: Noah Friedman <friedman@splode.com>
# Status: tested with Emacs 22
# Created: 2005-04-28
# This file is part of GNU Emacs.
#
# GNU Emacs is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
#
# GNU Emacs is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with GNU Emacs; see the file COPYING. If not, write to the
# Free Software Foundation, Inc.; 51 Franklin Street, Fifth Floor;
# Boston, MA 02110-1301, USA.
# Commentary:
# This is a set of gdb macros for recovering the contents of buffers from
# an Emacs coredump; they may not always be file-backed or have a recent
# autosave.
#
# The Emacs executable must have debugging symbols for this to work. But
# you never strip Emacs, right? Right!
#
# The main commands of interest are `ybuffer-list', `yfile-buffers',
# `ysave-buffer', and `ybuffer-contents'. The `y' prefix avoids any
# namespace collisions with emacs/src/.gdbinit.
# Example usage:
#
# $ gdb /export/src/emacs/2005-05-02--03-17/src/emacs core.emacs.6.9845
# Current directory is /u/noah/
# GNU gdb (6.1post-1.20040607.43rh)
# ...
# #0 0x400007a2 in _dl_sysinfo_int80 () from /lib/ld-linux.so.2
# (gdb) source emacs-buffer.gdb
# (gdb) ybuffer-list
# B# M Size Name Mode File
# -- - ---- ---- ---- ----
# 0 * 556 mail to emacs-devel@gnu.org Mail
# 1 * 0 *Minibuf-1* Fundamental
# 2 145769 ChangeLog Change Log /u/noah/lib/elisp/noahf/ChangeLog
# 3 6619 ascii-table.el Elisp /u/noah/lib/elisp/noahf/ascii-table.el
# 4 * 48396 *Messages* Fundamental
# 5 3191 *Apropos* Apropos
# 6 17642 init-21.el Elisp /u/noah/etc/init/emacs/init-21.el
# 7 333 cpuid.c C /u/noah/cpuid.c
# 8 230 src Dired
# 9 218 noah Dired
# 10 * 21 *Echo Area 0* Fundamental
# 11 * 0 *Echo Area 1* Fundamental
# 12 319952 *bbdb data* Text /u/noah/.bbdb
# (gdb) ysave-buffer 0 mail.save
# [Wrote buffer "mail to emacs-devel@gnu.org" to file mail.save]
# (gdb) quit
# $ ls -l mail.save
# -rw-rw-rw- 1 noah user 556 May 2 04:05 mail.save
# $
# Code:
# Force loading of symbols, enough to give us gdb_valbits etc.
set main
# When nonzero, display some extra diagnostics in various commands
set $yverbose = 1
set $yfile_buffers_only = 0
set $tagmask = (((long)1 << gdb_gctypebits) - 1)
set $valmask = gdb_use_lsb ? ~($tagmask) : ((long)1 << gdb_valbits) - 1
define ygetptr
set $ptr = $arg0
set $ptr = (gdb_use_union ? $ptr.u.val : $ptr & $valmask) | gdb_data_seg_bits
end
define ybuffer-list
set $files_only = $yfile_buffers_only
set $yfile_buffers_only = 0
if $yverbose
printf "B# M Size Name Mode File\n"
printf "-- - ---- ---- ---- ----\n"
end
set $i = 0
set $alist = Vbuffer_alist
while $alist != Qnil
ygetptr $alist
set $this = ((struct Lisp_Cons *) $ptr)->car
set $alist = ((struct Lisp_Cons *) $ptr)->cdr
# Vbuffer_alist elts are pairs of the form (name . buffer)
ygetptr $this
set $buf = ((struct Lisp_Cons *) $ptr)->cdr
ygetptr $buf
set $buf = (struct buffer *) $ptr
if ! ($files_only && $buf->filename == Qnil)
ygetptr $buf->name
set $name = ((struct Lisp_String *) $ptr)->data
set $modp = ($buf->text->modiff > $buf->text->save_modiff) ? '*' : ' '
ygetptr $buf->mode_name
set $mode = ((struct Lisp_String *) $ptr)->data
if $buf->filename != Qnil
ygetptr $buf->filename
set $filename = ((struct Lisp_String *) $ptr)->data
else
set $filename = ' '
end
printf "%2d %c %9d %-20s %-10s %s\n", \
$i, $modp, ($buf->text->z_byte - 1), $name, $mode, $filename
end
set $i++
end
end
document ybuffer-list
Display a list of buffer names, sizes, and other attributes.
The buffer number in the first column is used as an argument
to some other emacs-buffer recovery commands, e.g. `ysave-buffer'.
end
define yfile-buffers
set $yfile_buffers_only = 1
ybuffer-list
end
document yfile-buffers
Display a list of buffers which are associated with files.
This is like `ybuffer-list', but only buffers that were visiting files
are displayed.
end
define yset-buffer
set $i = $arg0
set $alist = Vbuffer_alist
while ($alist != Qnil && $i > 0)
ygetptr $alist
set $alist = ((struct Lisp_Cons *) $ptr)->cdr
set $i--
end
# Get car of alist; this is a pair (name . buffer)
ygetptr $alist
set $this = ((struct Lisp_Cons *) $ptr)->car
# Get the buffer object
ygetptr $this
set $this = ((struct Lisp_Cons *) $ptr)->cdr
ygetptr $this
set $ycurrent_buffer = (struct buffer *) $ptr
end
document yset-buffer
Set current buffer (for other emacs-buffer recovery commands) to the ARG'th
buffer as displayed by `ybuffer-list'.
end
define yget-buffer-pointers
yset-buffer $arg0
set $buf = $ycurrent_buffer->text
set $beg = $buf->beg
set $gap = $beg + $buf->gpt_byte
set $gap_end = $gap + $buf->gap_size - 1
set $end = $gap_end + ($buf->z_byte - $buf->gpt_byte)
set $modp = $buf->modiff > $buf->save_modiff
#print *$beg@($gap - $beg)
#print *$gap_end@($end - $gap_end)
end
document yget-buffer-pointers
Update convenience variables with address pointers for the ARG'th buffer
as displayed by `ybuffer-list'.
This also sets the current buffer using `yset-buffer' (which see).
end
define yget-current-buffer-name
set $this = $ycurrent_buffer->name
ygetptr $this
set $ycurrent_buffer_name = ((struct Lisp_String *) $ptr)->data
end
document yget-current-buffer-name
Set $ycurrent_buffer_name to the name of the currently selected buffer.
end
define ycurrent-buffer
yget-current-buffer-name
printf "%s\n", $ycurrent_buffer_name
end
document ycurrent-buffer
Display the currently selected buffer.
end
define ydump-buffer
yget-buffer-pointers $arg0
if $buf->z_byte > 1
if $buf->z_byte <= $buf->gpt_byte
set $endptr = $beg + $buf->gpt_byte - 1
dump binary memory $arg1 $beg $endptr
else
dump binary memory $arg1 $beg $gap-1
append binary memory $arg1 $gap_end $end
set $endptr = $end
end
end
end
document ydump-buffer
Write contents of buffer N (as numbered according to `ybuffer-list') to
file FILE.
This is mainly used as an internal subroutine for `ysave-buffer' and
`ybuffer-contents', which see.
end
define ysave-buffer
ydump-buffer $arg0 $arg1
if $yverbose
yget-current-buffer-name
if $buf->z_byte <= 1
printf "[Buffer \"%s\" is empty.]\n", $ycurrent_buffer_name
else
# Output string broken into separate calls as necessary to avoid
# requiring a running process for evaluation.
printf "[Wrote buffer \"%s\" to file ", $ycurrent_buffer_name
echo $arg1]\n
end
end
end
document ysave-buffer
Save contents of buffer N (as numbered according to `ybuffer-list') to
file FILE.
end
define ybuffer-contents
ydump-buffer $arg0 /dev/stdout
if $yverbose && $buf->z_byte <= 1
yget-current-buffer-name
printf "[Buffer \"%s\" is empty.]\n", $ycurrent_buffer_name
else
if *($endptr-1) != '\n'
echo \n
end
end
end
document ybuffer-contents
Write contents of buffer N (numbered according to `ybuffer-list') to stdout.
end
# local variables:
# mode: gdb-script
# end:
# arch-tag: 02087f62-2663-4868-977a-1fbb2fc2e7ef

View file

@ -1,3 +1,9 @@
2005-06-04 Eli Zaretskii <eliz@gnu.org>
* makefile.w32-in (distclean): Fix a typo (colon was after
"clean").
(extraclean): New target, emulates Makefile.in.
2005-04-06 Kenichi Handa <handa@m17n.org> 2005-04-06 Kenichi Handa <handa@m17n.org>
* quail/sgml-input.el ("sgml"): Enable quail-completion by typing * quail/sgml-input.el ("sgml"): Enable quail-completion by typing

View file

@ -1,6 +1,7 @@
# -*- Makefile -*- for leim subdirectory in GNU Emacs on the Microsoft W32 API. # -*- Makefile -*- for leim subdirectory in GNU Emacs on the Microsoft W32 API.
# Copyright (C) 1997, 2004 Electrotechnical Laboratory, JAPAN. # Copyright (C) 1997, 2004 Electrotechnical Laboratory, JAPAN.
# Licensed to the Free Software Foundation. # Licensed to the Free Software Foundation.
# Copyright (C) 2005, Free Software Foundation, Inc.
# This file is part of GNU Emacs. # This file is part of GNU Emacs.
@ -197,9 +198,12 @@ clean mostlyclean:
- $(FOREACH) $(MISC_DIC:.elc=.el) $(FORDO) $(DEL) $(FORVAR) $(ENDFOR) - $(FOREACH) $(MISC_DIC:.elc=.el) $(FORDO) $(DEL) $(FORVAR) $(ENDFOR)
- $(DEL) leim-list.el - $(DEL) leim-list.el
distclean clean: distclean: clean
- $(DELTREE) $(SUBDIRS) - $(DELTREE) $(SUBDIRS)
- $(DEL) stamp-subdir - $(DEL) stamp-subdir
maintainer-clean: distclean maintainer-clean: distclean
- $(FOREACH) $(WORLD) $(FORDO) $(DEL) $(FORVAR) $(ENDFOR) - $(FOREACH) $(WORLD) $(FORDO) $(DEL) $(FORVAR) $(ENDFOR)
extraclean: maintainer-clean
- $(FOREACH) *~ "#*" $(FORDO) $(DEL) $(FORVAR) $(ENDFOR)

View file

@ -1,3 +1,7 @@
2005-06-04 Eli Zaretskii <eliz@gnu.org>
* ntlib.h (fileno): Don't define if already defined.
2005-05-25 Thien-Thi Nguyen <ttn@gnu.org> 2005-05-25 Thien-Thi Nguyen <ttn@gnu.org>
* yow.c (setup_yow): Use EXIT_FAILURE in case no separators found. * yow.c (setup_yow): Use EXIT_FAILURE in case no separators found.

View file

@ -90,7 +90,9 @@ int fchown (int fd, int uid, int gid);
#define fcloseall _fcloseall #define fcloseall _fcloseall
#define fdopen _fdopen #define fdopen _fdopen
#define fgetchar _fgetchar #define fgetchar _fgetchar
#ifndef fileno
#define fileno _fileno #define fileno _fileno
#endif
#define flushall _flushall #define flushall _flushall
#define fputchar _fputchar #define fputchar _fputchar
#define getcwd _getcwd #define getcwd _getcwd

File diff suppressed because it is too large Load diff

View file

@ -220,7 +220,7 @@ Note: The search is conducted only within 10%, at the beginning of the file."
("^\\sw.........[0-9:+ ]*" ("^\\sw.........[0-9:+ ]*"
(0 'change-log-date-face) (0 'change-log-date-face)
;; Name and e-mail; some people put e-mail in parens, not angles. ;; Name and e-mail; some people put e-mail in parens, not angles.
("\\([^<(]+?\\)[ \t]*[(<]\\([A-Za-z0-9_.-]+@[A-Za-z0-9_.-]+\\)[>)]" nil nil ("\\([^<(]+?\\)[ \t]*[(<]\\([A-Za-z0-9_.+-]+@[A-Za-z0-9_.-]+\\)[>)]" nil nil
(1 'change-log-name-face) (1 'change-log-name-face)
(2 'change-log-email-face))) (2 'change-log-email-face)))
;; ;;

View file

@ -689,7 +689,7 @@ archive.
(setq major-mode 'archive-mode) (setq major-mode 'archive-mode)
(setq mode-name (concat typename "-Archive")) (setq mode-name (concat typename "-Archive"))
;; Run archive-foo-mode-hook and archive-mode-hook ;; Run archive-foo-mode-hook and archive-mode-hook
(run-hooks (archive-name "mode-hook") 'archive-mode-hook) (run-mode-hooks (archive-name "mode-hook") 'archive-mode-hook)
(use-local-map archive-mode-map)) (use-local-map archive-mode-map))
(make-local-variable 'archive-proper-file-start) (make-local-variable 'archive-proper-file-start)

View file

@ -872,6 +872,7 @@ take a numeric prefix argument):
Entering array mode calls the function `array-mode-hook'." Entering array mode calls the function `array-mode-hook'."
(interactive) (interactive)
(kill-all-local-variables)
;; Number of rows in the array. ;; Number of rows in the array.
(make-local-variable 'array-max-row) (make-local-variable 'array-max-row)
;; Number of columns in the array. ;; Number of columns in the array.
@ -907,7 +908,7 @@ Entering array mode calls the function `array-mode-hook'."
(setq truncate-lines t) (setq truncate-lines t)
(setq overwrite-mode 'overwrite-mode-textual) (setq overwrite-mode 'overwrite-mode-textual)
(use-local-map array-mode-map) (use-local-map array-mode-map)
(run-hooks 'array-mode-hook)) (run-mode-hooks 'array-mode-hook))

View file

@ -484,46 +484,47 @@ are checked first the next time this function is called.
This function is also responsible for removing buffers no longer in This function is also responsible for removing buffers no longer in
Auto-Revert mode from `auto-revert-buffer-list', and for canceling Auto-Revert mode from `auto-revert-buffer-list', and for canceling
the timer when no buffers need to be checked." the timer when no buffers need to be checked."
(let ((bufs (if global-auto-revert-mode (save-match-data
(buffer-list) (let ((bufs (if global-auto-revert-mode
auto-revert-buffer-list)) (buffer-list)
(remaining ()) auto-revert-buffer-list))
(new ())) (remaining ())
;; Partition `bufs' into two halves depending on whether or not (new ()))
;; the buffers are in `auto-revert-remaining-buffers'. The two ;; Partition `bufs' into two halves depending on whether or not
;; halves are then re-joined with the "remaining" buffers at the ;; the buffers are in `auto-revert-remaining-buffers'. The two
;; head of the list. ;; halves are then re-joined with the "remaining" buffers at the
(dolist (buf auto-revert-remaining-buffers) ;; head of the list.
(if (memq buf bufs) (dolist (buf auto-revert-remaining-buffers)
(push buf remaining))) (if (memq buf bufs)
(dolist (buf bufs) (push buf remaining)))
(if (not (memq buf remaining)) (dolist (buf bufs)
(push buf new))) (if (not (memq buf remaining))
(setq bufs (nreverse (nconc new remaining))) (push buf new)))
(while (and bufs (setq bufs (nreverse (nconc new remaining)))
(not (and auto-revert-stop-on-user-input (while (and bufs
(input-pending-p)))) (not (and auto-revert-stop-on-user-input
(let ((buf (car bufs))) (input-pending-p))))
(if (buffer-name buf) ; Buffer still alive? (let ((buf (car bufs)))
(with-current-buffer buf (if (buffer-name buf) ; Buffer still alive?
;; Test if someone has turned off Auto-Revert Mode in a (with-current-buffer buf
;; non-standard way, for example by changing major mode. ;; Test if someone has turned off Auto-Revert Mode in a
(if (and (not auto-revert-mode) ;; non-standard way, for example by changing major mode.
(not auto-revert-tail-mode) (if (and (not auto-revert-mode)
(memq buf auto-revert-buffer-list)) (not auto-revert-tail-mode)
(setq auto-revert-buffer-list (memq buf auto-revert-buffer-list))
(delq buf auto-revert-buffer-list))) (setq auto-revert-buffer-list
(when (auto-revert-active-p) (auto-revert-handler))) (delq buf auto-revert-buffer-list)))
;; Remove dead buffer from `auto-revert-buffer-list'. (when (auto-revert-active-p) (auto-revert-handler)))
(setq auto-revert-buffer-list ;; Remove dead buffer from `auto-revert-buffer-list'.
(delq buf auto-revert-buffer-list)))) (setq auto-revert-buffer-list
(setq bufs (cdr bufs))) (delq buf auto-revert-buffer-list))))
(setq auto-revert-remaining-buffers bufs) (setq bufs (cdr bufs)))
;; Check if we should cancel the timer. (setq auto-revert-remaining-buffers bufs)
(when (and (not global-auto-revert-mode) ;; Check if we should cancel the timer.
(null auto-revert-buffer-list)) (when (and (not global-auto-revert-mode)
(cancel-timer auto-revert-timer) (null auto-revert-buffer-list))
(setq auto-revert-timer nil)))) (cancel-timer auto-revert-timer)
(setq auto-revert-timer nil)))))
;; The end: ;; The end:

View file

@ -866,7 +866,7 @@ the annotation.
(use-local-map bookmark-read-annotation-mode-map) (use-local-map bookmark-read-annotation-mode-map)
(setq major-mode 'bookmark-read-annotation-mode) (setq major-mode 'bookmark-read-annotation-mode)
(insert (funcall bookmark-read-annotation-text-func bookmark)) (insert (funcall bookmark-read-annotation-text-func bookmark))
(run-hooks 'text-mode-hook)) (run-mode-hooks 'text-mode-hook))
(defun bookmark-read-annotation (parg bookmark) (defun bookmark-read-annotation (parg bookmark)
@ -903,7 +903,7 @@ When you have finished composing, type \\[bookmark-send-annotation].
(let ((annotation (bookmark-get-annotation bookmark))) (let ((annotation (bookmark-get-annotation bookmark)))
(if (and annotation (not (string-equal annotation ""))) (if (and annotation (not (string-equal annotation "")))
(insert annotation))) (insert annotation)))
(run-hooks 'text-mode-hook)) (run-mode-hooks 'text-mode-hook))
(defun bookmark-send-edited-annotation () (defun bookmark-send-edited-annotation ()
@ -1618,7 +1618,7 @@ Bookmark names preceded by a \"*\" have annotations.
(setq buffer-read-only t) (setq buffer-read-only t)
(setq major-mode 'bookmark-bmenu-mode) (setq major-mode 'bookmark-bmenu-mode)
(setq mode-name "Bookmark Menu") (setq mode-name "Bookmark Menu")
(run-hooks 'bookmark-bmenu-mode-hook)) (run-mode-hooks 'bookmark-bmenu-mode-hook))
(defun bookmark-bmenu-toggle-filenames (&optional show) (defun bookmark-bmenu-toggle-filenames (&optional show)

View file

@ -656,7 +656,7 @@ to show always.
truncate-lines t truncate-lines t
font-lock-defaults '(bs-mode-font-lock-keywords t) font-lock-defaults '(bs-mode-font-lock-keywords t)
font-lock-verbose nil) font-lock-verbose nil)
(run-hooks 'bs-mode-hook)) (run-mode-hooks 'bs-mode-hook))
(defun bs-kill () (defun bs-kill ()
"Let buffer disappear and reset window-configuration." "Let buffer disappear and reset window-configuration."

View file

@ -947,6 +947,9 @@ in Calc algebraic input.")
first nil)) first nil))
x)) x))
;; calc-arg-values is defined in calc-ext.el, but is used here.
(defvar calc-arg-values)
(defun calc-check-user-syntax (&optional x prec) (defun calc-check-user-syntax (&optional x prec)
(let ((p calc-user-parse-table) (let ((p calc-user-parse-table)
(matches nil) (matches nil)

View file

@ -192,8 +192,15 @@
(defvar calc-embed-top) (defvar calc-embed-top)
(defvar calc-embed-bot) (defvar calc-embed-bot)
;; The variable calc-embed-arg is local to calc-do-embedded,
;; calc-embedded-update-formula, calc-embedded-edit and
;; calc-do-embedded-activate, but is used by
;; calc-embedded-make-info, which is called by the above
;; functions.
(defvar calc-embed-arg)
(defvar calc-embedded-quiet nil) (defvar calc-embedded-quiet nil)
(defun calc-do-embedded (arg end obeg oend) (defun calc-do-embedded (calc-embed-arg end obeg oend)
(if calc-embedded-info (if calc-embedded-info
;; Turn embedded mode off or switch to a new buffer. ;; Turn embedded mode off or switch to a new buffer.
@ -237,7 +244,7 @@
(buffer-name))) (buffer-name)))
(keyboard-quit)) (keyboard-quit))
(calc-embedded nil))) (calc-embedded nil)))
(calc-embedded arg end obeg oend))) (calc-embedded calc-embed-arg end obeg oend)))
;; Turn embedded mode on. ;; Turn embedded mode on.
(calc-plain-buffer-only) (calc-plain-buffer-only)
@ -250,7 +257,8 @@
(calc-embedded-save-original-modes) (calc-embedded-save-original-modes)
(or calc-embedded-globals (or calc-embedded-globals
(calc-find-globals)) (calc-find-globals))
(setq info (calc-embedded-make-info (point) nil t arg end obeg oend)) (setq info
(calc-embedded-make-info (point) nil t calc-embed-arg end obeg oend))
(if (eq (car-safe (aref info 8)) 'error) (if (eq (car-safe (aref info 8)) 'error)
(progn (progn
(setq calc-embedded-original-modes nil) (setq calc-embedded-original-modes nil)
@ -311,13 +319,13 @@
(calc-select-part 2))) (calc-select-part 2)))
(defun calc-embedded-update-formula (arg) (defun calc-embedded-update-formula (calc-embed-arg)
(interactive "P") (interactive "P")
(if arg (if calc-embed-arg
(let ((entry (assq (current-buffer) calc-embedded-active))) (let ((entry (assq (current-buffer) calc-embedded-active)))
(while (setq entry (cdr entry)) (while (setq entry (cdr entry))
(and (eq (car-safe (aref (car entry) 8)) 'calcFunc-evalto) (and (eq (car-safe (aref (car entry) 8)) 'calcFunc-evalto)
(or (not (consp arg)) (or (not (consp calc-embed-arg))
(and (<= (aref (car entry) 2) (region-beginning)) (and (<= (aref (car entry) 2) (region-beginning))
(>= (aref (car entry) 3) (region-end)))) (>= (aref (car entry) 3) (region-end))))
(save-excursion (save-excursion
@ -337,9 +345,9 @@
(goto-char (+ (aref info 4) pt)))))))) (goto-char (+ (aref info 4) pt))))))))
(defun calc-embedded-edit (arg) (defun calc-embedded-edit (calc-embed-arg)
(interactive "P") (interactive "P")
(let ((info (calc-embedded-make-info (point) nil t arg)) (let ((info (calc-embedded-make-info (point) nil t calc-embed-arg))
str) str)
(if (eq (car-safe (aref info 8)) 'error) (if (eq (car-safe (aref info 8)) 'error)
(progn (progn
@ -374,12 +382,12 @@
(aset info 8 val) (aset info 8 val)
(calc-embedded-update info 14 t t)))) (calc-embedded-update info 14 t t))))
(defun calc-do-embedded-activate (arg cbuf) (defun calc-do-embedded-activate (calc-embed-arg cbuf)
(calc-plain-buffer-only) (calc-plain-buffer-only)
(if arg (if calc-embed-arg
(calc-embedded-forget)) (calc-embedded-forget))
(calc-find-globals) (calc-find-globals)
(if (< (prefix-numeric-value arg) 0) (if (< (prefix-numeric-value calc-embed-arg) 0)
(message "Deactivating %s for Calc Embedded mode" (buffer-name)) (message "Deactivating %s for Calc Embedded mode" (buffer-name))
(message "Activating %s for Calc Embedded mode..." (buffer-name)) (message "Activating %s for Calc Embedded mode..." (buffer-name))
(save-excursion (save-excursion
@ -432,7 +440,7 @@
(defun calc-embedded-word () (defun calc-embedded-word ()
(interactive) (interactive)
(calc-embedded '(4))) (calc-embedded '(t)))
(defun calc-embedded-mark-formula (&optional body-only) (defun calc-embedded-mark-formula (&optional body-only)
"Put point at the beginning of this Calc formula, mark at the end. "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."
(aset info 1 (or cbuf (save-excursion (aset info 1 (or cbuf (save-excursion
(calc-create-buffer) (calc-create-buffer)
(current-buffer))))) (current-buffer)))))
(if (and (integerp calc-embed-top) (not calc-embed-bot)) (if (and
(or (integerp calc-embed-top) (equal calc-embed-top '(4)))
(not calc-embed-bot))
; started with a user-supplied argument ; started with a user-supplied argument
(progn (progn
(if (= (setq arg (prefix-numeric-value arg)) 0) (if (equal calc-embed-top '(4))
(progn (progn
(aset info 2 (copy-marker (region-beginning))) (aset info 2 (copy-marker (line-beginning-position)))
(aset info 3 (copy-marker (region-end)))) (aset info 3 (copy-marker (line-end-position))))
(aset info (if (> arg 0) 2 3) (point-marker)) (if (= (setq calc-embed-arg (prefix-numeric-value calc-embed-arg)) 0)
(forward-line arg) (progn
(aset info (if (> arg 0) 3 2) (point-marker))) (aset info 2 (copy-marker (region-beginning)))
(aset info 3 (copy-marker (region-end))))
(aset info (if (> calc-embed-arg 0) 2 3) (point-marker))
(if (> calc-embed-arg 0)
(progn
(forward-line (1- calc-embed-arg))
(end-of-line))
(forward-line (1+ calc-embed-arg)))
(aset info (if (> calc-embed-arg 0) 3 2) (point-marker))))
(aset info 4 (copy-marker (aref info 2))) (aset info 4 (copy-marker (aref info 2)))
(aset info 5 (copy-marker (aref info 3)))) (aset info 5 (copy-marker (aref info 3))))
(if (aref info 4) (if (aref info 4)

View file

@ -43,6 +43,9 @@
(defvar math-comp-sel-cpos nil) (defvar math-comp-sel-cpos nil)
(defvar math-compose-hash-args nil) (defvar math-compose-hash-args nil)
(defvar calc-alg-map)
(defvar calc-alg-esc-map)
;;; The following was made a function so that it could be byte-compiled. ;;; The following was made a function so that it could be byte-compiled.
(defun calc-init-extensions () (defun calc-init-extensions ()
@ -1192,8 +1195,9 @@ calc-kill calc-kill-region calc-yank))))
(math-normalize val))))) (math-normalize val)))))
(defvar calc-help-map nil)
(if (boundp 'calc-help-map) (if calc-help-map
nil nil
(setq calc-help-map (make-keymap)) (setq calc-help-map (make-keymap))
(define-key calc-help-map "b" 'calc-describe-bindings) (define-key calc-help-map "b" 'calc-describe-bindings)

View file

@ -160,7 +160,7 @@ Calc user interface as before (either M-# C or M-# K; initially M-# C)."
"Go to a node in the Calculator info documentation." "Go to a node in the Calculator info documentation."
(interactive) (interactive)
(select-window (get-largest-window)) (select-window (get-largest-window))
(Info-goto-node (concat "(Calc)" node))) (info (concat "(Calc)" node)))
(defun calc-tutorial () (defun calc-tutorial ()
"Run the Emacs Info system on the Calculator Tutorial." "Run the Emacs Info system on the Calculator Tutorial."

View file

@ -702,7 +702,7 @@
(get func 'calc-user-defn))) (get func 'calc-user-defn)))
(kys (concat "z" (char-to-string (car def)))) (kys (concat "z" (char-to-string (car def))))
(intcmd (symbol-name (cdr def))) (intcmd (symbol-name (cdr def)))
(algcmd (substring (symbol-name func) 9))) (algcmd (if func (substring (symbol-name func) 9) "")))
(if (and defn (calc-valid-formula-func func)) (if (and defn (calc-valid-formula-func func))
(let ((niceexpr (math-format-nice-expr defn (frame-width)))) (let ((niceexpr (math-format-nice-expr defn (frame-width))))
(calc-wrapper (calc-wrapper
@ -1446,15 +1446,22 @@ Redefine the corresponding command."
(error "Unbalanced Z' in keyboard macro"))) (error "Unbalanced Z' in keyboard macro")))
(defun calc-kbd-report (msg) ;; (defun calc-kbd-report (msg)
(interactive "sMessage: ") ;; (interactive "sMessage: ")
(calc-wrapper ;; (calc-wrapper
(math-working msg (calc-top-n 1)))) ;; (math-working msg (calc-top-n 1))))
(defun calc-kbd-query (msg) (defun calc-kbd-query ()
(interactive "sPrompt: ") (interactive)
(calc-wrapper (let ((defining-kbd-macro nil)
(calc-alg-entry nil (and (not (equal msg "")) msg)))) (executing-kbd-macro nil)
(msg (calc-top 1)))
(if (not (eq (car-safe msg) 'vec))
(error "No prompt string provided")
(setq msg (math-vector-to-string msg))
(calc-wrapper
(calc-pop-stack 1)
(calc-alg-entry nil (and (not (equal msg "")) msg))))))
;;;; Logical operations. ;;;; Logical operations.

View file

@ -171,6 +171,7 @@ With a prefix, push that prefix as a number onto the stack."
(defvar math-max-digits-cache) ; calc-bin.el (defvar math-max-digits-cache) ; calc-bin.el
(defvar math-integral-cache) ; calcalg2.el (defvar math-integral-cache) ; calcalg2.el
(defvar math-units-table) ; calc-units.el (defvar math-units-table) ; calc-units.el
(defvar math-decls-cache-tag) ; calc-arith.el
(defvar math-format-date-cache) ; calc-forms.el (defvar math-format-date-cache) ; calc-forms.el
(defvar math-holidays-cache-tag) ; calc-forms.el (defvar math-holidays-cache-tag) ; calc-forms.el

View file

@ -447,7 +447,7 @@ To cancel the edit, simply kill the *Calc Edit* buffer."
(setq truncate-lines nil) (setq truncate-lines nil)
(setq major-mode 'calc-edit-mode) (setq major-mode 'calc-edit-mode)
(setq mode-name "Calc Edit") (setq mode-name "Calc Edit")
(run-hooks 'calc-edit-mode-hook) (run-mode-hooks 'calc-edit-mode-hook)
(make-local-variable 'calc-original-buffer) (make-local-variable 'calc-original-buffer)
(setq calc-original-buffer oldbuf) (setq calc-original-buffer oldbuf)
(make-local-variable 'calc-return-buffer) (make-local-variable 'calc-return-buffer)

View file

@ -209,7 +209,8 @@
(defgroup calc nil (defgroup calc nil
"GNU Calc" "GNU Calc"
:prefix "calc-" :prefix "calc-"
:tag "Calc") :tag "Calc"
:group 'applications)
;;;###autoload ;;;###autoload
(defcustom calc-settings-file (defcustom calc-settings-file
@ -324,7 +325,7 @@ This is not required to be present for user-written mode annotations."
:type '(choice (string) (sexp))) :type '(choice (string) (sexp)))
(defvar calc-bug-address "belanger@truman.edu" (defvar calc-bug-address "belanger@truman.edu"
"Address of the author of Calc, for use by `report-calc-bug'.") "Address of the maintainer of Calc, for use by `report-calc-bug'.")
(defvar calc-scan-for-dels t (defvar calc-scan-for-dels t
"If t, scan keymaps to find all DEL-like keys. "If t, scan keymaps to find all DEL-like keys.
@ -719,6 +720,12 @@ If nil, selections displayed but ignored.")
(defvar calc-load-hook nil (defvar calc-load-hook nil
"Hook run when calc.el is loaded.") "Hook run when calc.el is loaded.")
(defvar calc-window-hook nil
"Hook called to create the Calc window.")
(defvar calc-trail-window-hook nil
"Hook called to create the Calc trail window.")
;; Verify that Calc is running on the right kind of system. ;; Verify that Calc is running on the right kind of system.
(defvar calc-emacs-type-lucid (not (not (string-match "Lucid" emacs-version)))) (defvar calc-emacs-type-lucid (not (not (string-match "Lucid" emacs-version))))
@ -830,20 +837,6 @@ If nil, selections displayed but ignored.")
(defvar var-gamma '(special-const (math-gamma-const))) (defvar var-gamma '(special-const (math-gamma-const)))
(defvar var-Modes '(special-const (math-get-modes-vec))) (defvar var-Modes '(special-const (math-get-modes-vec)))
(defvar calc-language-alist
'((latex-mode . latex)
(tex-mode . tex)
(plain-tex-mode . tex)
(context-mode . tex)
(nroff-mode . eqn)
(pascal-mode . pascal)
(c-mode . c)
(c++-mode . c)
(fortran-mode . fortran)
(f90-mode . fortran))
"Alist of major modes with appropriate Calc languages.")
(mapcar (lambda (v) (or (boundp v) (set v nil))) (mapcar (lambda (v) (or (boundp v) (set v nil)))
calc-local-var-list) calc-local-var-list)
@ -1066,7 +1059,7 @@ If nil, selections displayed but ignored.")
(use-global-map glob) (use-global-map glob)
(use-local-map loc))))) (use-local-map loc)))))
(defvar calc-alg-map) ; Defined in calc-ext.el
(defun calc-mode () (defun calc-mode ()
"Calculator major mode. "Calculator major mode.
@ -1131,7 +1124,7 @@ Notations: 3.14e6 3.14 * 10^6
(string-match "full" (nth 1 p)) (string-match "full" (nth 1 p))
(setq calc-standalone-flag t)) (setq calc-standalone-flag t))
(setq p (cdr p)))) (setq p (cdr p))))
(run-hooks 'calc-mode-hook) (run-mode-hooks 'calc-mode-hook)
(calc-refresh t) (calc-refresh t)
(calc-set-mode-line) (calc-set-mode-line)
(calc-check-defines)) (calc-check-defines))
@ -1181,7 +1174,7 @@ commands given here will actually operate on the *Calculator* stack."
(insert (propertize (concat "Emacs Calculator v" calc-version (insert (propertize (concat "Emacs Calculator v" calc-version
" by Dave Gillespie\n") " by Dave Gillespie\n")
'font-lock-face 'italic)))) 'font-lock-face 'italic))))
(run-hooks 'calc-trail-mode-hook)) (run-mode-hooks 'calc-trail-mode-hook))
(defun calc-create-buffer () (defun calc-create-buffer ()
(set-buffer (get-buffer-create "*Calculator*")) (set-buffer (get-buffer-create "*Calculator*"))
@ -1218,18 +1211,20 @@ commands given here will actually operate on the *Calculator* stack."
(switch-to-buffer (current-buffer) t) (switch-to-buffer (current-buffer) t)
(if (get-buffer-window (current-buffer)) (if (get-buffer-window (current-buffer))
(select-window (get-buffer-window (current-buffer))) (select-window (get-buffer-window (current-buffer)))
(let ((w (get-largest-window))) (if calc-window-hook
(if (and pop-up-windows (run-hooks 'calc-window-hook)
(> (window-height w) (let ((w (get-largest-window)))
(+ window-min-height calc-window-height 2))) (if (and pop-up-windows
(progn (> (window-height w)
(setq w (split-window w (+ window-min-height calc-window-height 2)))
(- (window-height w) (progn
calc-window-height 2) (setq w (split-window w
nil)) (- (window-height w)
(set-window-buffer w (current-buffer)) calc-window-height 2)
(select-window w)) nil))
(pop-to-buffer (current-buffer)))))) (set-window-buffer w (current-buffer))
(select-window w))
(pop-to-buffer (current-buffer)))))))
(save-excursion (save-excursion
(set-buffer (calc-trail-buffer)) (set-buffer (calc-trail-buffer))
(and calc-display-trail (and calc-display-trail
@ -1836,15 +1831,17 @@ See calc-keypad for details."
(not (if flag (memq flag '(nil 0)) win))) (not (if flag (memq flag '(nil 0)) win)))
(if (null win) (if (null win)
(progn (progn
(let ((w (split-window nil (/ (* (window-width) 2) 3) t))) (if calc-trail-window-hook
(set-window-buffer w calc-trail-buffer)) (run-hooks 'calc-trail-window-hook)
(calc-wrapper (let ((w (split-window nil (/ (* (window-width) 2) 3) t)))
(setq overlay-arrow-string calc-trail-overlay (set-window-buffer w calc-trail-buffer)))
overlay-arrow-position calc-trail-pointer) (calc-wrapper
(or no-refresh (setq overlay-arrow-string calc-trail-overlay
(if interactive overlay-arrow-position calc-trail-pointer)
(calc-do-refresh) (or no-refresh
(calc-refresh)))))) (if interactive
(calc-do-refresh)
(calc-refresh))))))
(if win (if win
(progn (progn
(delete-window win) (delete-window win)
@ -3444,7 +3441,7 @@ Also looks for the equivalent TeX words, \\gets and \\evalto."
(defun calc-user-invocation () (defun calc-user-invocation ()
(interactive) (interactive)
(unless (stringp calc-invocation-macro) (unless calc-invocation-macro
(error "Use `Z I' inside Calc to define a `M-# Z' keyboard macro")) (error "Use `Z I' inside Calc to define a `M-# Z' keyboard macro"))
(execute-kbd-macro calc-invocation-macro nil)) (execute-kbd-macro calc-invocation-macro nil))

View file

@ -202,6 +202,8 @@
(defvar math-deriv-var) (defvar math-deriv-var)
(defvar math-deriv-total) (defvar math-deriv-total)
(defvar math-deriv-symb) (defvar math-deriv-symb)
(defvar math-decls-cache)
(defvar math-decls-all)
(defun math-derivative (expr) (defun math-derivative (expr)
(cond ((equal expr math-deriv-var) (cond ((equal expr math-deriv-var)

View file

@ -4,7 +4,7 @@
;; Author: Eli Barzilay <eli@barzilay.org> ;; Author: Eli Barzilay <eli@barzilay.org>
;; Keywords: tools, convenience ;; Keywords: tools, convenience
;; Time-stamp: <2002-07-13 01:14:35 eli> ;; Time-stamp: <26 May 2005, 14:32:34, Lute Kamstra, pijl>
;; This file is part of GNU Emacs. ;; This file is part of GNU Emacs.
@ -680,7 +680,7 @@ more information.
(setq major-mode 'calculator-mode) (setq major-mode 'calculator-mode)
(setq mode-name "Calculator") (setq mode-name "Calculator")
(use-local-map calculator-mode-map) (use-local-map calculator-mode-map)
(run-hooks 'calculator-mode-hook)) (run-mode-hooks 'calculator-mode-hook))
(eval-when-compile (require 'electric) (require 'ehelp)) (eval-when-compile (require 'electric) (require 'ehelp))

View file

@ -2335,6 +2335,7 @@ movement commands will not work correctly."
(propertize (substitute-command-keys (propertize (substitute-command-keys
"\\<calendar-mode-map>\\[scroll-calendar-left]") "\\<calendar-mode-map>\\[scroll-calendar-left]")
'help-echo "mouse-2: scroll left" 'help-echo "mouse-2: scroll left"
'mouse-face 'mode-line-highlight
'keymap (make-mode-line-mouse-map 'mouse-2 'keymap (make-mode-line-mouse-map 'mouse-2
'mouse-scroll-calendar-left)) 'mouse-scroll-calendar-left))
"Calendar" "Calendar"
@ -2343,12 +2344,14 @@ movement commands will not work correctly."
(substitute-command-keys (substitute-command-keys
"\\<calendar-mode-map>\\[calendar-goto-info-node] info") "\\<calendar-mode-map>\\[calendar-goto-info-node] info")
'help-echo "mouse-2: read Info on Calendar" 'help-echo "mouse-2: read Info on Calendar"
'mouse-face 'mode-line-highlight
'keymap (make-mode-line-mouse-map 'mouse-2 'calendar-goto-info-node)) 'keymap (make-mode-line-mouse-map 'mouse-2 'calendar-goto-info-node))
"/" "/"
(propertize (propertize
(substitute-command-keys (substitute-command-keys
"\\<calendar-mode-map>\\[calendar-other-month] other") "\\<calendar-mode-map>\\[calendar-other-month] other")
'help-echo "mouse-2: choose another month" 'help-echo "mouse-2: choose another month"
'mouse-face 'mode-line-highlight
'keymap (make-mode-line-mouse-map 'keymap (make-mode-line-mouse-map
'mouse-2 'mouse-calendar-other-month)) 'mouse-2 'mouse-calendar-other-month))
"/" "/"
@ -2356,11 +2359,13 @@ movement commands will not work correctly."
(substitute-command-keys (substitute-command-keys
"\\<calendar-mode-map>\\[calendar-goto-today] today") "\\<calendar-mode-map>\\[calendar-goto-today] today")
'help-echo "mouse-2: go to today's date" 'help-echo "mouse-2: go to today's date"
'mouse-face 'mode-line-highlight
'keymap (make-mode-line-mouse-map 'mouse-2 #'calendar-goto-today))) 'keymap (make-mode-line-mouse-map 'mouse-2 #'calendar-goto-today)))
'(calendar-date-string (calendar-current-date) t) '(calendar-date-string (calendar-current-date) t)
(propertize (substitute-command-keys (propertize (substitute-command-keys
"\\<calendar-mode-map>\\[scroll-calendar-right]") "\\<calendar-mode-map>\\[scroll-calendar-right]")
'help-echo "mouse-2: scroll right" 'help-echo "mouse-2: scroll right"
'mouse-face 'mode-line-highlight
'keymap (make-mode-line-mouse-map 'keymap (make-mode-line-mouse-map
'mouse-2 'mouse-scroll-calendar-right))) 'mouse-2 'mouse-scroll-calendar-right)))
"The mode line of the calendar buffer. "The mode line of the calendar buffer.

View file

@ -1050,15 +1050,16 @@ changing the variable `diary-include-string'."
(regexp-quote diary-include-string) (regexp-quote diary-include-string)
" \"\\([^\"]*\\)\"") " \"\\([^\"]*\\)\"")
nil t) nil t)
(let ((diary-file (substitute-in-file-name (let* ((diary-file (substitute-in-file-name
(buffer-substring-no-properties (match-string-no-properties 2)))
(match-beginning 2) (match-end 2)))) (mark-diary-entries-hook 'mark-included-diary-files)
(mark-diary-entries-hook 'mark-included-diary-files)) (dbuff (find-buffer-visiting diary-file)))
(if (file-exists-p diary-file) (if (file-exists-p diary-file)
(if (file-readable-p diary-file) (if (file-readable-p diary-file)
(progn (progn
(mark-diary-entries) (mark-diary-entries)
(kill-buffer (find-buffer-visiting diary-file))) (unless dbuff
(kill-buffer (find-buffer-visiting diary-file))))
(beep) (beep)
(message "Can't read included diary file %s" diary-file) (message "Can't read included diary file %s" diary-file)
(sleep-for 2)) (sleep-for 2))

View file

@ -165,7 +165,6 @@ replaced by the organizer."
;; all the other libs we need ;; all the other libs we need
;; ====================================================================== ;; ======================================================================
(require 'calendar) (require 'calendar)
(require 'appt)
;; ====================================================================== ;; ======================================================================
;; misc ;; misc

View file

@ -904,11 +904,12 @@ Number of entries for each category is given by `todo-print-priorities'."
\\{todo-mode-map}" \\{todo-mode-map}"
(interactive) (interactive)
(kill-all-local-variables)
(setq major-mode 'todo-mode) (setq major-mode 'todo-mode)
(setq mode-name "TODO") (setq mode-name "TODO")
(use-local-map todo-mode-map) (use-local-map todo-mode-map)
(easy-menu-add todo-menu) (easy-menu-add todo-menu)
(run-hooks 'todo-mode-hook)) (run-mode-hooks 'todo-mode-hook))
(eval-when-compile (eval-when-compile
(defvar date) (defvar date)

View file

@ -145,7 +145,7 @@ Keybindings:
(setq major-mode 'command-history-mode) (setq major-mode 'command-history-mode)
(setq mode-name "Command History") (setq mode-name "Command History")
(use-local-map command-history-map) (use-local-map command-history-map)
(run-hooks 'command-history-mode-hook)) (run-mode-hooks 'command-history-mode-hook))
(defun Command-history-setup () (defun Command-history-setup ()
(kill-all-local-variables) (kill-all-local-variables)

View file

@ -3437,7 +3437,7 @@ REGEXP-GROUP is the regular expression group in REGEXP to use."
;; (make-local-variable 'shell-directory-stack) ;; (make-local-variable 'shell-directory-stack)
;; (setq shell-directory-stack nil) ;; (setq shell-directory-stack nil)
;; (add-hook 'comint-input-filter-functions 'shell-directory-tracker) ;; (add-hook 'comint-input-filter-functions 'shell-directory-tracker)
;; (run-hooks 'shell-mode-hook)) ;; (run-mode-hooks 'shell-mode-hook))
;; ;;
;; ;;
;; Completion for comint-mode users ;; Completion for comint-mode users

View file

@ -4276,7 +4276,7 @@ if that value is non-nil."
(set (make-local-variable 'widget-link-prefix) "") (set (make-local-variable 'widget-link-prefix) "")
(set (make-local-variable 'widget-link-suffix) "")) (set (make-local-variable 'widget-link-suffix) ""))
(add-hook 'widget-edit-functions 'custom-state-buffer-message nil t) (add-hook 'widget-edit-functions 'custom-state-buffer-message nil t)
(run-hooks 'custom-mode-hook)) (run-mode-hooks 'custom-mode-hook))
(put 'custom-mode 'mode-class 'special) (put 'custom-mode 'mode-class 'special)

View file

@ -61,7 +61,7 @@ if that value is non-nil."
(use-local-map describe-text-mode-map) (use-local-map describe-text-mode-map)
(widget-setup) (widget-setup)
(add-hook 'change-major-mode-hook 'font-lock-defontify nil t) (add-hook 'change-major-mode-hook 'font-lock-defontify nil t)
(run-hooks 'describe-text-mode-hook)) (run-mode-hooks 'describe-text-mode-hook))
;;; Describe-Text Utilities. ;;; Describe-Text Utilities.

View file

@ -162,7 +162,7 @@ Entry to this mode via command `electric-buffer-list' calls the value of
(setq major-mode 'Electric-buffer-menu-mode) (setq major-mode 'Electric-buffer-menu-mode)
(goto-char (point-min)) (goto-char (point-min))
(if (search-forward "\n." nil t) (forward-char -1)) (if (search-forward "\n." nil t) (forward-char -1))
(run-hooks 'electric-buffer-menu-mode-hook)) (run-mode-hooks 'electric-buffer-menu-mode-hook))
;; generally the same as Buffer-menu-mode-map ;; generally the same as Buffer-menu-mode-map
;; (except we don't indirect to global-map) ;; (except we don't indirect to global-map)

View file

@ -1353,7 +1353,7 @@ Symlinks and the likes are not handled.
If FILTER-RE is non-nil, recursive checking in directories If FILTER-RE is non-nil, recursive checking in directories
affects only files whose names match the expression." affects only files whose names match the expression."
;; Normalize empty filter RE to nil. ;; Normalize empty filter RE to nil.
(unless (length filter-re) (setq filter-re nil)) (unless (> (length filter-re) 0) (setq filter-re nil))
;; Indicate progress ;; Indicate progress
(message "Comparing '%s' and '%s' modulo '%s'" d1 d2 filter-re) (message "Comparing '%s' and '%s' modulo '%s'" d1 d2 filter-re)
(cond (cond
@ -1367,27 +1367,11 @@ affects only files whose names match the expression."
(if (eq ediff-recurse-to-subdirectories 'yes) (if (eq ediff-recurse-to-subdirectories 'yes)
(let* ((all-entries-1 (directory-files d1 t filter-re)) (let* ((all-entries-1 (directory-files d1 t filter-re))
(all-entries-2 (directory-files d2 t filter-re)) (all-entries-2 (directory-files d2 t filter-re))
(entries-1 (remove-if (lambda (s) (entries-1 (ediff-delete-all-matches "^\\.\\.?$" all-entries-1))
(string-match "^\\.\\.?$" (entries-2 (ediff-delete-all-matches "^\\.\\.?$" all-entries-2))
(file-name-nondirectory s)))
all-entries-1))
(entries-2 (remove-if (lambda (s)
(string-match "^\\.\\.?$"
(file-name-nondirectory s)))
all-entries-2))
) )
;; First, check only the names (works quickly and ensures a
;; precondition for subsequent code) (ediff-same-file-contents-lists entries-1 entries-2 filter-re)
(if (and (= (length entries-1) (length entries-2))
(every (lambda (a b) (equal (file-name-nondirectory a)
(file-name-nondirectory b)))
entries-1 entries-2))
;; With name equality established, compare the entries
;; through recursion.
(every (lambda (a b)
(ediff-same-contents a b filter-re))
entries-1 entries-2)
)
)) ))
) ; end of the directories case ) ; end of the directories case
;; D1 & D2 are both files => compare directly ;; D1 & D2 are both files => compare directly
@ -1398,6 +1382,42 @@ affects only files whose names match the expression."
) )
) )
;; If lists have the same length and names of files are pairwise equal
;; (removing the directories) then compare contents pairwise.
;; True if all contents are the same; false otherwise
(defun ediff-same-file-contents-lists (entries-1 entries-2 filter-re)
;; First, check only the names (works quickly and ensures a
;; precondition for subsequent code)
(if (and (= (length entries-1) (length entries-2))
(equal (mapcar 'file-name-nondirectory entries-1)
(mapcar 'file-name-nondirectory entries-2)))
;; With name equality established, compare the entries
;; through recursion.
(let ((continue t))
(while (and entries-1 continue)
(if (ediff-same-contents
(car entries-1) (car entries-2) filter-re)
(setq entries-1 (cdr entries-1)
entries-2 (cdr entries-2))
(setq continue nil))
)
;; if reached the end then lists are equal
(null entries-1))
)
)
;; ARG1 is a regexp, ARG2 is a list of full-filenames
;; Delete all entries that match the regexp
(defun ediff-delete-all-matches (regex file-list-list)
(let (result elt)
(while file-list-list
(setq elt (car file-list-list))
(or (string-match regex (file-name-nondirectory elt))
(setq result (cons elt result)))
(setq file-list-list (cdr file-list-list)))
(reverse result)))
;;; Local Variables: ;;; Local Variables:
;;; eval: (put 'ediff-defvar-local 'lisp-indent-hook 'defun) ;;; eval: (put 'ediff-defvar-local 'lisp-indent-hook 'defun)

View file

@ -132,7 +132,7 @@ Normally, not a user option. See `ediff-help-message' for details.")
"Normally, not a user option. See `ediff-help-message' for details.") "Normally, not a user option. See `ediff-help-message' for details.")
(defconst ediff-brief-message-string (defconst ediff-brief-message-string
" ? -quick help " " Type ? for help"
"Contents of the brief help message.") "Contents of the brief help message.")
;; The actual brief help message ;; The actual brief help message
(ediff-defvar-local ediff-brief-help-message "" (ediff-defvar-local ediff-brief-help-message ""

View file

@ -560,17 +560,23 @@ behavior."
(ediff-add-slash-if-directory auxdir1 elt)) (ediff-add-slash-if-directory auxdir1 elt))
lis1) lis1)
auxdir2 (file-name-as-directory dir2) auxdir2 (file-name-as-directory dir2)
lis2 (directory-files auxdir2 nil regexp)
lis2 (delete "." lis2)
lis2 (delete ".." lis2)
lis2 (mapcar lis2 (mapcar
(lambda (elt) (lambda (elt)
(ediff-add-slash-if-directory auxdir2 elt)) (ediff-add-slash-if-directory auxdir2 elt))
(directory-files auxdir2 nil regexp))) lis2))
(if (stringp dir3) (if (stringp dir3)
(setq auxdir3 (file-name-as-directory dir3) (setq auxdir3 (file-name-as-directory dir3)
lis3 (directory-files auxdir3 nil regexp)
lis3 (delete "." lis3)
lis3 (delete ".." lis3)
lis3 (mapcar lis3 (mapcar
(lambda (elt) (lambda (elt)
(ediff-add-slash-if-directory auxdir3 elt)) (ediff-add-slash-if-directory auxdir3 elt))
(directory-files auxdir3 nil regexp)))) lis3)))
(if (ediff-nonempty-string-p merge-autostore-dir) (if (ediff-nonempty-string-p merge-autostore-dir)
(setq merge-autostore-dir (setq merge-autostore-dir

View file

@ -1,6 +1,7 @@
;;; ediff-util.el --- the core commands and utilities of ediff ;;; ediff-util.el --- the core commands and utilities of ediff
;; Copyright (C) 1994, 95, 96, 97, 98, 99, 2000, 01, 02, 04 Free Software Foundation, Inc. ;; Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
;; 2004 Free Software Foundation, Inc.
;; Author: Michael Kifer <kifer@cs.stonybrook.edu> ;; Author: Michael Kifer <kifer@cs.stonybrook.edu>

View file

@ -7,7 +7,7 @@
;; Keywords: comparing, merging, patching, tools, unix ;; Keywords: comparing, merging, patching, tools, unix
(defconst ediff-version "2.80" "The current version of Ediff") (defconst ediff-version "2.80" "The current version of Ediff")
(defconst ediff-date "February 19, 2005" "Date of last update") (defconst ediff-date "June 3, 2005" "Date of last update")
;; This file is part of GNU Emacs. ;; This file is part of GNU Emacs.

View file

@ -1248,15 +1248,15 @@ extra args."
(defun byte-compile-nogroup-warn (form) (defun byte-compile-nogroup-warn (form)
(let ((keyword-args (cdr (cdr (cdr (cdr form))))) (let ((keyword-args (cdr (cdr (cdr (cdr form)))))
(name (cadr form))) (name (cadr form)))
(unless (plist-get keyword-args :group) (or (plist-get keyword-args :group)
(byte-compile-warn (not (and (consp name) (eq (car name) 'quote)))
"%s for `%s' fails to specify containing group" (byte-compile-warn
(cdr (assq (car form) "%s for `%s' fails to specify containing group"
'((custom-declare-group . defgroup) (cdr (assq (car form)
(custom-declare-face . defface) '((custom-declare-group . defgroup)
(custom-declare-variable . defcustom)))) (custom-declare-face . defface)
(if (and (consp name) (eq (car name) 'quote)) (custom-declare-variable . defcustom))))
(cadr name) name))))) (cadr name)))))
;; Warn if the function or macro is being redefined with a different ;; Warn if the function or macro is being redefined with a different
;; number of arguments. ;; number of arguments.

View file

@ -1565,14 +1565,21 @@ form. See `defsetf' for a simpler way to define most setf-methods.
This macro is an easy-to-use substitute for `define-setf-method' that works This macro is an easy-to-use substitute for `define-setf-method' that works
well for simple place forms. In the simple `defsetf' form, `setf's of well for simple place forms. In the simple `defsetf' form, `setf's of
the form (setf (NAME ARGS...) VAL) are transformed to function or macro the form (setf (NAME ARGS...) VAL) are transformed to function or macro
calls of the form (FUNC ARGS... VAL). Example: (defsetf aref aset). calls of the form (FUNC ARGS... VAL). Example:
(defsetf aref aset)
Alternate form: (defsetf NAME ARGLIST (STORE) BODY...). Alternate form: (defsetf NAME ARGLIST (STORE) BODY...).
Here, the above `setf' call is expanded by binding the argument forms ARGS Here, the above `setf' call is expanded by binding the argument forms ARGS
according to ARGLIST, binding the value form VAL to STORE, then executing according to ARGLIST, binding the value form VAL to STORE, then executing
BODY, which must return a Lisp form that does the necessary `setf' operation. BODY, which must return a Lisp form that does the necessary `setf' operation.
Actually, ARGLIST and STORE may be bound to temporary variables which are Actually, ARGLIST and STORE may be bound to temporary variables which are
introduced automatically to preserve proper execution order of the arguments. introduced automatically to preserve proper execution order of the arguments.
Example: (defsetf nth (n x) (v) (list 'setcar (list 'nthcdr n x) v))." Example:
(defsetf nth (n x) (v) (list 'setcar (list 'nthcdr n x) v))
\(fn NAME [FUNC | ARGLIST (STORE) BODY...])"
(if (listp arg1) (if (listp arg1)
(let* ((largs nil) (largsr nil) (let* ((largs nil) (largsr nil)
(temps nil) (tempsr nil) (temps nil) (tempsr nil)

View file

@ -271,14 +271,26 @@ With zero or negative ARG turn mode off.
TURN-ON is a function that will be called with no args in every buffer TURN-ON is a function that will be called with no args in every buffer
and that should try to turn MODE on if applicable for that buffer. and that should try to turn MODE on if applicable for that buffer.
KEYS is a list of CL-style keyword arguments: KEYS is a list of CL-style keyword arguments:
:group to specify the custom group." :group to specify the custom group.
If MODE's set-up depends on the major mode in effect when it was
enabled, then disabling and reenabling MODE should make MODE work
correctly with the current major mode. This is important to
prevent problems with derived modes, that is, major modes that
call another major mode in their body."
(let* ((global-mode-name (symbol-name global-mode)) (let* ((global-mode-name (symbol-name global-mode))
(pretty-name (easy-mmode-pretty-mode-name mode)) (pretty-name (easy-mmode-pretty-mode-name mode))
(pretty-global-name (easy-mmode-pretty-mode-name global-mode)) (pretty-global-name (easy-mmode-pretty-mode-name global-mode))
(group nil) (group nil)
(extra-args nil) (extra-args nil)
(buffers (intern (concat global-mode-name "-buffers"))) (MODE-buffers (intern (concat global-mode-name "-buffers")))
(cmmh (intern (concat global-mode-name "-cmmh")))) (MODE-enable-in-buffers
(intern (concat global-mode-name "-enable-in-buffers")))
(MODE-check-buffers
(intern (concat global-mode-name "-check-buffers")))
(MODE-cmhh (intern (concat global-mode-name "-cmhh")))
(MODE-major-mode (intern (concat (symbol-name mode) "-major-mode"))))
;; Check keys. ;; Check keys.
(while (keywordp (car keys)) (while (keywordp (car keys))
@ -294,6 +306,8 @@ KEYS is a list of CL-style keyword arguments:
"-mode\\'" "" (symbol-name mode)))))) "-mode\\'" "" (symbol-name mode))))))
`(progn `(progn
(defvar ,MODE-major-mode nil)
(make-variable-buffer-local ',MODE-major-mode)
;; The actual global minor-mode ;; The actual global minor-mode
(define-minor-mode ,global-mode (define-minor-mode ,global-mode
,(format "Toggle %s in every buffer. ,(format "Toggle %s in every buffer.
@ -306,10 +320,13 @@ in which `%s' turns it on."
;; Setup hook to handle future mode changes and new buffers. ;; Setup hook to handle future mode changes and new buffers.
(if ,global-mode (if ,global-mode
(progn (progn
(add-hook 'after-change-major-mode-hook ',buffers) (add-hook 'after-change-major-mode-hook
(add-hook 'change-major-mode-hook ',cmmh)) ',MODE-enable-in-buffers)
(remove-hook 'after-change-major-mode-hook ',buffers) (add-hook 'find-file-hook ',MODE-check-buffers)
(remove-hook 'change-major-mode-hook ',cmmh)) (add-hook 'change-major-mode-hook ',MODE-cmhh))
(remove-hook 'after-change-major-mode-hook ',MODE-enable-in-buffers)
(remove-hook 'find-file-hook ',MODE-check-buffers)
(remove-hook 'change-major-mode-hook ',MODE-cmhh))
;; Go through existing buffers. ;; Go through existing buffers.
(dolist (buf (buffer-list)) (dolist (buf (buffer-list))
@ -321,22 +338,33 @@ in which `%s' turns it on."
:autoload-end :autoload-end
;; List of buffers left to process. ;; List of buffers left to process.
(defvar ,buffers nil) (defvar ,MODE-buffers nil)
;; The function that calls TURN-ON in each buffer. ;; The function that calls TURN-ON in each buffer.
(defun ,buffers () (defun ,MODE-enable-in-buffers ()
(remove-hook 'post-command-hook ',buffers) (dolist (buf ,MODE-buffers)
(while ,buffers (when (buffer-live-p buf)
(let ((buf (pop ,buffers))) (with-current-buffer buf
(when (buffer-live-p buf) (if ,mode
(with-current-buffer buf (,turn-on)))))) (unless (eq ,MODE-major-mode major-mode)
(put ',buffers 'definition-name ',global-mode) (,mode -1)
(,turn-on)
(setq ,MODE-major-mode major-mode))
(,turn-on)
(setq ,MODE-major-mode major-mode))))))
(put ',MODE-enable-in-buffers 'definition-name ',global-mode)
(defun ,MODE-check-buffers ()
(,MODE-enable-in-buffers)
(setq ,MODE-buffers nil)
(remove-hook 'post-command-hook ',MODE-check-buffers))
(put ',MODE-check-buffers 'definition-name ',global-mode)
;; The function that catches kill-all-local-variables. ;; The function that catches kill-all-local-variables.
(defun ,cmmh () (defun ,MODE-cmhh ()
(add-to-list ',buffers (current-buffer)) (add-to-list ',MODE-buffers (current-buffer))
(add-hook 'post-command-hook ',buffers)) (add-hook 'post-command-hook ',MODE-check-buffers))
(put ',cmmh 'definition-name ',global-mode)))) (put ',MODE-cmhh 'definition-name ',global-mode))))
;;; ;;;
;;; easy-mmode-defmap ;;; easy-mmode-defmap

View file

@ -1,6 +1,7 @@
;;; easymenu.el --- support the easymenu interface for defining a menu ;;; easymenu.el --- support the easymenu interface for defining a menu
;; Copyright (C) 1994,96,98,1999,2000,2004 Free Software Foundation, Inc. ;; Copyright (C) 1994, 1996, 1998, 1999, 2000, 2004, 2005
;; Free Software Foundation, Inc.
;; Keywords: emulations ;; Keywords: emulations
;; Author: Richard Stallman <rms@gnu.org> ;; Author: Richard Stallman <rms@gnu.org>
@ -534,7 +535,7 @@ earlier by `easy-menu-define' or `easy-menu-create-menu'."
(easy-menu-do-add-item map item before))) (easy-menu-do-add-item map item before)))
(defun easy-menu-item-present-p (map path name) (defun easy-menu-item-present-p (map path name)
"In submenu of MAP with path PATH, return true iff item NAME is present. "In submenu of MAP with path PATH, return non-nil iff item NAME is present.
MAP and PATH are defined as in `easy-menu-add-item'. MAP and PATH are defined as in `easy-menu-add-item'.
NAME should be a string, the name of the element to be looked for." NAME should be a string, the name of the element to be looked for."
(easy-menu-return-item (easy-menu-get-map map path) name)) (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."
"In menu MENU try to look for menu item with name NAME. "In menu MENU try to look for menu item with name NAME.
If a menu item is found, return (NAME . item), otherwise return nil. If a menu item is found, return (NAME . item), otherwise return nil.
If item is an old format item, a new format item is returned." If item is an old format item, a new format item is returned."
(let ((item (lookup-key menu (vector (easy-menu-intern name)))) ;; The call to `lookup-key' also calls the C function `get_keyelt' which
;; looks inside a menu-item to only return the actual command. This is
;; not what we want here. We should either add an arg to lookup-key to be
;; able to turn off this "feature", or else we could use map-keymap here.
;; In the mean time, I just use `assq' which is an OK approximation since
;; menus are rarely built from vectors or char-tables.
(let ((item (or (cdr (assq name menu))
(lookup-key menu (vector (easy-menu-intern name)))))
ret enable cache label) ret enable cache label)
(cond (cond
((stringp (car-safe item)) ((stringp (car-safe item))

View file

@ -246,8 +246,6 @@ searched for in `find-function-source-path' if non nil, otherwise
in `load-path'." in `load-path'."
(if (not function) (if (not function)
(error "You didn't specify a function")) (error "You didn't specify a function"))
(and (subrp (symbol-function function))
(error "%s is a primitive function" function))
(let ((def (symbol-function function)) (let ((def (symbol-function function))
aliases) aliases)
(while (symbolp def) (while (symbolp def)
@ -265,6 +263,8 @@ in `load-path'."
(let ((library (let ((library
(cond ((eq (car-safe def) 'autoload) (cond ((eq (car-safe def) 'autoload)
(nth 1 def)) (nth 1 def))
((subrp def)
(help-C-file-name def 'subr))
((symbol-file function 'defun))))) ((symbol-file function 'defun)))))
(find-function-search-for-symbol function nil library)))) (find-function-search-for-symbol function nil library))))

View file

@ -254,7 +254,7 @@ Except for Lisp syntax this is the same as `reb-regexp'.")
mode-name "RE Builder") mode-name "RE Builder")
(use-local-map reb-mode-map) (use-local-map reb-mode-map)
(reb-mode-common) (reb-mode-common)
(run-hooks 'reb-mode-hook)) (run-mode-hooks 'reb-mode-hook))
(define-derived-mode reb-lisp-mode (define-derived-mode reb-lisp-mode
emacs-lisp-mode "RE Builder Lisp" emacs-lisp-mode "RE Builder Lisp"

View file

@ -375,7 +375,7 @@
;;; ;;;
;;; Load the newly defined keys and clean up ;;; Load the newly defined keys and clean up
;;; ;;;
(eval-current-buffer) (eval-buffer)
(kill-buffer (current-buffer)) (kill-buffer (current-buffer))
(kill-buffer "*scratch*") (kill-buffer "*scratch*")
(kill-buffer "Gold-Keys") (kill-buffer "Gold-Keys")

View file

@ -403,7 +403,7 @@ form that is ready to be `apply'ed.")
(make-local-variable 'vi-mode-old-mode-name) (make-local-variable 'vi-mode-old-mode-name)
(make-local-variable 'vi-mode-old-major-mode) (make-local-variable 'vi-mode-old-major-mode)
(make-local-variable 'vi-mode-old-case-fold) (make-local-variable 'vi-mode-old-case-fold)
(run-hooks 'vi-mode-hook)) (run-mode-hooks 'vi-mode-hook))
;;;###autoload ;;;###autoload
(defun vi-mode () (defun vi-mode ()

View file

@ -50,16 +50,25 @@
;;; Variables ;;; Variables
(defvar viper-toggle-key "\C-z" (defcustom viper-toggle-key "\C-z"
"The key used to change states from emacs to Vi and back. "The key used to change states from emacs to Vi and back.
In insert mode, this key also functions as Meta. In insert mode, this key also functions as Meta.
Must be set in .viper file or prior to loading Viper. Must be set in .viper file or prior to loading Viper.
This setting cannot be changed interactively.") This setting cannot be changed interactively."
:type 'string
:group 'viper)
(defvar viper-ESC-key "\e" (defcustom viper-quoted-insert-key "\C-v"
"The key used to quote special characters when inserting them in Insert state."
:type 'string
:group 'viper)
(defcustom viper-ESC-key "\e"
"Key used to ESC. "Key used to ESC.
Must be set in .viper file or prior to loading Viper. Must be set in .viper file or prior to loading Viper.
This setting cannot be changed interactively.") This setting cannot be changed interactively."
:type 'string
:group 'viper)
;;; Emacs keys in other states. ;;; Emacs keys in other states.
@ -242,7 +251,7 @@ viper-insert-basic-map. Not recommended, except for novice users.")
(define-key viper-insert-basic-map "\C-t" 'viper-forward-indent) (define-key viper-insert-basic-map "\C-t" 'viper-forward-indent)
(define-key viper-insert-basic-map (define-key viper-insert-basic-map
(if viper-xemacs-p [(shift tab)] [S-tab]) 'viper-insert-tab) (if viper-xemacs-p [(shift tab)] [S-tab]) 'viper-insert-tab)
(define-key viper-insert-basic-map "\C-v" 'quoted-insert) (define-key viper-insert-basic-map viper-quoted-insert-key 'quoted-insert)
(define-key viper-insert-basic-map "\C-?" 'viper-del-backward-char-in-insert) (define-key viper-insert-basic-map "\C-?" 'viper-del-backward-char-in-insert)
(define-key viper-insert-basic-map [backspace] 'viper-del-backward-char-in-insert) (define-key viper-insert-basic-map [backspace] 'viper-del-backward-char-in-insert)
(define-key viper-insert-basic-map "\C-\\" 'viper-alternate-Meta-key) (define-key viper-insert-basic-map "\C-\\" 'viper-alternate-Meta-key)

View file

@ -990,12 +990,13 @@ remains buffer-local."
(setq global-mode-string (setq global-mode-string
(append '("" viper-mode-string) (cdr global-mode-string)))) (append '("" viper-mode-string) (cdr global-mode-string))))
(defadvice describe-key (before viper-read-keyseq-ad protect activate) (defadvice describe-key (before viper-describe-key-ad protect activate)
"Force to read key via `viper-read-key-sequence'." "Force to read key via `viper-read-key-sequence'."
(interactive (list (viper-read-key-sequence "Describe key: ")))) (interactive (list (viper-read-key-sequence "Describe key: "))
))
(defadvice describe-key-briefly (defadvice describe-key-briefly
(before viper-read-keyseq-ad protect activate) (before viper-describe-key-briefly-ad protect activate)
"Force to read key via `viper-read-key-sequence'." "Force to read key via `viper-read-key-sequence'."
(interactive (list (viper-read-key-sequence "Describe key briefly: ")))) (interactive (list (viper-read-key-sequence "Describe key briefly: "))))

View file

@ -294,7 +294,7 @@ The key bindings are:
(use-local-map wordstar-mode-map) (use-local-map wordstar-mode-map)
(setq mode-name "WordStar") (setq mode-name "WordStar")
(setq major-mode 'wordstar-mode) (setq major-mode 'wordstar-mode)
(run-hooks 'wordstar-mode-hook)) (run-mode-hooks 'wordstar-mode-hook))
(defun wordstar-center-paragraph () (defun wordstar-center-paragraph ()

View file

@ -136,8 +136,7 @@ to writing a completion function."
:type (get 'pcomplete-file-ignore 'custom-type) :type (get 'pcomplete-file-ignore 'custom-type)
:group 'eshell-cmpl) :group 'eshell-cmpl)
(defcustom eshell-cmpl-dir-ignore (defcustom eshell-cmpl-dir-ignore "\\`\\(\\.\\.?\\|CVS\\)/\\'"
(format "\\`\\(\\.\\.?\\|CVS\\)%c\\'" directory-sep-char)
(documentation-property 'pcomplete-dir-ignore (documentation-property 'pcomplete-dir-ignore
'variable-documentation) 'variable-documentation)
:type (get 'pcomplete-dir-ignore 'custom-type) :type (get 'pcomplete-dir-ignore 'custom-type)
@ -155,7 +154,7 @@ to writing a completion function."
:type (get 'pcomplete-autolist 'custom-type) :type (get 'pcomplete-autolist 'custom-type)
:group 'eshell-cmpl) :group 'eshell-cmpl)
(defcustom eshell-cmpl-suffix-list (list directory-sep-char ?:) (defcustom eshell-cmpl-suffix-list (list ?/ ?:)
(documentation-property 'pcomplete-suffix-list (documentation-property 'pcomplete-suffix-list
'variable-documentation) 'variable-documentation)
:type (get 'pcomplete-suffix-list 'custom-type) :type (get 'pcomplete-suffix-list 'custom-type)
@ -370,7 +369,8 @@ to writing a completion function."
(setq args (nthcdr (1+ l) args) (setq args (nthcdr (1+ l) args)
posns (nthcdr (1+ l) posns)))) posns (nthcdr (1+ l) posns))))
(assert (= (length args) (length posns))) (assert (= (length args) (length posns)))
(when (and args (eq (char-syntax (char-before end)) ? )) (when (and args (eq (char-syntax (char-before end)) ? )
(not (eq (char-before (1- end)) ?\\)))
(nconc args (list "")) (nconc args (list ""))
(nconc posns (list (point)))) (nconc posns (list (point))))
(cons (mapcar (cons (mapcar

View file

@ -276,8 +276,7 @@ Thus, this does not include the current directory.")
(let* ((letter (match-string 1)) (let* ((letter (match-string 1))
(regexp (concat "\\`" letter)) (regexp (concat "\\`" letter))
(path (eshell-find-previous-directory regexp))) (path (eshell-find-previous-directory regexp)))
(concat (or path letter) (concat (or path letter) "/"))))
(char-to-string directory-sep-char)))))
(defun eshell-complete-user-reference () (defun eshell-complete-user-reference ()
"If there is a user reference, complete it." "If there is a user reference, complete it."
@ -300,7 +299,7 @@ Thus, this does not include the current directory.")
(let* ((path default-directory) (let* ((path default-directory)
(len (length path))) (len (length path)))
(if (and (> len 1) (if (and (> len 1)
(eq (aref path (1- len)) directory-sep-char) (eq (aref path (1- len)) ?/)
(not (and (eshell-under-windows-p) (not (and (eshell-under-windows-p)
(string-match "\\`[A-Za-z]:[\\\\/]\\'" path)))) (string-match "\\`[A-Za-z]:[\\\\/]\\'" path))))
(setq path (substring path 0 (1- (length path))))) (setq path (substring path 0 (1- (length path)))))
@ -324,9 +323,7 @@ in the minibuffer:
(len (length extra-dots)) (len (length extra-dots))
replace-text) replace-text)
(while (> len 0) (while (> len 0)
(setq replace-text (setq replace-text (concat replace-text "/..")
(concat replace-text
(char-to-string directory-sep-char) "..")
len (1- len))) len (1- len)))
(setq path (setq path
(replace-match replace-text t t path 1)))) (replace-match replace-text t t path 1))))
@ -371,7 +368,7 @@ in the minibuffer:
(setq path (setq path
(ring-remove eshell-last-dir-ring (ring-remove eshell-last-dir-ring
(if index (if index
(string-to-int index) (string-to-number index)
0))))) 0)))))
((and path (string-match "^=\\(.*\\)$" path)) ((and path (string-match "^=\\(.*\\)$" path))
(let ((oldpath (eshell-find-previous-directory (let ((oldpath (eshell-find-previous-directory

View file

@ -265,9 +265,6 @@ the form:
(defvar matches) (defvar matches)
(defvar message-shown)) (defvar message-shown))
;; jww (1999-11-18): this function assumes that directory-sep-char is
;; a forward slash (/)
(defun eshell-glob-entries (path globs &optional recurse-p) (defun eshell-glob-entries (path globs &optional recurse-p)
"Glob the entries in PATHS, possibly recursing if RECURSE-P is non-nil." "Glob the entries in PATHS, possibly recursing if RECURSE-P is non-nil."
(let* ((entries (ignore-errors (let* ((entries (ignore-errors
@ -303,11 +300,11 @@ the form:
;; can't use `directory-file-name' because it strips away text ;; can't use `directory-file-name' because it strips away text
;; properties in the string ;; properties in the string
(let ((len (1- (length incl)))) (let ((len (1- (length incl))))
(if (eq (aref incl len) directory-sep-char) (if (eq (aref incl len) ?/)
(setq incl (substring incl 0 len))) (setq incl (substring incl 0 len)))
(when excl (when excl
(setq len (1- (length excl))) (setq len (1- (length excl)))
(if (eq (aref excl len) directory-sep-char) (if (eq (aref excl len) ?/)
(setq excl (substring excl 0 len))))) (setq excl (substring excl 0 len)))))
(setq incl (eshell-glob-regexp incl) (setq incl (eshell-glob-regexp incl)
excl (and excl (eshell-glob-regexp excl))) excl (and excl (eshell-glob-regexp excl)))
@ -329,7 +326,7 @@ the form:
(while entries (while entries
(setq name (car entries) (setq name (car entries)
len (length name) len (length name)
isdir (eq (aref name (1- len)) directory-sep-char)) isdir (eq (aref name (1- len)) ?/))
(if (let ((fname (directory-file-name name))) (if (let ((fname (directory-file-name name)))
(and (not (and excl (string-match excl fname))) (and (not (and excl (string-match excl fname)))
(string-match incl fname))) (string-match incl fname)))

View file

@ -877,7 +877,7 @@ Summarize disk usage of each FILE, recursively for directories.")
(unless by-bytes (unless by-bytes
(setq block-size (or block-size 1024))) (setq block-size (or block-size 1024)))
(if (and max-depth (stringp max-depth)) (if (and max-depth (stringp max-depth))
(setq max-depth (string-to-int max-depth))) (setq max-depth (string-to-number max-depth)))
;; filesystem support means nothing under Windows ;; filesystem support means nothing under Windows
(if (eshell-under-windows-p) (if (eshell-under-windows-p)
(setq only-one-filesystem nil)) (setq only-one-filesystem nil))

View file

@ -757,7 +757,7 @@ nil)' if none)."
(defmacro eshell-do-subjob (object) (defmacro eshell-do-subjob (object)
"Evaluate a command OBJECT as a subjob. "Evaluate a command OBJECT as a subjob.
We indicate thet the process was run in the background by returned it We indicate that the process was run in the background by returning it
ensconced in a list." ensconced in a list."
`(let ((eshell-current-subjob-p t)) `(let ((eshell-current-subjob-p t))
,object)) ,object))
@ -1006,11 +1006,10 @@ at the moment are:
(eshell-resume-eval)))) (eshell-resume-eval))))
;; On systems that don't support async subprocesses, eshell-resume ;; On systems that don't support async subprocesses, eshell-resume
;; can return t. Don't treat that as an error. ;; can return t. Don't treat that as an error.
(if (listp delim)
(setq delim (car delim)))
(if (and delim (not (eq delim t))) (if (and delim (not (eq delim t)))
(error "Unmatched delimiter: %c" (error "Unmatched delimiter: %c" delim)))))
(if (listp delim)
(car delim)
delim))))))
(defun eshell-resume-command (proc status) (defun eshell-resume-command (proc status)
"Resume the current command when a process ends." "Resume the current command when a process ends."

View file

@ -103,7 +103,7 @@ wholly ignored."
"Invoke a .BAT or .CMD file on DOS/Windows systems." "Invoke a .BAT or .CMD file on DOS/Windows systems."
;; since CMD.EXE can't handle forward slashes in the initial ;; since CMD.EXE can't handle forward slashes in the initial
;; argument... ;; argument...
(setcar args (subst-char-in-string directory-sep-char ?\\ (car args))) (setcar args (subst-char-in-string ?/ ?\\ (car args)))
(throw 'eshell-replace-command (throw 'eshell-replace-command
(eshell-parse-command eshell-windows-shell-file (cons "/c" args)))) (eshell-parse-command eshell-windows-shell-file (cons "/c" args))))

View file

@ -192,7 +192,7 @@ not be added to this variable."
(eshell-finish-arg (eshell-finish-arg
(prog1 (prog1
(list 'eshell-set-output-handle (list 'eshell-set-output-handle
(or (and sh (string-to-int sh)) 1) (or (and sh (string-to-number sh)) 1)
(list 'quote (list 'quote
(aref [overwrite append insert] (aref [overwrite append insert]
(1- (length oper))))) (1- (length oper)))))
@ -353,7 +353,8 @@ it defaults to `insert'."
((or (bufferp target) ((or (bufferp target)
(and (boundp 'eshell-buffer-shorthand) (and (boundp 'eshell-buffer-shorthand)
(symbol-value 'eshell-buffer-shorthand) (symbol-value 'eshell-buffer-shorthand)
(symbolp target))) (symbolp target)
(not (memq target '(t nil)))))
(let ((buf (if (bufferp target) (let ((buf (if (bufferp target)
target target
(get-buffer-create (get-buffer-create

View file

@ -438,7 +438,7 @@ This is used by `eshell-watch-for-password-prompt'."
(if eshell-first-time-p (if eshell-first-time-p
(run-hooks 'eshell-first-time-mode-hook)) (run-hooks 'eshell-first-time-mode-hook))
(run-hooks 'eshell-mode-hook) (run-mode-hooks 'eshell-mode-hook)
(run-hooks 'eshell-post-command-hook)) (run-hooks 'eshell-post-command-hook))
(put 'eshell-mode 'mode-class 'special) (put 'eshell-mode 'mode-class 'special)

View file

@ -253,14 +253,13 @@ If N or M is nil, it means the end of the list."
parts) parts)
(if (and (eshell-under-windows-p) (if (and (eshell-under-windows-p)
(> len 2) (> len 2)
(eq (aref path 0) directory-sep-char) (eq (aref path 0) ?/)
(eq (aref path 1) directory-sep-char)) (eq (aref path 1) ?/))
(setq i 2)) (setq i 2))
(while (< i len) (while (< i len)
(if (and (eq (aref path i) directory-sep-char) (if (and (eq (aref path i) ?/)
(not (get-text-property i 'escaped path))) (not (get-text-property i 'escaped path)))
(setq parts (cons (if (= li i) (setq parts (cons (if (= li i) "/"
(char-to-string directory-sep-char)
(substring path li (1+ i))) parts) (substring path li (1+ i))) parts)
li (1+ i))) li (1+ i)))
(setq i (1+ i))) (setq i (1+ i)))
@ -268,9 +267,7 @@ If N or M is nil, it means the end of the list."
(setq parts (cons (substring path li i) parts))) (setq parts (cons (substring path li i) parts)))
(if (and (eshell-under-windows-p) (if (and (eshell-under-windows-p)
(string-match "\\`[A-Za-z]:\\'" (car (last parts)))) (string-match "\\`[A-Za-z]:\\'" (car (last parts))))
(setcar (last parts) (setcar (last parts) (concat (car (last parts)) "/")))
(concat (car (last parts))
(char-to-string directory-sep-char))))
(nreverse parts))) (nreverse parts)))
(defun eshell-to-flat-string (value) (defun eshell-to-flat-string (value)
@ -450,8 +447,8 @@ list."
(point) (progn (end-of-line) (point) (progn (end-of-line)
(point))) ":"))) (point))) ":")))
(if (and (and fields (nth 0 fields) (nth 2 fields)) (if (and (and fields (nth 0 fields) (nth 2 fields))
(not (assq (string-to-int (nth 2 fields)) names))) (not (assq (string-to-number (nth 2 fields)) names)))
(setq names (cons (cons (string-to-int (nth 2 fields)) (setq names (cons (cons (string-to-number (nth 2 fields))
(nth 0 fields)) (nth 0 fields))
names)))) names))))
(forward-line)))) (forward-line))))

View file

@ -631,7 +631,7 @@ For example, to retrieve the second element of a user's record in
(if (and value (if (and value
(stringp value) (stringp value)
(file-directory-p value)) (file-directory-p value))
(concat varname (char-to-string directory-sep-char)) (concat varname "/")
varname)))) varname))))
(eshell-envvar-names (eshell-environment-variables))) (eshell-envvar-names (eshell-environment-variables)))
(all-completions argname obarray 'boundp) (all-completions argname obarray 'boundp)

View file

@ -183,10 +183,7 @@ Return nil if there is no such face.
If the optional argument FRAME is given, this gets the face NAME for If the optional argument FRAME is given, this gets the face NAME for
that frame; otherwise, it uses the selected frame. that frame; otherwise, it uses the selected frame.
If FRAME is the symbol t, then the global, non-frame face is returned. If FRAME is the symbol t, then the global, non-frame face is returned.
If NAME is already a face, it is simply returned. If NAME is already a face, it is simply returned."
This function is defined for compatibility with Emacs 20.2. It
should not be used anymore."
(facep name)) (facep name))
(make-obsolete 'internal-find-face 'facep "21.1") (make-obsolete 'internal-find-face 'facep "21.1")
@ -234,8 +231,8 @@ of a face name is the same for all frames."
(defun face-equal (face1 face2 &optional frame) (defun face-equal (face1 face2 &optional frame)
"Non-nil if faces FACE1 and FACE2 are equal. "Non-nil if faces FACE1 and FACE2 are equal.
Faces are considered equal if all their attributes are equal. Faces are considered equal if all their attributes are equal.
If the optional argument FRAME is given, report on face FACE in that frame. If the optional argument FRAME is given, report on FACE1 and FACE2 in that frame.
If FRAME is t, report on the defaults for face FACE (for new frames). If FRAME is t, report on the defaults for FACE1 and FACE2 (for new frames).
If FRAME is omitted or nil, use the selected frame." If FRAME is omitted or nil, use the selected frame."
(internal-lisp-face-equal-p face1 face2 frame)) (internal-lisp-face-equal-p face1 face2 frame))
@ -1154,16 +1151,24 @@ this regular expression. When called interactively with a prefix
arg, prompt for a regular expression." arg, prompt for a regular expression."
(interactive (list (and current-prefix-arg (interactive (list (and current-prefix-arg
(read-string "List faces matching regexp: ")))) (read-string "List faces matching regexp: "))))
(let ((faces (sort (face-list) #'string-lessp)) (let ((all-faces (zerop (length regexp)))
(frame (selected-frame)) (frame (selected-frame))
(max-length 0)
faces line-format
disp-frame window face-name) disp-frame window face-name)
(when (> (length regexp) 0) ;; We filter and take the max length in one pass
(setq faces (setq faces
(delq nil (delq nil
(mapcar (lambda (f) (mapcar (lambda (f)
(when (string-match regexp (symbol-name f)) (let ((s (symbol-name f)))
f)) (when (or all-faces (string-match regexp s))
faces)))) (setq max-length (max (length s) max-length))
f)))
(sort (face-list) #'string-lessp))))
(unless faces
(error "No faces matching \"%s\"" regexp))
(setq max-length (1+ max-length)
line-format (format "%%-%ds" max-length))
(with-output-to-temp-buffer "*Faces*" (with-output-to-temp-buffer "*Faces*"
(save-excursion (save-excursion
(set-buffer standard-output) (set-buffer standard-output)
@ -1178,7 +1183,7 @@ arg, prompt for a regular expression."
(setq help-xref-stack nil) (setq help-xref-stack nil)
(dolist (face faces) (dolist (face faces)
(setq face-name (symbol-name face)) (setq face-name (symbol-name face))
(insert (format "%25s " face-name)) (insert (format line-format face-name))
;; Hyperlink to a customization buffer for the face. Using ;; Hyperlink to a customization buffer for the face. Using
;; the help xref mechanism may not be the best way. ;; the help xref mechanism may not be the best way.
(save-excursion (save-excursion
@ -1203,7 +1208,7 @@ arg, prompt for a regular expression."
(goto-char beg) (goto-char beg)
(forward-line 1) (forward-line 1)
(while (not (eobp)) (while (not (eobp))
(insert " ") (insert-char ?\s max-length)
(forward-line 1)))) (forward-line 1))))
(goto-char (point-min))) (goto-char (point-min)))
(print-help-return-message)) (print-help-return-message))

View file

@ -514,6 +514,10 @@ Runs the usual ange-ftp hook, but only for completion operations."
This means to guarantee valid names and perhaps to canonicalize This means to guarantee valid names and perhaps to canonicalize
certain patterns. certain patterns.
FILENAME should be an absolute file name since the conversion rules
sometimes vary depending on the position in the file name. E.g. c:/foo
is a valid DOS file name, but c:/bar/c:/foo is not.
This function's standard definition is trivial; it just returns This function's standard definition is trivial; it just returns
the argument. However, on Windows and DOS, replace invalid the argument. However, on Windows and DOS, replace invalid
characters. On DOS, make sure to obey the 8.3 limitations. On characters. On DOS, make sure to obey the 8.3 limitations. On

View file

@ -132,7 +132,8 @@ Is buffer local variable.")
(defvar filesets-menu-ensure-use-cached (defvar filesets-menu-ensure-use-cached
(and filesets-running-xemacs (and filesets-running-xemacs
(not (emacs-version>= 21 5))) (if (fboundp 'emacs-version>=)
(not (emacs-version>= 21 5))))
"Make sure (X)Emacs uses filesets' cache. "Make sure (X)Emacs uses filesets' cache.
Well, if you use XEmacs (prior to 21.5?) custom.el is loaded after Well, if you use XEmacs (prior to 21.5?) custom.el is loaded after

View file

@ -88,6 +88,8 @@ settings. See the variable `font-lock-defaults', which takes precedence.")
It will be passed one argument, which is the current value of It will be passed one argument, which is the current value of
`font-lock-mode'.") `font-lock-mode'.")
;; The mode for which font-lock was initialized, or nil if none.
(defvar font-lock-mode-major-mode)
(define-minor-mode font-lock-mode (define-minor-mode font-lock-mode
"Toggle Font Lock mode. "Toggle Font Lock mode.
With arg, turn Font Lock mode off if and only if arg is a non-positive 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
;; Arrange to unfontify this buffer if we change major mode later. ;; Arrange to unfontify this buffer if we change major mode later.
(if font-lock-mode (if font-lock-mode
(add-hook 'change-major-mode-hook 'font-lock-change-mode nil t) (add-hook 'change-major-mode-hook 'font-lock-change-mode nil t)
(remove-hook 'change-major-mode-hook 'font-lock-change-mode t))) (remove-hook 'change-major-mode-hook 'font-lock-change-mode t))
(when font-lock-mode
(setq font-lock-mode-major-mode major-mode)))
;; Get rid of fontification for the old major mode. ;; Get rid of fontification for the old major mode.
;; We do this when changing major modes. ;; We do this when changing major modes.
@ -175,6 +179,7 @@ this function onto `change-major-mode-hook'."
'(font-lock-face))) '(font-lock-face)))
(restore-buffer-modified-p modp))) (restore-buffer-modified-p modp)))
(defvar font-lock-set-defaults)
(defun font-lock-default-function (mode) (defun font-lock-default-function (mode)
;; Turn on Font Lock mode. ;; Turn on Font Lock mode.
(when mode (when mode
@ -201,9 +206,14 @@ this function onto `change-major-mode-hook'."
;; Only do hard work if the mode has specified stuff in ;; Only do hard work if the mode has specified stuff in
;; `font-lock-defaults'. ;; `font-lock-defaults'.
(when (or font-lock-defaults (when (or font-lock-defaults
(and (boundp 'font-lock-keywords) font-lock-keywords) (if (boundp 'font-lock-keywords) font-lock-keywords)
(with-no-warnings (with-no-warnings
(cdr (assq major-mode font-lock-defaults-alist)))) (cdr (assq major-mode font-lock-defaults-alist)))
(and mode
(boundp 'font-lock-set-defaults)
font-lock-set-defaults
font-lock-mode-major-mode
(not (eq font-lock-mode-major-mode major-mode))))
(font-lock-mode-internal mode))) (font-lock-mode-internal mode)))
(defun turn-on-font-lock () (defun turn-on-font-lock ()

View file

@ -683,9 +683,22 @@ For example:
adds two fontification patterns for C mode, to fontify `FIXME:' words, even in adds two fontification patterns for C mode, to fontify `FIXME:' words, even in
comments, and to fontify `and', `or' and `not' words as keywords. comments, and to fontify `and', `or' and `not' words as keywords.
When used from a Lisp program (such as a minor mode), it is recommended to The above procedure will only add the keywords for C mode, not
use nil for MODE (and place the call on a hook) to avoid subtle problems for modes derived from C mode. To add them for derived modes too,
due to details of the implementation. pass nil for MODE and add the call to c-mode-hook.
For example:
(add-hook 'c-mode-hook
(lambda ()
(font-lock-add-keywords 'c-mode
'((\"\\\\\\=<\\\\(FIXME\\\\):\" 1 font-lock-warning-face prepend)
(\"\\\\\\=<\\\\(and\\\\|or\\\\|not\\\\)\\\\\\=>\" .
font-lock-keyword-face)))))
The above procedure may fail to add keywords to derived modes if
some involved major mode does not follow the standard conventions.
File a bug report if this happens, so the major mode can be corrected.
Note that some modes have specialized support for additional patterns, e.g., Note that some modes have specialized support for additional patterns, e.g.,
see the variables `c-font-lock-extra-types', `c++-font-lock-extra-types', 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',
(font-lock-update-removed-keyword-alist mode keywords append)) (font-lock-update-removed-keyword-alist mode keywords append))
(t (t
;; Otherwise set or add the keywords now. ;; Otherwise set or add the keywords now.
;; This is a no-op if it has been done already in this buffer. ;; This is a no-op if it has been done already in this buffer
;; for the correct major mode.
(font-lock-set-defaults) (font-lock-set-defaults)
(let ((was-compiled (eq (car font-lock-keywords) t))) (let ((was-compiled (eq (car font-lock-keywords) t)))
;; Bring back the user-level (uncompiled) keywords. ;; Bring back the user-level (uncompiled) keywords.
@ -774,9 +788,11 @@ see the variables `c-font-lock-extra-types', `c++-font-lock-extra-types',
MODE should be a symbol, the major mode command name, such as `c-mode' MODE should be a symbol, the major mode command name, such as `c-mode'
or nil. If nil, highlighting keywords are removed for the current buffer. or nil. If nil, highlighting keywords are removed for the current buffer.
When used from a Lisp program (such as a minor mode), it is recommended to To make the removal apply to modes derived from MODE as well,
use nil for MODE (and place the call on a hook) to avoid subtle problems pass nil for MODE and add the call to MODE-hook. This may fail
due to details of the implementation." for some derived modes if some involved major mode does not
follow the standard conventions. File a bug report if this
happens, so the major mode can be corrected."
(cond (mode (cond (mode
;; Remove one keyword at the time. ;; Remove one keyword at the time.
(dolist (keyword keywords) (dolist (keyword keywords)
@ -1351,7 +1367,7 @@ START should be at the beginning of a line."
comment-start-skip)) comment-start-skip))
(put-text-property beg (match-end 0) 'face (put-text-property beg (match-end 0) 'face
font-lock-comment-delimiter-face))) font-lock-comment-delimiter-face)))
(if (looking-back comment-end-regexp (point-at-bol)) (if (looking-back comment-end-regexp (point-at-bol) t)
(put-text-property (match-beginning 0) (point) 'face (put-text-property (match-beginning 0) (point) 'face
font-lock-comment-delimiter-face)))) font-lock-comment-delimiter-face))))
(< (point) end)) (< (point) end))
@ -1571,12 +1587,15 @@ A LEVEL of nil is equal to a LEVEL of 0, a LEVEL of t is equal to
(defvar font-lock-set-defaults nil) ; Whether we have set up defaults. (defvar font-lock-set-defaults nil) ; Whether we have set up defaults.
(defvar font-lock-mode-major-mode)
(defun font-lock-set-defaults () (defun font-lock-set-defaults ()
"Set fontification defaults appropriately for this mode. "Set fontification defaults appropriately for this mode.
Sets various variables using `font-lock-defaults' (or, if nil, using Sets various variables using `font-lock-defaults' (or, if nil, using
`font-lock-defaults-alist') and `font-lock-maximum-decoration'." `font-lock-defaults-alist') and `font-lock-maximum-decoration'."
;; Set fontification defaults iff not previously set. ;; Set fontification defaults iff not previously set for correct major mode.
(unless font-lock-set-defaults (unless (and font-lock-set-defaults
(eq font-lock-mode-major-mode major-mode))
(setq font-lock-mode-major-mode major-mode)
(set (make-local-variable 'font-lock-set-defaults) t) (set (make-local-variable 'font-lock-set-defaults) t)
(make-local-variable 'font-lock-fontified) (make-local-variable 'font-lock-fontified)
(make-local-variable 'font-lock-multiline) (make-local-variable 'font-lock-multiline)

View file

@ -713,7 +713,7 @@ Commands: Equivalent keys in read-only mode:
;; user customising ;; user customising
;;(message "forms: proceeding setup (user hooks)...") ;;(message "forms: proceeding setup (user hooks)...")
(run-hooks 'forms-mode-hook 'forms-mode-hooks) (run-mode-hooks 'forms-mode-hook 'forms-mode-hooks)
;;(message "forms: setting up... done.") ;;(message "forms: setting up... done.")
;; be helpful ;; be helpful

View file

@ -1,3 +1,241 @@
2005-06-04 Luc Teirlinck <teirllm@auburn.edu>
* gnus-art.el (article-update-date-lapsed): Use `save-match-data'.
2005-06-04 Lute Kamstra <lute@gnu.org>
* nnfolder.el (nnfolder-read-folder): Make sure that undo
information is never recorded.
2005-06-03 Stefan Monnier <monnier@iro.umontreal.ca>
* gnus-art.el (gnus-emphasis-alist): Disable the strikethru thingy.
2005-06-02 Katsumi Yamaoka <yamaoka@jpl.org>
* pop3.el (pop3-md5): Run md5 in the binary mode.
(pop3-md5-program-args): New variable.
* starttls.el (starttls-set-process-query-on-exit-flag):
Use eval-and-compile.
2005-05-31 Katsumi Yamaoka <yamaoka@jpl.org>
* gnus-art.el (article-display-x-face): Replace
process-kill-without-query by gnus-set-process-query-on-exit-flag.
* gnus-group.el: Bind gnus-cache-active-hashtb when compiling.
* gnus-util.el (gnus-set-process-query-on-exit-flag): Alias to
set-process-query-on-exit-flag or process-kill-without-query.
* html2text.el (html2text-fix-paragraphs): Use `while - re-search'
loop instead of replace-regexp.
* imap.el (imap-ssl-open): Use set-process-query-on-exit-flag
instead of process-kill-without-query if it is available.
* mm-util.el (mm-insert-file-contents): Bind find-file-hook
instead of find-file-hooks if it is available.
* mml1991.el: Bind pgg-default-user-id when compiling.
* mml2015.el: Bind pgg-default-user-id when compiling.
* nndraft.el (nndraft-request-associate-buffer):
Use write-contents-functions instead of write-contents-hooks if it is
available.
* nnheader.el (nnheader-find-file-noselect): Bind find-file-hook
instead of find-file-hooks if it is available.
* nntp.el (nntp-open-connection): Replace
process-kill-without-query by gnus-set-process-query-on-exit-flag.
(nntp-open-ssl-stream): Ditto.
(nntp-open-tls-stream): Ditto.
* pgg.el: Don't bind itimer vars; don't autoload itimer functions.
(pgg-run-at-time-1): New macro.
(pgg-run-at-time): Use it.
* starttls.el (starttls-set-process-query-on-exit-flag): Alias to
set-process-query-on-exit-flag or process-kill-without-query.
(starttls-open-stream-gnutls): Use it instead of
process-kill-without-query.
(starttls-open-stream): Ditto.
2005-05-31 Simon Josefsson <jas@extundo.com>
* imap.el (imap-ssl-open): Use imap-process-connection-type,
instead of hard coding to nil.
2005-05-31 Kevin Greiner <kgreiner@xpediantsolutions.com>
* gnus-group.el (): Require gnus-sum and autoload functions to
resolve warnings when gnus-group.el compiled alone.
2005-05-30 Reiner Steib <Reiner.Steib@gmx.de>
* gnus-agent.el (gnus-agent-regenerate-group)
(gnus-agent-fetch-articles): Replace `string-to-int' by
`string-to-number'.
* gnus-art.el (gnus-button-fetch-group): Ditto.
* gnus-cache.el (gnus-cache-generate-active)
(gnus-cache-articles-in-group): Ditto.
* gnus-group.el (gnus-group-set-current-level)
(gnus-group-insert-group-line): Ditto.
* gnus-score.el (gnus-score-set-expunge-below)
(gnus-score-set-mark-below, gnus-summary-score-effect)
(gnus-summary-score-entry): Ditto.
* gnus-soup.el (gnus-soup-send-packet, gnus-soup-parse-areas)
(gnus-soup-pack): Ditto.
* gnus-spec.el (gnus-xmas-format): Ditto.
* gnus-start.el (gnus-newsrc-to-gnus-format): Ditto.
* gnus-sum.el (gnus-create-xref-hashtb): Ditto.
* gnus-uu.el (gnus-uu-expand-numbers): Ditto.
* nnbabyl.el (nnbabyl-article-group-number): Ditto.
* nndb.el (nndb-get-remote-expire-response): Ditto.
* nndiary.el (nndiary-parse-schedule-value)
(nndiary-string-to-number, nndiary-request-replace-article)
(nndiary-request-article): Ditto.
* nndoc.el (nndoc-rnews-body-end, nndoc-mbox-body-end): Ditto.
* nndraft.el (nndraft-articles, nndraft-request-group): Ditto.
* nneething.el (nneething-make-head): Ditto.
* nnfolder.el (nnfolder-request-article)
(nnfolder-retrieve-headers): Ditto.
* nnheader.el (nnheader-file-to-number): Ditto.
* nnkiboze.el (nnkiboze-request-article): Ditto.
* nnmail.el (nnmail-process-unix-mail-format)
(nnmail-process-babyl-mail-format): Ditto.
* nnmbox.el (nnmbox-read-mbox, nnmbox-article-group-number): Ditto.
* nnmh.el (nnmh-update-gnus-unreads, nnmh-active-number)
(nnmh-request-create-group, nnmh-request-list-1)
(nnmh-request-group, nnmh-request-article): Ditto.
* nnml.el (nnml-request-replace-article, nnml-request-article): Ditto.
* nnrss.el (nnrss-find-rss-via-syndic8): Ditto.
* nnsoup.el (nnsoup-make-active): Ditto.
* nnspool.el (nnspool-find-id, nnspool-request-group): Ditto.
* nntp.el (nntp-find-group-and-number)
(nntp-retrieve-headers-with-xover): Ditto.
* pgg-gpg.el (pgg-gpg-snarf-keys-region): Ditto.
* pgg-parse.el (pgg-read-body, pgg-read-bytes)
(pgg-format-key-identifier): Ditto.
* pop3.el (pop3-last, pop3-stat): Ditto.
* qp.el (quoted-printable-decode-region): Ditto.
* spam-report.el (spam-report-url-ping-mm-url): Use format instead
of concat.
2005-05-30 Katsumi Yamaoka <yamaoka@jpl.org>
* gnus-agent.el (gnus-category-mode): Use gnus-run-mode-hooks.
* gnus-art.el (gnus-article-mode): Use gnus-run-mode-hooks.
* gnus-cus.el (gnus-custom-mode): Use gnus-run-mode-hooks.
* gnus-eform.el (gnus-edit-form-mode): Use gnus-run-mode-hooks.
* gnus-group.el (gnus-group-mode): Use gnus-run-mode-hooks.
* gnus-kill.el (gnus-kill-file-mode): Use gnus-run-mode-hooks.
* gnus-salt.el (gnus-tree-mode): Use gnus-run-mode-hooks.
(gnus-carpal-mode): Ditto.
* gnus-srvr.el (gnus-server-mode): Use gnus-run-mode-hooks.
(gnus-browse-mode): Ditto.
* gnus-sum.el (gnus-summary-mode): Use gnus-run-mode-hooks.
* gnus-util.el (gnus-run-mode-hooks): Save current buffer.
2005-05-29 Richard M. Stallman <rms@gnu.org>
* gnus-cite.el (gnus-cite-add-face): Set overlay's evaporate property.
2005-05-27 Katsumi Yamaoka <yamaoka@jpl.org>
* gnus-util.el (gnus-run-mode-hooks): New function.
* score-mode.el (gnus-score-mode): Use gnus-run-mode-hooks.
2005-05-26 Luc Teirlinck <teirllm@auburn.edu>
* gnus-agent.el (gnus-agent-make-mode-line-string):
Use mode-line-highlight as mouse-face.
2005-05-17 Katsumi Yamaoka <yamaoka@jpl.org>
* canlock.el (canlock): Change the parent group to news.
* deuglify.el (gnus-outlook-deuglify): Add :group.
* dig.el (dig): Add :group.
* gnus-art.el (gnus-inhibit-mime-unbuttonizing): Add :group.
* gnus-cite.el (gnus-cite-attribution-face): Add :group.
(gnus-cite-face-1, gnus-cite-face-2, gnus-cite-face-3): Ditto.
(gnus-cite-face-4, gnus-cite-face-5, gnus-cite-face-6): Ditto.
(gnus-cite-face-7, gnus-cite-face-8, gnus-cite-face-9): Ditto.
(gnus-cite-face-10, gnus-cite-face-11): Ditto.
* gnus-diary.el (gnus-diary): Add :group.
* gnus.el (gnus-group-news-1-face): Add :group.
(gnus-group-news-1-empty-face): Ditto.
(gnus-group-news-2-face, gnus-group-news-2-empty-face): Ditto.
(gnus-group-news-3-face, gnus-group-news-3-empty-face): Ditto.
(gnus-group-news-4-face, gnus-group-news-4-empty-face): Ditto.
(gnus-group-news-5-face, gnus-group-news-5-empty-face): Ditto.
(gnus-group-news-6-face, gnus-group-news-6-empty-face): Ditto.
(gnus-group-news-low-face, gnus-group-news-low-empty-face): Ditto.
(gnus-group-mail-1-face, gnus-group-mail-1-empty-face): Ditto.
(gnus-group-mail-2-face, gnus-group-mail-2-empty-face): Ditto.
(gnus-group-mail-3-face, gnus-group-mail-3-empty-face): Ditto.
(gnus-group-mail-low-face, gnus-group-mail-low-empty-face): Ditto.
(gnus-summary-selected-face, gnus-summary-cancelled-face): Ditto.
(gnus-summary-high-ticked-face): Ditto.
(gnus-summary-low-ticked-face): Ditto.
(gnus-summary-normal-ticked-face): Ditto.
(gnus-summary-high-ancient-face): Ditto.
(gnus-summary-low-ancient-face): Ditto.
(gnus-summary-normal-ancient-face): Ditto.
(gnus-summary-high-undownloaded-face): Ditto.
(gnus-summary-low-undownloaded-face): Ditto.
(gnus-summary-normal-undownloaded-face): Ditto.
(gnus-summary-high-unread-face): Ditto.
(gnus-summary-low-unread-face): Ditto.
(gnus-summary-normal-unread-face): Ditto.
(gnus-summary-high-read-face, gnus-summary-low-read-face): Ditto.
(gnus-summary-normal-read-face, gnus-splash-face): Ditto.
* message.el (message-minibuffer-local-map): Add :group.
* sieve-manage.el (sieve-manage-log): Add :group.
(sieve-manage-default-user): Diito.
(sieve-manage-server-eol, sieve-manage-client-eol): Ditto.
(sieve-manage-streams, sieve-manage-stream-alist): Ditto.
(sieve-manage-authenticators): Ditto.
(sieve-manage-authenticator-alist): Ditto.
(sieve-manage-default-port): Ditto.
* sieve-mode.el (sieve-control-commands-face): Add :group.
(sieve-action-commands-face): Ditto.
(sieve-test-commands-face): Ditto.
(sieve-tagged-arguments-face): Ditto.
* smime.el (smime): Add :group.
* spam-report.el (spam-report): Add :group.
* spam.el (spam, spam-face): Add :group.
2005-05-26 Lute Kamstra <lute@gnu.org>
* score-mode.el (gnus-score-mode): Use run-mode-hooks.
2005-05-16 Katsumi Yamaoka <yamaoka@jpl.org> 2005-05-16 Katsumi Yamaoka <yamaoka@jpl.org>
* gnus-art.el: Don't autoload mail-extract-address-components. * gnus-art.el: Don't autoload mail-extract-address-components.
@ -213,11 +451,11 @@
* nnimap.el (nnimap-date-days-ago): Ditto. * nnimap.el (nnimap-date-days-ago): Ditto.
* gnus-demon.el (parse-time-string): Added autoload. * gnus-demon.el (parse-time-string): Add autoload.
* gnus-delay.el (parse-time-string): Added autoload. * gnus-delay.el (parse-time-string): Add autoload.
* gnus-art.el (parse-time-string): Added autoload. * gnus-art.el (parse-time-string): Add autoload.
* nnultimate.el (parse-time): Require for `parse-time-string'. * nnultimate.el (parse-time): Require for `parse-time-string'.
@ -271,14 +509,13 @@
(rfc2047-encoded-word-regexp): Don't use shy group. (rfc2047-encoded-word-regexp): Don't use shy group.
(rfc2047-decode-region): Follow rfc2047-encoded-word-regexp change. (rfc2047-decode-region): Follow rfc2047-encoded-word-regexp change.
(rfc2047-parse-and-decode): Ditto. (rfc2047-parse-and-decode): Ditto.
(rfc2047-decode): Treat the ascii coding-system as raw-text by (rfc2047-decode): Treat the ascii coding-system as raw-text by default.
default.
2005-03-25 Lars Magne Ingebrigtsen <larsi@gnus.org> 2005-03-25 Lars Magne Ingebrigtsen <larsi@gnus.org>
* rfc2047.el (rfc2047-encode-encoded-words): New variable. * rfc2047.el (rfc2047-encode-encoded-words): New variable.
(rfc2047-field-value): Strip props. (rfc2047-field-value): Strip props.
(rfc2047-encode-message-header): Disabled header folding -- not (rfc2047-encode-message-header): Disable header folding -- not
all headers can be folded, and this should be done by the message all headers can be folded, and this should be done by the message
composition mode. Probably. I think. composition mode. Probably. I think.
(rfc2047-encodable-p): Say that =? needs encoding. (rfc2047-encodable-p): Say that =? needs encoding.

View file

@ -1,6 +1,6 @@
;;; canlock.el --- functions for Cancel-Lock feature ;;; canlock.el --- functions for Cancel-Lock feature
;; Copyright (C) 1998, 1999, 2001, 2002, 2003, 2004 ;; Copyright (C) 1998, 1999, 2001, 2002, 2003, 2004, 2005
;; Free Software Foundation, Inc. ;; Free Software Foundation, Inc.
;; Author: Katsumi Yamaoka <yamaoka@jpl.org> ;; Author: Katsumi Yamaoka <yamaoka@jpl.org>
@ -50,7 +50,7 @@
(defgroup canlock nil (defgroup canlock nil
"The Cancel-Lock feature." "The Cancel-Lock feature."
:group 'applications) :group 'news)
(defcustom canlock-password nil (defcustom canlock-password nil
"Password to use when signing a Cancel-Lock or a Cancel-Key header." "Password to use when signing a Cancel-Lock or a Cancel-Key header."

View file

@ -1,6 +1,6 @@
;;; deuglify.el --- deuglify broken Outlook (Express) articles ;;; deuglify.el --- deuglify broken Outlook (Express) articles
;; Copyright (C) 2002, 2003, 2004 Free Software Foundation, Inc. ;; Copyright (C) 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
;; Copyright (C) 2001, 2002 Raymond Scholz ;; Copyright (C) 2001, 2002 Raymond Scholz
;; Author: Raymond Scholz <rscholz@zonix.de> ;; Author: Raymond Scholz <rscholz@zonix.de>
@ -231,7 +231,8 @@
(defgroup gnus-outlook-deuglify nil (defgroup gnus-outlook-deuglify nil
"Deuglify articles generated by broken user agents like MS Outlook (Express)." "Deuglify articles generated by broken user agents like MS Outlook (Express)."
:version "22.1") :version "22.1"
:group 'gnus)
;;;###autoload ;;;###autoload
(defcustom gnus-outlook-deuglify-unwrap-min 45 (defcustom gnus-outlook-deuglify-unwrap-min 45

View file

@ -1,5 +1,5 @@
;;; dig.el --- Domain Name System dig interface ;;; dig.el --- Domain Name System dig interface
;; Copyright (c) 2000, 2001, 2003 Free Software Foundation, Inc. ;; Copyright (c) 2000, 2001, 2003, 2005 Free Software Foundation, Inc.
;; Author: Simon Josefsson <simon@josefsson.org> ;; Author: Simon Josefsson <simon@josefsson.org>
;; Keywords: DNS BIND dig ;; Keywords: DNS BIND dig
@ -40,7 +40,8 @@
(eval-when-compile (require 'cl)) (eval-when-compile (require 'cl))
(defgroup dig nil (defgroup dig nil
"Dig configuration.") "Dig configuration."
:group 'comm)
(defcustom dig-program "dig" (defcustom dig-program "dig"
"Name of dig (domain information groper) binary." "Name of dig (domain information groper) binary."

View file

@ -561,7 +561,8 @@ manipulated as follows:
(if (and (fboundp 'propertize) (if (and (fboundp 'propertize)
(fboundp 'make-mode-line-mouse-map)) (fboundp 'make-mode-line-mouse-map))
(propertize string 'local-map (propertize string 'local-map
(make-mode-line-mouse-map mouse-button mouse-func)) (make-mode-line-mouse-map mouse-button mouse-func)
'mouse-face 'mode-line-highlight)
string)) string))
(defun gnus-agent-toggle-plugged (set-to) (defun gnus-agent-toggle-plugged (set-to)
@ -1539,7 +1540,7 @@ downloaded into the agent."
(while (looking-at "\\([^: \n]+\\):\\([0-9]+\\) *") (while (looking-at "\\([^: \n]+\\):\\([0-9]+\\) *")
(push (cons (buffer-substring (match-beginning 1) (push (cons (buffer-substring (match-beginning 1)
(match-end 1)) (match-end 1))
(string-to-int (string-to-number
(buffer-substring (match-beginning 2) (buffer-substring (match-beginning 2)
(match-end 2)))) (match-end 2))))
crosses) crosses)
@ -2551,7 +2552,7 @@ The following commands are available:
(buffer-disable-undo) (buffer-disable-undo)
(setq truncate-lines t) (setq truncate-lines t)
(setq buffer-read-only t) (setq buffer-read-only t)
(gnus-run-hooks 'gnus-category-mode-hook)) (gnus-run-mode-hooks 'gnus-category-mode-hook))
(defalias 'gnus-category-position-point 'gnus-goto-colon) (defalias 'gnus-category-position-point 'gnus-goto-colon)
@ -3702,7 +3703,7 @@ If REREAD is not nil, downloaded articles are marked as unread."
(dir (file-name-directory file)) (dir (file-name-directory file))
point point
(downloaded (if (file-exists-p dir) (downloaded (if (file-exists-p dir)
(sort (mapcar (lambda (name) (string-to-int name)) (sort (mapcar (lambda (name) (string-to-number name))
(directory-files dir nil "^[0-9]+$" t)) (directory-files dir nil "^[0-9]+$" t))
'>) '>)
(progn (gnus-make-directory dir) nil))) (progn (gnus-make-directory dir) nil)))

View file

@ -367,8 +367,12 @@ advertisements. For example:
(or (nth 4 spec) 3) (or (nth 4 spec) 3)
(intern (format "gnus-emphasis-%s" (nth 2 spec))))) (intern (format "gnus-emphasis-%s" (nth 2 spec)))))
types)) types))
'(("\\(\\s-\\|^\\)\\(-\\(\\(\\w\\|-[^-]\\)+\\)-\\)\\(\\s-\\|[?!.,;]\\)" '(;; I've never seen anyone use this strikethru convention whereas I've
2 3 gnus-emphasis-strikethru) ;; several times seen it triggered by normal text. --Stef
;; Miles suggests that this form is sometimes used but for italics,
;; so maybe we should map it to `italic'.
;; ("\\(\\s-\\|^\\)\\(-\\(\\(\\w\\|-[^-]\\)+\\)-\\)\\(\\s-\\|[?!.,;]\\)"
;; 2 3 gnus-emphasis-strikethru)
("\\(\\s-\\|^\\)\\(_\\(\\(\\w\\|_[^_]\\)+\\)_\\)\\(\\s-\\|[?!.,;]\\)" ("\\(\\s-\\|^\\)\\(_\\(\\(\\w\\|_[^_]\\)+\\)_\\)\\(\\s-\\|[?!.,;]\\)"
2 3 gnus-emphasis-underline)))) 2 3 gnus-emphasis-underline))))
"*Alist that says how to fontify certain phrases. "*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,
as described by the variables `gnus-buttonized-mime-types' and as described by the variables `gnus-buttonized-mime-types' and
`gnus-unbuttonized-mime-types'." `gnus-unbuttonized-mime-types'."
:version "22.1" :version "22.1"
:group 'gnus-article-mime
:type 'boolean) :type 'boolean)
(defcustom gnus-body-boundary-delimiter "_" (defcustom gnus-body-boundary-delimiter "_"
@ -2180,10 +2185,11 @@ unfolded."
;; The command is a string, so we interpret the command ;; The command is a string, so we interpret the command
;; as a, well, command, and fork it off. ;; as a, well, command, and fork it off.
(let ((process-connection-type nil)) (let ((process-connection-type nil))
(process-kill-without-query (gnus-set-process-query-on-exit-flag
(start-process (start-process
"article-x-face" nil shell-file-name "article-x-face" nil shell-file-name
shell-command-switch gnus-article-x-face-command)) shell-command-switch gnus-article-x-face-command)
nil)
(with-temp-buffer (with-temp-buffer
(insert face) (insert face)
(process-send-region "article-x-face" (process-send-region "article-x-face"
@ -3032,20 +3038,21 @@ function and want to see what the date was before converting."
(defun article-update-date-lapsed () (defun article-update-date-lapsed ()
"Function to be run from a timer to update the lapsed time line." "Function to be run from a timer to update the lapsed time line."
(let (deactivate-mark) (save-match-data
(save-excursion (let (deactivate-mark)
(ignore-errors (save-excursion
(walk-windows (ignore-errors
(lambda (w) (walk-windows
(set-buffer (window-buffer w)) (lambda (w)
(when (eq major-mode 'gnus-article-mode) (set-buffer (window-buffer w))
(let ((mark (point-marker))) (when (eq major-mode 'gnus-article-mode)
(goto-char (point-min)) (let ((mark (point-marker)))
(when (re-search-forward "^X-Sent:" nil t) (goto-char (point-min))
(article-date-lapsed t)) (when (re-search-forward "^X-Sent:" nil t)
(goto-char (marker-position mark)) (article-date-lapsed t))
(move-marker mark nil)))) (goto-char (marker-position mark))
nil 'visible))))) (move-marker mark nil))))
nil 'visible))))))
(defun gnus-start-date-timer (&optional n) (defun gnus-start-date-timer (&optional n)
"Start a timer to update the X-Sent header in the article buffers. "Start a timer to update the X-Sent header in the article buffers.
@ -3741,7 +3748,7 @@ commands:
(setq buffer-read-only t) (setq buffer-read-only t)
(set-syntax-table gnus-article-mode-syntax-table) (set-syntax-table gnus-article-mode-syntax-table)
(mm-enable-multibyte) (mm-enable-multibyte)
(gnus-run-hooks 'gnus-article-mode-hook)) (gnus-run-mode-hooks 'gnus-article-mode-hook))
(defun gnus-article-setup-buffer () (defun gnus-article-setup-buffer ()
"Initialize the article buffer." "Initialize the article buffer."
@ -6786,7 +6793,7 @@ specified by `gnus-button-alist'."
(match-string 3 address) (match-string 3 address)
"nntp"))) "nntp")))
nil nil nil nil nil nil
(and (match-end 6) (list (string-to-int (match-string 6 address)))))))) (and (match-end 6) (list (string-to-number (match-string 6 address))))))))
(defun gnus-url-parse-query-string (query &optional downcase) (defun gnus-url-parse-query-string (query &optional downcase)
(let (retval pairs cur key val) (let (retval pairs cur key val)

View file

@ -487,7 +487,7 @@ Returns the list of articles removed."
articles) articles)
(when (file-exists-p dir) (when (file-exists-p dir)
(setq articles (setq articles
(sort (mapcar (lambda (name) (string-to-int name)) (sort (mapcar (lambda (name) (string-to-number name))
(directory-files dir nil "^[0-9]+$" t)) (directory-files dir nil "^[0-9]+$" t))
'<)) '<))
;; Update the cache active file, just to synch more. ;; Update the cache active file, just to synch more.
@ -681,7 +681,7 @@ If LOW, update the lower bound instead."
;; Separate articles from all other files and directories. ;; Separate articles from all other files and directories.
(while files (while files
(if (string-match "^[0-9]+$" (file-name-nondirectory (car files))) (if (string-match "^[0-9]+$" (file-name-nondirectory (car files)))
(push (string-to-int (file-name-nondirectory (pop files))) nums) (push (string-to-number (file-name-nondirectory (pop files))) nums)
(push (pop files) alphs))) (push (pop files) alphs)))
;; If we have nums, then this is probably a valid group. ;; If we have nums, then this is probably a valid group.
(when (setq nums (sort nums '<)) (when (setq nums (sort nums '<))

View file

@ -1,6 +1,7 @@
;;; gnus-cite.el --- parse citations in articles for Gnus ;;; gnus-cite.el --- parse citations in articles for Gnus
;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 ;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
;; 2005
;; Free Software Foundation, Inc. ;; Free Software Foundation, Inc.
;; Author: Per Abhiddenware ;; Author: Per Abhiddenware
@ -138,7 +139,8 @@ the envelope From line."
(defface gnus-cite-attribution-face '((t (defface gnus-cite-attribution-face '((t
(:italic t))) (:italic t)))
"Face used for attribution lines.") "Face used for attribution lines."
:group 'gnus-cite)
(defcustom gnus-cite-attribution-face 'gnus-cite-attribution-face (defcustom gnus-cite-attribution-face 'gnus-cite-attribution-face
"Face used for attribution lines. "Face used for attribution lines.
@ -155,7 +157,8 @@ It is merged with the face for the cited text belonging to the attribution."
(:foreground "MidnightBlue")) (:foreground "MidnightBlue"))
(t (t
(:italic t))) (:italic t)))
"Citation face.") "Citation face."
:group 'gnus-cite)
(defface gnus-cite-face-2 '((((class color) (defface gnus-cite-face-2 '((((class color)
(background dark)) (background dark))
@ -165,7 +168,8 @@ It is merged with the face for the cited text belonging to the attribution."
(:foreground "firebrick")) (:foreground "firebrick"))
(t (t
(:italic t))) (:italic t)))
"Citation face.") "Citation face."
:group 'gnus-cite)
(defface gnus-cite-face-3 '((((class color) (defface gnus-cite-face-3 '((((class color)
(background dark)) (background dark))
@ -175,7 +179,8 @@ It is merged with the face for the cited text belonging to the attribution."
(:foreground "dark green")) (:foreground "dark green"))
(t (t
(:italic t))) (:italic t)))
"Citation face.") "Citation face."
:group 'gnus-cite)
(defface gnus-cite-face-4 '((((class color) (defface gnus-cite-face-4 '((((class color)
(background dark)) (background dark))
@ -185,7 +190,8 @@ It is merged with the face for the cited text belonging to the attribution."
(:foreground "OrangeRed")) (:foreground "OrangeRed"))
(t (t
(:italic t))) (:italic t)))
"Citation face.") "Citation face."
:group 'gnus-cite)
(defface gnus-cite-face-5 '((((class color) (defface gnus-cite-face-5 '((((class color)
(background dark)) (background dark))
@ -195,7 +201,8 @@ It is merged with the face for the cited text belonging to the attribution."
(:foreground "dark khaki")) (:foreground "dark khaki"))
(t (t
(:italic t))) (:italic t)))
"Citation face.") "Citation face."
:group 'gnus-cite)
(defface gnus-cite-face-6 '((((class color) (defface gnus-cite-face-6 '((((class color)
(background dark)) (background dark))
@ -205,7 +212,8 @@ It is merged with the face for the cited text belonging to the attribution."
(:foreground "dark violet")) (:foreground "dark violet"))
(t (t
(:italic t))) (:italic t)))
"Citation face.") "Citation face."
:group 'gnus-cite)
(defface gnus-cite-face-7 '((((class color) (defface gnus-cite-face-7 '((((class color)
(background dark)) (background dark))
@ -215,7 +223,8 @@ It is merged with the face for the cited text belonging to the attribution."
(:foreground "SteelBlue4")) (:foreground "SteelBlue4"))
(t (t
(:italic t))) (:italic t)))
"Citation face.") "Citation face."
:group 'gnus-cite)
(defface gnus-cite-face-8 '((((class color) (defface gnus-cite-face-8 '((((class color)
(background dark)) (background dark))
@ -225,7 +234,8 @@ It is merged with the face for the cited text belonging to the attribution."
(:foreground "magenta")) (:foreground "magenta"))
(t (t
(:italic t))) (:italic t)))
"Citation face.") "Citation face."
:group 'gnus-cite)
(defface gnus-cite-face-9 '((((class color) (defface gnus-cite-face-9 '((((class color)
(background dark)) (background dark))
@ -235,7 +245,8 @@ It is merged with the face for the cited text belonging to the attribution."
(:foreground "violet")) (:foreground "violet"))
(t (t
(:italic t))) (:italic t)))
"Citation face.") "Citation face."
:group 'gnus-cite)
(defface gnus-cite-face-10 '((((class color) (defface gnus-cite-face-10 '((((class color)
(background dark)) (background dark))
@ -245,7 +256,8 @@ It is merged with the face for the cited text belonging to the attribution."
(:foreground "medium purple")) (:foreground "medium purple"))
(t (t
(:italic t))) (:italic t)))
"Citation face.") "Citation face."
:group 'gnus-cite)
(defface gnus-cite-face-11 '((((class color) (defface gnus-cite-face-11 '((((class color)
(background dark)) (background dark))
@ -255,7 +267,8 @@ It is merged with the face for the cited text belonging to the attribution."
(:foreground "turquoise")) (:foreground "turquoise"))
(t (t
(:italic t))) (:italic t)))
"Citation face.") "Citation face."
:group 'gnus-cite)
(defcustom gnus-cite-face-list (defcustom gnus-cite-face-list
'(gnus-cite-face-1 gnus-cite-face-2 gnus-cite-face-3 gnus-cite-face-4 '(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'."
(when (< from to) (when (< from to)
(push (setq overlay (gnus-make-overlay from to)) (push (setq overlay (gnus-make-overlay from to))
gnus-cite-overlay-list) gnus-cite-overlay-list)
(gnus-overlay-put overlay 'evaporate t)
(gnus-overlay-put overlay 'face face)))))) (gnus-overlay-put overlay 'face face))))))
(defun gnus-cite-toggle (prefix) (defun gnus-cite-toggle (prefix)

View file

@ -1,6 +1,6 @@
;;; gnus-cus.el --- customization commands for Gnus ;;; gnus-cus.el --- customization commands for Gnus
;; ;;
;; Copyright (C) 1996, 1999, 2000, 2001, 2002, 2003, 2004 ;; Copyright (C) 1996, 1999, 2000, 2001, 2002, 2003, 2004, 2005
;; Free Software Foundation, Inc. ;; Free Software Foundation, Inc.
;; Author: Per Abrahamsen <abraham@dina.kvl.dk> ;; Author: Per Abrahamsen <abraham@dina.kvl.dk>
@ -67,7 +67,7 @@ if that value is non-nil."
(set (make-local-variable 'widget-push-button-suffix) "") (set (make-local-variable 'widget-push-button-suffix) "")
(set (make-local-variable 'widget-link-prefix) "") (set (make-local-variable 'widget-link-prefix) "")
(set (make-local-variable 'widget-link-suffix) "")) (set (make-local-variable 'widget-link-suffix) ""))
(gnus-run-hooks 'gnus-custom-mode-hook)) (gnus-run-mode-hooks 'gnus-custom-mode-hook))
;;; Group Customization: ;;; Group Customization:

View file

@ -1,6 +1,6 @@
;;; gnus-diary.el --- Wrapper around the NNDiary Gnus backend ;;; gnus-diary.el --- Wrapper around the NNDiary Gnus backend
;; Copyright (c) 2001, 2002, 2003 Free Software Foundation, Inc. ;; Copyright (c) 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
;; Copyright (C) 1999, 2000, 2001 Didier Verna. ;; Copyright (C) 1999, 2000, 2001 Didier Verna.
;; Author: Didier Verna <didier@xemacs.org> ;; Author: Didier Verna <didier@xemacs.org>
@ -103,7 +103,8 @@
(defgroup gnus-diary nil (defgroup gnus-diary nil
"Utilities on top of the nndiary backend for Gnus." "Utilities on top of the nndiary backend for Gnus."
:version "22.1") :version "22.1"
:group 'gnus)
(defcustom gnus-diary-summary-line-format "%U%R%z %uD: %(%s%) (%ud)\n" (defcustom gnus-diary-summary-line-format "%U%R%z %uD: %(%s%) (%ud)\n"
"*Summary line format for nndiary groups." "*Summary line format for nndiary groups."

View file

@ -1,5 +1,5 @@
;;; gnus-eform.el --- a mode for editing forms for Gnus ;;; gnus-eform.el --- a mode for editing forms for Gnus
;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2004 ;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2004, 2005
;; Free Software Foundation, Inc. ;; Free Software Foundation, Inc.
;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org>
@ -83,7 +83,7 @@ It is a slightly enhanced emacs-lisp-mode.
(use-local-map gnus-edit-form-mode-map) (use-local-map gnus-edit-form-mode-map)
(make-local-variable 'gnus-edit-form-done-function) (make-local-variable 'gnus-edit-form-done-function)
(make-local-variable 'gnus-prev-winconf) (make-local-variable 'gnus-prev-winconf)
(gnus-run-hooks 'gnus-edit-form-mode-hook)) (gnus-run-mode-hooks 'gnus-edit-form-mode-hook))
(defun gnus-edit-form (form documentation exit-func) (defun gnus-edit-form (form documentation exit-func)
"Edit FORM in a new buffer. "Edit FORM in a new buffer.

View file

@ -1,5 +1,5 @@
;;; gnus-group.el --- group mode commands for Gnus ;;; gnus-group.el --- group mode commands for Gnus
;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 ;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005
;; Free Software Foundation, Inc. ;; Free Software Foundation, Inc.
;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org>
@ -41,7 +41,11 @@
(require 'time-date) (require 'time-date)
(require 'gnus-ems) (require 'gnus-ems)
(eval-when-compile (require 'mm-url)) (eval-when-compile
(require 'mm-url)
(let ((features (cons 'gnus-group features)))
(require 'gnus-sum))
(defvar gnus-cache-active-hashtb))
(defcustom gnus-group-archive-directory (defcustom gnus-group-archive-directory
"/ftp@ftp.hpc.uh.edu:/pub/emacs/ding-list/" "/ftp@ftp.hpc.uh.edu:/pub/emacs/ding-list/"
@ -1042,7 +1046,7 @@ The following commands are available:
(gnus-undo-mode 1)) (gnus-undo-mode 1))
(when gnus-slave (when gnus-slave
(gnus-slave-mode)) (gnus-slave-mode))
(gnus-run-hooks 'gnus-group-mode-hook)) (gnus-run-mode-hooks 'gnus-group-mode-hook))
(defun gnus-update-group-mark-positions () (defun gnus-update-group-mark-positions ()
(save-excursion (save-excursion
@ -1452,7 +1456,7 @@ if it is a string, only list groups matching REGEXP."
(eval gnus-group-line-format-spec))) (eval gnus-group-line-format-spec)))
`(gnus-group ,(gnus-intern-safe gnus-tmp-group gnus-active-hashtb) `(gnus-group ,(gnus-intern-safe gnus-tmp-group gnus-active-hashtb)
gnus-unread ,(if (numberp number) gnus-unread ,(if (numberp number)
(string-to-int gnus-tmp-number-of-unread) (string-to-number gnus-tmp-number-of-unread)
t) t)
gnus-marked ,gnus-tmp-marked-mark gnus-marked ,gnus-tmp-marked-mark
gnus-indentation ,gnus-group-indentation gnus-indentation ,gnus-group-indentation
@ -3246,7 +3250,7 @@ Uses the process/prefix convention."
(progn (progn
(unless (gnus-group-process-prefix current-prefix-arg) (unless (gnus-group-process-prefix current-prefix-arg)
(error "No group on the current line")) (error "No group on the current line"))
(string-to-int (string-to-number
(let ((s (read-string (let ((s (read-string
(format "Level (default %s): " (format "Level (default %s): "
(or (gnus-group-group-level) (or (gnus-group-group-level)

View file

@ -1,5 +1,5 @@
;;; gnus-kill.el --- kill commands for Gnus ;;; gnus-kill.el --- kill commands for Gnus
;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2003 ;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005
;; Free Software Foundation, Inc. ;; Free Software Foundation, Inc.
;; Author: Masanobu UMEDA <umerin@flab.flab.fujitsu.junet> ;; 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."
(setq major-mode 'gnus-kill-file-mode) (setq major-mode 'gnus-kill-file-mode)
(setq mode-name "Kill") (setq mode-name "Kill")
(lisp-mode-variables nil) (lisp-mode-variables nil)
(gnus-run-hooks 'emacs-lisp-mode-hook 'gnus-kill-file-mode-hook)) (gnus-run-mode-hooks 'emacs-lisp-mode-hook 'gnus-kill-file-mode-hook))
(defun gnus-kill-file-edit-file (newsgroup) (defun gnus-kill-file-edit-file (newsgroup)
"Begin editing a kill file for NEWSGROUP. "Begin editing a kill file for NEWSGROUP.

View file

@ -1,6 +1,6 @@
;;; gnus-salt.el --- alternate summary mode interfaces for Gnus ;;; gnus-salt.el --- alternate summary mode interfaces for Gnus
;; Copyright (C) 1996, 1997, 1998, 1999, 2001 ;; Copyright (C) 1996, 1997, 1998, 1999, 2001, 2002, 2004, 2005
;; Free Software Foundation, Inc. ;; Free Software Foundation, Inc.
;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org>
@ -496,7 +496,7 @@ Two predefined functions are available:
(gnus-set-work-buffer) (gnus-set-work-buffer)
(gnus-tree-node-insert (make-mail-header "") nil) (gnus-tree-node-insert (make-mail-header "") nil)
(setq gnus-tree-node-length (1- (point)))) (setq gnus-tree-node-length (1- (point))))
(gnus-run-hooks 'gnus-tree-mode-hook)) (gnus-run-mode-hooks 'gnus-tree-mode-hook))
(defun gnus-tree-read-summary-keys (&optional arg) (defun gnus-tree-read-summary-keys (&optional arg)
"Read a summary buffer key sequence and execute it." "Read a summary buffer key sequence and execute it."
@ -1009,7 +1009,7 @@ The following commands are available:
(buffer-disable-undo) (buffer-disable-undo)
(setq buffer-read-only t) (setq buffer-read-only t)
(make-local-variable 'gnus-carpal-attached-buffer) (make-local-variable 'gnus-carpal-attached-buffer)
(gnus-run-hooks 'gnus-carpal-mode-hook)) (gnus-run-mode-hooks 'gnus-carpal-mode-hook))
(defun gnus-carpal-setup-buffer (type) (defun gnus-carpal-setup-buffer (type)
(let ((buffer (symbol-value (intern (format "gnus-carpal-%s-buffer" type))))) (let ((buffer (symbol-value (intern (format "gnus-carpal-%s-buffer" type)))))

View file

@ -826,7 +826,7 @@ If optional argument `EXTRA' is non-nil, it's a non-standard overview header."
;; If this is an integer comparison, we transform from string to int. ;; If this is an integer comparison, we transform from string to int.
(if (eq (nth 2 (assoc header gnus-header-index)) 'gnus-score-integer) (if (eq (nth 2 (assoc header gnus-header-index)) 'gnus-score-integer)
(if (stringp match) (if (stringp match)
(setq match (string-to-int match))) (setq match (string-to-number match)))
(set-text-properties 0 (length match) nil match)) (set-text-properties 0 (length match) nil match))
(unless (eq date 'now) (unless (eq date 'now)
@ -891,7 +891,7 @@ EXTRA is the possible non-standard header."
t) t)
(read-string "Match: ") (read-string "Match: ")
(if (y-or-n-p "Use regexp match? ") 'r 's) (if (y-or-n-p "Use regexp match? ") 'r 's)
(string-to-int (read-string "Score: ")))) (string-to-number (read-string "Score: "))))
(save-excursion (save-excursion
(unless (and (stringp match) (> (length match) 0)) (unless (and (stringp match) (> (length match) 0))
(error "No match")) (error "No match"))
@ -945,7 +945,7 @@ EXTRA is the possible non-standard header."
"Automatically mark articles with score below SCORE as read." "Automatically mark articles with score below SCORE as read."
(interactive (interactive
(list (or (and current-prefix-arg (prefix-numeric-value current-prefix-arg)) (list (or (and current-prefix-arg (prefix-numeric-value current-prefix-arg))
(string-to-int (read-string "Mark below: "))))) (string-to-number (read-string "Mark below: ")))))
(setq score (or score gnus-summary-default-score 0)) (setq score (or score gnus-summary-default-score 0))
(gnus-score-set 'mark (list score)) (gnus-score-set 'mark (list score))
(gnus-score-set 'touched '(t)) (gnus-score-set 'touched '(t))
@ -979,7 +979,7 @@ EXTRA is the possible non-standard header."
"Automatically expunge articles with score below SCORE." "Automatically expunge articles with score below SCORE."
(interactive (interactive
(list (or (and current-prefix-arg (prefix-numeric-value current-prefix-arg)) (list (or (and current-prefix-arg (prefix-numeric-value current-prefix-arg))
(string-to-int (read-string "Set expunge below: "))))) (string-to-number (read-string "Set expunge below: ")))))
(setq score (or score gnus-summary-default-score 0)) (setq score (or score gnus-summary-default-score 0))
(gnus-score-set 'expunge (list score)) (gnus-score-set 'expunge (list score))
(gnus-score-set 'touched '(t))) (gnus-score-set 'touched '(t)))

View file

@ -349,9 +349,9 @@ If NOT-ALL, don't pack ticked articles."
(packer (if (< (string-match "%s" packer) (packer (if (< (string-match "%s" packer)
(string-match "%d" packer)) (string-match "%d" packer))
(format packer files (format packer files
(string-to-int (gnus-soup-unique-prefix dir))) (string-to-number (gnus-soup-unique-prefix dir)))
(format packer (format packer
(string-to-int (gnus-soup-unique-prefix dir)) (string-to-number (gnus-soup-unique-prefix dir))
files))) files)))
(dir (expand-file-name dir))) (dir (expand-file-name dir)))
(gnus-make-directory dir) (gnus-make-directory dir)
@ -385,7 +385,7 @@ though the two last may be nil if they are missing."
(and (eq (preceding-char) ?\t) (and (eq (preceding-char) ?\t)
(gnus-soup-field)) (gnus-soup-field))
(and (eq (preceding-char) ?\t) (and (eq (preceding-char) ?\t)
(string-to-int (gnus-soup-field)))) (string-to-number (gnus-soup-field))))
areas) areas)
(when (eq (preceding-char) ?\t) (when (eq (preceding-char) ?\t)
(beginning-of-line 2))) (beginning-of-line 2)))
@ -535,7 +535,7 @@ Return whether the unpacking was successful."
(error "Bad header")) (error "Bad header"))
(forward-line 1) (forward-line 1)
(setq beg (point) (setq beg (point)
end (+ (point) (string-to-int end (+ (point) (string-to-number
(buffer-substring (buffer-substring
(match-beginning 1) (match-end 1))))) (match-beginning 1) (match-end 1)))))
(switch-to-buffer tmp-buf) (switch-to-buffer tmp-buf)

View file

@ -509,7 +509,7 @@ are supported for %s."
(t (t
(if (null args) (if (null args)
(error 'wrong-number-of-arguments #'my-format n fstring)) (error 'wrong-number-of-arguments #'my-format n fstring))
(let* ((minlen (string-to-int (or (match-string 2) ""))) (let* ((minlen (string-to-number (or (match-string 2) "")))
(arg (car args)) (arg (car args))
(str (if (stringp arg) arg (format "%s" arg))) (str (if (stringp arg) arg (format "%s" arg)))
(lpad (null (match-string 1))) (lpad (null (match-string 1)))

View file

@ -1,5 +1,6 @@
;;; gnus-srvr.el --- virtual server support for Gnus ;;; gnus-srvr.el --- virtual server support for Gnus
;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 ;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003,
;; 2004, 2005
;; Free Software Foundation, Inc. ;; Free Software Foundation, Inc.
;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org>
@ -269,7 +270,7 @@ The following commands are available:
(put 'gnus-server-mode 'font-lock-defaults '(gnus-server-font-lock-keywords t)) (put 'gnus-server-mode 'font-lock-defaults '(gnus-server-font-lock-keywords t))
(set (make-local-variable 'font-lock-defaults) (set (make-local-variable 'font-lock-defaults)
'(gnus-server-font-lock-keywords t))) '(gnus-server-font-lock-keywords t)))
(gnus-run-hooks 'gnus-server-mode-hook)) (gnus-run-mode-hooks 'gnus-server-mode-hook))
(defun gnus-server-insert-server-line (gnus-tmp-name method) (defun gnus-server-insert-server-line (gnus-tmp-name method)
(let* ((gnus-tmp-how (car method)) (let* ((gnus-tmp-how (car method))
@ -849,7 +850,7 @@ buffer.
(setq truncate-lines t) (setq truncate-lines t)
(gnus-set-default-directory) (gnus-set-default-directory)
(setq buffer-read-only t) (setq buffer-read-only t)
(gnus-run-hooks 'gnus-browse-mode-hook)) (gnus-run-mode-hooks 'gnus-browse-mode-hook))
(defun gnus-browse-read-group (&optional no-article number) (defun gnus-browse-read-group (&optional no-article number)
"Enter the group at the current line. "Enter the group at the current line.

View file

@ -2518,7 +2518,7 @@ If FORCE is non-nil, the .newsrc file is read."
(cond (cond
((looking-at "[0-9]+") ((looking-at "[0-9]+")
;; We narrow and read a number instead of buffer-substring/ ;; We narrow and read a number instead of buffer-substring/
;; string-to-int because it's faster. narrow/widen is ;; string-to-number because it's faster. narrow/widen is
;; faster than save-restriction/narrow, and save-restriction ;; faster than save-restriction/narrow, and save-restriction
;; produces a garbage object. ;; produces a garbage object.
(setq num1 (progn (setq num1 (progn

View file

@ -2722,7 +2722,7 @@ The following commands are available:
(make-local-variable 'gnus-summary-mark-positions) (make-local-variable 'gnus-summary-mark-positions)
(gnus-make-local-hook 'pre-command-hook) (gnus-make-local-hook 'pre-command-hook)
(add-hook 'pre-command-hook 'gnus-set-global-variables nil t) (add-hook 'pre-command-hook 'gnus-set-global-variables nil t)
(gnus-run-hooks 'gnus-summary-mode-hook) (gnus-run-mode-hooks 'gnus-summary-mode-hook)
(turn-on-gnus-mailing-list-mode) (turn-on-gnus-mailing-list-mode)
(mm-enable-multibyte) (mm-enable-multibyte)
(gnus-update-format-specifications nil 'summary 'summary-mode 'summary-dummy) (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."
(match-end 1))) (match-end 1)))
(substring xrefs (match-beginning 1) (match-end 1)))) (substring xrefs (match-beginning 1) (match-end 1))))
(setq number (setq number
(string-to-int (substring xrefs (match-beginning 2) (string-to-number (substring xrefs (match-beginning 2)
(match-end 2)))) (match-end 2))))
(if (setq entry (gnus-gethash group xref-hashtb)) (if (setq entry (gnus-gethash group xref-hashtb))
(setcdr entry (cons number (cdr entry))) (setcdr entry (cons number (cdr entry)))

View file

@ -1015,6 +1015,13 @@ ARG is passed to the first function."
(save-current-buffer (save-current-buffer
(apply 'run-hooks funcs))) (apply 'run-hooks funcs)))
(defun gnus-run-mode-hooks (&rest funcs)
"Run `run-mode-hooks' if it is available, otherwise `run-hooks'.
This function saves the current buffer."
(if (fboundp 'run-mode-hooks)
(save-current-buffer (apply 'run-mode-hooks funcs))
(save-current-buffer (apply 'run-hooks funcs))))
;;; Various ;;; Various
(defvar gnus-group-buffer) ; Compiler directive (defvar gnus-group-buffer) ; Compiler directive
@ -1564,6 +1571,11 @@ empty directories from OLD-PATH."
(file-truename (file-truename
(concat old-dir ".."))))))))) (concat old-dir "..")))))))))
(if (fboundp 'set-process-query-on-exit-flag)
(defalias 'gnus-set-process-query-on-exit-flag
'set-process-query-on-exit-flag)
(defalias 'gnus-set-process-query-on-exit-flag
'process-kill-without-query))
(provide 'gnus-util) (provide 'gnus-util)

View file

@ -1185,7 +1185,7 @@ When called interactively, prompt for REGEXP."
(ignore-errors (ignore-errors
(replace-match (replace-match
(format "%06d" (format "%06d"
(string-to-int (buffer-substring (string-to-number (buffer-substring
(match-beginning 0) (match-end 0))))))) (match-beginning 0) (match-end 0)))))))
(setq string (buffer-substring 1 (point-max))) (setq string (buffer-substring 1 (point-max)))
(setcar (car string-list) string) (setcar (car string-list) string)

View file

@ -366,7 +366,8 @@ be set in `.emacs' instead."
(:foreground "ForestGreen" :bold t)) (:foreground "ForestGreen" :bold t))
(t (t
())) ()))
"Level 1 newsgroup face.") "Level 1 newsgroup face."
:group 'gnus-group)
(defface gnus-group-news-1-empty-face (defface gnus-group-news-1-empty-face
'((((class color) '((((class color)
@ -377,7 +378,8 @@ be set in `.emacs' instead."
(:foreground "ForestGreen")) (:foreground "ForestGreen"))
(t (t
())) ()))
"Level 1 empty newsgroup face.") "Level 1 empty newsgroup face."
:group 'gnus-group)
(defface gnus-group-news-2-face (defface gnus-group-news-2-face
'((((class color) '((((class color)
@ -388,7 +390,8 @@ be set in `.emacs' instead."
(:foreground "CadetBlue4" :bold t)) (:foreground "CadetBlue4" :bold t))
(t (t
())) ()))
"Level 2 newsgroup face.") "Level 2 newsgroup face."
:group 'gnus-group)
(defface gnus-group-news-2-empty-face (defface gnus-group-news-2-empty-face
'((((class color) '((((class color)
@ -399,7 +402,8 @@ be set in `.emacs' instead."
(:foreground "CadetBlue4")) (:foreground "CadetBlue4"))
(t (t
())) ()))
"Level 2 empty newsgroup face.") "Level 2 empty newsgroup face."
:group 'gnus-group)
(defface gnus-group-news-3-face (defface gnus-group-news-3-face
'((((class color) '((((class color)
@ -410,7 +414,8 @@ be set in `.emacs' instead."
(:bold t)) (:bold t))
(t (t
())) ()))
"Level 3 newsgroup face.") "Level 3 newsgroup face."
:group 'gnus-group)
(defface gnus-group-news-3-empty-face (defface gnus-group-news-3-empty-face
'((((class color) '((((class color)
@ -421,7 +426,8 @@ be set in `.emacs' instead."
()) ())
(t (t
())) ()))
"Level 3 empty newsgroup face.") "Level 3 empty newsgroup face."
:group 'gnus-group)
(defface gnus-group-news-4-face (defface gnus-group-news-4-face
'((((class color) '((((class color)
@ -432,7 +438,8 @@ be set in `.emacs' instead."
(:bold t)) (:bold t))
(t (t
())) ()))
"Level 4 newsgroup face.") "Level 4 newsgroup face."
:group 'gnus-group)
(defface gnus-group-news-4-empty-face (defface gnus-group-news-4-empty-face
'((((class color) '((((class color)
@ -443,7 +450,8 @@ be set in `.emacs' instead."
()) ())
(t (t
())) ()))
"Level 4 empty newsgroup face.") "Level 4 empty newsgroup face."
:group 'gnus-group)
(defface gnus-group-news-5-face (defface gnus-group-news-5-face
'((((class color) '((((class color)
@ -454,7 +462,8 @@ be set in `.emacs' instead."
(:bold t)) (:bold t))
(t (t
())) ()))
"Level 5 newsgroup face.") "Level 5 newsgroup face."
:group 'gnus-group)
(defface gnus-group-news-5-empty-face (defface gnus-group-news-5-empty-face
'((((class color) '((((class color)
@ -465,7 +474,8 @@ be set in `.emacs' instead."
()) ())
(t (t
())) ()))
"Level 5 empty newsgroup face.") "Level 5 empty newsgroup face."
:group 'gnus-group)
(defface gnus-group-news-6-face (defface gnus-group-news-6-face
'((((class color) '((((class color)
@ -476,7 +486,8 @@ be set in `.emacs' instead."
(:bold t)) (:bold t))
(t (t
())) ()))
"Level 6 newsgroup face.") "Level 6 newsgroup face."
:group 'gnus-group)
(defface gnus-group-news-6-empty-face (defface gnus-group-news-6-empty-face
'((((class color) '((((class color)
@ -487,7 +498,8 @@ be set in `.emacs' instead."
()) ())
(t (t
())) ()))
"Level 6 empty newsgroup face.") "Level 6 empty newsgroup face."
:group 'gnus-group)
(defface gnus-group-news-low-face (defface gnus-group-news-low-face
'((((class color) '((((class color)
@ -498,7 +510,8 @@ be set in `.emacs' instead."
(:foreground "DarkGreen" :bold t)) (:foreground "DarkGreen" :bold t))
(t (t
())) ()))
"Low level newsgroup face.") "Low level newsgroup face."
:group 'gnus-group)
(defface gnus-group-news-low-empty-face (defface gnus-group-news-low-empty-face
'((((class color) '((((class color)
@ -509,7 +522,8 @@ be set in `.emacs' instead."
(:foreground "DarkGreen")) (:foreground "DarkGreen"))
(t (t
())) ()))
"Low level empty newsgroup face.") "Low level empty newsgroup face."
:group 'gnus-group)
(defface gnus-group-mail-1-face (defface gnus-group-mail-1-face
'((((class color) '((((class color)
@ -520,7 +534,8 @@ be set in `.emacs' instead."
(:foreground "DeepPink3" :bold t)) (:foreground "DeepPink3" :bold t))
(t (t
(:bold t))) (:bold t)))
"Level 1 mailgroup face.") "Level 1 mailgroup face."
:group 'gnus-group)
(defface gnus-group-mail-1-empty-face (defface gnus-group-mail-1-empty-face
'((((class color) '((((class color)
@ -531,7 +546,8 @@ be set in `.emacs' instead."
(:foreground "DeepPink3")) (:foreground "DeepPink3"))
(t (t
(:italic t :bold t))) (:italic t :bold t)))
"Level 1 empty mailgroup face.") "Level 1 empty mailgroup face."
:group 'gnus-group)
(defface gnus-group-mail-2-face (defface gnus-group-mail-2-face
'((((class color) '((((class color)
@ -542,7 +558,8 @@ be set in `.emacs' instead."
(:foreground "HotPink3" :bold t)) (:foreground "HotPink3" :bold t))
(t (t
(:bold t))) (:bold t)))
"Level 2 mailgroup face.") "Level 2 mailgroup face."
:group 'gnus-group)
(defface gnus-group-mail-2-empty-face (defface gnus-group-mail-2-empty-face
'((((class color) '((((class color)
@ -553,7 +570,8 @@ be set in `.emacs' instead."
(:foreground "HotPink3")) (:foreground "HotPink3"))
(t (t
(:bold t))) (:bold t)))
"Level 2 empty mailgroup face.") "Level 2 empty mailgroup face."
:group 'gnus-group)
(defface gnus-group-mail-3-face (defface gnus-group-mail-3-face
'((((class color) '((((class color)
@ -564,7 +582,8 @@ be set in `.emacs' instead."
(:foreground "magenta4" :bold t)) (:foreground "magenta4" :bold t))
(t (t
(:bold t))) (:bold t)))
"Level 3 mailgroup face.") "Level 3 mailgroup face."
:group 'gnus-group)
(defface gnus-group-mail-3-empty-face (defface gnus-group-mail-3-empty-face
'((((class color) '((((class color)
@ -575,7 +594,8 @@ be set in `.emacs' instead."
(:foreground "magenta4")) (:foreground "magenta4"))
(t (t
())) ()))
"Level 3 empty mailgroup face.") "Level 3 empty mailgroup face."
:group 'gnus-group)
(defface gnus-group-mail-low-face (defface gnus-group-mail-low-face
'((((class color) '((((class color)
@ -586,7 +606,8 @@ be set in `.emacs' instead."
(:foreground "DeepPink4" :bold t)) (:foreground "DeepPink4" :bold t))
(t (t
(:bold t))) (:bold t)))
"Low level mailgroup face.") "Low level mailgroup face."
:group 'gnus-group)
(defface gnus-group-mail-low-empty-face (defface gnus-group-mail-low-empty-face
'((((class color) '((((class color)
@ -597,18 +618,21 @@ be set in `.emacs' instead."
(:foreground "DeepPink4")) (:foreground "DeepPink4"))
(t (t
(:bold t))) (:bold t)))
"Low level empty mailgroup face.") "Low level empty mailgroup face."
:group 'gnus-group)
;; Summary mode faces. ;; Summary mode faces.
(defface gnus-summary-selected-face '((t (defface gnus-summary-selected-face '((t
(:underline t))) (:underline t)))
"Face used for selected articles.") "Face used for selected articles."
:group 'gnus-summary)
(defface gnus-summary-cancelled-face (defface gnus-summary-cancelled-face
'((((class color)) '((((class color))
(:foreground "yellow" :background "black"))) (:foreground "yellow" :background "black")))
"Face used for cancelled articles.") "Face used for cancelled articles."
:group 'gnus-summary)
(defface gnus-summary-high-ticked-face (defface gnus-summary-high-ticked-face
'((((class color) '((((class color)
@ -619,7 +643,8 @@ be set in `.emacs' instead."
(:foreground "firebrick" :bold t)) (:foreground "firebrick" :bold t))
(t (t
(:bold t))) (:bold t)))
"Face used for high interest ticked articles.") "Face used for high interest ticked articles."
:group 'gnus-summary)
(defface gnus-summary-low-ticked-face (defface gnus-summary-low-ticked-face
'((((class color) '((((class color)
@ -630,7 +655,8 @@ be set in `.emacs' instead."
(:foreground "firebrick" :italic t)) (:foreground "firebrick" :italic t))
(t (t
(:italic t))) (:italic t)))
"Face used for low interest ticked articles.") "Face used for low interest ticked articles."
:group 'gnus-summary)
(defface gnus-summary-normal-ticked-face (defface gnus-summary-normal-ticked-face
'((((class color) '((((class color)
@ -641,7 +667,8 @@ be set in `.emacs' instead."
(:foreground "firebrick")) (:foreground "firebrick"))
(t (t
())) ()))
"Face used for normal interest ticked articles.") "Face used for normal interest ticked articles."
:group 'gnus-summary)
(defface gnus-summary-high-ancient-face (defface gnus-summary-high-ancient-face
'((((class color) '((((class color)
@ -652,7 +679,8 @@ be set in `.emacs' instead."
(:foreground "RoyalBlue" :bold t)) (:foreground "RoyalBlue" :bold t))
(t (t
(:bold t))) (:bold t)))
"Face used for high interest ancient articles.") "Face used for high interest ancient articles."
:group 'gnus-summary)
(defface gnus-summary-low-ancient-face (defface gnus-summary-low-ancient-face
'((((class color) '((((class color)
@ -663,7 +691,8 @@ be set in `.emacs' instead."
(:foreground "RoyalBlue" :italic t)) (:foreground "RoyalBlue" :italic t))
(t (t
(:italic t))) (:italic t)))
"Face used for low interest ancient articles.") "Face used for low interest ancient articles."
:group 'gnus-summary)
(defface gnus-summary-normal-ancient-face (defface gnus-summary-normal-ancient-face
'((((class color) '((((class color)
@ -674,7 +703,8 @@ be set in `.emacs' instead."
(:foreground "RoyalBlue")) (:foreground "RoyalBlue"))
(t (t
())) ()))
"Face used for normal interest ancient articles.") "Face used for normal interest ancient articles."
:group 'gnus-summary)
(defface gnus-summary-high-undownloaded-face (defface gnus-summary-high-undownloaded-face
'((((class color) '((((class color)
@ -683,7 +713,8 @@ be set in `.emacs' instead."
(((class color) (background dark)) (((class color) (background dark))
(:bold t :foreground "LightGray")) (:bold t :foreground "LightGray"))
(t (:inverse-video t :bold t))) (t (:inverse-video t :bold t)))
"Face used for high interest uncached articles.") "Face used for high interest uncached articles."
:group 'gnus-summary)
(defface gnus-summary-low-undownloaded-face (defface gnus-summary-low-undownloaded-face
'((((class color) '((((class color)
@ -692,7 +723,8 @@ be set in `.emacs' instead."
(((class color) (background dark)) (((class color) (background dark))
(:italic t :foreground "LightGray" :bold nil)) (:italic t :foreground "LightGray" :bold nil))
(t (:inverse-video t :italic t))) (t (:inverse-video t :italic t)))
"Face used for low interest uncached articles.") "Face used for low interest uncached articles."
:group 'gnus-summary)
(defface gnus-summary-normal-undownloaded-face (defface gnus-summary-normal-undownloaded-face
'((((class color) '((((class color)
@ -701,22 +733,26 @@ be set in `.emacs' instead."
(((class color) (background dark)) (((class color) (background dark))
(:foreground "LightGray" :bold nil)) (:foreground "LightGray" :bold nil))
(t (:inverse-video t))) (t (:inverse-video t)))
"Face used for normal interest uncached articles.") "Face used for normal interest uncached articles."
:group 'gnus-summary)
(defface gnus-summary-high-unread-face (defface gnus-summary-high-unread-face
'((t '((t
(:bold t))) (:bold t)))
"Face used for high interest unread articles.") "Face used for high interest unread articles."
:group 'gnus-summary)
(defface gnus-summary-low-unread-face (defface gnus-summary-low-unread-face
'((t '((t
(:italic t))) (:italic t)))
"Face used for low interest unread articles.") "Face used for low interest unread articles."
:group 'gnus-summary)
(defface gnus-summary-normal-unread-face (defface gnus-summary-normal-unread-face
'((t '((t
())) ()))
"Face used for normal interest unread articles.") "Face used for normal interest unread articles."
:group 'gnus-summary)
(defface gnus-summary-high-read-face (defface gnus-summary-high-read-face
'((((class color) '((((class color)
@ -729,7 +765,8 @@ be set in `.emacs' instead."
:bold t)) :bold t))
(t (t
(:bold t))) (:bold t)))
"Face used for high interest read articles.") "Face used for high interest read articles."
:group 'gnus-summary)
(defface gnus-summary-low-read-face (defface gnus-summary-low-read-face
'((((class color) '((((class color)
@ -742,7 +779,8 @@ be set in `.emacs' instead."
:italic t)) :italic t))
(t (t
(:italic t))) (:italic t)))
"Face used for low interest read articles.") "Face used for low interest read articles."
:group 'gnus-summary)
(defface gnus-summary-normal-read-face (defface gnus-summary-normal-read-face
'((((class color) '((((class color)
@ -753,7 +791,8 @@ be set in `.emacs' instead."
(:foreground "DarkGreen")) (:foreground "DarkGreen"))
(t (t
())) ()))
"Face used for normal interest read articles.") "Face used for normal interest read articles."
:group 'gnus-summary)
;;; ;;;
@ -806,7 +845,8 @@ be set in `.emacs' instead."
(:foreground "#888888")) (:foreground "#888888"))
(t (t
())) ()))
"Face for the splash screen.") "Face for the splash screen."
:group 'gnus)
(defun gnus-splash () (defun gnus-splash ()
(save-excursion (save-excursion

View file

@ -1,5 +1,5 @@
;;; html2text.el --- a simple html to plain text converter ;;; html2text.el --- a simple html to plain text converter
;; Copyright (C) 2002, 2003, 2004 Free Software Foundation, Inc. ;; Copyright (C) 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
;; Author: Joakim Hove <hove@phys.ntnu.no> ;; Author: Joakim Hove <hove@phys.ntnu.no>
@ -374,7 +374,8 @@ formatting, and then moved afterward.")
fashion, quite close to pure guess-work. It does work in some cases though." fashion, quite close to pure guess-work. It does work in some cases though."
(interactive) (interactive)
(goto-char (point-min)) (goto-char (point-min))
(replace-regexp "^<br>$" "") (while (re-search-forward "^<br>$" nil t)
(delete-region (match-beginning 0) (match-end 0)))
;; Removing lonely <br> on a single line, if they are left intact we ;; Removing lonely <br> on a single line, if they are left intact we
;; dont have any paragraphs at all. ;; dont have any paragraphs at all.
(goto-char (point-min)) (goto-char (point-min))

View file

@ -640,7 +640,11 @@ sure of changing the value of `foo'."
(let* ((port (or port imap-default-ssl-port)) (let* ((port (or port imap-default-ssl-port))
(coding-system-for-read imap-coding-system-for-read) (coding-system-for-read imap-coding-system-for-read)
(coding-system-for-write imap-coding-system-for-write) (coding-system-for-write imap-coding-system-for-write)
(process-connection-type nil) (process-connection-type imap-process-connection-type)
(set-process-query-on-exit-flag
(if (fboundp 'set-process-query-on-exit-flag)
'set-process-query-on-exit-flag
'process-kill-without-query))
process) process)
(when (progn (when (progn
(setq process (start-process (setq process (start-process
@ -650,7 +654,7 @@ sure of changing the value of `foo'."
(format-spec-make (format-spec-make
?s server ?s server
?p (number-to-string port))))) ?p (number-to-string port)))))
(process-kill-without-query process) (funcall set-process-query-on-exit-flag process nil)
process) process)
(with-current-buffer buffer (with-current-buffer buffer
(goto-char (point-min)) (goto-char (point-min))

View file

@ -842,7 +842,8 @@ the signature is inserted."
(set-keymap-parent map minibuffer-local-map) (set-keymap-parent map minibuffer-local-map)
map) map)
"Keymap for `message-read-from-minibuffer'." "Keymap for `message-read-from-minibuffer'."
:version "22.1") :version "22.1"
:group 'message-various)
;;;###autoload ;;;###autoload
(defcustom message-citation-line-function 'message-insert-citation-line (defcustom message-citation-line-function 'message-insert-citation-line

View file

@ -831,22 +831,28 @@ to advanced Emacs features, such as file-name-handlers, format decoding,
`find-file-hooks', etc. `find-file-hooks', etc.
If INHIBIT is non-nil, inhibit `mm-inhibit-file-name-handlers'. If INHIBIT is non-nil, inhibit `mm-inhibit-file-name-handlers'.
This function ensures that none of these modifications will take place." This function ensures that none of these modifications will take place."
(let ((format-alist nil) (let* ((format-alist nil)
(auto-mode-alist (if inhibit nil (mm-auto-mode-alist))) (auto-mode-alist (if inhibit nil (mm-auto-mode-alist)))
(default-major-mode 'fundamental-mode) (default-major-mode 'fundamental-mode)
(enable-local-variables nil) (enable-local-variables nil)
(after-insert-file-functions nil) (after-insert-file-functions nil)
(enable-local-eval nil) (enable-local-eval nil)
(find-file-hooks nil) (inhibit-file-name-operation (if inhibit
(inhibit-file-name-operation (if inhibit 'insert-file-contents
'insert-file-contents inhibit-file-name-operation))
inhibit-file-name-operation)) (inhibit-file-name-handlers
(inhibit-file-name-handlers (if inhibit
(if inhibit (append mm-inhibit-file-name-handlers
(append mm-inhibit-file-name-handlers inhibit-file-name-handlers)
inhibit-file-name-handlers) inhibit-file-name-handlers))
inhibit-file-name-handlers))) (ffh (if (boundp 'find-file-hook)
(insert-file-contents filename visit beg end replace))) 'find-file-hook
'find-file-hooks))
(val (symbol-value ffh)))
(set ffh nil)
(unwind-protect
(insert-file-contents filename visit beg end replace)
(set ffh val))))
(defun mm-append-to-file (start end filename &optional codesys inhibit) (defun mm-append-to-file (start end filename &optional codesys inhibit)
"Append the contents of the region to the end of file FILENAME. "Append the contents of the region to the end of file FILENAME.

View file

@ -1,5 +1,6 @@
;;; mml1991.el --- Old PGP message format (RFC 1991) support for MML ;;; mml1991.el --- Old PGP message format (RFC 1991) support for MML
;; Copyright (C) 1998, 1999, 2000, 2001, 2003 Free Software Foundation, Inc. ;; Copyright (C) 1998, 1999, 2000, 2001, 2003, 2005
;; Free Software Foundation, Inc.
;; Author: Sascha Lüdecke <sascha@meta-x.de>, ;; Author: Sascha Lüdecke <sascha@meta-x.de>,
;; Simon Josefsson <simon@josefsson.org> (Mailcrypt interface, Gnus glue) ;; Simon Josefsson <simon@josefsson.org> (Mailcrypt interface, Gnus glue)
@ -219,8 +220,10 @@
;; pgg wrapper ;; pgg wrapper
(defvar pgg-output-buffer) (eval-when-compile
(defvar pgg-errors-buffer) (defvar pgg-default-user-id)
(defvar pgg-errors-buffer)
(defvar pgg-output-buffer))
(defun mml1991-pgg-sign (cont) (defun mml1991-pgg-sign (cont)
(let (headers cte) (let (headers cte)

View file

@ -1,5 +1,6 @@
;;; mml2015.el --- MIME Security with Pretty Good Privacy (PGP) ;;; mml2015.el --- MIME Security with Pretty Good Privacy (PGP)
;; Copyright (C) 2000, 2001, 2002, 2003 Free Software Foundation, Inc. ;; Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005
;; Free Software Foundation, Inc.
;; Author: Shenghuo Zhu <zsh@cs.rochester.edu> ;; Author: Shenghuo Zhu <zsh@cs.rochester.edu>
;; Keywords: PGP MIME MML ;; Keywords: PGP MIME MML
@ -632,6 +633,7 @@
;;; pgg wrapper ;;; pgg wrapper
(eval-when-compile (eval-when-compile
(defvar pgg-default-user-id)
(defvar pgg-errors-buffer) (defvar pgg-errors-buffer)
(defvar pgg-output-buffer)) (defvar pgg-output-buffer))

View file

@ -493,7 +493,7 @@
(when (re-search-forward "^X-Gnus-Newsgroup: +\\([^:]+\\):\\([0-9]+\\) " (when (re-search-forward "^X-Gnus-Newsgroup: +\\([^:]+\\):\\([0-9]+\\) "
nil t) nil t)
(cons (buffer-substring (match-beginning 1) (match-end 1)) (cons (buffer-substring (match-beginning 1) (match-end 1))
(string-to-int (string-to-number
(buffer-substring (match-beginning 2) (match-end 2))))))) (buffer-substring (match-beginning 2) (match-end 2)))))))
(defun nnbabyl-insert-lines () (defun nnbabyl-insert-lines ()

View file

@ -196,7 +196,7 @@ article was posted to nndb")
;; otherwise, pull all of the following numbers into the list ;; otherwise, pull all of the following numbers into the list
(re-search-forward "follows\r?\n?" nil t) (re-search-forward "follows\r?\n?" nil t)
(while (re-search-forward "^[0-9]+$" nil t) (while (re-search-forward "^[0-9]+$" nil t)
(push (string-to-int (match-string 0)) list))) (push (string-to-number (match-string 0)) list)))
list)) list))
(defun nndb-request-expire-articles-remote (defun nndb-request-expire-articles-remote

Some files were not shown because too many files have changed in this diff Show more