* src/image.c (xpm_scan, xpm_make_color_table_v)
(xpm_put_color_table_v, xpm_get_color_table_v)
(xpm_make_color_table_h, xpm_put_color_table_h)
(xpm_get_color_table_h, xpm_str_to_color_key, xpm_load_image)
(xpm_load): Convert to ANSI C prototypes.
* src/lisp.h (fmod_float): Declare.
* src/menu.h (x_set_menu_bar_line): Declare.
(free_menubar_widget_value_tree et.al): Add HAVE_NS for these functions.
* src/window.c: Include menu.h.
* src/nsfns.m (have_menus_p, ns_display_info_for_name)
(x_set_cursor_type, ns_appkit_version_str)
(ns_appkit_version_int, ns_do_applescript)
(x_set_scroll_bar_default_width, x_sync, compute_tip_xy)
(syms_of_nsfns): Convert to ANSI C prototypes.
* src/nsfont.m (ns_fallback_entity, syms_of_nsfont): Convert to ANSI C
prototypes.
* src/nsimage.m (ns_load_image): Move NSTRACE after declarations.
* src/nsmenu.m (popup_activated, name_is_separator)
(syms_of_nsmenu): Convert to ANSI C prototypes.
(runMenuAt): Prototypes and move declarations before code.
Dan Nicolaescu [Fri, 6 Aug 2010 04:09:54 +0000 (21:09 -0700)]
emacsclient.c cleanups.
* lib-src/emacsclient.c: Move socket related #includes together with the
rest of the #includes. Move a WINDOWSNT includes closer together.
(HAVE_CONFIG_H): Remove.
(NO_RETURN): Remove, defined in config.h.
(main): Convert definition to standard C.
Dan Nicolaescu [Fri, 6 Aug 2010 00:36:12 +0000 (17:36 -0700)]
Cleanup process.c.
* src/process.c: Remove HAVE_SOCKETS #ifdefs inside #ifdef
subprocesses, only MSDOS does not define HAVE_SOCKETS.
(socket_options): Use const char* for name.
Dan Nicolaescu [Thu, 5 Aug 2010 22:20:09 +0000 (15:20 -0700)]
Fix emacs -Q -f server-start & emacsclient -t on GNU/Linux.
* src/term.c (dissociate_if_controlling_tty): Use USG5 instead of
USG. This is equivalent to defined (USG) && !defined (BSD_PGRPS),
which is what was there before BSD_PGRPS was removed.
Michael Albinus [Thu, 5 Aug 2010 08:15:22 +0000 (10:15 +0200)]
* net/tramp.el (tramp-handle-dired-uncache): Flush directory
cache, not only file cache.
(tramp-process-sentinel): New defun.
(tramp-handle-start-file-process): Use it, in order to invalidate
file caches.
Katsumi Yamaoka [Sun, 1 Aug 2010 23:49:32 +0000 (23:49 +0000)]
Fix last nnmail-get-new-mail-1 change that caused double encoding in XEmacs.
2010-08-01 Katsumi Yamaoka <yamaoka@jpl.org>
* nnmail.el (nnmail-get-new-mail-1): Revert.
* nnml.el (nnml-active-number): Make sure names of newly created groups
in nnml-group-alist are encoded.
Jan D [Sun, 1 Aug 2010 13:57:07 +0000 (15:57 +0200)]
Use Gtk+ tooltips by default for Gtk+ Emacs.
* lisp/cus-start.el (x-gtk-use-system-tooltips): New variable.
* src/gtkutil.c (hierarchy_ch_cb, qttip_cb, xg_prepare_tooltip)
(xg_show_tooltip, xg_hide_tooltip, xg_free_frame_widgets): New
functions.
(xg_create_frame_widgets): Set ttip_* to 0. Set a dummy tooltip
text so qttip_cb is called. Connect query-tooltip to qttip_cb.
Remove code that is commented out.
* src/xfns.c (x_gtk_use_system_tooltips): New variable.
(Fx_show_tip): If USE_GTK and x_gtk_use_system_tooltips, call
new gtkutil tooltip functions to show the tooltip.
(Fx_hide_tip): Call xg_hide_tooltip.
(syms_of_xfns): Defvar x-gtk-use-system-tooltips.
Chong Yidong [Sun, 1 Aug 2010 00:38:19 +0000 (20:38 -0400)]
Package listing tweaks.
* emacs-lisp/package.el (package--list-packages): Fix column
alignment.
(package--builtins): Tweak descriptions.
(package-print-package): Upcase descriptions if necessary. Show
all built-in packages in font-lock-builtin-face.
(package-list-packages-internal): Omit "emacs" package. Show
status of built-in packages as "built-in".
Eli Zaretskii [Sat, 31 Jul 2010 15:46:58 +0000 (18:46 +0300)]
Add a Hebrew translation of the tutorial.
etc/tutorials/TUTORIAL.he: New file.
etc/tutorials/TUTORIAL.translators: Add TUTORIAL.he.
lisp/files.el (bidi-paragraph-direction): Define safe local values.
lisp/language/hebrew.el ("Hebrew"): Add TUTORIAL.he to
language-info-alist. Remove outdated FIXME in a comment.
Encode names of nnml groups that nnmail-get-new-mail creates in active file.
2010-07-30 Katsumi Yamaoka <yamaoka@jpl.org>
* nnmail.el (nnmail-get-new-mail-1): Encode group names possibly
containing non-ASCII characters in active file for nnml back end.
Dan Nicolaescu [Thu, 29 Jul 2010 18:34:39 +0000 (11:34 -0700)]
Rename s/usg5-4.h -> s/usg5-4-common.h.
* s/usg5-4.h: Rename file to ...
* src/s/usg5-4-common.h: ... this for consistency with what we do for BSD.
* src/s/unixware.h:
* src/s/sol2-6.h:
* src/s/irix6-5.h: Update includes accordingly.
Jan Djärv [Thu, 29 Jul 2010 16:49:59 +0000 (18:49 +0200)]
Add ability to put Gtk+ tool bar on the left/right/bottom or top. Default top.
* lisp/menu-bar.el (menu-bar-showhide-tool-bar-menu-customize-enable-left)
(menu-bar-showhide-tool-bar-menu-customize-disable)
(menu-bar-showhide-tool-bar-menu-customize-enable-right)
(menu-bar-showhide-tool-bar-menu-customize-enable-top)
(menu-bar-showhide-tool-bar-menu-customize-enable-bottom): New functions
(menu-bar-showhide-tool-bar-menu): If tool bar is moveable,
make a menu for Options => toolbar that can move it.
* src/frame.c (Qtool_bar_position): New variable.
(make_frame): Set tool_bar_position to Qtop.
(frame_parms): Add tool-bar-position.
(x_report_frame_params): Store tool_bar_position.
(x_set_fringe_width): Reset wm size hint after fringe changes.
* src/gtkutil.c (FRAME_TOTAL_PIXEL_WIDTH): New macro.
(xg_frame_set_char_size): Add FRAME_TOOLBAR_WIDTH to pixelwidth.
(xg_height_or_width_changed): Use FRAME_TOTAL_PIXEL_WIDTH.
(xg_create_frame_widgets): Create a hobox for placing widgets
vertically. Use gtk_box_pack_start.
(xg_height_or_width_changed): Renamed from xg_height_changed.
(x_wm_set_size_hint): Add FRAME_TOOLBAR_WIDTH to base_width.
(xg_update_frame_menubar, free_frame_menubar): Change to
xg_height_or_width_changed.
(xg_tool_bar_detach_callback): Update left/right/top/bottom tool bar
size correctly. Remove hardcoded 4, instead use handlebox size -
toolbar size.
(xg_tool_bar_attach_callback): Update left/right/top/bottom tool bar
size correctly. Use handlebox size + toolbar size as additional
size.
(xg_pack_tool_bar): POS is a new parameter.
Set orientation of tool bar based on pos.
Only make handlebox_widget if NULL.
Check if tool bar goes to vbox or hbox depending on pos.
(xg_update_tool_bar_sizes): New function.
(update_frame_tool_bar): Remove old_req, new_req. Do not get tool bar
height, call xg_update_tool_bar_sizes instead.
(free_frame_tool_bar): Remove from hbox or vbox depending on
toolbar_in_hbox, Set all FRAME_TOOLBAR_*_(WIDTH|HEIGHT) to zero.
(xg_change_toolbar_position): New function.
* src/window.c (calc_absolute_offset): Check for FRAME_TOOLBAR_TOP_HEIGHT
and FRAME_TOOLBAR_LEFT_WIDTH.
* src/xfns.c (x_set_tool_bar_position): New function.
(xic_set_statusarea): Use FRAME_TOOLBAR_TOP_HEIGHT.
(x_frame_parm_handlers): Add x_set_tool_bar_position.
(syms_of_xfns): if USE_GTK, provide move-toolbar.
* src/xterm.c (x_set_window_size_1): Add FRAME_TOOLBAR_WIDTH to pixelwidth.
* src/xterm.h (struct x_output): Add toolbar_top_height,
toolbar_bottom_height, toolbar_left_width, toolbar_right_width. Remove
toolbar_height.
if USE_GTK: Add hbox_widget and toolbar_in_hbox.
(FRAME_TOOLBAR_TOP_HEIGHT, FRAME_TOOLBAR_BOTTOM_HEIGHT)
(FRAME_TOOLBAR_LEFT_WIDTH, FRAME_TOOLBAR_RIGHT_WIDTH): New macros.
(FRAME_TOOLBAR_HEIGHT): Is now TOP_HEIGHT + BOTTOM_HEIGHT.
Dan Nicolaescu [Thu, 29 Jul 2010 15:50:04 +0000 (08:50 -0700)]
Make lisp_time_argument work on all systems.
* src/lisp.h (lisp_time_argument): Move declaration ...
* src/systime.h (lisp_time_argument): ... here
* src/editfns.c (lisp_time_argument): Remove declaration. (Bug#6751)
Michael Albinus [Thu, 29 Jul 2010 13:13:11 +0000 (15:13 +0200)]
* net/tramp.el (tramp-handle-start-file-process): Check only for
`remote-tty' process property.
(tramp-open-shell): Don't check for tty.
(tramp-open-connection-setup-interactive-shell): Set `remote-tty'
process property.
* progmodes/gdb-mi.el (gdb-init-1): Check also for tty on a remote
host.
Dan Nicolaescu [Thu, 29 Jul 2010 05:58:58 +0000 (22:58 -0700)]
* src/mem-limits.h: Remove duplicated includes.
(NULL): Remove definition, unused.
(POINTER): Remove definition.
(start_of_data): Use char* in prototype, as the function
definition does.
Phil Hagelberg [Wed, 28 Jul 2010 18:54:42 +0000 (14:54 -0400)]
Add support for non-default package repositories.
* lisp/emacs-lisp/package.el (package-archive-base): Var deleted.
(package-archives): New variable.
(package-archive-contents): Doc fix.
(package-load-descriptor): Do nothing if descriptor file is
missing.
(package--write-file-no-coding): New function.
(package-unpack-single): Use it.
(package-archive-id): New function.
(package-download-single, package-download-tar)
(package-menu-view-commentary): Use it.
(package-installed-p): Make second argument optional.
(package-read-all-archive-contents): New function.
(package-initialize): Use it.
(package-read-archive-contents): Add ARCHIVE argument.
(package--add-to-archive-contents): New function.
(package-install): Don't call package-read-archive-contents.
(package--download-one-archive): Store archive file in a
subdirectory of package-user-dir.
(package-menu-execute): Remove spurious line movement.
* lisp/emacs-lisp/package.el (package-load-list, package-archives)
(package-archive-contents, package-user-dir)
(package-directory-list, package--builtins, package-alist)
(package-activated-list, package-obsolete-alist): Mark as risky.
Michael Albinus [Wed, 28 Jul 2010 10:02:18 +0000 (12:02 +0200)]
* net/tramp.el (tramp-methods): Move hostname to the end in all
ssh `tramp-login-args'.
(tramp-verbose): Describe verbose level 9.
(tramp-open-shell): Check for tty if `tramp-verbose' >= 9.
(tramp-open-connection-setup-interactive-shell): Trace stty
settings if `tramp-verbose' >= 9.
(tramp-handle-start-file-process): Implement tty setting.
(Bug#4604, Bug#6360)
* net/tramp-cmds.el (tramp-bug): Recommend setting of
`tramp-verbose' to 9.