emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

master f909433 3/3: Merge from origin/emacs-27


From: Paul Eggert
Subject: master f909433 3/3: Merge from origin/emacs-27
Date: Sun, 5 Jan 2020 14:47:25 -0500 (EST)

branch: master
commit f9094332287cf1434788f6407347265350ae5dd5
Merge: bb2b857 448df8f
Author: Paul Eggert <address@hidden>
Commit: Paul Eggert <address@hidden>

    Merge from origin/emacs-27
    
    448df8fec7 Improve doc-strings of 'quit-window' and 'quit-restore-win...
    7f01dfca56 Fix MH-E bug #470: Show buffer discards text properties
    f95a2b8301 Fix some broken conditional forms
    28727444f1 Fix a scoping error in tramp-sudoedit.el
    6cbdd048bd * lisp/autorevert.el (auto-revert-notify-handler): Fix bra...
    076dd1f69a Fix typo in 'window_box_height'
---
 lisp/autorevert.el                |  4 ++--
 lisp/cedet/ede/cpp-root.el        | 15 ---------------
 lisp/cedet/ede/pconf.el           |  5 +++--
 lisp/cedet/srecode/semantic.el    |  2 +-
 lisp/emacs-lisp/tabulated-list.el |  8 ++++----
 lisp/filesets.el                  |  2 +-
 lisp/gnus/gnus-cloud.el           |  8 ++++----
 lisp/gnus/mml-smime.el            | 11 +++--------
 lisp/international/titdic-cnv.el  |  3 +--
 lisp/mh-e/mh-show.el              | 14 ++++++--------
 lisp/net/nsm.el                   |  6 +++---
 lisp/net/tramp-sudoedit.el        | 30 +++++++++++++++---------------
 lisp/org/org-agenda.el            |  1 -
 lisp/org/ox-odt.el                |  2 +-
 lisp/textmodes/table.el           |  6 +-----
 lisp/window.el                    | 16 ++++++++--------
 src/xdisp.c                       | 21 +++++++++++----------
 17 files changed, 64 insertions(+), 90 deletions(-)

diff --git a/lisp/autorevert.el b/lisp/autorevert.el
index 7503fcc..3151b6e 100644
--- a/lisp/autorevert.el
+++ b/lisp/autorevert.el
@@ -733,8 +733,8 @@ system.")
                      (null buffer-file-name))
                 (auto-revert-notify-rm-watch)
                 ;; Restart the timer if it wasn't running.
-                (unless auto-revert-timer)
-                  (auto-revert-set-timer))))
+                (unless auto-revert-timer
+                  (auto-revert-set-timer)))))
 
         ;; Loop over all buffers, in order to find the intended one.
         (cl-dolist (buffer buffers)
diff --git a/lisp/cedet/ede/cpp-root.el b/lisp/cedet/ede/cpp-root.el
index ee8aa5d..f0dbccb 100644
--- a/lisp/cedet/ede/cpp-root.el
+++ b/lisp/cedet/ede/cpp-root.el
@@ -478,21 +478,6 @@ Argument COMMAND is the command to use for compiling the 
target."
   "Don't rescan this project from the sources."
   (message "cpp-root has nothing to rescan."))
 
