* atimer.c (start_atimer): Use EMACS_TIME, not struct timeval.
* sysdep.c (set_file_times): Use EMACS_TIME, not struct timeval.
* xgselect.c (xg_select): Use SELECT_TYPE, EMACS_TIME.
* dired.c (file_name_completion_stat): Use DIRENTRY, not struct dirent.
* fileio.c (read_non_regular, read_non_regular_quit): Pass Lisp_Object,
as required by internal_condition_case_1.
* regex.c (bcmp_translate): Use RE_TRANSLATE_TYPE, not Lisp_Object.
(analyse_first): Fix "const const".
Michael Albinus [Sun, 4 Jul 2010 09:52:57 +0000 (11:52 +0200)]
* net/dbus.el: Implement signal "PropertiesChanged" (from D-Bus 1.3.1).
(dbus-register-property): New optional argument EMITS-SIGNAL.
(dbus-property-handler): Send signal "PropertiesChanged" if requested.
Dan Nicolaescu [Sun, 4 Jul 2010 05:47:55 +0000 (22:47 -0700)]
Convert function definitions in lwlib files to standard C.
* lwlib/lwlib-Xaw.c: Convert function definitions to standard C.
* lwlib/lwlib-Xlw.c:
* lwlib/lwlib-utils.c:
* lwlib/lwlib.c:
* lwlib/lwlib.h:
* lwlib/xlwmenu.c: Likewise.
Eli Zaretskii [Sat, 3 Jul 2010 14:42:02 +0000 (17:42 +0300)]
Fix menu bar and colors on MS-DOS.
msdos.c (IT_set_frame_parameters): Set menu-bar-lines
according to menu-bar-mode, if not set in the frame parameters
or in default-frame-alist. Fix setting of colors in frames
other than the initial one. Fix reversal of colors when
`reverse' is specified in the frame parameters. Call
update_face_from_frame_parameter instead of
internal-set-lisp-face-attribute. Initialize screen colors
from initial_screen_colors[] when f->default_face_done_p is
zero, instead of depending on being called with
default-frame-alist as the alist argument.
xfaces.c (update_face_from_frame_parameter): Move out of
HAVE_WINDOW_SYSTEM portion. Condition window-system only parts
with HAVE_WINDOW_SYSTEM.
Eli Zaretskii [Sat, 3 Jul 2010 14:36:18 +0000 (17:36 +0300)]
Fix setting colors on MS-DOS frames.
msdos.c (IT_set_frame_parameters): Fix setting of colors in
frames other than the initial one. Fix reversal of colors when
`reverse' is specified in the frame parameters. Call
update_face_from_frame_parameter instead of
internal-set-lisp-face-attribute. Initialize screen colors from
initial_screen_colors[] when f->default_face_done_p is zero,
instead of depending on being called with default-frame-alist as
the alist argument.
xfaces.c (update_face_from_frame_parameter): Move out of
HAVE_WINDOW_SYSTEM portion. Condition window-system only parts
with HAVE_WINDOW_SYSTEM.
* lib-src/ebrowse.c (match_qualified_namespace_alias):
Pass sym* to find_namespace, not link*.
* lib-src/emacsclient.c (send_to_emacs, quote_argument): Arg s is HSOCKET.
* lib-src/sorted-doc.c (qsort_compare): New typedef.
(main): Use it to cast cmpdoc.
Simplify mouse-dragging implementation.
Now that DEL deletes active regions, we can handle it by using the
ordinary region instead of a separate overlay.
* mouse.el (mouse-drag-overlay): Variable deleted.
(mouse-move-drag-overlay, mouse-show-mark): Functions deleted.
(mouse--remap-link-click-p): New function.
(mouse-drag-track): Handle dragging by using temporary Transient
Mark mode, instead of a special overlay.
(mouse-kill-ring-save, mouse-save-then-kill): Don't call
mouse-show-mark.
Dan Nicolaescu [Sat, 3 Jul 2010 00:50:23 +0000 (17:50 -0700)]
Convert function definitions to standard C.
* lib-src/update-game-score.c: Convert function definitions to standard C.
* lib-src/sorted-doc.c:
* lib-src/profile.c:
* lib-src/pop.c:
* lib-src/movemail.c:
* lib-src/make-docfile.c:
* lib-src/hexl.c:
* lib-src/fakemail.c:
* lib-src/etags.c:
* lib-src/ebrowse.c:
* lib-src/digest-doc.c:
* lib-src/b2m.c: Likewise.
Juri Linkov [Fri, 2 Jul 2010 22:28:52 +0000 (01:28 +0300)]
* lisp/faces.el (read-face-name): Rename arg `string-describing-default'
to `default'. Doc fix. Display the default value in quotes
in the prompt. With empty input, return the `default' arg,
unless the default value is a string (in which case return nil).
(describe-face): Replace the string `default' arg of `read-face-name'
with the symbol `default'.
http://lists.gnu.org/archive/html/emacs-devel/2010-06/msg01109.html
Dan Nicolaescu [Fri, 2 Jul 2010 22:18:28 +0000 (15:18 -0700)]
Convert some prototypes to standard C.
* lib-src/make-docfile.c (xmalloc, xrealloc, concat, readline, fatal):
* lib-src/b2m.c (scan_file, scan_lisp_file, scan_c_file): Convert to
standard C prototypes.
* src/term.c (term_clear_mouse_face, Fidentity):
* src/syssignal.h (signal_handler_t):
* src/lisp.h (memory_warnings):
* src/coding.h (preferred_coding_system):
* src/cm.h (evalcost):
* src/blockinput.h (reinvoke_input_signal): Convert to standard C prototypes.
Dan Nicolaescu [Fri, 2 Jul 2010 08:11:24 +0000 (01:11 -0700)]
Define USE_LISP_UNION_TYPE using autoconf.
* configure.in (--enable-use-lisp-union-type): New flag.
* src/lisp.h: Document that USE_LISP_UNION_TYPE is now enabled using autoconf.
Dan Nicolaescu [Fri, 2 Jul 2010 07:05:09 +0000 (00:05 -0700)]
Cleanup old code.
* src/dired.c (BSD4_3): Remove all uses, redundant with BSD4_2.
* src/syssignal.h: Remove code for Lynx, not supported anymore.
* src/vm-limit.c: Remove unused code the depends on emacs not being
defined and NO_LIM_DATA being defined.
* src/mem-limits.h: Remove dead code.
2010-07-01 Mark A. Hershberger <mah@everybody.org>
* url-http.el (url-http-create-request): Add a CRLF on the end so
that POSTs with content to https urls work. See
<https://bugs.launchpad.net/mediawiki-el/+bug/540759>
Prior to this, the following request would not terminate:
Fix application of default-frame-alist (Bug#5378).
* lisp/frame.el (make-frame): Add default-frame-alist to the PARAMETERS
argument passed to frame-creation-function (Bug#5378).
* lisp/faces.el (x-handle-named-frame-geometry)
(x-handle-reverse-video, x-create-frame-with-faces)
(face-set-after-frame-default, tty-create-frame-with-faces): Don't
separately consult default-frame-alist. It is now passed as the
PARAMETER argument.
Chong Yidong [Wed, 30 Jun 2010 22:43:52 +0000 (18:43 -0400)]
Don't always set ruler-mode-header-line-format-old (Bug#5370).
* ruler-mode.el (ruler--save-header-line-format): New fun.
(ruler-mode): Use it as a setter function, so as not to overwrite
ruler-mode-header-line-format-old if Ruler mode is on (Bug#5370).
Dan Nicolaescu [Wed, 30 Jun 2010 05:51:07 +0000 (22:51 -0700)]
Fix CFLAGS for non-GCC compilers.
* configure.in (CFLAGS): Always use -g like it was done before the
2010-03-30 change.
(REAL_CFLAGS): Use CFLAGS for non-GCC to get optimization flags. (Bug#6538)
Glenn Morris [Wed, 30 Jun 2010 02:48:54 +0000 (19:48 -0700)]
Remove some cpp that is internal to configure.in.
* configure.in (C_OPTIMIZE_SWITCH, CANNOT_DUMP, SYSTEM_MALLOC):
(USE_MMAP_FOR_BUFFERS, C_WARNING_SWITCH): Set with shell, not cpp.
(LIBX): Remove, just use -lX11 in the one place this was used.
(cannot_dump): Replace with CANNOT_DUMP.
* src/Makefile.in (CANNOT_DUMP): Update for configure name change.
Chong Yidong [Tue, 29 Jun 2010 18:17:31 +0000 (14:17 -0400)]
Allow global VC ops like `C-x v D' in Diff and Log-View buffers.
* vc/diff-mode.el (diff-vc-backend): New var.
* vc/vc.el (vc-deduce-backend): New fun. Handle diff buffers.
(vc-root-diff, vc-print-root-log, vc-log-incoming)
(vc-log-outgoing): Use it.
(vc-diff-internal): Set diff-vc-backend.
Jan D [Mon, 28 Jun 2010 10:11:26 +0000 (12:11 +0200)]
Use non-deprecated Gtk+ functions, add changes for Gtk+3 with GSEAL_ENABLE.
* 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.
* 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.
Chong Yidong [Sun, 27 Jun 2010 00:30:52 +0000 (20:30 -0400)]
Change default-frame-alist and menu/tool-bar-mode interaction (Bug#2249).
Don't add entries for `menu-bar-lines' and `tool-bar-lines' to
`default-frame-alist' and `initial-frame-alist' at startup.
Instead, use X resources to update the `menu-bar-mode' and
`tool-bar-mode' variables at startup, and use them as defaults during
frame creation.
* lisp/frame.el (frame-notice-user-settings): Don't change
default-frame-alist based on menu-bar-mode and tool-bar-mode, or
vice versa.
* lisp/menu-bar.el (menu-bar-mode):
* lisp/tool-bar.el (tool-bar-mode): Don't change default-frame-alist.
Set init-value to t.
* lisp/startup.el (command-line): Use X resources to set the value of
menu-bar-mode and tool-bar-mode, before calling frame-initialize.
* src/frame.c (Vmenu_bar_mode, Vtool_bar_mode): New vars.
* src/xfns.c (Fx_create_frame): Don't consult X resouces when setting
menu-bar-lines and tool-bar-lines. Use menu-bar-mode and
tool-bar-mode, which are now set using these X resources at
startup, to determine the defaults.
Eli Zaretskii [Sat, 26 Jun 2010 14:36:27 +0000 (17:36 +0300)]
Fix the MS-DOS build due to changes in configury.
config.bat: Remove white space around "+" in COPY commands.
msods/mainmake.v2 (version): Use emacs_version[] in src/emacs.c
instead of lisp/version.el (see 2010-05-15T21:11:37Z!raeburn@raeburn.org).
msdos/sed1v2.inp (MKDEPDIR): Edit to empty.
Delete lines in rules that invoke $(MKDEPDIR).
Fix editing rules that begin with "cd ../lisp".
Edit out sh if-then-else-fi constructs that test ${CANNOT_DUMP}.
Edit out "|| exit ;\" constructs in emacs${EXEEXT} rule.
* org-agenda.el (org-agenda-goto-calendar): Do not bind obsolete
variables.
* org.el (calendar): Require calendar now on top level in org.el
and define aliases to new variables when needed.
(org-read-date, org-goto-calendar): Do not bind obsolete
variables.
Chong Yidong [Fri, 25 Jun 2010 19:24:05 +0000 (15:24 -0400)]
Change initial-frame-alist and default-frame-alist defaults (Bug#2249).
Since the menu-bar and tool-bar are now unconditionally turned on by
default, we can let the defcustom defaults reflect that.
* frame.el (initial-frame-alist): Give default value entries for
menu-bar-lines and tool-bar-lines consistent with the startup
default (Bug#2249).
* frame.c (Vdefault_frame_alist): Give default value entries for
menu-bar-lines and tool-bar-lines consistent with the startup
default (Bug#2249).
Jan Djärv [Tue, 22 Jun 2010 12:28:08 +0000 (14:28 +0200)]
Hide scroll bar when window is too small to avoid Gtk+ warning.
* 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.
Karl Fogel [Mon, 21 Jun 2010 23:26:46 +0000 (19:26 -0400)]
* lisp/simple.el (compose-mail): Fix doc string to refer to
`compose-mail-user-agent-warnings', instead of to the
nonexistent `compose-mail-check-user-agent'.
Alan Mackenzie [Mon, 21 Jun 2010 21:08:26 +0000 (21:08 +0000)]
Fix an indentation bug:
progmodes/cc-mode.el (c-common-init): Initialise c-new-BEG/END.
(c-neutralize-syntax-in-and-mark-CPP): c-new-BEG/END: Take account
of existing values.
progmodes/cc-engine.el (c-clear-<-pair-props-if-match-after)
(c-clear->-pair-props-if-match-before): now return t when they've cleared
properties, nil otherwise.
(c-before-change-check-<>-operators): Set c-new-beg/end correctly by
taking account of the existing value.
progmodes/cc-defs.el (c-clear-char-property-with-value-function): Fix
this to clear the property rather than overwriting it with nil.
Eli Zaretskii [Sun, 20 Jun 2010 18:04:30 +0000 (21:04 +0300)]
Avoid recentering when lines differ in their height.
xdisp.c (try_scrolling): When scroll-conservatively is set to
most-positive-fixnum, be extra accurate when scrolling window
start, to avoid missing the cursor line.
Chong Yidong [Sun, 20 Jun 2010 04:55:14 +0000 (00:55 -0400)]
Tweaks to package list UI.
* help-mode.el (help-package): New button type.
* emacs-lisp/package.el (package-print-package): Add link to
package description via describe-package.
(describe-package-1): List package requirements. Add button to
perform installation.
(package-menu-describe-package): New command.