1. 07 Aug, 2013 5 commits
  2. 06 Aug, 2013 4 commits
    • Dmitry Antipov's avatar
      * window.c (window_scroll, window_scroll_pixel_based) · 56b5d5b1
      Dmitry Antipov authored
      (window_scroll_line_based): Use bool for booleans.
      56b5d5b1
    • Paul Eggert's avatar
      * process.c: Fix minor off-by-one issues in descriptor counts. · 2878ba7e
      Paul Eggert authored
      This shouldn't fix any real bugs, but it cleans up the code a bit.
      (max_process_desc, max_input_desc): -1, not 0, means none.
      All uses changed.
      (delete_input_desc): New function.
      (delete_write_fd, delete_keyboard_wait_descriptor): Use it.
      (deactivate_process): Scan backwards when recomuting max_process_desc;
      that should be faster.
      (init_process_emacs): Initialize max_input_desc.
      2878ba7e
    • Dmitry Antipov's avatar
      Use region cache to speedup bidi_find_paragraph_start. · e30b79c1
      Dmitry Antipov authored
      * src/buffer.h (struct buffer): New member bidi_paragraph_cache.
      Rename cache_long_line_scans to cache_long_scans.
      * src/buffer.c (bset_cache_long_line_scans): Rename to
      bset_cache_long_scans.
      (Fget_buffer_create, Fmake_indirect_buffer, Fkill_buffer)
      (Fbuffer_swap_text, init_buffer_once): Take bidi_paragraph_cache
      into account.
      (syms_of_buffer): Rename cache-long-line-scans to
      cache-long-scans.  Adjust docstring.
      * src/search.c (newline_cache_on_off):
      * src/indent.c (width_run_cache_on_off): Adjust users.
      * src/bidi.c (bidi_paragraph_cache_on_off): New function.
      (bidi_find_paragraph_start): Use bidi_paragraph_cache if needed.
      * src/insdel.c (prepare_to_modify_buffer): Invalidate
      bidi_paragraph_cache if enabled.
      * doc/lispref/positions.texi (Motion by Screen Lines):
      * doc/lispref/display.texi (Truncation): Rename `cache-long-line-scans'
      to `cache-long-scans'.
      e30b79c1
    • Dmitry Antipov's avatar
      Invalidate region caches only if buffer text is going to be changed. · 00012b86
      Dmitry Antipov authored
      * lisp.h (modify_region_1): Remove 3rd arg and rename to...
      (modify_text): ...new prototype.
      (prepare_to_modify_buffer_1): New prototype.
      * textprop.c (modify_region): Rename to...
      (modify_text_properties): ...new function.
      (add_text_properties_1, set_text_properties, Fremove_text_properties)
      (Fremove_list_of_text_properties): Adjust users.
      * insdel.c (modify_region_1): Remove 3rd arg and reimplement as...
      (modify_text): ...new function.
      (prepare_to_modify_buffer): Reimplement mostly as a wrapper for...
      (prepare_to_modify_buffer_1): ...new function.
      * casefiddle.c (casify_region):
      * editfns.c (Fsubst_char_in_region, Ftranslate_region_internal)
      (Ftranspose_regions): Use modify_text.
      00012b86
  3. 05 Aug, 2013 2 commits
    • Stefan Monnier's avatar
      Revert introduction of isearch-filter-predicates. · dc6c0eda
      Stefan Monnier authored
      Rely on add-function instead.
      * lisp/loadup.el: Preload nadvice.
      * lisp/isearch.el (isearch-filter-predicates): Rename it back to
      isearch-filter-predicate.
      (isearch-message-prefix): Use advice-function-mapc and advice
      properties to get the isearch-message-prefix.
      (isearch-search, isearch-lazy-highlight-search): Revert to funcall
      instead of run-hook-with-args-until-failure.
      (isearch-filter-visible): Not obsolete any more.
      * lisp/replace.el (perform-replace): Revert to funcall
      instead of run-hook-with-args-until-failure.
      * lisp/wdired.el (wdired-change-to-wdired-mode): Use add-function.
      * lisp/dired-aux.el (dired-isearch-filenames-mode): Rename from
      dired-isearch-filenames-toggle; make it into a proper minor mode.
      Use add/remove-function.
      (dired-isearch-filenames-setup, dired-isearch-filenames-end):
      Call the minor-mode rather than add/remove-hook.
      (dired-isearch-filter-filenames):
      Remove isearch-message-prefix property.
      * lisp/info.el (Info--search-loop): New function, extracted from Info-search.
      Funcall isearch-filter-predicate instead of
      run-hook-with-args-until-failure isearch-filter-predicates.
      (Info-search): Use it.
      (Info-mode): Use isearch-filter-predicate instead of
      isearch-filter-predicates.
      * src/lisp.mk (lisp): Add nadvice.elc.
      * lib-src/makefile.w32-in (lisp2): Add nadvice.elc.
      
      Fixes: debbugs:14714
      dc6c0eda
    • Dmitry Antipov's avatar
      New macro to iterate over live buffers similar to frames. · 8f3a2c26
      Dmitry Antipov authored
      * buffer.h (FOR_EACH_LIVE_BUFFER): New macro.
      (Vbuffer_alist, Qpriority, Qbefore_string, Qafter_string):
      Declare buffer-related variables here to offload lisp.h.
      * buffer.c (Vbuffer_alist): Adjust comment.
      (Fget_file_buffer, get_truename_buffer, Fother_buffer)
      (other_buffer_safely):
      * data.c (store_symval_forwarding):
      * dispnew.c (Fframe_or_buffer_changed_p):
      * fileio.c (Fdo_auto_save):
      * filelock.c (unlock_all_files):
      * minibuf.c (read_minibuf): Use FOR_EACH_LIVE_BUFFER.
      8f3a2c26
  4. 04 Aug, 2013 4 commits
    • Paul Eggert's avatar
      Fix some minor races in hosts lacking mkostemp. · e0fdb694
      Paul Eggert authored
      Gnulib's emulation of mkostemp doesn't have races that Emacs's does.
      * configure.ac (mkostemp): Remove check for this function;
      gnulib does the check now.
      (mkstemp): Remove check for this no-longer-used function.
      * lib/mkostemp.c, lib/secure_getenv.c, lib/tempname.c, lib/tempname.h:
      * m4/mkostemp.m4, m4/secure_getenv.m4, m4/tempname.m4:
      New files, copied from Gnulib.
      * lib/gnulib.mk, m4/gnulib-comp.m4: Regenerate.
      * admin/merge-gnulib (GNULIB_MODULES): Add mkostemp.
      * lib-src/movemail.c (main):
      * lib-src/update-game-score.c (write_scores):
      Use mkostemp (which now works on all platforms, due to changes
      in the portability layer) rather than mktemp (which has a race)
      or mkstemp (which we no longer bother with).
      * src/callproc.c (create_temp_file):
      * src/filelock.c (create_lock_file):
      Assume mkostemp, since it's now provided by Gnulib.
      
      Fixes: debbugs:15015
      e0fdb694
    • Eli Zaretskii's avatar
      Minor fix of the last commit. · 484ab239
      Eli Zaretskii authored
      484ab239
    • Eli Zaretskii's avatar
      Implement mkostemp for MS-Windows. · 63f5c6c2
      Eli Zaretskii authored
       nt/mingw-cfg.site (ac_cv_func_mkostemp): New var with value of "yes".
       nt/inc/ms-w32.h (mkostemp): Declare prototype.
       nt/config.nt (HAVE_MKOSTEMP): Define to 1.
      
       src/w32.c (mkostemp): New function.
       (mktemp): Remove, no longer used.  Most of the code reused in mkostemp.
      
      Fixes: debbugs:15015
      63f5c6c2
    • Dmitry Antipov's avatar
      * dispnew.c (glyph_matrix_count, glyph_pool_count): · f0b79313
      Dmitry Antipov authored
      Move under GLYPH_DEBUG and ENABLE_CHECKING.
      (new_glyph_matrix, free_glyph_matrix, new_glyph_pool)
      (free_glyph_pool, check_glyph_memory): Likewise for
      all users.  Adjust comments where appropriate.
      f0b79313
  5. 03 Aug, 2013 4 commits
    • Paul Eggert's avatar
      * composite.h: Minor fixups. · 98f638d6
      Paul Eggert authored
      (composition_registered_p): Rename from COMPOSITION_REGISTERD_P
      to fix a misspelling, and change it to an inline function while
      we're at it (it need not be a macro).  All uses changed.
      (composition_method, composition_valid_p):
      Rewrite to avoid assignments in if-conditions.
      98f638d6
    • Dmitry Antipov's avatar
      416a3e01
    • Dmitry Antipov's avatar
      Do not use global Lisp_Object in composition macros. · 75c59fb3
      Dmitry Antipov authored
      * composite.h (composition_temp): Remove declaration.
      (COMPOSITION_METHOD, COMPOSITION_VALID_P): Replace with...
      (composition_method, composition_valid_p): ...inline functions.
      * composite.c (composition_temp): Remove.
      (run_composition_function, update_compositions)
      (composition_compute_stop_pos, composition_adjust_point)
      (Ffind_composition_internal):
      * coding.c (handle_composition_annotation):
      * xdisp.c (handle_composition_prop, check_point_in_composition):
      Related users changed.
      75c59fb3
    • Dmitry Antipov's avatar
      Drop FRAME_PTR typedef. · a10c8269
      Dmitry Antipov authored
      * composite.c, font.c, font.h, fontset.c, fontset.h, frame.c, frame.h:
      * ftfont.c, ftxfont.c, gtkutil.c, gtkutil.h, image.c, keyboard.c:
      * menu.c, menu.h, msdos.c, nsfns.m, nsfont.m, nsmenu.m, nsterm.h:
      * nsterm.m, scroll.c, term.c, w32fns.c, w32font.c, w32font.h:
      * w32inevt.c, w32inevt.h, w32menu.c, w32notify.c, w32term.c, w32term.h:
      * w32uniscribe.c, w32xfns.c, widget.c, window.c, xdisp.c, xfaces.c:
      * xfns.c, xfont.c, xftfont.c, xmenu.c, xselect.c, xterm.c:
      All related users changed.
      a10c8269
  6. 02 Aug, 2013 6 commits
    • Stefan Monnier's avatar
      Make defvar affect the default binding outside of any let. · a104f656
      Stefan Monnier authored
      * src/eval.c (default_toplevel_binding): New function.
      (Fdefvar): Use it.
      (unbind_to, backtrace_eval_unrewind): Do a bit of CSE simplification.
      (Fdefault_toplevel_value, Fset_default_toplevel_value): New subrs.
      (syms_of_eval): Export them.
      * src/data.c (Fdefault_value): Micro cleanup.
      * src/term.c (init_tty): Use "false".
      * lisp/custom.el (custom-initialize-default, custom-initialize-set)
      (custom-initialize-reset, custom-initialize-changed): Affect the
      toplevel-default-value (bug#6275, bug#14586).
      * lisp/emacs-lisp/advice.el (ad-compile-function): Undo previous workaround
      for bug#6275.
      * test/automated/core-elisp-tests.el: New file.
      a104f656
    • Dmitry Antipov's avatar
      Fix X GC leak in GTK and raw (no toolkit) X ports. · 4b5c9326
      Dmitry Antipov authored
      * xterm.c (x_free_frame_resources): If white and black relief
      GCs are allocated, always free them here.
      * xfns.c (x_make_gc): Omit redundant initialization.
      * widget.c (create_frame_gcs): Remove the leftover.
      (EmacsFrameDestroy): Do nothing because all GCs are now freed
      in x_free_frame_resources.
      4b5c9326
    • Jan Djärv's avatar
      * nsterm.h (EmacsView): Add maximizing_resize, put it and old_title · b19aa636
      Jan Djärv authored
      inside NS_IMPL_COCOA.
      
      * nsterm.m (windowWillResize:toSize:): Only change title if
      ! maximizing_resize && FULLSCREEN_NONE.  strdup title before
      modifying it.
      (viewDidEndLiveResize): New method.
      
      Fixes: debbugs:15005
      b19aa636
    • Dmitry Antipov's avatar
      * insdel.c (adjust_after_replace, replace_range, del_range_2): · af1f7e06
      Dmitry Antipov authored
      Do not check whether undo is enabled because record_insert and
      record_delete does that themselves.
      af1f7e06
    • Dmitry Antipov's avatar
    • Dmitry Antipov's avatar
      * xterm.h (struct x_output) [HAVE_X_I18N]: Remove xic_base_fontname · 65b02bb9
      Dmitry Antipov authored
      member which is not really used any more.
      (FRAME_XIC_BASE_FONTNAME): Remove.
      * xfns.c (xic_free_fontset): Adjust user.
      * xmenu.c (mouse_position_for_popup, x_activate_menubar)
      (update_frame_menubar, set_frame_menubar, free_frame_menubar)
      (create_and_show_popup_menu, xmenu_show, create_and_show_dialog)
      (xdialog_show): Use eassert for debugging check.
      65b02bb9
  7. 01 Aug, 2013 9 commits
  8. 31 Jul, 2013 4 commits
  9. 30 Jul, 2013 2 commits