diff options
| author | Karoly Lorentey | 2005-02-04 15:36:07 +0000 |
|---|---|---|
| committer | Karoly Lorentey | 2005-02-04 15:36:07 +0000 |
| commit | 077f3dd9e0510164a37dcdfa69db9fe0b48675d9 (patch) | |
| tree | 6e117d59746e46bf69ee1c8cf0b71521d672f783 | |
| parent | 44d7460c77fa0c27513944bb8b6f819976b01cda (diff) | |
| parent | e67d06eb0d71b8d769b467a8cea28aa8d761a906 (diff) | |
| download | emacs-077f3dd9e0510164a37dcdfa69db9fe0b48675d9.tar.gz emacs-077f3dd9e0510164a37dcdfa69db9fe0b48675d9.zip | |
Merged from miles@gnu.org--gnu-2005 (patch 76-78)
Patches applied:
* miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-76
Update from CVS
* miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-77
Update from CVS
* miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-78
Update from CVS
git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-288
| -rw-r--r-- | lisp/ChangeLog | 24 | ||||
| -rw-r--r-- | lisp/calc/calc-embed.el | 15 | ||||
| -rw-r--r-- | lisp/calc/calc-lang.el | 29 | ||||
| -rw-r--r-- | lisp/help-fns.el | 1 | ||||
| -rw-r--r-- | lisp/international/mule-cmds.el | 9 | ||||
| -rw-r--r-- | lisp/textmodes/ispell.el | 5 | ||||
| -rw-r--r-- | man/ChangeLog | 4 | ||||
| -rw-r--r-- | man/frames.texi | 12 | ||||
| -rw-r--r-- | src/ChangeLog | 31 | ||||
| -rw-r--r-- | src/dispnew.c | 5 | ||||
| -rw-r--r-- | src/gtkutil.c | 2 | ||||
| -rw-r--r-- | src/mac.c | 2 | ||||
| -rw-r--r-- | src/macfns.c | 2 | ||||
| -rw-r--r-- | src/macterm.c | 6 | ||||
| -rw-r--r-- | src/xfaces.c | 8 | ||||
| -rw-r--r-- | src/xfns.c | 8 | ||||
| -rw-r--r-- | src/xmenu.c | 17 |
17 files changed, 136 insertions, 44 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index c7ab3fb44ae..81daee7d7b5 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,27 @@ | |||
| 1 | 2005-02-04 Jay Belanger <belanger@truman.edu> | ||
| 2 | |||
| 3 | * calc/calc-embed.el (calc-embedded-update): Don't put in | ||
| 4 | unnecessary newlines. Adjust the end of formula marker. | ||
| 5 | |||
| 6 | * calc/calc-lang.el (math-latex-parse-frac): Don't use arguments. | ||
| 7 | (math-latex-parse-two-args): New function. | ||
| 8 | |||
| 9 | 2005-02-03 Lute Kamstra <lute@gnu.org> | ||
| 10 | |||
| 11 | * help-fns.el (help-with-tutorial): Make sure that users cannot | ||
| 12 | remove the entire text of the tutorial by means of `undo'. | ||
| 13 | |||
| 14 | 2005-02-03 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 15 | |||
| 16 | * textmodes/ispell.el (ispell-internal-change-dictionary): Fix problem | ||
| 17 | in recent changes, where the ispell process was repeatedly | ||
| 18 | killed & restarted. | ||
| 19 | |||
| 20 | * international/mule-cmds.el (set-locale-environment): Set file-name | ||
| 21 | coding system to utf-8 on Darwin systems. | ||
| 22 | (set-default-coding-systems): Don't set default-file-name-coding-system | ||
| 23 | on Darwin systems. | ||
| 24 | |||
| 1 | 2005-02-03 Richard M. Stallman <rms@gnu.org> | 25 | 2005-02-03 Richard M. Stallman <rms@gnu.org> |
| 2 | 26 | ||
| 3 | * hi-lock.el (hi-lock-mode): Turning on Hi-Lock turns on Font-Lock. | 27 | * hi-lock.el (hi-lock-mode): Turning on Hi-Lock turns on Font-Lock. |
diff --git a/lisp/calc/calc-embed.el b/lisp/calc/calc-embed.el index 4c6311c9a5b..e3b3b6b5b19 100644 --- a/lisp/calc/calc-embed.el +++ b/lisp/calc/calc-embed.el | |||
| @@ -967,19 +967,24 @@ The command \\[yank] can retrieve it from there." | |||
| 967 | (calc-embedded-original-buffer t info) | 967 | (calc-embedded-original-buffer t info) |
| 968 | (or (equal str (aref info 6)) | 968 | (or (equal str (aref info 6)) |
| 969 | (let ((delta (- (aref info 5) (aref info 3))) | 969 | (let ((delta (- (aref info 5) (aref info 3))) |
| 970 | (adjbot 0) | ||
| 970 | (buffer-read-only nil)) | 971 | (buffer-read-only nil)) |
| 971 | (goto-char (aref info 2)) | 972 | (goto-char (aref info 2)) |
| 972 | (delete-region (point) (aref info 3)) | 973 | (delete-region (point) (aref info 3)) |
| 973 | (and (> (nth 1 entry) (1+ extra)) | 974 | (and (> (nth 1 entry) (1+ extra)) |
| 974 | (aref info 7) | 975 | (aref info 7) |
| 975 | (progn | 976 | (progn |
| 976 | (aset info 7 nil) | ||
| 977 | (delete-horizontal-space) | 977 | (delete-horizontal-space) |
| 978 | (insert "\n\n") | 978 | (if (looking-at "\n") |
| 979 | (delete-horizontal-space) | 979 | ;; If there's a newline there, don't add one |
| 980 | (backward-char 1))) | 980 | (insert "\n") |
| 981 | (insert "\n\n") | ||
| 982 | (delete-horizontal-space) | ||
| 983 | (setq adjbot 1) | ||
| 984 | ; (setq delta (1+ delta)) | ||
| 985 | (backward-char 1)))) | ||
| 981 | (insert str) | 986 | (insert str) |
| 982 | (set-marker (aref info 3) (point)) | 987 | (set-marker (aref info 3) (+ (point) adjbot)) |
| 983 | (set-marker (aref info 5) (+ (point) delta)) | 988 | (set-marker (aref info 5) (+ (point) delta)) |
| 984 | (aset info 6 str)))))) | 989 | (aset info 6 str)))))) |
| 985 | (if (eq (car-safe val) 'calcFunc-evalto) | 990 | (if (eq (car-safe val) 'calcFunc-evalto) |
diff --git a/lisp/calc/calc-lang.el b/lisp/calc/calc-lang.el index d91d78fc461..63d24bb76d5 100644 --- a/lisp/calc/calc-lang.el +++ b/lisp/calc/calc-lang.el | |||
| @@ -469,12 +469,12 @@ | |||
| 469 | (put 'latex 'math-function-table | 469 | (put 'latex 'math-function-table |
| 470 | (append | 470 | (append |
| 471 | (get 'tex 'math-function-table) | 471 | (get 'tex 'math-function-table) |
| 472 | '(( \\frac . (math-latex-parse-frac /)) | 472 | '(( \\frac . (math-latex-parse-frac)) |
| 473 | ( \\tfrac . (math-latex-parse-frac /)) | 473 | ( \\tfrac . (math-latex-parse-frac)) |
| 474 | ( \\dfrac . (math-latex-parse-frac /)) | 474 | ( \\dfrac . (math-latex-parse-frac)) |
| 475 | ( \\binom . (math-latex-parse-frac calcFunc-choose)) | 475 | ( \\binom . (math-latex-parse-two-args calcFunc-choose)) |
| 476 | ( \\tbinom . (math-latex-parse-frac calcFunc-choose)) | 476 | ( \\tbinom . (math-latex-parse-two-args calcFunc-choose)) |
| 477 | ( \\dbinom . (math-latex-parse-frac calcFunc-choose)) | 477 | ( \\dbinom . (math-latex-parse-two-args calcFunc-choose)) |
| 478 | ( \\phi . calcFunc-totient ) | 478 | ( \\phi . calcFunc-totient ) |
| 479 | ( \\mu . calcFunc-moebius )))) | 479 | ( \\mu . calcFunc-moebius )))) |
| 480 | 480 | ||
| @@ -487,12 +487,23 @@ | |||
| 487 | 487 | ||
| 488 | (put 'latex 'math-complex-format 'i) | 488 | (put 'latex 'math-complex-format 'i) |
| 489 | 489 | ||
| 490 | |||
| 490 | (defun math-latex-parse-frac (f val) | 491 | (defun math-latex-parse-frac (f val) |
| 491 | (let (numer denom) | 492 | (let (numer denom) |
| 492 | (setq args (math-read-expr-list)) | 493 | (setq numer (car (math-read-expr-list))) |
| 494 | (math-read-token) | ||
| 495 | (setq denom (math-read-factor)) | ||
| 496 | (if (and (Math-num-integerp numer) | ||
| 497 | (Math-num-integerp denom)) | ||
| 498 | (list 'frac numer denom) | ||
| 499 | (list '/ numer denom)))) | ||
| 500 | |||
| 501 | (defun math-latex-parse-two-args (f val) | ||
| 502 | (let (first second) | ||
| 503 | (setq first (car (math-read-expr-list))) | ||
| 493 | (math-read-token) | 504 | (math-read-token) |
| 494 | (setq margs (math-read-factor)) | 505 | (setq second (math-read-factor)) |
| 495 | (list (nth 2 f) (car args) margs))) | 506 | (list (nth 2 f) first second))) |
| 496 | 507 | ||
| 497 | (defun math-latex-print-frac (a fn) | 508 | (defun math-latex-print-frac (a fn) |
| 498 | (list 'horiz (nth 1 fn) "{" (math-compose-expr (nth 1 a) -1) | 509 | (list 'horiz (nth 1 fn) "{" (math-compose-expr (nth 1 a) -1) |
diff --git a/lisp/help-fns.el b/lisp/help-fns.el index 9acadaa2fa6..4bf0a4775a0 100644 --- a/lisp/help-fns.el +++ b/lisp/help-fns.el | |||
| @@ -97,6 +97,7 @@ With ARG, you are asked to choose which language." | |||
| 97 | (forward-line 1) | 97 | (forward-line 1) |
| 98 | (newline (- n (/ n 2))))) | 98 | (newline (- n (/ n 2))))) |
| 99 | (goto-char (point-min)) | 99 | (goto-char (point-min)) |
| 100 | (setq buffer-undo-list nil) | ||
| 100 | (set-buffer-modified-p nil)))) | 101 | (set-buffer-modified-p nil)))) |
| 101 | 102 | ||
| 102 | ;;;###autoload | 103 | ;;;###autoload |
diff --git a/lisp/international/mule-cmds.el b/lisp/international/mule-cmds.el index e101b7c5f33..338a6025e18 100644 --- a/lisp/international/mule-cmds.el +++ b/lisp/international/mule-cmds.el | |||
| @@ -327,7 +327,8 @@ This also sets the following values: | |||
| 327 | (or (local-variable-p 'buffer-file-coding-system buffer) | 327 | (or (local-variable-p 'buffer-file-coding-system buffer) |
| 328 | (ucs-set-table-for-input buffer)))) | 328 | (ucs-set-table-for-input buffer)))) |
| 329 | 329 | ||
| 330 | (if default-enable-multibyte-characters | 330 | (if (and default-enable-multibyte-characters (not (eq system-type 'darwin))) |
| 331 | ;; The file-name coding system on Darwin systems is always utf-8. | ||
| 331 | (setq default-file-name-coding-system coding-system)) | 332 | (setq default-file-name-coding-system coding-system)) |
| 332 | ;; If coding-system is nil, honor that on MS-DOS as well, so | 333 | ;; If coding-system is nil, honor that on MS-DOS as well, so |
| 333 | ;; that they could reset the terminal coding system. | 334 | ;; that they could reset the terminal coding system. |
| @@ -1694,6 +1695,8 @@ The default status is as follows: | |||
| 1694 | 1695 | ||
| 1695 | (set-default-coding-systems nil) | 1696 | (set-default-coding-systems nil) |
| 1696 | (setq default-sendmail-coding-system 'iso-latin-1) | 1697 | (setq default-sendmail-coding-system 'iso-latin-1) |
| 1698 | ;; On Darwin systems, this should be utf-8, but when this file is loaded | ||
| 1699 | ;; utf-8 is not yet defined, so we set it in set-locale-environment instead. | ||
| 1697 | (setq default-file-name-coding-system 'iso-latin-1) | 1700 | (setq default-file-name-coding-system 'iso-latin-1) |
| 1698 | ;; Preserve eol-type from existing default-process-coding-systems. | 1701 | ;; Preserve eol-type from existing default-process-coding-systems. |
| 1699 | ;; On non-unix-like systems in particular, these may have been set | 1702 | ;; On non-unix-like systems in particular, these may have been set |
| @@ -2489,6 +2492,10 @@ See also `locale-charset-language-names', `locale-language-names', | |||
| 2489 | (set-keyboard-coding-system code-page-coding) | 2492 | (set-keyboard-coding-system code-page-coding) |
| 2490 | (set-terminal-coding-system code-page-coding)))) | 2493 | (set-terminal-coding-system code-page-coding)))) |
| 2491 | 2494 | ||
| 2495 | ;; On Darwin, file names are always encoded in utf-8, no matter the locale. | ||
| 2496 | (when (eq system-type 'darwin) | ||
| 2497 | (setq default-file-name-coding-system 'utf-8)) | ||
| 2498 | |||
| 2492 | ;; Default to A4 paper if we're not in a C, POSIX or US locale. | 2499 | ;; Default to A4 paper if we're not in a C, POSIX or US locale. |
| 2493 | ;; (See comments in Flocale_info.) | 2500 | ;; (See comments in Flocale_info.) |
| 2494 | (let ((locale locale) | 2501 | (let ((locale locale) |
diff --git a/lisp/textmodes/ispell.el b/lisp/textmodes/ispell.el index c403422801f..d5171125ae8 100644 --- a/lisp/textmodes/ispell.el +++ b/lisp/textmodes/ispell.el | |||
| @@ -1,6 +1,7 @@ | |||
| 1 | ;;; ispell.el --- interface to International Ispell Versions 3.1 and 3.2 | 1 | ;;; ispell.el --- interface to International Ispell Versions 3.1 and 3.2 |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1994, 1995, 1997, 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 1994, 1995, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2005 |
| 4 | ;; Free Software Foundation, Inc. | ||
| 4 | 5 | ||
| 5 | ;; Author: Ken Stevens <k.stevens@ieee.org> | 6 | ;; Author: Ken Stevens <k.stevens@ieee.org> |
| 6 | ;; Maintainer: Ken Stevens <k.stevens@ieee.org> | 7 | ;; Maintainer: Ken Stevens <k.stevens@ieee.org> |
| @@ -2449,7 +2450,7 @@ With prefix argument, set the default dictionary." | |||
| 2449 | "Update the dictionary actually used by Ispell. | 2450 | "Update the dictionary actually used by Ispell. |
| 2450 | This may kill the Ispell process; if so, | 2451 | This may kill the Ispell process; if so, |
| 2451 | a new one will be started when needed." | 2452 | a new one will be started when needed." |
| 2452 | (let ((dict (or ispell-local-dictionary ispell-dictionary "default"))) | 2453 | (let ((dict (or ispell-local-dictionary ispell-dictionary))) |
| 2453 | (unless (equal ispell-current-dictionary dict) | 2454 | (unless (equal ispell-current-dictionary dict) |
| 2454 | (setq ispell-current-dictionary dict) | 2455 | (setq ispell-current-dictionary dict) |
| 2455 | (ispell-kill-ispell t)))) | 2456 | (ispell-kill-ispell t)))) |
diff --git a/man/ChangeLog b/man/ChangeLog index ca46664fe39..8f123098ec4 100644 --- a/man/ChangeLog +++ b/man/ChangeLog | |||
| @@ -1,3 +1,7 @@ | |||
| 1 | 2005-02-03 Lute Kamstra <lute@gnu.org> | ||
| 2 | |||
| 3 | * frames.texi (Frames, Drag and Drop): Fix typos. | ||
| 4 | |||
| 1 | 2005-02-03 Richard M. Stallman <rms@gnu.org> | 5 | 2005-02-03 Richard M. Stallman <rms@gnu.org> |
| 2 | 6 | ||
| 3 | * windows.texi (Basic Window): Mention color-change in mode line. | 7 | * windows.texi (Basic Window): Mention color-change in mode line. |
diff --git a/man/frames.texi b/man/frames.texi index 1e403adf3e3..603dfdea252 100644 --- a/man/frames.texi +++ b/man/frames.texi | |||
| @@ -813,12 +813,12 @@ buffers are scrolled. | |||
| 813 | @section Drag and Drop | 813 | @section Drag and Drop |
| 814 | @cindex drag and drop | 814 | @cindex drag and drop |
| 815 | 815 | ||
| 816 | Emacs supports drag and drop using the mouse. For instance, dropping | 816 | Emacs supports @dfn{drag and drop} using the mouse. For instance, |
| 817 | text onto an Emacs frame inserts the text where it is dropped. Dropping | 817 | dropping text onto an Emacs frame inserts the text where it is dropped. |
| 818 | a file onto an Emacs frame visits that file. As a special case, | 818 | Dropping a file onto an Emacs frame visits that file. As a special |
| 819 | dropping the file on a Dired buffer moves or copies the file (according | 819 | case, dropping the file on a Dired buffer moves or copies the file |
| 820 | to the conventions of the application it came from) into the directory | 820 | (according to the conventions of the application it came from) into the |
| 821 | displayed in that buffer. | 821 | directory displayed in that buffer. |
| 822 | 822 | ||
| 823 | @vindex x-dnd-open-file-other-window | 823 | @vindex x-dnd-open-file-other-window |
| 824 | Dropping a file normally visits it in the window you drop it on. If | 824 | Dropping a file normally visits it in the window you drop it on. If |
diff --git a/src/ChangeLog b/src/ChangeLog index 6dd4211364f..eb8bab64362 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,34 @@ | |||
| 1 | 2005-02-03 Jan Dj,Ad(Brv <jan.h.d@swipnet.se> | ||
| 2 | |||
| 3 | * xmenu.c (menubar_selection_callback): Force out GTK buffered | ||
| 4 | events so the menu event comes after them. This is to prevent sit-for | ||
| 5 | from exiting on buffered events directly after a menu selection, | ||
| 6 | lisp code for Help => About Emacs uses sit-for. | ||
| 7 | |||
| 8 | * gtkutil.c (create_menus): Connect selection-done event instead of | ||
| 9 | the deactivate event to deactivate_cb. This will make the last | ||
| 10 | leave event come before the call to deactivate_cb, so the leave | ||
| 11 | event does not make sit-for exit after a menu selection. | ||
| 12 | |||
| 13 | 2005-02-03 Kim F. Storm <storm@cua.dk> | ||
| 14 | |||
| 15 | * dispnew.c (build_frame_matrix_from_leaf_window) | ||
| 16 | [!GLYPH_DEBUG]: Fix xassert. | ||
| 17 | |||
| 18 | * xfaces.c (x_free_gc) [!GLYPH_DEBUG]: Fix xassert. | ||
| 19 | |||
| 20 | * xfns.c (unwind_create_frame) [!GLYPH_DEBUG]: Fix xassert. | ||
| 21 | |||
| 22 | 2005-02-03 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> | ||
| 23 | |||
| 24 | * mac.c: Use MAC_OS_X_VERSION_MAX_ALLOWED to conditionalize by | ||
| 25 | the compiling OS version. | ||
| 26 | |||
| 27 | * macfns.c (x_create_tip_frame): Likewise. | ||
| 28 | |||
| 29 | * macterm.c (mac_draw_string_common, x_make_frame_visible): | ||
| 30 | Likewise. | ||
| 31 | |||
| 1 | 2005-02-03 Richard M. Stallman <rms@gnu.org> | 32 | 2005-02-03 Richard M. Stallman <rms@gnu.org> |
| 2 | 33 | ||
| 3 | * xterm.c (x_error_quitter): On GCC 3 and up, specify noinline. | 34 | * xterm.c (x_error_quitter): On GCC 3 and up, specify noinline. |
diff --git a/src/dispnew.c b/src/dispnew.c index 47e36aa991c..606e8331347 100644 --- a/src/dispnew.c +++ b/src/dispnew.c | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | /* Updating of data structures for redisplay. | 1 | /* Updating of data structures for redisplay. |
| 2 | Copyright (C) 1985,86,87,88,93,94,95,97,98,1999,2000,01,02,03,04 | 2 | Copyright (C) 1985, 1986, 1987, 1988, 1993, 1994, 1995, 1997, 1998, 1999, |
| 3 | Free Software Foundation, Inc. | 3 | 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | This file is part of GNU Emacs. | 5 | This file is part of GNU Emacs. |
| 6 | 6 | ||
| @@ -2775,7 +2775,6 @@ build_frame_matrix_from_leaf_window (frame_matrix, w) | |||
| 2775 | /* If rows are in sync, we don't have to copy glyphs because | 2775 | /* If rows are in sync, we don't have to copy glyphs because |
| 2776 | frame and window share glyphs. */ | 2776 | frame and window share glyphs. */ |
| 2777 | 2777 | ||
| 2778 | #if GLYPH_DEBUG | ||
| 2779 | strcpy (w->current_matrix->method, w->desired_matrix->method); | 2778 | strcpy (w->current_matrix->method, w->desired_matrix->method); |
| 2780 | add_window_display_history (w, w->current_matrix->method, 0); | 2779 | add_window_display_history (w, w->current_matrix->method, 0); |
| 2781 | #endif | 2780 | #endif |
diff --git a/src/gtkutil.c b/src/gtkutil.c index aecc4e2eaea..6bf0c25f350 100644 --- a/src/gtkutil.c +++ b/src/gtkutil.c | |||
| @@ -1905,7 +1905,7 @@ create_menus (data, f, select_cb, deactivate_cb, highlight_cb, | |||
| 1905 | 1905 | ||
| 1906 | if (deactivate_cb) | 1906 | if (deactivate_cb) |
| 1907 | g_signal_connect (G_OBJECT (wmenu), | 1907 | g_signal_connect (G_OBJECT (wmenu), |
| 1908 | "deactivate", deactivate_cb, 0); | 1908 | "selection-done", deactivate_cb, 0); |
| 1909 | 1909 | ||
| 1910 | g_signal_connect (G_OBJECT (wmenu), | 1910 | g_signal_connect (G_OBJECT (wmenu), |
| 1911 | "grab-notify", G_CALLBACK (menu_grab_callback), 0); | 1911 | "grab-notify", G_CALLBACK (menu_grab_callback), 0); |
| @@ -2858,7 +2858,7 @@ select_and_poll_event (n, rfds, wfds, efds, timeout) | |||
| 2858 | return r; | 2858 | return r; |
| 2859 | } | 2859 | } |
| 2860 | 2860 | ||
| 2861 | #ifndef MAC_OS_X_VERSION_10_2 | 2861 | #if MAC_OS_X_VERSION_MAX_ALLOWED < 1020 |
| 2862 | #undef SELECT_INVALIDATE_CFSOCKET | 2862 | #undef SELECT_INVALIDATE_CFSOCKET |
| 2863 | #endif | 2863 | #endif |
| 2864 | 2864 | ||
diff --git a/src/macfns.c b/src/macfns.c index 416522b49b9..26d63ec99af 100644 --- a/src/macfns.c +++ b/src/macfns.c | |||
| @@ -3882,7 +3882,7 @@ x_create_tip_frame (dpyinfo, parms, text) | |||
| 3882 | SetRect (&r, 0, 0, 1, 1); | 3882 | SetRect (&r, 0, 0, 1, 1); |
| 3883 | #if TARGET_API_MAC_CARBON | 3883 | #if TARGET_API_MAC_CARBON |
| 3884 | if (CreateNewWindow (kHelpWindowClass, | 3884 | if (CreateNewWindow (kHelpWindowClass, |
| 3885 | #ifdef MAC_OS_X_VERSION_10_2 | 3885 | #if MAC_OS_X_VERSION_MAX_ALLOWED >= 1020 |
| 3886 | kWindowIgnoreClicksAttribute | | 3886 | kWindowIgnoreClicksAttribute | |
| 3887 | #endif | 3887 | #endif |
| 3888 | kWindowNoUpdatesAttribute | | 3888 | kWindowNoUpdatesAttribute | |
diff --git a/src/macterm.c b/src/macterm.c index 16878f9a45a..21effb23cfa 100644 --- a/src/macterm.c +++ b/src/macterm.c | |||
| @@ -729,7 +729,7 @@ mac_draw_string_common (display, w, gc, x, y, buf, nchars, mode, | |||
| 729 | int nchars, mode, bytes_per_char; | 729 | int nchars, mode, bytes_per_char; |
| 730 | { | 730 | { |
| 731 | SetPortWindowPort (w); | 731 | SetPortWindowPort (w); |
| 732 | #ifdef MAC_OS_X_VERSION_10_2 | 732 | #if MAC_OS_X_VERSION_MAX_ALLOWED >= 1020 |
| 733 | UInt32 textFlags, savedFlags; | 733 | UInt32 textFlags, savedFlags; |
| 734 | if (!NILP(Vmac_use_core_graphics)) { | 734 | if (!NILP(Vmac_use_core_graphics)) { |
| 735 | textFlags = kQDUseCGTextRendering; | 735 | textFlags = kQDUseCGTextRendering; |
| @@ -746,7 +746,7 @@ mac_draw_string_common (display, w, gc, x, y, buf, nchars, mode, | |||
| 746 | 746 | ||
| 747 | MoveTo (x, y); | 747 | MoveTo (x, y); |
| 748 | DrawText (buf, 0, nchars * bytes_per_char); | 748 | DrawText (buf, 0, nchars * bytes_per_char); |
| 749 | #ifdef MAC_OS_X_VERSION_10_2 | 749 | #if MAC_OS_X_VERSION_MAX_ALLOWED >= 1020 |
| 750 | if (!NILP(Vmac_use_core_graphics)) | 750 | if (!NILP(Vmac_use_core_graphics)) |
| 751 | SwapQDTextFlags(savedFlags); | 751 | SwapQDTextFlags(savedFlags); |
| 752 | #endif | 752 | #endif |
| @@ -5451,7 +5451,7 @@ x_make_frame_visible (f) | |||
| 5451 | else | 5451 | else |
| 5452 | RepositionWindow (FRAME_MAC_WINDOW (f), | 5452 | RepositionWindow (FRAME_MAC_WINDOW (f), |
| 5453 | FRAME_MAC_WINDOW (sf), | 5453 | FRAME_MAC_WINDOW (sf), |
| 5454 | #ifdef MAC_OS_X_VERSION_10_2 | 5454 | #if MAC_OS_X_VERSION_MAX_ALLOWED >= 1020 |
| 5455 | kWindowCascadeStartAtParentWindowScreen | 5455 | kWindowCascadeStartAtParentWindowScreen |
| 5456 | #else | 5456 | #else |
| 5457 | kWindowCascadeOnParentWindowScreen | 5457 | kWindowCascadeOnParentWindowScreen |
diff --git a/src/xfaces.c b/src/xfaces.c index 0c4665a4cb6..a0ac3867ef6 100644 --- a/src/xfaces.c +++ b/src/xfaces.c | |||
| @@ -1,5 +1,5 @@ | |||
| 1 | /* xfaces.c -- "Face" primitives. | 1 | /* xfaces.c -- "Face" primitives. |
| 2 | Copyright (C) 1993, 1994, 1998, 1999, 2000, 2001, 2002, 2003, 2004 | 2 | Copyright (C) 1993, 1994, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 |
| 3 | Free Software Foundation. | 3 | Free Software Foundation. |
| 4 | 4 | ||
| 5 | This file is part of GNU Emacs. | 5 | This file is part of GNU Emacs. |
| @@ -741,9 +741,7 @@ x_free_gc (f, gc) | |||
| 741 | GC gc; | 741 | GC gc; |
| 742 | { | 742 | { |
| 743 | BLOCK_INPUT; | 743 | BLOCK_INPUT; |
| 744 | #if GLYPH_DEBUG | 744 | IF_DEBUG (xassert (--ngcs >= 0)); |
| 745 | xassert (--ngcs >= 0); | ||
| 746 | #endif | ||
| 747 | XFreeGC (FRAME_X_DISPLAY (f), gc); | 745 | XFreeGC (FRAME_X_DISPLAY (f), gc); |
| 748 | UNBLOCK_INPUT; | 746 | UNBLOCK_INPUT; |
| 749 | } | 747 | } |
| @@ -776,7 +774,7 @@ x_free_gc (f, gc) | |||
| 776 | GC gc; | 774 | GC gc; |
| 777 | { | 775 | { |
| 778 | BLOCK_INPUT; | 776 | BLOCK_INPUT; |
| 779 | xassert (--ngcs >= 0); | 777 | IF_DEBUG (xassert (--ngcs >= 0)); |
| 780 | xfree (gc); | 778 | xfree (gc); |
| 781 | UNBLOCK_INPUT; | 779 | UNBLOCK_INPUT; |
| 782 | } | 780 | } |
diff --git a/src/xfns.c b/src/xfns.c index eaae071ef26..48967575f0c 100644 --- a/src/xfns.c +++ b/src/xfns.c | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | /* Functions for the X window system. | 1 | /* Functions for the X window system. |
| 2 | Copyright (C) 1989, 92, 93, 94, 95, 96, 97, 98, 99, 2000,01,02,03,04 | 2 | Copyright (C) 1989, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, |
| 3 | Free Software Foundation. | 3 | 2001, 2002, 2003, 2004, 2005 Free Software Foundation. |
| 4 | 4 | ||
| 5 | This file is part of GNU Emacs. | 5 | This file is part of GNU Emacs. |
| 6 | 6 | ||
| @@ -4108,7 +4108,7 @@ Value is VALUE. */) | |||
| 4108 | 4108 | ||
| 4109 | if (! NILP (outer_p)) w = FRAME_OUTER_WINDOW (f); | 4109 | if (! NILP (outer_p)) w = FRAME_OUTER_WINDOW (f); |
| 4110 | else w = FRAME_X_WINDOW (f); | 4110 | else w = FRAME_X_WINDOW (f); |
| 4111 | 4111 | ||
| 4112 | XChangeProperty (FRAME_X_DISPLAY (f), w, | 4112 | XChangeProperty (FRAME_X_DISPLAY (f), w, |
| 4113 | prop_atom, target_type, element_format, PropModeReplace, | 4113 | prop_atom, target_type, element_format, PropModeReplace, |
| 4114 | data, nelements); | 4114 | data, nelements); |
| @@ -5293,7 +5293,7 @@ or directory must exist. ONLY-DIR-P is ignored." */) | |||
| 5293 | if (keysym == XK_g && (event.xkey.state & ControlMask) != 0) | 5293 | if (keysym == XK_g && (event.xkey.state & ControlMask) != 0) |
| 5294 | XtUnmanageChild (dialog); | 5294 | XtUnmanageChild (dialog); |
| 5295 | } | 5295 | } |
| 5296 | 5296 | ||
| 5297 | (void) x_dispatch_event (&event, FRAME_X_DISPLAY (f)); | 5297 | (void) x_dispatch_event (&event, FRAME_X_DISPLAY (f)); |
| 5298 | } | 5298 | } |
| 5299 | 5299 | ||
diff --git a/src/xmenu.c b/src/xmenu.c index f6e0523378f..b6a5186f1f1 100644 --- a/src/xmenu.c +++ b/src/xmenu.c | |||
| @@ -1445,9 +1445,9 @@ menu_highlight_callback (widget, id, call_data) | |||
| 1445 | /* Find the menu selection and store it in the keyboard buffer. | 1445 | /* Find the menu selection and store it in the keyboard buffer. |
| 1446 | F is the frame the menu is on. | 1446 | F is the frame the menu is on. |
| 1447 | MENU_BAR_ITEMS_USED is the length of VECTOR. | 1447 | MENU_BAR_ITEMS_USED is the length of VECTOR. |
| 1448 | VECTOR is an array of menu events for the whole menu. | 1448 | VECTOR is an array of menu events for the whole menu. */ |
| 1449 | */ | 1449 | |
| 1450 | void | 1450 | static void |
| 1451 | find_and_call_menu_selection (f, menu_bar_items_used, vector, client_data) | 1451 | find_and_call_menu_selection (f, menu_bar_items_used, vector, client_data) |
| 1452 | FRAME_PTR f; | 1452 | FRAME_PTR f; |
| 1453 | int menu_bar_items_used; | 1453 | int menu_bar_items_used; |
| @@ -1554,6 +1554,17 @@ menubar_selection_callback (widget, client_data) | |||
| 1554 | if (! cb_data || ! cb_data->cl_data || ! cb_data->cl_data->f) | 1554 | if (! cb_data || ! cb_data->cl_data || ! cb_data->cl_data->f) |
| 1555 | return; | 1555 | return; |
| 1556 | 1556 | ||
| 1557 | /* When a menu is popped down, X generates a focus event (i.e. focus | ||
| 1558 | goes back to the frame below the menu). Since GTK buffers events, | ||
| 1559 | we force it out here before the menu selection event. Otherwise | ||
| 1560 | sit-for will exit at once if the focus event follows the menu selection | ||
| 1561 | event. */ | ||
| 1562 | |||
| 1563 | BLOCK_INPUT; | ||
| 1564 | while (gtk_events_pending ()) | ||
| 1565 | gtk_main_iteration (); | ||
| 1566 | UNBLOCK_INPUT; | ||
| 1567 | |||
| 1557 | find_and_call_menu_selection (cb_data->cl_data->f, | 1568 | find_and_call_menu_selection (cb_data->cl_data->f, |
| 1558 | cb_data->cl_data->menu_bar_items_used, | 1569 | cb_data->cl_data->menu_bar_items_used, |
| 1559 | cb_data->cl_data->menu_bar_vector, | 1570 | cb_data->cl_data->menu_bar_vector, |