1. 28 Jun, 2010 1 commit
    • Jan D's avatar
      Use non-deprecated Gtk+ functions, add changes for Gtk+3 with GSEAL_ENABLE. · e547b051
      Jan D authored
      * configure.in: Add --with-x-toolkit=gtk3. Remove HAVE_GTK_MULTIDISPLAY,
      check for gtk_file_chooser_dialog_new, and HAVE_GTK_FILE_BOTH (implied
      by minimum required Gtk+ 2.6).  Add checks for functions introduced
      in Gtk+ 2.14 or newer.
      
      * xterm.h (gtk_widget_get_window, gtk_widget_get_mapped)
      (gtk_adjustment_get_page_size, gtk_adjustment_get_upper): New
      defines based on what configure finds.
      
      * xterm.c (XTflash): Use gtk_widget_get_window.
      (xg_scroll_callback): Use gtk_adjustment_get_upper and
      gtk_adjustment_get_page_size.
      (handle_one_xevent): Use gtk_widget_get_mapped.
      (x_term_init): Remove HAVE_GTK_MULTIDISPLAY and associated error
      messages.
      
      * xmenu.c (create_and_show_popup_menu): Call gtk_widget_get_mapped.
      
      * gtkutil.h: Replace HAVE_GTK_FILE_BOTH with
      HAVE_GTK_FILE_SELECTION_NEW.
      
      * gtkutil.c (xg_display_open, xg_display_close): Remove
      HAVE_GTK_MULTIDISPLAY, it is always defined.
      (xg_display_open): Return type is void.
      (gtk_widget_set_has_window)
      (gtk_dialog_get_action_area, gtk_dialog_get_content_area)
      (gtk_widget_get_sensitive, gtk_adjustment_set_page_size)
      (gtk_adjustment_set_page_increment)
      (gtk_adjustment_get_step_increment): #define these if not found
      by configure.
      (remove_submenu): New define based on Gtk+ version.
      (xg_set_cursor, xg_frame_resized, xg_event_is_for_scrollbar): Use
      gtk_widget_get_window.
      (xg_frame_resized, xg_update_frame_menubar): Use gtk_widget_get_mapped.
      (xg_create_frame_widgets): Use gtk_widget_set_has_window.
      (create_dialog): Use gtk_dialog_get_action_area and
      gtk_dialog_get_content_area.
      (xg_uses_old_file_dialog, xg_get_file_name): Remove HAVE_GTK_FILE_BOTH
      and HAVE_GTK_FILE_CHOOSER_DIALOG_NEW.  File chooser is always
      available, so checking for HAVE_GTK_FILE_SELECTION_NEW is enough.
      (xg_update_menubar, xg_update_submenu, xg_show_toolbar_item): Use
      g_object_ref and g_object_unref.
      (xg_update_menu_item, xg_tool_bar_menu_proxy): Use
      gtk_widget_get_sensitive.
      (xg_update_submenu): Use remove_submenu.
      (xg_update_scrollbar_pos): Don't use GtkFixedChild, use child
      properties instead to get old x and y position.
      (xg_set_toolkit_scroll_bar_thumb): Use gtk_adjustment_get_page_size,
      gtk_adjustment_get_step_increment, gtk_adjustment_set_page_size,
      gtk_adjustment_set_step_increment and gtk_adjustment_set_page_increment.
      (xg_get_tool_bar_widgets): New function.
      (xg_tool_bar_menu_proxy, xg_show_toolbar_item)
      (update_frame_tool_bar): Call xg_get_tool_bar_widgets.
      (toolbar_set_orientation): New #define based on if configure
      finds gtk_orientable_set_orientation.
      (xg_create_tool_bar): Call toolbar_set_orientation.
      (xg_make_tool_item, xg_show_toolbar_item): Call gtk_box_pack_start
      instead of gtk_box_pack_start_defaults.
      e547b051
  2. 22 Jun, 2010 1 commit
    • Jan Djärv's avatar
      Hide scroll bar when window is too small to avoid Gtk+ warning. · bc869eca
      Jan Djärv authored
      * gtkutil.c (xg_update_scrollbar_pos): Show/hide scroll bar as needed
      if height is less than scroll bar min size.
      (xg_show_scroll_bar): Remove, show moved to xg_update_scrollbar_pos.
      
      * gtkutil.h (xg_show_scroll_bar): : Remove.
      
      * xterm.c (x_scroll_bar_create): Remove call to xg_show_scroll_bar.
      bc869eca
  3. 08 Jun, 2010 1 commit
    • Dan Nicolaescu's avatar
      Remove INCLUDED_FCNTL. · a99ebb40
      Dan Nicolaescu authored
      * xterm.c (INCLUDED_FCNTL):
      * callproc.c (INCLUDED_FCNTL):
      * alloc.c (INCLUDED_FCNTL):
      * systty.h (INCLUDED_FCNTL): Remove all uses, not needed anymore.
      (emacs_get_tty, emacs_set_tty): Declare unconditionally.
      a99ebb40
  4. 06 May, 2010 1 commit
  5. 02 May, 2010 1 commit
    • Jan Djärv's avatar
      Run kill-emacs when exiting for display closed or SIGTERM/HUP. · f63d0028
      Jan Djärv authored
      * xsmfns.c (CHDIR_OPT): New define.
      (smc_save_yourself_CB): Add CHDIR_OPT to options to use when
      restarting emacs.
      
      * xterm.c (x_connection_closed): Call Fkill_emacs instead of
      shut_down_emacs.
      
      * emacs.c (USAGE1): Mention --chdir.
      (main): Handle --chdir.
      (standard_args): Add --chdir.
      (fatal_error_signal): Call Fkill_emacs for SIGTERM and SIGHUP (Bug
      #5552).
      
      * cmdargs.texi (Initial Options): Mention --chdir.
      f63d0028
  6. 20 Apr, 2010 1 commit
    • Jan Djärv's avatar
      Gtk tool bars can be text, icons with text or just icons. · f904c0f9
      Jan Djärv authored
      * xsettings.c: Qmonospace_font_name, Qtool_bar_style and
      current_tool_bar_style are new.
      (store_config_changed_event): Rename from store_font_changed_event.
      (XSETTINGS_TOOL_BAR_STYLE): New define.
      (SEEN_FONT, SEEN_TB_STYLE): New enum values.
      (struct xsettings): Add font and tb_style, set xft stuff inside #ifdef
      HAVE_XFT.
      (something_changedCB): store_font_changed_event is now
      store_config_changed_event
      (parse_settings): Rename from parse_xft_settings.  Read
      non-xft xsettings outside #ifdef HAVE_XFT.
      (read_settings): Renamed from read_xft_settings.
      (apply_xft_settings): Take current settings as parameter.  Do not
      call read_(xft)_settings.
      (read_and_apply_settings): New function.
      (xft_settings_event): Do non-xft stuff out of HAVE_XFT.  Call
      read_and_apply_settings if there are settings to be read.
      (init_xsettings): Renamed from init_xfd_settings.
      Call read_and_apply_settings unconditionally.
      (xsettings_initialize): Call init_xsettings.
      (Ftool_bar_get_system_style): New function.
      (syms_of_xsettings): Define Qmonospace_font_name and
      Qtool_bar_style.  Initialize current_tool_bar_style to nil.
      defsubr Stool_bar_get_system_style. Fprovide on
      dynamic-setting.
      
      * xsettings.h (Ftool_bar_get_system_style): Declare.
      
      * xdisp.c: Vtool_bar_style, tool_bar_max_label_size,
      Qtext, Qboth, Qboth_horiz are new.
      (syms_of_xdisp): Intern Qtext, Qboth, Qboth_horiz, DEFVAR
      Vtool_bar_style, tool_bar_max_label_size.
      
      * lisp.h: Extern declare Qtext, Qboth, Qboth_horiz.
      
      * keyboard.c: QClabel is new.
      (parse_tool_bar_item): Take out QClabel from tool bar items.
      Try to construct a label if ther is no QClabel.
      (syms_of_keyboard): Intern :label as QClabel.
      
      * dispextern.h (tool_bar_item_idx): TOOL_BAR_ITEM_LABEL is new.
      (Vtool_bar_style, tool_bar_max_label_size, DEFAULT_TOOL_BAR_LABEL_SIZE):
      New.
      
      * Makefile.in (SOME_MACHINE_LISP): font-setting.el renamed to
      dynamic-setting.el.
      
      * gtkutil.c (xg_tool_bar_menu_proxy): Handle label in tool bar item.
      (xg_make_tool_item, xg_show_toolbar_item): New function.
      (update_frame_tool_bar): Take label from TOOL_BAR_ITEM_LABEL.
      Call xg_make_tool_item to make a tool bar item.
      Call xg_show_toolbar_item.  Use wtoolbar instead of x->toolbar_widget.
      
      * xterm.c (x_draw_image_relief): Take Vtool_bar_button_margin
      into account for toolbars.
      
      * vc-dir.el (vc-dir-tool-bar-map): Add :label on some tool bar items.
      
      * tool-bar.el (tool-bar-setup): Add :label on some tool bar items.
      
      * loadup.el: Load dynamic-setting.el if feature dynamic-setting
      is present.
      
      * info.el (info-tool-bar-map): Add labels.
      
      * cus-start.el (all): Add tool-bar-style and tool-bar-max-label-size.
      
      * cus-edit.el (custom-commands): Add labels for tool bar.
      (custom-buffer-create-internal, Custom-mode): Adjust for
      labels in custom-commands.
      
      * dynamic-setting.el: Renamed from font-setting.el.
      f904c0f9
  7. 10 Apr, 2010 1 commit
    • Eli Zaretskii's avatar
      Implement cursor on the left fringe for R2L lines. · f951a506
      Eli Zaretskii authored
       xdisp.c (IT_OVERFLOW_NEWLINE_INTO_FRINGE): For R2L lines,
       consider the left fringe, not the right one.
       (set_cursor_from_row): Don't reverse pos_before and pos_after for
       reversed glyph rows.  Set cursor.x to negative value when the
       cursor might be on the left fringe.
       (extend_face_to_end_of_line): Append the stretch glyph only if its
       width is positive.
       (notice_overwritten_cursor, draw_phys_cursor_glyph)
       (erase_phys_cursor): For reversed cursor_row, support cursor on
       the left fringe.
       w32term.c (w32_draw_window_cursor): For reversed glyph rows,
       draw cursor on the left fringe.
       xterm.c (x_draw_window_cursor): For reversed glyph rows, draw
       cursor on the left fringe.
       fringe.c (draw_fringe_bitmap): For reversed glyph rows, allow
       cursor on the left fringe.
       dispnew.c (update_text_area): Handle reversed desired rows when
       the cursor is on the left fringe.
       (set_window_cursor_after_update): Limit cursor's hpos by -1 from
       below, not by 0, for when the cursor is on the left fringe.
      f951a506
  8. 07 Apr, 2010 2 commits
  9. 02 Apr, 2010 1 commit
    • Dan Nicolaescu's avatar
      Remove extern errno declarations. · 42a2c622
      Dan Nicolaescu authored
      * xterm.c:
      * xrdb.c:
      * w32term.c:
      * unexec.c:
      * unexaix.c:
      * sysdep.c:
      * process.c:
      * lread.c:
      * keyboard.c:
      * floatfns.c:
      * filelock.c:
      * fileio.c:
      * emacs.c (main):
      * ecrt0.c:
      * dispnew.c:
      * callproc.c:
      * buffer.c: Remove errno extern declarations.
      * s/netbsd.h (NEED_ERRNO): Remove.
      
      * movemail.c:
      * etags.c:
      * emacsclient.c: Remove extern errno declarations.
      42a2c622
  10. 31 Mar, 2010 1 commit
    • Dan Nicolaescu's avatar
      Clean up BSD_SYSTEM use. · 1d29df59
      Dan Nicolaescu authored
      * xterm.c:
      * process.c:
      * emacs.c: Use HAVE_SYS_IOCTL_H instead of BSD_SYSTEM as a guard
      for including <sys/ioctl.h>.
      * sysdep.c (wait_without_blocking): Remove BSD_SYSTEM case, this
      code is only used for MSDOS.
      1d29df59
  11. 24 Feb, 2010 1 commit
    • Jan Djärv's avatar
      Move declarations before statements. · 32e737d7
      Jan Djärv authored
      * xterm.c (XTflash): Move declarations before statements.
      
      * gtkutil.c (xg_get_gdk_display): Remove (unused).
      (xg_get_pixbuf_from_pix_and_mask, xg_create_frame_widgets)
      (xg_toggle_notify_cb, xg_set_toolkit_scroll_bar_thumb)
      (xg_create_tool_bar): Remove unused variables.
      (x_wm_set_size_hint): Move declarations before statements.
      (xg_create_frame_widgets): Remove variable grav,
      32e737d7
  12. 13 Feb, 2010 2 commits
  13. 16 Jan, 2010 2 commits
  14. 13 Jan, 2010 3 commits
  15. 09 Jan, 2010 1 commit
    • YAMAMOTO Mitsuharu's avatar
      Make line<->pixel_y conversion macros aware of native menu/tool bars. · 4b00d3b1
      YAMAMOTO Mitsuharu authored
      They are placed above the internal border.  This supersedes special
      treatment of native tool bars in the display code.
      
      This fixes wrong display position of native menu bars and bogus mouse
      highlighting of native tool bars, both of which can be found when
      internal border width is large.  Also it fixes wrong flashed part on
      visible bell with native menu bars.
      
      * frame.h (FRAME_TOP_MARGIN_HEIGHT): New macro.
      (FRAME_LINE_TO_PIXEL_Y, FRAME_PIXEL_Y_TO_LINE): Take account of pseudo
      windows above internal border.
      
      * window.h (WINDOW_MENU_BAR_P, WINDOW_TOOL_BAR_P): New macros.
      (WINDOW_TOP_EDGE_Y, WINDOW_BOTTOM_EDGE_Y): Take account of pseudo
      windows above internal border.
      
      * xdisp.c (get_glyph_string_clip_rects, init_glyph_string): Don't treat
      tool bar windows specially.
      
      * xfns.c (x_set_tool_bar_lines): Take account of menu bar height.
      
      * xterm.c (x_after_update_window_line): Don't treat tool bar windows
      specially.
      (XTflash): Take account of menu bar height.
      
      * w32term.c (x_after_update_window_line): Don't treat tool bar windows
      specially.
      4b00d3b1
  16. 06 Jan, 2010 1 commit
  17. 05 Jan, 2010 2 commits
    • Jan Djärv's avatar
      Remove fprintf · 451f23ab
      Jan Djärv authored
      451f23ab
    • Jan Djärv's avatar
      Handle change of internal-border width when maximized. · 7c583cd8
      Jan Djärv authored
      * xterm.c (x_new_font): Move code for setting rows/cols before
      resizing ...
      (x_set_window_size): ... to here. bug #2568.
      
      * gtkutil.c (xg_clear_under_internal_border): New function.
      (xg_frame_resized, xg_frame_set_char_size): Call
      xg_clear_under_internal_border.
      (xg_update_scrollbar_pos): Clear under old scroll bar position.
      7c583cd8
  18. 13 Dec, 2009 3 commits
    • Jan Djärv's avatar
      Set the extended window manager hint for tooltip windows. · 36acb2a7
      Jan Djärv authored
      * xfns.c (x_create_tip_frame): Set the extended window manager hint for
      tooltip windows.
      
      * xterm.h (struct x_display_info): Add Xatom_net_window_type_tooltip and
      Xatom_net_window_type.
      
      * xterm.c (x_term_init): Initialize Xatom_net_window_type_tooltip and
      Xatom_net_window_type.
      36acb2a7
    • Jan Djärv's avatar
      Work around warning about g_set_prgname() called multiple times. · b8f00677
      Jan Djärv authored
      * xterm.c (my_log_handler): New function.
      (x_term_init): Set my_log_handler as log handler during gtk_init
      so we can filter out buggy messages. (bug #5120).
      b8f00677
    • Jan Djärv's avatar
      Bug 5177: Scroll bar thumb did not move when scrolling with mouse wheel. · e5f0bc9a
      Jan Djärv authored
      * xterm.c (xg_scroll_callback): Parameter list changed,
      use parameter GtkScrollType to determine scroll/line/page.
      Only allow dragging if a button < 4 is grabbed (bug #5177).
      (xg_end_scroll_callback): New function.
      (x_create_toolkit_scroll_bar): Pass xg_end_scroll_callback to
      xg_create_scroll_bar.
      
      * gtkutil.c (xg_gtk_scroll_destroy): Remove XG_LAST_SB_DATA handling.
      (scroll_end_callback): Remove.
      (xg_create_scroll_bar): Add parameter end_callback, bind it to
      button-release-event.  Replace value-changed event with change-value,
      bug #5177,
      (xg_event_is_for_scrollbar): Only return true if button is less than 4,
      bug #5177.
      
      * gtkutil.h (XG_LAST_SB_DATA): Remove.
      (xg_create_scroll_bar): Add GCallback end_callback.
      e5f0bc9a
  19. 27 Nov, 2009 1 commit
    • Jan Djärv's avatar
      Don't crash if an X terminal is deleted with force == t. · ece2d4ed
      Jan Djärv authored
      * xftfont.c (xftfont_end_for_frame): Just return if dpyinfo->display
      is NULL.
      
      * xterm.c (x_delete_terminal): Set dpyinfo->display to NULL.
      
      * frame.c (frame_make_pointer_invisible)
      (frame_make_pointer_visible): Just return if there isn't any selected
      frame.
      ece2d4ed
  20. 24 Nov, 2009 1 commit
  21. 21 Nov, 2009 3 commits
    • Jan Djärv's avatar
      Use a select wrapper around the GLib event loop, thus taking into account GLib · 872870b2
      Jan Djärv authored
      timeouts and event sources.  This simplifies Gtk+-code a lot, and is needed
      for handling GConf death/restart.
      
      * xterm.c: #include xgselect.h.
      (x_initialize): Call xgselect_initialize.
      
      * xsettings.c (something_changedCB): C++ comments => C comments.
      (init_gconf): Do not deal with any GLib file descriptors, xg_select
      does that now.
      
      * gtkutil.c (xg_timer, xg_process_timeouts, xg_start_timer)
      (xg_stop_timer, menu_grab_callback_cnt, menu_grab_callback)
      (scroll_bar_button_cb): Remove.
      (create_menus): C++ comments => C comments. Don't bind grab-notify
      event.
      (xg_create_scroll_bar): Don't bind button-press-event and
      button-release-event.
      
      * process.c: Include xgselect.h if defined (USE_GTK) ||
      defined (HAVE_GCONF).
      (wait_reading_process_output): Call xg_select for the same condition.
      
      * xgselect.c (xg_select): New function to better integrate with
      GLib/Gtk event handling.  Needed if GConf daemon dies/restarts.
      
      * xgselect.h: New file, declare xg_select, xgselect_initialize.
      
      * Makefile.in (XOBJ): Add xgselect.o.
      872870b2
    • Andreas Schwab's avatar
      * character.h (STRING_CHAR, STRING_CHAR_AND_LENGTH): Remove · 62a6e103
      Andreas Schwab authored
      ignored second argument.  All callers changed.
      * regex.c (STRING_CHAR, STRING_CHAR_AND_LENGTH, RE_STRING_CHAR)
      (RE_STRING_CHAR_AND_LENGTH): Likewise.
      * xdisp.c (string_char_and_length): Likewise.
      62a6e103
    • Dan Nicolaescu's avatar
      * xterm.c (x_new_font): · b0ca0f33
      Dan Nicolaescu authored
      * print.c (print_object):
      * cmds.c (Fself_insert_command): Move declarations before statements.
      b0ca0f33
  22. 17 Nov, 2009 1 commit
    • Jan Djärv's avatar
      Handle system default font and changing font parameters. · 637fa988
      Jan Djärv authored
      * xterm.h (struct x_display_info): Add atoms and Window for xsettings.
      
      * xterm.c (handle_one_xevent): Call xft_settings_event for
      ClientMessage, PropertyNotify and DestroyNotify.
      (x_term_init): If we have XFT, get DPI from Xft.dpi.
      Call xsettings_initialize.
      
      * xftfont.c (xftfont_fix_match): New function.
      (xftfont_open): Call XftDefaultSubstitute before XftFontMatch.
      Call xftfont_fix_match after XftFontMatch.
      
      * xfont.c (xfont_driver): Initialize all members.
      
      * xfns.c (x_default_font_parameter): Try font from Ffont_get_system_font.
      Do not get font from x_default_parameter if we got one from
      Ffont_get_system_font.
      (Fx_select_font): Get the defaut font name from :name of FRAME_FONT (f).
      
      * w32font.c (w32font_driver): Initialize all members.
      
      * termhooks.h (enum event_kind): CONFIG_CHANGED_EVENT is new.
      
      * lisp.h: Declare syms_of_xsettings.
      
      * keyboard.c (kbd_buffer_get_event, make_lispy_event): Handle
      CONFIG_CHANGED_EVENT.
      
      * ftfont.c (ftfont_filter_properties): New function.
      
      * frame.c (x_set_font): Remove unused variable lval.
      
      * font.h (struct font_driver): filter_properties is new.
      
      * font.c (font_put_extra): Don't return if val is nil, it means
      boolean option is off.
      (font_parse_fcname): Collect all extra properties in extra_props
      and call filter_properties for all drivers with extra_props and
      font as parameter.
      (font_open_entity): Do not use cache, it does not pick up new fontconfig
      settings like hinting.
      (font_load_for_lface): If spec had a name in it, store it in entity.
      
      * emacs.c (main): Call syms_of_xsettings
      
      * config.in: HAVE_GCONF is new.
      
      * Makefile.in (GCONF_CFLAGS, GCONF_LIBS): New variables for HAVE_GCONF.
      xsettings.o is new.
      
      * menu-bar.el: Put "Use system font" in Option-menu.
      
      * loadup.el: If feature system-font-setting or font-render-setting is
      there, load font-setting.
      
      * Makefile.in (ELCFILES): font-settings.el is new.
      * font-setting.el: New file.
      
      * NEWS: Mention dynamic font changes (font-use-system-font).
      
      * configure.in: New option: --with(out)-gconf.
      Set HAVE_GCONF if we find gconf.
      637fa988
  23. 11 Nov, 2009 1 commit
  24. 06 Nov, 2009 2 commits
    • Jan Djärv's avatar
      Fix bug #4870, issues 3 and 4. · e511451f
      Jan Djärv authored
      * gtkutil.c (xg_event_is_for_scrollbar): New function (bug#4870).
      
      * gtkutil.h: Declare xg_event_is_for_scrollbar (bug#4870).
      
      * xterm.c (handle_one_xevent): Call xg_event_is_for_scrollbar for
      ButtonPressRelease and MotionNotify (bug#4870).
      e511451f
    • Dan Nicolaescu's avatar
      * xterm.c (syms_of_xterm): · d67b4f80
      Dan Nicolaescu authored
      * xselect.c (syms_of_xselect):
      * xmenu.c (syms_of_xmenu):
      * xfns.c (syms_of_xfns):
      * xfaces.c (syms_of_xfaces):
      * xdisp.c (syms_of_xdisp):
      * window.c (syms_of_window):
      * w32fns.c (syms_of_w32fns):
      * undo.c (syms_of_undo):
      * textprop.c (syms_of_textprop):
      * terminal.c (syms_of_terminal):
      * syntax.c (syms_of_syntax):
      * sound.c (syms_of_sound):
      * search.c (syms_of_search):
      * print.c (syms_of_print):
      * minibuf.c (syms_of_minibuf):
      * macros.c (syms_of_macros):
      * keymap.c (syms_of_keymap, initial_define_key)
      (initial_define_lispy_key):
      * keyboard.c (syms_of_keyboard):
      * insdel.c (syms_of_insdel):
      * image.c (syms_of_image):
      * fringe.c (syms_of_fringe):
      * frame.c (syms_of_frame):
      * fontset.c (syms_of_fontset):
      * fns.c (syms_of_fns):
      * fns.c (syms_of_fns):
      * fileio.c (syms_of_fileio):
      * fileio.c (syms_of_fileio):
      * eval.c (syms_of_eval):
      * doc.c (syms_of_doc):
      * dispnew.c (syms_of_display):
      * dired.c (syms_of_dired):
      * dbusbind.c (syms_of_dbusbind):
      * data.c (syms_of_data):
      * composite.c (syms_of_composite):
      * coding.c (syms_of_coding):
      * cmds.c (syms_of_cmds):
      * charset.c (define_charset_internal, syms_of_character):
      * ccl.c (syms_of_ccl):
      * category.c (syms_of_category, init_category_once):
      * casetab.c (syms_of_casetab):
      * casefiddle.c (syms_of_casefiddle):
      * callint.c (syms_of_callint):
      * bytecode.c (syms_of_bytecode):
      * buffer.c (keys_of_buffer, syms_of_buffer):
      * alloc.c (syms_of_alloc):
      * process.c (syms_of_process, init_process):
      * lread.c (syms_of_lread, init_obarray):
      * font.c (build_style_table):
      * emacs.c (syms_of_emacs, main): Replace calls to intern with
      intern_c_string, calls to make_pure_string with
      make_pure_c_string.  Use pure_cons instead of Fcons.
      
      * process.c (socket_options): Make it const.
      (set_socket_option, init_process): Use a const pointer.
      
      * lread.c (intern_c_string): New function.
      (defvar_kboard, defvar_lisp, defvar_lisp_nopro, defvar_bool)
      (defvar_int): Uset it.  Make the name const char*.
      
      * font.c (struct table_entry): Remove unused member.  Make NAMES
      constant.
      (weight_table, slant_table, width_table): Make constant.
      
      * emacs.c (struct standard_args): Make name and longname constant.
      d67b4f80
  25. 21 Oct, 2009 2 commits
    • Jan Djärv's avatar
    • Jan Djärv's avatar
      Fix resize due to font change on a maximized/xmonad-controlled frame. · 5c646d5a
      Jan Djärv authored
      * xterm.h (x_wait_for_event): Declare it.
      
      * xterm.c (pending_event_wait): New variable.
      (handle_one_xevent): Set pending_event_wait.eventtype to 0 if we
      see pending_event_wait.eventtype.
      (handle_one_xevent): Don't change gravity when parent changes.
      (x_new_font): Call change_frame_size with new rows/columns before we try
      to resize the frame.
      (x_wait_for_event): New function.
      (x_set_window_size_1): Don't change gravity unless change_gravity is set.
      Call XResizeWindow with FRAME_OUTER_WINDOW.  If we are visible,
      don't change frame size, instead wait for the ConfigureNotify.
      (x_set_window_size): Call x_set_window_size_1 for USE_X_TOOLKIT also.
      (x_wm_set_size_hint): Remove ifdefs for USE_X_TOOLKIT.
      (x_initialize): Initialize pending_event_wait.
      
      * xmenu.c (set_frame_menubar): Add internal border width to menu bar
      size.
      
      * widget.c (EmacsFrameSetValues): Add comment.
      (EmacsFrameSetCharSize): Just call x_set_window_size.
      
      * gtkutil.c (xg_frame_set_char_size): Flush events and call
      x_wait_for_event.
      (flush_and_sync): Removed again.
      (xg_get_font_name): Suggest monospace if no previous font is known.
      5c646d5a
  26. 20 Oct, 2009 1 commit
  27. 19 Oct, 2009 2 commits