-;;; Quick Hack
-(defun ede-create-lots-of-projects-under-dir (dir projfile &rest attributes)
-  "Create a bunch of projects under directory DIR.
-PROJFILE is a file name sans directory that indicates a subdirectory
-is a project directory.
-Generic ATTRIBUTES, such as :include-path can be added.
-Note: This needs some work."
-  (let ((files (directory-files dir t)))
-    (dolist (F files)
-      (if (file-exists-p (expand-file-name projfile F))
-         `(ede-cpp-root-project (file-name-nondirectory F)
-                                :name (file-name-nondirectory F)
-                                :file (expand-file-name projfile F)
-                                attributes)))))
-
 (provide 'ede/cpp-root)
 
 ;; Local variables:
diff --git a/lisp/cedet/ede/pconf.el b/lisp/cedet/ede/pconf.el
index 63fb62b..b85b397 100644
--- a/lisp/cedet/ede/pconf.el
+++ b/lisp/cedet/ede/pconf.el
@@ -56,8 +56,9 @@ don't do it.  A value of nil means to just do it.")
            (and (eq ede-pconf-create-file-query 'ask)
                 (not (eq ede-pconf-create-file-query 'never))
                 (not (y-or-n-p
-                      (format "I had to create the %s file for you.  Ok? " 
file)))
-                (error "Quit")))))))
+                      (format "I had to create the %s file for you.  Ok? "
+                              file))))
+         (error "Quit"))))))
 
 
 (cl-defmethod ede-proj-configure-synchronize ((this ede-proj-project))
diff --git a/lisp/cedet/srecode/semantic.el b/lisp/cedet/srecode/semantic.el
index 26c1489..5b2dd03 100644
--- a/lisp/cedet/srecode/semantic.el
+++ b/lisp/cedet/srecode/semantic.el
@@ -201,7 +201,7 @@ variable default values, and other things."
   (let ((tag (or srecode-semantic-selected-tag
                 (srecode-semantic-tag-from-kill-ring))))
     (when (not tag)
-      "No tag for current template.  Use the semantic kill-ring.")
+      (error "No tag for current template.  Use the semantic kill-ring."))
     (srecode-semantic-apply-tag-to-dict
      (srecode-semantic-tag (semantic-tag-name tag)
                           :prime tag)
diff --git a/lisp/emacs-lisp/tabulated-list.el 
b/lisp/emacs-lisp/tabulated-list.el
index 501cc3a..b13f609 100644
--- a/lisp/emacs-lisp/tabulated-list.el
+++ b/lisp/emacs-lisp/tabulated-list.el
@@ -547,10 +547,10 @@ Return the column number after insertion."
     ;; Don't truncate to `width' if the next column is align-right
     ;; and has some space left, truncate to `available-space' instead.
     (when (and not-last-col
-               (> label-width available-space)
-               (setq label (truncate-string-to-width
-                            label available-space nil nil t t)
-                     label-width available-space)))
+              (> label-width available-space))
+      (setq label (truncate-string-to-width
+                  label available-space nil nil t t)
+           label-width available-space))
     (setq label (bidi-string-mark-left-to-right label))
     (when (and right-align (> width label-width))
       (let ((shift (- width label-width)))
diff --git a/lisp/filesets.el b/lisp/filesets.el
index 9834bcf..1ec0d24 100644
--- a/lisp/filesets.el
+++ b/lisp/filesets.el
@@ -1645,10 +1645,10 @@ Replace <file-name> or <<file-name>> with filename."
                                      (dolist (this args txt)
                                        (setq txt
                                              (concat txt
+                                                     (if (equal txt "") "" " ")
                                                      (filesets-run-cmd--repl-fn
                                                       this
                                                       (lambda (this)
-                                                        (if (equal txt "") "" 
" ")
                                                         (format "%s" 
this))))))))
                                   (cmd (concat fn " " args)))
                              (filesets-cmd-show-result
diff --git a/lisp/gnus/gnus-cloud.el b/lisp/gnus/gnus-cloud.el
index cecfaef..4d8764b 100644
--- a/lisp/gnus/gnus-cloud.el
+++ b/lisp/gnus/gnus-cloud.el
@@ -243,10 +243,10 @@ Use old data if FORCE-OLDER is not nil."
                 (when (or (not gnus-cloud-interactive)
                           (gnus-y-or-n-p
                            (format "%s has older different info in the cloud 
as of %s, update it here? "
-                                   group date))))
-                (gnus-message 2 "Installing cloud update of group %s" group)
-                (gnus-set-info group contents)
-                (gnus-group-update-group group)))
+                                  group date)))
+                 (gnus-message 2 "Installing cloud update of group %s" group)
+                 (gnus-set-info group contents)
+                 (gnus-group-update-group group))))
           (gnus-error 1 "Sorry, group %s is not subscribed" group))
       (gnus-error 1 "Sorry, could not update newsrc for group %s (invalid data 
%S)"
                   group elem))))
diff --git a/lisp/gnus/mml-smime.el b/lisp/gnus/mml-smime.el
index 3cc463d5..4754f37 100644
--- a/lisp/gnus/mml-smime.el
+++ b/lisp/gnus/mml-smime.el
@@ -154,14 +154,9 @@ Whether the passphrase is cached at all is controlled by
          (write-region (point-min) (point-max) file))
        (push file certfiles)
        (push file tmpfiles)))
-    (if (smime-encrypt-buffer certfiles)
-       (progn
-         (while (setq tmp (pop tmpfiles))
-           (delete-file tmp))
-         t)
-      (while (setq tmp (pop tmpfiles))
-       (delete-file tmp))
-      nil))
+    (smime-encrypt-buffer certfiles)
+    (while (setq tmp (pop tmpfiles))
+      (delete-file tmp)))
   (goto-char (point-max)))
 
 (defvar gnus-extract-address-components)
diff --git a/lisp/international/titdic-cnv.el b/lisp/international/titdic-cnv.el
index 2a80d75..e95e399 100644
--- a/lisp/international/titdic-cnv.el
+++ b/lisp/international/titdic-cnv.el
@@ -737,8 +737,7 @@ To get complete usage, invoke \"emacs -batch -f 
batch-titdic-convert -h\"."
 ;; method is for inputting CNS characters.
 
 (defun tsang-quick-converter (dicbuf tsang-p big5-p)
-  (let ((fulltitle (if tsang-p (if big5-p "倉頡" "倉頡")
-                    (if big5-p "簡易" "簡易")))
+  (let ((fulltitle (if tsang-p "倉頡" "簡易"))
        dic)
     (goto-char (point-max))
     (if big5-p
diff --git a/lisp/mh-e/mh-show.el b/lisp/mh-e/mh-show.el
index 8871059..952579f 100644
--- a/lisp/mh-e/mh-show.el
+++ b/lisp/mh-e/mh-show.el
@@ -221,6 +221,8 @@ Sets the current buffer to the show buffer."
              ;; pgp.el uses this.
              (if (boundp 'write-contents-hooks) ;Emacs 19
                  (kill-local-variable 'write-contents-hooks))
+             (font-lock-mode -1)
+             (mh-show-mode)
              (if formfile
                  (mh-exec-lib-cmd-output "mhl" "-nobell" "-noclear"
                                          (if (stringp formfile)
@@ -232,7 +234,6 @@ Sets the current buffer to the show buffer."
                (mh-add-missing-mime-version-header)
                (setf (mh-buffer-data) (mh-make-buffer-data))
                (mh-mime-display))
-             (mh-show-mode)
              ;; Header cleanup
              (goto-char (point-min))
              (cond (clean-message-header
@@ -252,13 +253,11 @@ Sets the current buffer to the show buffer."
              (setq buffer-backed-up nil)
              (auto-save-mode 1)
              (set-mark nil)
-             (unwind-protect
-                 (when (and mh-decode-mime-flag (not formfile))
-                   (setq buffer-read-only nil)
-                   (mh-display-smileys)
-                   (mh-display-emphasis))
-               (setq buffer-read-only t))
+             (when (and mh-decode-mime-flag (not formfile))
+               (mh-display-smileys)
+               (mh-display-emphasis))
              (set-buffer-modified-p nil)
+             (setq buffer-read-only t)
              (setq mh-show-folder-buffer folder)
              (setq mode-line-buffer-identification
                    (list (format mh-show-buffer-mode-line-buffer-id
@@ -870,7 +869,6 @@ See also `mh-folder-mode'.
   (easy-menu-add mh-show-folder-menu)
   (make-local-variable 'mh-show-folder-buffer)
   (buffer-disable-undo)
-  (setq buffer-read-only t)
   (use-local-map mh-show-mode-map))
 
 
diff --git a/lisp/net/nsm.el b/lisp/net/nsm.el
index e94947b..1b0f04e 100644
--- a/lisp/net/nsm.el
+++ b/lisp/net/nsm.el
@@ -311,9 +311,9 @@ See also: `network-security-protocol-checks' and 
`nsm-noninteractive'"
                                                   (map-values results)
                                                   "\n")
                                                  "\n")
-                                                "\n* ")))))
-                 (delete-process process)
-                 (setq process nil)))
+                                               "\n* "))))))
+       (delete-process process)
+       (setq process nil))
       (run-hook-with-args 'nsm-tls-post-check-functions
                           host port status settings results)))
   process)
