diff options
| author | Paul Eggert | 2016-04-18 14:05:31 -0700 |
|---|---|---|
| committer | Paul Eggert | 2016-04-18 14:05:31 -0700 |
| commit | 0808f2a1a331fbcb2e6ab57894502b0a34311869 (patch) | |
| tree | 72386004f3d60a5fdbaf1176edeb38ba4083677e | |
| parent | 3aa73b04e81ebc396892b14e5e9fa78a13ff85d1 (diff) | |
| parent | ac00a92e3df7111c0eb2c6456ae7df5850bfd8fa (diff) | |
| download | emacs-0808f2a1a331fbcb2e6ab57894502b0a34311869.tar.gz emacs-0808f2a1a331fbcb2e6ab57894502b0a34311869.zip | |
Merge from origin/emacs-25
ac00a92 Make sh-electric-here-document-mode accessible in sh-mode-hoo...
3287f48 ; Add entry to MAINTAINERS
b85981f * configure.ac (HAVE_MODULES): Exclude gnu-kfreebsd from prev...
0f33284 Make use of rectangle-preview custom variable.
aa0d83a Make use of rectangle-preview face.
33bef6e Use 'grep-find-program' in check-declare.el
a8560e5 Improve "C-h S" for cl-lib symbols
52e798b Fix minor issues with removing left or right fringes
d6ffd64 Speed up redisplay in ansi-term mode
4ab671c Simplify 8-bit character handling by terminal for 'raw-text'
f3653ec * configure.ac (HAVE_MODULES): Treat gnu like gnu-linux. (Bu...
ab849b7 Fix w32 memory-management problem when extending buffer text
| -rw-r--r-- | admin/MAINTAINERS | 1 | ||||
| -rw-r--r-- | configure.ac | 38 | ||||
| -rw-r--r-- | doc/emacs/display.texi | 17 | ||||
| -rw-r--r-- | doc/lispref/windows.texi | 6 | ||||
| -rw-r--r-- | lisp/emacs-lisp/check-declare.el | 2 | ||||
| -rw-r--r-- | lisp/info-look.el | 4 | ||||
| -rw-r--r-- | lisp/international/mule.el | 65 | ||||
| -rw-r--r-- | lisp/progmodes/sh-script.el | 7 | ||||
| -rw-r--r-- | lisp/rect.el | 77 | ||||
| -rw-r--r-- | lisp/term.el | 12 | ||||
| -rw-r--r-- | lisp/window.el | 14 | ||||
| -rw-r--r-- | lisp/xt-mouse.el | 5 | ||||
| -rw-r--r-- | src/w32heap.c | 8 |
13 files changed, 148 insertions, 108 deletions
diff --git a/admin/MAINTAINERS b/admin/MAINTAINERS index 0fe30f01f6a..f8baddd5316 100644 --- a/admin/MAINTAINERS +++ b/admin/MAINTAINERS | |||
| @@ -73,6 +73,7 @@ Michael Albinus | |||
| 73 | 73 | ||
| 74 | File Notifications | 74 | File Notifications |
| 75 | src/gfilenotify.c | 75 | src/gfilenotify.c |
| 76 | src/kqueue.c | ||
| 76 | lisp/filenotify.el | 77 | lisp/filenotify.el |
| 77 | test/lisp/filenotify-tests.el | 78 | test/lisp/filenotify-tests.el |
| 78 | 79 | ||
diff --git a/configure.ac b/configure.ac index 0f6f6502452..eec6ce769cd 100644 --- a/configure.ac +++ b/configure.ac | |||
| @@ -3374,24 +3374,26 @@ HAVE_MODULES=no | |||
| 3374 | MODULES_OBJ= | 3374 | MODULES_OBJ= |
| 3375 | MODULES_SUFFIX= | 3375 | MODULES_SUFFIX= |
| 3376 | if test "${with_modules}" != "no"; then | 3376 | if test "${with_modules}" != "no"; then |
| 3377 | if test "$opsys" = "gnu-linux"; then | 3377 | case $opsys in |
| 3378 | LIBMODULES="-ldl" | 3378 | gnu|gnu-linux) |
| 3379 | MODULES_SUFFIX=".so" | 3379 | LIBMODULES="-ldl" |
| 3380 | HAVE_MODULES=yes | 3380 | MODULES_SUFFIX=".so" |
| 3381 | elif test "$opsys" = "cygwin"; then | 3381 | HAVE_MODULES=yes |
| 3382 | MODULES_SUFFIX=".dll" | 3382 | ;; |
| 3383 | HAVE_MODULES=yes | 3383 | cygwin|mingw32) |
| 3384 | elif test "$opsys" = "darwin"; then | 3384 | MODULES_SUFFIX=".dll" |
| 3385 | MODULES_SUFFIX=".so" | 3385 | HAVE_MODULES=yes |
| 3386 | HAVE_MODULES=yes | 3386 | ;; |
| 3387 | elif test "$opsys" = "mingw32"; then | 3387 | darwin) |
| 3388 | MODULES_SUFFIX=".dll" | 3388 | MODULES_SUFFIX=".so" |
| 3389 | HAVE_MODULES=yes | 3389 | HAVE_MODULES=yes |
| 3390 | else | 3390 | ;; |
| 3391 | # BSD system have dlopen in the libc | 3391 | *) |
| 3392 | AC_CHECK_FUNC(dlopen, [MODULES_SUFFIX=".so"] | 3392 | # BSD system have dlopen in the libc |
| 3393 | [HAVE_MODULES=yes], []) | 3393 | AC_CHECK_FUNC(dlopen, [MODULES_SUFFIX=".so"] |
| 3394 | fi | 3394 | [HAVE_MODULES=yes], []) |
| 3395 | ;; | ||
| 3396 | esac | ||
| 3395 | 3397 | ||
| 3396 | if test "${HAVE_MODULES}" = no; then | 3398 | if test "${HAVE_MODULES}" = no; then |
| 3397 | AC_MSG_ERROR([Dynamic modules are not supported on your system]) | 3399 | AC_MSG_ERROR([Dynamic modules are not supported on your system]) |
diff --git a/doc/emacs/display.texi b/doc/emacs/display.texi index 01f899f1c09..8039291298c 100644 --- a/doc/emacs/display.texi +++ b/doc/emacs/display.texi | |||
| @@ -1087,6 +1087,23 @@ To disable this, change the variable | |||
| 1087 | @code{overflow-newline-into-fringe} to @code{nil}; this causes Emacs | 1087 | @code{overflow-newline-into-fringe} to @code{nil}; this causes Emacs |
| 1088 | to continue or truncate lines that are exactly as wide as the window. | 1088 | to continue or truncate lines that are exactly as wide as the window. |
| 1089 | 1089 | ||
| 1090 | If you customize @code{fringe-mode} to remove the fringes on one or | ||
| 1091 | both sides of the window display, the features that display on the | ||
| 1092 | fringe are not available. Indicators of line continuation and | ||
| 1093 | truncation are an exception: when fringes are not available, Emacs | ||
| 1094 | uses the leftmost and rightmost character cells to indicate | ||
| 1095 | continuation and truncation with special ASCII characters, see | ||
| 1096 | @ref{Continuation Lines}, and @ref{Line Truncation}. This reduces the | ||
| 1097 | width available for displaying text on each line, because the | ||
| 1098 | character cells used for truncation and continuation indicators are | ||
| 1099 | reserved for that purpose. Since buffer text can include | ||
| 1100 | bidirectional text, and thus both left-to-right and right-to-left | ||
| 1101 | paragraphs (@pxref{Bidirectional Editing}), removing only one of the | ||
| 1102 | fringes still reserves two character cells, one on each side of the | ||
| 1103 | window, for truncation and continuation indicators, because these | ||
| 1104 | indicators are displayed on opposite sides of the window in | ||
| 1105 | right-to-left paragraphs. | ||
| 1106 | |||
| 1090 | @node Displaying Boundaries | 1107 | @node Displaying Boundaries |
| 1091 | @section Displaying Boundaries | 1108 | @section Displaying Boundaries |
| 1092 | 1109 | ||
diff --git a/doc/lispref/windows.texi b/doc/lispref/windows.texi index bb13934fb3a..74837ac82b9 100644 --- a/doc/lispref/windows.texi +++ b/doc/lispref/windows.texi | |||
| @@ -617,6 +617,12 @@ exceed its total height as returned by @code{window-total-height}. | |||
| 617 | @cindex body width of a window | 617 | @cindex body width of a window |
| 618 | The @dfn{body width} of a window is the width of its text area, which | 618 | The @dfn{body width} of a window is the width of its text area, which |
| 619 | does not include the scroll bar, fringes, margins or a right divider. | 619 | does not include the scroll bar, fringes, margins or a right divider. |
| 620 | Note that when one or both fringes are removed (by setting their width | ||
| 621 | to zero), the display engine reserves two character cells, one on each | ||
| 622 | side of the window, for displaying the continuation and truncation | ||
| 623 | glyphs, which leaves 2 columns less for text display. (The function | ||
| 624 | @code{window-max-chars-per-line}, described below, takes this | ||
| 625 | peculiarity into account.) | ||
| 620 | 626 | ||
| 621 | @defun window-body-width &optional window pixelwise | 627 | @defun window-body-width &optional window pixelwise |
| 622 | This function returns the width, in columns, of the body of window | 628 | This function returns the width, in columns, of the body of window |
diff --git a/lisp/emacs-lisp/check-declare.el b/lisp/emacs-lisp/check-declare.el index b6fa0546088..b8a00b3fb4e 100644 --- a/lisp/emacs-lisp/check-declare.el +++ b/lisp/emacs-lisp/check-declare.el | |||
| @@ -339,7 +339,7 @@ Returns non-nil if any false statements are found." | |||
| 339 | errlist files) | 339 | errlist files) |
| 340 | (message "%s" m) | 340 | (message "%s" m) |
| 341 | (message "%s" m2) | 341 | (message "%s" m2) |
| 342 | (setq files (process-lines find-program root | 342 | (setq files (process-lines grep-find-program root |
| 343 | "-name" "*.el" | 343 | "-name" "*.el" |
| 344 | "-exec" grep-program | 344 | "-exec" grep-program |
| 345 | "-l" "^[ \t]*(declare-function" "{}" ";")) | 345 | "-l" "^[ \t]*(declare-function" "{}" ";")) |
diff --git a/lisp/info-look.el b/lisp/info-look.el index 70d2756dfc7..899f41e850d 100644 --- a/lisp/info-look.el +++ b/lisp/info-look.el | |||
| @@ -912,7 +912,9 @@ Return nil if there is nothing appropriate in the buffer near point." | |||
| 912 | ;; for things that should go to Function: etc, and those latter | 912 | ;; for things that should go to Function: etc, and those latter |
| 913 | ;; are much more important. Perhaps this could change if some | 913 | ;; are much more important. Perhaps this could change if some |
| 914 | ;; sort of fallback match scheme existed. | 914 | ;; sort of fallback match scheme existed. |
| 915 | ("(elisp)Index" nil "^ -+ .*: " "\\( \\|$\\)"))) | 915 | ("(elisp)Index" nil "^ -+ .*: " "\\( \\|$\\)") |
| 916 | ("(cl)Function Index" nil "^ -+ .*: " "\\( \\|$\\)") | ||
| 917 | ("(cl)Variable Index" nil "^ -+ .*: " "\\( \\|$\\)"))) | ||
| 916 | 918 | ||
| 917 | ;; docstrings talk about elisp, so have apropos-mode follow emacs-lisp-mode | 919 | ;; docstrings talk about elisp, so have apropos-mode follow emacs-lisp-mode |
| 918 | (info-lookup-maybe-add-help | 920 | (info-lookup-maybe-add-help |
diff --git a/lisp/international/mule.el b/lisp/international/mule.el index 60a90ae15a4..21ab7e176d7 100644 --- a/lisp/international/mule.el +++ b/lisp/international/mule.el | |||
| @@ -1445,42 +1445,35 @@ graphical terminals." | |||
| 1445 | (let ((coding-type (coding-system-type coding-system)) | 1445 | (let ((coding-type (coding-system-type coding-system)) |
| 1446 | (saved-meta-mode | 1446 | (saved-meta-mode |
| 1447 | (terminal-parameter terminal 'keyboard-coding-saved-meta-mode))) | 1447 | (terminal-parameter terminal 'keyboard-coding-saved-meta-mode))) |
| 1448 | (if (not (eq coding-type 'raw-text)) | 1448 | (let (accept-8-bit) |
| 1449 | (let (accept-8-bit) | 1449 | (if (not (or (coding-system-get coding-system :suitable-for-keyboard) |
| 1450 | (if (not (or (coding-system-get coding-system :suitable-for-keyboard) | 1450 | (coding-system-get coding-system :ascii-compatible-p))) |
| 1451 | (coding-system-get coding-system :ascii-compatible-p))) | 1451 | (error "Unsuitable coding system for keyboard: %s" coding-system)) |
| 1452 | (error "Unsuitable coding system for keyboard: %s" coding-system)) | 1452 | (cond ((memq coding-type '(raw-text charset utf-8 shift-jis big5 ccl)) |
| 1453 | (cond ((memq coding-type '(charset utf-8 shift-jis big5 ccl)) | 1453 | (setq accept-8-bit t)) |
| 1454 | (setq accept-8-bit t)) | 1454 | ((eq coding-type 'iso-2022) |
| 1455 | ((eq coding-type 'iso-2022) | 1455 | (let ((flags (coding-system-get coding-system :flags))) |
| 1456 | (let ((flags (coding-system-get coding-system :flags))) | 1456 | (or (memq '7-bit flags) |
| 1457 | (or (memq '7-bit flags) | 1457 | (setq accept-8-bit t)))) |
| 1458 | (setq accept-8-bit t)))) | 1458 | (t |
| 1459 | (t | 1459 | (error "Unsupported coding system for keyboard: %s" |
| 1460 | (error "Unsupported coding system for keyboard: %s" | 1460 | coding-system))) |
| 1461 | coding-system))) | 1461 | (if accept-8-bit |
| 1462 | (if accept-8-bit | 1462 | (progn |
| 1463 | (progn | 1463 | (or saved-meta-mode |
| 1464 | (or saved-meta-mode | 1464 | (set-terminal-parameter terminal |
| 1465 | (set-terminal-parameter terminal | 1465 | 'keyboard-coding-saved-meta-mode |
| 1466 | 'keyboard-coding-saved-meta-mode | 1466 | (cons (nth 2 (current-input-mode)) |
| 1467 | (cons (nth 2 (current-input-mode)) | 1467 | nil))) |
| 1468 | nil))) | 1468 | (set-input-meta-mode 8 terminal)) |
| 1469 | (set-input-meta-mode 8 terminal)) | 1469 | (when saved-meta-mode |
| 1470 | (when saved-meta-mode | 1470 | (set-input-meta-mode (car saved-meta-mode) terminal) |
| 1471 | (set-input-meta-mode (car saved-meta-mode) terminal) | 1471 | (set-terminal-parameter terminal |
| 1472 | (set-terminal-parameter terminal | 1472 | 'keyboard-coding-saved-meta-mode |
| 1473 | 'keyboard-coding-saved-meta-mode | 1473 | nil))) |
| 1474 | nil))) | 1474 | ;; Avoid end-of-line conversion. |
| 1475 | ;; Avoid end-of-line conversion. | 1475 | (setq coding-system |
| 1476 | (setq coding-system | 1476 | (coding-system-change-eol-conversion coding-system 'unix)))) |
| 1477 | (coding-system-change-eol-conversion coding-system 'unix))) | ||
| 1478 | |||
| 1479 | (when saved-meta-mode | ||
| 1480 | (set-input-meta-mode (car saved-meta-mode) terminal) | ||
| 1481 | (set-terminal-parameter terminal | ||
| 1482 | 'keyboard-coding-saved-meta-mode | ||
| 1483 | nil)))) | ||
| 1484 | (set-keyboard-coding-system-internal coding-system terminal) | 1477 | (set-keyboard-coding-system-internal coding-system terminal) |
| 1485 | (setq keyboard-coding-system coding-system)) | 1478 | (setq keyboard-coding-system coding-system)) |
| 1486 | 1479 | ||
diff --git a/lisp/progmodes/sh-script.el b/lisp/progmodes/sh-script.el index 2b61bc2e752..4fe47f026b6 100644 --- a/lisp/progmodes/sh-script.el +++ b/lisp/progmodes/sh-script.el | |||
| @@ -1225,9 +1225,10 @@ and command `sh-reset-indent-vars-to-global-values'." | |||
| 1225 | :type 'hook | 1225 | :type 'hook |
| 1226 | :group 'sh-script) | 1226 | :group 'sh-script) |
| 1227 | 1227 | ||
| 1228 | (defcustom sh-mode-hook nil | 1228 | (defcustom sh-mode-hook '(sh-electric-here-document-mode) |
| 1229 | "Hook run by `sh-mode'." | 1229 | "Hook run by `sh-mode'." |
| 1230 | :type 'hook | 1230 | :type 'hook |
| 1231 | :options '(sh-electric-here-document-mode) | ||
| 1231 | :group 'sh-script) | 1232 | :group 'sh-script) |
| 1232 | 1233 | ||
| 1233 | (defcustom sh-learn-basic-offset nil | 1234 | (defcustom sh-learn-basic-offset nil |
| @@ -1616,7 +1617,8 @@ buffer indents as it currently is indented. | |||
| 1616 | \\[sh-execute-region] Have optional header and region be executed in a subshell. | 1617 | \\[sh-execute-region] Have optional header and region be executed in a subshell. |
| 1617 | 1618 | ||
| 1618 | `sh-electric-here-document-mode' controls whether insertion of two | 1619 | `sh-electric-here-document-mode' controls whether insertion of two |
| 1619 | unquoted < insert a here document. | 1620 | unquoted < insert a here document. You can control this behavior by |
| 1621 | modifying `sh-mode-hook'. | ||
| 1620 | 1622 | ||
| 1621 | If you generally program a shell different from your login shell you can | 1623 | If you generally program a shell different from your login shell you can |
| 1622 | set `sh-shell-file' accordingly. If your shell's file name doesn't correctly | 1624 | set `sh-shell-file' accordingly. If your shell's file name doesn't correctly |
| @@ -1653,7 +1655,6 @@ with your script for an edit-interpret-debug cycle." | |||
| 1653 | (setq-local syntax-propertize-function #'sh-syntax-propertize-function) | 1655 | (setq-local syntax-propertize-function #'sh-syntax-propertize-function) |
| 1654 | (add-hook 'syntax-propertize-extend-region-functions | 1656 | (add-hook 'syntax-propertize-extend-region-functions |
| 1655 | #'syntax-propertize-multiline 'append 'local) | 1657 | #'syntax-propertize-multiline 'append 'local) |
| 1656 | (sh-electric-here-document-mode 1) | ||
| 1657 | (setq-local skeleton-pair-alist '((?` _ ?`))) | 1658 | (setq-local skeleton-pair-alist '((?` _ ?`))) |
| 1658 | (setq-local skeleton-pair-filter-function 'sh-quoted-p) | 1659 | (setq-local skeleton-pair-filter-function 'sh-quoted-p) |
| 1659 | (setq-local skeleton-further-elements | 1660 | (setq-local skeleton-further-elements |
diff --git a/lisp/rect.el b/lisp/rect.el index 685213a0635..6056b14734d 100644 --- a/lisp/rect.el +++ b/lisp/rect.el | |||
| @@ -408,40 +408,41 @@ With a prefix (or a FILL) argument, also fill too short lines." | |||
| 408 | :type 'boolean) | 408 | :type 'boolean) |
| 409 | 409 | ||
| 410 | (defun rectangle--string-preview () | 410 | (defun rectangle--string-preview () |
| 411 | (let ((str (minibuffer-contents))) | 411 | (when rectangle-preview |
| 412 | (when (equal str "") | 412 | (let ((str (minibuffer-contents))) |
| 413 | (setq str (or (car-safe minibuffer-default) | 413 | (when (equal str "") |
| 414 | (if (stringp minibuffer-default) minibuffer-default)))) | 414 | (setq str (or (car-safe minibuffer-default) |
| 415 | (when str (setq str (propertize str 'face 'region))) | 415 | (if (stringp minibuffer-default) minibuffer-default)))) |
| 416 | (with-selected-window rectangle--string-preview-window | 416 | (when str (setq str (propertize str 'face 'rectangle-preview))) |
| 417 | (unless (or (null rectangle--string-preview-state) | 417 | (with-selected-window rectangle--string-preview-window |
| 418 | (equal str (car rectangle--string-preview-state))) | 418 | (unless (or (null rectangle--string-preview-state) |
| 419 | (rectangle--string-flush-preview) | 419 | (equal str (car rectangle--string-preview-state))) |
| 420 | (apply-on-rectangle | 420 | (rectangle--string-flush-preview) |
| 421 | (lambda (startcol endcol) | 421 | (apply-on-rectangle |
| 422 | (let* ((sc (move-to-column startcol)) | 422 | (lambda (startcol endcol) |
| 423 | (start (if (<= sc startcol) (point) | 423 | (let* ((sc (move-to-column startcol)) |
| 424 | (forward-char -1) | 424 | (start (if (<= sc startcol) (point) |
| 425 | (setq sc (current-column)) | 425 | (forward-char -1) |
| 426 | (point))) | 426 | (setq sc (current-column)) |
| 427 | (ec (move-to-column endcol)) | 427 | (point))) |
| 428 | (end (point)) | 428 | (ec (move-to-column endcol)) |
| 429 | (ol (make-overlay start end))) | 429 | (end (point)) |
| 430 | (push ol (nthcdr 3 rectangle--string-preview-state)) | 430 | (ol (make-overlay start end))) |
| 431 | ;; FIXME: The extra spacing doesn't interact correctly with | 431 | (push ol (nthcdr 3 rectangle--string-preview-state)) |
| 432 | ;; the extra spacing added by the rectangular-region-highlight. | 432 | ;; FIXME: The extra spacing doesn't interact correctly with |
| 433 | (when (< sc startcol) | 433 | ;; the extra spacing added by the rectangular-region-highlight. |
| 434 | (overlay-put ol 'before-string (rectangle--space-to startcol))) | 434 | (when (< sc startcol) |
| 435 | (let ((as (when (< endcol ec) | 435 | (overlay-put ol 'before-string (rectangle--space-to startcol))) |
| 436 | ;; (rectangle--space-to ec) | 436 | (let ((as (when (< endcol ec) |
| 437 | (spaces-string (- ec endcol)) | 437 | ;; (rectangle--space-to ec) |
| 438 | ))) | 438 | (spaces-string (- ec endcol)) |
| 439 | (if (= start end) | 439 | ))) |
| 440 | (overlay-put ol 'after-string (if as (concat str as) str)) | 440 | (if (= start end) |
| 441 | (overlay-put ol 'display str) | 441 | (overlay-put ol 'after-string (if as (concat str as) str)) |
| 442 | (if as (overlay-put ol 'after-string as)))))) | 442 | (overlay-put ol 'display str) |
| 443 | (nth 1 rectangle--string-preview-state) | 443 | (if as (overlay-put ol 'after-string as)))))) |
| 444 | (nth 2 rectangle--string-preview-state)))))) | 444 | (nth 1 rectangle--string-preview-state) |
| 445 | (nth 2 rectangle--string-preview-state))))))) | ||
| 445 | 446 | ||
| 446 | ;; FIXME: Should this be turned into inhibit-region-highlight and made to apply | 447 | ;; FIXME: Should this be turned into inhibit-region-highlight and made to apply |
| 447 | ;; to non-rectangular regions as well? | 448 | ;; to non-rectangular regions as well? |
| @@ -782,7 +783,7 @@ Ignores `line-move-visual'." | |||
| 782 | (if (not old) | 783 | (if (not old) |
| 783 | (let ((ol (make-overlay left right))) | 784 | (let ((ol (make-overlay left right))) |
| 784 | (overlay-put ol 'window window) | 785 | (overlay-put ol 'window window) |
| 785 | (overlay-put ol 'face 'region) | 786 | (overlay-put ol 'face 'rectangle-preview) |
| 786 | ol) | 787 | ol) |
| 787 | (let ((ol (pop old))) | 788 | (let ((ol (pop old))) |
| 788 | (move-overlay ol left right (current-buffer)) | 789 | (move-overlay ol left right (current-buffer)) |
| @@ -814,7 +815,7 @@ Ignores `line-move-visual'." | |||
| 814 | (overlay-put ol 'after-string nil))) | 815 | (overlay-put ol 'after-string nil))) |
| 815 | ((< mright rightcol) ;`rightcol' is past EOL. | 816 | ((< mright rightcol) ;`rightcol' is past EOL. |
| 816 | (let ((str (rectangle--space-to rightcol))) | 817 | (let ((str (rectangle--space-to rightcol))) |
| 817 | (put-text-property 0 (length str) 'face 'region str) | 818 | (put-text-property 0 (length str) 'face 'rectangle-preview str) |
| 818 | ;; If cursor happens to be here, draw it at the right place. | 819 | ;; If cursor happens to be here, draw it at the right place. |
| 819 | (rectangle--place-cursor leftcol left str) | 820 | (rectangle--place-cursor leftcol left str) |
| 820 | (overlay-put ol 'after-string str))) | 821 | (overlay-put ol 'after-string str))) |
| @@ -826,7 +827,7 @@ Ignores `line-move-visual'." | |||
| 826 | (overlay-put ol 'after-string nil) | 827 | (overlay-put ol 'after-string nil) |
| 827 | (goto-char right) | 828 | (goto-char right) |
| 828 | (let ((str (rectangle--space-to rightcol))) | 829 | (let ((str (rectangle--space-to rightcol))) |
| 829 | (put-text-property 0 (length str) 'face 'region str) | 830 | (put-text-property 0 (length str) 'face 'rectangle-preview str) |
| 830 | (when (= left right) | 831 | (when (= left right) |
| 831 | (rectangle--place-cursor leftcol left str)) | 832 | (rectangle--place-cursor leftcol left str)) |
| 832 | (overlay-put ol 'after-string str)))) | 833 | (overlay-put ol 'after-string str)))) |
| @@ -836,7 +837,7 @@ Ignores `line-move-visual'." | |||
| 836 | ;; Make zero-width rectangles visible! | 837 | ;; Make zero-width rectangles visible! |
| 837 | (overlay-put ol 'after-string | 838 | (overlay-put ol 'after-string |
| 838 | (concat (propertize " " | 839 | (concat (propertize " " |
| 839 | 'face '(region (:height 0.2))) | 840 | 'face '(rectangle-preview (:height 0.2))) |
| 840 | (overlay-get ol 'after-string)))) | 841 | (overlay-get ol 'after-string)))) |
| 841 | (push ol nrol))) | 842 | (push ol nrol))) |
| 842 | start end)) | 843 | start end)) |
diff --git a/lisp/term.el b/lisp/term.el index ecaca505683..3520a3938e3 100644 --- a/lisp/term.el +++ b/lisp/term.el | |||
| @@ -4159,7 +4159,17 @@ the process. Any more args are arguments to PROGRAM." | |||
| 4159 | ;; .emacs ... | 4159 | ;; .emacs ... |
| 4160 | (term-set-escape-char ?\C-x)) | 4160 | (term-set-escape-char ?\C-x)) |
| 4161 | 4161 | ||
| 4162 | (switch-to-buffer term-ansi-buffer-name)) | 4162 | (switch-to-buffer term-ansi-buffer-name) |
| 4163 | ;; For some reason, without the below setting, ansi-term behaves | ||
| 4164 | ;; sluggishly, not clear why, since the buffer is typically very | ||
| 4165 | ;; small. | ||
| 4166 | ;; | ||
| 4167 | ;; There's a larger problem here with supporting bidirectional text: | ||
| 4168 | ;; the application that writes to the terminal could have its own | ||
| 4169 | ;; ideas about displaying bidirectional text, and might not want us | ||
| 4170 | ;; reordering the text or deciding on base paragraph direction. One | ||
| 4171 | ;; such application is Emacs in TTY mode... FIXME. | ||
| 4172 | (setq bidi-paragraph-direction 'left-to-right)) | ||
| 4163 | 4173 | ||
| 4164 | 4174 | ||
| 4165 | ;;; Serial terminals | 4175 | ;;; Serial terminals |
diff --git a/lisp/window.el b/lisp/window.el index 1d41d821dc4..e086efb594d 100644 --- a/lisp/window.el +++ b/lisp/window.el | |||
| @@ -1889,9 +1889,19 @@ the font." | |||
| 1889 | (ncols (/ window-width font-width))) | 1889 | (ncols (/ window-width font-width))) |
| 1890 | (if (and (display-graphic-p) | 1890 | (if (and (display-graphic-p) |
| 1891 | overflow-newline-into-fringe | 1891 | overflow-newline-into-fringe |
| 1892 | (/= (frame-parameter nil 'left-fringe) 0) | 1892 | (not |
| 1893 | (/= (frame-parameter nil 'right-fringe) 0)) | 1893 | (or (eq left-fringe-width 0) |
| 1894 | (and (null left-fringe-width) | ||
| 1895 | (= (frame-parameter nil 'left-fringe) 0)))) | ||
| 1896 | (not | ||
| 1897 | (or (eq right-fringe-width 0) | ||
| 1898 | (and (null right-fringe-width) | ||
| 1899 | (= (frame-parameter nil 'right-fringe) 0))))) | ||
| 1894 | ncols | 1900 | ncols |
| 1901 | ;; FIXME: This should remove 1 more column when there are no | ||
| 1902 | ;; fringes, lines are truncated, and the window is hscrolled, | ||
| 1903 | ;; but EOL is not in the view, because then there are 2 | ||
| 1904 | ;; truncation glyphs, not one. | ||
| 1895 | (1- ncols))))) | 1905 | (1- ncols))))) |
| 1896 | 1906 | ||
| 1897 | (defun window-current-scroll-bars (&optional window) | 1907 | (defun window-current-scroll-bars (&optional window) |
diff --git a/lisp/xt-mouse.el b/lisp/xt-mouse.el index e52095789ba..a2b64019f97 100644 --- a/lisp/xt-mouse.el +++ b/lisp/xt-mouse.el | |||
| @@ -155,10 +155,7 @@ single byte." | |||
| 155 | (set-keyboard-coding-system | 155 | (set-keyboard-coding-system |
| 156 | (if (terminal-parameter nil 'xterm-mouse-utf-8) | 156 | (if (terminal-parameter nil 'xterm-mouse-utf-8) |
| 157 | 'utf-8-unix | 157 | 'utf-8-unix |
| 158 | ;; Use Latin-1 instead of no-conversion to avoid flicker | 158 | 'no-conversion)) |
| 159 | ;; due to `set-keyboard-coding-system' changing the meta | ||
| 160 | ;; mode. | ||
| 161 | 'latin-1)) | ||
| 162 | ;; Wait only a little; we assume that the entire escape sequence | 159 | ;; Wait only a little; we assume that the entire escape sequence |
| 163 | ;; has already been sent when this function is called. | 160 | ;; has already been sent when this function is called. |
| 164 | (read-char nil nil 0.1)) | 161 | (read-char nil nil 0.1)) |
diff --git a/src/w32heap.c b/src/w32heap.c index df2fe0a8fa3..6643b439a26 100644 --- a/src/w32heap.c +++ b/src/w32heap.c | |||
| @@ -714,13 +714,12 @@ mmap_realloc (void **var, size_t nbytes) | |||
| 714 | /* If there is enough room in the current reserved area, then | 714 | /* If there is enough room in the current reserved area, then |
| 715 | commit more pages as needed. */ | 715 | commit more pages as needed. */ |
| 716 | if (m2.State == MEM_RESERVE | 716 | if (m2.State == MEM_RESERVE |
| 717 | && m2.AllocationBase == memInfo.AllocationBase | ||
| 717 | && nbytes <= memInfo.RegionSize + m2.RegionSize) | 718 | && nbytes <= memInfo.RegionSize + m2.RegionSize) |
| 718 | { | 719 | { |
| 719 | void *p; | 720 | void *p; |
| 720 | 721 | ||
| 721 | p = VirtualAlloc (*var + memInfo.RegionSize, | 722 | p = VirtualAlloc (*var, nbytes, MEM_COMMIT, PAGE_READWRITE); |
| 722 | nbytes - memInfo.RegionSize, | ||
| 723 | MEM_COMMIT, PAGE_READWRITE); | ||
| 724 | if (!p /* && GetLastError() != ERROR_NOT_ENOUGH_MEMORY */) | 723 | if (!p /* && GetLastError() != ERROR_NOT_ENOUGH_MEMORY */) |
| 725 | { | 724 | { |
| 726 | DebPrint (("realloc enlarge: VirtualAlloc (%p + %I64x, %I64x) error %ld\n", | 725 | DebPrint (("realloc enlarge: VirtualAlloc (%p + %I64x, %I64x) error %ld\n", |
| @@ -728,7 +727,8 @@ mmap_realloc (void **var, size_t nbytes) | |||
| 728 | (uint64_t)(nbytes - memInfo.RegionSize), | 727 | (uint64_t)(nbytes - memInfo.RegionSize), |
| 729 | GetLastError ())); | 728 | GetLastError ())); |
| 730 | DebPrint (("next region: %p %p %I64x %x\n", m2.BaseAddress, | 729 | DebPrint (("next region: %p %p %I64x %x\n", m2.BaseAddress, |
| 731 | m2.AllocationBase, m2.RegionSize, m2.AllocationProtect)); | 730 | m2.AllocationBase, (uint64_t)m2.RegionSize, |
| 731 | m2.AllocationProtect)); | ||
| 732 | } | 732 | } |
| 733 | else | 733 | else |
| 734 | return *var; | 734 | return *var; |