1. 20 Jan, 2019 1 commit
    • Eli Zaretskii's avatar
      Support native image resizing on MS-Windows · 67b1053d
      Eli Zaretskii authored
      * src/w32term.c (x_draw_image_foreground): Scale the image if
      the requested dimensions are different from the bitmap
      * src/image.c (Fimage_scaling_p): Return t when HAVE_NTGUI.
      (x_set_image_size) [HAVE_NTGUI]: Record the scaled dimensions
      in the image struct.
      * src/dispextern.h (HAVE_NATIVE_SCALING): Define when
      HAVE_NTGUI as well.
      * etc/NEWS: Update the announcement of native image scaling.
  2. 18 Jan, 2019 1 commit
  3. 17 Jan, 2019 1 commit
    • Martin Rudalics's avatar
      Expand spectrum of window change functions · 0aece3e1
      Martin Rudalics authored
      * src/window.c (run_window_change_functions): Run window
      change functions for Qwindow_state_change_functions.
      (resize_frame_windows): Set frame's window_change slot when
      single-window frames change size.
      (Qwindow_state_change_functions): New symbol.
      (Vwindow_state_change_functions): New Lisp variable.
      * doc/lispref/windows.texi (Selecting Windows): Mention
      'window-selection/state-change-functions' and add reference to
      Window Hooks.
      (Window Hooks): Document 'window-state-change-functions'.
      * etc/NEWS: Mention new hook 'window-state-change-functions'.
  4. 16 Jan, 2019 1 commit
    • Eli Zaretskii's avatar
      Improve documentation of pdumper; minor code cleanup · ebd174e2
      Eli Zaretskii authored
      * src/emacs.c (usage_message): Add the --dump-file option.
      (string_starts_with_p, find_argument): Functions removed; use
      'argmatch' instead.
      (PDUMP_FILE_ARG): Macro removed; use literal strings instead,
      as with other command-line options.  Use HAVE_PDUMPER for cpp
      conditionals which used PDUMP_FILE_ARG.
      (load_pdump, main): Use 'argmatch' for "--dump-file" and
      "--temacs" arguments, thus supporting the "-dump-file" and
      "-temacs" variants, for consistency with other options.
      (main): Remove the extra fatal error for using --dump-file in
      unexec'ed Emacs: load_pdump does that anyway.
      (standard_args): Add --dump-file and --temacs, with
      appropriate priorities.
      * etc/NEWS: Expand on the pdumper support.
      * doc/emacs/cmdargs.texi (Initial Options): Document the
      '--dump-file' command-line option.
  5. 15 Jan, 2019 1 commit
  6. 11 Jan, 2019 1 commit
    • Martin Rudalics's avatar
      Run window change functions during redisplay · e567ac14
      Martin Rudalics authored
      * doc/lispref/windows.texi (Window Sizes): Move (and rename)
      descriptions of 'window-pixel-height-before-size-change' and
      'window-pixel-width-before-size-change' to Window Hooks
      (Window Configurations): Remove warning against use of
      'save-window-excursion' in 'window-size-change-functions'.
      (Window Hooks): Rewrite section according to redesign of
      window change functions.
      * lisp/erc/erc-track.el (erc-window-configuration-change)
      (erc-modified-channels-update): Call latter directly from
      'window-configuration-change-hook' instead via
      * lisp/frame.el (frame-size-changed-p): Change nomenclature
      in let bindings.
      * lisp/net/rcirc.el (rcirc-window-configuration-change)
      (rcirc-window-configuration-change-1): Call latter directly
      from 'window-configuration-change-hook' instead via
      * lisp/window.el (window-pixel-width-before-size-change)
      (window-pixel-height-before-size-change): Defalias.
      (window--resize-mini-window, window-resize)
      (adjust-window-trailing-edge, delete-window)
      (delete-other-windows, balance-windows): Don't run
      'window-configuration-change-hook' any more from here.
      (split-window): Don't run 'window-configuration-change-hook'
      from here.  'run-window-scroll-functions' from here.
      (window--adjust-process-windows): Run from
      'window-configuration-change-hook' only.
      * src/frame.c (old_selected_frame): New Lisp variable.
      (make_frame): Initialize frame's change_stamp slot.
      (Fold_selected_frame): New function.
      * src/frame.h (struct frame): New slots old_selected_window,
      window_change, change_stamp and number_of_windows.
      (fset_old_selected_window): New inlined function.
      * src/window.c (old_selected_window): New Lisp variable.
      (wset_old_buffer): New inlined function.
      (Fframe_old_selected_window, Fold_selected_window)
      (Fwindow_old_buffer): New functions.
      (Fwindow_old_pixel_width, Fwindow_old_pixel_height): Rename
      from Fwindow_pixel_width_before_size_change and
      Fwindow_pixel_height_before_size_change.  Update doc-strings.
      (Fwindow_old_body_pixel_width, Fwindow_old_body_pixel_height):
      New functions.
      (Fdelete_other_windows_internal): Set frame's window_change
      slot instead of running 'window-configuration-change-hook'.
      (Frun_window_configuration_change_hook): In doc-string tell
      that this function is no more needed.
      (Frun_window_scroll_functions): Amend doc-string.  Run with
      window's buffer current.
      (window_sub_list, window_change_record_windows)
      (window_change_record_frame, window_change_record)
      (run_window_change_functions_1, run_window_change_functions):
      New functions.
      (set_window_buffer): Set frame's window_change slot instead of
      running 'window-configuration-change-hook'.
      (make_window): Don't initialize pixel_width_before_size_change
      and pixel_height_before_size_change slots.
      (window_resize_apply, Fdelete_window_internal): Set frame's
      window_change slot.
      (Fsplit_window_internal): Set frame's window_change slot.
      Don't run 'window-scroll-functions' from here.
      * src/window.h (struct window): New slots old_buffer,
      change_stamp, old_pixel_width (renamed from
      pixel_width_before_size_change), old_pixel_height (renamed
      from pixel_height_before_size_change), old_body_pixel_width
      and old_body_pixel_height.
      * src/xdisp.c (init_iterator): Set frame's window_change slot
      when the body height or width changes.
      (prepare_menu_bars): Don't run_window_size_change_functions.
      (redisplay_internal): Don't run_window_size_change_functions,
      run_window_change_functions instead.
  7. 10 Jan, 2019 4 commits
    • Alan Third's avatar
      Add native image scaling (bug#33587) · a1b7a3f2
      Alan Third authored
      * configure.ac: Test for XRender outside of xft checks.
      * src/Makefile.in (XRENDER_LIBS): List XRender libs separately from
      xft libs.
      * lisp/image.el (image--get-imagemagick-and-warn): Allow resizing if
      native scaling is available.
      * src/dispextern.h: Add XRender and image scaling stuff.
      (struct image): Add XRender Pictures.
      * src/image.c (x_create_bitmap_mask):
      (image_create_x_image_and_pixmap): Handle XRender Picture.
      (compute_image_size): Make available when any form of scaling is
      (x_set_image_size): New function.
      (lookup_image): Set image size.
      (x_create_x_image_and_pixmap): Create XRender Picture when necessary.
      (x_put_x_image): Handle the case where desired size != actual size.
      (free_image): Free XRender Pictures.
      (Fimage_scaling_p): New function.
      (syms_of_image): Add image-scaling-p.
      * src/nsimage.m (ns_load_image): Remove NS specific resizing.
      ([EmacsImage setSizeFromSpec:]): Remove method.
      (ns_image_set_size): New function.
      * src/nsterm.m (ns_draw_fringe_bitmap): Cocoa and GNUstep both have
      the same compositing functions, so remove unnecessary difference.
      * src/xterm.c (x_composite_image): New function.
      (x_draw_image_foreground): Use new x_composite_image function.
      * doc/lispref/display.texi (Image Descriptors): Document
      image-scaling-p and add resizing descriptors.
      (ImageMagick Images): Remove resizing descriptors.
    • Alan Third's avatar
      Fix drag and drop behaviour on NS (bug#30929) · c342b263
      Alan Third authored
      * doc/emacs/macos.texi (Mac / GNUstep Events): Describe the new drag
      and drop behaviour.
      * lisp/term/ns-win.el (ns-drag-n-drop): Handle the new event format.
      (ns-drag-n-drop-as-text-other-frame): Remove functions and key
      * src/nsterm.m ([EmacsView performDragOperation:]): Send Emacs event
      in new format without setting any modifiers.
    • Martin Rudalics's avatar
      Handle dedicated status in 'window--display-buffer' (Bug#33870) · f646675c
      Martin Rudalics authored
      * lisp/window.el (display-buffer-record-window): Rewrite
      (window--display-buffer): Remove fifth argument DEDICATED and
      either directly use a 'dedicated' entry in ALIST or the value
      of 'display-buffer-mark-dedicated' instead.
      (display-buffer-in-atom-window, display-buffer-use-some-frame)
      (display-buffer-pop-up-frame, display-buffer-pop-up-window)
      (display-buffer-below-selected, display-buffer-at-bottom):
      Adjust callers of 'window--display-buffer'.
      (display-buffer-in-side-window): Handle dedicated status of
      the chosen side window via a 'dedicated' alist entry and
      adjust 'window--display-buffer' call.
      (display-buffer-in-child-frame): Set up TYPE correctly for and
      adjust 'window--display-buffer' call.
      (display-buffer-in-previous-window): Handle dedicated status
      of a previous window already showing BUFFER.
      * doc/lispref/windows.texi (Buffer Display Action Alists): New
      action alist entry 'dedicated'.
      (Dedicated Windows): Mention new buffer display action alist
      entry 'dedicated'.
      * etc/NEWS: Mention new buffer display action alist entry
    • Paul Eggert's avatar
      Mention Japanese change in documentation · a2e78046
      Paul Eggert authored
  8. 07 Jan, 2019 1 commit
    • Paul Eggert's avatar
      Fix logb on zero, infinite, NaN args · 202bd7bf
      Paul Eggert authored
      Change logb to return -infinity, +infinity, and NaN respectively.
      Formerly logb returned an extreme fixnum to represent
      infinity, but this is no longer the right thing to do now that
      we have bignums and there is no extreme integer.
      * doc/lispref/numbers.texi (Float Basics), etc/NEWS: Document.
      * src/floatfns.c (Flogb): Implement this.
  9. 02 Jan, 2019 3 commits
  10. 01 Jan, 2019 2 commits
    • Paul Eggert's avatar
      Update more copyright years · a04bf151
      Paul Eggert authored
      Update some other copyright years automatically, by running:
      UPDATE_COPYRIGHT_MAX_LINE_LENGTH=79 admin/update-copyright'
      followed by 'admin/merge-gnulib'.
    • Paul Eggert's avatar
      Update copyright year to 2019 · 26bed8ba
      Paul Eggert authored
      Run 'TZ=UTC0 admin/update-copyright $(git ls-files)'.
  11. 31 Dec, 2018 1 commit
    • Michael Albinus's avatar
      Precise documentation of Tramp ad-hoc proxies · 792dc36e
      Michael Albinus authored
      * doc/misc/tramp.texi (Ad-hoc multi-hops): Remove superfluous
      first entry about %h and %u.  Describe, how to remove ad-hoc proxy
      (Cleanup remote connections): Mention, that also ad-hoc proxy
      definitions are removed.
      * etc/NEWS: Mention default host names in Tramp ad-hoc proxies.
  12. 25 Dec, 2018 2 commits
  13. 23 Dec, 2018 2 commits
  14. 22 Dec, 2018 3 commits
    • Philipp Stephani's avatar
      Add file name handler support for 'make-process' (Bug#28691) · 039be4e0
      Philipp Stephani authored
      * src/process.c (Fmake_process): Add new keyword argument
      (syms_of_process) <make-process, :file-handler>: Define new symbols.
      * lisp/files.el (file-name-non-special): Add support for
      * test/src/process-tests.el (make-process/file-handler/found)
      (make-process/file-handler/disable): New unit tests.
      (process-tests--file-handler): New helper function.
      * test/lisp/files-tests.el
      (files-tests-file-name-non-special-make-process): New unit test.
      * doc/lispref/files.texi (Magic File Names): Document that
      'make-process' can invoke file name handlers.
      * doc/lispref/processes.texi (Asynchronous Processes): Document
      ':file-handlers' argument to 'make-process'.
      * etc/NEWS (Lisp Changes in Emacs 27.1): Mention new
      :file-handler argument for 'make-process'.
    • Michael Albinus's avatar
      ; Cosmetic changes in etc/NEWS · 29310168
      Michael Albinus authored
    • Michael Albinus's avatar
      ; Cosmetic changes to etc/NEWS · 36c270da
      Michael Albinus authored
  15. 20 Dec, 2018 3 commits
  16. 17 Dec, 2018 3 commits
    • Juri Linkov's avatar
      Syntactic fontification of diff hunks (bug#33567) · 6973b148
      Juri Linkov authored
      * lisp/vc/diff-mode.el (diff-font-lock-syntax): New defcustom.
      (diff-default-directory): New buffer-local variable.
      (diff-indicator-removed, diff-indicator-added)
      (diff-indicator-changed): Set foreground to distinctive colors.
      (diff-context): Remove colors to make room for syntax highlighting.
      (diff-font-lock-keywords): Add diff--font-lock-syntax.
      (diff--font-lock-cleanup): Remove diff-mode syntax overlays.
      (diff--font-lock-syntax, diff--font-lock-syntax--refresh)
      (diff-syntax-fontify-revisions, diff-syntax-fontify-hunk)
      (diff-syntax-fontify-props): New functions.
      * lisp/vc/diff.el (diff-no-select): Set diff-default-directory to
      * doc/emacs/files.texi (Diff Mode): Document diff-font-lock-syntax.
    • Stefan Monnier's avatar
      * lisp/emacs-lisp/map.el: Avoid special casing lists. · 55838e4e
      Stefan Monnier authored
      (map-not-inplace, map-inplace): New errors.
      (map-insert): New generic function.
      (map-put!): Signal map-not-inplace rather than a generic 'error'.
      (map-elt): Use map-not-inplace and map-insert to avoid hardcoding
      a special case for lists.
      * test/lisp/emacs-lisp/map-tests.el (test-map-put!): Rename from
      test-map-put.  Also test the errors signaled.
    • Alex Branham's avatar
      New function flatten-tree · 36b05dc8
      Alex Branham authored
      Co-authored-by: default avatarBasil L. Contovounesios <contovob@tcd.ie>
      * doc/lispref/lists.texi: Document `flatten-tree'.
      * lisp/progmodes/js.el (js--maybe-join):
      * lisp/printing.el (pr-switches):
      * lisp/lpr.el (lpr-print-region):
      * lisp/gnus/nnimap.el (nnimap-find-wanted-parts):
      * lisp/gnus/message.el (message-talkative-question):
      * lisp/gnus/gnus-sum.el (gnus-remove-thread)
      (gnus-thread-highest-number, gnus-thread-latest-date):
      * lisp/eshell/esh-util.el (eshell-flatten-and-stringify):
      * lisp/eshell/esh-opt.el (eshell-eval-using-options):
      * lisp/eshell/esh-ext.el (eshell-external-command):
      * lisp/eshell/em-xtra.el (eshell/expr):
      * lisp/eshell/em-unix.el (eshell/rm, eshell-mvcpln-template)
      (eshell/cat, eshell/make, eshell-poor-mans-grep, eshell-grep)
      (eshell/du, eshell/time, eshell/diff, eshell/locate):
      * lisp/eshell/em-tramp.el (eshell/su, eshell/sudo):
      * lisp/eshell/em-term.el (eshell-exec-visual):
      * lisp/eshell/em-dirs.el (eshell-dirs-substitute-cd, eshell/cd):
      * lisp/eshell/em-basic.el (eshell/printnl):
      Use new flatten-tree.
      * lisp/progmodes/js.el (js--flatten-list):
      * lisp/lpr.el (lpr-flatten-list):
      * lisp/gnus/message.el (message-flatten-list):
      * lisp/eshell/esh-util.el (eshell-flatten-list):
      Obsolete in favor of Emacs-wide `flatten-tree'.
      * lisp/subr.el (flatten-list): Alias to `flatten-tree' for
      * lisp/subr.el (flatten-tree): New defun.
      * test/lisp/subr-tests.el (subr-tests-flatten-tree): New test.
  17. 16 Dec, 2018 1 commit
    • Michael Albinus's avatar
      Add Tramp sudoedit method · e8199e76
      Michael Albinus authored
      * doc/misc/tramp.texi (Quick Start Guide): New section "Using sudoedit".
      (External methods) <sudoedit>: Describe.
      * lisp/net/tramp-adb.el (tramp-adb-file-name-handler-alist):
      * lisp/net/tramp-gvfs.el (tramp-gvfs-file-name-handler-alist):
      * lisp/net/tramp-rclone.el (tramp-rclone-file-name-handler-alist):
      * lisp/net/tramp-sh.el (tramp-sh-file-name-handler-alist)
      * lisp/net/tramp-smb.el (tramp-smb-file-name-handler-alist):
      Add handler.
      * lisp/net/tramp-sh.el (tramp-sh-handle-set-file-uid-gid): Rename from
      `tramp-sh-handle-set-file-uid-gid'.  Handle only remote file names.
      * lisp/net/tramp-sudoedit.el: New file.
      * lisp/net/tramp.el (tramp-file-name-for-operation): Handle also
      (tramp-set-file-uid-gid): New defun.
      (tramp-get-local-uid, tramp-get-local-gid): Cache result.
      * test/lisp/net/tramp-tests.el (tramp--test-sudoedit-p): New defun.
      (tramp-test20-file-modes, tramp-test22-file-times)
      (tramp--test-sudoedit-p): Use it.
  18. 11 Dec, 2018 1 commit
    • Stefan Monnier's avatar
      * lisp/emacs-lisp/map.el: Make the functions generic · 1691a510
      Stefan Monnier authored
      Make them document their delegation relationship, to clarify when
      a method is needed.
      (map--dispatch): Give more info in the error message.
      (map-elt): Make it generic and deprecate the 'testfn' arg.
      (map-put): Make it obsolete.
      (map-length): Make it work on hash-tables.
      (map-apply): Define it in terms of map-do.
      (map-do, map-into): Use cl-generic dispatch instead of map--dispatch.
      (map-empty-p): Define it in terms of map-length.
      (map-contains-key): Deprecate 'testfn'.  Make it return a boolean, so
      it can return non-nil even if 'key' is nil.  Improve implementation to
      avoid constructing an intermediate list of all keys.
      (map-merge-with): Use 'eql' rather than `eq'.
      (map-put!): Rename from map--put and make it generic, to replace map-put.
      (map--apply-alist, map--apply-hash-table, map--apply-array):
      Turn them into methods of map-apply.
      (map--do-alist, map--do-array): Turn them into methods of map-do.
      (map--into-hash-table): Turn it into a method of map-into.
  19. 10 Dec, 2018 1 commit
  20. 08 Dec, 2018 2 commits
  21. 06 Dec, 2018 2 commits
  22. 04 Dec, 2018 3 commits
    • Eli Zaretskii's avatar
      Support IBM038 (a.k.a. "EBCDIC-INT") encoding · 6d898918
      Eli Zaretskii authored
      * lisp/international/mule-conf.el (ibm038): New charset.
      (ebcdic-int, cp038): Alias charsets of ibm038.
      * lisp/language/english.el (ibm038): New coding-system.
      (ebcdic-int, cp038): Alias coding-systems of ibm038.
      * etc/NEWS: Announce the new coding system ibm038.
    • Juri Linkov's avatar
      * lisp/isearch.el (isearch-yank-on-move): New defcustom · f745cf8c
      Juri Linkov authored
      with shift-move related options extracted from `search-exit-option'.
      (isearch-pre-command-hook): Rename search-exit-option to
      isearch-yank-on-move in shift-move related places.
      (isearch-post-command-hook): Check for isearch-pre-move-point
      instead of search-exit-option.  (Bug#15839)
      * doc/emacs/search.texi (Not Exiting Isearch): Rename
      search-exit-option to isearch-yank-on-move.
      * lisp/menu-bar.el (menu-bar-i-search-menu): Add more isearch commands.
    • Juri Linkov's avatar
      * lisp/isearch.el (isearch-allow-scroll): New option `unlimited'. · beafe2bf
      Juri Linkov authored
      (isearch-pre-command-hook): Call isearch-pre-scroll-point unless
      isearch-allow-scroll is 'unlimited'.
      (isearch-post-command-hook): Use `when' instead of `cond'.
      Call isearch-lazy-highlight-new-loop when isearch-allow-scroll is
      'unlimited'.  (Bug#15839)