aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul Eggert2017-12-02 21:38:05 -0800
committerPaul Eggert2017-12-02 21:38:05 -0800
commitf1204e1dda84a65d7906949247076c6ba4d4ba40 (patch)
tree634603e56c040597c1f11fbe39fda9d6a4ba14a4
parentbc092fcaea7268f2339f0e92720a37e62cdca5b2 (diff)
parent8c8b6732882248df4ca3b687e0a4b4e5e4ab3777 (diff)
downloademacs-f1204e1dda84a65d7906949247076c6ba4d4ba40.tar.gz
emacs-f1204e1dda84a65d7906949247076c6ba4d4ba40.zip
Merge from origin/emacs-26
8c8b673288 Fix backing up remote files in local directories on MS-Win... 8eb6870be6 Fix vertical cursor motion in pixel-scroll.el 625e84f156 Fix typos in doc strings of message.el 9292276a44 Fix a typo in the Emacs manual 42509c0649 Improve the documentation of 'table-insert-sequence' 93dc7ae4a4 Port better to QNX ad99550610 Make tramp-test42-auto-load more robust af0ce33d08 ; * lisp/composite.el (find-composition): Fix a typo in la... bdbcdbac43 Avoid assertions in find-composition
-rw-r--r--configure.ac4
-rw-r--r--doc/emacs/abbrevs.texi4
-rw-r--r--doc/emacs/text.texi11
-rw-r--r--lisp/composite.el5
-rw-r--r--lisp/files.el54
-rw-r--r--lisp/gnus/message.el8
-rw-r--r--lisp/pixel-scroll.el20
-rw-r--r--src/font.c23
-rw-r--r--test/lisp/net/tramp-tests.el6
9 files changed, 82 insertions, 53 deletions
diff --git a/configure.ac b/configure.ac
index 469ad00eaaa..b773e3b7f0c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -702,7 +702,9 @@ case "${canonical}" in
702 ## QNX Neutrino 702 ## QNX Neutrino
703 *-nto-qnx* ) 703 *-nto-qnx* )
704 opsys=qnxnto 704 opsys=qnxnto
705 test -z "$CC" && CC=qcc
705 CFLAGS="$CFLAGS -D__NO_EXT_QNX" 706 CFLAGS="$CFLAGS -D__NO_EXT_QNX"
707 LDFLAGS="-N2MB $LDFLAGS"
706 ;; 708 ;;
707 709
708 ## Intel 386 machines where we don't care about the manufacturer. 710 ## Intel 386 machines where we don't care about the manufacturer.
@@ -2218,7 +2220,7 @@ test "$CANNOT_DUMP" = yes ||
2218case "$opsys" in 2220case "$opsys" in
2219 ## darwin ld insists on the use of malloc routines in the System framework. 2221 ## darwin ld insists on the use of malloc routines in the System framework.
2220 darwin | mingw32 | nacl | sol2-10) ;; 2222 darwin | mingw32 | nacl | sol2-10) ;;
2221 cygwin | qnxto | freebsd) 2223 cygwin | qnxnto | freebsd)
2222 hybrid_malloc=yes 2224 hybrid_malloc=yes
2223 system_malloc= ;; 2225 system_malloc= ;;
2224 *) test "$ac_cv_func_sbrk" = yes && system_malloc=$emacs_cv_sanitize_address;; 2226 *) test "$ac_cv_func_sbrk" = yes && system_malloc=$emacs_cv_sanitize_address;;
diff --git a/doc/emacs/abbrevs.texi b/doc/emacs/abbrevs.texi
index 117d07e2814..5f400a2399a 100644
--- a/doc/emacs/abbrevs.texi
+++ b/doc/emacs/abbrevs.texi
@@ -62,8 +62,8 @@ definition for the current major mode overrides a global definition.
62 62
63 You can define abbrevs interactively during the editing session, 63 You can define abbrevs interactively during the editing session,
64irrespective of whether Abbrev mode is enabled. You can also save 64irrespective of whether Abbrev mode is enabled. You can also save
65lists of abbrev definitions in files, which you can the reload for use 65lists of abbrev definitions in files, which you can then reload for
66in later sessions. 66use in later sessions.
67 67
68@node Defining Abbrevs 68@node Defining Abbrevs
69@section Defining Abbrevs 69@section Defining Abbrevs
diff --git a/doc/emacs/text.texi b/doc/emacs/text.texi
index c5967f8cf65..7aa859d1772 100644
--- a/doc/emacs/text.texi
+++ b/doc/emacs/text.texi
@@ -2814,9 +2814,14 @@ high, the table is 67 characters wide and 16 lines high with 2 columns
2814and 3 rows, and a total of 5 cells. 2814and 3 rows, and a total of 5 cells.
2815 2815
2816@findex table-insert-sequence 2816@findex table-insert-sequence
2817 @kbd{M-x table-insert-sequence} inserts a string into each cell. 2817 @kbd{M-x table-insert-sequence} traverses the cells of a table
2818Each string is a part of a sequence i.e., a series of increasing 2818inserting a sequence of text strings into each cell as it goes. It
2819integer numbers. 2819asks for the base string of the sequence, and then produces the
2820sequence by ``incrementing'' the base string, either numerically (if
2821the base string ends in numerical characters) or in the
2822@acronym{ASCII} order. In addition to the base string, the command
2823prompts for the number of elements in the sequence, the increment, the
2824cell interval, and the justification of the text in each cell.
2820 2825
2821@cindex table for HTML and LaTeX 2826@cindex table for HTML and LaTeX
2822@findex table-generate-source 2827@findex table-generate-source
diff --git a/lisp/composite.el b/lisp/composite.el
index 72b0ffc8f48..7293d7c15cd 100644
--- a/lisp/composite.el
+++ b/lisp/composite.el
@@ -337,8 +337,9 @@ When Automatic Composition mode is on, this function also finds a
337chunk of text that is automatically composed. If such a chunk is 337chunk of text that is automatically composed. If such a chunk is
338found closer to POS than the position that has `composition' 338found closer to POS than the position that has `composition'
339property, the value is a list of FROM, TO, and a glyph-string 339property, the value is a list of FROM, TO, and a glyph-string
340that specifies how the chunk is to be composed. See the function 340that specifies how the chunk is to be composed; DETAIL-P is
341`composition-get-gstring' for the format of the glyph-string." 341inored in this case. See the function `composition-get-gstring'
342for the format of the glyph-string."
342 (let ((result (find-composition-internal pos limit string detail-p))) 343 (let ((result (find-composition-internal pos limit string detail-p)))
343 (if (and detail-p (> (length result) 3) (nth 2 result) (not (nth 3 result))) 344 (if (and detail-p (> (length result) 3) (nth 2 result) (not (nth 3 result)))
344 ;; This is a valid rule-base composition. 345 ;; This is a valid rule-base composition.
diff --git a/lisp/files.el b/lisp/files.el
index 25746094d2a..a5a268195f5 100644
--- a/lisp/files.el
+++ b/lisp/files.el
@@ -4653,25 +4653,41 @@ The function `find-backup-file-name' also uses this."
4653 ;; "/drive_x". 4653 ;; "/drive_x".
4654 (or (file-name-absolute-p file) 4654 (or (file-name-absolute-p file)
4655 (setq file (expand-file-name file))) ; make defaults explicit 4655 (setq file (expand-file-name file))) ; make defaults explicit
4656 ;; Replace any invalid file-name characters (for the 4656 (cond
4657 ;; case of backing up remote files). 4657 ((file-remote-p file)
4658 (setq file (expand-file-name (convert-standard-filename file))) 4658 ;; Remove the leading slash, if any, to prevent
4659 (if (eq (aref file 1) ?:) 4659 ;; expand-file-name from adding a drive letter.
4660 (setq file (concat "/" 4660 (and (memq (aref file 0) '(?/ ?\\))
4661 "drive_" 4661 (setq file (substring file 1)))
4662 (char-to-string (downcase (aref file 0))) 4662 ;; Replace any invalid file-name characters.
4663 (if (eq (aref file 2) ?/) 4663 (setq file (convert-standard-filename file))
4664 "" 4664 ;; Replace slashes to make the file name unique, and
4665 "/") 4665 ;; prepend backup-directory.
4666 (substring file 2))))) 4666 (expand-file-name
4667 ;; Make the name unique by substituting directory 4667 (subst-char-in-string
4668 ;; separators. It may not really be worth bothering about 4668 ?/ ?!
4669 ;; doubling `!'s in the original name... 4669 (replace-regexp-in-string "!" "!!"
4670 (expand-file-name 4670 (concat "/" file)))
4671 (subst-char-in-string 4671 backup-directory))
4672 ?/ ?! 4672 (t
4673 (replace-regexp-in-string "!" "!!" file)) 4673 ;; Replace any invalid file-name characters.
4674 backup-directory)) 4674 (setq file (expand-file-name (convert-standard-filename file)))
4675 (if (eq (aref file 1) ?:)
4676 (setq file (concat "/"
4677 "drive_"
4678 (char-to-string (downcase (aref file 0)))
4679 (if (eq (aref file 2) ?/)
4680 ""
4681 "/")
4682 (substring file 2))))
4683 ;; Make the name unique by substituting directory
4684 ;; separators. It may not really be worth bothering about
4685 ;; doubling `!'s in the original name...
4686 (expand-file-name
4687 (subst-char-in-string
4688 ?/ ?!
4689 (replace-regexp-in-string "!" "!!" file))
4690 backup-directory)))))
4675 (expand-file-name (file-name-nondirectory file) 4691 (expand-file-name (file-name-nondirectory file)
4676 (file-name-as-directory abs-backup-directory)))))) 4692 (file-name-as-directory abs-backup-directory))))))
4677 4693
diff --git a/lisp/gnus/message.el b/lisp/gnus/message.el
index 8e3d299ee80..0f99cb697dc 100644
--- a/lisp/gnus/message.el
+++ b/lisp/gnus/message.el
@@ -1433,7 +1433,7 @@ starting with `not' and followed by regexps."
1433 (:foreground "MidnightBlue" :bold t)) 1433 (:foreground "MidnightBlue" :bold t))
1434 (t 1434 (t
1435 (:bold t :italic t))) 1435 (:bold t :italic t)))
1436 "Face used for displaying From headers." 1436 "Face used for displaying To headers."
1437 :group 'message-faces) 1437 :group 'message-faces)
1438;; backward-compatibility alias 1438;; backward-compatibility alias
1439(put 'message-header-to-face 'face-alias 'message-header-to) 1439(put 'message-header-to-face 'face-alias 'message-header-to)
@@ -1463,7 +1463,7 @@ starting with `not' and followed by regexps."
1463 (:foreground "navy blue" :bold t)) 1463 (:foreground "navy blue" :bold t))
1464 (t 1464 (t
1465 (:bold t))) 1465 (:bold t)))
1466 "Face used for displaying subject headers." 1466 "Face used for displaying Subject headers."
1467 :group 'message-faces) 1467 :group 'message-faces)
1468;; backward-compatibility alias 1468;; backward-compatibility alias
1469(put 'message-header-subject-face 'face-alias 'message-header-subject) 1469(put 'message-header-subject-face 'face-alias 'message-header-subject)
@@ -1478,7 +1478,7 @@ starting with `not' and followed by regexps."
1478 (:foreground "blue4" :bold t :italic t)) 1478 (:foreground "blue4" :bold t :italic t))
1479 (t 1479 (t
1480 (:bold t :italic t))) 1480 (:bold t :italic t)))
1481 "Face used for displaying newsgroups headers." 1481 "Face used for displaying Newsgroups headers."
1482 :group 'message-faces) 1482 :group 'message-faces)
1483;; backward-compatibility alias 1483;; backward-compatibility alias
1484(put 'message-header-newsgroups-face 'face-alias 'message-header-newsgroups) 1484(put 'message-header-newsgroups-face 'face-alias 'message-header-newsgroups)
@@ -1493,7 +1493,7 @@ starting with `not' and followed by regexps."
1493 (:foreground "steel blue")) 1493 (:foreground "steel blue"))
1494 (t 1494 (t
1495 (:bold t :italic t))) 1495 (:bold t :italic t)))
1496 "Face used for displaying newsgroups headers." 1496 "Face used for displaying other headers."
1497 :group 'message-faces) 1497 :group 'message-faces)
1498;; backward-compatibility alias 1498;; backward-compatibility alias
1499(put 'message-header-other-face 'face-alias 'message-header-other) 1499(put 'message-header-other-face 'face-alias 'message-header-other)
diff --git a/lisp/pixel-scroll.el b/lisp/pixel-scroll.el
index 9bfe5c91f57..f64a4392b49 100644
--- a/lisp/pixel-scroll.el
+++ b/lisp/pixel-scroll.el
@@ -110,11 +110,11 @@ This is an alternative of `scroll-up'. Scope moves downward."
110 pixel-resolution-fine-flag 110 pixel-resolution-fine-flag
111 (frame-char-height)) 111 (frame-char-height))
112 (pixel-line-height)))) 112 (pixel-line-height))))
113 (if (pixel-eob-at-top-p) ; when end-of-the-buffer is close 113 (while (pixel-point-at-top-p amt) ; prevent too late (multi tries)
114 (scroll-up 1) ; relay on robust method 114 (vertical-motion 1)) ; move point downward
115 (while (pixel-point-at-top-p amt) ; prevent too late (multi tries) 115 (if (pixel-eob-at-top-p) ; when end-of-the-buffer is close
116 (vertical-motion 1)) ; move point downward 116 (scroll-up 1) ; relay on robust method
117 (pixel-scroll-pixel-up amt))))) ; move scope downward 117 (pixel-scroll-pixel-up amt))))) ; move scope downward
118 118
119(defun pixel-scroll-down (&optional arg) 119(defun pixel-scroll-down (&optional arg)
120 "Scroll text of selected window down ARG lines. 120 "Scroll text of selected window down ARG lines.
@@ -127,11 +127,11 @@ This is and alternative of `scroll-down'. Scope moves upward."
127 pixel-resolution-fine-flag 127 pixel-resolution-fine-flag
128 (frame-char-height)) 128 (frame-char-height))
129 (pixel-line-height -1)))) 129 (pixel-line-height -1))))
130 (if (or (pixel-bob-at-top-p amt) ; when beginning-of-the-buffer is seen 130 (while (pixel-point-at-bottom-p amt) ; prevent too late (multi tries)
131 (pixel-eob-at-top-p)) ; for file with a long line 131 (vertical-motion -1)) ; move point upward
132 (scroll-down 1) ; relay on robust method 132 (if (or (pixel-bob-at-top-p amt) ; when beginning-of-the-buffer is seen
133 (while (pixel-point-at-bottom-p amt) ; prevent too late (multi tries) 133 (pixel-eob-at-top-p)) ; for file with a long line
134 (vertical-motion -1)) 134 (scroll-down 1) ; relay on robust method
135 (pixel-scroll-pixel-down amt))))) 135 (pixel-scroll-pixel-down amt)))))
136 136
137(defun pixel-bob-at-top-p (amt) 137(defun pixel-bob-at-top-p (amt)
diff --git a/src/font.c b/src/font.c
index f7cebdce78c..441652b0951 100644
--- a/src/font.c
+++ b/src/font.c
@@ -3794,19 +3794,26 @@ font_range (ptrdiff_t pos, ptrdiff_t pos_byte, ptrdiff_t *limit,
3794 int c; 3794 int c;
3795 Lisp_Object font_object = Qnil; 3795 Lisp_Object font_object = Qnil;
3796 3796
3797 if (NILP (string)) 3797 if (!face)
3798 { 3798 {
3799 if (! face) 3799 struct frame *f = XFRAME (w->frame);
3800 int face_id;
3801
3802 if (NILP (string))
3803 face_id = face_at_buffer_position (w, pos, &ignore, *limit,
3804 false, -1);
3805 else
3800 { 3806 {
3801 int face_id; 3807 face_id =
3808 NILP (Vface_remapping_alist)
3809 ? DEFAULT_FACE_ID
3810 : lookup_basic_face (f, DEFAULT_FACE_ID);
3802 3811
3803 face_id = face_at_buffer_position (w, pos, &ignore, 3812 face_id = face_at_string_position (w, string, pos, 0, &ignore,
3804 *limit, false, -1); 3813 face_id, false);
3805 face = FACE_FROM_ID (XFRAME (w->frame), face_id);
3806 } 3814 }
3815 face = FACE_FROM_ID (f, face_id);
3807 } 3816 }
3808 else
3809 eassert (face);
3810 3817
3811 while (pos < *limit) 3818 while (pos < *limit)
3812 { 3819 {
diff --git a/test/lisp/net/tramp-tests.el b/test/lisp/net/tramp-tests.el
index 044ab9329ff..5699ab4b237 100644
--- a/test/lisp/net/tramp-tests.el
+++ b/test/lisp/net/tramp-tests.el
@@ -4624,15 +4624,13 @@ process sentinels. They shall not disturb each other."
4624 (ignore-errors (cancel-timer timer)) 4624 (ignore-errors (cancel-timer timer))
4625 (ignore-errors (delete-directory tmp-name 'recursive))))))) 4625 (ignore-errors (delete-directory tmp-name 'recursive)))))))
4626 4626
4627;; This test is inspired by Bug#29163.
4627(ert-deftest tramp-test42-auto-load () 4628(ert-deftest tramp-test42-auto-load ()
4628 "Check that Tramp autoloads properly." 4629 "Check that Tramp autoloads properly."
4629 (skip-unless (tramp--test-enabled))
4630 (skip-unless (not (tramp--test-mock-p)))
4631
4632 (let ((default-directory (expand-file-name temporary-file-directory)) 4630 (let ((default-directory (expand-file-name temporary-file-directory))
4633 (code 4631 (code
4634 (format 4632 (format
4635 "(message \"Tramp loaded: %%s\" (consp (file-attributes %S)))" 4633 "(message \"Tramp loaded: %%s\" (and (file-remote-p %S) t))"
4636 tramp-test-temporary-file-directory))) 4634 tramp-test-temporary-file-directory)))
4637 (should 4635 (should
4638 (string-match 4636 (string-match