1. 29 Nov, 2013 2 commits
  2. 28 Nov, 2013 1 commit
    • Stefan Monnier's avatar
      Refine redisplay optimizations to only redisplay *some* frames/windows · 655ab9a3
      Stefan Monnier authored
      rather than all of them.
      * src/xdisp.c (REDISPLAY_SOME): New constant.
      (redisplay_other_windows, wset_redisplay, fset_redisplay)
      (bset_redisplay, bset_update_mode_line): New functions.
      (message_dolog): Use bset_redisplay.
      (clear_garbaged_frames): Use fset_redisplay.
      (echo_area_display): Use wset_redisplay.
      (buffer_shared_and_changed): Remove.
      (prepare_menu_bars): Call Vpre_redisplay_function before updating
      frame titles.  Compute the actual set of windows redisplayed.
      Don't update frame titles and menu bars for frames that don't need to
      be redisplayed.
      (propagate_buffer_redisplay): New function.
      (AINC): New macro.
      (redisplay_internal): Use it.  Be more selective in the set of windows
      we redisplay.  Propagate windows_or_buffers_changed to
      update_mode_lines a bit later to simplify the code.
      (mark_window_display_accurate_1): Reset window and buffer's
      `redisplay' flag.
      (redisplay_window): Do nothing if neither the window nor the buffer nor
      the frame needs redisplay.
      * src/window.h (struct window): Add `redisplay' field.
      (wset_redisplay, fset_redisplay, bset_redisplay, bset_update_mode_line)
      (redisplay_other_windows, window_list): New declarations.
      * src/window.c (select_window, Fset_window_start): Use wset_redisplay.
      (window_list): Not static any more.
      (grow_mini_window, shrink_mini_window): Use fset_redisplay.
      * src/minibuf.c (read_minibuf_unwind): Don't redisplay everything.
      * src/insdel.c (prepare_to_modify_buffer_1): Use bset_redisplay.
      * src/frame.c (Fmake_frame_visible): Don't redisplay everything.
      * src/frame.h (struct frame): Add `redisplay' field.
      Move `external_menu_bar' bitfield next to other bit-fields.
      (SET_FRAME_GARBAGED): Use fset_redisplay.
      (SET_FRAME_VISIBLE): Don't garbage the frame;
      Use redisplay_other_windows.
      * src/buffer.h (struct buffer): Add `redisplay' field.
      * src/buffer.c (Fforce_mode_line_update): Pay attention to the `all' flag.
      (modify_overlay): Use bset_redisplay.
      * src/alloc.c (gc_sweep): Don't unmark strings while sweeping symbols.
      
      * lisp/doc-view.el (doc-view-goto-page): Update mode-line.
      655ab9a3
  3. 27 Nov, 2013 1 commit
  4. 06 Nov, 2013 2 commits
  5. 04 Nov, 2013 1 commit
    • Paul Eggert's avatar
      Port to stricter C99 platforms. · 91f2d272
      Paul Eggert authored
      Especially, C99 prohibits nesting a struct X inside struct Y if
      struct X has a flexible array member.
      Also, merge from gnulib, incorporating:
      2013-11-03 intprops: port to Oracle Studio c99
      * lib/intprops.h: Update from gnulib.
      * src/alloc.c (struct sdata): New type.
      (sdata): Implement in terms of struct sdata.
      Remove u member; all uses replaced by next_vector, set_next_vector.
      (SDATA_SELECTOR, SDATA_DATA, SDATA_DATA_OFFSET): Adjust to sdata change.
      (SDATA_DATA_OFFSET): Now a constant, not a macro.
      (struct sblock): Rename first_data member to data, which is now
      a flexible array member.  All uses changed.
      (next_vector, set_next_vector, large_vector_vec): New functions.
      (vector_alignment): New constant.
      (roundup_size): Make it a multiple of ALIGNOF_STRUCT_LISP_VECTOR, too.
      (struct large-vector): Now merely a NEXT member, since the old approach
      ran afoul of stricter C99.  All uses changed to use
      large_vector_vec or large_vector_offset.
      (large_vector_offset): New constant.
      * src/dispnew.c: Include tparam.h, for tgetent.
      Do not include term.h; no longer needed.
      * src/gnutls.c (Fgnutls_boot): Don't continue after calling a _Noreturn.
      * src/lisp.h (ENUM_BF) [__SUNPRO_C && __STDC__]: Use unsigned int.
      (struct Lisp_Vector): Use a flexible array member for contents,
      instead of a union with a member that is an array of size 1.
      All uses changed.
      (ALIGNOF_STRUCT_LISP_VECTOR): New constant, to make up for the
      fact that the struct no longer contains a union.
      (struct Lisp_Misc_Any, struct Lisp_Marker, struct Lisp_Overlay)
      (struct Lisp_Save_Value, struct Lisp_Free):
      Use unsigned, not int, for spacers, to avoid c99 warning.
      (union specbinding): Use unsigned, not bool, for bitfield, as
      bool is not portable to pre-C99 hosts.
      91f2d272
  6. 02 Oct, 2013 1 commit
  7. 30 Sep, 2013 1 commit
  8. 29 Sep, 2013 1 commit
  9. 24 Sep, 2013 1 commit
    • Dmitry Antipov's avatar
      Use union for the payload of struct Lisp_Vector. · d6d9cbc1
      Dmitry Antipov authored
      This helps to avoid a few glitches dictated by C's aliasing rules.
      * lisp.h (struct Lisp_Vector): Use union for next and
      contents member.  Adjust comment.  Change related users.
      * alloc.c (next_in_free_list, set_next_in_free_list): Remove.
      Related users changed.
      * buffer.c, bytecode.c, ccl.c, character.h, chartab.c, composite.c:
      * composite.h, disptab.h, fns.c, fontset.c, indent.c, keyboard.c:
      * lread.c, msdos.c, process.c, w32menu.c, window.c, xdisp.c:
      * xfaces.c, xfont.c, xmenu.c: Related users changed.
      d6d9cbc1
  10. 23 Sep, 2013 1 commit
    • Dmitry Antipov's avatar
      * dispnew.c (frame_garbaged, selected_frame, last_nonminibuf_frame): · 5492865b
      Dmitry Antipov authored
      Move to...
      * frame.c (frame_garbaged, selected_frame, last_nonminibuf_frame):
      ...this file and convert the latter to static.  Adjust comment.
      (make_initial_frame):
      * window.c (init_window_once): Adjust user.
      * frame.h (last_nonminibuf_frame): Remove declaration.
      * lisp.h (selected_frame): Likewise.
      * msdos.c (the_only_display_info): Adjust comment.
      5492865b
  11. 20 Sep, 2013 1 commit
    • Paul Eggert's avatar
      A simpler, centralized INLINE. · 00382e8b
      Paul Eggert authored
      * lib-src/profile.c (INLINE): New macro.
      (SYSTIME_INLINE): Remove.
      * src/conf_post.h (INLINE): Define only if not already defined.
      This allows us to use a single INLINE, defined by one file
      per executable.
      * src/emacs.c (INLINE): Define it.
      Also, include category.h, charset.h, composite.h, dispextern.h,
      syntax.h, systime.h, so that their INLINE definitions are expanded
      properly for Emacs.
      * src/blockinput.h, src/keyboard.c (BLOCKINPUT_INLINE):
      * src/buffer.h, src/buffer.c (BUFFER_INLINE):
      * src/category.h, src/category.c (CATEGORY_INLINE):
      * src/character.h, src/character.c (CHARACTER_INLINE):
      * src/charset.h, src/charset.c (CHARSET_INLINE):
      * src/composite.h, src/composite.c (COMPOSITE_INLINE):
      * src/dispextern.h, src/dispnew.c (DISPEXTERN_INLINE):
      * src/frame.h, src/frame.c (FRAME_INLINE):
      * src/intervals.h, src/intervals.c (INTERVALS_INLINE):
      * src/keyboard.h, src/keyboard.c (KEYBOARD_INLINE):
      * src/lisp.h, src/alloc.c (LISP_INLINE):
      * src/process.h, src/process.c (PROCESS_INLINE):
      * src/syntax.h, src/syntax.c (SYNTAX_INLINE):
      * src/systime.h, src/sysdep.c (SYSTIME_INLINE):
      * src/termhooks.h, src/terminal.h (TERMHOOKS_INLINE):
      * src/window.h, src/window.c (WINDOW_INLINE):
      Remove.  All uses replaced with INLINE.
      00382e8b
  12. 11 Sep, 2013 1 commit
    • Dmitry Antipov's avatar
      Ifdef away frame tool bar code when it is not really used. · 742516e0
      Dmitry Antipov authored
      * frame.h (struct frame) [HAVE_WINDOW_SYSTEM && !USE_GTK && !HAVE_NS]:
      Move tool_bar_window, desired_tool_bar_string, current_tool_bar_string
      and minimize_tool_bar_window_p under the above.
      (fset_current_tool_bar_string, fset_desired_tool_bar_string)
      (fset_tool_bar_window): Likewise.
      * dispnew.c (clear_current_matrices, clear_desired_matrices)
      (adjust_frame_glyphs_for_window_redisplay, free_glyphs, update_frame)
      (change_frame_size_1):
      * window.c (window_from_coordinates, Frecenter): Adjust users.
      * window.h (WINDOW_TOOL_BAR_P): Define to zero when frame tool bar
      code is not really used.
      * xdisp.c (build_desired_tool_bar_string, display_tool_bar_line)
      (tool_bar_lines_needed, MAX_FRAME_TOOL_BAR_HEIGHT, tool_bar_item_info)
      (get_tool_bar_item, handle_tool_bar_click, note_tool_bar_highlight)
      [!USE_GTK && !HAVE_NS]: Define as such.
      (Ftool_bar_lines_needed, redisplay_tool_bar, show_mouse_face)
      (note_mouse_highlight, expose_frame):
      * xfns.c (x_set_tool_bar_lines):
      * xterm.c (handle_one_xevent): Adjust users.
      742516e0
  13. 06 Sep, 2013 1 commit
    • Dmitry Antipov's avatar
      Attempt to make redisplay more selective when changing fonts. · bd0443bb
      Dmitry Antipov authored
      * frame.h (struct frame): New bitfield fonts_changed.
      * dispextern.h (fonts_changed_p, adjust_glyphs): Remove declaration.
      (adjust_frame_glyphs): Add prototype.
      * dispnew.c (fonts_changed_p): Remove.
      (adjust_glyphs): Remove becase we do not
      adjust matrices on all frames at once any more.
      (adjust_frame_glyphs): Block and unblock input here.
      (adjust_glyph_matrix): Use fonts_changed.
      (change_frame_size_1): Use adjust_frame_glyphs.
      * font.c (font_open_entity): Use fonts_changed.
      * frame.c (set_menu_bar_lines, Fmake_terminal_frame):
      * w32fns.c (x_set_menu_bar_lines, x_set_tool_bar_lines, Fx_show_tip):
      * window.c (Fdelete_other_windows_internal, Fwindow_resize_apply)
      (Fsplit_window_internal, Fdelete_window_internal, grow_mini_window)
      (shrink_mini_window, Fresize_mini_window_internal)
      (window_scroll_pixel_based, Fset_window_configuration)
      (apply_window_adjustment, Fset_window_vscroll):
      * xfns.c (x_set_menu_bar_lines, x_set_tool_bar_lines, Fx_show_tip):
      Use adjust_frame_glyphs.
      * xdisp.c (redisplay_tool_bar, redisplay_window, try_window)
      (try_window_reusing_current_matrix, try_window_id, display_line)
      (IT_EXPAND_MATRIX_WIDTH): Use fonts_changed.
      (redisplay_internal): Consider fonts_changed and adjust frame
      matrices for each frame only if the frame is visible.  If font
      has been changed on some frame during full redisplay, retry
      only visible frames where the font has been actually changed.
      bd0443bb
  14. 05 Sep, 2013 2 commits
    • Dmitry Antipov's avatar
      Cache current header and mode line height for each window. · b9695828
      Dmitry Antipov authored
      * window.h (struct window): New fields mode_line_height
      and header_line_height.
      * window.c (make_window): Initialize them.
      * dispextern.h (CURRENT_MODE_LINE_HEIGHT)
      (CURRENT_HEADER_LINE_HEIGHT): Use them.  Adjust comment.
      (current_mode_line_height, current_header_line_height):
      Remove declaration.
      * xdisp.c (current_mode_line_height, current_header_line_height):
      Remove.
      (pos_visible_p, init_xdisp): Adjust user.
      (redisplay_window): Invalidate mode_line_height and
      header_line_height if current and desired matrices do not agree.
      b9695828
    • Dmitry Antipov's avatar
      * fontset.c, window.c, xdisp.c (toplevel): Use TERM_HEADER. · 66738305
      Dmitry Antipov authored
      * xfaces.c (toplevel) [HAVE_X_WINDOWS]: Do not include xterm.h twice.
      66738305
  15. 01 Sep, 2013 1 commit
  16. 31 Aug, 2013 1 commit
  17. 29 Aug, 2013 1 commit
  18. 27 Aug, 2013 1 commit
    • Dmitry Antipov's avatar
      * lisp.h (Mouse_HLInfo): Move from here... · 9fed9729
      Dmitry Antipov authored
      * dispextern.h (Mouse_HLInfo): ...to here and offload lisp.h.
      (reset_mouse_highlight): New function.
      * msdos.c (dos_set_window_size, IT_update_begin)
      (internal_terminal_init):
      * nsterm.m (ns_update_window_end, x_free_frame_resources)
      (ns_initialize_display_info):
      * w32console.c (initialize_w32_display):
      * w32term.c (x_update_window_end, x_free_frame_resources)
      (w32_initialize_display_info):
      * xterm.c (x_update_window_end, x_free_frame_resources, x_term_init):
      * window.c (Fdelete_other_windows_internal):
      * xdisp.c (clear_mouse_face, cancel_mouse_face): Use it.
      * termchar.h (toplevel):
      * xterm.h (toplevel): Include dispextern.h.
      9fed9729
  19. 26 Aug, 2013 1 commit
  20. 23 Aug, 2013 1 commit
  21. 14 Aug, 2013 3 commits
    • Dmitry Antipov's avatar
      * window.h (struct window): Convert window_end_pos and · 02455cb6
      Dmitry Antipov authored
      window_end_vpos from Lisp_Object to ptrdiff_t and int, respectively.
      (wset_window_end_pos, wset_window_end_vpos): Remove.
      * dispnew.c (adjust_glyph_matrix):
      * window.c (Fwindow_end, replace_window, set_window_buffer)
      (make_window):
      * xdisp.c (check_window_end, move_it_to, redisplay_internal)
      (set_vertical_scroll_bar, redisplay_window, try_window)
      (try_window_reusing_current_matrix, find_first_unchanged_at_end_row)
      (try_window_id, decode_mode_spec, mouse_face_from_buffer_pos)
      (note_mouse_highlight): Adjust users.
      (try_cursor_movement): Likewise.  Convert old precondition to eassert.
      Add comment.
      02455cb6
    • Dmitry Antipov's avatar
      Cleanup window fringes, margins and scroll bars adjustments. · 25554267
      Dmitry Antipov authored
      * window.c (set_window_fringes, set_window_margins)
      (set_window_scroll_bars, apply_window_adjustment): New functions.
      (set_window_buffer, Fset_window_margins, Fset_window_fringes)
      (Fset_window_scroll_bars): Use them.
      25554267
    • Dmitry Antipov's avatar
      * window.h (struct window): Convert scroll_bar_width · 38a2c910
      Dmitry Antipov authored
      from Lisp_Object to integer.  Adjust comment.
      (WINDOW_CONFIG_SCROLL_BAR_WIDTH, WINDOW_CONFIG_SCROLL_BAR_COLS):
      Adjust users.
      * window.c (wset_scroll_bar_width): Remove.
      (make_window): Initialize scroll_bar_width.
      (Fsplit_window_internal): Use direct assignment.
      (Fset_window_configuration, save_window_save):
      Convert Lisp_Object to integer and back where appropriate.
      (Fset_window_scroll_bars): Adjust user.  Return t if any scroll
      bar was actually changed, and mention this in docstring.
      38a2c910
  22. 13 Aug, 2013 4 commits
    • Eli Zaretskii's avatar
      Fix the Windows build broken by 2013-08-13T15:29:25Z!dmantipov@yandex.ru. · 2fa611b7
      Eli Zaretskii authored
       src/window.c (Fwindow_margins): Return nil when there's no marginal
       area, as per the documented API.
       src/w32term.c (x_scroll_bar_create): Use ALLOCATE_PSEUDOVECTOR, not
       Fmake_vector, as scroll bar's struct members are not all Lisp
       objects now.  This avoids crashes in GC.
       src/w32term.h (struct scroll_bar): Convert fringe_extended_p to a
       bool, so its address could be taken.
      2fa611b7
    • Dmitry Antipov's avatar
      * window.h (struct window): Convert left_margin_cols and · eeaf9bf3
      Dmitry Antipov authored
      right_margin_cols from Lisp_Objects to integers.  Adjust comment.
      (WINDOW_LEFT_MARGIN_COLS, WINDOW_RIGHT_MARGIN_COLS)
      (WINDOW_LEFT_MARGIN_WIDTH, WINDOW_RIGHT_MARGIN_WIDTH):
      Adjust users.
      * dispnew.c (margin_glyphs_to_reserve): Convert 3rd arg to int.
      Adjust comment.
      (showing_window_margins_p, update_window_line, update_frame_1):
      * fringe.c (draw_fringe_bitmap_1):
      * xdisp.c (window_box_width): Adjust users.
      * window.c (wset_left_margin_cols, wset_right_margin_cols): Remove.
      (adjust_window_margins, set_window_buffer, Fsplit_window_internal):
      Use direct assignment.
      (Fset_window_configuration, save_window_save, Fwindow_margins):
      Convert Lisp_Object to integer and back where appropriate.
      (Fset_window_margins): Adjust user.  Return t if any margin
      was actually changed, and mention this in docstring.
      eeaf9bf3
    • Dmitry Antipov's avatar
      * window.h (struct window): Convert left_fringe_width · 9e37ee3b
      Dmitry Antipov authored
      and right_fringe_width from Lisp_Objects to integers.
      Adjust comment.
      (WINDOW_FRINGE_COLS, WINDOW_LEFT_FRINGE_WIDTH)
      (WINDOW_RIGHT_FRINGE_WIDTH): Adjust users.
      * window.c (wset_left_fringe_width, wset_right_fringe_width):
      Remove.
      (make_window): Initialize new integer fields to -1.
      (Fsplit_window_internal): Use direct assignment.
      (Fset_window_configuration, save_window_save): Convert
      Lisp_Object to integer and back where appropriate.
      (Fset_window_fringes): Adjust user.  Return t if any fringe
      was actually changed, and mention this in docstring.
      9e37ee3b
    • Dmitry Antipov's avatar
      * window.c (Fset_window_start): Compare `w', not `window' because · ae966a86
      Dmitry Antipov authored
      `w' might not be equal to `window' after call to decode_live_window.
      ae966a86
  23. 12 Aug, 2013 1 commit
    • Dmitry Antipov's avatar
      Avoid looping over all frame windows to freeze and unfreeze. · d2e113bc
      Dmitry Antipov authored
      * window.h (struct window): Drop frozen_window_start_p.
      (freeze_window_starts): Drop prototype.
      * frame.h (struct frame): New frozen_window_starts flag.
      (FRAME_WINDOWS_FROZEN): New macro.
      * window.c (freeze_window_start, freeze_window_starts):
      Remove.
      (select_window, replace_window): Adjust users.
      * xdisp.c (resize_mini_window): Use FRAME_WINDOWS_FROZEN.
      (window_frozen_p): New function.
      (redisplay_window): Use it.
      d2e113bc
  24. 11 Aug, 2013 1 commit
    • Paul Eggert's avatar
      Omit some unnecessary casts. · 7d652d97
      Paul Eggert authored
      Many of these go back to the old pre-C89 days, when they may have
      been needed, but we've been assuming C89 or later for a while now.
      * alloc.c (live_string_p, live_cons_p, live_symbol_p)
      (live_float_p, live_misc_p, live_vector_p):
      * buffer.c (compare_overlays, cmp_for_strings, mmap_find)
      (mmap_alloc, alloc_buffer_text, enlarge_buffer_text)
      (defvar_per_buffer):
      * callint.c (Fcall_interactively):
      * doc.c (Fsubstitute_command_keys):
      * filelock.c (get_boot_time):
      * frame.c (xrdb_get_resource):
      * gtkutil.c (hierarchy_ch_cb, qttip_cb, style_changed_cb)
      (delete_cb, xg_dialog_response_cb, xg_maybe_add_timer)
      (xg_get_file_name_from_selector, menuitem_destroy_callback)
      (menuitem_highlight_callback, menu_destroy_callback)
      (xg_update_menu_item, xg_modify_menubar_widgets, menubar_map_cb)
      (xg_tool_bar_callback, xg_get_tool_bar_widgets)
      (xg_tool_bar_detach_callback, xg_tool_bar_attach_callback)
      (xg_tool_bar_help_callback, tb_size_cb):
      * image.c (xpm_alloc_color, png_read_from_memory)
      (png_read_from_file, png_load_body, our_memory_skip_input_data)
      (jpeg_memory_src, jpeg_file_src, imagemagick_load_image)
      (syms_of_image):
      * keymap.c (describe_map):
      * nsfns.m (Fns_display_monitor_attributes_list):
      * nsmenu.m (process_dialog:):
      * nsterm.m (hold_event):
      * process.c (wait_reading_process_output):
      * regex.c (REGEX_REALLOCATE, re_set_registers, re_exec, regexec):
      * scroll.c (do_direct_scrolling, scrolling_1):
      * termcap.c (tgetent):
      * window.c (check_window_containing, add_window_to_list)
      (freeze_window_starts):
      * xdisp.c (compare_overlay_entries, vmessage):
      * xfns.c (x_window, x_get_monitor_attributes_xinerama)
      (x_get_monitor_attributes_xrandr)
      (Fx_display_monitor_attributes_list, x_display_info_for_name)
      (Fx_open_connection, file_dialog_cb, file_dialog_unmap_cb):
      * xfont.c (xfont_match, xfont_open):
      * xmenu.c (x_menu_wait_for_event, menu_highlight_callback)
      (menubar_selection_callback, menu_position_func)
      (popup_selection_callback, create_and_show_popup_menu)
      (dialog_selection_callback, create_and_show_dialog):
      * xrdb.c (x_get_string_resource):
      (main) [TESTRM]:
      * xsmfns.c (x_session_check_input):
      * xterm.c (x_draw_glyphless_glyph_string_foreground)
      (xm_scroll_callback, xg_scroll_callback, xg_end_scroll_callback)
      (xaw_jump_callback, xaw_scroll_callback):
      Omit unnecessary casts.
      7d652d97
  25. 08 Aug, 2013 1 commit
    • Dmitry Antipov's avatar
      Do not reset window modification event counters excessively. · 628fdc56
      Dmitry Antipov authored
      These leftovers and poor man's tricky methods to catch extra
      redisplay's attention are no longer needed.
      * frame.c (set_menu_bar_lines_1):
      * minibuf.c (read_minibuf_unwind):
      * window.c (Fset_window_start, set_window_buffer, window_resize_apply)
      (grow_mini_window, shrink_mini_window, window_scroll_pixel_based)
      (window_scroll_line_based, Fset_window_configuration):
      * xdisp.c (redisplay_window): Do not reset last_modified and
      last_overlay_modified counters.
      628fdc56
  26. 07 Aug, 2013 2 commits
    • Dmitry Antipov's avatar
      Prefer selected_window to Fselected_window, likewise for frames. · d2a95ffb
      Dmitry Antipov authored
      * buffer.c (Fbuffer_swap_text):
      * data.c (Fvariable_binding_locus):
      * window.c (run_window_configuration_change_hook): Adjust users.
      * w16select.c (Fw16_set_clipboard_data, Fw16_get_clipboard_data):
      Use decode_live_frame.
      d2a95ffb
    • Dmitry Antipov's avatar
      Be more careful if selected window shows the buffer other than current, · 170da1ec
      Dmitry Antipov authored
      use window_outdated only if this is not so.  This change should also
      address some weird issues discussed in Bug#13012.
      * window.h (window_outdated): New prototype.
      * window.c (window_outdated): Now here.  Convert from static and
      always assume window's buffer.
      (Fwindow_end, Fwindow_line_height): Use it.
      * xdisp.c (reconsider_clip_changes): Remove prototype, drop 2nd arg
      and always assume window's buffer.
      (redisplay_window): Adjust user.
      (redisplay_internal): Call to reconsider_clip_change once and
      check whether mode line should be updated only if selected window
      shows current buffer.
      (run_window_scroll_functions): Use eassert for debugging check.
      (Fmove_point_visually, note_mouse_highlight): Use window_outdated.
      170da1ec
  27. 06 Aug, 2013 1 commit
  28. 03 Aug, 2013 1 commit
    • 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
  29. 30 Jul, 2013 1 commit
    • Dmitry Antipov's avatar
      * fringe.c (draw_window_fringes, update_window_fringes) · d7e6881a
      Dmitry Antipov authored
      (compute_fringe_widths):
      * w32term.c (x_draw_glyph_string):
      * window.c (candidate_window_p, Frecenter):
      * xfaces.c (realize_basic_faces, realize_default_face)
      (Fbitmap_space_p, Finternal_set_lisp_face_attribute)
      (x_update_menu_appearance, face_attr_equal_p, lface_equal_p):
      * xfns.c (x_set_cursor_color, xic_free_xfontset):
      * xmenu.c (Fx_menu_bar_open_internal):
      * xselect.c (x_reply_selection_request, Fx_get_atom_name):
      * xsettings.c (xft_settings_event):
      * xterm.c (x_draw_glyph_string, x_had_errors_p):
      Use bool for booleans.  Adjust style and comments where
      appropriate.
      * dispextern.h (draw_window_fringes, update_window_fringes)
      (compute_fringe_widths):
      * xterm.h (x_had_errors_p): Adjust prototype.
      d7e6881a
  30. 16 Jul, 2013 1 commit
    • Paul Eggert's avatar
      New unwind-protect flavors to better type-check C callbacks. · 27e498e6
      Paul Eggert authored
      This also lessens the need to write wrappers for callbacks,
      and the need for make_save_pointer.
      * alloca.c (free_save_value):
      * atimer.c (run_all_atimers):
      Now extern.
      * alloc.c (safe_alloca_unwind):
      * atimer.c (unwind_stop_other_atimers):
      * keyboard.c (cancel_hourglass_unwind) [HAVE_WINDOW_SYSTEM]:
      * menu.c (cleanup_popup_menu) [HAVE_NS]:
      * minibuf.c (choose_minibuf_frame_1):
      * process.c (make_serial_process_unwind):
      * xdisp.h (pop_message_unwind):
      * xselect.c (queue_selection_requests_unwind):
      Remove no-longer-needed wrapper.  All uses replaced by the wrappee.
      * alloca.c (record_xmalloc):
      Prefer record_unwind_protect_ptr to record_unwind_protect with
      make_save_pointer.
      * alloca.c (Fgarbage_collect):
      Prefer record_unwind_protect_void to passing a dummy.
      * buffer.c (restore_buffer):
      * window.c (restore_window_configuration):
      * xfns.c, w32fns.c (do_unwind_create_frame)
      New wrapper.  All record-unwind uses of wrappee changed.
      * buffer.c (set_buffer_if_live):
      * callproc.c (call_process_cleanup, delete_temp_file):
      * coding.c (code_conversion_restore):
      * dired.c (directory_files_internal_w32_unwind) [WINDOWSNT]:
      * editfns.c (save_excursion_restore)
      (subst_char_in_region_unwind, subst_char_in_region_unwind_1)
      (save_restriction_restore):
      * eval.c (restore_stack_limits, un_autoload):
      * fns.c (require_unwind):
      * keyboard.c (recursive_edit_unwind, tracking_off):
      * lread.c (record_load_unwind, load_warn_old_style_backquotes):
      * macros.c (pop_kbd_macro, restore_menu_items):
      * nsfns.m (unwind_create_frame):
      * print.c (print_unwind):
      * process.c (start_process_unwind):
      * search.c (unwind_set_match_data):
      * window.c (select_window_norecord, select_frame_norecord):
      * xdisp.c (unwind_with_echo_area_buffer, unwind_format_mode_line)
      (fast_set_selected_frame):
      * xfns.c, w32fns.c (unwind_create_tip_frame):
      Return void, not a dummy Lisp_Object.  All uses changed.
      * buffer.h (set_buffer_if_live): Move decl here from lisp.h.
      * callproc.c (call_process_kill):
      * fileio.c (restore_point_unwind, decide_coding_unwind)
      (build_annotations_unwind):
      * insdel.c (Fcombine_after_change_execute_1):
      * keyboard.c (read_char_help_form_unwind):
      * menu.c (unuse_menu_items):
      * minibuf.c (run_exit_minibuf_hook, read_minibuf_unwind):
      * sound.c (sound_cleanup):
      * xdisp.c (unwind_redisplay):
      * xfns.c (clean_up_dialog):
      * xselect.c (x_selection_request_lisp_error, x_catch_errors_unwind):
      Accept no args and return void, instead of accepting and returning
      a dummy Lisp_Object.  All uses changed.
      * cygw32.c (fchdir_unwind):
      * fileio.c (close_file_unwind):
      * keyboard.c (restore_kboard_configuration):
      * lread.c (readevalllop_1):
      * process.c (wait_reading_process_output_unwind):
      Accept int and return void, rather than accepting an Emacs integer
      and returning a dummy object.  In some cases this fixes an
      unlikely bug when the corresponding int is outside Emacs integer
      range.  All uses changed.
      * dired.c (directory_files_internal_unwind):
      * fileio.c (do_auto_save_unwind):
      * gtkutil.c (pop_down_dialog):
      * insdel.c (reset_var_on_error):
      * lread.c (load_unwind):
      * xfns.c (clean_up_file_dialog):
      * xmenu.c, nsmenu.m (pop_down_menu):
      * xmenu.c (cleanup_widget_value_tree):
      * xselect.c (wait_for_property_change_unwind):
      Accept pointer and return void, rather than accepting an Emacs
      save value encapsulating the pointer and returning a dummy object.
      All uses changed.
      * editfns.c (Fformat): Update the saved pointer directly via
      set_unwind_protect_ptr rather than indirectly via make_save_pointer.
      * eval.c (specpdl_func): Remove.  All uses replaced by definiens.
      (unwind_body): New function.
      (record_unwind_protect): First arg is now a function returning void,
      not a dummy Lisp_Object.
      (record_unwind_protect_ptr, record_unwind_protect_int)
      (record_unwind_protect_void): New functions.
      (unbind_to): Support SPECPDL_UNWIND_PTR etc.
      * fileio.c (struct auto_save_unwind): New type.
      (do_auto_save_unwind): Use it.
      (do_auto_save_unwind_1): Remove; subsumed by new do_auto_save_unwind.
      * insdel.c (struct rvoe_arg): New type.
      (reset_var_on_error): Use it.
      * lisp.h (SPECPDL_UNWIND_PTR, SPECPDL_UNWIND_INT, SPECPDL_UNWIND_VOID):
      New constants.
      (specbinding_func): Remove; there are now several such functions.
      (union specbinding): New members unwind_ptr, unwind_int, unwind_void.
      (set_unwind_protect_ptr): New function.
      * xselect.c: Remove unnecessary forward decls, to simplify maintenance.
      27e498e6
  31. 06 Jul, 2013 1 commit
    • Eli Zaretskii's avatar
      Fix bug #14771 with scroll-step = 1 and non-nil line-spacing. · fdda0220
      Eli Zaretskii authored
       src/xdisp.c (default_line_pixel_height): New function.
       (pos_visible_p, move_it_vertically_backward, try_scrolling)
       (try_cursor_movement, redisplay_window, try_window)
       (try_window_id): Use it instead of FRAME_LINE_HEIGHT.  (Bug#14771)
       src/window.c (window_scroll_pixel_based): use
       default_line_pixel_height.
       src/dispextern.h (default_line_pixel_height): Add prototype.
       src/frame.c (x_set_line_spacing): Accept a float value for
       line-spacing parameter, per the documentation.
      fdda0220