merge trunk

This commit is contained in:
Kenichi Handa 2011-09-27 11:18:32 +09:00
commit 9aa99d0176
125 changed files with 6844 additions and 3424 deletions

View file

@ -1,3 +1,32 @@
2011-09-26 Paul Eggert <eggert@cs.ucla.edu>
Merge from gnulib, improving some licensing wording.
This clarifies and fixes some licensing issues raised by Glenn Morris
<http://lists.gnu.org/archive/html/bug-gnulib/2011-09/msg00397.html>.
It also merges the latest version of texinfo.tex and has some
MSVC-related changes that don't affect Emacs.
* Makefile.in (GNULIB_TOOL_FLAGS): Avoid msvc-inval, msvc-nothrow,
pathmax, and raise, since these are needed only to address
MSVC-related issues that Emacs doesn't have.
* doc/misc/texinfo.tex, lib/dup2.c, lib/gnulib.mk, lib/signal.in.h:
* lib/sigprocmask.c, lib/stat.c, lib/stdio.in.h, lib/sys_stat.in.h:
* lib/unistd.in.h, m4/dup2.m4, m4/getloadavg.m4, m4/gl-comp.m4:
* m4/include_next.m4, m4/signal_h.m4, m4/signalblocking.m4:
* m4/stdint.m4, m4/stdio_h.m4, m4/sys_stat_h.m4, m4/time_h.m4:
* m4/unistd_h.m4: Merge from gnulib.
2011-09-26 Andreas Schwab <schwab@linux-m68k.org>
* configure.in: Initialize HAVE_LIBXML2.
2011-09-26 Glenn Morris <rgm@gnu.org>
* make-dist: Add lib/makefile.w32-in.
2011-09-24 Glenn Morris <rgm@gnu.org>
* configure.in (CRT_DIR): Fix netbsd/openbsd handling.
2011-09-19 Lars Magne Ingebrigtsen <larsi@gnus.org>
* .dir-locals.el: Change the debbugs regexp to allow having the

View file

@ -339,7 +339,8 @@ GNULIB_MODULES = \
mktime pthread_sigmask readlink \
socklen stdarg stdio strftime strtoimax strtoumax symlink sys_stat
GNULIB_TOOL_FLAGS = \
--avoid=threadlib \
--avoid=msvc-inval --avoid=msvc-nothrow --avoid=pathmax \
--avoid=raise --avoid=threadlib \
--conditional-dependencies --import --no-changelog --no-vc-files \
--makefile-name=gnulib.mk
sync-from-gnulib: $(gnulib_srcdir)

2
README
View file

@ -2,7 +2,7 @@ Copyright (C) 2001-2011 Free Software Foundation, Inc.
See the end of the file for license conditions.
This directory tree holds version 24.0.50 of GNU Emacs, the extensible,
This directory tree holds version 24.0.90 of GNU Emacs, the extensible,
customizable, self-documenting real-time display editor.
The file INSTALL in this directory says how to build and install GNU

View file

@ -1,3 +1,8 @@
2011-09-26 Chong Yidong <cyd@stupidchicken.com>
* admin.el (set-version): Fix regexps for config.nt and
sed2v2.inp.
2011-09-06 Paul Eggert <eggert@cs.ucla.edu>
Merge from gnulib (Bug#9169).

View file

@ -75,11 +75,11 @@ Root must be the root of an Emacs source tree."
(submatch (1+ (in "0-9."))))))
(set-version-in-file root "nt/config.nt" version
(rx (and bol "#" (0+ blank) "define" (1+ blank)
"VERSION" (1+ blank)
"VERSION" (1+ blank) "\""
(submatch (1+ (in "0-9."))))))
(set-version-in-file root "msdos/sed2v2.inp" version
(rx (and bol "/^#undef " (1+ not-newline)
"define VERSION" (1+ space)
"define VERSION" (1+ space) "\""
(submatch (1+ (in "0-9."))))))
(set-version-in-file root "nt/makefile.w32-in" version
(rx (and "VERSION" (0+ space) "=" (0+ space)

View file

@ -62,37 +62,26 @@ For each step, check for possible errors.
number of the old Emacs to __, do the same with the new log and do
M-x ediff. Especially check that Info files aren't built.
10. cd EMACS_ROOT_DIR; cvs tag TAG
10. cd EMACS_ROOT_DIR; bzr tag TAG
TAG is EMACS_PRETEST_XX_YY_ZZZ for a pretest, EMACS_XX_YY for a
release.
Shortly before the release, cut the branch with the following commands:
cvs rtag EMACS_`NUMBER'_BASE
cvs rtag -b EMACS_`NUMBER'_RC -r EMACS_`NUMBER'_BASE
where `NUMBER' is the major version number of the release. This
makes it easier to see what changes have been applied to the
branch with:
cvs diff -r EMACS_`NUMBER'_BASE -r EMACS_`NUMBER'_RC
or merge changes back to the trunk with "cvs update -j", if
necessary.
After doing this, increase the version number on the trunk as per
step 4.
Also, open a Savannah support request asking for commits to the
new branch to be sent to the emacs-diffs mailing list (by default,
the list normally only gets commits to the trunk).
Shortly before the release, cut the version branch also, and open
a Savannah support request asking for commits to the new branch to
be sent to the emacs-diffs mailing list (by default, the list
normally only gets commits to the trunk).
11. Now you should upload the files to the GNU ftp server. In order to
do that, you must be registered as an Emacs maintainer and have your
GPG key acknowledged by the ftp people. Mail <ftp-upload@gnu.org>
for instructions. Once you are there, for each file FILE to be
released, create a detached GPG binary signature and a clearsigned
directive file like this:
for instructions.
You can use the gnupload script to upload each FILE, like this:
gnupload --to alpha.gnu.org:emacs/pretest FILE (for a pretest)
gnupload --to ftp.gnu.org:emacs FILE (for a release)
Instead of using gnupload, for each FILE, create a detached GPG
binary signature and a clearsigned directive file like this:
gpg -b FILE
echo directory: emacs/pretest > FILE.directive (for a pretest)
echo directory: emacs > FILE.directive (for a release)

44
autogen/configure vendored
View file

@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.65 for emacs 24.0.50.
# Generated by GNU Autoconf 2.65 for emacs 24.0.90.
#
#
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
@ -549,8 +549,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='emacs'
PACKAGE_TARNAME='emacs'
PACKAGE_VERSION='24.0.50'
PACKAGE_STRING='emacs 24.0.50'
PACKAGE_VERSION='24.0.90'
PACKAGE_STRING='emacs 24.0.90'
PACKAGE_BUGREPORT=''
PACKAGE_URL=''
@ -1870,7 +1870,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
\`configure' configures emacs 24.0.50 to adapt to many kinds of systems.
\`configure' configures emacs 24.0.90 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@ -1944,7 +1944,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
short | recursive ) echo "Configuration of emacs 24.0.50:";;
short | recursive ) echo "Configuration of emacs 24.0.90:";;
esac
cat <<\_ACEOF
@ -2107,7 +2107,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
emacs configure 24.0.50
emacs configure 24.0.90
generated by GNU Autoconf 2.65
Copyright (C) 2009 Free Software Foundation, Inc.
@ -2829,7 +2829,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by emacs $as_me 24.0.50, which was
It was created by emacs $as_me 24.0.90, which was
generated by GNU Autoconf 2.65. Invocation command line was
$ $0 $@
@ -3662,7 +3662,7 @@ fi
# Define the identity of the package.
PACKAGE='emacs'
VERSION='24.0.50'
VERSION='24.0.90'
cat >>confdefs.h <<_ACEOF
@ -8057,14 +8057,9 @@ case $opsys in
LIB_STANDARD=-lc
START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o'
;;
netbsd | openbsd )
if test -f $CRT_DIR/crti.o; then
LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o'
START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o'
else
LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o'
START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crtbegin.o'
fi
netbsd | openbsd )
LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o'
START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crtbegin.o'
;;
esac
@ -8163,6 +8158,19 @@ fi # crt_files != ""
case $opsys in
netbsd | openbsd )
if test -f $CRT_DIR/crti.o; then
test -f $CRT_DIR/crtn.o || \
as_fn_error "Required file not found: crtn.o" "$LINENO" 5
LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o'
START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o'
fi
;;
esac
@ -23092,7 +23100,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
This file was extended by emacs $as_me 24.0.50, which was
This file was extended by emacs $as_me 24.0.90, which was
generated by GNU Autoconf 2.65. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@ -23158,7 +23166,7 @@ _ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
ac_cs_version="\\
emacs config.status 24.0.50
emacs config.status 24.0.90
configured by $0, generated by GNU Autoconf 2.65,
with options \\"\$ac_cs_config\\"

View file

@ -22,7 +22,7 @@ dnl You should have received a copy of the GNU General Public License
dnl along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>.
AC_PREREQ(2.65)
AC_INIT(emacs, 24.0.50)
AC_INIT(emacs, 24.0.90)
AC_CONFIG_HEADER(src/config.h:src/config.in)
AC_CONFIG_SRCDIR(src/lisp.h)
AC_CONFIG_AUX_DIR(build-aux)
@ -985,6 +985,7 @@ LIB_MATH=-lm
LIB_STANDARD=
START_FILES=
dnl NB do not use CRT_DIR unquoted here, since it might not be set yet.
case $opsys in
cygwin )
LIB_MATH=
@ -1007,14 +1008,10 @@ case $opsys in
LIB_STANDARD=-lc
START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o'
;;
dnl NB this may be adjusted below.
netbsd | openbsd )
if test -f $CRT_DIR/crti.o; then
LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o'
START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o'
else
LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o'
START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crtbegin.o'
fi
LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o'
START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crtbegin.o'
;;
esac
@ -1094,6 +1091,19 @@ fi # crt_files != ""
AC_SUBST(CRT_DIR)
case $opsys in
netbsd | openbsd )
if test -f $CRT_DIR/crti.o; then
test -f $CRT_DIR/crtn.o || \
AC_MSG_ERROR([Required file not found: crtn.o])
LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o'
START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o'
fi
;;
esac
dnl This function definition taken from Gnome 2.0
dnl PKG_CHECK_MODULES(GSTUFF, gtk+-2.0 >= 1.3 glib = 1.3.4, action-if, action-not)
@ -2614,6 +2624,7 @@ fi
AC_SUBST(LIBXSM)
### Use libxml (-lxml2) if available
HAVE_LIBXML2=no
if test "${with_xml2}" != "no"; then
### I'm not sure what the version number should be, so I just guessed.
PKG_CHECK_MODULES(LIBXML2, libxml-2.0 > 2.6.17, HAVE_LIBXML2=yes, HAVE_LIBXML2=no)

View file

@ -1,3 +1,17 @@
2011-09-24 Chong Yidong <cyd@stupidchicken.com>
* windows.texi (Pop Up Window): Defer discussion of window
splitting to the Window Choice node. Add index entries.
(Force Same Window): Node deleted.
(Displaying Buffers, Window Choice): New nodes.
* buffers.texi (Select Buffer): Clarify description of
buffer-switching commands. Add xref to Window Display node.
Don't repeat confirm-nonexistent-file-or-buffer description from
Visiting node. Remove even-window-heights.
* frames.texi (Special Buffer Frames): Add xref to Window Choice.
2011-09-18 Chong Yidong <cyd@stupidchicken.com>
* cmdargs.texi (Icons X): Fix description of Emacs icon.

View file

@ -91,9 +91,9 @@ selected buffer other than the current buffer.
@var{bufname} @key{RET}}. This runs the command
@code{switch-to-buffer} with argument @var{bufname}. While entering
the buffer name, you can use the usual minibuffer completion and
history commands (@pxref{Minibuffer}). An empty argument to @kbd{C-x
b} specifies the buffer that was current most recently among those not
now displayed in any window.
history commands (@pxref{Minibuffer}). An empty input specifies the
buffer that was current most recently among those not now displayed in
any window.
@cindex minibuffer confirmation
@cindex confirming in the minibuffer
@ -107,16 +107,8 @@ catches a common mistake, in which one types @key{RET} before
realizing that @key{TAB} did not complete far enough to yield the
desired buffer name (@pxref{Completion}). Emacs asks for confirmation
by putting the message @samp{[Confirm]} in the minibuffer; type
@key{RET} again to confirm and visit the buffer.
@vindex confirm-nonexistent-file-or-buffer
The variable @code{confirm-nonexistent-file-or-buffer} controls
whether Emacs asks for confirmation before visiting a buffer that did
not previously exist. The default value, @code{after-completion},
gives the behavior we have just described. If the value is
@code{nil}, Emacs never asks for confirmation; for any other
non-@code{nil} value, Emacs always asks for confirmation. This
variable also affects the @code{find-file} command (@pxref{Visiting}).
@key{RET} again to confirm and visit the buffer. @xref{Visiting}, for
information about modifying this behavior.
One reason to create a new buffer is to use it for making temporary
notes. If you try to save it, Emacs asks for the file name to use.
@ -136,36 +128,26 @@ of most recent selection in the current frame), while @kbd{C-x @key{LEFT}}
@kindex C-x 4 b
@findex switch-to-buffer-other-window
@vindex even-window-heights
To select a buffer in a window other than the current one, type
@kbd{C-x 4 b} (@code{switch-to-buffer-other-window}). This prompts
for a buffer name using the minibuffer, displays that buffer in
another window, and selects that window. By default, if displaying
the buffer causes two vertically adjacent windows to be displayed, the
heights of those windows are evened out; to countermand that and
preserve the window configuration, set the variable
@code{even-window-heights} to @code{nil}.
another window, and selects that window.
@kindex C-x 5 b
@findex switch-to-buffer-other-frame
Similarly, @kbd{C-x 5 b} (@code{switch-to-buffer-other-frame})
prompts for a buffer name, displays that buffer in another frame, and
selects that frame.
selects that frame. If the buffer is already being shown in a window
on another frame, Emacs selects that window and frame instead of
creating a new frame.
@xref{Displaying Buffers}, for how the @kbd{C-x 4 b} and @kbd{C-x 5
b} commands get the window and/or frame to display in.
In addition, @kbd{C-x C-f}, and any other command for visiting a
file, can also be used to switch to an existing file-visiting buffer.
@xref{Visiting}.
@vindex display-buffer-reuse-frames
You can control how certain buffers are handled by these commands by
customizing the variables @code{special-display-buffer-names},
@code{special-display-regexps}, @code{same-window-buffer-names}, and
@code{same-window-regexps}. See @ref{Force Same Window}, and
@ref{Special Buffer Frames}, for more about these variables. In
addition, if the value of @code{display-buffer-reuse-frames} is
non-@code{nil}, and the buffer you want to switch to is already
displayed in some frame, Emacs will just raise that frame.
@findex goto-line
@kbd{C-u M-g M-g}, that is @code{goto-line} with a plain prefix
argument, reads a number @var{n} using the minibuffer, selects the

View file

@ -488,9 +488,8 @@ Multiple Windows
* Split Window:: New windows are made by splitting existing windows.
* Other Window:: Moving to another window or doing something to it.
* Pop Up Window:: Finding a file or buffer in another window.
* Force Same Window:: Forcing certain buffers to appear in the selected
window rather than in another window.
* Change Window:: Deleting windows and changing their sizes.
* Displaying Buffers:: How Emacs picks a window for displaying a buffer.
* Window Convenience:: Convenience functions for window handling.
Frames and Graphical Displays

View file

@ -1,4 +1,4 @@
@c It would be nicer to generate this using configure and @version@.
@c However, that would mean emacsver.texi would always be newer
@c then the info files in release tarfiles.
@set EMACSVER 24.0.50
@set EMACSVER 24.0.90

View file

@ -850,11 +850,12 @@ each others' edits if they are not careful.
@vindex special-display-buffer-names
You can make certain chosen buffers, which Emacs normally displays
in ``another window,'' appear in special frames of their own. To do
this, set the variable @code{special-display-buffer-names} to a list
of buffer names; any buffer whose name is in that list automatically
gets a special frame, when an Emacs command wants to display it ``in
another window.''
in ``some other window'' (@pxref{Displaying Buffers}), appear in
special frames of their own. To do this, set the variable
@code{special-display-buffer-names} to a list of buffer names; any
buffer whose name is in that list automatically gets a special frame.
@xref{Window Choice}, for how this fits in with the other ways for
Emacs to choose a window to display in.
For example, if you set the variable this way,
@ -906,13 +907,6 @@ where @var{function} is a symbol. Then the frame is constructed by
calling @var{function}; its first argument is the buffer, and its
remaining arguments are @var{args}.
An analogous feature lets you specify buffers which should be
displayed in the selected window. @xref{Force Same Window}. The
same-window feature takes precedence over the special-frame feature;
therefore, if you add a buffer name to
@code{special-display-buffer-names} and it has no effect, check to see
whether that feature is also in use for the same buffer name.
@node Frame Parameters
@section Setting Frame Parameters
@cindex Auto-Raise mode

View file

@ -18,9 +18,8 @@ one frame.
* Split Window:: New windows are made by splitting existing windows.
* Other Window:: Moving to another window or doing something to it.
* Pop Up Window:: Finding a file or buffer in another window.
* Force Same Window:: Forcing certain buffers to appear in the selected
window rather than in another window.
* Change Window:: Deleting windows and changing their sizes.
* Displaying Buffers:: How Emacs picks a window for displaying a buffer.
* Window Convenience:: Convenience functions for window handling.
@end menu
@ -191,84 +190,47 @@ feature is off by default.
@cindex selecting buffers in other windows
@kindex C-x 4
@kbd{C-x 4} is a prefix key for commands that select another window
(splitting the window if there is only one) and select a buffer in that
window. Different @kbd{C-x 4} commands have different ways of finding the
buffer to select.
@kbd{C-x 4} is a prefix key for a variety of commands that switch to
a buffer in a different window---either another existing window, or a
new window created by splitting the selected window. @xref{Window
Choice}, for how Emacs picks or creates the window to use.
@table @kbd
@findex switch-to-buffer-other-window
@item C-x 4 b @var{bufname} @key{RET}
Select buffer @var{bufname} in another window. This runs
@code{switch-to-buffer-other-window}.
Select buffer @var{bufname} in another window
(@code{switch-to-buffer-other-window}).
@findex display-buffer
@item C-x 4 C-o @var{bufname} @key{RET}
Display buffer @var{bufname} in another window, but
don't select that buffer or that window. This runs
@code{display-buffer}.
Display buffer @var{bufname} in some window, without trying to select
it (@code{display-buffer}). @xref{Displaying Buffers}, for details
about how the window is chosen.
@findex find-file-other-window
@item C-x 4 f @var{filename} @key{RET}
Visit file @var{filename} and select its buffer in another window. This
runs @code{find-file-other-window}. @xref{Visiting}.
Visit file @var{filename} and select its buffer in another window
(@code{find-file-other-window}). @xref{Visiting}.
@findex dired-other-window
@item C-x 4 d @var{directory} @key{RET}
Select a Dired buffer for directory @var{directory} in another window.
This runs @code{dired-other-window}. @xref{Dired}.
Select a Dired buffer for directory @var{directory} in another window
(@code{dired-other-window}). @xref{Dired}.
@findex mail-other-window
@item C-x 4 m
Start composing a mail message in another window. This runs
@code{mail-other-window}; its same-window analogue is @kbd{C-x m}
(@pxref{Sending Mail}).
Start composing a mail message, similar to @kbd{C-x m} (@pxref{Sending
Mail}), but in another window (@code{mail-other-window}).
@findex find-tag-other-window
@item C-x 4 .
Find a tag in the current tags table, in another window. This runs
@code{find-tag-other-window}, the multiple-window variant of @kbd{M-.}
(@pxref{Tags}).
Find a tag in the current tags table, similar to @kbd{M-.}
(@pxref{Tags}), but in another window (@code{find-tag-other-window}).
@item C-x 4 r @var{filename} @key{RET}
Visit file @var{filename} read-only, and select its buffer in another
window. This runs @code{find-file-read-only-other-window}.
@xref{Visiting}.
window (@code{find-file-read-only-other-window}). @xref{Visiting}.
@end table
@vindex split-height-threshold
@vindex split-width-threshold
By default, these commands split the window vertically when there is
only one. You can customize the variables @code{split-height-threshold}
and @code{split-width-threshold} to split the window horizontally
instead.
@node Force Same Window
@section Forcing Display in the Same Window
Certain Emacs commands switch to a specific buffer with special
contents. For example, @kbd{M-x shell} switches to a buffer named
@samp{*shell*}. By convention, all these commands are written to pop up
the buffer in a separate window. But you can specify that certain of
these buffers should appear in the selected window.
@vindex same-window-buffer-names
If you add a buffer name to the list @code{same-window-buffer-names},
the effect is that such commands display that particular buffer by
switching to it in the selected window. For example, if you add the
element @code{"*grep*"} to the list, the @code{grep} command will
display its output buffer in the selected window.
The default value of @code{same-window-buffer-names} is not
@code{nil}: it specifies buffer names @samp{*info*}, @samp{*mail*} and
@samp{*shell*} (as well as others used by more obscure Emacs packages).
This is why @kbd{M-x shell} normally switches to the @samp{*shell*}
buffer in the selected window. If you delete this element from the
value of @code{same-window-buffer-names}, the behavior of @kbd{M-x
shell} will change---it will pop up the buffer in another window
instead.
@vindex same-window-regexps
You can specify these buffers more generally with the variable
@code{same-window-regexps}. Set it to a list of regular expressions;
then any buffer whose name matches one of those regular expressions is
displayed by switching to it in the selected window. (Once again, this
applies only to buffers that normally get displayed for you in a
separate window.) The default value of this variable specifies Telnet
and rlogin buffers.
An analogous feature lets you specify buffers which should be
displayed in their own individual frames. @xref{Special Buffer Frames}.
@node Change Window
@section Deleting and Rearranging Windows
@ -356,6 +318,113 @@ heights of all the windows in the selected frame.
Mouse clicks on the mode line provide another way to change window
heights and to delete windows. @xref{Mode Line Mouse}.
@node Displaying Buffers
@section Displaying a Buffer in a Window
It is a common Emacs operation to display or ``pop up'' some buffer
in response to a user command. There are several different ways by
which commands do this.
Many commands, like @kbd{C-x C-f} (@code{find-file}), display the
buffer by ``taking over'' the selected window, expecting that the
user's attention will be diverted to that buffer. These commands
usually work by calling @code{switch-to-buffer} internally
(@pxref{Select Buffer}).
@findex display-buffer
Some commands try to display ``intelligently'', trying not to take
over the selected window, e.g. by splitting the selected window and
displaying the desired buffer in the child window. Such commands,
which include the various help commands (@pxref{Help}), work by
calling @code{display-buffer} internally. @xref{Window Choice}, for
details.
Other commands do the same as @code{display-buffer}, and
additionally select the displaying window so that you can begin
editing its buffer. The command @kbd{C-x `} (@code{next-error}) is
one example (@pxref{Compilation Mode}). Such commands work by calling
@code{pop-to-buffer} internally. @xref{Displaying Buffers,,Displaying
Buffers in Windows, elisp, The Emacs Lisp Reference Manual}.
Commands with names ending in @code{-other-window} behave like
@code{display-buffer}, except that they never display in the selected
window. Several of these commands are bound in the @kbd{C-x 4} prefix
key (@pxref{Pop Up Window}).
Commands with names ending in @code{-other-frame} behave like
@code{display-buffer}, except that they (i) never display in the
selected window and (ii) prefer to create a new frame to display the
desired buffer instead of splitting a window---as though the variable
@code{pop-up-frames} is set to @code{t} (@pxref{Window Choice}).
Several of these commands are bound in the @kbd{C-x 5} prefix key.
@menu
* Window Choice:: How @code{display-buffer} works.
@end menu
@node Window Choice
@subsection How @code{display-buffer} works
@findex display-buffer
The @code{display-buffer} command (as well as commands that call it
internally) chooses a window to display using the following steps:
@itemize
@vindex same-window-buffer-names
@vindex same-window-regexps
@item
First, check if the buffer should be displayed in the selected window
regardless of other considerations. You can tell Emacs to do this by
adding the desired buffer's name to the list
@code{same-window-buffer-names}, or adding a matching regular
expression to the list @code{same-window-regexps}. By default, these
variables are @code{nil}, so this step is skipped.
@vindex display-buffer-reuse-frames
@item
Otherwise, if the buffer is already displayed in an existing window,
``reuse'' that window. Normally, only windows on the selected frame
are considered, but windows on other frames are also reusable if you
change @code{display-buffer-reuse-frames} to @code{t}, or if you
change @code{pop-up-frames} (see below) to @code{t}.
@item
Otherwise, if you specified that the buffer should be displayed in a
special frame by customizing @code{special-display-buffer-names} or
@code{special-display-regexps}, do so. @xref{Special Buffer Frames}.
@vindex pop-up-frames
@item
Otherwise, optionally create a new frame and display the buffer there.
By default, this step is skipped. To enable it, change the variable
@code{pop-up-frames} to a non-@code{nil} value. The special value
@code{graphic-only} means to do this only on graphical displays.
@item
Otherwise, try to create a new window by splitting the selected
window, and display the buffer in that new window.
@vindex split-height-threshold
@vindex split-width-threshold
The split can be either vertical or horizontal, depending on the
variables @code{split-height-threshold} and
@code{split-width-threshold}. These variables should have integer
values. If @code{split-height-threshold} is smaller than the selected
window's height, the split puts the new window below. Otherwise, if
@code{split-width-threshold} is smaller than the window's width, the
split puts the new window on the right. If neither condition holds,
Emacs tries to split so that the new window is below---but only if the
window was not split before (to avoid excessive splitting).
@item
Otherwise, display the buffer in an existing window on the selected
frame.
@item
If all the above methods fail for whatever reason, create a new frame
and display the buffer there.
@end itemize
@node Window Convenience
@section Window Handling Convenience Features and Customization

View file

@ -1,3 +1,74 @@
2011-09-25 Martin Rudalics <rudalics@gmx.at>
* windows.texi (Windows and Frames, Display Action Functions)
(Switching Buffers): Fix some typos.
(Buffers and Windows): Remove reference to window-auto-delete.
Reword description of replace-buffer-in-windows.
(Window History): Fix some typos and refer to frame local buffer
list.
(Quitting Windows): New node.
(Window Configurations): Add descriptions of window-state-get
and window-state-put.
(Window Parameters): Describe variable ignore-window-parameters.
Sketch some window parameters currently in use.
* elisp.texi (Top): Update node listing.
2011-09-25 Chong Yidong <cyd@stupidchicken.com>
* windows.texi (Display Action Functions)
(Choosing Window Options): New nodes.
2011-09-24 Chong Yidong <cyd@stupidchicken.com>
* windows.texi (Window History): New node. Move text here from
Buffers and Windows.
(Switching Buffers): Rename from Displaying Buffers, since we
don't document display-buffer here; callers changed. Document
FORCE-SAME-WINDOW arg to switch-to-buffer and
switch-to-buffer-other-frame. Delete duplicate
replace-buffer-in-windows doc.
(Choosing Window): Document display actions.
2011-09-24 Eli Zaretskii <eliz@gnu.org>
* display.texi (Forcing Redisplay): Update the description of
redisplay-dont-pause due to change in the default value.
2011-09-23 Martin Rudalics <rudalics@gmx.at>
* frames.texi (Frames and Windows): Move section and rename to
Windows and Frames in windows.texi.
* windows.texi (Windows): Restructure.
(Basic Windows): Rewrite. Explain live and internal windows and
normalization functions.
(Windows and Frames): Move section here from frames.texi.
Describe subwindows, window combinations, window tree, and
corresponding functions including window-list here.
(Window Sizes): Rename section from Size of Window and move it
up in chapter. Describe total and body sizes and the
corresponding functions. Explain new semantics of
window-min-height/-width.
(Resizing Windows): Move section up in chapter. Describe new
resize functions.
(Splitting Windows): Describe new behavior of split-window,
split-window-above-each-other and split-window-side-by-side.
Provide examples. Describe window-nest and window-splits
options.
(Deleting Windows): Minor rewrite.
(Selecting Windows): Minor rewrite. Describe
frame-selected-window and set-frame-selected-window here.
(Cyclic Window Ordering): Minor rewrite. Describe
window-list-1.
(Buffers and Windows): Rewrite. Explain a window's previous and
next buffers and the corresponding functions.
(Window Tree): Merge into Windows and Frames section.
* elisp.texi (Top): Update node listings for frames and windows
sections.
2011-09-21 Stefan Monnier <monnier@iro.umontreal.ca>
* display.texi (Face Functions): `face-list' returns faces (bug#9564).
2011-09-19 Lars Magne Ingebrigtsen <larsi@gnus.org>
* errors.texi (Standard Errors): Remove apparent placeholder text

View file

@ -124,7 +124,7 @@ selected window. This is to prevent confusion: it ensures that the
buffer that the cursor is in, when Emacs reads a command, is the
buffer to which that command applies (@pxref{Command Loop}). Thus,
you should not use @code{set-buffer} to switch visibly to a different
buffer; for that, use the functions described in @ref{Displaying
buffer; for that, use the functions described in @ref{Switching
Buffers}.
When writing a Lisp function, do @emph{not} rely on this behavior of
@ -775,13 +775,14 @@ been displayed in a window. Several functions, notably
@code{other-buffer}, use this ordering. A buffer list displayed for the
user also follows this order.
Creating a buffer adds it to the end of the buffer list, and killing a
buffer removes it from that list. A buffer moves to the front of this
list whenever it is chosen for display in a window (@pxref{Displaying
Buffers}) or a window displaying it is selected (@pxref{Selecting
Windows}). A buffer moves to the end of the list when it is buried (see
@code{bury-buffer}, below). There are no functions available to the
Lisp programmer which directly manipulate the buffer list.
Creating a buffer adds it to the end of the buffer list, and killing
a buffer removes it from that list. A buffer moves to the front of
this list whenever it is chosen for display in a window
(@pxref{Switching Buffers}) or a window displaying it is selected
(@pxref{Selecting Windows}). A buffer moves to the end of the list
when it is buried (see @code{bury-buffer}, below). There are no
functions available to the Lisp programmer which directly manipulate
the buffer list.
In addition to the fundamental buffer list just described, Emacs
maintains a local buffer list for each frame, in which the buffers that
@ -888,24 +889,24 @@ as well as the fundamental buffer list; therefore, the buffer that you
bury will come last in the value of @code{(buffer-list @var{frame})} and
in the value of @code{(buffer-list)}.
If @var{buffer-or-name} is @code{nil} or omitted, this means to bury the
current buffer. In addition, if the buffer is displayed in the selected
window, this switches to some other buffer (obtained using
@code{other-buffer}) in the selected window. @xref{Displaying Buffers}.
But if the selected window is dedicated to its buffer, it deletes that
window if there are other windows left on its frame. Otherwise, if the
selected window is the only window on its frame, it iconifies that
frame. If @var{buffer-or-name} is displayed in some other window, it
remains displayed there.
If @var{buffer-or-name} is @code{nil} or omitted, this means to bury
the current buffer. In addition, if the buffer is displayed in the
selected window, this switches to some other buffer (obtained using
@code{other-buffer}) in the selected window. @xref{Switching
Buffers}. But if the selected window is dedicated to its buffer, it
deletes that window if there are other windows left on its frame.
Otherwise, if the selected window is the only window on its frame, it
iconifies that frame. If @var{buffer-or-name} is displayed in some
other window, it remains displayed there.
To replace a buffer in all the windows that display it, use
@code{replace-buffer-in-windows}. @xref{Buffers and Windows}.
@end deffn
@deffn Command unbury-buffer
This command switches to the last buffer in the local buffer list of the
selected frame. More precisely, it calls the function
@code{switch-to-buffer} (@pxref{Displaying Buffers}), to display the
This command switches to the last buffer in the local buffer list of
the selected frame. More precisely, it calls the function
@code{switch-to-buffer} (@pxref{Switching Buffers}), to display the
buffer returned by @code{last-buffer}, see above, in the selected
window.
@end deffn

View file

@ -118,15 +118,12 @@ redisplay of all windows.
to put more work on the queue to be done by redisplay whenever there
is a chance.
Emacs redisplay normally stops if input arrives, and does not happen
at all if input is available before it starts. Most of the time, this
is exactly what you want. However, you can prevent preemption by
binding @code{redisplay-dont-pause} to a non-@code{nil} value.
@defvar redisplay-dont-pause
If this variable is non-@code{nil}, pending input does not
prevent or halt redisplay; redisplay occurs, and finishes,
regardless of whether input is available.
If this variable is non-@code{nil}, pending input does not prevent or
halt redisplay; redisplay occurs, and finishes, regardless of whether
input is available. If it is @code{nil}, Emacs redisplay stops if
input arrives, and does not happen at all if input is available before
it starts. The default is @code{t}.
@end defvar
@defvar redisplay-preemption-period
@ -2598,7 +2595,7 @@ attributes @code{nil}. It does nothing if there is already a face named
@end defun
@defun face-list
This function returns a list of all defined face names.
This function returns a list of all defined faces.
@end defun
@defun copy-face old-face new-name &optional frame new-frame

View file

@ -21,7 +21,7 @@
@end ifset
@c per rms and peterb, use 10pt fonts for the main text, mostly to
@c save on paper cost.
@c save on paper cost.
@c Do this inside @tex for now, so current makeinfo does not complain.
@tex
@ifset smallbook
@ -927,26 +927,30 @@ Buffers
Windows
* Basic Windows:: Basic information on using windows.
* Windows and Frames:: Relating windows to the frame they appear on.
* Window Sizes:: Accessing a window's size.
* Resizing Windows:: Changing the sizes of windows.
* Splitting Windows:: Splitting one window into two windows.
* Deleting Windows:: Deleting a window gives its space to other windows.
* Selecting Windows:: The selected window is the one that you edit in.
* Cyclic Window Ordering:: Moving around the existing windows.
* Buffers and Windows:: Each window displays the contents of a buffer.
* Displaying Buffers:: Higher-level functions for displaying a buffer
and choosing a window for it.
* Switching Buffers:: Higher-level functions for switching to a buffer.
* Choosing Window:: How to choose a window for displaying a buffer.
* Display Action Functions:: Subroutines for @code{display-buffer}.
* Choosing Window Options:: Extra options affecting how buffers are displayed.
* Window History:: Each window remembers the buffers displayed in it.
* Dedicated Windows:: How to avoid displaying another buffer in
a specific window.
a specific window.
* Quitting Windows:: How to restore the state prior to displaying a
buffer.
* Window Point:: Each window has its own location of point.
* Window Start and End:: Buffer positions indicating which text is
on-screen in a window.
* Textual Scrolling:: Moving text up and down through the window.
* Vertical Scrolling:: Moving the contents up and down on the window.
* Horizontal Scrolling:: Moving the contents sideways on the window.
* Size of Window:: Accessing the size of a window.
* Resizing Windows:: Changing the size of a window.
* Coordinates and Windows:: Converting coordinates to windows.
* Window Tree:: The layout and sizes of all windows in a frame.
* Window Configurations:: Saving and restoring the state of the screen.
* Window Parameters:: Associating additional information with windows.
* Window Hooks:: Hooks for scrolling, window size changes,
@ -962,8 +966,6 @@ Frames
* Frame Titles:: Automatic updating of frame titles.
* Deleting Frames:: Frames last until explicitly deleted.
* Finding All Frames:: How to examine all existing frames.
* Frames and Windows:: A frame contains windows;
display of text always works through windows.
* Minibuffers and Frames:: How a frame finds the minibuffer to use.
* Input Focus:: Specifying the selected frame.
* Visibility of Frames:: Frames may be visible or invisible, or icons.

View file

@ -103,7 +103,7 @@ function is basically equivalent to:
@end smallexample
@noindent
(See @code{switch-to-buffer} in @ref{Displaying Buffers}.)
(See @code{switch-to-buffer} in @ref{Switching Buffers}.)
If @var{wildcards} is non-@code{nil}, which is always true in an
interactive call, then @code{find-file} expands wildcard characters in
@ -187,8 +187,9 @@ various files.
@deffn Command find-file-other-window filename &optional wildcards
This command selects a buffer visiting the file @var{filename}, but
does so in a window other than the selected window. It may use another
existing window or split a window; see @ref{Displaying Buffers}.
does so in a window other than the selected window. It may use
another existing window or split a window; see @ref{Switching
Buffers}.
When this command is called interactively, it prompts for
@var{filename}.

View file

@ -86,8 +86,6 @@ is the same as for @code{framep} above.
* Frame Titles:: Automatic updating of frame titles.
* Deleting Frames:: Frames last until explicitly deleted.
* Finding All Frames:: How to examine all existing frames.
* Frames and Windows:: A frame contains windows;
display of text always works through windows.
* Minibuffers and Frames:: How a frame finds the minibuffer to use.
* Input Focus:: Specifying the selected frame.
* Visibility of Frames:: Frames may be visible or invisible, or icons.
@ -1309,53 +1307,6 @@ direction.
See also @code{next-window} and @code{previous-window}, in @ref{Cyclic
Window Ordering}.
@node Frames and Windows
@section Frames and Windows
Each window is part of one and only one frame; you can get that frame
with @code{window-frame}.
@defun window-frame window
This function returns the frame that @var{window} is on.
@end defun
All the non-minibuffer windows in a frame are arranged in a cyclic
order. The order runs from the frame's top window, which is at the
upper left corner, down and to the right, until it reaches the window at
the lower right corner (always the minibuffer window, if the frame has
one), and then it moves back to the top. @xref{Cyclic Window Ordering}.
@defun frame-first-window &optional frame
This returns the topmost, leftmost window of frame @var{frame}.
If omitted or @code{nil}, @var{frame} defaults to the selected frame.
@end defun
At any time, exactly one window on any frame is @dfn{selected within the
frame}. The significance of this designation is that selecting the
frame also selects this window. Conversely, selecting a window for
Emacs with @code{select-window} also makes that window selected within
its frame. @xref{Selecting Windows}.
@defun frame-selected-window &optional frame
This function returns the window on @var{frame} that is selected
within @var{frame}. If omitted or @code{nil}, @var{frame} defaults to
the selected frame.
@end defun
@defun set-frame-selected-window frame window &optional norecord
This sets the selected window of frame @var{frame} to @var{window}.
If @var{frame} is @code{nil}, it operates on the selected frame. If
@var{frame} is the selected frame, this makes @var{window} the
selected window. This function returns @var{window}.
Optional argument @var{norecord} non-@code{nil} means to neither change
the order of recently selected windows nor the buffer list (@pxref{The
Buffer List}).
@end defun
Another function that (usually) returns one of the windows in a given
frame is @code{minibuffer-window}. @xref{Definition of minibuffer-window}.
@node Minibuffers and Frames
@section Minibuffers and Frames

View file

@ -953,11 +953,13 @@ Windows
* Selecting Windows:: The selected window is the one that you edit in.
* Cyclic Window Ordering:: Moving around the existing windows.
* Buffers and Windows:: Each window displays the contents of a buffer.
* Displaying Buffers:: Higher-level functions for displaying a buffer
and choosing a window for it.
* Switching Buffers:: Higher-level functions for switching to a buffer.
* Choosing Window:: How to choose a window for displaying a buffer.
* Display Action Functions:: Subroutines for @code{display-buffer}.
* Choosing Window Options:: Extra options affecting how buffers are displayed.
* Window History:: Each window remembers the buffers displayed in it.
* Dedicated Windows:: How to avoid displaying another buffer in
a specific window.
a specific window.
* Window Point:: Each window has its own location of point.
* Window Start and End:: Buffer positions indicating which text is
on-screen in a window.

View file

@ -952,11 +952,13 @@ Windows
* Selecting Windows:: The selected window is the one that you edit in.
* Cyclic Window Ordering:: Moving around the existing windows.
* Buffers and Windows:: Each window displays the contents of a buffer.
* Displaying Buffers:: Higher-level functions for displaying a buffer
and choosing a window for it.
* Switching Buffers:: Higher-level functions for switching to a buffer.
* Choosing Window:: How to choose a window for displaying a buffer.
* Display Action Functions:: Subroutines for @code{display-buffer}.
* Choosing Window Options:: Extra options affecting how buffers are displayed.
* Window History:: Each window remembers the buffers displayed in it.
* Dedicated Windows:: How to avoid displaying another buffer in
a specific window.
a specific window.
* Window Point:: Each window has its own location of point.
* Window Start and End:: Buffer positions indicating which text is
on-screen in a window.

File diff suppressed because it is too large Load diff

View file

@ -1,5 +1,5 @@
.\" See section COPYING for copyright and redistribution information.
.TH EMACS 1 "2007 April 13" "GNU Emacs 24.0.50"
.TH EMACS 1 "2007 April 13" "GNU Emacs 24.0.90"
.
.
.SH NAME

View file

@ -1,3 +1,18 @@
2011-09-21 Lars Magne Ingebrigtsen <larsi@gnus.org>
* gnus.texi (Archived Messages): Note the default (bug#9552).
2011-09-21 Bill Wohler <wohler@newt.com>
Release MH-E manual version 8.3.
* mh-e.texi: (VERSION, EDITION, UPDATED, UPDATE-MONTH): Update for
release 8.3.
(Preface): Updated support information.
(From Bill Wohler): Reset text to original version. As a
historical quote, the tense should be correct in the time that it
was written.
2011-09-11 Lars Magne Ingebrigtsen <larsi@gnus.org>
* gnus.texi (Listing Groups): Explain `gnus-group-list-limit'.

View file

@ -12617,7 +12617,7 @@ Messages will be saved in all those groups.
When a key ``matches'', the result is used.
@item @code{nil}
No message archiving will take place. This is the default.
No message archiving will take place.
@end table
Let's illustrate:

View file

@ -8,12 +8,12 @@
@c %**end of header
@c Version of the software and manual.
@set VERSION 8.2
@set VERSION 8.3
@c Edition of the manual. It is either empty for the first edition or
@c has the form ", nth Edition" (without the quotes).
@set EDITION
@set UPDATED 2009-06-13
@set UPDATE-MONTH June, 2009
@set UPDATED 2011-09-20
@set UPDATE-MONTH September, 2011
@c Other variables.
@set MH-BOOK-HOME http://rand-mh.sourceforge.net/book/mh
@ -212,10 +212,11 @@ more niceties about GNU Emacs and MH@. Now I'm fully hooked on both of
them.
The MH-E package is distributed with Emacs@footnote{Version
@value{VERSION} of MH-E appeared in Emacs 23.1. It is supported
in Emacs 21 and 22, as well as XEmacs 21 (except for versions
21.5.9-21.5.16). It is compatible with MH versions 6.8.4 and higher,
all versions of nmh, and GNU mailutils 1.0 and higher.}, so you
@value{VERSION} of MH-E appeared in Emacs 24.1. It is supported in GNU
Emacs 23 and higher, as well as XEmacs 21.4.22 and 21.5.31. MH-E is
known not to work with GNU Emacs versions 20 and below, and XEmacs
version 21.5.9 - 21.5.16. It is compatible with MH versions 6.8.4 and
higher, all versions of nmh, and GNU mailutils 1.0 and higher}, so you
shouldn't have to do anything special to use it. Gnus is also
required; version 5.10 or higher is recommended. This manual covers
MH-E version @value{VERSION}. To help you decide which version you
@ -8950,8 +8951,8 @@ files that were already part of Emacs) and the software was completely
reorganized to push back two decades of entropy. Version 8 appeared in
Emacs 22.1 in 2006.
Development was then quiet for a couple of years. Emacs 23.1, released
in June 2009, contains version 8.2. This version includes a few
Development was then quiet for a couple of years. Emacs 23.1, which is
due out in 2009, will contain version 8.1. This version includes a few
new features and several bug fixes.
Bill Wohler, August 2008