diff --git a/lisp/net/tramp-sudoedit.el b/lisp/net/tramp-sudoedit.el
index 18b30ad..08188ce 100644
--- a/lisp/net/tramp-sudoedit.el
+++ b/lisp/net/tramp-sudoedit.el
@@ -508,21 +508,21 @@ the result will be a local, non-Tramp, file name."
       (tramp-message v 5 "file system info: %s" localname)
       (when (tramp-sudoedit-send-command
             v "df" "--block-size=1" "--output=size,used,avail"
-            (tramp-compat-file-name-unquote localname)))
-      (with-current-buffer (tramp-get-connection-buffer v)
-       (goto-char (point-min))
-       (forward-line)
-       (when (looking-at
-              (eval-when-compile
-                (concat "[[:space:]]*\\([[:digit:]]+\\)"
-                        "[[:space:]]+\\([[:digit:]]+\\)"
-                        "[[:space:]]+\\([[:digit:]]+\\)")))
-         (list (string-to-number (match-string 1))
-               ;; The second value is the used size.  We need the
-               ;; free size.
-               (- (string-to-number (match-string 1))
-                  (string-to-number (match-string 2)))
-               (string-to-number (match-string 3))))))))
+            (tramp-compat-file-name-unquote localname))
+       (with-current-buffer (tramp-get-connection-buffer v)
+         (goto-char (point-min))
+         (forward-line)
+         (when (looking-at
+                (eval-when-compile
+                  (concat "[[:space:]]*\\([[:digit:]]+\\)"
+                          "[[:space:]]+\\([[:digit:]]+\\)"
+                          "[[:space:]]+\\([[:digit:]]+\\)")))
+           (list (string-to-number (match-string 1))
+                 ;; The second value is the used size.  We need the
+                 ;; free size.
+                 (- (string-to-number (match-string 1))
+                    (string-to-number (match-string 2)))
+                 (string-to-number (match-string 3)))))))))
 
 (defun tramp-sudoedit-handle-set-file-times (filename &optional time)
   "Like `set-file-times' for Tramp files."
diff --git a/lisp/org/org-agenda.el b/lisp/org/org-agenda.el
index ceaa816..5fe140d 100644
--- a/lisp/org/org-agenda.el
+++ b/lisp/org/org-agenda.el
@@ -8981,7 +8981,6 @@ fold drawers."
         (narrow-to-region (org-entry-beginning-position)
                           (org-entry-end-position))
         (org-show-all '(drawers))))
-      (when arg )
       (setq org-agenda-show-window (selected-window)))
     (select-window win)))
 
