1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-02-04 22:50:59 -08:00
Commit graph

33786 commits

Author SHA1 Message Date
Eli Zaretskii
24becea4a7 Fix cursor display when several display strings follow each other.
src/xdisp.c (set_cursor_from_row): Skip step 2 only if point is not
 between bpos_covered and bpos_max.  This fixes cursor display when
 several display strings follow each other.
2012-11-23 10:27:05 +02:00
Eli Zaretskii
8654a41b44 Fix pgx in .gdbinit when CHECK_LISP_OBJECT_TYPE is defined.
src/.gdbinit (pgx): If the glyph's object is a string, display the
 pointer to string data, rather than the value of the string object
 itself (which barfs under CHECK_LISP_OBJECT_TYPE).
2012-11-23 09:54:33 +02:00
Eli Zaretskii
cb5867b1f8 Fix bug #12930 with vertical-motion through a display string.
src/indent.c (Fvertical_motion): If the starting position is covered
 by a display string, return to one position before that, to avoid
 overshooting it inside move_it_to.
2012-11-21 21:28:14 +02:00
Daniel Colascione
a16ac13f62 Backport: Rename cygwin_convert_path* to cygwin_convert_file_name* 2012-11-20 11:28:53 -08:00
Ken Brown
4ffea44780 Fix non-GTK builds on Cygwin
* src/emacs.c (main): Set the G_SLICE environment variable for all
  Cygwin builds, not just GTK builds.  See
  https://lists.gnu.org/archive/html/emacs-devel/2012-11/msg00368.html.
2012-11-20 08:26:40 -05:00
Eli Zaretskii
88c4a13c3b More fixes for bug #12878 with MS-Windows MSVC build.
src/xdisp.c (start_hourglass) [HAVE_NTGUI]: Don't mix declaration of
 w32_note_current_window with code.  (Backport from trunk.)
 src/w32.c (FILE_DEVICE_FILE_SYSTEM, METHOD_BUFFERED)
 (FILE_ANY_ACCESS, CTL_CODE, FSCTL_GET_REPARSE_POINT) [_MSC_VER]:
 Define for the MSVC compiler.
 src/w32term.h (EnumSystemLocalesW) [_MSC_VER]: Add a missing
 semi-colon.

 nt/inc/stdint.h (PTRDIFF_MIN) [!__GNUC__]: Define for MSVC.
2012-11-19 19:34:21 +02:00
Eli Zaretskii
273ac8d1ef Prevent crashes on MS-Windows when w32-downcase-file-names is non-nil.
src/fileio.c (Fsubstitute_in_file_name, Ffile_name_directory)
 (Fexpand_file_name) [DOS_NT]: Pass encoded file name to
 dostounix_filename.  Prevents crashes down the road, because
 dostounix_filename assumes it gets a unibyte string.  Reported by
 Michel de Ruiter <michel@sentient.nl>, see
 http://lists.gnu.org/archive/html/help-emacs-windows/2012-11/msg00017.html
2012-11-18 18:43:36 +02:00
Eli Zaretskii
d8715cdf90 Fix bug #12878 with compilation failure with Visual C++ 11.0.
src/w32select.c: Include w32common.h before w32term.h, so that
 windows.h gets included before w32term.h uses some of its
 features, see below.
 src/w32term.h (LOCALE_ENUMPROCA, LOCALE_ENUMPROCW) [_MSC_VER]: New
 typedefs.
 (EnumSystemLocalesA, EnumSystemLocalesW) [_MSC_VER]: New
 prototypes.
 (EnumSystemLocales) [_MSC_VER]: Define if undefined.