View file

@ -3,7 +3,7 @@
% Load plain if necessary, i.e., if running under initex.
\expandafter\ifx\csname fmtname\endcsname\relax\input plain\fi
%
\def\texinfoversion{2011-08-14.17}
\def\texinfoversion{2011-09-23.09}
%
% Copyright 1985, 1986, 1988, 1990, 1991, 1992, 1993, 1994, 1995,
% 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006,
@ -3955,13 +3955,13 @@
% If so, set to same dimension as multitablelinespace.
\ifdim\multitableparskip>\multitablelinespace
\global\multitableparskip=\multitablelinespace
\global\advance\multitableparskip-7pt %% to keep parskip somewhat smaller
%% than skip between lines in the table.
\global\advance\multitableparskip-7pt % to keep parskip somewhat smaller
% than skip between lines in the table.
\fi%
\ifdim\multitableparskip=0pt
\global\multitableparskip=\multitablelinespace
\global\advance\multitableparskip-7pt %% to keep parskip somewhat smaller
%% than skip between lines in the table.
\global\advance\multitableparskip-7pt % to keep parskip somewhat smaller
% than skip between lines in the table.
\fi}
@ -7247,9 +7247,15 @@
\def\macroxxx#1{%
\getargs{#1}% now \macname is the macname and \argl the arglist
\ifx\argl\empty % no arguments
\paramno=0
\paramno=0\relax
\else
\expandafter\parsemargdef \argl;%
\if\paramno>256\relax
\ifx\eTeXversion\thisisundefined
\errhelp = \EMsimple
\errmessage{You need eTeX to compile a file with macros with more than 256 arguments}
\fi
\fi
\fi
\if1\csname ismacro.\the\macname\endcsname
\message{Warning: redefining \the\macname}%
@ -7299,9 +7305,17 @@
\def\getmacname#1 #2\relax{\macname={#1}}
\def\getmacargs#1{\def\argl{#1}}
% For macro processing make @ a letter so that we can make Texinfo private macro names.
\edef\texiatcatcode{\the\catcode`\@}
\catcode `@=11\relax
% Parse the optional {params} list. Set up \paramno and \paramlist
% so \defmacro knows what to do. Define \macarg.blah for each blah
% in the params list to be ##N where N is the position in that list.
% so \defmacro knows what to do. Define \macarg.BLAH for each BLAH
% in the params list to some hook where the argument si to be expanded. If
% there are less than 10 arguments that hook is to be replaced by ##N where N
% is the position in that list, that is to say the macro arguments are to be
% defined `a la TeX in the macro body.
%
% That gets used by \mbodybackslash (above).
%
% We need to get `macro parameter char #' into several definitions.
@ -7311,12 +7325,33 @@
%
% The same technique is used to protect \eatspaces till just before
% the macro is used.
%
% If there are 10 or more arguments, a different technique is used, where the
% hook remains in the body, and when macro is to be expanded the body is
% processed again to replace the arguments.
%
% In that case, the hook is \the\toks N-1, and we simply set \toks N-1 to the
% argument N value and then \edef the body (nothing else will expand because of
% the catcode regime underwhich the body was input).
%
% If you compile with TeX (not eTeX), and you have macros with 10 or more
% arguments, you need that no macro has more than 256 arguments, otherwise an
% error is produced.
\def\parsemargdef#1;{%
\paramno=0\def\paramlist{}%
\let\hash\relax
\let\xeatspaces\relax
\parsemargdefxxx#1,;,%
% In case that there are 10 or more arguments we parse again the arguments
% list to set new definitions for the \macarg.BLAH macros corresponding to
% each BLAH argument. It was anyhow needed to parse already once this list
% in order to count the arguments, and as macros with at most 9 arguments
% are by far more frequent than macro with 10 or more arguments, defining
% twice the \macarg.BLAH macros does not cost too much processing power.
\ifnum\paramno<10\relax\else
\paramno0\relax
\parsemmanyargdef@@#1,;,% 10 or more arguments
\fi
}
\def\parsemargdefxxx#1,{%
\if#1;\let\next=\relax
@ -7327,16 +7362,205 @@
\edef\paramlist{\paramlist\hash\the\paramno,}%
\fi\next}
\def\parsemmanyargdef@@#1,{%
\if#1;\let\next=\relax
\else
\let\next=\parsemmanyargdef@@
\edef\tempb{\eatspaces{#1}}%
\expandafter\def\expandafter\tempa
\expandafter{\csname macarg.\tempb\endcsname}%
% Note that we need some extra \noexpand\noexpand, this is because we
% don't want \the to be expanded in the \parsermacbody as it uses an
% \xdef .
\expandafter\edef\tempa
{\noexpand\noexpand\noexpand\the\toks\the\paramno}%
\advance\paramno by 1\relax
\fi\next}
% These two commands read recursive and nonrecursive macro bodies.
% (They're different since rec and nonrec macros end differently.)
%
\catcode `\@\texiatcatcode
\long\def\parsemacbody#1@end macro%
{\xdef\temp{\eatcr{#1}}\endgroup\defmacro}%
\long\def\parsermacbody#1@end rmacro%
{\xdef\temp{\eatcr{#1}}\endgroup\defmacro}%
\catcode `\@=11\relax
% This defines the macro itself. There are six cases: recursive and
% nonrecursive macros of zero, one, and many arguments.
\let\endargs@\relax
\let\nil@\relax
\def\nilm@{\nil@}%
\long\def\nillm@{\nil@}%
% This macro is expanded during the Texinfo macro expansion, not during its
% definition. It gets all the arguments values and assigns them to macros
% macarg.ARGNAME
%
% #1 is the macro name
% #2 is the list of argument names
% #3 is the list of argument values
\def\getargvals@#1#2#3{%
\def\macargdeflist@{}%
\def\saveparamlist@{#2}% Need to keep a copy for parameter expansion.
\def\paramlist{#2,\nil@}%
\def\macroname{#1}%
\begingroup
\macroargctxt
\def\argvaluelist{#3,\nil@}%
\def\@tempa{#3}%
\ifx\@tempa\empty
\setemptyargvalues@
\else
\getargvals@@
\fi
}
%
\def\getargvals@@{%
\ifx\paramlist\nilm@
% Some sanity check needed here that \argvaluelist is also empty.
\ifx\argvaluelist\nillm@
\else
\errhelp = \EMsimple
\errmessage{Too many arguments in macro `\macroname'!}%
\fi
\let\next\macargexpandinbody@
\else
\ifx\argvaluelist\nillm@
% No more arguments values passed to macro. Set remaining named-arg
% macros to empty.
\let\next\setemptyargvalues@
\else
% pop current arg name into \@tempb
\def\@tempa##1{\pop@{\@tempb}{\paramlist}##1\endargs@}%
\expandafter\@tempa\expandafter{\paramlist}%
% pop current argument value into \@tempc
\def\@tempa##1{\longpop@{\@tempc}{\argvaluelist}##1\endargs@}%
\expandafter\@tempa\expandafter{\argvaluelist}%
% Here \@tempb is the current arg name and \@tempc is the current arg value.
% First place the new argument macro definition into \@tempd
\expandafter\macname\expandafter{\@tempc}%
\expandafter\let\csname macarg.\@tempb\endcsname\relax
\expandafter\def\expandafter\@tempe\expandafter{%
\csname macarg.\@tempb\endcsname}%
\edef\@tempd{\long\def\@tempe{\the\macname}}%
\push@\@tempd\macargdeflist@
\let\next\getargvals@@
\fi
\fi
\next
}
\def\push@#1#2{%
\expandafter\expandafter\expandafter\def
\expandafter\expandafter\expandafter#2%
\expandafter\expandafter\expandafter{%
\expandafter#1#2}%
}
% Replace arguments by their values in the macro body, and place the result
% in macro \@tempa
\def\macvalstoargs@{%
% To do this we use the property that token registers that are \the'ed
% within an \edef expand only once. So we are going to place all argument
% values into respective token registers.
%
% First we save the token context, and initialize argument numbering.
\begingroup
\paramno0\relax
% Then, for each argument number #N, we place the corresponding argument
% value into a new token list register \toks#N
\expandafter\putargsintokens@\saveparamlist@,;,%
% Then, we expand the body so that argument are replaced by their
% values. The trick for values not to be expanded themselves is that they
% are within tokens and that tokens expand only once in an \edef .
\edef\@tempc{\csname mac.\macroname .body\endcsname}%
% Now we restore the token stack pointer to free the token list registers
% which we have used, but we make sure that expanded body is saved after
% group.
\expandafter
\endgroup
\expandafter\def\expandafter\@tempa\expandafter{\@tempc}%
}
\def\macargexpandinbody@{%
%% Define the named-macro outside of this group and then close this group.
\expandafter
\endgroup
\macargdeflist@
% First the replace in body the macro arguments by their values, the result
% is in \@tempa .
\macvalstoargs@
% Then we point at the \norecurse or \gobble (for recursive) macro value
% with \@tempb .
\expandafter\let\expandafter\@tempb\csname mac.\macroname .recurse\endcsname
% Depending on whether it is recursive or not, we need some tailing
% \egroup .
\ifx\@tempb\gobble
\let\@tempc\relax
\else
\let\@tempc\egroup
\fi
% And now we do the real job:
\edef\@tempd{\noexpand\@tempb{\macroname}\noexpand\scanmacro{\@tempa}\@tempc}%
\@tempd
}
\def\putargsintokens@#1,{%
\if#1;\let\next\relax
\else
\let\next\putargsintokens@
% First we allocate the new token list register, and give it a temporary
% alias \@tempb .
\toksdef\@tempb\the\paramno
% Then we place the argument value into that token list register.
\expandafter\let\expandafter\@tempa\csname macarg.#1\endcsname
\expandafter\@tempb\expandafter{\@tempa}%
\advance\paramno by 1\relax
\fi
\next
}
% Save the token stack pointer into macro #1
\def\texisavetoksstackpoint#1{\edef#1{\the\@cclvi}}
% Restore the token stack pointer from number in macro #1
\def\texirestoretoksstackpoint#1{\expandafter\mathchardef\expandafter\@cclvi#1\relax}
% newtoks that can be used non \outer .
\def\texinonouternewtoks{\alloc@ 5\toks \toksdef \@cclvi}
% Tailing missing arguments are set to empty
\def\setemptyargvalues@{%
\ifx\paramlist\nilm@
\let\next\macargexpandinbody@
\else
\expandafter\setemptyargvaluesparser@\paramlist\endargs@
\let\next\setemptyargvalues@
\fi
\next
}
\def\setemptyargvaluesparser@#1,#2\endargs@{%
\expandafter\def\expandafter\@tempa\expandafter{%
\expandafter\def\csname macarg.#1\endcsname{}}%
\push@\@tempa\macargdeflist@
\def\paramlist{#2}%
}
% #1 is the element target macro
% #2 is the list macro
% #3,#4\endargs@ is the list value
\def\pop@#1#2#3,#4\endargs@{%
\def#1{#3}%
\def#2{#4}%
}
\long\def\longpop@#1#2#3,#4\endargs@{%
\long\def#1{#3}%
\long\def#2{#4}%
}
% This defines a Texinfo @macro. There are eight cases: recursive and
% nonrecursive macros of zero, one, up to nine, and many arguments.
% Much magic with \expandafter here.
% \xdef is used so that macro definitions will survive the file
% they're defined in; @include reads the file inside a group.
@ -7355,17 +7579,25 @@
\expandafter\noexpand\csname\the\macname xxx\endcsname}%
\expandafter\xdef\csname\the\macname xxx\endcsname##1{%
\egroup\noexpand\scanmacro{\temp}}%
\else % many
\expandafter\xdef\csname\the\macname\endcsname{%
\bgroup\noexpand\macroargctxt
\noexpand\csname\the\macname xx\endcsname}%
\expandafter\xdef\csname\the\macname xx\endcsname##1{%
\expandafter\noexpand\csname\the\macname xxx\endcsname ##1,}%
\expandafter\expandafter
\expandafter\xdef
\expandafter\expandafter
\csname\the\macname xxx\endcsname
\paramlist{\egroup\noexpand\scanmacro{\temp}}%
\else
\ifnum\paramno<10\relax % at most 9
\expandafter\xdef\csname\the\macname\endcsname{%
\bgroup\noexpand\macroargctxt
\noexpand\csname\the\macname xx\endcsname}%
\expandafter\xdef\csname\the\macname xx\endcsname##1{%
\expandafter\noexpand\csname\the\macname xxx\endcsname ##1,}%
\expandafter\expandafter
\expandafter\xdef
\expandafter\expandafter
\csname\the\macname xxx\endcsname
\paramlist{\egroup\noexpand\scanmacro{\temp}}%
\else % 10 or more
\expandafter\xdef\csname\the\macname\endcsname{%
\noexpand\getargvals@{\the\macname}{\argl}%
}%
\global\expandafter\let\csname mac.\the\macname .body\endcsname\temp
\global\expandafter\let\csname mac.\the\macname .recurse\endcsname\gobble
\fi
\fi
\else
\ifcase\paramno
@ -7382,23 +7614,33 @@
\egroup
\noexpand\norecurse{\the\macname}%
\noexpand\scanmacro{\temp}\egroup}%
\else % many
\expandafter\xdef\csname\the\macname\endcsname{%
\bgroup\noexpand\macroargctxt
\expandafter\noexpand\csname\the\macname xx\endcsname}%
\expandafter\xdef\csname\the\macname xx\endcsname##1{%
\expandafter\noexpand\csname\the\macname xxx\endcsname ##1,}%
\expandafter\expandafter
\expandafter\xdef
\expandafter\expandafter
\csname\the\macname xxx\endcsname
\paramlist{%
\egroup
\noexpand\norecurse{\the\macname}%
\noexpand\scanmacro{\temp}\egroup}%
\else % at most 9
\ifnum\paramno<10\relax
\expandafter\xdef\csname\the\macname\endcsname{%
\bgroup\noexpand\macroargctxt
\expandafter\noexpand\csname\the\macname xx\endcsname}%
\expandafter\xdef\csname\the\macname xx\endcsname##1{%
\expandafter\noexpand\csname\the\macname xxx\endcsname ##1,}%
\expandafter\expandafter
\expandafter\xdef
\expandafter\expandafter
\csname\the\macname xxx\endcsname
\paramlist{%
\egroup
\noexpand\norecurse{\the\macname}%
\noexpand\scanmacro{\temp}\egroup}%
\else % 10 or more:
\expandafter\xdef\csname\the\macname\endcsname{%
\noexpand\getargvals@{\the\macname}{\argl}%
}%
\global\expandafter\let\csname mac.\the\macname .body\endcsname\temp
\global\expandafter\let\csname mac.\the\macname .recurse\endcsname\norecurse
\fi
\fi
\fi}
\catcode `\@\texiatcatcode\relax
\def\norecurse#1{\bgroup\cslet{#1}{macsave.#1}}
% \braceorline decides whether the next nonwhitespace character is a

File diff suppressed because it is too large Load diff

View file

@ -1,3 +1,13 @@
2011-09-23 Martin Rudalics <rudalics@gmx.at>
* NEWS: Document some window code changes.
2011-09-20 Bill Wohler <wohler@newt.com>
Release MH-E version 8.3.
* NEWS, MH-E-NEWS: Update for MH-E release 8.3.
2011-09-13 William Stevenson <yhvh2000@gmail.com>
* themes/adwaita-theme.el: New file.

View file

@ -3,33 +3,12 @@
Copyright (C) 2001-2011 Free Software Foundation, Inc.
See the end of the file for license conditions.
* Changes in MH-E 8.2.93
Version 8.2.93 reverts back to using `switch-to-buffer' which the
Emacs developers decided was fine to call from programs after all.
* Changes in MH-E 8.2.92
Version 8.2.92 actually corrects the error in the modeline glyph when
running XEmacs 21.5.31 in a terminal.
* Changes in MH-E 8.2.91
Version 8.2.91 fixes the folder window problem that was introduced
in 8.2.90. It also fixes compilation warnings in XEmacs 21.5.31, as
well as an error when running XEmacs 21.5.31 in a terminal.
Another implication of the VCS change is that users who download MH-E
from SourceForge and explicitly load MH-E will have to be change their
`load-path' to "/path/to/mh-e/emacs/trunk/lisp/mh-e" instead. Note the
addition of "trunk."
* Changes in MH-E 8.2.90
* Changes in MH-E 8.3
In 2010, the version control system (VCS) of Emacs was upgraded from
CVS to Bazaar. In 2011, the MH-E team followed suit and upgraded the
MH-E repository at SourceForge from CVS to Bazaar as well. The result
is version 8.2.90 of MH-E, which includes needed changes to the build
is version 8.3 of MH-E, which includes needed changes to the build
scripts.
Otherwise, this is a small release that includes mostly internal
@ -40,9 +19,17 @@ meaning that `+f/b/b TAB' can complete to `+foo/bar/baz'.
Also, RFC 2047-encoded Subject header fields in replies are now
decoded.
It also fixes compilation warnings in XEmacs 21.5.31, as
well as an error when running XEmacs 21.5.31 in a terminal.
Another implication of the VCS change is that users who download MH-E
from SourceForge and explicitly load MH-E will have to be change their
`load-path' to "/path/to/mh-e/emacs/trunk/lisp/mh-e" instead. Note the
addition of "trunk."
This version of MH-E is packaged with GNU Emacs 24.1
** Bug Fixes in MH-E 8.2.90
** Bug Fixes in MH-E 8.3
*** Make mh-showing a legitimate minor mode

145
etc/NEWS
View file

@ -386,6 +386,50 @@ by default.
*** `menu-bar-select-buffer-function' lets you choose another operation
instead of `switch-to-buffer' when selecting an item in the Buffers menu.
** Window changes
+++
*** Resizing an Emacs frame now preserves proportional window sizes,
modulo restrictions like window minimum sizes and fixed-size windows.
*** The behavior of `display-buffer' is now customizable in detail.
**** New option `display-buffer-base-action' specifies a list of
user-determined display "actions" (functions and optional arguments
for choosing the displaying window).
This takes precedence over the default display action, which is
specified by `display-buffer-fallback-action'.
**** New option `display-buffer-alist' maps buffer name regexps to
display actions, taking precedence over `display-buffer-base-action'.
+++
*** New option `window-nest'.
The new option `window-nest' allows to return the space obtained for
resizing or creating a window more reliably to the window from which
such space was obtained.
+++
*** New option `window-splits'.
The new option `window-splits' allows to split a window that otherwise
cannot be split because it's too small by stealing space from other
windows in the same combination.
+++
*** New commands `maximize-window' and `minimize-window'.
These maximize and minize the size of a window within its frame.
+++
*** New commands `switch-to-prev-buffer' and `switch-to-next-buffer'.
These functions allow to navigate through the live buffers that have
been shown in a specific window.
+++
*** New functions `window-state-get' and `window-state-put'.
These functions allow to save and restore the state of an arbitrary
frame or window as an Elisp object.
** The inactive minibuffer has its own major mode `minibuffer-inactive-mode'.
This is handy for minibuffer-only frames, and is also used for the "mouse-1
pops up *Messages*" feature, which can now easily be changed.
@ -410,7 +454,7 @@ isearch-yank-kill.
** The default value of `backup-by-copying-when-mismatch' is now t.
** The command `just-one-space' (C-SPC), if given a negative argument,
** The command `just-one-space' (M-SPC), if given a negative argument,
also deletes newlines around point.
** Deletion changes
@ -500,6 +544,13 @@ prompts for a number to count from and for a format string.
directory is a remote file name and neither environment variable
$ESHELL nor variable `explicit-shell-file-name' is set.
+++
** The default value of redisplay-dont-change is now t
This makes Emacs feel more responsive to editing commands that arrive
at high rate, e.g. if you lean on some key, because stopping redisplay
in the middle (when this variable is nil) forces more expensive
updates later on, and Emacs appears to be unable to keep up.
* Changes in Specialized Modes and Packages in Emacs 24.1
@ -654,7 +705,7 @@ consult.
** The Landmark game is now invoked with `landmark', not `lm'.
** MH-E has been upgraded to MH-E version 8.2.93.
** MH-E has been upgraded to MH-E version 8.3.
See MH-E-NEWS for details.
** Modula-2 mode provides auto-indentation.
@ -961,12 +1012,100 @@ of the line.
** Window changes
+++
*** Window tree functions are accessible in Elisp.
Functions are provided to return the parent, siblings or child windows
of any window including internal windows (windows not associated with a
buffer) in the window tree.
+++
*** Window manipulation can deal with internal windows.
Many window handling functions like `split-window', `delete-window', or
`delete-other-windows' as well as the window resizing functions can now
act on any window including internal ones.
+++
*** window-total-height/-width vs window-body-height/-width.
The function `window-height' has been renamed to `window-total-height'
and `window-width' has been renamed to `window-body-width'. The old
names are provided as aliases. Two new functions `window-total-width'
and `window-body-height' are provided.
+++
*** Window parameters specific to window handling functions.
For each window you can specify a parameter to override the default
behavior of a number of functions like `split-window', `delete-window'
and `delete-other-windows'. The variable `ignore-window-parameters'
allows to ignore processing such parameters.
+++
*** New semantics of third argument of `split-window'.
The third argument of `split-window' has been renamed to SIDE and can be
set to any of the values 'below, 'right, 'above, or 'left to make the
new window appear on the corresponding side of the window that shall be
split. Any other value of SIDE will cause `split-window' to split the
window into two side-by-side windows as before.
+++
*** `split-window-above-each-other' and `split-window-side-by-side'.
The commands `split-window-vertically' and `split-window-horizontally'
have been renamed to `split-window-above-each-other' and
`split-window-side-by-side' respectively. The old names are provided as
aliases.
+++
*** Window resizing functions.
A new standard function for resizing windows called `resize-window' has
been introduced. This and all other functions for resizing windows no
longer delete any windows when they become too small.
+++
*** `adjust-window-trailing-edge' adjustments.
`adjust-window-trailing-edge' can now deal with fixed-size windows and
is able to resize other windows if a window adjacent to the trailing
edge cannot be shrunk any more. This makes its behavior more similar to
that of Emacs 21 without compromising, however, its inability to delete
windows which was introduced in Emacs 22.
+++
*** Window-local buffer lists.
Windows now have local buffer lists. This means that removing a buffer
from display in a window will preferably show the buffer previously
shown in that window with its previous window-start and window-point
positions. This also means that the same buffer may be automatically
shown twice even if it already appears in another window.
+++
*** `switch-to-buffer' has a new optional argument FORCE-SAME-WINDOW,
which if non-nil requires the buffer to be displayed in the currently
selected window, signaling an error otherwise. If nil, another window
can be used, e.g. if the selected one is strongly dedicated.
*** FIXME: buffer-display-alist changes
*** `split-window-vertically' and `split-window-horizontally' renamed
to `split-window-above-each-other' and `split-window-side-by-side'
respectively. The old names are kept as aliases.
*** Display actions
**** The second arg to `display-buffer' and `pop-to-buffer' is now
named ACTION, and takes a display action of the same form as
`display-buffer-base-action' (see Changes, above). A non-nil,
non-list value is treated specially, as the old meaning.
**** New variable `display-buffer-overriding-action'.
**** The procedure of `display-buffer' etc. to choose a window is
determined by combining `display-buffer-overriding-action',
`display-buffer-alist', the ACTION arg, `display-buffer-base-action',
and `display-buffer-fallback-action'. The second and fourth of these
are user-customizable variables.
See the docstring of `display-buffer' for details.
+++
*** New behavior of `quit-window'.
The behavior of `quit-window' has been changed in order to restore the
state before the last buffer display operation in that window.
** Completion

View file

@ -503,6 +503,12 @@ This can happen with CVS versions 1.12.8 and 1.12.9. Upgrade to CVS
** Miscellaneous problems
*** Editing files with very long lines is slow.
For example, simply moving through a file that contains hundreds of
thousands of characters per line is slow, and consumes a lot of CPU.
This is a known limitation of Emacs with no solution at this time.
*** Emacs uses 100% of CPU time
This is a known problem with some versions of the Semantic package.

View file

@ -25,21 +25,26 @@
#include <errno.h>
#include <fcntl.h>
#if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
/* Get declarations of the Win32 API functions. */
# define WIN32_LEAN_AND_MEAN
# include <windows.h>
#endif
#if HAVE_DUP2
# undef dup2
int
rpl_dup2 (int fd, int desired_fd)
# if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
/* Get declarations of the Win32 API functions. */
# define WIN32_LEAN_AND_MEAN
# include <windows.h>
# include "msvc-inval.h"
/* Get _get_osfhandle. */
# include "msvc-nothrow.h"
static int
ms_windows_dup2 (int fd, int desired_fd)
{
int result;
# if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
/* If fd is closed, mingw hangs on dup2 (fd, fd). If fd is open,
dup2 (fd, fd) returns 0, but all further attempts to use fd in
future dup2 calls will hang. */
@ -52,6 +57,7 @@ rpl_dup2 (int fd, int desired_fd)
}
return fd;
}
/* Wine 1.0.1 return 0 when desired_fd is negative but not -1:
http://bugs.winehq.org/show_bug.cgi?id=21289 */
if (desired_fd < 0)
@ -59,26 +65,45 @@ rpl_dup2 (int fd, int desired_fd)
errno = EBADF;
return -1;
}
# elif !defined __linux__
/* On Haiku, dup2 (fd, fd) mistakenly clears FD_CLOEXEC. */
if (fd == desired_fd)
return fcntl (fd, F_GETFL) == -1 ? -1 : fd;
# endif
result = dup2 (fd, desired_fd);
# ifdef __linux__
/* Correct a Linux return value.
<http://git.kernel.org/?p=linux/kernel/git/stable/linux-2.6.30.y.git;a=commitdiff;h=2b79bc4f7ebbd5af3c8b867968f9f15602d5f802>
*/
if (fd == desired_fd && result == (unsigned int) -EBADF)
TRY_MSVC_INVAL
{
result = dup2 (fd, desired_fd);
}
CATCH_MSVC_INVAL
{
errno = EBADF;
result = -1;
}
# endif
DONE_MSVC_INVAL;
if (result == 0)
result = desired_fd;
/* Correct a cygwin 1.5.x errno value. */
else if (result == -1 && errno == EMFILE)
return result;
}
# define dup2 ms_windows_dup2
# endif
int
rpl_dup2 (int fd, int desired_fd)
{
int result;
# ifdef F_GETFL
/* On Linux kernels 2.6.26-2.6.29, dup2 (fd, fd) returns -EBADF.
On Cygwin 1.5.x, dup2 (1, 1) returns 0.
On Haiku, dup2 (fd, fd) mistakenly clears FD_CLOEXEC. */
if (fd == desired_fd)
return fcntl (fd, F_GETFL) == -1 ? -1 : fd;
# endif
result = dup2 (fd, desired_fd);
/* Correct an errno value on FreeBSD 6.1 and Cygwin 1.5.x. */
if (result == -1 && errno == EMFILE)
errno = EBADF;
# if REPLACE_FCHDIR
if (fd != desired_fd && result != -1)

View file

@ -2,14 +2,26 @@
## Process this file with automake to produce Makefile.in.
# Copyright (C) 2002-2011 Free Software Foundation, Inc.
#
# This file is free software, distributed under the terms of the GNU
# General Public License. As a special exception to the GNU General
# Public License, this file may be distributed as part of a program
# that contains a configuration script generated by Autoconf, under
# This file 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 3 of the License, or
# (at your option) any later version.
#
# This file 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 this file. If not, see <http://www.gnu.org/licenses/>.
#
# As a special exception to the GNU General Public License,
# this file may be distributed as part of a program that
# contains a configuration script generated by Autoconf, under
# the same distribution terms as the rest of that program.
#
# Generated by gnulib-tool.
# Reproduce by: gnulib-tool --import --dir=. --lib=libgnu --source-base=lib --m4-base=m4 --doc-base=doc --tests-base=tests --aux-dir=build-aux --avoid=threadlib --makefile-name=gnulib.mk --conditional-dependencies --no-libtool --macro-prefix=gl --no-vc-files alloca-opt careadlinkat crypto/md5 crypto/sha1 crypto/sha256 crypto/sha512 dtoastr dup2 filemode getloadavg getopt-gnu ignore-value intprops lstat mktime pthread_sigmask readlink socklen stdarg stdio strftime strtoimax strtoumax symlink sys_stat
# Reproduce by: gnulib-tool --import --dir=. --lib=libgnu --source-base=lib --m4-base=m4 --doc-base=doc --tests-base=tests --aux-dir=build-aux --avoid=msvc-inval --avoid=msvc-nothrow --avoid=pathmax --avoid=raise --avoid=threadlib --makefile-name=gnulib.mk --conditional-dependencies --no-libtool --macro-prefix=gl --no-vc-files alloca-opt careadlinkat crypto/md5 crypto/sha1 crypto/sha256 crypto/sha512 dtoastr dup2 filemode getloadavg getopt-gnu ignore-value intprops lstat mktime pthread_sigmask readlink socklen stdarg stdio strftime strtoimax strtoumax symlink sys_stat
MOSTLYCLEANFILES += core *.stackdump
@ -264,7 +276,7 @@ EXTRA_libgnu_a_SOURCES += readlink.c
## end gnulib module readlink
## begin gnulib module signal
## begin gnulib module signal-h
BUILT_SOURCES += signal.h
@ -279,11 +291,13 @@ signal.h: signal.in.h $(top_builddir)/config.status $(CXXDEFS_H) $(ARG_NONNULL_H
-e 's|@''PRAGMA_COLUMNS''@|@PRAGMA_COLUMNS@|g' \
-e 's|@''NEXT_SIGNAL_H''@|$(NEXT_SIGNAL_H)|g' \
-e 's|@''GNULIB_PTHREAD_SIGMASK''@|$(GNULIB_PTHREAD_SIGMASK)|g' \
-e 's|@''GNULIB_RAISE''@|$(GNULIB_RAISE)|g' \
-e 's/@''GNULIB_SIGNAL_H_SIGPIPE''@/$(GNULIB_SIGNAL_H_SIGPIPE)/g' \
-e 's/@''GNULIB_SIGPROCMASK''@/$(GNULIB_SIGPROCMASK)/g' \
-e 's/@''GNULIB_SIGACTION''@/$(GNULIB_SIGACTION)/g' \
-e 's|@''HAVE_POSIX_SIGNALBLOCKING''@|$(HAVE_POSIX_SIGNALBLOCKING)|g' \
-e 's|@''HAVE_PTHREAD_SIGMASK''@|$(HAVE_PTHREAD_SIGMASK)|g' \
-e 's|@''HAVE_RAISE''@|$(HAVE_RAISE)|g' \
-e 's|@''HAVE_SIGSET_T''@|$(HAVE_SIGSET_T)|g' \
-e 's|@''HAVE_SIGINFO_T''@|$(HAVE_SIGINFO_T)|g' \
-e 's|@''HAVE_SIGACTION''@|$(HAVE_SIGACTION)|g' \
@ -291,6 +305,7 @@ signal.h: signal.in.h $(top_builddir)/config.status $(CXXDEFS_H) $(ARG_NONNULL_H
-e 's|@''HAVE_TYPE_VOLATILE_SIG_ATOMIC_T''@|$(HAVE_TYPE_VOLATILE_SIG_ATOMIC_T)|g' \
-e 's|@''HAVE_SIGHANDLER_T''@|$(HAVE_SIGHANDLER_T)|g' \
-e 's|@''REPLACE_PTHREAD_SIGMASK''@|$(REPLACE_PTHREAD_SIGMASK)|g' \
-e 's|@''REPLACE_RAISE''@|$(REPLACE_RAISE)|g' \
-e '/definitions of _GL_FUNCDECL_RPL/r $(CXXDEFS_H)' \
-e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \
-e '/definition of _GL_WARN_ON_USE/r $(WARN_ON_USE_H)' \
@ -301,7 +316,7 @@ MOSTLYCLEANFILES += signal.h signal.h-t
EXTRA_DIST += signal.in.h
## end gnulib module signal
## end gnulib module signal-h
## begin gnulib module sigprocmask
@ -553,6 +568,7 @@ stdio.h: stdio.in.h $(top_builddir)/config.status $(CXXDEFS_H) $(ARG_NONNULL_H)
-e 's|@''NEXT_STDIO_H''@|$(NEXT_STDIO_H)|g' \
-e 's/@''GNULIB_DPRINTF''@/$(GNULIB_DPRINTF)/g' \
-e 's/@''GNULIB_FCLOSE''@/$(GNULIB_FCLOSE)/g' \
-e 's/@''GNULIB_FDOPEN''@/$(GNULIB_FDOPEN)/g' \
-e 's/@''GNULIB_FFLUSH''@/$(GNULIB_FFLUSH)/g' \
-e 's/@''GNULIB_FGETC''@/$(GNULIB_FGETC)/g' \
-e 's/@''GNULIB_FGETS''@/$(GNULIB_FGETS)/g' \
@ -577,6 +593,7 @@ stdio.h: stdio.in.h $(top_builddir)/config.status $(CXXDEFS_H) $(ARG_NONNULL_H)
-e 's/@''GNULIB_GETS''@/$(GNULIB_GETS)/g' \
-e 's/@''GNULIB_OBSTACK_PRINTF''@/$(GNULIB_OBSTACK_PRINTF)/g' \
-e 's/@''GNULIB_OBSTACK_PRINTF_POSIX''@/$(GNULIB_OBSTACK_PRINTF_POSIX)/g' \
-e 's/@''GNULIB_PCLOSE''@/$(GNULIB_PCLOSE)/g' \
-e 's/@''GNULIB_PERROR''@/$(GNULIB_PERROR)/g' \
-e 's/@''GNULIB_POPEN''@/$(GNULIB_POPEN)/g' \
-e 's/@''GNULIB_PRINTF''@/$(GNULIB_PRINTF)/g' \
@ -615,11 +632,14 @@ stdio.h: stdio.in.h $(top_builddir)/config.status $(CXXDEFS_H) $(ARG_NONNULL_H)
-e 's|@''HAVE_DPRINTF''@|$(HAVE_DPRINTF)|g' \
-e 's|@''HAVE_FSEEKO''@|$(HAVE_FSEEKO)|g' \
-e 's|@''HAVE_FTELLO''@|$(HAVE_FTELLO)|g' \
-e 's|@''HAVE_PCLOSE''@|$(HAVE_PCLOSE)|g' \
-e 's|@''HAVE_POPEN''@|$(HAVE_POPEN)|g' \
-e 's|@''HAVE_RENAMEAT''@|$(HAVE_RENAMEAT)|g' \
-e 's|@''HAVE_VASPRINTF''@|$(HAVE_VASPRINTF)|g' \
-e 's|@''HAVE_VDPRINTF''@|$(HAVE_VDPRINTF)|g' \
-e 's|@''REPLACE_DPRINTF''@|$(REPLACE_DPRINTF)|g' \
-e 's|@''REPLACE_FCLOSE''@|$(REPLACE_FCLOSE)|g' \
-e 's|@''REPLACE_FDOPEN''@|$(REPLACE_FDOPEN)|g' \
-e 's|@''REPLACE_FFLUSH''@|$(REPLACE_FFLUSH)|g' \
-e 's|@''REPLACE_FOPEN''@|$(REPLACE_FOPEN)|g' \
-e 's|@''REPLACE_FPRINTF''@|$(REPLACE_FPRINTF)|g' \
@ -826,6 +846,7 @@ sys/stat.h: sys_stat.in.h $(top_builddir)/config.status $(CXXDEFS_H) $(ARG_NONNU
-e 's|@''PRAGMA_COLUMNS''@|@PRAGMA_COLUMNS@|g' \
-e 's|@''NEXT_SYS_STAT_H''@|$(NEXT_SYS_STAT_H)|g' \
-e 's/@''GNULIB_FCHMODAT''@/$(GNULIB_FCHMODAT)/g' \
-e 's/@''GNULIB_FSTAT''@/$(GNULIB_FSTAT)/g' \
-e 's/@''GNULIB_FSTATAT''@/$(GNULIB_FSTATAT)/g' \
-e 's/@''GNULIB_FUTIMENS''@/$(GNULIB_FUTIMENS)/g' \
-e 's/@''GNULIB_LCHMOD''@/$(GNULIB_LCHMOD)/g' \
@ -943,8 +964,10 @@ unistd.h: unistd.in.h $(top_builddir)/config.status $(CXXDEFS_H) $(ARG_NONNULL_H
-e 's|@''PRAGMA_SYSTEM_HEADER''@|@PRAGMA_SYSTEM_HEADER@|g' \
-e 's|@''PRAGMA_COLUMNS''@|@PRAGMA_COLUMNS@|g' \
-e 's|@''NEXT_UNISTD_H''@|$(NEXT_UNISTD_H)|g' \
-e 's/@''GNULIB_CHDIR''@/$(GNULIB_CHDIR)/g' \
-e 's/@''GNULIB_CHOWN''@/$(GNULIB_CHOWN)/g' \
-e 's/@''GNULIB_CLOSE''@/$(GNULIB_CLOSE)/g' \
-e 's/@''GNULIB_DUP''@/$(GNULIB_DUP)/g' \
-e 's/@''GNULIB_DUP2''@/$(GNULIB_DUP2)/g' \
-e 's/@''GNULIB_DUP3''@/$(GNULIB_DUP3)/g' \
-e 's/@''GNULIB_ENVIRON''@/$(GNULIB_ENVIRON)/g' \
@ -952,6 +975,7 @@ unistd.h: unistd.in.h $(top_builddir)/config.status $(CXXDEFS_H) $(ARG_NONNULL_H
-e 's/@''GNULIB_FACCESSAT''@/$(GNULIB_FACCESSAT)/g' \
-e 's/@''GNULIB_FCHDIR''@/$(GNULIB_FCHDIR)/g' \
-e 's/@''GNULIB_FCHOWNAT''@/$(GNULIB_FCHOWNAT)/g' \
-e 's/@''GNULIB_FDATASYNC''@/$(GNULIB_FDATASYNC)/g' \
-e 's/@''GNULIB_FSYNC''@/$(GNULIB_FSYNC)/g' \
-e 's/@''GNULIB_FTRUNCATE''@/$(GNULIB_FTRUNCATE)/g' \
-e 's/@''GNULIB_GETCWD''@/$(GNULIB_GETCWD)/g' \
@ -995,6 +1019,7 @@ unistd.h: unistd.in.h $(top_builddir)/config.status $(CXXDEFS_H) $(ARG_NONNULL_H
-e 's|@''HAVE_FACCESSAT''@|$(HAVE_FACCESSAT)|g' \
-e 's|@''HAVE_FCHDIR''@|$(HAVE_FCHDIR)|g' \
-e 's|@''HAVE_FCHOWNAT''@|$(HAVE_FCHOWNAT)|g' \
-e 's|@''HAVE_FDATASYNC''@|$(HAVE_FDATASYNC)|g' \
-e 's|@''HAVE_FSYNC''@|$(HAVE_FSYNC)|g' \
-e 's|@''HAVE_FTRUNCATE''@|$(HAVE_FTRUNCATE)|g' \
-e 's|@''HAVE_GETDTABLESIZE''@|$(HAVE_GETDTABLESIZE)|g' \
@ -1019,6 +1044,7 @@ unistd.h: unistd.in.h $(top_builddir)/config.status $(CXXDEFS_H) $(ARG_NONNULL_H
-e 's|@''HAVE_USLEEP''@|$(HAVE_USLEEP)|g' \
-e 's|@''HAVE_DECL_ENVIRON''@|$(HAVE_DECL_ENVIRON)|g' \
-e 's|@''HAVE_DECL_FCHDIR''@|$(HAVE_DECL_FCHDIR)|g' \
-e 's|@''HAVE_DECL_FDATASYNC''@|$(HAVE_DECL_FDATASYNC)|g' \
-e 's|@''HAVE_DECL_GETDOMAINNAME''@|$(HAVE_DECL_GETDOMAINNAME)|g' \
-e 's|@''HAVE_DECL_GETLOGIN_R''@|$(HAVE_DECL_GETLOGIN_R)|g' \
-e 's|@''HAVE_DECL_GETPAGESIZE''@|$(HAVE_DECL_GETPAGESIZE)|g' \

View file

@ -152,6 +152,29 @@ _GL_WARN_ON_USE (pthread_sigmask, "pthread_sigmask is not portable - "
#endif
#if @GNULIB_RAISE@
# if @REPLACE_RAISE@
# if !(defined __cplusplus && defined GNULIB_NAMESPACE)
# undef raise
# define raise rpl_raise
# endif
_GL_FUNCDECL_RPL (raise, int, (int sig));
_GL_CXXALIAS_RPL (raise, int, (int sig));
# else
# if !@HAVE_RAISE@
_GL_FUNCDECL_SYS (raise, int, (int sig));
# endif
_GL_CXXALIAS_SYS (raise, int, (int sig));
# endif
_GL_CXXALIASWARN (raise);
#elif defined GNULIB_POSIXCHECK
# undef raise
/* Assume raise is always declared. */
_GL_WARN_ON_USE (raise, "raise can crash on native Windows - "
"use gnulib module raise for portability");
#endif
#if @GNULIB_SIGPROCMASK@
# if !@HAVE_POSIX_SIGNALBLOCKING@

View file

@ -24,6 +24,10 @@
#include <stdint.h>
#include <stdlib.h>
#if HAVE_MSVC_INVALID_PARAMETER_HANDLER
# include "msvc-inval.h"
#endif
/* We assume that a platform without POSIX signal blocking functions
also does not have the POSIX sigaction() function, only the
signal() function. We also assume signal() has SysV semantics,
@ -58,6 +62,28 @@
typedef void (*handler_t) (int);
#if HAVE_MSVC_INVALID_PARAMETER_HANDLER
static inline handler_t
signal_nothrow (int sig, handler_t handler)
{
handler_t result;
TRY_MSVC_INVAL
{
result = signal (sig, handler);
}
CATCH_MSVC_INVAL
{
result = SIG_ERR;
errno = EINVAL;
}
DONE_MSVC_INVAL;
return result;
}
# define signal signal_nothrow
#endif
/* Handling of gnulib defined signals. */
#if GNULIB_defined_SIGPIPE
@ -80,6 +106,7 @@ ext_signal (int sig, handler_t handler)
return signal (sig, handler);
}
}
# undef signal
# define signal ext_signal
#endif

View file

@ -46,6 +46,15 @@ orig_stat (const char *filename, struct stat *buf)
#include "dosname.h"
#include "verify.h"
#if REPLACE_FUNC_STAT_DIR
# include "pathmax.h"
/* The only known systems where REPLACE_FUNC_STAT_DIR is needed also
have a constant PATH_MAX. */
# ifndef PATH_MAX
# error "Please port this replacement to your platform"
# endif
#endif
/* Store information about NAME into ST. Work around bugs with
trailing slashes. Mingw has other bugs (such as st_ino always
being 0 on success) which this wrapper does not work around. But
@ -70,11 +79,6 @@ rpl_stat (char const *name, struct stat *st)
}
#endif /* REPLACE_FUNC_STAT_FILE */
#if REPLACE_FUNC_STAT_DIR
/* The only known systems where REPLACE_FUNC_STAT_DIR is needed also
have a constant PATH_MAX. */
# ifndef PATH_MAX
# error "Please port this replacement to your platform"
# endif
if (result == -1 && errno == ENOENT)
{

View file

@ -170,6 +170,26 @@ _GL_WARN_ON_USE (fclose, "fclose is not always POSIX compliant - "
"use gnulib module fclose for portable POSIX compliance");
#endif
#if @GNULIB_FDOPEN@
# if @REPLACE_FDOPEN@
# if !(defined __cplusplus && defined GNULIB_NAMESPACE)
# undef fdopen
# define fdopen rpl_fdopen
# endif
_GL_FUNCDECL_RPL (fdopen, FILE *, (int fd, const char *mode)
_GL_ARG_NONNULL ((2)));
_GL_CXXALIAS_RPL (fdopen, FILE *, (int fd, const char *mode));
# else
_GL_CXXALIAS_SYS (fdopen, FILE *, (int fd, const char *mode));
# endif
_GL_CXXALIASWARN (fdopen);
#elif defined GNULIB_POSIXCHECK
# undef fdopen
/* Assume fdopen is always declared. */
_GL_WARN_ON_USE (fdopen, "fdopen on Win32 platforms is not POSIX compatible - "
"use gnulib module fdopen for portability");
#endif
#if @GNULIB_FFLUSH@
/* Flush all pending data on STREAM according to POSIX rules. Both
output and seekable input streams are supported.
@ -750,6 +770,20 @@ _GL_CXXALIAS_SYS (obstack_vprintf, int,
_GL_CXXALIASWARN (obstack_vprintf);
#endif
#if @GNULIB_PCLOSE@
# if !@HAVE_PCLOSE@
_GL_FUNCDECL_SYS (pclose, int, (FILE *stream) _GL_ARG_NONNULL ((1)));
# endif
_GL_CXXALIAS_SYS (pclose, int, (FILE *stream));
_GL_CXXALIASWARN (pclose);
#elif defined GNULIB_POSIXCHECK
# undef pclose
# if HAVE_RAW_DECL_PCLOSE
_GL_WARN_ON_USE (pclose, "popen is unportable - "
"use gnulib module pclose for more portability");
# endif
#endif
#if @GNULIB_PERROR@
/* Print a message to standard error, describing the value of ERRNO,
(if STRING is not NULL and not empty) prefixed with STRING and ": ",
@ -781,6 +815,10 @@ _GL_FUNCDECL_RPL (popen, FILE *, (const char *cmd, const char *mode)
_GL_ARG_NONNULL ((1, 2)));
_GL_CXXALIAS_RPL (popen, FILE *, (const char *cmd, const char *mode));
# else
# if !@HAVE_POPEN@
_GL_FUNCDECL_SYS (popen, FILE *, (const char *cmd, const char *mode)
_GL_ARG_NONNULL ((1, 2)));
# endif
_GL_CXXALIAS_SYS (popen, FILE *, (const char *cmd, const char *mode));
# endif
_GL_CXXALIASWARN (popen);

View file

@ -55,10 +55,17 @@
/* The definition of _GL_WARN_ON_USE is copied here. */
/* Before doing "#define mkdir rpl_mkdir" below, we need to include all
headers that may declare mkdir(). */
headers that may declare mkdir(). Native Windows platforms declare mkdir
in <io.h> and/or <direct.h>, not in <unistd.h>. */
#if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
# include <io.h> /* mingw32, mingw64 */
# include <direct.h> /* mingw64 */
# include <direct.h> /* mingw64, MSVC 9 */
#endif
#ifndef S_IFIFO
# ifdef _S_IFIFO
# define S_IFIFO _S_IFIFO
# endif
#endif
#ifndef S_IFMT
@ -312,16 +319,25 @@ _GL_WARN_ON_USE (fchmodat, "fchmodat is not portable - "
#endif
#if @REPLACE_FSTAT@
# if !(defined __cplusplus && defined GNULIB_NAMESPACE)
# define fstat rpl_fstat
# endif
#if @GNULIB_FSTAT@
# if @REPLACE_FSTAT@
# if !(defined __cplusplus && defined GNULIB_NAMESPACE)
# undef fstat
# define fstat rpl_fstat
# endif
_GL_FUNCDECL_RPL (fstat, int, (int fd, struct stat *buf) _GL_ARG_NONNULL ((2)));
_GL_CXXALIAS_RPL (fstat, int, (int fd, struct stat *buf));
#else
# else
_GL_CXXALIAS_SYS (fstat, int, (int fd, struct stat *buf));
#endif
# endif
_GL_CXXALIASWARN (fstat);
#elif defined GNULIB_POSIXCHECK
# undef fstat
# if HAVE_RAW_DECL_FSTAT
_GL_WARN_ON_USE (fstat, "fstat has portability problems - "
"use gnulib module fstat for portability");
# endif
#endif
#if @GNULIB_FSTATAT@

View file

@ -75,18 +75,21 @@
#endif
/* mingw fails to declare _exit in <unistd.h>. */
/* mingw, BeOS, Haiku declare environ in <stdlib.h>, not in <unistd.h>. */
/* mingw, MSVC, BeOS, Haiku declare environ in <stdlib.h>, not in
<unistd.h>. */
/* Solaris declares getcwd not only in <unistd.h> but also in <stdlib.h>. */
/* But avoid namespace pollution on glibc systems. */
#ifndef __GLIBC__
# include <stdlib.h>
#endif
/* mingw declares getcwd in <io.h>, not in <unistd.h>. */
#if ((@GNULIB_GETCWD@ || defined GNULIB_POSIXCHECK) \
/* Native Windows platforms declare chdir, getcwd, rmdir in
<io.h> and/or <direct.h>, not in <unistd.h>. */
#if ((@GNULIB_CHDIR@ || @GNULIB_GETCWD@ || @GNULIB_RMDIR@ \
|| defined GNULIB_POSIXCHECK) \
&& ((defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__))
# include <io.h> /* mingw32, mingw64 */
# include <direct.h> /* mingw64 */
# include <direct.h> /* mingw64, MSVC 9 */
#endif
/* AIX and OSF/1 5.1 declare getdomainname in <netdb.h>, not in <unistd.h>.
@ -98,6 +101,12 @@
# include <netdb.h>
#endif
/* MSVC defines off_t in <sys/types.h>. */
#if !@HAVE_UNISTD_H@
/* Get off_t. */
# include <sys/types.h>
#endif
#if (@GNULIB_READ@ || @GNULIB_WRITE@ \
|| @GNULIB_READLINK@ || @GNULIB_READLINKAT@ \
|| @GNULIB_PREAD@ || @GNULIB_PWRITE@ || defined GNULIB_POSIXCHECK)
@ -224,12 +233,24 @@ _GL_WARN_ON_USE (access, "the access function is a security risk - "
#endif
#if @GNULIB_CHDIR@
_GL_CXXALIAS_SYS (chdir, int, (const char *file) _GL_ARG_NONNULL ((1)));
_GL_CXXALIASWARN (chdir);
#elif defined GNULIB_POSIXCHECK
# undef chdir
# if HAVE_RAW_DECL_CHDIR
_GL_WARN_ON_USE (chown, "chdir is not always in <unistd.h> - "
"use gnulib module chdir for portability");
# endif
#endif
#if @GNULIB_CHOWN@
/* Change the owner of FILE to UID (if UID is not -1) and the group of FILE
to GID (if GID is not -1). Follow symbolic links.
Return 0 if successful, otherwise -1 and errno set.
See the POSIX:2001 specification
<http://www.opengroup.org/susv3xsh/chown.html>. */
See the POSIX:2008 specification
<http://pubs.opengroup.org/onlinepubs/9699919799/functions/chown.html. */
# if @REPLACE_CHOWN@
# if !(defined __cplusplus && defined GNULIB_NAMESPACE)
# undef chown
@ -280,24 +301,32 @@ _GL_WARN_ON_USE (close, "close does not portably work on sockets - "
#endif
#if @REPLACE_DUP@
# if !(defined __cplusplus && defined GNULIB_NAMESPACE)
# define dup rpl_dup
# endif
#if @GNULIB_DUP@
# if @REPLACE_DUP@
# if !(defined __cplusplus && defined GNULIB_NAMESPACE)
# define dup rpl_dup
# endif
_GL_FUNCDECL_RPL (dup, int, (int oldfd));
_GL_CXXALIAS_RPL (dup, int, (int oldfd));
#else
# else
_GL_CXXALIAS_SYS (dup, int, (int oldfd));
#endif
# endif
_GL_CXXALIASWARN (dup);
#elif defined GNULIB_POSIXCHECK
# undef dup
# if HAVE_RAW_DECL_DUP
_GL_WARN_ON_USE (dup, "dup is unportable - "
"use gnulib module dup for portability");
# endif
#endif
#if @GNULIB_DUP2@
/* Copy the file descriptor OLDFD into file descriptor NEWFD. Do nothing if
NEWFD = OLDFD, otherwise close NEWFD first if it is open.
Return newfd if successful, otherwise -1 and errno set.
See the POSIX:2001 specification
<http://www.opengroup.org/susv3xsh/dup2.html>. */
See the POSIX:2008 specification
<http://pubs.opengroup.org/onlinepubs/9699919799/functions/dup2.html>. */
# if @REPLACE_DUP2@
# if !(defined __cplusplus && defined GNULIB_NAMESPACE)
# define dup2 rpl_dup2
@ -426,8 +455,8 @@ _GL_WARN_ON_USE (faccessat, "faccessat is not portable - "
/* Change the process' current working directory to the directory on which
the given file descriptor is open.
Return 0 if successful, otherwise -1 and errno set.
See the POSIX:2001 specification
<http://www.opengroup.org/susv3xsh/fchdir.html>. */
See the POSIX:2008 specification
<http://pubs.opengroup.org/onlinepubs/9699919799/functions/fchdir.html>. */
# if ! @HAVE_FCHDIR@
_GL_FUNCDECL_SYS (fchdir, int, (int /*fd*/));
@ -484,11 +513,30 @@ _GL_WARN_ON_USE (fchownat, "fchownat is not portable - "
#endif
#if @GNULIB_FSYNC@
#if @GNULIB_FDATASYNC@
/* Synchronize changes to a file.
Return 0 if successful, otherwise -1 and errno set.
See POSIX:2001 specification
<http://www.opengroup.org/susv3xsh/fsync.html>. */
See POSIX:2008 specification
<http://pubs.opengroup.org/onlinepubs/9699919799/functions/fdatasync.html>. */
# if !@HAVE_FDATASYNC@ || !@HAVE_DECL_FDATASYNC@
_GL_FUNCDECL_SYS (fdatasync, int, (int fd));
# endif
_GL_CXXALIAS_SYS (fdatasync, int, (int fd));
_GL_CXXALIASWARN (fdatasync);
#elif defined GNULIB_POSIXCHECK
# undef fdatasync
# if HAVE_RAW_DECL_FDATASYNC
_GL_WARN_ON_USE (fdatasync, "fdatasync is unportable - "
"use gnulib module fdatasync for portability");
# endif
#endif
#if @GNULIB_FSYNC@
/* Synchronize changes, including metadata, to a file.
Return 0 if successful, otherwise -1 and errno set.
See POSIX:2008 specification
<http://pubs.opengroup.org/onlinepubs/9699919799/functions/fsync.html>. */
# if !@HAVE_FSYNC@
_GL_FUNCDECL_SYS (fsync, int, (int fd));
# endif
@ -506,8 +554,8 @@ _GL_WARN_ON_USE (fsync, "fsync is unportable - "
#if @GNULIB_FTRUNCATE@
/* Change the size of the file to which FD is opened to become equal to LENGTH.
Return 0 if successful, otherwise -1 and errno set.
See the POSIX:2001 specification
<http://www.opengroup.org/susv3xsh/ftruncate.html>. */
See the POSIX:2008 specification
<http://pubs.opengroup.org/onlinepubs/9699919799/functions/ftruncate.html>. */
# if !@HAVE_FTRUNCATE@
_GL_FUNCDECL_SYS (ftruncate, int, (int fd, off_t length));
# endif
@ -527,8 +575,8 @@ _GL_WARN_ON_USE (ftruncate, "ftruncate is unportable - "
of BUF.
Return BUF if successful, or NULL if the directory couldn't be determined
or SIZE was too small.
See the POSIX:2001 specification
<http://www.opengroup.org/susv3xsh/getcwd.html>.
See the POSIX:2008 specification
<http://pubs.opengroup.org/onlinepubs/9699919799/functions/getcwd.html>.
Additionally, the gnulib module 'getcwd' guarantees the following GNU
extension: If BUF is NULL, an array is allocated with 'malloc'; the array
is SIZE bytes long, unless SIZE == 0, in which case it is as big as
@ -891,8 +939,8 @@ _GL_WARN_ON_USE (group_member, "group_member is unportable - "
/* Change the owner of FILE to UID (if UID is not -1) and the group of FILE
to GID (if GID is not -1). Do not follow symbolic links.
Return 0 if successful, otherwise -1 and errno set.
See the POSIX:2001 specification
<http://www.opengroup.org/susv3xsh/lchown.html>. */
See the POSIX:2008 specification
<http://pubs.opengroup.org/onlinepubs/9699919799/functions/lchown.html>. */
# if @REPLACE_LCHOWN@
# if !(defined __cplusplus && defined GNULIB_NAMESPACE)
# undef lchown
@ -921,8 +969,8 @@ _GL_WARN_ON_USE (lchown, "lchown is unportable to pre-POSIX.1-2001 systems - "
#if @GNULIB_LINK@
/* Create a new hard link for an existing file.
Return 0 if successful, otherwise -1 and errno set.
See POSIX:2001 specification
<http://www.opengroup.org/susv3xsh/link.html>. */
See POSIX:2008 specification
<http://pubs.opengroup.org/onlinepubs/9699919799/functions/link.html>. */
# if @REPLACE_LINK@
# if !(defined __cplusplus && defined GNULIB_NAMESPACE)
# define link rpl_link
@ -987,8 +1035,8 @@ _GL_WARN_ON_USE (linkat, "linkat is unportable - "
#if @GNULIB_LSEEK@
/* Set the offset of FD relative to SEEK_SET, SEEK_CUR, or SEEK_END.
Return the new offset if successful, otherwise -1 and errno set.
See the POSIX:2001 specification
<http://www.opengroup.org/susv3xsh/lseek.html>. */
See the POSIX:2008 specification
<http://pubs.opengroup.org/onlinepubs/9699919799/functions/lseek.html>. */
# if @REPLACE_LSEEK@
# if !(defined __cplusplus && defined GNULIB_NAMESPACE)
# define lseek rpl_lseek
@ -1058,8 +1106,9 @@ _GL_WARN_ON_USE (pipe2, "pipe2 is unportable - "
#if @GNULIB_PREAD@
/* Read at most BUFSIZE bytes from FD into BUF, starting at OFFSET.
Return the number of bytes placed into BUF if successful, otherwise
set errno and return -1. 0 indicates EOF. See the POSIX:2001
specification <http://www.opengroup.org/susv3xsh/pread.html>. */
set errno and return -1. 0 indicates EOF.
See the POSIX:2008 specification
<http://pubs.opengroup.org/onlinepubs/9699919799/functions/pread.html>. */
# if @REPLACE_PREAD@
# if !(defined __cplusplus && defined GNULIB_NAMESPACE)
# undef pread
@ -1093,8 +1142,8 @@ _GL_WARN_ON_USE (pread, "pread is unportable - "
/* Write at most BUFSIZE bytes from BUF into FD, starting at OFFSET.
Return the number of bytes written if successful, otherwise
set errno and return -1. 0 indicates nothing written. See the
POSIX:2001 specification
<http://www.opengroup.org/susv3xsh/pwrite.html>. */
POSIX:2008 specification
<http://pubs.opengroup.org/onlinepubs/9699919799/functions/pwrite.html>. */
# if @REPLACE_PWRITE@
# if !(defined __cplusplus && defined GNULIB_NAMESPACE)
# undef pwrite
@ -1126,9 +1175,9 @@ _GL_WARN_ON_USE (pwrite, "pwrite is unportable - "
#if @GNULIB_READ@
/* Read up to COUNT bytes from file descriptor FD into the buffer starting
at BUF. See the POSIX:2001 specification
<http://www.opengroup.org/susv3xsh/read.html>. */
# if @REPLACE_READ@ && @GNULIB_UNISTD_H_NONBLOCKING@
at BUF. See the POSIX:2008 specification
<http://pubs.opengroup.org/onlinepubs/9699919799/functions/read.html>. */
# if @REPLACE_READ@
# if !(defined __cplusplus && defined GNULIB_NAMESPACE)
# undef read
# define read rpl_read
@ -1150,8 +1199,8 @@ _GL_CXXALIASWARN (read);
/* Read the contents of the symbolic link FILE and place the first BUFSIZE
bytes of it into BUF. Return the number of bytes placed into BUF if
successful, otherwise -1 and errno set.
See the POSIX:2001 specification
<http://www.opengroup.org/susv3xsh/readlink.html>. */
See the POSIX:2008 specification
<http://pubs.opengroup.org/onlinepubs/9699919799/functions/readlink.html>. */
# if @REPLACE_READLINK@
# if !(defined __cplusplus && defined GNULIB_NAMESPACE)
# define readlink rpl_readlink
@ -1222,8 +1271,8 @@ _GL_WARN_ON_USE (rmdir, "rmdir is unportable - "
#if @GNULIB_SLEEP@
/* Pause the execution of the current thread for N seconds.
Returns the number of seconds left to sleep.
See the POSIX:2001 specification
<http://www.opengroup.org/susv3xsh/sleep.html>. */
See the POSIX:2008 specification
<http://pubs.opengroup.org/onlinepubs/9699919799/functions/sleep.html>. */
# if @REPLACE_SLEEP@
# if !(defined __cplusplus && defined GNULIB_NAMESPACE)
# undef sleep
@ -1372,7 +1421,7 @@ _GL_WARN_ON_USE (unlinkat, "unlinkat is not portable - "
/* Pause the execution of the current thread for N microseconds.
Returns 0 on completion, or -1 on range error.
See the POSIX:2001 specification
<http://www.opengroup.org/susv3xsh/sleep.html>. */
<http://www.opengroup.org/susv3xsh/usleep.html>. */
# if @REPLACE_USLEEP@
# if !(defined __cplusplus && defined GNULIB_NAMESPACE)
# undef usleep
@ -1398,9 +1447,9 @@ _GL_WARN_ON_USE (usleep, "usleep is unportable - "
#if @GNULIB_WRITE@
/* Write up to COUNT bytes starting at BUF to file descriptor FD.
See the POSIX:2001 specification
<http://www.opengroup.org/susv3xsh/write.html>. */
# if @REPLACE_WRITE@ && (@GNULIB_UNISTD_H_NONBLOCKING@ || @GNULIB_UNISTD_H_SIGPIPE@)
See the POSIX:2008 specification
<http://pubs.opengroup.org/onlinepubs/9699919799/functions/write.html>. */
# if @REPLACE_WRITE@
# if !(defined __cplusplus && defined GNULIB_NAMESPACE)
# undef write
# define write rpl_write

View file

@ -1,3 +1,14 @@
2011-09-25 Michael Albinus <michael.albinus@gmx.de>
* net/dbus.el (dbus-unregister-object): Don't release services for
registered signals. (Bug#9581)
2011-09-25 Teodor Zlatanov <tzz@lifelogs.com>
* progmodes/cfengine.el (cfengine-auto-mode): Add convenience
function that picks between cfengine 2 and 3 support
automatically. Update docs accordingly.
2011-09-22 Kenichi Handa <handa@m17n.org>
* language/ind-util.el (indian-tml-base-table): Add TAMIL DIGIT
@ -5,6 +16,179 @@
(indian-itrans-v5-table-for-tamil): New variable.
(indian-tml-itrans-v5-hash): Use the above variable (Bug#9336).
2011-09-22 Ken Manheimer <ken.manheimer@gmail.com>
* allout.el (allout-this-command-hid-stuff): Buffer-local variable
that's true if the current command involved collapsing of text.
It's reset to false at the beginning of the next command.
(allout-post-command-business): Move the cursor to the beginning
of entry if the cursor is hidden and collapsing activity just
happened.
2011-09-24 Chong Yidong <cyd@stupidchicken.com>
* mouse.el (mouse-drag-track): Set scroll-margin to 0 while
tracking (Bug#9541).
2011-09-24 Ulf Jasper <ulf.jasper@web.de>
* net/newst-reader.el (newsticker-html-renderer)
(newsticker-show-news): Automatically
load html rendering package if newsticker-html-renderer is
set. Fixes "Warning: defvar ignored because w3m-fill-column is
let-bound" and the error "Symbol's value as variable is void:
w3m-fill-column".
2011-09-24 Michael Albinus <michael.albinus@gmx.de>
* net/dbus.el (dbus-unregister-object): Remove match rule of signals.
Release services only if they are defined. (Bug#9581)
2011-09-23 Richard Stallman <rms@gnu.org>
* textmodes/paragraphs.el (forward-sentence): For backwards case,
distinguish start of paragraph from start of its text.
* mail/emacsbug.el (report-emacs-bug-query-existing-bugs): Autoload.
* mail/rmail.el (rmail-view-buffer-kill-buffer-hook): New function.
(rmail-generate-viewer-buffer): Put that hook on view buffer.
(rmail-mode-kill-buffer-hook): Override that hook, to kill view buffer.
2011-09-23 Andreas Schwab <schwab@linux-m68k.org>
* international/mule-diag.el (mule-diag): Insert a newline after
each fontset description.
2011-09-23 Stefan Monnier <monnier@iro.umontreal.ca>
* simple.el (delete-trailing-whitespace):
Document last change; simplify.
2011-09-23 Peter J. Weisberg <pj@irregularexpressions.net>
* simple.el (delete-trailing-whitespace): Also delete
extra newlines at the end of the buffer.
* textmodes/picture.el: Make motion commands obey shift-select-mode.
(picture-newline): Use forward-line so as to ignore fields.
2011-09-23 Stefan Monnier <monnier@iro.umontreal.ca>
* subr.el (with-wrapper-hook): Fix edebug spec.
2011-09-23 Lars Magne Ingebrigtsen <larsi@gnus.org>
* simple.el (kill-line): Note effect of `show-trailing-whitespace'
(bug#4538).
2011-09-23 Michael Albinus <michael.albinus@gmx.de>
* net/tramp-sh.el (tramp-sh-handle-file-name-all-completions):
Fix nasty bug using wrong cached values.
2011-09-23 Alan Mackenzie <acm@muc.de>
* progmodes/cc-defs.el (c-version): Increase to 5.31.9.
2011-09-23 Chong Yidong <cyd@stupidchicken.com>
* window.el (pop-to-buffer): Ensure right window is selected if we
chose another frame.
2011-09-22 Eli Zaretskii <eliz@gnu.org>
* simple.el (what-cursor-position): Use get-char-property-change
and next-single-char-property-change, to be able to show display
properties that come from overlays as well as text properties.
2011-09-22 Chong Yidong <cyd@stupidchicken.com>
* window.el (pop-to-buffer-same-window): New (reinstated) fun.
* cmuscheme.el (run-scheme, switch-to-scheme):
* cus-edit.el (customize-group, custom-buffer-create)
(customize-browse):
* info.el (info):
* shell.el (shell):
* mail/sendmail.el (mail):
* progmodes/inf-lisp.el (inferior-lisp): Use it (Bug#9532).
2011-09-22 Richard Stallman <rms@gnu.org>
* textmodes/paragraphs.el (forward-sentence): When setting PAR-BEG,
move back only to line beg, don't move back over blank lines.
2011-09-22 Michael Albinus <michael.albinus@gmx.de>
* files.el (copy-directory): Set directory attributes only in case
they could be retrieved from the source directory. (Bug#9565)
2011-09-22 Dima Kogan <dkogan@secretsauce.net> (tiny change)
* progmodes/hideshow.el (hs-looking-at-block-start-p)
(hs-find-block-beginning, hs-hide-level-recursive):
Ignore strings as well as comments. (Bug#9502)
2011-09-22 Andrew Schein <andrew@andrewschein.com> (tiny change)
* progmodes/sql.el (sql-comint-postgres):
Convert port number to a string. (Bug#9566)
2011-09-22 Martin Rudalics <rudalics@gmx.at>
* window.el (quit-window): Undedicate window when switching to
previous buffer. Reported by Thierry Volpiatto
<thierry.volpiatto@gmail.com>.
(special-display-popup-frame): When popping up a new frame reset
its previous buffers to nil. Simplify code.
2011-09-21 Michael Albinus <michael.albinus@gmx.de>
* net/tramp.el (tramp-handle-shell-command): Set process sentinel
and process filter, as done also in `shell-command'.
2011-09-21 Martin Rudalics <rudalics@gmx.at>
* window.el (set-window-buffer-start-and-point):
Call set-window-start with NOFORCE argument t. Suggested by Thierry
Volpiatto <thierry.volpiatto@gmail.com>.
(quit-window): Reword doc-string. Handle new format of
quit-restore parameter. Don't delete window if it has a
previous buffer we can show instead of the present one.
(display-buffer-record-window): Rewrite using a new format for
the quit-restore window parameter
(special-display-popup-frame, display-buffer-same-window)
(display-buffer-reuse-window, display-buffer-pop-up-frame)
(display-buffer-pop-up-window, display-buffer-use-some-window):
Adapt symbol passed to display-buffer-record-window.
* help.el (help-window-setup): Handle new format of quit-restore
parameter.
2011-09-21 Stefan Monnier <monnier@iro.umontreal.ca>
* faces.el (face-list): Fix docstring (bug#9564).
* window.el (display-buffer--action-function-custom-type):
Don't include internal functions in the Custom interface.
2011-09-20 Juri Linkov <juri@jurta.org>
* info.el (Info-history-skip-intermediate-nodes): New defcustom.
(Info-forward-node, Info-backward-node, Info-next-preorder)
(Info-last-preorder): Use it. (Bug#9528)
2011-09-20 Juri Linkov <juri@jurta.org>
* info.el (Info-last-preorder): Visit last menu item only when
`Info-scroll-prefer-subnodes' is non-nil (third test-case of bug#9528).
2011-09-20 Julien Danjou <julien@danjou.info>
* password-cache.el (password-cache-remove): Remove entries even if the
value is nil, so that password with a nil value (negative caching) is
possible to invalidate.
2011-09-20 Lawrence Mitchell <wence@gmx.li>
* progmodes/f90.el (f90-break-line): If breaking inside comment delete
@ -120,8 +304,8 @@
* net/tramp.el (top): Don't require 'shell.
(tramp-methods): Fix docstring.
(tramp-get-remote-tmpdir): New defun, moved from tramp-sh.el.
Return complete remote file name. Handle "smb" case. Use
`tramp-tmpdir', if defined for the respective method.
Return complete remote file name. Handle "smb" case.
Use `tramp-tmpdir', if defined for the respective method.
(tramp-make-tramp-temp-file): Adapt call of `tramp-get-remote-tmpdir'.
* net/tramp-compat.el (top): Require 'shell.

View file

@ -10619,7 +10619,7 @@
2008-06-14 Martin Rudalics <rudalics@gmx.at>
* window.el (window--even-window-heights): Even window heights
only if the selected window is higher than WINDOW.
only if the selected window is higher than WINDOW. (Bug#410)
Reported by Stephen Berman <Stephen.Berman at gmx.net>.
2008-06-14 Stefan Monnier <monnier@iro.umontreal.ca>

View file

@ -3304,6 +3304,10 @@ are mapped to the command of the corresponding control-key on the
Set by `allout-pre-command-business', to support allout addons in
coordinating with allout activity.")
(make-variable-buffer-local 'allout-command-counter)
;;;_ = allout-this-command-hid-text
(defvar allout-this-command-hid-text nil
"True if the most recent allout-mode command hid any text.")
(make-variable-buffer-local 'allout-this-command-hid-text)
;;;_ > allout-post-command-business ()
(defun allout-post-command-business ()
"Outline `post-command-hook' function.
@ -3311,6 +3315,9 @@ coordinating with allout activity.")
- Implement (and clear) `allout-post-goto-bullet', for hot-spot
outline commands.
- Move the cursor to the beginning of the entry if it is hidden
and collapsing activity just happened.
- If the command we're following was an undo, check for change in
the status of encrypted items and adjust auto-save inhibitions
accordingly.
@ -3343,8 +3350,9 @@ coordinating with allout activity.")
(if (and allout-post-goto-bullet
(allout-current-bullet-pos))
(progn (goto-char (allout-current-bullet-pos))
(setq allout-post-goto-bullet nil)))
))
(setq allout-post-goto-bullet nil))
(when (and (allout-hidden-p) allout-this-command-hid-text)
(allout-beginning-of-current-entry)))))
;;;_ > allout-pre-command-business ()
(defun allout-pre-command-business ()
"Outline `pre-command-hook' function for outline buffers.
@ -3367,8 +3375,8 @@ return to regular interpretation of self-insert characters."
(if (not (allout-mode-p))
nil
;; Increment allout-command-counter
(setq allout-command-counter (1+ allout-command-counter))
(setq allout-this-command-hid-text nil)
;; Do hot-spot navigation.
(if (and (eq this-command 'self-insert-command)
(eq (point)(allout-current-bullet-pos)))
@ -4767,7 +4775,8 @@ arguments as this function, after the exposure changes are made."
(condition-case nil
;; as of 2008-02-27, xemacs lacks modification-hooks
(overlay-put o (pop props) (pop props))
(error nil)))))))
(error nil))))))
(setq allout-this-command-hid-text t))
(run-hook-with-args 'allout-exposure-change-hook from to flag))
;;;_ > allout-flag-current-subtree (flag)
(defun allout-flag-current-subtree (flag)

View file

@ -246,7 +246,7 @@ is run).
(inferior-scheme-mode)))
(setq scheme-program-name cmd)
(setq scheme-buffer "*scheme*")
(switch-to-buffer "*scheme*"))
(pop-to-buffer-same-window "*scheme*"))
(defun scheme-start-file (prog)
"Return the name of the start file corresponding to PROG.
@ -371,7 +371,7 @@ With argument, position cursor at end of buffer."
(interactive "P")
(if (or (and scheme-buffer (get-buffer scheme-buffer))
(scheme-interactively-start-process))
(switch-to-buffer scheme-buffer)
(pop-to-buffer-same-window scheme-buffer)
(error "No current process buffer. See variable `scheme-buffer'"))
(when eob-p
(push-mark)

View file

@ -1111,15 +1111,19 @@ If OTHER-WINDOW is non-nil, display in another window."
(setq group (intern group))))
(let ((name (format "*Customize Group: %s*"
(custom-unlispify-tag-name group))))
(if (get-buffer name)
(switch-to-buffer name other-window)
(cond
((null (get-buffer name))
(funcall (if other-window
'custom-buffer-create-other-window
'custom-buffer-create)
(list (list group 'custom-group))
name
(concat " for group "
(custom-unlispify-tag-name group))))))
(custom-unlispify-tag-name group))))
(other-window
(switch-to-buffer-other-window name))
(t
(pop-to-buffer-same-window name)))))
;;;###autoload
(defun customize-group-other-window (&optional group)
@ -1533,7 +1537,7 @@ Optional NAME is the name of the buffer.
OPTIONS should be an alist of the form ((SYMBOL WIDGET)...), where
SYMBOL is a customization option, and WIDGET is a widget for editing
that option."
(switch-to-buffer (custom-get-fresh-buffer (or name "*Customization*")))
(pop-to-buffer-same-window (custom-get-fresh-buffer (or name "*Customization*")))
(custom-buffer-create-internal options description))
;;;###autoload
@ -1721,7 +1725,7 @@ Otherwise use brackets."
(unless group
(setq group 'emacs))
(let ((name "*Customize Browser*"))
(switch-to-buffer (custom-get-fresh-buffer name)))
(pop-to-buffer-same-window (custom-get-fresh-buffer name)))
(Custom-mode)
(widget-insert (format "\
%s buttons; type RET or click mouse-1

View file

@ -1,3 +1,8 @@
2011-09-23 Antoine Levitt <antoine.levitt@gmail.com>
* erc-button.el (erc-button-next-function): Scoping fix
(Bug#9487).
2011-07-04 Vivek Dasmohapatra <vivek@etla.org>
* erc.el (erc-generate-new-buffer-name): Reuse old buffer names

View file

@ -430,19 +430,19 @@ call it with the value of the `erc-data' text property."
(defun erc-button-next-function ()
"Pseudo completion function that actually jumps to the next button.
For use on `completion-at-point-functions'."
(let ((here (point)))
(when (< here (erc-beg-of-input-line))
(lambda ()
(while (and (get-text-property here 'erc-callback)
(not (= here (point-max))))
(setq here (1+ here)))
(while (and (not (get-text-property here 'erc-callback))
(not (= here (point-max))))
(setq here (1+ here)))
(if (< here (point-max))
(goto-char here)
(error "No next button"))
t))))
(when (< (point) (erc-beg-of-input-line))
`(lambda ()
(let ((here ,(point)))
(while (and (get-text-property here 'erc-callback)
(not (= here (point-max))))
(setq here (1+ here)))
(while (and (not (get-text-property here 'erc-callback))
(not (= here (point-max))))
(setq here (1+ here)))
(if (< here (point-max))
(goto-char here)
(error "No next button"))
t))))
(defun erc-button-next ()
"Go to the next button in this buffer."

View file

@ -119,7 +119,7 @@ REGISTRY, ALTERNATIVE1, ALTERNATIVE2, and etc."
(defun face-list ()
"Return a list of all defined face names."
"Return a list of all defined faces."
(mapcar #'car face-new-frame-defaults))

View file

@ -4941,9 +4941,10 @@ directly into NEWNAME instead."
(copy-file file target t keep-time)))))
;; Set directory attributes.
(set-file-modes newname (file-modes directory))
(if keep-time
(set-file-times newname (nth 5 (file-attributes directory)))))))
(let ((modes (file-modes directory))
(times (and keep-time (nth 5 (file-attributes directory)))))
(if modes (set-file-modes newname modes))
(if times (set-file-times newname times))))))
(put 'revert-buffer-function 'permanent-local t)
(defvar revert-buffer-function nil

View file

@ -1,3 +1,90 @@
2011-09-26 Lars Magne Ingebrigtsen <larsi@gnus.org>
* nnimap.el (nnimap-wait-for-response): Message less (bug#9540).
(nnimap-insert-partial-structure): The charset parameter isn't
case-sensitive.
* nnheader.el (nnheader-message-maybe): New function.
* shr.el (shr-tag-table): Render totally broken tables better.
* mml.el (mml-generate-mime-1): Don't alter the contents if we're
computing the boundary.
2011-09-26 Lars Magne Ingebrigtsen <larsi@gnus.org>
* pop3.el (pop3-number-of-responses): Remove.
(pop3-wait-for-messages): Rewrite to take linear time instead of
exponential time.
2011-09-24 Lars Magne Ingebrigtsen <larsi@gnus.org>
* gnus-sum.el (gnus-summary-show-article): Bind `shr-ignore-cache' to
re-fetch images.
* shr.el (shr-tag-img): Support a new variable `shr-ignore-cache' to
re-fetch images when hitting `g' in Gnus.
2011-09-22 Katsumi Yamaoka <yamaoka@jpl.org>
* mml.el (mml-inhibit-compute-boundary): New internal variable.
(mml-compute-boundary): Don't check collision if it is non-nil.
(mml-compute-boundary-1): Use mml-generate-mime-1 to encode part
before checking collision.
2011-09-21 Lars Magne Ingebrigtsen <larsi@gnus.org>
* message.el (message-indent-citation): Really make sure there's a
newline at the end.
* nnimap.el (nnimap-parse-flags): Make regexp less prone to overflows.
Fix suggested by John Wiegley.
* pop3.el (pop3-open-server): Fix +OK end-of-command regexp.
* gnus-art.el (gnus-treat-hide-citation): Add doc.
* message.el (message-default-send-rename-function): Break out into its
own function.
* ecomplete.el (ecomplete-display-matches): Revert patch since it
doesn't work under XEmacs.
* nnimap.el (nnimap-map-port): New function to connect to 993 instead
of "imaps" to word around Windows problems.
(nnimap-open-connection-1): Use it.
* message.el (message-indent-citation): Revert last change which made
`F' not work.
2011-09-13 Kan-Ru Chen <kanru@kanru.info>
* ecomplete.el (ecomplete-display-matches): Intercept key sequence from
terminal as well.
2011-09-21 Katsumi Yamaoka <yamaoka@jpl.org>
* mm-view.el (mm-display-inline-fontify): Don't run doc-view-mode
because it displays images using overlays that aren't easy to copy to
the article buffer.
2011-09-20 Łukasz Stelmach <lukasz.stelmach@iem.pw.edu.pl> (tiny change)
* message.el (message-indent-citation): Fix empty line removal at the
end of the citation.
2011-09-20 Julien Danjou <julien@danjou.info>
* auth-source.el (auth-source-netrc-create): Use default value for
password if specified. Evaluate default.
(auth-source-plstore-create): Ditto.
(auth-source-plstore-create, auth-source-netrc-create): Fix default
value evaluation.
(auth-source-netrc-create): Typo fix.
(auth-source-plstore-create): Ditto.
* auth-source.el (auth-source-format-cache-entry): New function.
2011-09-20 Katsumi Yamaoka <yamaoka@jpl.org>
* gnus-fun.el (gnus-convert-image-to-x-face-command): Doc fix.

View file

@ -749,28 +749,31 @@ Returns the deleted entries."
do (password-cache-remove (symbol-name sym)))
(setq auth-source-netrc-cache nil))
(defun auth-source-format-cache-entry (spec)
"Format SPEC entry to put it in the password cache."
(concat auth-source-magic (format "%S" spec)))
(defun auth-source-remember (spec found)
"Remember FOUND search results for SPEC."
(let ((password-cache-expiry auth-source-cache-expiry))
(password-cache-add
(concat auth-source-magic (format "%S" spec)) found)))
(auth-source-format-cache-entry spec) found)))
(defun auth-source-recall (spec)
"Recall FOUND search results for SPEC."
(password-read-from-cache
(concat auth-source-magic (format "%S" spec))))
(password-read-from-cache (auth-source-format-cache-entry spec)))
(defun auth-source-remembered-p (spec)
"Check if SPEC is remembered."
(password-in-cache-p
(concat auth-source-magic (format "%S" spec))))
(auth-source-format-cache-entry spec)))
(defun auth-source-forget (spec)
"Forget any cached data matching SPEC exactly.
This is the same SPEC you passed to `auth-source-search'.
Returns t or nil for forgotten or not found."
(password-cache-remove (concat auth-source-magic (format "%S" spec))))
(password-cache-remove (auth-source-format-cache-entry spec)))
;;; (loop for sym being the symbols of password-data when (string-match (concat "^" auth-source-magic) (symbol-name sym)) collect (symbol-name sym))
@ -1222,49 +1225,46 @@ See `auth-source-search' for details on SPEC."
(?p ,(aget printable-defaults 'port))))))
;; Store the data, prompting for the password if needed.
(setq data
(cond
((and (null data) (eq r 'secret))
;; Special case prompt for passwords.
;; TODO: make the default (setq auth-source-netrc-use-gpg-tokens `((,(if (boundp 'epa-file-auto-mode-alist-entry) (car (symbol-value 'epa-file-auto-mode-alist-entry)) "\\.gpg\\'") nil) (t gpg)))
;; TODO: or maybe leave as (setq auth-source-netrc-use-gpg-tokens 'never)
(let* ((ep (format "Use GPG password tokens in %s?" file))
(gpg-encrypt
(cond
((eq auth-source-netrc-use-gpg-tokens 'never)
'never)
((listp auth-source-netrc-use-gpg-tokens)
(let ((check (copy-sequence
auth-source-netrc-use-gpg-tokens))
item ret)
(while check
(setq item (pop check))
(when (or (eq (car item) t)
(string-match (car item) file))
(setq ret (cdr item))
(setq check nil)))))
(t 'never)))
(plain (read-passwd prompt)))
;; ask if we don't know what to do (in which case
;; auth-source-netrc-use-gpg-tokens must be a list)
(unless gpg-encrypt
(setq gpg-encrypt (if (y-or-n-p ep) 'gpg 'never))
;; TODO: save the defcustom now? or ask?
(setq auth-source-netrc-use-gpg-tokens
(cons `(,file ,gpg-encrypt)
auth-source-netrc-use-gpg-tokens)))
(if (eq gpg-encrypt 'gpg)
(auth-source-epa-make-gpg-token plain file)
plain)))
((null data)
(when default
(setq prompt
(if (string-match ": *\\'" prompt)
(concat (substring prompt 0 (match-beginning 0))
" (default " default "): ")
(concat prompt "(default " default ") "))))
(read-string prompt nil nil default))
(t (or data default))))
(setq data (or data
(if (eq r 'secret)
;; Special case prompt for passwords.
;; TODO: make the default (setq auth-source-netrc-use-gpg-tokens `((,(if (boundp 'epa-file-auto-mode-alist-entry) (car (symbol-value 'epa-file-auto-mode-alist-entry)) "\\.gpg\\'") nil) (t gpg)))
;; TODO: or maybe leave as (setq auth-source-netrc-use-gpg-tokens 'never)
(let* ((ep (format "Use GPG password tokens in %s?" file))
(gpg-encrypt
(cond
((eq auth-source-netrc-use-gpg-tokens 'never)
'never)
((listp auth-source-netrc-use-gpg-tokens)
(let ((check (copy-sequence
auth-source-netrc-use-gpg-tokens))
item ret)
(while check
(setq item (pop check))
(when (or (eq (car item) t)
(string-match (car item) file))
(setq ret (cdr item))
(setq check nil)))))
(t 'never)))
(plain (or (eval default) (read-passwd prompt))))
;; ask if we don't know what to do (in which case
;; auth-source-netrc-use-gpg-tokens must be a list)
(unless gpg-encrypt
(setq gpg-encrypt (if (y-or-n-p ep) 'gpg 'never))
;; TODO: save the defcustom now? or ask?
(setq auth-source-netrc-use-gpg-tokens
(cons `(,file ,gpg-encrypt)
auth-source-netrc-use-gpg-tokens)))
(if (eq gpg-encrypt 'gpg)
(auth-source-epa-make-gpg-token plain file)
plain))
(if (stringp default)
(read-string (if (string-match ": *\\'" prompt)
(concat (substring prompt 0 (match-beginning 0))
" (default " default "): ")
(concat prompt "(default " default ") "))
nil nil default)
(eval default)))))
(when data
(setq artificial (plist-put artificial
@ -1668,20 +1668,16 @@ authentication tokens:
(?p ,(aget printable-defaults 'port))))))
;; Store the data, prompting for the password if needed.
(setq data
(cond
((and (null data) (eq r 'secret))
;; Special case prompt for passwords.
(read-passwd prompt))
((null data)
(when default
(setq prompt
(if (string-match ": *\\'" prompt)
(concat (substring prompt 0 (match-beginning 0))
" (default " default "): ")
(concat prompt "(default " default ") "))))
(read-string prompt nil nil default))
(t (or data default))))
(setq data (or data
(if (eq r 'secret)
(or (eval default) (read-passwd prompt))
(if (stringp default)
(read-string (if (string-match ": *\\'" prompt)
(concat (substring prompt 0 (match-beginning 0))
" (default " default "): ")
(concat prompt "(default " default ") "))
nil nil default)
(eval default)))))
(when data
(if (member r base-secret)

View file

@ -1231,7 +1231,10 @@ predicate. See Info node `(gnus)Customizing Articles'."
(defcustom gnus-treat-hide-citation nil
"Hide cited text.
Valid values are nil, t, `head', `first', `last', an integer or a
predicate. See Info node `(gnus)Customizing Articles'."
predicate. See Info node `(gnus)Customizing Articles'.
See `gnus-article-highlight-citation' for variables used to
control what it hides."
:group 'gnus-article-treat
:link '(custom-manual "(gnus)Customizing Articles")
:type gnus-article-treat-custom)

View file

@ -9611,8 +9611,10 @@ C-u g', show the raw article."
(when (gnus-summary-goto-subject (cdr gnus-article-current) nil t)
(gnus-summary-update-secondary-mark (cdr gnus-article-current))))))
((not arg)
;; Select the article the normal way.
(gnus-summary-select-article nil 'force))
(require 'shr)
(let ((shr-ignore-cache t))
;; Select the article the normal way.
(gnus-summary-select-article nil 'force)))
((equal arg '(16))
;; C-u C-u g
(let ((gnus-inhibit-article-treatments t))

View file

@ -3679,7 +3679,7 @@ However, if `message-yank-prefix' is non-nil, insert that prefix on each line."
(message-delete-line))
;; Delete blank lines at the end of the buffer.
(goto-char (point-max))
(unless (eolp)
(unless (eq (preceding-char) ?\n)
(insert "\n"))
(while (and (zerop (forward-line -1))
(looking-at "$"))
@ -6358,35 +6358,38 @@ between beginning of field and beginning of line."
;; Rename the buffer.
(if message-send-rename-function
(funcall message-send-rename-function)
;; Note: mail-abbrevs of XEmacs renames buffer name behind Gnus.
(when (string-match
"\\`\\*\\(sent \\|unsent \\)?\\(.+\\)\\*[^\\*]*\\|\\`mail to "
(buffer-name))
(let ((name (match-string 2 (buffer-name)))
to group)
(if (not (or (null name)
(string-equal name "mail")
(string-equal name "posting")))
(setq name (concat "*sent " name "*"))
(message-narrow-to-headers)
(setq to (message-fetch-field "to"))
(setq group (message-fetch-field "newsgroups"))
(widen)
(setq name
(cond
(to (concat "*sent mail to "
(or (car (mail-extract-address-components to))
to) "*"))
((and group (not (string= group "")))
(concat "*sent posting on " group "*"))
(t "*sent mail*"))))
(unless (string-equal name (buffer-name))
(rename-buffer name t)))))
(message-default-send-rename-function))
;; Push the current buffer onto the list.
(when message-max-buffers
(setq message-buffer-list
(nconc message-buffer-list (list (current-buffer))))))
(defun message-default-send-rename-function ()
;; Note: mail-abbrevs of XEmacs renames buffer name behind Gnus.
(when (string-match
"\\`\\*\\(sent \\|unsent \\)?\\(.+\\)\\*[^\\*]*\\|\\`mail to "
(buffer-name))
(let ((name (match-string 2 (buffer-name)))
to group)
(if (not (or (null name)
(string-equal name "mail")
(string-equal name "posting")))
(setq name (concat "*sent " name "*"))
(message-narrow-to-headers)
(setq to (message-fetch-field "to"))
(setq group (message-fetch-field "newsgroups"))
(widen)
(setq name
(cond
(to (concat "*sent mail to "
(or (car (mail-extract-address-components to))
to) "*"))
((and group (not (string= group "")))
(concat "*sent posting on " group "*"))
(t "*sent mail*"))))
(unless (string-equal name (buffer-name))
(rename-buffer name t)))))
(defun message-mail-user-agent ()
(let ((mua (cond
((not message-mail-user-agent) nil)

View file

@ -607,7 +607,10 @@ If MODE is not set, try to find mode automatically."
(set (make-local-variable 'enable-local-variables) nil)
(if mode
(funcall mode)
(set-auto-mode))
(let ((auto-mode-alist
(delq (rassq 'doc-view-mode-maybe auto-mode-alist)
(copy-sequence auto-mode-alist))))
(set-auto-mode)))
;; The mode function might have already turned on font-lock.
;; Do not fontify if the guess mode is fundamental.
(unless (or (symbol-value 'font-lock-mode)

View file

@ -461,6 +461,7 @@ If MML is non-nil, return the buffer up till the correspondent mml tag."
(defvar mml-boundary nil)
(defvar mml-base-boundary "-=-=")
(defvar mml-multipart-number 0)
(defvar mml-inhibit-compute-boundary nil)
(defun mml-generate-mime ()
"Generate a MIME message based on the current MML document."
@ -539,7 +540,8 @@ If MML is non-nil, return the buffer up till the correspondent mml tag."
(mml-to-mime)
;; Update handle so mml-compute-boundary can
;; detect collisions with the nested parts.
(setcdr (assoc 'contents cont) (buffer-string)))
(unless mml-inhibit-compute-boundary
(setcdr (assoc 'contents cont) (buffer-string))))
(let ((mm-7bit-chars (concat mm-7bit-chars "\x1b")))
;; ignore 0x1b, it is part of iso-2022-jp
(setq encoding (mm-body-7-or-8))))
@ -710,34 +712,30 @@ If MML is non-nil, return the buffer up till the correspondent mml tag."
"Return a unique boundary that does not exist in CONT."
(let ((mml-boundary (funcall mml-boundary-function
(incf mml-multipart-number))))
;; This function tries again and again until it has found
;; a unique boundary.
(while (not (catch 'not-unique
(mml-compute-boundary-1 cont))))
(unless mml-inhibit-compute-boundary
;; This function tries again and again until it has found
;; a unique boundary.
(while (not (catch 'not-unique
(mml-compute-boundary-1 cont)))))
mml-boundary))
(defun mml-compute-boundary-1 (cont)
(let (filename)
(cond
((member (car cont) '(part mml))
(with-temp-buffer
(cond
((cdr (assq 'buffer cont))
(insert-buffer-substring (cdr (assq 'buffer cont))))
((and (setq filename (cdr (assq 'filename cont)))
(not (equal (cdr (assq 'nofile cont)) "yes")))
(mm-insert-file-contents filename nil nil nil nil t))
(t
(insert (cdr (assq 'contents cont)))))
(goto-char (point-min))
(when (re-search-forward (concat "^--" (regexp-quote mml-boundary))
nil t)
(setq mml-boundary (funcall mml-boundary-function
(incf mml-multipart-number)))
(throw 'not-unique nil))))
((eq (car cont) 'multipart)
(mapc 'mml-compute-boundary-1 (cddr cont))))
t))
(cond
((member (car cont) '(part mml))
(mm-with-multibyte-buffer
(let ((mml-inhibit-compute-boundary t)
(mml-multipart-number 0)
mml-sign-alist mml-encrypt-alist)
(mml-generate-mime-1 cont))
(goto-char (point-min))
(when (re-search-forward (concat "^--" (regexp-quote mml-boundary))
nil t)
(setq mml-boundary (funcall mml-boundary-function
(incf mml-multipart-number)))
(throw 'not-unique nil))))
((eq (car cont) 'multipart)
(mapc 'mml-compute-boundary-1 (cddr cont))))
t)
(defun mml-make-boundary (number)
(concat (make-string (% number 60) ?=)

View file

@ -1112,6 +1112,13 @@ See `find-file-noselect' for the arguments."
'(buffer-string)))))
(insert-buffer-substring ,buffer ,start ,end))))
(defvar nnheader-last-message-time '(0 0))
(defun nnheader-message-maybe (&rest args)
(let ((now (current-time)))
(when (> (float-time (time-subtract now nnheader-last-message-time)) 1)
(setq nnheader-last-message-time now)
(apply 'nnheader-message args))))
(when (featurep 'xemacs)
(require 'nnheaderxm))

View file

@ -345,6 +345,11 @@ textual parts.")
nil
stream)))
(defun nnimap-map-port (port)
(if (equal port "imaps")
"993"
port))
(defun nnimap-open-connection-1 (buffer)
(unless nnimap-keepalive-timer
(setq nnimap-keepalive-timer (run-at-time (* 60 15) (* 60 15)
@ -373,7 +378,8 @@ textual parts.")
(push nnimap-server-port ports))
(let* ((stream-list
(open-protocol-stream
"*nnimap*" (current-buffer) nnimap-address (car ports)
"*nnimap*" (current-buffer) nnimap-address
(nnimap-map-port (car ports))
:type nnimap-stream
:return-list t
:shell-command nnimap-shell-program
@ -666,12 +672,13 @@ textual parts.")
(if (consp (caar structure))
(nnimap-insert-partial-structure (pop structure) parts t)
(let ((bit (pop structure)))
(insert (format "Content-type: %s/%s"
(downcase (nth 0 bit))
(downcase (nth 1 bit))))
(if (member "CHARSET" (nth 2 bit))
(insert (format "Content-type: %s/%s"
(downcase (nth 0 bit))
(downcase (nth 1 bit))))
(if (member-ignore-case "CHARSET" (nth 2 bit))
(insert (format
"; charset=%S\n" (cadr (member "CHARSET" (nth 2 bit)))))
"; charset=%S\n"
(cadr (member-ignore-case "CHARSET" (nth 2 bit)))))
(insert "\n"))
(insert (format "Content-transfer-encoding: %s\n"
(nth 5 bit)))
@ -1551,7 +1558,7 @@ textual parts.")
(goto-char start)
(setq vanished
(and (eq flag-sequence 'qresync)
(re-search-forward "^\\* VANISHED .* \\([0-9:,]+\\)"
(re-search-forward "^\\* VANISHED .*? \\([0-9:,]+\\)"
(or end (point-min)) t)
(match-string 1)))
(goto-char start)
@ -1717,7 +1724,8 @@ textual parts.")
(looking-at "\\*"))))
(not (looking-at (format "%d .*\n" sequence)))))
(when messagep
(nnheader-message 7 "nnimap read %dk" (/ (buffer-size) 1000)))
(nnheader-message-maybe
7 "nnimap read %dk" (/ (buffer-size) 1000)))
(nnheader-accept-process-output process)
(goto-char (point-max)))
openp)

View file

@ -167,17 +167,30 @@ Use streaming commands."
(defun pop3-send-streaming-command (process command count total-size)
(erase-buffer)
(let ((i 1))
(let ((i 1)
(start-point (point-min))
(waited-for 0))
(while (>= count i)
(process-send-string process (format "%s %d\r\n" command i))
;; Only do 100 messages at a time to avoid pipe stalls.
(when (zerop (% i pop3-stream-length))
(pop3-wait-for-messages process i total-size))
(incf i)))
(pop3-wait-for-messages process count total-size))
(setq start-point
(pop3-wait-for-messages process pop3-stream-length
total-size start-point))
(incf waited-for pop3-stream-length))
(incf i))
(pop3-wait-for-messages process (- count waited-for)
total-size start-point)))
(defun pop3-wait-for-messages (process count total-size)
(while (< (pop3-number-of-responses total-size) count)
(defun pop3-wait-for-messages (process count total-size start-point)
(while (> count 0)
(goto-char start-point)
(while (or (and (re-search-forward "^\\+OK" nil t)
(or (not total-size)
(re-search-forward "^\\.\r?\n" nil t)))
(re-search-forward "^-ERR " nil t))
(decf count)
(setq start-point (point)))
(unless (memq (process-status process) '(open run))
(error "pop3 process died"))
(when total-size
@ -185,7 +198,8 @@ Use streaming commands."
(truncate (/ (buffer-size) 1000))
(truncate (* (/ (* (buffer-size) 1.0)
total-size) 100))))
(pop3-accept-process-output process)))
(pop3-accept-process-output process))
start-point)
(defun pop3-write-to-file (file)
(let ((pop-buffer (current-buffer))
@ -219,17 +233,6 @@ Use streaming commands."
(delete-char 1))
(write-region (point-min) (point-max) file nil 'nomesg)))))
(defun pop3-number-of-responses (endp)
(let ((responses 0))
(save-excursion
(goto-char (point-min))
(while (or (and (re-search-forward "^\\+OK" nil t)
(or (not endp)
(re-search-forward "^\\.\r?\n" nil t)))
(re-search-forward "^-ERR " nil t))
(incf responses)))
responses))
(defun pop3-logon (process)
(let ((pop3-password pop3-password))
;; for debugging only
@ -308,7 +311,7 @@ Returns the process associated with the connection."
(t
(or pop3-stream-type 'network)))
:capability-command "CAPA\r\n"
:end-of-command "^\\(-ERR\\|+OK \\).*\n"
:end-of-command "^\\(-ERR\\|+OK\\).*\n"
:end-of-capability "^\\.\r?\n\\|^-ERR"
:success "^\\+OK.*\n"
:return-list t

View file

@ -112,6 +112,7 @@ cid: URL as the argument.")
(defvar shr-table-depth 0)
(defvar shr-stylesheet nil)
(defvar shr-base nil)
(defvar shr-ignore-cache nil)
(defvar shr-map
(let ((map (make-sparse-keymap)))
@ -896,10 +897,16 @@ ones, in case fg and bg are nil."
(if (> (string-width alt) 8)
(shr-insert (truncate-string-to-width alt 8))
(shr-insert alt))))
((url-is-cached (shr-encode-url url))
((and (not shr-ignore-cache)
(url-is-cached (shr-encode-url url)))
(funcall shr-put-image-function (shr-get-image-data url) alt))
(t
(insert alt)
(when (and shr-ignore-cache
(url-is-cached (shr-encode-url url)))
(let ((file (url-cache-create-filename (shr-encode-url url))))
(when (file-exists-p file)
(delete-file file))))
(funcall
(if (fboundp 'url-queue-retrieve)
'url-queue-retrieve
@ -1048,44 +1055,53 @@ ones, in case fg and bg are nil."
(nheader (if header (shr-max-columns header)))
(nbody (if body (shr-max-columns body)))
(nfooter (if footer (shr-max-columns footer))))
(shr-tag-table-1
(nconc
(if caption `((tr (td ,@caption))))
(if header
(if footer
;; hader + body + footer
(if (and (not caption)
(not header)
(not (cdr (assq 'tbody cont)))
(not (cdr (assq 'tr cont)))
(not footer))
;; The table is totally invalid and just contains random junk.
;; Try to output it anyway.
(shr-generic cont)
;; It's a real table, so render it.
(shr-tag-table-1
(nconc
(if caption `((tr (td ,@caption))))
(if header
(if footer
;; hader + body + footer
(if (= nheader nbody)
(if (= nbody nfooter)
`((tr (td (table (tbody ,@header ,@body ,@footer)))))
(nconc `((tr (td (table (tbody ,@header ,@body)))))
(if (= nfooter 1)
footer
`((tr (td (table (tbody ,@footer))))))))
(nconc `((tr (td (table (tbody ,@header)))))
(if (= nbody nfooter)
`((tr (td (table (tbody ,@body ,@footer)))))
(nconc `((tr (td (table (tbody ,@body)))))
(if (= nfooter 1)
footer
`((tr (td (table (tbody ,@footer))))))))))
;; header + body
(if (= nheader nbody)
(if (= nbody nfooter)
`((tr (td (table (tbody ,@header ,@body ,@footer)))))
(nconc `((tr (td (table (tbody ,@header ,@body)))))
(if (= nfooter 1)
footer
`((tr (td (table (tbody ,@footer))))))))
(nconc `((tr (td (table (tbody ,@header)))))
(if (= nbody nfooter)
`((tr (td (table (tbody ,@body ,@footer)))))
(nconc `((tr (td (table (tbody ,@body)))))
(if (= nfooter 1)
footer
`((tr (td (table (tbody ,@footer))))))))))
;; header + body
(if (= nheader nbody)
`((tr (td (table (tbody ,@header ,@body)))))
(if (= nheader 1)
`(,@header (tr (td (table (tbody ,@body)))))
`((tr (td (table (tbody ,@header))))
(tr (td (table (tbody ,@body))))))))
(if footer
;; body + footer
(if (= nbody nfooter)
`((tr (td (table (tbody ,@body ,@footer)))))
(nconc `((tr (td (table (tbody ,@body)))))
(if (= nfooter 1)
footer
`((tr (td (table (tbody ,@footer))))))))
(if caption
`((tr (td (table (tbody ,@body)))))
body)))))
`((tr (td (table (tbody ,@header ,@body)))))
(if (= nheader 1)
`(,@header (tr (td (table (tbody ,@body)))))
`((tr (td (table (tbody ,@header))))
(tr (td (table (tbody ,@body))))))))
(if footer
;; body + footer
(if (= nbody nfooter)
`((tr (td (table (tbody ,@body ,@footer)))))
(nconc `((tr (td (table (tbody ,@body)))))
(if (= nfooter 1)
footer
`((tr (td (table (tbody ,@footer))))))))
(if caption
`((tr (td (table (tbody ,@body)))))
body))))))
(when bgcolor
(shr-colorize-region start (point) (cdr (assq 'color shr-stylesheet))
bgcolor))))

View file

@ -1066,7 +1066,7 @@ HELP-WINDOW is the window used for displaying the help buffer."
(let* ((help-buffer (when (window-live-p help-window)
(window-buffer help-window)))
(help-setup (when (window-live-p help-window)
(window-parameter help-window 'help-setup))))
(car (window-parameter help-window 'quit-restore)))))
(when help-buffer
;; Handle `help-window-point-marker'.
(when (eq (marker-buffer help-window-point-marker) help-buffer)
@ -1077,7 +1077,7 @@ HELP-WINDOW is the window used for displaying the help buffer."
(cond
((or (eq help-window (selected-window))
(and (or (eq help-window-select t)
(eq help-setup 'new-frame)
(eq help-setup 'frame)
(and (eq help-window-select 'other)
(eq (window-frame help-window) (selected-frame))
(> (length (window-list nil 'no-mini)) 2)))
@ -1085,12 +1085,12 @@ HELP-WINDOW is the window used for displaying the help buffer."
;; The help window is or gets selected ...
(help-window-display-message
(cond
((eq help-setup 'new-window)
((eq help-setup 'window)
;; ... and is new, ...
"Type \"q\" to delete help window")
((eq help-setup 'new-frame)
((eq help-setup 'frame)
"Type \"q\" to delete help frame")
((eq help-setup 'reuse-other)
((eq help-setup 'other)
;; ... or displayed some other buffer before.
"Type \"q\" to restore previous buffer"))
help-window t))
@ -1100,19 +1100,19 @@ HELP-WINDOW is the window used for displaying the help buffer."
;; other one is the selected one.
(help-window-display-message
(cond
((eq help-setup 'new-window)
((eq help-setup 'window)
"Type \\[delete-other-windows] to delete the help window")
((eq help-setup 'reuse-other)
((eq help-setup 'other)
"Type \"q\" in help window to restore its previous buffer"))
help-window 'other))
(t
;; The help window is not selected ...
(help-window-display-message
(cond
((eq help-setup 'new-window)
((eq help-setup 'window)
;; ... and is new, ...
"Type \"q\" in help window to delete it")
((eq help-setup 'reuse-other)
((eq help-setup 'other)
;; ... or displayed some other buffer before.
"Type \"q\" in help window to restore previous buffer"))
help-window))))))

View file

@ -52,6 +52,15 @@ Each element of the stack is a list (FILENAME NODENAME BUFFERPOS).")
"List of all Info nodes user has visited.
Each element of the list is a list (FILENAME NODENAME).")
(defcustom Info-history-skip-intermediate-nodes t
"Non-nil means don't record intermediate Info nodes to the history.
Intermediate Info nodes are nodes visited by Info internally in the process of
searching the node to display. Intermediate nodes are not presented
to the user."
:type 'boolean
:group 'info
:version "24.1")
(defcustom Info-enable-edit nil
"Non-nil means the \\<Info-mode-map>\\[Info-edit] command in Info can edit the current node.
This is convenient if you want to write Info files by hand.
@ -640,7 +649,8 @@ See a list of available Info commands in `Info-mode'."
(read-file-name "Info file name: " nil nil t))
(if (numberp current-prefix-arg)
(format "*info*<%s>" current-prefix-arg))))
(info-setup file-or-node (switch-to-buffer (or buffer "*info*"))))
(info-setup file-or-node
(pop-to-buffer-same-window (or buffer "*info*"))))
(defun info-setup (file-or-node buffer)
"Display Info node FILE-OR-NODE in BUFFER."
@ -2668,10 +2678,13 @@ N is the digit argument used to invoke this command."
"top")))
(let ((old-node Info-current-node))
(Info-up)
(let (Info-history success)
(let ((old-history Info-history)
success)
(unwind-protect
(setq success (Info-forward-node t nil no-error))
(or success (Info-goto-node old-node))))))
(or success (Info-goto-node old-node)))
(if Info-history-skip-intermediate-nodes
(setq Info-history old-history)))))
(no-error nil)
(t (error "No pointer forward from this node")))))
@ -2693,10 +2706,12 @@ N is the digit argument used to invoke this command."
;; If we move back at the same level,
;; go down to find the last subnode*.
(Info-prev)
(let (Info-history)
(let ((old-history Info-history))
(while (and (not (Info-index-node))
(save-excursion (search-forward "\n* Menu:" nil t)))
(Info-goto-node (Info-extract-menu-counting nil)))))
(Info-goto-node (Info-extract-menu-counting nil)))
(if Info-history-skip-intermediate-nodes
(setq Info-history old-history))))
(t
(error "No pointer backward from this node")))))
@ -2752,38 +2767,45 @@ N is the digit argument used to invoke this command."
;; Since logically we are done with the node with that menu,
;; move on from it. But don't add intermediate nodes
;; to the history on recursive calls.
(let (Info-history)
(Info-next-preorder)))
(let ((old-history Info-history))
(Info-next-preorder)
(if Info-history-skip-intermediate-nodes
(setq Info-history old-history))))
(t
(error "No more nodes"))))
(defun Info-last-preorder ()
"Go to the last node, popping up a level if there is none."
(interactive)
(cond ((Info-no-error
(Info-last-menu-item)
;; If we go down a menu item, go to the end of the node
;; so we can scroll back through it.
(goto-char (point-max)))
(cond ((and Info-scroll-prefer-subnodes
(Info-no-error
(Info-last-menu-item)
;; If we go down a menu item, go to the end of the node
;; so we can scroll back through it.
(goto-char (point-max))))
;; Keep going down, as long as there are nested menu nodes.
(let (Info-history) ; Don't add intermediate nodes to the history.
(let ((old-history Info-history))
(while (Info-no-error
(Info-last-menu-item)
;; If we go down a menu item, go to the end of the node
;; so we can scroll back through it.
(goto-char (point-max)))))
(goto-char (point-max))))
(if Info-history-skip-intermediate-nodes
(setq Info-history old-history)))
(recenter -1))
((and (Info-no-error (Info-extract-pointer "prev"))
(not (equal (Info-extract-pointer "up")
(Info-extract-pointer "prev"))))
(Info-no-error (Info-prev))
(goto-char (point-max))
(let (Info-history) ; Don't add intermediate nodes to the history.
(let ((old-history Info-history))
(while (Info-no-error
(Info-last-menu-item)
;; If we go down a menu item, go to the end of the node
;; so we can scroll back through it.
(goto-char (point-max)))))
(goto-char (point-max))))
(if Info-history-skip-intermediate-nodes
(setq Info-history old-history)))
(recenter -1))
((Info-no-error (Info-up t))
(goto-char (point-min))

View file

@ -1139,7 +1139,8 @@ system which uses fontsets)."
(insert "Fontset-Name\t\t\t\t\t\t WDxHT Style\n")
(insert "------------\t\t\t\t\t\t ----- -----\n")
(dolist (fontset (fontset-list))
(print-fontset fontset t)))
(print-fontset fontset t)
(insert "\n")))
(help-print-return-message))))
;;;###autoload

File diff suppressed because it is too large Load diff

View file

@ -479,6 +479,7 @@ and send the mail again%s."
buglist))))
(report-emacs-bug-create-existing-bugs-buffer (nreverse buglist) keywords)))
;;;###autoload
(defun report-emacs-bug-query-existing-bugs (keywords)
"Query for KEYWORDS at `report-emacs-bug-tracker-url', and return the result.
The result is an alist with items of the form (URL SUBJECT NO)."

View file

@ -1310,9 +1310,14 @@ Create the buffer if necessary."
(if (and (local-variable-p 'rmail-view-buffer)
(buffer-live-p rmail-view-buffer))
rmail-view-buffer
(generate-new-buffer
(format " *message-viewer %s*"
(file-name-nondirectory (or buffer-file-name (buffer-name)))))))
(let ((newbuf
(generate-new-buffer
(format " *message-viewer %s*"
(file-name-nondirectory
(or buffer-file-name (buffer-name)))))))
(with-current-buffer newbuf
(add-hook 'kill-buffer-hook 'rmail-view-buffer-kill-buffer-hook nil t))
newbuf)))
(defun rmail-swap-buffers ()
"Swap text between current buffer and `rmail-view-buffer'.
@ -1372,7 +1377,14 @@ If so restore the actual mbox message collection."
(message "Marking buffer unmodified to avoid rewriting Babyl file as mbox file")))
(defun rmail-mode-kill-buffer-hook ()
(if (buffer-live-p rmail-view-buffer) (kill-buffer rmail-view-buffer)))
;; Turn off the hook on the view buffer, so we can kill it, then kill it.
(if (buffer-live-p rmail-view-buffer)
(with-current-buffer rmail-view-buffer
(setq kill-buffer-hook nil)
(kill-buffer rmail-view-buffer))))
(defun rmail-view-buffer-kill-buffer-hook ()
(error "Can't kill message view buffer by itself"))
;; Set up the permanent locals associated with an Rmail file.
(defun rmail-perm-variables ()

View file

@ -1785,11 +1785,11 @@ The seventh argument ACTIONS is a list of actions to take
This is how Rmail arranges to mark messages `answered'."
(interactive "P")
(if (eq noerase 'new)
(switch-to-buffer (generate-new-buffer "*mail*"))
(pop-to-buffer-same-window (generate-new-buffer "*mail*"))
(and noerase
(not (get-buffer "*mail*"))
(setq noerase nil))
(switch-to-buffer "*mail*"))
(pop-to-buffer-same-window "*mail*"))
;; Avoid danger that the auto-save file can't be written.
(let ((dir (expand-file-name

View file

@ -1,3 +1,14 @@
2011-09-20 Bill Wohler <wohler@newt.com>
Release MH-E version 8.3.
* mh-e.el (Version, mh-version): Update for release 8.3.
2011-07-30 Bill Wohler <wohler@newt.com>
* mh-show.el (mh-unvisit-file): Clarify language in yes-or-no-p
and error messages.
2011-07-17 Bill Wohler <wohler@newt.com>
Release MH-E version 8.2.93.

View file

@ -5,7 +5,7 @@
;; Author: Bill Wohler <wohler@newt.com>
;; Maintainer: Bill Wohler <wohler@newt.com>
;; Version: 8.2.93
;; Version: 8.3
;; Keywords: mail
;; This file is part of GNU Emacs.
@ -127,7 +127,7 @@
;; Try to keep variables local to a single file. Provide accessors if
;; variables are shared. Use this section as a last resort.
(defconst mh-version "8.2.93" "Version number of MH-E.")
(defconst mh-version "8.3" "Version number of MH-E.")
;; Variants

View file

@ -319,9 +319,9 @@ ignored if VISIBLE-HEADERS is non-nil."
"Separate current buffer from the message file it was visiting."
(or (not (buffer-modified-p))
(null buffer-file-name) ;we've been here before
(yes-or-no-p (format "Message %s modified; flush changes? "
(yes-or-no-p (format "Message %s modified; discard changes? "
(file-name-nondirectory buffer-file-name)))
(error "Flushing changes not confirmed"))
(error "Changes preserved"))
(clear-visited-file-modtime)
(unlock-buffer)
(setq buffer-file-name nil))

View file

@ -904,7 +904,8 @@ DO-MOUSE-DRAG-REGION-POST-PROCESS should only be used by
(mouse-minibuffer-check start-event)
(setq mouse-selection-click-count-buffer (current-buffer))
(deactivate-mark)
(let* ((original-window (selected-window))
(let* ((scroll-margin 0) ; Avoid margin scrolling (Bug#9541).
(original-window (selected-window))
;; We've recorded what we needed from the current buffer and
;; window, now let's jump to the place of the event, where things
;; are happening.

View file

@ -140,11 +140,14 @@ association to the service from D-Bus."
;; Find the corresponding entry in the hash table.
(let* ((key (car object))
(value (cdr object))
(value (cadr object))
(bus (car key))
(service (car value))
(entry (gethash key dbus-registered-objects-table))
ret)
;; entry has the structure ((UNAME SERVICE PATH MEMBER) ...).
;; value has the structure ((SERVICE PATH [HANDLER]) ...).
;; key has the structure (BUS INTERRFACE MEMBER).
;; value has the structure (SERVICE PATH [HANDLER]).
;; entry has the structure ((UNAME SERVICE PATH MEMBER [RULE]) ...).
;; MEMBER is either a string (the handler), or a cons cell (a
;; property value). UNAME and property values are not taken into
;; account for comparision.
@ -152,31 +155,37 @@ association to the service from D-Bus."
;; Loop over the registered functions.
(dolist (elt entry)
(when (equal
(car value)
(butlast (cdr elt) (- (length (cdr elt)) (length (car value)))))
value
(butlast (cdr elt) (- (length (cdr elt)) (length value))))
(setq ret t)
;; Compute new hash value. If it is empty, remove it from the
;; hash table.
(unless (puthash key (delete elt entry) dbus-registered-objects-table)
(remhash key dbus-registered-objects-table))
(setq ret t)))
;; Remove match rule of signals.
(let ((rule (nth 4 elt)))
(when (stringp rule)
(setq service nil) ; We do not need to unregister the service.
(dbus-call-method
bus dbus-service-dbus dbus-path-dbus dbus-interface-dbus
"RemoveMatch" rule)))))
;; Check, whether there is still a registered function or property
;; for the given service. If not, unregister the service from the
;; bus.
(dolist (elt entry)
(let ((service (cadr elt))
(bus (car key))
found)
(maphash
(lambda (k v)
(dolist (e v)
(ignore-errors
(when (and (equal bus (car k)) (string-equal service (cadr e)))
(setq found t)))))
dbus-registered-objects-table)
(unless found
(dbus-call-method
bus dbus-service-dbus dbus-path-dbus dbus-interface-dbus
"ReleaseName" service))))
(when service
(dolist (elt entry)
(let (found)
(maphash
(lambda (k v)
(dolist (e v)
(ignore-errors
(when (and (equal bus (car k)) (string-equal service (cadr e)))
(setq found t)))))
dbus-registered-objects-table)
(unless found
(dbus-call-method
bus dbus-service-dbus dbus-path-dbus dbus-interface-dbus
"ReleaseName" service)))))
;; Return.
ret))

View file

@ -5,7 +5,7 @@
;; Author: Ulf Jasper <ulf.jasper@web.de>
;; Filename: newst-reader.el
;; URL: http://www.nongnu.org/newsticker
;; Time-stamp: "13. Mai 2011, 20:55:24 (ulf)"
;; Time-stamp: "24. September 2011, 15:47:49 (ulf)"
;; Package: newsticker
;; ======================================================================
@ -103,28 +103,11 @@ window is used when filling. See also `newsticker-justification'."
(defcustom newsticker-html-renderer
nil
"Function for rendering HTML contents.
If non-nil, newsticker.el will call this function whenever it finds
HTML-like tags in item descriptions. Possible functions are, for
example, `w3m-region', `w3-region', and (if you have htmlr.el installed)
`newsticker-htmlr-render'.
In order to make sure that the HTML renderer is loaded when you
run newsticker, you should add one of the following statements to
your .emacs. If you use w3m,
(autoload 'w3m-region \"w3m\"
\"Render region in current buffer and replace with result.\" t)
(autoload 'w3m-toggle-inline-image \"w3m\"
\"Toggle the visibility of an image under point.\" t)
or, if you use w3,
(require 'w3-auto)
or, if you use htmlr
(require 'htmlr)"
If non-nil, newsticker.el will call this function whenever it
finds HTML-like tags in item descriptions. Possible functions
are `w3m-region', `w3-region', and `newsticker-htmlr-render'.
Newsticker automatically loads the respective package w3m, w3, or
htmlr if this option is set."
:type '(choice :tag "Function"
(const :tag "None" nil)
(const :tag "w3" w3-region)
@ -286,6 +269,14 @@ Return the image."
"Start reading news. You may want to bind this to a key."
(interactive)
(newsticker-start t) ;; will start only if not running
;; Load the html rendering packages
(if newsticker-html-renderer
(cond ((eq newsticker-html-renderer 'w3m-region)
(require 'w3m))
((eq newsticker-html-renderer 'w3-region)
(require 'w3-auto))
((eq newsticker-html-renderer 'newsticker-htmlr-render)
(require 'htmlr))))
(funcall newsticker-frontend))
;; ======================================================================

View file

@ -1738,7 +1738,9 @@ and gid of the corresponding user is taken. Both parameters must be integers."
"file-name-all-completions"
nil)))
(when cache-hit (list cache-hit))))
(tramp-compat-number-sequence (length filename) 0 -1)))))
;; We cannot use a length of 0, because file properties
;; for "foo" and "foo/" are identical.
(tramp-compat-number-sequence (length filename) 1 -1)))))
;; Cache expired or no matching cache entry found so we need
;; to perform a remote operation.
@ -1803,12 +1805,12 @@ and gid of the corresponding user is taken. Both parameters must be integers."
(with-current-buffer (tramp-get-buffer v)
(goto-char (point-max))
;; Check result code, found in last line of output
;; Check result code, found in last line of output.
(forward-line -1)
(if (looking-at "^fail$")
(progn
;; Grab error message from line before last line
;; (it was put there by `cd 2>&1')
;; (it was put there by `cd 2>&1').
(forward-line -1)
(tramp-error
v 'file-error
@ -1829,9 +1831,8 @@ tramp-sh-handle-file-name-all-completions: internal error accessing `%s': `%s'"
(push (buffer-substring (point) (point-at-eol)) result)))
;; Because the remote op went through OK we know the
;; directory we `cd'-ed to exists
(tramp-set-file-property
v localname "file-exists-p" t)
;; directory we `cd'-ed to exists.
(tramp-set-file-property v localname "file-exists-p" t)
;; Because the remote op went through OK we know every
;; file listed by `ls' exists.
@ -1840,11 +1841,10 @@ tramp-sh-handle-file-name-all-completions: internal error accessing `%s': `%s'"
v (concat localname entry) "file-exists-p" t))
result)
;; Store result in the cache
;; Store result in the cache.
(tramp-set-file-property
v (concat localname filename)
"file-name-all-completions"
result))))))))
"file-name-all-completions" result))))))))
;; cp, mv and ln

View file

@ -3024,11 +3024,13 @@ User is always nil."
(if (and (not current-buffer-p) (integerp asynchronous))
(prog1
;; Run the process.
(apply 'start-file-process "*Async Shell*" buffer args)
(setq p (apply 'start-file-process "*Async Shell*" buffer args))
;; Display output.
(pop-to-buffer output-buffer)
(setq mode-line-process '(":%s"))
(shell-mode))
(shell-mode)
(set-process-sentinel p 'shell-command-sentinel)
(set-process-filter p 'comint-output-filter))
(prog1
;; Run the process.

View file

@ -116,13 +116,14 @@ but can be invoked at any time to forcefully remove passwords
from the cache. This may be useful when it has been detected
that a password is invalid, so that `password-read' query the
user again."
(let ((password (symbol-value (intern-soft key password-data))))
(when password
(when (stringp password)
(if (fboundp 'clear-string)
(clear-string password)
(fillarray password ?_)))
(unintern key password-data))))
(let ((sym (intern-soft key password-data)))
(when sym
(let ((password (symbol-value sym)))
(when (stringp password)
(if (fboundp 'clear-string)
(clear-string password)
(fillarray password ?_)))
(unintern key password-data)))))
(defun password-cache-add (key password)
"Add password to cache.

View file

@ -93,7 +93,7 @@
;;; Variables also used at compile time.
(defconst c-version "5.31.8"
(defconst c-version "5.31.9"
"CC Mode version number.")
(defconst c-version-sym (intern c-version))

View file

@ -26,16 +26,21 @@
;; Provides support for editing GNU Cfengine files, including
;; font-locking, Imenu and indention, but with no special keybindings.
;; Possible customization for auto-mode selection:
;; (push '(("^cfagent.conf\\'" . cfengine-mode)) auto-mode-alist)
;; (push '(("^cf\\." . cfengine-mode)) auto-mode-alist)
;; (push '(("\\.cf\\'" . cfengine-mode)) auto-mode-alist)
;; The CFEngine 3.x support doesn't have Imenu support but patches are
;; welcome.
;; Or, if you want to use the CFEngine 3.x support:
;; You can set it up so either cfengine-mode (2.x and earlier) or
;; cfengine3-mode (3.x) will be picked, depending on the buffer
;; contents:
;; (push '(("^cfagent.conf\\'" . cfengine3-mode)) auto-mode-alist)
;; (push '(("^cf\\." . cfengine3-mode)) auto-mode-alist)
;; (push '(("\\.cf\\'" . cfengine3-mode)) auto-mode-alist)
;; (add-to-list 'auto-mode-alist '("\\.cf\\'" . cfengine-auto-mode))
;; OR you can choose to always use a specific version, if you prefer
;; it
;; (add-to-list 'auto-mode-alist '("\\.cf\\'" . cfengine3-mode))
;; (add-to-list 'auto-mode-alist '("^cf\\." . cfengine-mode))
;; (add-to-list 'auto-mode-alist '("^cfagent.conf\\'" . cfengine-mode))
;; This is not the same as the mode written by Rolf Ebert
;; <ebert@waporo.muc.de>, distributed with cfengine-2.0.5. It does
@ -466,6 +471,18 @@ to the action header."
#'cfengine-beginning-of-defun)
(set (make-local-variable 'end-of-defun-function) #'cfengine-end-of-defun))
;;;###autoload
(defun cfengine-auto-mode ()
"Choose between `cfengine-mode' and `cfengine3-mode' depending
on the buffer contents"
(let ((v3 nil))
(save-restriction
(goto-char (point-min))
(while (not (or (eobp) v3))
(setq v3 (looking-at (concat cfengine3-defuns-regex "\\>")))
(forward-line)))
(if v3 (cfengine3-mode) (cfengine-mode))))
(provide 'cfengine3)
(provide 'cfengine)

View file

@ -2012,14 +2012,15 @@ is non-nil, call `f90-update-line' after inserting the continuation marker."
(defun f90-find-breakpoint ()
"From `fill-column', search backward for break-delimiter."
;; Commented text more likely than commented code.
(if (f90-in-comment)
(re-search-backward "\\s-" (line-beginning-position))
(re-search-backward f90-break-delimiters (line-beginning-position)))
(if (not f90-break-before-delimiters)
(forward-char (if (looking-at f90-no-break-re) 2 1))
(backward-char)
(or (looking-at f90-no-break-re)
(forward-char))))
(re-search-backward f90-break-delimiters (line-beginning-position))
(if (not f90-break-before-delimiters)
(forward-char (if (looking-at f90-no-break-re) 2 1))
(backward-char)
(or (looking-at f90-no-break-re)
(forward-char)))))
(defun f90-do-auto-fill ()
"Break line if non-white characters beyond `fill-column'.

View file

@ -539,7 +539,7 @@ property of an overlay."
(defun hs-looking-at-block-start-p ()
"Return non-nil if the point is at the block start."
(and (looking-at hs-block-start-regexp)
(save-match-data (not (nth 4 (syntax-ppss))))))
(save-match-data (not (nth 8 (syntax-ppss))))))
(defun hs-forward-sexp (match-data arg)
"Adjust point based on MATCH-DATA and call `hs-forward-sexp-func' w/ ARG.
@ -693,8 +693,8 @@ Return point, or nil if original point was not in a block."
(point)
;; look backward for the start of a block that contains the cursor
(while (and (re-search-backward hs-block-start-regexp nil t)
;; go again if in a comment
(or (save-match-data (nth 4 (syntax-ppss)))
;; go again if in a comment or a string
(or (save-match-data (nth 8 (syntax-ppss)))
(not (setq done
(< here (save-excursion
(hs-forward-sexp (match-data t) 1)
@ -718,7 +718,7 @@ Return point, or nil if original point was not in a block."
(and (< (point) maxp)
(re-search-forward hs-block-start-regexp maxp t)))
(when (save-match-data
(not (nth 4 (syntax-ppss)))) ; not inside comments
(not (nth 8 (syntax-ppss)))) ; not inside comments or strings
(if (> arg 1)
(hs-hide-level-recursive (1- arg) minp maxp)
(goto-char (match-beginning hs-block-start-mdata-select))

View file

@ -297,7 +297,7 @@ of `inferior-lisp-program'). Runs the hooks from
"inferior-lisp" (car cmdlist) nil (cdr cmdlist)))
(inferior-lisp-mode)))
(setq inferior-lisp-buffer "*inferior-lisp*")
(switch-to-buffer "*inferior-lisp*"))
(pop-to-buffer-same-window "*inferior-lisp*"))
;;;###autoload
(defalias 'run-lisp 'inferior-lisp)

View file

@ -4725,7 +4725,7 @@ Try to set `comint-output-filter-functions' like this:
(if (not (string= "" sql-user))
(setq params (append (list "-U" sql-user) params)))
(if (not (= 0 sql-port))
(setq params (append (list "-p" sql-port) params)))
(setq params (append (list "-p" (number-to-string sql-port)) params)))
(sql-comint product params)))
(defun sql-postgres-completion-object (sqlbuf schema)

View file

@ -6658,7 +6658,7 @@ If FACE is not a valid face name, use default face."
;; But autoload them here to make the separation invisible.
;;;### (autoloads (ps-mule-end-job ps-mule-begin-job ps-mule-initialize
;;;;;; ps-multibyte-buffer) "ps-mule" "ps-mule.el" "179b43ee432338186dde9e8c4fe761af")
;;;;;; ps-multibyte-buffer) "ps-mule" "ps-mule.el" "cf055ee6ba398da614a675dc25bdb123")
;;; Generated autoloads from ps-mule.el
(defvar ps-multibyte-buffer nil "\

View file

@ -652,7 +652,7 @@ Otherwise, one argument `-i' is passed to the shell.
;; The buffer's window must be correctly set when we call comint (so
;; that comint sets the COLUMNS env var properly).
(switch-to-buffer buffer)
(pop-to-buffer-same-window buffer)
(unless (comint-check-proc buffer)
(let* ((prog (or explicit-shell-file-name
(getenv "ESHELL") shell-file-name))

View file

@ -568,6 +568,7 @@ On nonblank line, delete any immediately following blank lines."
All whitespace after the last non-whitespace character in a line is deleted.
This respects narrowing, created by \\[narrow-to-region] and friends.
A formfeed is not considered whitespace by this function.
If END is nil, also delete all trailing lines at the end of the buffer.
If the region is active, only delete whitespace within the region."
(interactive (progn
(barf-if-buffer-read-only)
@ -580,12 +581,18 @@ If the region is active, only delete whitespace within the region."
(start (or start (point-min))))
(goto-char start)
(while (re-search-forward "\\s-$" end-marker t)
(skip-syntax-backward "-" (save-excursion (forward-line 0) (point)))
(skip-syntax-backward "-" (line-beginning-position))
;; Don't delete formfeeds, even if they are considered whitespace.
(save-match-data
(if (looking-at ".*\f")
(goto-char (match-end 0))))
(if (looking-at-p ".*\f")
(goto-char (match-end 0)))
(delete-region (point) (match-end 0)))
;; Delete trailing empty lines.
(goto-char end-marker)
(when (and (not end)
(<= (skip-chars-backward "\n") -2)
;; Really the end of buffer.
(save-restriction (widen) (eobp)))
(delete-region (1+ (point)) end-marker))
(set-marker end-marker nil))))
;; Return nil for the benefit of `write-file-functions'.
nil)
@ -1054,9 +1061,9 @@ in *Help* buffer. See also the command `describe-char'."
;; Check if the character is displayed with some `display'
;; text property. In that case, set under-display to the
;; buffer substring covered by that property.
(setq display-prop (get-text-property pos 'display))
(setq display-prop (get-char-property pos 'display))
(if display-prop
(let ((to (or (next-single-property-change pos 'display)
(let ((to (or (next-single-char-property-change pos 'display)
(point-max))))
(if (< to (+ pos 4))
(setq under-display "")
@ -3430,6 +3437,10 @@ a number counts as a prefix arg.
To kill a whole line, when point is not at the beginning, type \
\\[move-beginning-of-line] \\[kill-line] \\[kill-line].
If `show-trailing-whitespace' is non-nil, this command will just
kill the rest of the current line, even if there are only
nonblanks there.
If `kill-whole-line' is non-nil, then this command kills the whole line
including its terminating newline, when used at the beginning of a line
with no argument. As a consequence, you can always kill a whole line

View file

@ -1377,7 +1377,7 @@ arbitrary expression.
ARGS is a list of variables which will be passed as additional arguments
to each function, after the initial argument, and which the first argument
expects to receive when called."
(declare (indent 2) (debug t))
(declare (indent 2) (debug (form sexp body)))
;; We need those two gensyms because CL's lexical scoping is not available
;; for function arguments :-(
(let ((funs (make-symbol "funs"))

View file

@ -456,21 +456,29 @@ sentences. Also, every paragraph boundary terminates sentences as well."
(sentence-end (sentence-end)))
(while (< arg 0)
(let ((pos (point))
;; We used to use (start-of-paragraph-text), but this can
;; prevent sentence-end from matching if it is anchored at
;; BOL and the paragraph starts indented.
(par-beg (save-excursion (backward-paragraph) (point))))
(if (and (re-search-backward sentence-end par-beg t)
(or (< (match-end 0) pos)
(re-search-backward sentence-end par-beg t)))
(goto-char (match-end 0))
(goto-char par-beg)))
par-beg par-text-beg)
(save-excursion
(start-of-paragraph-text)
;; Start of real text in the paragraph.
;; We move back to here if we don't see a sentence-end.
(setq par-text-beg (point))
;; Start of the first line of the paragraph.
;; We use this as the search limit
;; to allow s1entence-end to match if it is anchored at
;; BOL and the paragraph starts indented.
(beginning-of-line)
(setq par-beg (point)))
(if (and (re-search-backward sentence-end par-beg t)
(or (< (match-end 0) pos)
(re-search-backward sentence-end par-beg t)))
(goto-char (match-end 0))
(goto-char par-text-beg)))
(setq arg (1+ arg)))
(while (> arg 0)
(let ((par-end (save-excursion (end-of-paragraph-text) (point))))
(if (re-search-forward sentence-end par-end t)
(skip-chars-backward " \t\n")
(goto-char par-end)))
(if (re-search-forward sentence-end par-end t)
(skip-chars-backward " \t\n")
(goto-char par-end)))
(setq arg (1- arg)))
(constrain-to-field nil opoint t)))

View file

@ -83,7 +83,7 @@
"Position point at the beginning of the line.
With ARG not nil, move forward ARG - 1 lines first.
If scan reaches end of buffer, stop there without error."
(interactive "P")
(interactive "^P")
(if arg (forward-line (1- (prefix-numeric-value arg))))
(beginning-of-line)
(setq picture-desired-column 0))
@ -92,7 +92,7 @@ If scan reaches end of buffer, stop there without error."
"Position point after last non-blank character on current line.
With ARG not nil, move forward ARG - 1 lines first.
If scan reaches end of buffer, stop there without error."
(interactive "P")
(interactive "^P")
(if arg (forward-line (1- (prefix-numeric-value arg))))
(beginning-of-line)
(skip-chars-backward " \t" (prog1 (point) (end-of-line)))
@ -101,7 +101,7 @@ If scan reaches end of buffer, stop there without error."
(defun picture-forward-column (arg &optional interactive)
"Move cursor right, making whitespace if necessary.
With argument, move that many columns."
(interactive "p\nd")
(interactive "^p\nd")
(let (deactivate-mark)
(picture-update-desired-column interactive)
(setq picture-desired-column (max 0 (+ picture-desired-column arg)))
@ -115,14 +115,14 @@ With argument, move that many columns."
(defun picture-backward-column (arg &optional interactive)
"Move cursor left, making whitespace if necessary.
With argument, move that many columns."
(interactive "p\nd")
(interactive "^p\nd")
(picture-update-desired-column interactive)
(picture-forward-column (- arg)))
(defun picture-move-down (arg)
"Move vertically down, making whitespace if necessary.
With argument, move that many lines."
(interactive "p")
(interactive "^p")
(let (deactivate-mark)
(picture-update-desired-column nil)
(picture-newline arg)
@ -139,7 +139,7 @@ With argument, move that many lines."
(defun picture-move-up (arg)
"Move vertically up, making whitespace if necessary.
With argument, move that many lines."
(interactive "p")
(interactive "^p")
(picture-update-desired-column nil)
(picture-move-down (- arg)))
@ -212,7 +212,7 @@ The mode line is updated to reflect the current direction."
With ARG do it that many times. Useful for delineating rectangles in
conjunction with diagonal picture motion.
Do \\[command-apropos] picture-movement to see commands which control motion."
(interactive "p")
(interactive "^p")
(picture-move-down (* arg picture-vertical-step))
(picture-forward-column (* arg picture-horizontal-step)))
@ -221,7 +221,7 @@ Do \\[command-apropos] picture-movement to see commands which control motion."
With ARG do it that many times. Useful for delineating rectangles in
conjunction with diagonal picture motion.
Do \\[command-apropos] picture-movement to see commands which control motion."
(interactive "p")
(interactive "^p")
(picture-motion (- arg)))
(defun picture-mouse-set-point (event)
@ -323,13 +323,14 @@ many lines."
"Move to the beginning of the following line.
With argument, moves that many lines (up, if negative argument);
always moves to the beginning of a line."
(interactive "p")
(if (< arg 0)
(forward-line arg)
(while (> arg 0)
(end-of-line)
(if (eobp) (newline) (forward-char 1))
(setq arg (1- arg)))))
(interactive "^p")
(let ((start (point))
(lines-left (forward-line arg)))
(if (and (eobp)
(> (point) start))
(newline))
(if (> lines-left 0)
(newline lines-left))))
(defun picture-open-line (arg)
"Insert an empty line after the current line.
@ -438,7 +439,7 @@ With ARG move to column occupied by next interesting character in this
line. The character must be preceded by whitespace.
\"interesting characters\" are defined by variable `picture-tab-chars'.
If no such character is found, move to beginning of line."
(interactive "P")
(interactive "^P")
(let ((target (current-column)))
(save-excursion
(if (and (not arg)
@ -464,7 +465,7 @@ If no such character is found, move to beginning of line."
With prefix arg, overwrite the traversed text with spaces. The tab stop
list can be changed by \\[picture-set-tab-stops] and \\[edit-tab-stops].
See also documentation for variable `picture-tab-chars'."
(interactive "P")
(interactive "^P")
(let* ((opoint (point)))
(move-to-tab-stop)
(if arg

View file

@ -1,3 +1,8 @@
2011-09-24 Christopher J. White <chris@grierwhite.com> (tiny change)
* url-http.el (url-http-create-request): Avoid adding extra CRLF
(Bug#8931).
2011-09-13 Lars Magne Ingebrigtsen <larsi@gnus.org>
* url-http.el (url-http-find-free-connection): If there was an

View file

@ -342,7 +342,9 @@ request.")
;; End request
"\r\n"
;; Any data
url-http-data))
url-http-data
;; If `url-http-data' is nil, avoid two CRLFs (Bug#8931).
(if url-http-data "\r\n")))
""))
(url-http-debug "Request is: \n%s" request)
request))

View file

@ -2531,7 +2531,8 @@ before was current this also makes BUFFER the current buffer."
(when (and selected current)
(set-buffer buffer))
(when start
(set-window-start window start))
;; Don't force window-start here (even if POINT is nil).
(set-window-start window start t))
(when point
(if selected
(with-current-buffer buffer
@ -2868,8 +2869,9 @@ all window-local buffer lists."
(defun quit-window (&optional kill window)
"Quit WINDOW and bury its buffer.
WINDOW defaults to the selected window.
With a prefix argument, kill the buffer instead.
WINDOW must be a live window and defaults to the selected one.
With prefix argument KILL non-nil, kill the buffer instead of
burying it.
According to information stored in WINDOW's `quit-restore' window
parameter either \(1) delete WINDOW and its frame, \(2) delete
@ -2878,51 +2880,65 @@ or \(4) make WINDOW display some other buffer than the present
one. If non-nil, reset `quit-restore' parameter to nil."
(interactive "P")
(setq window (window-normalize-live-window window))
(let ((buffer (window-buffer window))
(quit-restore (window-parameter window 'quit-restore))
resize)
(let* ((buffer (window-buffer window))
(quit-restore (window-parameter window 'quit-restore))
(prev-buffer
(let* ((prev-buffers (window-prev-buffers window))
(prev-buffer (caar prev-buffers)))
(and (or (not (eq prev-buffer buffer))
(and (cdr prev-buffers)
(not (eq (setq prev-buffer (cadr prev-buffers))
buffer))))
prev-buffer)))
quad resize)
(cond
((and (eq (car-safe quit-restore) 'new-frame)
(eq (nth 1 quit-restore) (window-buffer window))
(eq (window-deletable-p window) 'frame))
((and (not prev-buffer)
(eq (nth 1 quit-restore) 'frame)
(eq (window-deletable-p window) 'frame)
(eq (nth 3 quit-restore) buffer))
;; WINDOW's frame can be deleted.
(delete-frame (window-frame window))
;; If the previously selected window is still alive, select it.
(when (window-live-p (nth 2 quit-restore))
(select-window (nth 2 quit-restore))))
((and (eq (car-safe quit-restore) 'new-window)
(eq (nth 1 quit-restore) (window-buffer window))
(eq (window-deletable-p window) t))
;; WINDOW's can be deleted.
((and (not prev-buffer)
(eq (nth 1 quit-restore) 'window)
(eq (window-deletable-p window) t)
(eq (nth 3 quit-restore) buffer))
;; WINDOW can be deleted.
(delete-window window)
;; If the previously selected window is still alive, select it.
(when (window-live-p (nth 2 quit-restore))
(select-window (nth 2 quit-restore))))
((and (buffer-live-p (nth 0 quit-restore))
;; The buffer currently shown in WINDOW must still be the
;; buffer shown when its `quit-restore' parameter was created
;; in the first place.
(eq (window-buffer window) (nth 3 quit-restore)))
(setq resize (with-current-buffer buffer temp-buffer-resize-mode))
((and (listp (setq quad (nth 1 quit-restore)))
(buffer-live-p (car quad))
(eq (nth 3 quit-restore) buffer))
;; Show another buffer stored in quit-restore parameter.
(setq resize (with-current-buffer buffer
(and temp-buffer-resize-mode
(/= (nth 3 quad) (window-total-size window)))))
(unrecord-window-buffer window buffer)
;; Display buffer stored in the quit-restore parameter.
(set-window-dedicated-p window nil)
(set-window-buffer window (nth 0 quit-restore))
(set-window-start window (nth 1 quit-restore))
(set-window-point window (nth 2 quit-restore))
(and resize
(/= (nth 4 quit-restore) (window-total-size window))
(window-resize window
(- (nth 4 quit-restore)
(window-total-size window))))
(when resize
;; Try to resize WINDOW to its old height but don't signal an
;; error.
(condition-case nil
(window-resize window (- (nth 3 quad) (window-total-size window)))
(error nil)))
;; Restore WINDOW's previous buffer, window start and point.
(set-window-buffer-start-and-point
window (nth 0 quad) (nth 1 quad) (nth 2 quad))
;; Reset the quit-restore parameter.
(set-window-parameter window 'quit-restore nil)
(when (window-live-p (nth 5 quit-restore))
(select-window (nth 5 quit-restore))))
;; Select old window.
(when (window-live-p (nth 2 quit-restore))
(select-window (nth 2 quit-restore))))
(t
;; Otherwise, show another buffer in WINDOW and reset the
;; quit-restore parameter.
;; Show some other buffer in WINDOW and reset the quit-restore
;; parameter.
(set-window-parameter window 'quit-restore nil)
;; Make sure that WINDOW is no more dedicated.
(set-window-dedicated-p window nil)
(switch-to-prev-buffer window 'bury-or-kill)))
;; Kill WINDOW's old-buffer if requested
@ -3787,39 +3803,48 @@ subwindows can get as small as `window-safe-min-height' and
(defun display-buffer-record-window (type window buffer)
"Record information for window used by `display-buffer'.
TYPE must be one of the symbols reuse-window, pop-up-window, or
pop-up-frame. WINDOW is the window used for or created by the
`display-buffer' routines. BUFFER is the buffer that shall be
displayed."
TYPE specifies the type of the calling operation and must be one
of the symbols 'reuse \(when WINDOW existed already and was
reused for displaying BUFFER), 'window \(when WINDOW was created
on an already existing frame), or 'frame \(when WINDOW was
created on a new frame). WINDOW is the window used for or created
by the `display-buffer' routines. BUFFER is the buffer that
shall be displayed.
This function installs or updates the quit-restore parameter of
WINDOW. The quit-restore parameter is a list of four elements:
The first element is one of the symbols 'window, 'frame, 'same or
'other. The second element is either one of the symbols 'window
or 'frame or a list whose elements are the buffer previously
shown in the window, that buffer's window start and window point,
and the window's height. The third element is the window
selected at the time the parameter was created. The fourth
element is BUFFER."
(cond
((eq type 'reuse-window)
;; In `help-setup' window parameter record whether we used a window
;; on the same buffer or another one.
(set-window-parameter
window 'help-setup
(if (eq (window-buffer window) buffer) 'reuse-same 'reuse-other))
;; In `quit-restore' parameter record information about the old
;; buffer unless such information exists already.
(unless (window-parameter window 'quit-restore)
((eq type 'reuse)
(if (eq (window-buffer window) buffer)
;; WINDOW shows BUFFER already.
(when (consp (window-parameter window 'quit-restore))
;; If WINDOW has a quit-restore parameter, reset its car.
(setcar (window-parameter window 'quit-restore) 'same))
;; WINDOW shows another buffer.
(set-window-parameter
window 'quit-restore
(list (window-buffer window) (window-start window)
(window-point window) buffer
(window-total-size window) (selected-window)))))
((eq type 'pop-up-window)
;; In `help-setup' window parameter record window as new.
(set-window-parameter window 'help-setup 'new-window)
;; In `quit-restore' parameter record that we popped up this window,
;; its buffer, and which window was selected before.
(list 'other
;; A quadruple of WINDOW's buffer, start, point and height.
(list (window-buffer window) (window-start window)
(window-point window) (window-total-size window))
(selected-window) buffer))))
((eq type 'window)
;; WINDOW has been created on an existing frame.
(set-window-parameter
window 'quit-restore (list 'new-window buffer (selected-window))))
((eq type 'pop-up-frame)
;; In `help-setup' window parameter record window as on new frame.
(set-window-parameter window 'help-setup 'new-frame)
;; In `quit-restore' parameter record that we popped up this window
;; on a new frame, the buffer, and which window was selected before.
window 'quit-restore
(list 'window 'window (selected-window) buffer)))
((eq type 'frame)
;; WINDOW has been created on a new frame.
(set-window-parameter
window 'quit-restore (list 'new-frame buffer (selected-window))))))
window 'quit-restore
(list 'frame 'frame (selected-window) buffer)))))
(defcustom display-buffer-function nil
"If non-nil, function to call to handle `display-buffer'.
@ -4065,7 +4090,7 @@ and (cdr ARGS) as second."
(let ((frame (window-frame window)))
(make-frame-visible frame)
(raise-frame frame)
(display-buffer-record-window 'reuse-window window buffer)
(display-buffer-record-window 'reuse window buffer)
window))
;; Reuse the current window if the user requested it.
(when (cdr (assq 'same-window args))
@ -4079,14 +4104,16 @@ and (cdr ARGS) as second."
special-display-buffer-names special-display-regexps)
(display-buffer buffer)))
;; If no window yet, make one in a new frame.
(let ((frame
(with-current-buffer buffer
(make-frame (append args special-display-frame-alist)))))
(display-buffer-record-window
'pop-up-frame (frame-selected-window frame) buffer)
(set-window-buffer (frame-selected-window frame) buffer)
(set-window-dedicated-p (frame-selected-window frame) t)
(frame-selected-window frame))))))
(let* ((frame
(with-current-buffer buffer
(make-frame (append args special-display-frame-alist))))
(window (frame-selected-window frame)))
(display-buffer-record-window 'frame window buffer)
(set-window-buffer window buffer)
;; Reset list of WINDOW's previous buffers to nil.
(set-window-prev-buffers window nil)
(set-window-dedicated-p window t)
window)))))
(defcustom special-display-function 'special-display-popup-frame
"Function to call for displaying special buffers.
@ -4442,10 +4469,7 @@ BUFFER-OR-NAME and return that buffer."
(defconst display-buffer--action-function-custom-type
'(choice :tag "Function"
(const :tag "--" ignore) ; default for insertion
(const display-buffer--maybe-same-window)
(const display-buffer-reuse-window)
(const display-buffer--special)
(const display-buffer--maybe-pop-up-frame-or-window)
(const display-buffer-use-some-window)
(const display-buffer-same-window)
(const display-buffer-pop-up-frame)
@ -4647,7 +4671,7 @@ selected window."
(unless (or (cdr (assq 'inhibit-same-window alist))
(window-minibuffer-p)
(window-dedicated-p))
(display-buffer-record-window 'reuse-window (selected-window) buffer)
(display-buffer-record-window 'reuse (selected-window) buffer)
(window--display-buffer-2 buffer (selected-window))))
(defun display-buffer--maybe-same-window (buffer alist)
@ -4692,7 +4716,7 @@ terminal if either of those variables is non-nil."
(get-buffer-window-list buffer 'nomini
frames))))))
(when window
(display-buffer-record-window 'reuse-window window buffer)
(display-buffer-record-window 'reuse window buffer)
(window--display-buffer-1 window))))
(defun display-buffer--special (buffer alist)
@ -4716,7 +4740,7 @@ return the window used; otherwise return nil."
(when (and fun
(setq frame (funcall fun))
(setq window (frame-selected-window frame)))
(display-buffer-record-window 'pop-up-frame window buffer)
(display-buffer-record-window 'frame window buffer)
(window--display-buffer-2 buffer window)
;; Reset list of WINDOW's previous buffers to nil.
(set-window-prev-buffers window nil)
@ -4742,7 +4766,7 @@ If sucessful, return the new window; otherwise return nil."
(get-largest-window frame t))
(window--try-to-split-window
(get-lru-window frame t)))))
(display-buffer-record-window 'pop-up-window window buffer)
(display-buffer-record-window 'window window buffer)
(window--display-buffer-2 buffer window)
;; Reset list of WINDOW's previous buffers to nil.
(set-window-prev-buffers window nil)
@ -4796,7 +4820,7 @@ return the window. If no suitable window is found, return nil."
;; Restore dedicated status of selected window.
(set-window-dedicated-p window-to-undedicate nil)))
(when window
(display-buffer-record-window 'reuse-window window buffer)
(display-buffer-record-window 'reuse window buffer)
(window--even-window-heights window)
(window--display-buffer-2 buffer window))))
@ -4829,14 +4853,35 @@ at the front of the list of recently selected ones."
(old-frame (selected-frame))
(window (display-buffer buffer action))
(frame (window-frame window)))
(if (eq frame old-frame)
;; Make sure new window is selected (Bug#8615), (Bug#6954).
(select-window window norecord)
;; If `display-buffer' has chosen another frame, make sure it
;; gets input focus.
;; If we chose another frame, make sure it gets input focus.
(unless (eq frame old-frame)
(select-frame-set-input-focus frame norecord))
;; Make sure new window is selected (Bug#8615), (Bug#6954).
(select-window window norecord)
buffer))
(defun pop-to-buffer-same-window (buffer &optional norecord)
"Select buffer BUFFER in some window, preferably the same one.
This function behaves much like `switch-to-buffer', except it
displays with `special-display-function' if BUFFER has a match in
`special-display-buffer-names' or `special-display-regexps'.
Unlike `pop-to-buffer', this function prefers using the selected
window over popping up a new window or frame.
BUFFER may be a buffer, a string (a buffer name), or nil. If it
is a string not naming an existent buffer, create a buffer with
that name. If BUFFER is nil, choose some other buffer. Return
the buffer.
NORECORD, if non-nil means do not put this buffer at the front of
the list of recently selected ones."
(pop-to-buffer buffer
'((display-buffer--special
display-buffer-same-window)
(inhibit-same-window . nil))
norecord))
(defun read-buffer-to-switch (prompt)
"Read the name of a buffer to switch to, prompting with PROMPT.
Return the neame of the buffer as a string.
@ -4892,9 +4937,9 @@ do not make the window displaying it the most recently selected
one.
If FORCE-SAME-WINDOW is non-nil, BUFFER-OR-NAME must be displayed
in the currently selected window; signal an error if that is
impossible (e.g. if the selected window is minibuffer-only).
If non-nil, BUFFER-OR-NAME may be displayed in another window.
in the selected window; signal an error if that is
impossible (e.g. if the selected window is minibuffer-only). If
non-nil, BUFFER-OR-NAME may be displayed in another window.
Return the buffer switched to."
(interactive

View file

@ -1,4 +1,4 @@
#serial 14
#serial 16
dnl Copyright (C) 2002, 2005, 2007, 2009-2011 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@ -71,3 +71,6 @@ AC_DEFUN([gl_FUNC_DUP2],
fi
])
])
# Prerequisites of lib/dup2.c.
AC_DEFUN([gl_PREREQ_DUP2], [])

View file

@ -7,7 +7,7 @@
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
#serial 4
#serial 5
# Autoconf defines AC_FUNC_GETLOADAVG, but that is obsolescent.
# New applications should use gl_GETLOADAVG instead.
@ -91,10 +91,10 @@ else
HAVE_SYS_LOADAVG_H=0
fi
AC_CHECK_DECL([getloadavg], [], [HAVE_DECL_GETLOADAVG=0],
[#if HAVE_SYS_LOADAVG_H
# include <sys/loadavg.h>
#endif
#include <stdlib.h>])
[[#if HAVE_SYS_LOADAVG_H
# include <sys/loadavg.h>
#endif
#include <stdlib.h>]])
])# gl_GETLOADAVG

View file

@ -1,10 +1,22 @@
# DO NOT EDIT! GENERATED AUTOMATICALLY!
# Copyright (C) 2002-2011 Free Software Foundation, Inc.
#
# This file is free software, distributed under the terms of the GNU
# General Public License. As a special exception to the GNU General
# Public License, this file may be distributed as part of a program
# that contains a configuration script generated by Autoconf, under
# This file 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 3 of the License, or
# (at your option) any later version.
#
# This file 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 this file. If not, see <http://www.gnu.org/licenses/>.
#
# As a special exception to the GNU General Public License,
# this file may be distributed as part of a program that
# contains a configuration script generated by Autoconf, under
# the same distribution terms as the rest of that program.
#
# Generated by gnulib-tool.
@ -55,7 +67,7 @@ AC_DEFUN([gl_EARLY],
# Code from module nocrash:
# Code from module pthread_sigmask:
# Code from module readlink:
# Code from module signal:
# Code from module signal-h:
# Code from module sigprocmask:
# Code from module snippet/_Noreturn:
# Code from module snippet/arg-nonnull:
@ -115,6 +127,7 @@ AC_REQUIRE([gl_C99_STRTOLD])
gl_FUNC_DUP2
if test $HAVE_DUP2 = 0 || test $REPLACE_DUP2 = 1; then
AC_LIBOBJ([dup2])
gl_PREREQ_DUP2
fi
gl_UNISTD_MODULE_INDICATOR([dup2])
gl_FILEMODE
@ -233,6 +246,12 @@ if test $HAVE_POSIX_SIGNALBLOCKING = 0; then
fi
gl_SIGNAL_MODULE_INDICATOR([sigprocmask])
gl_gnulib_enabled_sigprocmask=true
if $condition; then
func_gl_gnulib_m4code_raise
fi
if $condition; then
func_gl_gnulib_m4code_f691f076f650964c9f5598c3ee487616
fi
fi
}
func_gl_gnulib_m4code_stat ()
@ -248,6 +267,9 @@ gl_SYS_STAT_MODULE_INDICATOR([stat])
if $condition; then
func_gl_gnulib_m4code_dosname
fi
if $condition; then
func_gl_gnulib_m4code_pathmax
fi
if $condition; then
func_gl_gnulib_m4code_verify
fi
@ -283,6 +305,12 @@ gl_STDLIB_MODULE_INDICATOR([strtoull])
gl_gnulib_enabled_verify=true
fi
}
if test $HAVE_DUP2 = 0 || test $REPLACE_DUP2 = 1; then
func_gl_gnulib_m4code_f691f076f650964c9f5598c3ee487616
fi
if test $HAVE_DUP2 = 0 || test $REPLACE_DUP2 = 1; then
func_gl_gnulib_m4code_676220fa4366efa9bdbfccf11a857c07
fi
if test $REPLACE_GETOPT = 1; then
func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36
fi

View file

@ -1,4 +1,4 @@
# include_next.m4 serial 21
# include_next.m4 serial 22
dnl Copyright (C) 2006-2011 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@ -223,9 +223,11 @@ changequote(,)
;;
esac
changequote([,])
gl_absolute_header_sed='\#'"${gl_dirsep_regex}"']m4_defn([gl_HEADER_NAME])[#{
s#.*"\(.*'"${gl_dirsep_regex}"']m4_defn([gl_HEADER_NAME])[\)".*#\1#
s#^/[^/]#//&#
gl_absolute_header_sed='\|'"${gl_dirsep_regex}"']m4_defn([gl_HEADER_NAME])[|{
s|.*"\(.*'"${gl_dirsep_regex}"']m4_defn([gl_HEADER_NAME])[\)".*|\1|
changequote(,)dnl
s|^/[^/]|//&|
changequote([,])dnl
p
q
}'

View file

@ -1,4 +1,4 @@
# signal_h.m4 serial 17
# signal_h.m4 serial 18
dnl Copyright (C) 2007-2011 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@ -62,12 +62,14 @@ AC_DEFUN([gl_SIGNAL_MODULE_INDICATOR],
AC_DEFUN([gl_SIGNAL_H_DEFAULTS],
[
GNULIB_PTHREAD_SIGMASK=0; AC_SUBST([GNULIB_PTHREAD_SIGMASK])
GNULIB_RAISE=0; AC_SUBST([GNULIB_RAISE])
GNULIB_SIGNAL_H_SIGPIPE=0; AC_SUBST([GNULIB_SIGNAL_H_SIGPIPE])
GNULIB_SIGPROCMASK=0; AC_SUBST([GNULIB_SIGPROCMASK])
GNULIB_SIGACTION=0; AC_SUBST([GNULIB_SIGACTION])
dnl Assume proper GNU behavior unless another module says otherwise.
HAVE_POSIX_SIGNALBLOCKING=1; AC_SUBST([HAVE_POSIX_SIGNALBLOCKING])
HAVE_PTHREAD_SIGMASK=1; AC_SUBST([HAVE_PTHREAD_SIGMASK])
HAVE_RAISE=1; AC_SUBST([HAVE_RAISE])
HAVE_SIGSET_T=1; AC_SUBST([HAVE_SIGSET_T])
HAVE_SIGINFO_T=1; AC_SUBST([HAVE_SIGINFO_T])
HAVE_SIGACTION=1; AC_SUBST([HAVE_SIGACTION])
@ -77,4 +79,5 @@ AC_DEFUN([gl_SIGNAL_H_DEFAULTS],
AC_SUBST([HAVE_TYPE_VOLATILE_SIG_ATOMIC_T])
HAVE_SIGHANDLER_T=1; AC_SUBST([HAVE_SIGHANDLER_T])
REPLACE_PTHREAD_SIGMASK=0; AC_SUBST([REPLACE_PTHREAD_SIGMASK])
REPLACE_RAISE=0; AC_SUBST([REPLACE_RAISE])
])

View file

@ -1,4 +1,4 @@
# signalblocking.m4 serial 12
# signalblocking.m4 serial 13
dnl Copyright (C) 2001-2002, 2006-2011 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@ -22,4 +22,6 @@ AC_DEFUN([gl_SIGNALBLOCKING],
])
# Prerequisites of lib/sigprocmask.c.
AC_DEFUN([gl_PREREQ_SIGPROCMASK], [:])
AC_DEFUN([gl_PREREQ_SIGPROCMASK], [
AC_REQUIRE([AC_C_INLINE])
])

View file

@ -466,6 +466,14 @@ AC_DEFUN([gl_STDINT_TYPE_PROPERTIES],
fi
gl_INTEGER_TYPE_SUFFIX([sig_atomic_t wchar_t wint_t],
[gl_STDINT_INCLUDES])
dnl If wint_t is smaller than 'int', it cannot satisfy the ISO C 99
dnl requirement that wint_t is "unchanged by default argument promotions".
dnl In this case gnulib's <wchar.h> and <wctype.h> override wint_t.
dnl Set the variable BITSIZEOF_WINT_T accordingly.
if test $BITSIZEOF_WINT_T -lt 32; then
BITSIZEOF_WINT_T=32
fi
])
dnl Autoconf >= 2.61 has AC_COMPUTE_INT built-in.

View file

@ -1,4 +1,4 @@
# stdio_h.m4 serial 37
# stdio_h.m4 serial 40
dnl Copyright (C) 2007-2011 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@ -74,7 +74,7 @@ AC_DEFUN([gl_STDIO_H],
dnl corresponding gnulib module is not in use, and which is not
dnl guaranteed by C89.
gl_WARN_ON_USE_PREPARE([[#include <stdio.h>
]], [dprintf fpurge fseeko ftello getdelim getline popen renameat
]], [dprintf fpurge fseeko ftello getdelim getline pclose popen renameat
snprintf tmpfile vdprintf vsnprintf])
])
@ -91,6 +91,7 @@ AC_DEFUN([gl_STDIO_H_DEFAULTS],
[
GNULIB_DPRINTF=0; AC_SUBST([GNULIB_DPRINTF])
GNULIB_FCLOSE=0; AC_SUBST([GNULIB_FCLOSE])
GNULIB_FDOPEN=0; AC_SUBST([GNULIB_FDOPEN])
GNULIB_FFLUSH=0; AC_SUBST([GNULIB_FFLUSH])
GNULIB_FGETC=0; AC_SUBST([GNULIB_FGETC])
GNULIB_FGETS=0; AC_SUBST([GNULIB_FGETS])
@ -115,6 +116,7 @@ AC_DEFUN([gl_STDIO_H_DEFAULTS],
GNULIB_GETS=0; AC_SUBST([GNULIB_GETS])
GNULIB_OBSTACK_PRINTF=0; AC_SUBST([GNULIB_OBSTACK_PRINTF])
GNULIB_OBSTACK_PRINTF_POSIX=0; AC_SUBST([GNULIB_OBSTACK_PRINTF_POSIX])
GNULIB_PCLOSE=0; AC_SUBST([GNULIB_PCLOSE])
GNULIB_PERROR=0; AC_SUBST([GNULIB_PERROR])
GNULIB_POPEN=0; AC_SUBST([GNULIB_POPEN])
GNULIB_PRINTF=0; AC_SUBST([GNULIB_PRINTF])
@ -153,11 +155,14 @@ AC_DEFUN([gl_STDIO_H_DEFAULTS],
HAVE_DPRINTF=1; AC_SUBST([HAVE_DPRINTF])
HAVE_FSEEKO=1; AC_SUBST([HAVE_FSEEKO])
HAVE_FTELLO=1; AC_SUBST([HAVE_FTELLO])
HAVE_PCLOSE=1; AC_SUBST([HAVE_PCLOSE])
HAVE_POPEN=1; AC_SUBST([HAVE_POPEN])
HAVE_RENAMEAT=1; AC_SUBST([HAVE_RENAMEAT])
HAVE_VASPRINTF=1; AC_SUBST([HAVE_VASPRINTF])
HAVE_VDPRINTF=1; AC_SUBST([HAVE_VDPRINTF])
REPLACE_DPRINTF=0; AC_SUBST([REPLACE_DPRINTF])
REPLACE_FCLOSE=0; AC_SUBST([REPLACE_FCLOSE])
REPLACE_FDOPEN=0; AC_SUBST([REPLACE_FDOPEN])
REPLACE_FFLUSH=0; AC_SUBST([REPLACE_FFLUSH])
REPLACE_FOPEN=0; AC_SUBST([REPLACE_FOPEN])
REPLACE_FPRINTF=0; AC_SUBST([REPLACE_FPRINTF])

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