diff --git a/lisp/org/ox-odt.el b/lisp/org/ox-odt.el
index 51cb42a..a148631 100644
--- a/lisp/org/ox-odt.el
+++ b/lisp/org/ox-odt.el
@@ -940,7 +940,7 @@ See `org-odt--build-date-styles' for implementation 
details."
         (has-time-p (or (not timestamp)
                         (org-timestamp-has-time-p timestamp)))
         (iso-date (let ((format (if has-time-p "%Y-%m-%dT%H:%M:%S"
-                                  "%Y-%m-%dT%H:%M:%S")))
+                                  "%Y-%m-%d")))
                     (funcall format-timestamp timestamp format end))))
     (if iso-date-p iso-date
       (let* ((style (if has-time-p "OrgDate2" "OrgDate1"))
diff --git a/lisp/textmodes/table.el b/lisp/textmodes/table.el
index 4482e7d..a33e926 100644
--- a/lisp/textmodes/table.el
+++ b/lisp/textmodes/table.el
@@ -3206,11 +3206,7 @@ CALS (DocBook DTD):
          (while (and (re-search-forward "$" nil t)
                      (not (eobp)))
            (insert "<br />")
-           (forward-char 1)))
-       (unless (and table-html-delegate-spacing-to-user-agent
-                    (progn
-                      (goto-char (point-min))
-                      (looking-at "\\s *\\'")))))
+           (forward-char 1))))
        ((eq language 'cals)
        (table--remove-eol-spaces (point-min) (point-max))
        (if (re-search-forward "\\s +\\'" nil t)
diff --git a/lisp/window.el b/lisp/window.el
index 4334863..40c4bf5 100644
--- a/lisp/window.el
+++ b/lisp/window.el
@@ -4970,9 +4970,11 @@ WINDOW must be a live window and defaults to the 
selected one.
 
 According to information stored in WINDOW's `quit-restore' window
 parameter either (1) delete WINDOW and its frame, (2) delete