2012-11-17 20:51:06 +02:00
Jan Djärv
7436fc63c0 * nsterm.m (hold_event): Set send_appdefined to YES.
(ns_select): Return at once if events are held (Bug#12834).
2012-11-17 16:28:56 +01:00
enami tsugutomo
86dcf21c07 * src/unexelf.c (ELFSIZE) [__NetBSD__ && _LP64]: Set to 64
Needed following 2012-10-20 change.

Fixes: debbugs:12902
2012-11-16 13:41:00 -05:00
Glenn Morris
d56f2e49b2 * src/editfns.c (Fmessage): Mention message-log-max. (Bug#12849) 2012-11-15 21:40:54 -05:00
Stefan Monnier
5c2a71483b * src/eval.c (Finteractive_p): Revert lexbind-merge mishap. 2012-11-15 12:17:23 -05:00
Glenn Morris
bde3c6c0f7 Fixes related to face underlining
* lisp/faces.el (face-underline-p): Doc fix.  Handle :underline being
things other than `t' (a string, a list).
(face-inverse-video-p): Doc fix.
(set-face-underline): Rename it back from set-face-underline-p.
Doc fix.  Allow interactive input of values other than t.
(read-face-attribute): Apply formatting to :underline,
since like :box and :stipple it can take list values.

* doc/lispref/display.texi (Face Attributes): Fix :underline COLOR description.
(Attribute Functions): Update for set-face-underline rename.
Tweak descriptions of face-underline-p, face-inverse-video-p.

* etc/NEWS: Related edit.
2012-11-14 23:30:46 -08:00
Eli Zaretskii
730b2d8f6b Clean up w32 timer thread code in the hope of solving bug #12832.
src/w32proc.c (timer_loop): Make sure SuspendThread and ResumeThread
 use the same value of thread handle.
 (start_timer_thread): If the timer thread exited (due to error),
 clean up by closing the two handles it used.  Duplicate the caller
 thread's handle here, so it gets duplicated only once, when
 launching the timer thread.  Set priority of the timer thread, not
 the caller thread.
 (getitimer): Don't duplicate the caller thread's handle here.
2012-11-14 18:41:43 +02:00
Jan Djärv
f99c65e574 * nsterm.m (hold_event): Send SIGIO to make sure ns_read_socket is
called.

Fixes: debbugs:12834
2012-11-13 08:56:15 +01:00
Eli Zaretskii
3252027325 Fix bug #12867 with crashes due to large field width in mode-line format.
src/xdisp.c (decode_mode_spec): Limit the value of WIDTH argument
 passed to pint2str and pint2hrstr to be at most the size of the
 frame's decode_mode_spec_buffer.  This avoids crashes with very
 large values of FIELD_WIDTH argument to decode_mode_spec.
2012-11-12 17:25:34 +02:00
Martin Rudalics
fdaf534a7b Fix and rewrite doc on window recombining facilities.
* window.c (Fsplit_window_internal): Set combination limit of
new parent window to t iff Vwindow_combination_limit is t;
fixing a regression introduced with the change from 2012-09-22.
(Fwindow_combination_limit, Fset_window_combination_limit): Fix
doc-strings.

* elisp.texi (Top): Add Recombining Windows to menu.
* windows.texi (Recombining Windows): New subsection.
(Splitting Windows): Rewrite text on handling of window
combinations and move it to new subsection.
2012-11-07 10:41:52 +01:00
Eli Zaretskii
acf93bcf19 Fix bug #12811 with scrolling under scroll-up/down-aggressively.
src/xdisp.c (try_scrolling): Fix correction of aggressive-scroll
 amount when the scroll margins are too large.  When scrolling
 backwards in the buffer, give up if cannot reach point or the
 scroll margin within a reasonable number of screen lines.  Fixes
 point position in window under scroll-up/down-aggressively when
 point is positioned many lines beyond the window top/bottom.
2012-11-06 18:36:02 +02:00
Eli Zaretskii
508f51f5f4 Fix bug #12774 with crashes in ralloc.c.
src/ralloc.c (relinquish): If real_morecore fails to return memory
 to the system, don't crash; instead, leave the last heap
 unchanged and return.
2012-11-05 19:23:25 +02:00
Eli Zaretskii
858f0f24b1 Adapt MSDOS port to latest changes.
config.bat: Copy lib/execinfo.in.h to lib/execinfo.in-h if needed.

 msdos/sedlibmk.inp: Sync with changes in lib/Makefile.in.
 (HAVE_DECL_ENVIRON, GNULIB_ENVIRON): Edit to require declaration
 through lib/unistd.h.
 msdos/sed1v2.inp: Sync with changes in src/Makefile.in.
 msdos/sed2v2.inp: Sync with changes in src/config.in.

 src/lisp.mk: Adjust comments to the fact that term/internal is now
 loaded from loadup.el.
 src/msdos.c (msdos_abort): Rename from emacs_abort, and make static.
 (msdos_fatal_signal): New function.
 (XMenuActivate): Adjust the call to kbd_buffer_events_waiting to
 its argument list.
 src/conf_post.h (_GL_EXECINFO_INLINE) [MSDOS]: Define to "inline"
 for GCC versions before 4.
 (emacs_raise): Define to call msdos_fatal_signal.

 lisp/term/pc-win.el: Don't load term/internal from here.
 lisp/loadup.el: Load term/internal from here.
2012-11-03 15:58:33 +02:00
Eli Zaretskii
1d4341f988 Load term/internal from loadup.el. 2012-11-03 15:56:02 +02:00
Eli Zaretskii
b3cf17f695 Adapt the MSDOS build to the latest changes on mainline. 2012-11-03 15:48:33 +02:00
Jan Djärv
ad10696b89 Backport from trunk.
* widget.c (resize_cb): New function.
(EmacsFrameRealize): Add resize_cb as event handler.
(EmacsFrameResize): Check if all is up to date before changing frame
size.

Fixes: debbugs:12733
2012-11-03 12:33:28 +01:00
Eli Zaretskii
67b50ba47b Fix bidi initialization in init_from_display_pos.
src/xdisp.c (init_from_display_pos): Fix initialization of the bidi
 iterator when starting in the middle of a display or overlay
 string.

Fixes: debbugs:12745
2012-11-03 11:25:34 +02:00
Eli Zaretskii
7e8b50d9e5 Fix MS-Windows build broken by fixing bug #12776 on Posix platforms.
src/w32proc.c (getpgrp, setpgid): New functions.

 nt/inc/unistd.h (setpgid, getpgrp): Provide prototypes.
 nt/config.nt (GETPGRP_VOID): Define to 1.
2012-11-01 16:21:45 +02:00
Paul Eggert
5c6ce1c7d0 Spelling fixes. 2012-10-31 12:23:06 -07:00
Paul Eggert
322aea6ddf Fix crash when using Emacs as commit editor for git.
* callproc.c (setpgrp): Remove macro, as we now use setpgid
and it is configured in conf_post.h.
(Fcall_process): Don't invoke both setsid and setpgid; the former
is enough, if it exists.
* callproc.c (Fcall_process, child_setup):
* process.c (create_process): Use setpgid.
* conf_post.h (setpgid) [!HAVE_SETPGID]: New macro, which substitutes
for the real thing.
* dispnew.c (init_display): Initialize the foreground group
if we are running a tty display.
* emacs.c (main): Do not worry about setpgrp; init_display does it now.
* lisp.h (init_foreground_group): New decl.
* sysdep.c (inherited_pgroup): New static var.
(init_foreground_group, tcsetpgrp_without_stopping)
(narrow_foreground_group, widen_foreground_group): New functions.
(init_sys_modes): Narrow foreground group.
(reset_sys_modes): Widen foreground group.

Fixes: debbugs:12697
2012-10-31 10:27:29 -07:00
Michael Albinus
220cb2bd70 * dbusbind.c: Fix cut'n'waste error. Use HAVE_DBUS_VALIDATE_INTERFACE. 2012-10-31 12:45:40 +01:00
Martin Rudalics
218e997a10 Install fixes for Bug#12764 and Bug#12766.
* window.el (quit-restore-window): If the window has been
created on an existing frame and ended up as the sole window on
that frame, do not delete it (Bug#12764).

* minibuf.c (read_minibuf): Restore current buffer since
choose_minibuf_frame calling Fset_frame_selected_window may
change it (Bug#12766).
2012-10-31 11:02:51 +01:00
Jan Djärv
02615da072 * frame.c (Fframe_pixel_height): Fix documentation.
Fixes: debbugs:12733
2012-10-30 19:28:48 +01:00
Kenichi Handa
6ccc848cd8 merge trun 2012-10-30 20:38:37 +09:00
Kenichi Handa
aee5b18ec3 font.c (Ffont_at): If WINDOW is specified and it is not displaying the current buffer, signal an error. 2012-10-30 20:14:15 +09:00
Daniel Colascione
53372c278e Complete fix for build break 2012-10-29 19:10:52 -08:00
Daniel Colascione
7f590b0c3b Fix build break in non-Cygw32 Cygwin builds introduced in 2012-10-29T17:24:29Z!dancol@dancol.org. 2012-10-29 17:56:38 -08:00
Daniel Colascione
ba11600816 2012-10-29 Daniel Colascione <dancol@dancol.org>
cygw32.h, cygw32.c (Qutf_16le, from_unicode, to_unicode): In
preparation for fixing bug#12739, move these functions from
here...

* coding.h, coding.c: ... to here, and compile them only when
WINDOWSNT or HAVE_NTGUI.  Moving these functions out of cygw32
proper lets us write cygw32-agnostic code for the HAVE_NTGUI case.
2012-10-29 09:24:29 -08:00
Eli Zaretskii
640bf8ad44 Don't use CLOCKS_PER_SEC in w32 timers.
src/w32proc.c (TIMER_TICKS_PER_SEC): New macro.
 (timer_loop, getitimer, setitimer): Use it instead of
 CLOCKS_PER_SEC, which is no longer pertinent, since we don't use
 'clock'.
 (w32_get_timer_time): Use 10*TIMER_TICKS_PER_SEC instead of a
 literal 10000.
2012-10-28 19:42:52 +02:00
Jan Djärv
64ccff5f0e * nsterm.m (NO_APPDEFINED_DATA): New define.
(last_appdefined_event_data): New variable
(last_appdefined_event): Remove.
(ns_select): Initialize t from last_appdefined_event_data instead
of [last_appdefined_event data1].
(sendEvent:): Save [theEvent data1] to last_appdefined_event_data,
remove last_appdefined_event.

Fixes: debbugs:12698
2012-10-28 17:10:06 +01:00
Stefan Monnier
e483264ca5 * src/frame.c (x_set_font): Catch internal error. 2012-10-28 11:52:42 -04:00
Eli Zaretskii
2f246cd3c8 Fix compiler warnings in w32proc.c.
src/w32proc.c (sys_spawnve): Avoid compiler warning about format mismatch.
 (timer_loop): Remove unused variable.
2012-10-27 21:43:48 +02:00
Eli Zaretskii
2e612797ce Use 'volatile' types for communications between timer thread and main thread. 2012-10-27 21:32:30 +02:00
Eli Zaretskii
15cc05e984 Fix a typo in a comment. 2012-10-27 21:20:02 +02:00
Eli Zaretskii
6c16c13ed1 Fix w32 implementation of itimers: overflow and ITIMER_PROF.
Avoid overflow in w32 implementation of interval timers.  When
 possible, for ITIMER_PROF count only times the main thread
 actually executes.

 src/w32proc.c <struct itimer_data>: 'expire' and 'reload' are now
 ULONGLONG types.  Likewise for all the other data which was
 previously clock_t.
 (GetThreadTimes_Proc): New typedef.
 (w32_get_timer_time): New function, returns a suitable time value
 for the timer.
 (timer_loop): Enter critical section when accessing ULONGLONG
 values of the itimer_data struct, as these accesses are no longer
 atomic.  Call 'w32_get_timer_time' instead of 'clock'.
 (init_timers): Initialize s_pfn_Get_Thread_Times.
 (start_timer_thread): Don't assign itimer->caller_thread here.
 (getitimer): Assign itimer->caller_thread here.
 (setitimer): Always call getitimer to get the value of ticks_now.
2012-10-27 13:21:26 +02:00
Eli Zaretskii
ccc83f50a4 Avoid hourglass mouse pointer when a tooltip for menu item is shown.
src/w32fns.c (w32_wnd_proc) <WM_MOUSEMOVE>: Don't enable tracking of
 mouse movement events if the menu bar is active.  This avoids
 producing a busy "hour-glass" cursor by Windows if the mouse
 pointer is positioned over a tooltip shown for some menu item.
2012-10-26 11:46:46 +02:00
Paul Eggert
69deda53a8 Don't assume process IDs fit in int.
* emacs.c (shut_down_emacs) [!DOS_NT]:
* sysdep.c (sys_suspend) [SIGTSTP && !MSDOS]:
* term.c (dissociate_if_controlling_tty) [!DOS_NT]:
Use pid_t, not int, to store process IDs, as 'int'
is not wide enough on a few platforms (e.g., AIX and IRIX).
2012-10-24 21:35:39 -07:00
Kenichi Handa
6a8f819329 merge trunk 2012-10-24 00:47:51 +09:00
Kenichi Handa
7e70a15287 Make face-font-rescale-alist work correctly for non-ASCII fonts. 2012-10-24 00:42:29 +09:00
Chong Yidong
49238e7f5c Make unused variable font-list-limit obsolete, and move it out of C.
* display.texi (Font Lookup): Remove font-list-limit.

* lisp/startup.el (command-line):
* lisp/cus-start.el: Don't refer to font-list-limit.

* lisp/faces.el (font-list-limit): Define as an obsolete variable.

* xfaces.c (Vfont_list_limit): Move unused variable to faces.el.
2012-10-23 10:39:13 +08:00
Jan Djärv
ef44695952 * nsfont.m (nsfont_open, ns_glyph_metrics): Force integer advancement
for screen font.
(nsfont_draw): Turn off LCD-smoothing.

Fixes: debbugs:11484
2012-10-21 20:48:11 +02:00
Jan Djärv
5ec86886a7 * xterm.c (x_focus_changed): Check if daemonp when sending focus in
event.

Fixes: debbugs:12681
2012-10-21 16:53:28 +02:00
Paul Eggert
791ef5f8ea Spelling fixes. 2012-10-21 00:23:34 -07:00