aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJuanma Barranquero2010-09-14 16:41:53 +0200
committerJuanma Barranquero2010-09-14 16:41:53 +0200
commit6664fc59a8f296117ea98b943f062c0cc0e907c1 (patch)
treeb8e0bf218492291433d00a71122bc8cd2c662ea9
parent74769e8b4c73f24e8f3356bd281a56a30000c648 (diff)
parentf3a30a50fab486dcaafb9d897797794fe4c3c4b3 (diff)
downloademacs-6664fc59a8f296117ea98b943f062c0cc0e907c1.tar.gz
emacs-6664fc59a8f296117ea98b943f062c0cc0e907c1.zip
Merge changes from emacs-23 branch.
-rw-r--r--doc/emacs/ChangeLog16
-rw-r--r--doc/emacs/cal-xtra.texi4
-rw-r--r--doc/emacs/calendar.texi9
-rw-r--r--doc/emacs/emacs.texi1
-rw-r--r--doc/emacs/trouble.texi191
-rw-r--r--etc/NEWS.232
-rw-r--r--lisp/ChangeLog71
-rw-r--r--lisp/calendar/appt.el15
-rw-r--r--lisp/calendar/diary-lib.el22
-rw-r--r--lisp/emacs-lisp/byte-run.el13
-rw-r--r--lisp/font-lock.el2
-rw-r--r--lisp/menu-bar.el24
-rw-r--r--lisp/progmodes/antlr-mode.el2
-rw-r--r--lisp/repeat.el7
-rw-r--r--lisp/simple.el2
-rw-r--r--lisp/subr.el13
-rw-r--r--lisp/url/ChangeLog12
-rw-r--r--lisp/url/url-cache.el13
-rw-r--r--lisp/url/url-cookie.el36
-rw-r--r--lisp/vc/vc-hg.el8
-rw-r--r--src/ChangeLog30
-rw-r--r--src/coding.c7
-rw-r--r--src/term.c1
-rw-r--r--src/xterm.c156
24 files changed, 461 insertions, 196 deletions
diff --git a/doc/emacs/ChangeLog b/doc/emacs/ChangeLog
index 225cf9dcd74..80be53432e0 100644
--- a/doc/emacs/ChangeLog
+++ b/doc/emacs/ChangeLog
@@ -1,3 +1,19 @@
12010-09-14 Glenn Morris <rgm@gnu.org>
2
3 * cal-xtra.texi (Fancy Diary Display): Emphasize that sort should be
4 the last hook item.
5
6 * calendar.texi (Appointments): Also updated when a diary include file
7 is saved.
8
92010-09-14 Glenn Morris <rgm@gnu.org>
10
11 * trouble.texi (Bugs): Update the section intro.
12 (Known Problems): New section.
13 (Checklist): Misc updates. Prefer M-x report-emacs-bug.
14 (Sending Patches): Bug fixes are best as responses to existing bugs.
15 * emacs.texi (Known Problems): Add menu entry for new section.
16
12010-09-09 Glenn Morris <rgm@gnu.org> 172010-09-09 Glenn Morris <rgm@gnu.org>
2 18
3 * xresources.texi: Untabify. 19 * xresources.texi: Untabify.
diff --git a/doc/emacs/cal-xtra.texi b/doc/emacs/cal-xtra.texi
index 60588542356..de36ccc4f5f 100644
--- a/doc/emacs/cal-xtra.texi
+++ b/doc/emacs/cal-xtra.texi
@@ -613,7 +613,9 @@ each day's diary entries by their time of day. Here's how:
613@noindent 613@noindent
614For each day, this sorts diary entries that begin with a recognizable 614For each day, this sorts diary entries that begin with a recognizable
615time of day according to their times. Diary entries without times come 615time of day according to their times. Diary entries without times come
616first within each day. 616first within each day. Note how the sort command is placed at the end
617of the hook list, in case earlier members of the list change the order
618of the diary entries, or add items.
617 619
618@vindex diary-include-string 620@vindex diary-include-string
619 Your main diary file can include other files. This permits a group of 621 Your main diary file can include other files. This permits a group of
diff --git a/doc/emacs/calendar.texi b/doc/emacs/calendar.texi
index 5698fd5ff58..89504764d7d 100644
--- a/doc/emacs/calendar.texi
+++ b/doc/emacs/calendar.texi
@@ -1508,7 +1508,14 @@ automatically just after midnight. You can force an update at any
1508time by re-enabling appointment notification. Both these actions also 1508time by re-enabling appointment notification. Both these actions also
1509display the day's diary buffer, unless you set 1509display the day's diary buffer, unless you set
1510@code{appt-display-diary} to @code{nil}. The appointments list is 1510@code{appt-display-diary} to @code{nil}. The appointments list is
1511also updated whenever the diary file is saved. 1511also updated whenever the diary file (or a file it includes; see
1512@iftex
1513@inforef{Fancy Diary Display,, emacs-xtra})
1514@end iftex
1515@ifnottex
1516@ref{Fancy Diary Display})
1517@end ifnottex
1518is saved.
1512 1519
1513@findex appt-add 1520@findex appt-add
1514@findex appt-delete 1521@findex appt-delete
diff --git a/doc/emacs/emacs.texi b/doc/emacs/emacs.texi
index 4de9ee4a57a..17337d2c592 100644
--- a/doc/emacs/emacs.texi
+++ b/doc/emacs/emacs.texi
@@ -1137,6 +1137,7 @@ Dealing with Emacs Trouble
1137 1137
1138Reporting Bugs 1138Reporting Bugs
1139 1139
1140* Known Problems:: How to read about known problems and bugs.
1140* Bug Criteria:: Have you really found a bug? 1141* Bug Criteria:: Have you really found a bug?
1141* Understanding Bug Reporting:: How to report a bug effectively. 1142* Understanding Bug Reporting:: How to report a bug effectively.
1142* Checklist:: Steps to follow for a good bug report. 1143* Checklist:: Steps to follow for a good bug report.
diff --git a/doc/emacs/trouble.texi b/doc/emacs/trouble.texi
index 0390b7da910..2f90b30bf83 100644
--- a/doc/emacs/trouble.texi
+++ b/doc/emacs/trouble.texi
@@ -409,29 +409,76 @@ say something to the psychotherapist, you must end it by typing
409@section Reporting Bugs 409@section Reporting Bugs
410 410
411@cindex bugs 411@cindex bugs
412 Sometimes you will encounter a bug in Emacs. Although we cannot 412 If you think you have found a bug in Emacs, please report it. We
413promise we can or will fix the bug, and we might not even agree that it 413cannot promise to fix it, or always to agree that it is a bug, but we
414is a bug, we want to hear about problems you encounter. Often we agree 414certainly want to hear about it. The same applies for new features
415they are bugs and want to fix them. 415you would like to see added. The following sections will help you to
416 416construct an effective bug report.
417 To make it possible for us to fix a bug, you must report it. In order
418to do so effectively, you must know when and how to do it.
419
420 Before reporting a bug, it is a good idea to see if it is already
421known. You can find the list of known problems in the file
422@file{etc/PROBLEMS} in the Emacs distribution; type @kbd{C-h C-p} to read
423it. Some additional user-level problems can be found in @ref{Bugs and
424problems, , Bugs and problems, efaq, GNU Emacs FAQ}. Looking up your
425problem in these two documents might provide you with a solution or a
426work-around, or give you additional information about related issues.
427 417
428@menu 418@menu
419* Known Problems:: How to read about known problems and bugs.
429* Criteria: Bug Criteria. Have you really found a bug? 420* Criteria: Bug Criteria. Have you really found a bug?
430* Understanding Bug Reporting:: How to report a bug effectively. 421* Understanding Bug Reporting:: How to report a bug effectively.
431* Checklist:: Steps to follow for a good bug report. 422* Checklist:: Steps to follow for a good bug report.
432* Sending Patches:: How to send a patch for GNU Emacs. 423* Sending Patches:: How to send a patch for GNU Emacs.
433@end menu 424@end menu
434 425
426@node Known Problems
427@subsection Reading Existing Bug Reports and Known Problems
428
429 Before reporting a bug, if at all possible please check to see if it
430is already known about. Indeed, it may already have been fixed in a
431later release of Emacs, or in the development version. Here is a list
432of the main places you can read about known issues:
433
434@itemize
435@item
436The @file{etc/PROBLEMS} file in the Emacs distribution; type @kbd{C-h
437C-p} to read it. This file contains a list of particularly well-known
438issues that have been encountered in compiling, installing and running
439Emacs. Often, there are suggestions for workarounds and solutions.
440
441@item
442Some additional user-level problems can be found in @ref{Bugs and
443problems, , Bugs and problems, efaq, GNU Emacs FAQ}.
444
445@item
446The @samp{bug-gnu-emacs} mailing list (also available as the newsgroup
447@samp{gnu.emacs.bug}). This is where you will find most Emacs bug
448reports. You can read the list archives at
449@url{http://lists.gnu.org/mailman/listinfo/bug-gnu-emacs}. If you
450like, you can also subscribe to the list. Be aware that the sole
451purpose of this list is to provide the Emacs maintainers with
452information about bugs and feature requests. Reports may contain
453fairly large amounts of data; spectators should not complain about
454this.
455
456@item
457The bug tracker at @url{http://debbugs.gnu.org}. From early 2008,
458reports from the @samp{bug-gnu-emacs} list have been sent here. The
459tracker contains the same information as the mailing list, just in a
460different format. You may prefer to browse and read reports using the
461tracker.
462
463@item
464The @samp{emacs-pretest-bug} mailing list. This list is no longer
465used, and is mainly of historical interest. At one time, it was used
466for bug reports in development (i.e., not yet released) versions of
467Emacs. You can read the archives for 2003 to mid 2007 at
468@url{http://lists.gnu.org/archive/html/emacs-pretest-bug/}. From
469late 2007 to mid 2008, the address was an alias for the
470@samp{emacs-devel} mailing list. From mid 2008 onwards, it has been
471an alias for @samp{bug-gnu-emacs}.
472
473@item
474The @samp{emacs-devel} mailing list. Sometimes people report bugs to
475this mailing list. This is not the main purpose of the list, however,
476and it is much better to send bug reports to the bug list. You should
477not feel obliged to read this list before reporting a bug.
478
479@end itemize
480
481
435@node Bug Criteria 482@node Bug Criteria
436@subsection When Is There a Bug 483@subsection When Is There a Bug
437 484
@@ -540,56 +587,81 @@ well.
540@subsection Checklist for Bug Reports 587@subsection Checklist for Bug Reports
541 588
542@cindex reporting bugs 589@cindex reporting bugs
543 The best way to send a bug report is to mail it electronically to the 590
544Emacs maintainers at @email{bug-gnu-emacs@@gnu.org}. (If you want to 591 Before reporting a bug, first try to see if the problem has already
545suggest a change as an improvement, use the same address.) 592been reported (@pxref{Known Problems}).
546 593
547 If you'd like to read the bug reports, you can find them on the 594If you are able to, try the latest release of Emacs to see if the
548newsgroup @samp{gnu.emacs.bug}; keep in mind, however, that as a 595problem has already been fixed. Even better is to try the latest
549spectator you should not criticize anything about what you see there. 596development version. We recognize that this is not easy for some
550The purpose of bug reports is to give information to the Emacs 597people, so do not feel that you absolutely must do this before making
551maintainers. Spectators are welcome only as long as they do not 598a report.
552interfere with this. In particular, some bug reports contain fairly
553large amounts of data; spectators should not complain about this.
554
555 Please do not post bug reports using netnews; mail is more reliable
556than netnews about reporting your correct address, which we may need
557in order to ask you for more information. If your data is more than
558500,000 bytes, please don't include it directly in the bug report;
559instead, offer to send it on request, or make it available by ftp and
560say where.
561 599
562@findex report-emacs-bug 600@findex report-emacs-bug
563 A convenient way to send a bug report for Emacs is to use the command 601 The best way to write a bug report for Emacs is to use the command
564@kbd{M-x report-emacs-bug}. This sets up a mail buffer (@pxref{Sending 602@kbd{M-x report-emacs-bug}. This sets up a mail buffer
565Mail}) and automatically inserts @emph{some} of the essential 603(@pxref{Sending Mail}) and automatically inserts @emph{some} of the
566information. However, it cannot supply all the necessary information; 604essential information. However, it cannot supply all the necessary
567you should still read and follow the guidelines below, so you can enter 605information; you should still read and follow the guidelines below, so
568the other crucial information by hand before you send the message. 606you can enter the other crucial information by hand before you send
607the message. You may feel that some of the information inserted by
608@kbd{M-x report-emacs-bug} is not relevant, but unless you are
609absolutely sure it is best to leave it, so that the developers can
610decide for themselves.
611
612When you have finished writing your report, type @kbd{C-c C-c} and it
613will be sent to the Emacs maintainers at @email{bug-gnu-emacs@@gnu.org}.
614(If you want to suggest an improvement or new feature, use the same
615address.) If you cannot send mail from inside Emacs, you can copy the
616text of your report to your normal mail client and send it to that
617address. Or you can simply send an email to that address describing
618the problem.
619
620Your report will be sent to the @samp{bug-gnu-emacs} mailing list, and
621stored in the tracker at @url{http://debbugs.gnu.org}. Please try to
622include a valid reply email address, in case we need to ask you for
623more information about your report. Submissions are moderated, so
624there may be a delay before your report appears.
625
626You do not need to know how the @url{http://debbugs.gnu.org} bug
627tracker works in order to report a bug, but if you want to, you can
628read the tracker's online documentation to see the various features
629you can use.
630
631All mail sent to the @samp{bug-gnu-emacs} mailing list is also
632gatewayed to the @samp{bug.gnu.emacs} newsgroup. The reverse is also
633true, but we ask you not to post bug reports via the newsgroup. It
634can make it much harder to contact you if we need to ask for more
635information, and it does not integrate well with the bug tracker.
636
637If your data is more than 500,000 bytes, please don't include it
638directly in the bug report; instead, offer to send it on request, or
639make it available by ftp and say where.
569 640
570 To enable maintainers to investigate a bug, your report 641 To enable maintainers to investigate a bug, your report
571should include all these things: 642should include all these things:
572 643
573@itemize @bullet 644@itemize @bullet
574@item 645@item
575The version number of Emacs. Without this, we won't know whether there 646The version number of Emacs. Without this, we won't know whether there is any
576is any point in looking for the bug in the current version of GNU 647point in looking for the bug in the current version of GNU Emacs.
577Emacs.
578 648
579You can get the version number by typing @kbd{M-x emacs-version 649@kbd{M-x report-emacs-bug} includes this information automatically,
580@key{RET}}. If that command does not work, you probably have something 650but if you are not using that command for your report you can get the
581other than GNU Emacs, so you will have to report the bug somewhere 651version number by typing @kbd{M-x emacs-version @key{RET}}. If that
582else. 652command does not work, you probably have something other than GNU
653Emacs, so you will have to report the bug somewhere else.
583 654
584@item 655@item
585The type of machine you are using, and the operating system name and 656The type of machine you are using, and the operating system name and
586version number. @kbd{M-x emacs-version @key{RET}} provides this 657version number (again, automatically included by @kbd{M-x
587information too. Copy its output from the @samp{*Messages*} buffer, so 658report-emacs-bug}). @kbd{M-x emacs-version @key{RET}} provides this
588that you get it all and get it accurately. 659information too. Copy its output from the @samp{*Messages*} buffer,
660so that you get it all and get it accurately.
589 661
590@item 662@item
591The operands given to the @code{configure} command when Emacs was 663The operands given to the @code{configure} command when Emacs was
592installed. 664installed (automatically included by @kbd{M-x report-emacs-bug}).
593 665
594@item 666@item
595A complete list of any modifications you have made to the Emacs source. 667A complete list of any modifications you have made to the Emacs source.
@@ -619,12 +691,15 @@ the last line is terminated, but try telling the bugs that).
619 691
620@item 692@item
621The precise commands we need to type to reproduce the bug. 693The precise commands we need to type to reproduce the bug.
694If at all possible, give a full recipe for an Emacs started with the
695@samp{-Q} option (@pxref{Initial Options}). This bypasses your
696@file{.emacs} customizations.
622 697
623@findex open-dribble-file 698@findex open-dribble-file
624@cindex dribble file 699@cindex dribble file
625@cindex logging keystrokes 700@cindex logging keystrokes
626The easy way to record the input to Emacs precisely is to write a 701One way to record the input to Emacs precisely is to write a dribble
627dribble file. To start the file, execute the Lisp expression 702file. To start the file, execute the Lisp expression
628 703
629@example 704@example
630(open-dribble-file "~/dribble") 705(open-dribble-file "~/dribble")
@@ -735,7 +810,7 @@ Check whether any programs you have loaded into the Lisp world,
735including your @file{.emacs} file, set any variables that may affect the 810including your @file{.emacs} file, set any variables that may affect the
736functioning of Emacs. Also, see whether the problem happens in a 811functioning of Emacs. Also, see whether the problem happens in a
737freshly started Emacs without loading your @file{.emacs} file (start 812freshly started Emacs without loading your @file{.emacs} file (start
738Emacs with the @code{-q} switch to prevent loading the init file). If 813Emacs with the @code{-Q} switch to prevent loading the init files). If
739the problem does @emph{not} occur then, you must report the precise 814the problem does @emph{not} occur then, you must report the precise
740contents of any programs that you must load into the Lisp world in order 815contents of any programs that you must load into the Lisp world in order
741to cause the problem to occur. 816to cause the problem to occur.
@@ -907,12 +982,10 @@ your best to help.
907@itemize @bullet 982@itemize @bullet
908@item 983@item
909Send an explanation with your changes of what problem they fix or what 984Send an explanation with your changes of what problem they fix or what
910improvement they bring about. For a bug fix, just include a copy of the 985improvement they bring about. For a fix for an existing bug, it is
911bug report, and explain why the change fixes the bug. 986best to reply to the relevant discussion on the @samp{bug-gnu-emacs}
912 987list, or item in the @url{http://debbugs.gnu.org} tracker. Explain
913(Referring to a bug report is not as good as including it, because then 988why your change fixes the bug.
914we will have to look it up, and we have probably already deleted it if
915we've already fixed the bug.)
916 989
917@item 990@item
918Always include a proper bug report for the problem you think you have 991Always include a proper bug report for the problem you think you have
diff --git a/etc/NEWS.23 b/etc/NEWS.23
index 74291bab8ab..e63767d891c 100644
--- a/etc/NEWS.23
+++ b/etc/NEWS.23
@@ -40,6 +40,8 @@ This can be used in place of the default appt-message-warning-time.
40 40
41* Lisp changes in Emacs 23.3 41* Lisp changes in Emacs 23.3
42 42
43** The use of unintern without an obarray arg is declared obsolete.
44
43** New function byte-to-string, like char-to-string but for bytes. 45** New function byte-to-string, like char-to-string but for bytes.
44 46
45 47
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 52ba1f89303..6f80ba5cdc5 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,72 @@
12010-09-14 Stefan Monnier <monnier@iro.umontreal.ca>
2
3 * emacs-lisp/byte-run.el (set-advertised-calling-convention):
4 Add `when' argument. Update callers.
5
6 * subr.el (unintern): Declare the obarray arg mandatory.
7
82010-09-14 Glenn Morris <rgm@gnu.org>
9
10 * calendar/diary-lib.el (diary-list-entries-hook, diary-sort-entries):
11 Doc fixes.
12
13 * calendar/diary-lib.el (diary-included-files): New variable.
14 (diary-list-entries): Maybe initialize diary-included-files.
15 (diary-include-other-diary-files): Append to diary-included-files.
16 * calendar/appt.el (appt-update-list): Also check the members of
17 diary-included-files. (Bug#6999)
18 (appt-check): Doc fix.
19
202010-09-14 David Reitter <david.reitter@gmail.com>
21
22 * simple.el (line-move-visual): Do not truncate goal column to
23 integer size. (Bug#7020)
24
252010-09-14 Stefan Monnier <monnier@iro.umontreal.ca>
26
27 * repeat.el (repeat): Allow repeating when the last event is a click.
28 Suggested by Drew Adams (bug#6256).
29
302010-09-14 Sascha Wilde <wilde@sha-bang.de>
31
32 * vc/vc-hg.el (vc-hg-state,vc-hg-working-revision):
33 Replace setting HGRCPATH to "" by some less invasive --config options.
34
352010-09-14 Stefan Monnier <monnier@iro.umontreal.ca>
36
37 * font-lock.el (font-lock-beginning-of-syntax-function):
38 Mark as obsolete.
39
402010-09-14 Glenn Morris <rgm@gnu.org>
41
42 * menu-bar.el (menu-bar-options-save): Fix handling of menu-bar
43 and tool-bar modes. (Bug#6211)
44 (menu-bar-mode): Move setting of standard-value after the
45 minor-mode definition, otherwise it seems to have no effect.
46
472010-09-14 Masatake YAMATO <yamato@redhat.com>
48
49 * progmodes/antlr-mode.el (antlr-font-lock-additional-keywords):
50 Fix typo. (Bug#6976)
51
522010-09-14 Vinicius Jose Latorre <viniciusjl@ig.com.br>
53
54 * whitespace.el: Allow cleaning up blanks without blank
55 visualization (Bug#6651). Adjust help window for
56 whitespace-toggle-options (Bug#6479). Allow to use fill-column
57 instead of whitespace-line-column (from EmacsWiki). New version 13.1.
58 (whitespace-style): Add new value 'face. Adjust docstring.
59 (whitespace-space, whitespace-hspace, whitespace-tab):
60 Adjust foreground property face.
61 (whitespace-line-column): Adjust docstring and type declaration.
62 (whitespace-style-value-list, whitespace-toggle-option-alist)
63 (whitespace-help-text): Adjust const initialization.
64 (whitespace-toggle-options, global-whitespace-toggle-options):
65 Adjust docstring.
66 (whitespace-display-window, whitespace-interactive-char)
67 (whitespace-style-face-p, whitespace-color-on): Adjust code.
68 (whitespace-help-scroll): New fun.
69
12010-09-14 Katsumi Yamaoka <yamaoka@jpl.org> 702010-09-14 Katsumi Yamaoka <yamaoka@jpl.org>
2 71
3 * calendar/time-date.el (format-seconds): Comment fix. 72 * calendar/time-date.el (format-seconds): Comment fix.
@@ -116,7 +185,7 @@
116 (tramp-get-remote-readlink, tramp-get-remote-trash) 185 (tramp-get-remote-readlink, tramp-get-remote-trash)
117 (tramp-get-remote-id, tramp-get-remote-uid, tramp-get-remote-gid) 186 (tramp-get-remote-id, tramp-get-remote-uid, tramp-get-remote-gid)
118 (tramp-get-local-uid, tramp-get-local-gid) 187 (tramp-get-local-uid, tramp-get-local-gid)
119 (tramp-get-inline-compress, tramp-get-inline-coding, ): Move to 188 (tramp-get-inline-compress, tramp-get-inline-coding): Move to
120 tramp-sh.el. 189 tramp-sh.el.
121 (tramp-methods, tramp-default-method-alist) 190 (tramp-methods, tramp-default-method-alist)
122 (tramp-default-user-alist, tramp-foreign-file-name-handler-alist): 191 (tramp-default-user-alist, tramp-foreign-file-name-handler-alist):
diff --git a/lisp/calendar/appt.el b/lisp/calendar/appt.el
index ad36531bb40..ea419aee52d 100644
--- a/lisp/calendar/appt.el
+++ b/lisp/calendar/appt.el
@@ -48,8 +48,9 @@
48;; package is activated. Additionally, the appointments list is 48;; package is activated. Additionally, the appointments list is
49;; recreated automatically at 12:01am for those who do not logout 49;; recreated automatically at 12:01am for those who do not logout
50;; every day or are programming late. It is also updated when the 50;; every day or are programming late. It is also updated when the
51;; `diary-file' is saved. Calling `appt-check' with an argument (or 51;; `diary-file' (or a file it includes) is saved. Calling
52;; re-enabling the package) forces a re-initialization at any time. 52;; `appt-check' with an argument (or re-enabling the package) forces a
53;; re-initialization at any time.
53;; 54;;
54;; In order to add or delete items from today's list, without 55;; In order to add or delete items from today's list, without
55;; changing the diary file, use `appt-add' and `appt-delete'. 56;; changing the diary file, use `appt-add' and `appt-delete'.
@@ -262,7 +263,7 @@ The variable `appt-audible' controls the audible reminder."
262 "Check for an appointment and update any reminder display. 263 "Check for an appointment and update any reminder display.
263If optional argument FORCE is non-nil, reparse the diary file for 264If optional argument FORCE is non-nil, reparse the diary file for
264appointments. Otherwise the diary file is only parsed once per day, 265appointments. Otherwise the diary file is only parsed once per day,
265and when saved. 266or when it (or a file it includes) is saved.
266 267
267Note: the time must be the first thing in the line in the diary 268Note: the time must be the first thing in the line in the diary
268for a warning to be issued. The format of the time can be either 269for a warning to be issued. The format of the time can be either
@@ -346,6 +347,8 @@ displayed in a window:
346 (if d-buff ; diary buffer exists 347 (if d-buff ; diary buffer exists
347 (with-current-buffer d-buff 348 (with-current-buffer d-buff
348 diary-selective-display)))) 349 diary-selective-display))))
350 ;; FIXME why not using diary-list-entries with
351 ;; non-nil LIST-ONLY?
349 (diary) 352 (diary)
350 ;; If the diary buffer existed before this command, 353 ;; If the diary buffer existed before this command,
351 ;; restore its display state. Otherwise, kill it. 354 ;; restore its display state. Otherwise, kill it.
@@ -643,8 +646,10 @@ hour and minute parts."
643 646
644(defun appt-update-list () 647(defun appt-update-list ()
645 "If the current buffer is visiting the diary, update appointments. 648 "If the current buffer is visiting the diary, update appointments.
646This function is intended for use with `write-file-functions'." 649This function also acts on any file listed in `diary-included-files'.
647 (and (string-equal buffer-file-name (expand-file-name diary-file)) 650It is intended for use with `write-file-functions'."
651 (and (member buffer-file-name (append diary-included-files
652 (list (expand-file-name diary-file))))
648 appt-timer 653 appt-timer
649 (let ((appt-display-diary nil)) 654 (let ((appt-display-diary nil))
650 (appt-check t))) 655 (appt-check t)))
diff --git a/lisp/calendar/diary-lib.el b/lisp/calendar/diary-lib.el
index 39354bd31e3..46926050362 100644
--- a/lisp/calendar/diary-lib.el
+++ b/lisp/calendar/diary-lib.el
@@ -187,11 +187,12 @@ you will probably also want to add `diary-mark-included-diary-files' to
187 187
188 (setq diary-display-function 'diary-fancy-display) 188 (setq diary-display-function 'diary-fancy-display)
189 (add-hook 'diary-list-entries-hook 'diary-include-other-diary-files) 189 (add-hook 'diary-list-entries-hook 'diary-include-other-diary-files)
190 (add-hook 'diary-list-entries-hook 'diary-sort-entries) 190 (add-hook 'diary-list-entries-hook 'diary-sort-entries t)
191 191
192in your `.emacs' file to cause the fancy diary buffer to be displayed with 192in your `.emacs' file to cause the fancy diary buffer to be displayed with
193diary entries from various included files, each day's entries sorted into 193diary entries from various included files, each day's entries sorted into
194lexicographic order." 194lexicographic order. Note how the sort function is placed last,
195so that it can sort the entries included from other files."
195 :type 'hook 196 :type 'hook
196 :options '(diary-include-other-diary-files diary-sort-entries) 197 :options '(diary-include-other-diary-files diary-sort-entries)
197 :group 'diary) 198 :group 'diary)
@@ -699,6 +700,10 @@ of the appropriate type."
699 (1+ (calendar-absolute-from-gregorian gdate)))))) 700 (1+ (calendar-absolute-from-gregorian gdate))))))
700 (goto-char (point-min))) 701 (goto-char (point-min)))
701 702
703(defvar diary-including) ; dynamically bound in diary-include-other-diary-files
704(defvar diary-included-files nil
705 "List of any diary files included in the last call to `diary-list-entries'.")
706
702;; FIXME non-greg and list hooks run same number of times? 707;; FIXME non-greg and list hooks run same number of times?
703(defun diary-list-entries (date number &optional list-only) 708(defun diary-list-entries (date number &optional list-only)
704 "Create and display a buffer containing the relevant lines in `diary-file'. 709 "Create and display a buffer containing the relevant lines in `diary-file'.
@@ -743,6 +748,8 @@ LIST-ONLY is non-nil, in which case it just returns the list."
743 (date-string (calendar-date-string date)) 748 (date-string (calendar-date-string date))
744 (diary-buffer (find-buffer-visiting diary-file)) 749 (diary-buffer (find-buffer-visiting diary-file))
745 diary-entries-list file-glob-attrs) 750 diary-entries-list file-glob-attrs)
751 (or (bound-and-true-p diary-including)
752 (setq diary-included-files nil))
746 (message "Preparing diary...") 753 (message "Preparing diary...")
747 (save-current-buffer 754 (save-current-buffer
748 (if (not diary-buffer) 755 (if (not diary-buffer)
@@ -828,11 +835,15 @@ the variable `diary-include-string'."
828 (let ((diary-file (match-string-no-properties 1)) 835 (let ((diary-file (match-string-no-properties 1))
829 (diary-list-entries-hook 'diary-include-other-diary-files) 836 (diary-list-entries-hook 'diary-include-other-diary-files)
830 (diary-display-function 'ignore) 837 (diary-display-function 'ignore)
838 (diary-including t)
831 diary-hook diary-list-include-blanks) 839 diary-hook diary-list-include-blanks)
832 (if (file-exists-p diary-file) 840 (if (file-exists-p diary-file)
833 (if (file-readable-p diary-file) 841 (if (file-readable-p diary-file)
834 (unwind-protect 842 (unwind-protect
835 (setq diary-entries-list 843 (setq diary-included-files
844 (append diary-included-files
845 (list (expand-file-name diary-file)))
846 diary-entries-list
836 (append diary-entries-list 847 (append diary-entries-list
837 (diary-list-entries original-date number))) 848 (diary-list-entries original-date number)))
838 (with-current-buffer (find-buffer-visiting diary-file) 849 (with-current-buffer (find-buffer-visiting diary-file)
@@ -1574,7 +1585,10 @@ be used instead of a colon (:) to separate the hour and minute parts."
1574 (string-lessp ts1 ts2))))))) 1585 (string-lessp ts1 ts2)))))))
1575 1586
1576(defun diary-sort-entries () 1587(defun diary-sort-entries ()
1577 "Sort the list of diary entries by time of day." 1588 "Sort the list of diary entries by time of day.
1589If you add this function to `diary-list-entries-hook', it should
1590be the last item in the hook, in case earlier items add diary
1591entries, or change the order."
1578 (setq diary-entries-list (sort diary-entries-list 'diary-entry-compare))) 1592 (setq diary-entries-list (sort diary-entries-list 'diary-entry-compare)))
1579 1593
1580(define-obsolete-function-alias 'sort-diary-entries 'diary-sort-entries "23.1") 1594(define-obsolete-function-alias 'sort-diary-entries 'diary-sort-entries "23.1")
diff --git a/lisp/emacs-lisp/byte-run.el b/lisp/emacs-lisp/byte-run.el
index 6ce141eb8e6..0388435dbc2 100644
--- a/lisp/emacs-lisp/byte-run.el
+++ b/lisp/emacs-lisp/byte-run.el
@@ -108,10 +108,11 @@ The return value of this function is not used."
108 108
109(defvar advertised-signature-table (make-hash-table :test 'eq :weakness 'key)) 109(defvar advertised-signature-table (make-hash-table :test 'eq :weakness 'key))
110 110
111(defun set-advertised-calling-convention (function signature) 111(defun set-advertised-calling-convention (function signature when)
112 "Set the advertised SIGNATURE of FUNCTION. 112 "Set the advertised SIGNATURE of FUNCTION.
113This will allow the byte-compiler to warn the programmer when she uses 113This will allow the byte-compiler to warn the programmer when she uses
114an obsolete calling convention." 114an obsolete calling convention. WHEN specifies since when the calling
115convention was modified."
115 (puthash (indirect-function function) signature 116 (puthash (indirect-function function) signature
116 advertised-signature-table)) 117 advertised-signature-table))
117 118
@@ -132,7 +133,7 @@ was first made obsolete, for example a date or a release number."
132 obsolete-name) 133 obsolete-name)
133(set-advertised-calling-convention 134(set-advertised-calling-convention
134 ;; New code should always provide the `when' argument. 135 ;; New code should always provide the `when' argument.
135 'make-obsolete '(obsolete-name current-name when)) 136 'make-obsolete '(obsolete-name current-name when) "23.1")
136 137
137(defmacro define-obsolete-function-alias (obsolete-name current-name 138(defmacro define-obsolete-function-alias (obsolete-name current-name
138 &optional when docstring) 139 &optional when docstring)
@@ -153,7 +154,7 @@ See the docstrings of `defalias' and `make-obsolete' for more details."
153(set-advertised-calling-convention 154(set-advertised-calling-convention
154 ;; New code should always provide the `when' argument. 155 ;; New code should always provide the `when' argument.
155 'define-obsolete-function-alias 156 'define-obsolete-function-alias
156 '(obsolete-name current-name when &optional docstring)) 157 '(obsolete-name current-name when &optional docstring) "23.1")
157 158
158(defun make-obsolete-variable (obsolete-name current-name &optional when) 159(defun make-obsolete-variable (obsolete-name current-name &optional when)
159 "Make the byte-compiler warn that OBSOLETE-NAME is obsolete. 160 "Make the byte-compiler warn that OBSOLETE-NAME is obsolete.
@@ -175,7 +176,7 @@ was first made obsolete, for example a date or a release number."
175 obsolete-name) 176 obsolete-name)
176(set-advertised-calling-convention 177(set-advertised-calling-convention
177 ;; New code should always provide the `when' argument. 178 ;; New code should always provide the `when' argument.
178 'make-obsolete-variable '(obsolete-name current-name when)) 179 'make-obsolete-variable '(obsolete-name current-name when) "23.1")
179 180
180(defmacro define-obsolete-variable-alias (obsolete-name current-name 181(defmacro define-obsolete-variable-alias (obsolete-name current-name
181 &optional when docstring) 182 &optional when docstring)
@@ -210,7 +211,7 @@ CURRENT-NAME, if it does not already have them:
210(set-advertised-calling-convention 211(set-advertised-calling-convention
211 ;; New code should always provide the `when' argument. 212 ;; New code should always provide the `when' argument.
212 'define-obsolete-variable-alias 213 'define-obsolete-variable-alias
213 '(obsolete-name current-name when &optional docstring)) 214 '(obsolete-name current-name when &optional docstring) "23.1")
214 215
215;; FIXME This is only defined in this file because the variable- and 216;; FIXME This is only defined in this file because the variable- and
216;; function- versions are too. Unlike those two, this one is not used 217;; function- versions are too. Unlike those two, this one is not used
diff --git a/lisp/font-lock.el b/lisp/font-lock.el
index 92c62010848..6c316f5f958 100644
--- a/lisp/font-lock.el
+++ b/lisp/font-lock.el
@@ -564,6 +564,8 @@ outside of any comment, string, or sexp. This variable is semi-obsolete;
564we recommend setting `syntax-begin-function' instead. 564we recommend setting `syntax-begin-function' instead.
565 565
566This is normally set via `font-lock-defaults'.") 566This is normally set via `font-lock-defaults'.")
567(make-obsolete-variable 'font-lock-beginning-of-syntax-function
568 'syntax-begin-function "23.3")
567 569
568(defvar font-lock-mark-block-function nil 570(defvar font-lock-mark-block-function nil
569 "*Non-nil means use this function to mark a block of text. 571 "*Non-nil means use this function to mark a block of text.
diff --git a/lisp/menu-bar.el b/lisp/menu-bar.el
index 6149fea4769..d0a8653f95c 100644
--- a/lisp/menu-bar.el
+++ b/lisp/menu-bar.el
@@ -664,13 +664,23 @@ by \"Save Options\" in Custom buffers.")
664 ;; put on a customized-value property. 664 ;; put on a customized-value property.
665 (dolist (elt '(line-number-mode column-number-mode size-indication-mode 665 (dolist (elt '(line-number-mode column-number-mode size-indication-mode
666 cua-mode show-paren-mode transient-mark-mode 666 cua-mode show-paren-mode transient-mark-mode
667 blink-cursor-mode display-time-mode display-battery-mode)) 667 blink-cursor-mode display-time-mode display-battery-mode
668 ;; These are set by other functions that don't set
669 ;; the customized state. Having them here has the
670 ;; side-effect that turning them off via X
671 ;; resources acts like having customized them, but
672 ;; that seems harmless.
673 menu-bar-mode tool-bar-mode))
674 ;; FIXME ? It's a little annoying that running this command
675 ;; always loads cua-base, paren, time, and battery, even if they
676 ;; have not been customized in any way. (Due to custom-load-symbol.)
668 (and (customize-mark-to-save elt) 677 (and (customize-mark-to-save elt)
669 (setq need-save t))) 678 (setq need-save t)))
670 ;; These are set with `customize-set-variable'. 679 ;; These are set with `customize-set-variable'.
671 (dolist (elt '(scroll-bar-mode 680 (dolist (elt '(scroll-bar-mode
672 debug-on-quit debug-on-error 681 debug-on-quit debug-on-error
673 tooltip-mode menu-bar-mode tool-bar-mode 682 ;; Somehow this works, when tool-bar and menu-bar don't.
683 tooltip-mode
674 save-place uniquify-buffer-name-style fringe-mode 684 save-place uniquify-buffer-name-style fringe-mode
675 indicate-empty-lines indicate-buffer-boundaries 685 indicate-empty-lines indicate-buffer-boundaries
676 case-fold-search font-use-system-font 686 case-fold-search font-use-system-font
@@ -2037,6 +2047,16 @@ turn on menu bars; otherwise, turn off menu bars."
2037 (run-with-idle-timer 0 nil 'message 2047 (run-with-idle-timer 0 nil 'message
2038 "Menu-bar mode disabled. Use M-x menu-bar-mode to make the menu bar appear."))) 2048 "Menu-bar mode disabled. Use M-x menu-bar-mode to make the menu bar appear.")))
2039 2049
2050;;;###autoload
2051;; (This does not work right unless it comes after the above definition.)
2052;; This comment is taken from tool-bar.el near
2053;; (put 'tool-bar-mode ...)
2054;; We want to pretend the menu bar by standard is on, as this will make
2055;; customize consider disabling the menu bar a customization, and save
2056;; that. We could do this for real by setting :init-value above, but
2057;; that would overwrite disabling the menu bar from X resources.
2058(put 'menu-bar-mode 'standard-value '(t))
2059
2040(defun toggle-menu-bar-mode-from-frame (&optional arg) 2060(defun toggle-menu-bar-mode-from-frame (&optional arg)
2041 "Toggle menu bar on or off, based on the status of the current frame. 2061 "Toggle menu bar on or off, based on the status of the current frame.
2042See `menu-bar-mode' for more information." 2062See `menu-bar-mode' for more information."
diff --git a/lisp/progmodes/antlr-mode.el b/lisp/progmodes/antlr-mode.el
index 9b24ac7a1f4..742bcf726eb 100644
--- a/lisp/progmodes/antlr-mode.el
+++ b/lisp/progmodes/antlr-mode.el
@@ -951,7 +951,7 @@ group. The string matched by the first group is highlighted with
951 (3 antlr-keyword-face) 951 (3 antlr-keyword-face)
952 (4 (if (member (match-string 4) '("Lexer" "Parser" "TreeParser")) 952 (4 (if (member (match-string 4) '("Lexer" "Parser" "TreeParser"))
953 antlr-keyword-face 953 antlr-keyword-face
954 type-face))) 954 font-lock-type-face)))
955 (,(lambda (limit) 955 (,(lambda (limit)
956 (antlr-re-search-forward 956 (antlr-re-search-forward
957 "\\<\\(header\\|options\\|tokens\\|exception\\|catch\\|returns\\)\\>" 957 "\\<\\(header\\|options\\|tokens\\|exception\\|catch\\|returns\\)\\>"
diff --git a/lisp/repeat.el b/lisp/repeat.el
index eddaf4f020e..86484ec68d6 100644
--- a/lisp/repeat.el
+++ b/lisp/repeat.el
@@ -335,7 +335,12 @@ recently executed command not bound to an input event\"."
335 (setq real-last-command 'repeat) 335 (setq real-last-command 'repeat)
336 (setq repeat-undo-count 1) 336 (setq repeat-undo-count 1)
337 (unwind-protect 337 (unwind-protect
338 (while (eq (read-event) repeat-repeat-char) 338 (while (let ((evt (read-event))) ;FIXME: read-key maybe?
339 ;; For clicks, we need to strip the meta-data to
340 ;; check the underlying event name.
341 (eq (or (car-safe evt) evt)
342 (or (car-safe repeat-repeat-char)
343 repeat-repeat-char)))
339 (repeat repeat-arg)) 344 (repeat repeat-arg))
340 ;; Make sure `repeat-undo-count' is reset. 345 ;; Make sure `repeat-undo-count' is reset.
341 (setq repeat-undo-count nil)) 346 (setq repeat-undo-count nil))
diff --git a/lisp/simple.el b/lisp/simple.el
index 36931c7777c..1ab737d5ec1 100644
--- a/lisp/simple.el
+++ b/lisp/simple.el
@@ -4343,7 +4343,7 @@ into account variable-width characters and line continuation."
4343 (or (and (= (vertical-motion 4343 (or (and (= (vertical-motion
4344 (cons (or goal-column 4344 (cons (or goal-column
4345 (if (consp temporary-goal-column) 4345 (if (consp temporary-goal-column)
4346 (truncate (car temporary-goal-column)) 4346 (car temporary-goal-column)
4347 temporary-goal-column)) 4347 temporary-goal-column))
4348 arg)) 4348 arg))
4349 arg) 4349 arg)
diff --git a/lisp/subr.el b/lisp/subr.el
index f2c12a736c2..b391f1f0b93 100644
--- a/lisp/subr.el
+++ b/lisp/subr.el
@@ -239,7 +239,7 @@ letter but *do not* end with a period. Please follow this convention
239for the sake of consistency." 239for the sake of consistency."
240 (while t 240 (while t
241 (signal 'error (list (apply 'format args))))) 241 (signal 'error (list (apply 'format args)))))
242(set-advertised-calling-convention 'error '(string &rest args)) 242(set-advertised-calling-convention 'error '(string &rest args) "23.1")
243 243
244;; We put this here instead of in frame.el so that it's defined even on 244;; We put this here instead of in frame.el so that it's defined even on
245;; systems where frame.el isn't loaded. 245;; systems where frame.el isn't loaded.
@@ -1039,9 +1039,10 @@ is converted into a string by expressing it in decimal."
1039(make-obsolete 'make-variable-frame-local 1039(make-obsolete 'make-variable-frame-local
1040 "explicitly check for a frame-parameter instead." "22.2") 1040 "explicitly check for a frame-parameter instead." "22.2")
1041(make-obsolete 'interactive-p 'called-interactively-p "23.2") 1041(make-obsolete 'interactive-p 'called-interactively-p "23.2")
1042(set-advertised-calling-convention 'called-interactively-p '(kind)) 1042(set-advertised-calling-convention 'called-interactively-p '(kind) "23.1")
1043(set-advertised-calling-convention 1043(set-advertised-calling-convention
1044 'all-completions '(string collection &optional predicate)) 1044 'all-completions '(string collection &optional predicate) "23.1")
1045(set-advertised-calling-convention 'unintern '(name obarray) "23.3")
1045 1046
1046;;;; Obsolescence declarations for variables, and aliases. 1047;;;; Obsolescence declarations for variables, and aliases.
1047 1048
@@ -2064,7 +2065,7 @@ floating point support."
2064 (setq read (cons t read))) 2065 (setq read (cons t read)))
2065 (push read unread-command-events) 2066 (push read unread-command-events)
2066 nil)))))) 2067 nil))))))
2067(set-advertised-calling-convention 'sit-for '(seconds &optional nodisp)) 2068(set-advertised-calling-convention 'sit-for '(seconds &optional nodisp) "22.1")
2068 2069
2069;;; Atomic change groups. 2070;;; Atomic change groups.
2070 2071
@@ -2592,7 +2593,7 @@ discouraged."
2592 (start-process name buffer shell-file-name shell-command-switch 2593 (start-process name buffer shell-file-name shell-command-switch
2593 (mapconcat 'identity args " "))) 2594 (mapconcat 'identity args " ")))
2594(set-advertised-calling-convention 'start-process-shell-command 2595(set-advertised-calling-convention 'start-process-shell-command
2595 '(name buffer command)) 2596 '(name buffer command) "23.1")
2596 2597
2597(defun start-file-process-shell-command (name buffer &rest args) 2598(defun start-file-process-shell-command (name buffer &rest args)
2598 "Start a program in a subprocess. Return the process object for it. 2599 "Start a program in a subprocess. Return the process object for it.
@@ -2603,7 +2604,7 @@ Similar to `start-process-shell-command', but calls `start-file-process'."
2603 (if (file-remote-p default-directory) "-c" shell-command-switch) 2604 (if (file-remote-p default-directory) "-c" shell-command-switch)
2604 (mapconcat 'identity args " "))) 2605 (mapconcat 'identity args " ")))
2605(set-advertised-calling-convention 'start-file-process-shell-command 2606(set-advertised-calling-convention 'start-file-process-shell-command
2606 '(name buffer command)) 2607 '(name buffer command) "23.1")
2607 2608
2608(defun call-process-shell-command (command &optional infile buffer display 2609(defun call-process-shell-command (command &optional infile buffer display
2609 &rest args) 2610 &rest args)
diff --git a/lisp/url/ChangeLog b/lisp/url/ChangeLog
index 170bedd3b28..7726f6cd081 100644
--- a/lisp/url/ChangeLog
+++ b/lisp/url/ChangeLog
@@ -1,3 +1,15 @@
12010-09-14 Julien Danjou <julien@danjou.info>
2
3 * url-cache (url-store-in-cache): Make `buff' argument really optional.
4
52010-09-14 Glenn Morris <rgm@gnu.org>
6
7 * url-cookie.el (url-cookie-expired-p): Tweak previous change.
8
92010-09-14 shawn boles <shawn.boles@gmail.com> (tiny change)
10
11 * url-cookie.el (url-cookie-expired-p): Simplify and fix. (Bug#6957)
12
12010-09-11 Glenn Morris <rgm@gnu.org> 132010-09-11 Glenn Morris <rgm@gnu.org>
2 14
3 * url-cache.el, url-gw.el, url-history.el, url-irc.el, url-util.el: 15 * url-cache.el, url-gw.el, url-history.el, url-irc.el, url-util.el:
diff --git a/lisp/url/url-cache.el b/lisp/url/url-cache.el
index 7cff9aa923d..3a6f00db306 100644
--- a/lisp/url/url-cache.el
+++ b/lisp/url/url-cache.el
@@ -62,14 +62,11 @@ FILE can be created or overwritten."
62;;;###autoload 62;;;###autoload
63(defun url-store-in-cache (&optional buff) 63(defun url-store-in-cache (&optional buff)
64 "Store buffer BUFF in the cache." 64 "Store buffer BUFF in the cache."
65 (if (not (and buff (get-buffer buff))) 65 (with-current-buffer (get-buffer (or buff (current-buffer)))
66 nil 66 (let ((fname (url-cache-create-filename (url-view-url t))))
67 (save-current-buffer 67 (if (url-cache-prepare fname)
68 (and buff (set-buffer buff)) 68 (let ((coding-system-for-write 'binary))
69 (let* ((fname (url-cache-create-filename (url-view-url t)))) 69 (write-region (point-min) (point-max) fname nil 5))))))
70 (if (url-cache-prepare fname)
71 (let ((coding-system-for-write 'binary))
72 (write-region (point-min) (point-max) fname nil 5)))))))
73 70
74;;;###autoload 71;;;###autoload
75(defun url-is-cached (url) 72(defun url-is-cached (url)
diff --git a/lisp/url/url-cookie.el b/lisp/url/url-cookie.el
index 75a1b218830..2067f097224 100644
--- a/lisp/url/url-cookie.el
+++ b/lisp/url/url-cookie.el
@@ -1,7 +1,7 @@
1;;; url-cookie.el --- Netscape Cookie support 1;;; url-cookie.el --- Netscape Cookie support
2 2
3;; Copyright (C) 1996, 1997, 1998, 1999, 2004, 3;; Copyright (C) 1996, 1997, 1998, 1999, 2004, 2005, 2006, 2007, 2008,
4;; 2005, 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc. 4;; 2009, 2010 Free Software Foundation, Inc.
5 5
6;; Keywords: comm, data, processes, hypermedia 6;; Keywords: comm, data, processes, hypermedia
7 7
@@ -24,7 +24,6 @@
24 24
25;;; Code: 25;;; Code:
26 26
27(require 'timezone)
28(require 'url-util) 27(require 'url-util)
29(require 'url-parse) 28(require 'url-parse)
30(eval-when-compile (require 'cl)) 29(eval-when-compile (require 'cl))
@@ -194,34 +193,9 @@ telling Microsoft that."
194 (setq url-cookie-storage (list (list domain tmp)))))))) 193 (setq url-cookie-storage (list (list domain tmp))))))))
195 194
196(defun url-cookie-expired-p (cookie) 195(defun url-cookie-expired-p (cookie)
197 (let* ( 196 "Return non-nil if COOKIE is expired."
198 (exp (url-cookie-expires cookie)) 197 (let ((exp (url-cookie-expires cookie)))
199 (cur-date (and exp (timezone-parse-date (current-time-string)))) 198 (and exp (> (float-time) (float-time (date-to-time exp))))))
200 (exp-date (and exp (timezone-parse-date exp)))
201 (cur-greg (and cur-date (timezone-absolute-from-gregorian
202 (string-to-number (aref cur-date 1))
203 (string-to-number (aref cur-date 2))
204 (string-to-number (aref cur-date 0)))))
205 (exp-greg (and exp (timezone-absolute-from-gregorian
206 (string-to-number (aref exp-date 1))
207 (string-to-number (aref exp-date 2))
208 (string-to-number (aref exp-date 0)))))
209 (diff-in-days (and exp (- cur-greg exp-greg)))
210 )
211 (cond
212 ((not exp) nil) ; No expiry == expires at browser quit
213 ((< diff-in-days 0) nil) ; Expires sometime after today
214 ((> diff-in-days 0) t) ; Expired before today
215 (t ; Expires sometime today, check times
216 (let* ((cur-time (timezone-parse-time (aref cur-date 3)))
217 (exp-time (timezone-parse-time (aref exp-date 3)))
218 (cur-norm (+ (* 360 (string-to-number (aref cur-time 2)))
219 (* 60 (string-to-number (aref cur-time 1)))
220 (* 1 (string-to-number (aref cur-time 0)))))
221 (exp-norm (+ (* 360 (string-to-number (aref exp-time 2)))
222 (* 60 (string-to-number (aref exp-time 1)))
223 (* 1 (string-to-number (aref exp-time 0))))))
224 (> (- cur-norm exp-norm) 1))))))
225 199
226(defun url-cookie-retrieve (host &optional localpart secure) 200(defun url-cookie-retrieve (host &optional localpart secure)
227 "Retrieve all the netscape-style cookies for a specified HOST and LOCALPART." 201 "Retrieve all the netscape-style cookies for a specified HOST and LOCALPART."
diff --git a/lisp/vc/vc-hg.el b/lisp/vc/vc-hg.el
index c087a4d9e1f..689cd4d12bd 100644
--- a/lisp/vc/vc-hg.el
+++ b/lisp/vc/vc-hg.el
@@ -171,10 +171,12 @@ If nil, use the value of `vc-diff-switches'. If t, use no switches."
171 (let ((process-environment 171 (let ((process-environment
172 ;; Avoid localization of messages so we 172 ;; Avoid localization of messages so we
173 ;; can parse the output. 173 ;; can parse the output.
174 (append (list "TERM=dumb" "LANGUAGE=C" "HGRCPATH=") 174 (append (list "TERM=dumb" "LANGUAGE=C")
175 process-environment))) 175 process-environment)))
176 (process-file 176 (process-file
177 "hg" nil t nil 177 "hg" nil t nil
178 "--config" "alias.status=status"
179 "--config" "defaults.status="
178 "status" "-A" (file-relative-name file))) 180 "status" "-A" (file-relative-name file)))
179 ;; Some problem happened. E.g. We can't find an `hg' 181 ;; Some problem happened. E.g. We can't find an `hg'
180 ;; executable. 182 ;; executable.
@@ -199,7 +201,7 @@ If nil, use the value of `vc-diff-switches'. If t, use no switches."
199 ((status nil) 201 ((status nil)
200 (default-directory (file-name-directory file)) 202 (default-directory (file-name-directory file))
201 ;; Avoid localization of messages so we can parse the output. 203 ;; Avoid localization of messages so we can parse the output.
202 (avoid-local-env (append (list "TERM=dumb" "LANGUAGE=C" "HGRCPATH=") 204 (avoid-local-env (append (list "TERM=dumb" "LANGUAGE=C")
203 process-environment)) 205 process-environment))
204 (out 206 (out
205 (with-output-to-string 207 (with-output-to-string
@@ -211,6 +213,8 @@ If nil, use the value of `vc-diff-switches'. If t, use no switches."
211 ;; Ignore all errors. 213 ;; Ignore all errors.
212 (process-file 214 (process-file
213 "hg" nil t nil 215 "hg" nil t nil
216 "--config" "alias.parents=parents"
217 "--config" "defaults.parents="
214 "parents" "--template" "{rev}" (file-relative-name file))) 218 "parents" "--template" "{rev}" (file-relative-name file)))
215 ;; Some problem happened. E.g. We can't find an `hg' 219 ;; Some problem happened. E.g. We can't find an `hg'
216 ;; executable. 220 ;; executable.
diff --git a/src/ChangeLog b/src/ChangeLog
index fa0dfc79c5b..29f410cad86 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,7 +1,29 @@
12010-09-14 Jan Djärv <jan.h.d@swipnet.se>
2
3 * xterm.c (get_current_vm_state): New function.
4 (do_ewmh_fullscreen): Call get_current_vm_state and compare with
5 want_fullscreen so set_wm_state calls are few (Bug#7013).
6 (x_handle_net_wm_state): Move code to get_current_vm_state and
7 call that function.
8
92010-09-14 Courtney Bane <emacs-bugs-7626@cbane.org> (tiny change)
10
11 * term.c (tty_set_terminal_modes): Don't initialize twice (bug#7002).
12
132010-09-14 Kenichi Handa <handa@m17n.org>
14
15 * coding.c (encode_coding_iso_2022): Don't optimize for ASCII if
16 we may use designation or locking-shift.
17
182010-09-14 Kenichi Handa <handa@m17n.org>
19
20 * coding.c (detect_coding_emacs_mule): Fix checking of multibyte
21 sequence when the source is multibyte.
22
12010-09-14 Andreas Schwab <schwab@linux-m68k.org> 232010-09-14 Andreas Schwab <schwab@linux-m68k.org>
2 24
3 * xml.c (Fxml_parse_string, Fxml_parse_string): Revert last 25 * xml.c (Fxml_parse_string, Fxml_parse_string): Revert last change.
4 change. Don't make first argument optional. Doc fix. 26 Don't make first argument optional. Doc fix.
5 27
62010-09-14 Leo <sdl.web@gmail.com> (tiny change) 282010-09-14 Leo <sdl.web@gmail.com> (tiny change)
7 29
@@ -111,8 +133,8 @@
111 (produce_stretch_glyph): Set it2.char_to_display too before 133 (produce_stretch_glyph): Set it2.char_to_display too before
112 calling x_produce_glyphs. 134 calling x_produce_glyphs.
113 (x_produce_glyphs): Simplify by using the same code for ASCII and 135 (x_produce_glyphs): Simplify by using the same code for ASCII and
114 non-ASCII characters. Don't set it->char_to_display here. Don't 136 non-ASCII characters. Don't set it->char_to_display here.
115 handle unibyte-display-via-language-environment here. For a 137 Don't handle unibyte-display-via-language-environment here. For a
116 charater of no glyph, use font->space_width instead of FONT_WIDTH. 138 charater of no glyph, use font->space_width instead of FONT_WIDTH.
117 139
1182010-08-31 Stefan Monnier <monnier@iro.umontreal.ca> 1402010-08-31 Stefan Monnier <monnier@iro.umontreal.ca>
diff --git a/src/coding.c b/src/coding.c
index 6012978b60a..d6285ed9245 100644
--- a/src/coding.c
+++ b/src/coding.c
@@ -2008,7 +2008,7 @@ detect_coding_emacs_mule (struct coding_system *coding,
2008 } 2008 }
2009 else 2009 else
2010 { 2010 {
2011 int more_bytes = emacs_mule_bytes[*src_base] - 1; 2011 int more_bytes = emacs_mule_bytes[c] - 1;
2012 2012
2013 while (more_bytes > 0) 2013 while (more_bytes > 0)
2014 { 2014 {
@@ -4490,7 +4490,10 @@ encode_coding_iso_2022 (struct coding_system *coding)
4490 charset_list = CODING_ATTR_CHARSET_LIST (attrs); 4490 charset_list = CODING_ATTR_CHARSET_LIST (attrs);
4491 coding->safe_charsets = SDATA (CODING_ATTR_SAFE_CHARSETS (attrs)); 4491 coding->safe_charsets = SDATA (CODING_ATTR_SAFE_CHARSETS (attrs));
4492 4492
4493 ascii_compatible = ! NILP (CODING_ATTR_ASCII_COMPAT (attrs)); 4493 ascii_compatible
4494 = (! NILP (CODING_ATTR_ASCII_COMPAT (attrs))
4495 && ! (CODING_ISO_FLAGS (coding) & (CODING_ISO_FLAG_DESIGNATION
4496 | CODING_ISO_FLAG_LOCKING_SHIFT)));
4494 4497
4495 while (charbuf < charbuf_end) 4498 while (charbuf < charbuf_end)
4496 { 4499 {
diff --git a/src/term.c b/src/term.c
index f090cdd2792..2deca1014e8 100644
--- a/src/term.c
+++ b/src/term.c
@@ -247,7 +247,6 @@ tty_set_terminal_modes (struct terminal *terminal)
247 cmputc ('\n'); 247 cmputc ('\n');
248 } 248 }
249 249
250 OUTPUT_IF (tty, tty->TS_termcap_modes);
251 OUTPUT_IF (tty, visible_cursor ? tty->TS_cursor_visible : tty->TS_cursor_normal); 250 OUTPUT_IF (tty, visible_cursor ? tty->TS_cursor_visible : tty->TS_cursor_normal);
252 OUTPUT_IF (tty, tty->TS_keypad_mode); 251 OUTPUT_IF (tty, tty->TS_keypad_mode);
253 losecursor (tty); 252 losecursor (tty);
diff --git a/src/xterm.c b/src/xterm.c
index 2ebe8a80378..c1d1aada530 100644
--- a/src/xterm.c
+++ b/src/xterm.c
@@ -8285,19 +8285,89 @@ x_set_sticky (struct frame *f, Lisp_Object new_value, Lisp_Object old_value)
8285 "_NET_WM_STATE_STICKY", NULL); 8285 "_NET_WM_STATE_STICKY", NULL);
8286} 8286}
8287 8287
8288/* Return the current _NET_WM_STATE.
8289 SIZE_STATE is set to one of the FULLSCREEN_* values.
8290 STICKY is set to 1 if the sticky state is set, 0 if not. */
8291
8292static void
8293get_current_vm_state (struct frame *f,
8294 Window window,
8295 int *size_state,
8296 int *sticky)
8297{
8298 Atom actual_type;
8299 unsigned long actual_size, bytes_remaining;
8300 int i, rc, actual_format;
8301 struct x_display_info *dpyinfo = FRAME_X_DISPLAY_INFO (f);
8302 long max_len = 65536;
8303 Display *dpy = FRAME_X_DISPLAY (f);
8304 unsigned char *tmp_data = NULL;
8305 Atom target_type = XA_ATOM;
8306
8307 *sticky = 0;
8308 *size_state = FULLSCREEN_NONE;
8309
8310 BLOCK_INPUT;
8311 x_catch_errors (dpy);
8312 rc = XGetWindowProperty (dpy, window, dpyinfo->Xatom_net_wm_state,
8313 0, max_len, False, target_type,
8314 &actual_type, &actual_format, &actual_size,
8315 &bytes_remaining, &tmp_data);
8316
8317 if (rc != Success || actual_type != target_type || x_had_errors_p (dpy))
8318 {
8319 if (tmp_data) XFree (tmp_data);
8320 x_uncatch_errors ();
8321 UNBLOCK_INPUT;
8322 return;
8323 }
8324
8325 x_uncatch_errors ();
8326
8327 for (i = 0; i < actual_size; ++i)
8328 {
8329 Atom a = ((Atom*)tmp_data)[i];
8330 if (a == dpyinfo->Xatom_net_wm_state_maximized_horz)
8331 {
8332 if (*size_state == FULLSCREEN_HEIGHT)
8333 *size_state = FULLSCREEN_MAXIMIZED;
8334 else
8335 *size_state = FULLSCREEN_WIDTH;
8336 }
8337 else if (a == dpyinfo->Xatom_net_wm_state_maximized_vert)
8338 {
8339 if (*size_state == FULLSCREEN_WIDTH)
8340 *size_state = FULLSCREEN_MAXIMIZED;
8341 else
8342 *size_state = FULLSCREEN_HEIGHT;
8343 }
8344 else if (a == dpyinfo->Xatom_net_wm_state_fullscreen_atom)
8345 *size_state = FULLSCREEN_BOTH;
8346 else if (a == dpyinfo->Xatom_net_wm_state_sticky)
8347 *sticky = 1;
8348 }
8349
8350 if (tmp_data) XFree (tmp_data);
8351 UNBLOCK_INPUT;
8352}
8353
8288/* Do fullscreen as specified in extended window manager hints */ 8354/* Do fullscreen as specified in extended window manager hints */
8289 8355
8290static int 8356static int
8291do_ewmh_fullscreen (struct frame *f) 8357do_ewmh_fullscreen (struct frame *f)
8292{ 8358{
8293 int have_net_atom = wm_supports (f, "_NET_WM_STATE"); 8359 int have_net_atom = wm_supports (f, "_NET_WM_STATE");
8360 Lisp_Object lval = get_frame_param (f, Qfullscreen);
8361 int cur, dummy;
8362
8363 get_current_vm_state (f, FRAME_OUTER_WINDOW (f), &cur, &dummy);
8294 8364
8295 /* Some window managers don't say they support _NET_WM_STATE, but they do say 8365 /* Some window managers don't say they support _NET_WM_STATE, but they do say
8296 they support _NET_WM_STATE_FULLSCREEN. Try that also. */ 8366 they support _NET_WM_STATE_FULLSCREEN. Try that also. */
8297 if (!have_net_atom) 8367 if (!have_net_atom)
8298 have_net_atom = wm_supports (f, "_NET_WM_STATE_FULLSCREEN"); 8368 have_net_atom = wm_supports (f, "_NET_WM_STATE_FULLSCREEN");
8299 8369
8300 if (have_net_atom) 8370 if (have_net_atom && cur != f->want_fullscreen)
8301 { 8371 {
8302 Lisp_Object frame; 8372 Lisp_Object frame;
8303 const char *fs = "_NET_WM_STATE_FULLSCREEN"; 8373 const char *fs = "_NET_WM_STATE_FULLSCREEN";
@@ -8306,26 +8376,41 @@ do_ewmh_fullscreen (struct frame *f)
8306 8376
8307 XSETFRAME (frame, f); 8377 XSETFRAME (frame, f);
8308 8378
8309 set_wm_state (frame, 0, fs, NULL); 8379 /* Keep number of calls to set_wm_state as low as possible.
8310 set_wm_state (frame, 0, fh, NULL); 8380 Some window managers, or possible Gtk+, hangs when too many
8311 set_wm_state (frame, 0, fw, NULL); 8381 are sent at once. */
8312
8313 /* If there are _NET_ atoms we assume we have extended window manager
8314 hints. */
8315 switch (f->want_fullscreen) 8382 switch (f->want_fullscreen)
8316 { 8383 {
8317 case FULLSCREEN_BOTH: 8384 case FULLSCREEN_BOTH:
8385 if (cur == FULLSCREEN_WIDTH || cur == FULLSCREEN_MAXIMIZED
8386 || cur == FULLSCREEN_HEIGHT)
8387 set_wm_state (frame, 0, fw, fh);
8318 set_wm_state (frame, 1, fs, NULL); 8388 set_wm_state (frame, 1, fs, NULL);
8319 break; 8389 break;
8320 case FULLSCREEN_WIDTH: 8390 case FULLSCREEN_WIDTH:
8321 set_wm_state (frame, 1, fw, NULL); 8391 if (cur == FULLSCREEN_BOTH || cur == FULLSCREEN_HEIGHT
8392 || cur == FULLSCREEN_MAXIMIZED)
8393 set_wm_state (frame, 0, fs, fh);
8394 if (cur != FULLSCREEN_MAXIMIZED)
8395 set_wm_state (frame, 1, fw, NULL);
8322 break; 8396 break;
8323 case FULLSCREEN_HEIGHT: 8397 case FULLSCREEN_HEIGHT:
8324 set_wm_state (frame, 1, fh, NULL); 8398 if (cur == FULLSCREEN_BOTH || cur == FULLSCREEN_WIDTH
8399 || cur == FULLSCREEN_MAXIMIZED)
8400 set_wm_state (frame, 0, fs, fw);
8401 if (cur != FULLSCREEN_MAXIMIZED)
8402 set_wm_state (frame, 1, fh, NULL);
8325 break; 8403 break;
8326 case FULLSCREEN_MAXIMIZED: 8404 case FULLSCREEN_MAXIMIZED:
8405 if (cur == FULLSCREEN_BOTH)
8406 set_wm_state (frame, 0, fs, NULL);
8327 set_wm_state (frame, 1, fw, fh); 8407 set_wm_state (frame, 1, fw, fh);
8328 break; 8408 break;
8409 case FULLSCREEN_NONE:
8410 if (cur == FULLSCREEN_BOTH)
8411 set_wm_state (frame, 0, fs, NULL);
8412 else
8413 set_wm_state (frame, 0, fw, fh);
8329 } 8414 }
8330 8415
8331 f->want_fullscreen = FULLSCREEN_NONE; 8416 f->want_fullscreen = FULLSCREEN_NONE;
@@ -8351,57 +8436,11 @@ XTfullscreen_hook (FRAME_PTR f)
8351static void 8436static void
8352x_handle_net_wm_state (struct frame *f, XPropertyEvent *event) 8437x_handle_net_wm_state (struct frame *f, XPropertyEvent *event)
8353{ 8438{
8354 Atom actual_type; 8439 int value = FULLSCREEN_NONE;
8355 unsigned long actual_size, bytes_remaining;
8356 int i, rc, actual_format, value = FULLSCREEN_NONE;
8357 struct x_display_info *dpyinfo = FRAME_X_DISPLAY_INFO (f);
8358 long max_len = 65536;
8359 Display *dpy = FRAME_X_DISPLAY (f);
8360 unsigned char *tmp_data = NULL;
8361 Atom target_type = XA_ATOM;
8362 Lisp_Object lval; 8440 Lisp_Object lval;
8363 int sticky = 0; 8441 int sticky = 0;
8364 8442
8365 BLOCK_INPUT; 8443 get_current_vm_state (f, event->window, &value, &sticky);
8366 x_catch_errors (dpy);
8367 rc = XGetWindowProperty (dpy, event->window,
8368 event->atom, 0, max_len, False, target_type,
8369 &actual_type, &actual_format, &actual_size,
8370 &bytes_remaining, &tmp_data);
8371
8372 if (rc != Success || actual_type != target_type || x_had_errors_p (dpy))
8373 {
8374 if (tmp_data) XFree (tmp_data);
8375 x_uncatch_errors ();
8376 UNBLOCK_INPUT;
8377 return;
8378 }
8379
8380 x_uncatch_errors ();
8381
8382 for (i = 0; i < actual_size; ++i)
8383 {
8384 Atom a = ((Atom*)tmp_data)[i];
8385 if (a == dpyinfo->Xatom_net_wm_state_maximized_horz)
8386 {
8387 if (value == FULLSCREEN_HEIGHT)
8388 value = FULLSCREEN_MAXIMIZED;
8389 else
8390 value = FULLSCREEN_WIDTH;
8391 }
8392 else if (a == dpyinfo->Xatom_net_wm_state_maximized_vert)
8393 {
8394 if (value == FULLSCREEN_WIDTH)
8395 value = FULLSCREEN_MAXIMIZED;
8396 else
8397 value = FULLSCREEN_HEIGHT;
8398 }
8399 else if (a == dpyinfo->Xatom_net_wm_state_fullscreen_atom)
8400 value = FULLSCREEN_BOTH;
8401 else if (a == dpyinfo->Xatom_net_wm_state_sticky)
8402 sticky = 1;
8403 }
8404
8405 lval = Qnil; 8444 lval = Qnil;
8406 switch (value) 8445 switch (value)
8407 { 8446 {
@@ -8421,9 +8460,6 @@ x_handle_net_wm_state (struct frame *f, XPropertyEvent *event)
8421 8460
8422 store_frame_param (f, Qfullscreen, lval); 8461 store_frame_param (f, Qfullscreen, lval);
8423 store_frame_param (f, Qsticky, sticky ? Qt : Qnil); 8462 store_frame_param (f, Qsticky, sticky ? Qt : Qnil);
8424
8425 if (tmp_data) XFree (tmp_data);
8426 UNBLOCK_INPUT;
8427} 8463}
8428 8464
8429/* Check if we need to resize the frame due to a fullscreen request. 8465/* Check if we need to resize the frame due to a fullscreen request.