-WINDOW, (3) restore the buffer previously displayed in WINDOW,
-or (4) make WINDOW display some other buffer than the present
-one.  If non-nil, reset `quit-restore' parameter to nil.
+WINDOW but leave its frame alone, (3) restore the buffer
+previously shown in WINDOW, or (4) make WINDOW display some other
+buffer.  If WINDOW is not deleted, reset its `quit-restore'
+parameter to nil.  See Info node `(elisp) Quitting Windows' for
+more details.
 
 Optional second argument BURY-OR-KILL tells how to proceed with
 the buffer of WINDOW.  The following values are handled:
@@ -5083,11 +5085,9 @@ 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
-WINDOW, (3) restore the buffer previously displayed in WINDOW,
-or (4) make WINDOW display some other buffer than the present
-one.  If non-nil, reset `quit-restore' parameter to nil.
+This calls the function `quit-restore-window' to delete WINDOW or
+show some other buffer in it.  See Info node `(elisp) Quitting
+Windows' for more details.
 
 The functions in `quit-window-hook' will be run before doing
 anything else."
diff --git a/src/xdisp.c b/src/xdisp.c
index 723309a..cc936ff 100644
--- a/src/xdisp.c
+++ b/src/xdisp.c
@@ -1136,16 +1136,17 @@ window_box_height (struct window *w)
     {
       if (w->header_line_height >= 0)
        height -= w->header_line_height;
-      {
-       struct glyph_row *hl_row
-         = (w->current_matrix && w->current_matrix->rows
-            ? MATRIX_HEADER_LINE_ROW (w->current_matrix)
-            : 0);
-       if (hl_row && hl_row->mode_line_p)
-         height -= hl_row->height;
-       else
-         height -= estimate_mode_line_height (f, HEADER_LINE_FACE_ID);
-      }
+      else
+       {
+         struct glyph_row *hl_row
+           = (w->current_matrix && w->current_matrix->rows
+              ? MATRIX_HEADER_LINE_ROW (w->current_matrix)
+              : 0);
+         if (hl_row && hl_row->mode_line_p)
+           height -= hl_row->height;
+         else
+           height -= estimate_mode_line_height (f, HEADER_LINE_FACE_ID);
+       }
     }
 
   /* With a very small font and a mode-line that's taller than



reply via email to

[Prev in Thread] Current Thread [Next in Thread]