diff options
| -rw-r--r-- | lisp/ChangeLog | 86 | ||||
| -rw-r--r-- | lisp/emacs-lisp/bytecomp.el | 34 | ||||
| -rw-r--r-- | lisp/files.el | 2 | ||||
| -rw-r--r-- | lisp/gnus/ChangeLog | 2 | ||||
| -rw-r--r-- | lisp/gnus/mm-view.el | 5 | ||||
| -rw-r--r-- | lisp/help-mode.el | 9 | ||||
| -rw-r--r-- | lisp/international/characters.el | 33 | ||||
| -rw-r--r-- | lisp/net/ldap.el | 2 | ||||
| -rw-r--r-- | lisp/pcvs.el | 2 | ||||
| -rw-r--r-- | lisp/progmodes/gdb-ui.el | 20 | ||||
| -rw-r--r-- | lisp/progmodes/gud.el | 11 | ||||
| -rw-r--r-- | lisp/simple.el | 72 | ||||
| -rw-r--r-- | lisp/textmodes/tex-mode.el | 31 | ||||
| -rw-r--r-- | lisp/wid-edit.el | 2 | ||||
| -rw-r--r-- | lispref/ChangeLog | 4 | ||||
| -rw-r--r-- | lispref/modes.texi | 2 | ||||
| -rw-r--r-- | man/search.texi | 12 | ||||
| -rw-r--r-- | src/.gdbinit | 14 | ||||
| -rw-r--r-- | src/ChangeLog | 49 | ||||
| -rw-r--r-- | src/print.c | 3 | ||||
| -rw-r--r-- | src/regex.c | 132 | ||||
| -rw-r--r-- | src/search.c | 2 | ||||
| -rw-r--r-- | src/w32console.c | 124 | ||||
| -rw-r--r-- | src/w32fns.c | 4 | ||||
| -rw-r--r-- | src/w32menu.c | 14 | ||||
| -rw-r--r-- | src/w32proc.c | 4 | ||||
| -rw-r--r-- | src/w32term.h | 6 |
27 files changed, 464 insertions, 217 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 8e2b74d5b60..81da604aea5 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,18 +1,61 @@ | |||
| 1 | 2004-05-19 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 2 | |||
| 3 | * simple.el (do-auto-fill): Remove unused vars `bol' and `opoint'. | ||
| 4 | (completion-setup-function): Use with-current-buffer. | ||
| 5 | Properly save excursion. Simplify. | ||
| 6 | Don't assume there is necessarily a `mouse-face' property somewhere. | ||
| 7 | |||
| 8 | * progmodes/gud.el (gud-reset): Use unless & with-current-buffer. | ||
| 9 | |||
| 10 | * progmodes/gdb-ui.el (gdb-reset): Use unless. Fix regexp. | ||
| 11 | |||
| 12 | * emacs-lisp/bytecomp.el (byte-compile-log): Use backquotes. | ||
| 13 | (byte-compile-log-1): Don't call (byte-goto-log-buffer). | ||
| 14 | Use with-current-buffer. | ||
| 15 | (byte-goto-log-buffer): Delete. | ||
| 16 | (byte-compile-log-file): Call compilation-forget-errors. | ||
| 17 | |||
| 18 | 2004-05-19 Takaaki Ota <Takaaki.Ota@am.sony.com> (tiny change) | ||
| 19 | |||
| 20 | * net/ldap.el (ldap-search-internal): Avoid mixing standard error | ||
| 21 | output messages into the search result. | ||
| 22 | |||
| 23 | 2004-05-19 Masatake YAMATO <jet@gyve.org> | ||
| 24 | |||
| 25 | * wid-edit.el (widget-radio-button-notify): Revert my last | ||
| 26 | change. Reported by Katsumi Yamaoka <yamaoka@jpl.org>. | ||
| 27 | |||
| 28 | 2004-05-19 Kenichi Handa <handa@m17n.org> | ||
| 29 | |||
| 30 | * international/characters.el: Fix syntax (open/close) of CJK chars. | ||
| 31 | |||
| 32 | 2004-05-18 Karl Chen <quarl@hkn.eecs.berkeley.edu> (tiny change) | ||
| 33 | |||
| 34 | * help-mode.el (help-go-back): Don't depend on position of back button. | ||
| 35 | |||
| 36 | 2004-05-18 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 37 | |||
| 38 | * files.el (auto-save-file-name-transforms): Make sure ange-ftp temp | ||
| 39 | files files don't contain an accidental additional /. | ||
| 40 | |||
| 41 | * textmodes/tex-mode.el (tex-compilation-parse-errors): Save excursion | ||
| 42 | in source buffer. | ||
| 43 | |||
| 1 | 2004-05-18 Masatake YAMATO <jet@gyve.org> | 44 | 2004-05-18 Masatake YAMATO <jet@gyve.org> |
| 2 | 45 | ||
| 3 | * wid-edit.el (widget-radio-button-notify): Don't pass `widget' | 46 | * wid-edit.el (widget-radio-button-notify): Don't pass `widget' |
| 4 | to widget-apply. :action method assumes 2 arguments, not 3. | 47 | to widget-apply. :action method assumes 2 arguments, not 3. |
| 5 | 48 | ||
| 6 | 2004-05-17 Glenn Morris <gmorris@ast.cam.ac.uk> | 49 | 2004-05-17 Glenn Morris <gmorris@ast.cam.ac.uk> |
| 7 | 50 | ||
| 8 | * progmodes/f90.el (f90-end-block-re, f90-start-block-re): New | 51 | * progmodes/f90.el (f90-end-block-re, f90-start-block-re): |
| 9 | constants. | 52 | New constants. |
| 10 | (hs-special-modes-alist): Add an f90-mode entry. | 53 | (hs-special-modes-alist): Add an f90-mode entry. |
| 11 | 54 | ||
| 12 | 2004-05-17 Sam Steingold <sds@gnu.org> | 55 | 2004-05-17 Sam Steingold <sds@gnu.org> |
| 13 | 56 | ||
| 14 | * emacs-lisp/cl-indent.el (common-lisp-indent-function-1): Indent | 57 | * emacs-lisp/cl-indent.el (common-lisp-indent-function-1): |
| 15 | "without-" forms just like "with-" and "do-". Use regexp-opt. | 58 | Indent "without-" forms just like "with-" and "do-". Use regexp-opt. |
| 16 | 59 | ||
| 17 | 2004-05-16 Kim F. Storm <storm@cua.dk> | 60 | 2004-05-16 Kim F. Storm <storm@cua.dk> |
| 18 | 61 | ||
| @@ -20,15 +63,14 @@ | |||
| 20 | 63 | ||
| 21 | 2004-05-15 John Wiegley <johnw@newartisans.com> | 64 | 2004-05-15 John Wiegley <johnw@newartisans.com> |
| 22 | 65 | ||
| 23 | * eshell/esh-io.el (eshell-get-target): whitespace changes. | 66 | * eshell/esh-io.el (eshell-get-target): Whitespace changes. |
| 24 | (eshell-output-object-to-target): Improve output speed 20% by not | 67 | (eshell-output-object-to-target): Improve output speed 20% by not |
| 25 | calling `eshell-stringify' if something is already known to be a | 68 | calling `eshell-stringify' if something is already known to be a string. |
| 26 | string. | ||
| 27 | 69 | ||
| 28 | 2004-05-15 Alex Ott <ott@jet.msk.su> | 70 | 2004-05-15 Alex Ott <ott@jet.msk.su> |
| 29 | 71 | ||
| 30 | * textmodes/ispell.el (ispell-local-dictionary-alist): Add | 72 | * textmodes/ispell.el (ispell-local-dictionary-alist): |
| 31 | windows-1251 to the choice of coding systems. | 73 | Add windows-1251 to the choice of coding systems. |
| 32 | (ispell-dictionary-alist-6): Add support for "russianw.aff", | 74 | (ispell-dictionary-alist-6): Add support for "russianw.aff", |
| 33 | encoded in cp1251. | 75 | encoded in cp1251. |
| 34 | 76 | ||
| @@ -75,7 +117,7 @@ | |||
| 75 | 117 | ||
| 76 | 2004-05-13 Marcelo Toledo <marcelo@marcelotoledo.org> | 118 | 2004-05-13 Marcelo Toledo <marcelo@marcelotoledo.org> |
| 77 | 119 | ||
| 78 | * language/european.el ("Brazilian Portuguese"): Added support for | 120 | * language/european.el ("Brazilian Portuguese"): Add support for |
| 79 | Brazilian Portuguese. | 121 | Brazilian Portuguese. |
| 80 | 122 | ||
| 81 | 2004-05-13 John Wiegley <johnw@newartisans.com> | 123 | 2004-05-13 John Wiegley <johnw@newartisans.com> |
| @@ -84,8 +126,7 @@ | |||
| 84 | `recentf-mode' if this variable has been customized to t. | 126 | `recentf-mode' if this variable has been customized to t. |
| 85 | 127 | ||
| 86 | * eshell/esh-test.el (eshell-test): Call the function | 128 | * eshell/esh-test.el (eshell-test): Call the function |
| 87 | `emacs-version' rather than trying to build a custom version | 129 | `emacs-version' rather than trying to build a custom version string. |
| 88 | string. | ||
| 89 | 130 | ||
| 90 | 2004-05-13 Stefan Monnier <monnier@iro.umontreal.ca> | 131 | 2004-05-13 Stefan Monnier <monnier@iro.umontreal.ca> |
| 91 | 132 | ||
| @@ -775,18 +816,17 @@ | |||
| 775 | * progmodes/fortran.el (fortran-fill): Use local var `bol' rather | 816 | * progmodes/fortran.el (fortran-fill): Use local var `bol' rather |
| 776 | than duplicate call to `line-beginning-position'. | 817 | than duplicate call to `line-beginning-position'. |
| 777 | 818 | ||
| 778 | * progmodes/f90.el (f90-get-present-comment-type): Return | 819 | * progmodes/f90.el (f90-get-present-comment-type): |
| 779 | whitespace, as well as comment chars, for consistent filling | 820 | Return whitespace, as well as comment chars, for consistent filling |
| 780 | of comment blocks. Use `match-string-no-properties'. | 821 | of comment blocks. Use `match-string-no-properties'. |
| 781 | (f90-break-line): Do not leave trailing whitespace when filling | 822 | (f90-break-line): Trim trailing whitespace when filling comments. |
| 782 | comments. | ||
| 783 | 823 | ||
| 784 | 2004-04-30 Dave Love <fx@gnu.org> | 824 | 2004-04-30 Dave Love <fx@gnu.org> |
| 785 | 825 | ||
| 786 | * calendar/diary-lib.el (diary-outlook-formats): New variable. | 826 | * calendar/diary-lib.el (diary-outlook-formats): New variable. |
| 787 | (diary-from-outlook-internal, diary-from-outlook) | 827 | (diary-from-outlook-internal, diary-from-outlook) |
| 788 | (diary-from-outlook-gnus, diary-from-outlook-rmail): New | 828 | (diary-from-outlook-gnus, diary-from-outlook-rmail): |
| 789 | functions to import diary entries from Outlook-format | 829 | New functions to import diary entries from Outlook-format |
| 790 | appointments in mail messages. | 830 | appointments in mail messages. |
| 791 | 831 | ||
| 792 | 2004-04-29 Stefan Monnier <monnier@iro.umontreal.ca> | 832 | 2004-04-29 Stefan Monnier <monnier@iro.umontreal.ca> |
| @@ -814,8 +854,7 @@ | |||
| 814 | 854 | ||
| 815 | * progmodes/sql.el (sql-product-alist): Rename variable | 855 | * progmodes/sql.el (sql-product-alist): Rename variable |
| 816 | `sql-product-support'. Add Postgres login parameters. | 856 | `sql-product-support'. Add Postgres login parameters. |
| 817 | (sql-set-product, sql-product-feature): Update with renamed | 857 | (sql-set-product, sql-product-feature): Update with renamed variable. |
| 818 | variable. | ||
| 819 | (sql-connect-postgres): Add username prompt. | 858 | (sql-connect-postgres): Add username prompt. |
| 820 | (sql-imenu-generic-expression, sql-mode-font-lock-object-name): | 859 | (sql-imenu-generic-expression, sql-mode-font-lock-object-name): |
| 821 | Make patterns less product specific. | 860 | Make patterns less product specific. |
| @@ -837,8 +876,7 @@ | |||
| 837 | (sql-mode-sqlite-font-lock-keywords) | 876 | (sql-mode-sqlite-font-lock-keywords) |
| 838 | (sql-mode-db2-font-lock-keywords): Default to nil. | 877 | (sql-mode-db2-font-lock-keywords): Default to nil. |
| 839 | (sql-product-font-lock): Always highlight ANSI keywords. | 878 | (sql-product-font-lock): Always highlight ANSI keywords. |
| 840 | (sql-add-product-keywords): Made similar to | 879 | (sql-add-product-keywords): Made similar to `font-lock-add-keywords'. |
| 841 | `font-lock-add-keywords'. | ||
| 842 | (sql-send-string): Add function. | 880 | (sql-send-string): Add function. |
| 843 | 881 | ||
| 844 | 2004-04-29 Dave Love <fx@gnu.org> | 882 | 2004-04-29 Dave Love <fx@gnu.org> |
| @@ -7391,7 +7429,7 @@ See ChangeLog.10 for earlier changes. | |||
| 7391 | ;; coding: iso-2022-7bit | 7429 | ;; coding: iso-2022-7bit |
| 7392 | ;; End: | 7430 | ;; End: |
| 7393 | 7431 | ||
| 7394 | Copyright (C) 2001, 2002 Free Software Foundation, Inc. | 7432 | Copyright (C) 2001, 02, 04 Free Software Foundation, Inc. |
| 7395 | Copying and distribution of this file, with or without modification, | 7433 | Copying and distribution of this file, with or without modification, |
| 7396 | are permitted provided the copyright notice and this notice are preserved. | 7434 | are permitted provided the copyright notice and this notice are preserved. |
| 7397 | 7435 | ||
diff --git a/lisp/emacs-lisp/bytecomp.el b/lisp/emacs-lisp/bytecomp.el index f6e2946aa8b..8e20925c70d 100644 --- a/lisp/emacs-lisp/bytecomp.el +++ b/lisp/emacs-lisp/bytecomp.el | |||
| @@ -832,24 +832,22 @@ Each function's symbol gets added to `byte-compile-noruntime-functions'." | |||
| 832 | 832 | ||
| 833 | ;; Log something that isn't a warning. | 833 | ;; Log something that isn't a warning. |
| 834 | (defmacro byte-compile-log (format-string &rest args) | 834 | (defmacro byte-compile-log (format-string &rest args) |
| 835 | (list 'and | 835 | `(and |
| 836 | 'byte-optimize | 836 | byte-optimize |
| 837 | '(memq byte-optimize-log '(t source)) | 837 | (memq byte-optimize-log '(t source)) |
| 838 | (list 'let '((print-escape-newlines t) | 838 | (let ((print-escape-newlines t) |
| 839 | (print-level 4) | 839 | (print-level 4) |
| 840 | (print-length 4)) | 840 | (print-length 4)) |
| 841 | (list 'byte-compile-log-1 | 841 | (byte-compile-log-1 |
| 842 | (cons 'format | 842 | (format |
| 843 | (cons format-string | 843 | ,format-string |
| 844 | (mapcar | 844 | ,@(mapcar |
| 845 | (lambda (x) | 845 | (lambda (x) (if (symbolp x) (list 'prin1-to-string x) x)) |
| 846 | (if (symbolp x) (list 'prin1-to-string x) x)) | 846 | args)))))) |
| 847 | args))))))) | ||
| 848 | 847 | ||
| 849 | ;; Log something that isn't a warning. | 848 | ;; Log something that isn't a warning. |
| 850 | (defun byte-compile-log-1 (string) | 849 | (defun byte-compile-log-1 (string) |
| 851 | (save-excursion | 850 | (with-current-buffer "*Compile-Log*" |
| 852 | (byte-goto-log-buffer) | ||
| 853 | (goto-char (point-max)) | 851 | (goto-char (point-max)) |
| 854 | (byte-compile-warning-prefix nil nil) | 852 | (byte-compile-warning-prefix nil nil) |
| 855 | (cond (noninteractive | 853 | (cond (noninteractive |
| @@ -903,11 +901,6 @@ Each function's symbol gets added to `byte-compile-noruntime-functions'." | |||
| 903 | (defvar byte-compile-last-warned-form nil) | 901 | (defvar byte-compile-last-warned-form nil) |
| 904 | (defvar byte-compile-last-logged-file nil) | 902 | (defvar byte-compile-last-logged-file nil) |
| 905 | 903 | ||
| 906 | (defun byte-goto-log-buffer () | ||
| 907 | (set-buffer (get-buffer-create "*Compile-Log*")) | ||
| 908 | (unless (eq major-mode 'compilation-mode) | ||
| 909 | (compilation-mode))) | ||
| 910 | |||
| 911 | ;; This is used as warning-prefix for the compiler. | 904 | ;; This is used as warning-prefix for the compiler. |
| 912 | ;; It is always called with the warnings buffer current. | 905 | ;; It is always called with the warnings buffer current. |
| 913 | (defun byte-compile-warning-prefix (level entry) | 906 | (defun byte-compile-warning-prefix (level entry) |
| @@ -983,6 +976,7 @@ Each function's symbol gets added to `byte-compile-noruntime-functions'." | |||
| 983 | ;; Do this after setting default-directory. | 976 | ;; Do this after setting default-directory. |
| 984 | (unless (eq major-mode 'compilation-mode) | 977 | (unless (eq major-mode 'compilation-mode) |
| 985 | (compilation-mode)) | 978 | (compilation-mode)) |
| 979 | (compilation-forget-errors) | ||
| 986 | pt)))) | 980 | pt)))) |
| 987 | 981 | ||
| 988 | ;; Log a message STRING in *Compile-Log*. | 982 | ;; Log a message STRING in *Compile-Log*. |
diff --git a/lisp/files.el b/lisp/files.el index 91da8a4c2c7..99cad16cf5b 100644 --- a/lisp/files.el +++ b/lisp/files.el | |||
| @@ -293,7 +293,7 @@ Normally auto-save files are written under other names." | |||
| 293 | :group 'auto-save) | 293 | :group 'auto-save) |
| 294 | 294 | ||
| 295 | (defcustom auto-save-file-name-transforms | 295 | (defcustom auto-save-file-name-transforms |
| 296 | `(("\\`/[^/]*:\\(.+/\\)*\\(.*\\)" | 296 | `(("\\`/[^/]*:\\([^/]*/\\)*\\([^/]*\\)\\'" |
| 297 | ;; Don't put "\\2" inside expand-file-name, since it will be | 297 | ;; Don't put "\\2" inside expand-file-name, since it will be |
| 298 | ;; transformed to "/2" on DOS/Windows. | 298 | ;; transformed to "/2" on DOS/Windows. |
| 299 | ,(concat temporary-file-directory "\\2") t)) | 299 | ,(concat temporary-file-directory "\\2") t)) |
diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog index 00a2634ee8c..68df8d0941e 100644 --- a/lisp/gnus/ChangeLog +++ b/lisp/gnus/ChangeLog | |||
| @@ -1,5 +1,7 @@ | |||
| 1 | 2004-05-18 Stefan Monnier <monnier@iro.umontreal.ca> | 1 | 2004-05-18 Stefan Monnier <monnier@iro.umontreal.ca> |
| 2 | 2 | ||
| 3 | * mm-view.el (mm-insert-inline): Make it work in read-only buffer. | ||
| 4 | |||
| 3 | * gnus-win.el (gnus-all-windows-visible-p): Don't consider | 5 | * gnus-win.el (gnus-all-windows-visible-p): Don't consider |
| 4 | non-visible windows. | 6 | non-visible windows. |
| 5 | 7 | ||
diff --git a/lisp/gnus/mm-view.el b/lisp/gnus/mm-view.el index f7dfdb60f02..69cbd3d8a1d 100644 --- a/lisp/gnus/mm-view.el +++ b/lisp/gnus/mm-view.el | |||
| @@ -1,5 +1,5 @@ | |||
| 1 | ;;; mm-view.el --- functions for viewing MIME objects | 1 | ;;; mm-view.el --- functions for viewing MIME objects |
| 2 | ;; Copyright (C) 1998, 1999, 2000, 2001 Free Software Foundation, Inc. | 2 | ;; Copyright (C) 1998, 1999, 2000, 01, 2004 Free Software Foundation, Inc. |
| 3 | 3 | ||
| 4 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> | 4 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> |
| 5 | ;; This file is part of GNU Emacs. | 5 | ;; This file is part of GNU Emacs. |
| @@ -197,7 +197,8 @@ | |||
| 197 | 197 | ||
| 198 | (defun mm-insert-inline (handle text) | 198 | (defun mm-insert-inline (handle text) |
| 199 | "Insert TEXT inline from HANDLE." | 199 | "Insert TEXT inline from HANDLE." |
| 200 | (let ((b (point))) | 200 | (let ((b (point)) |
| 201 | (inhibit-read-only t)) | ||
| 201 | (insert text) | 202 | (insert text) |
| 202 | (mm-handle-set-undisplayer | 203 | (mm-handle-set-undisplayer |
| 203 | handle | 204 | handle |
diff --git a/lisp/help-mode.el b/lisp/help-mode.el index 1f1b529c8ef..11656ec368c 100644 --- a/lisp/help-mode.el +++ b/lisp/help-mode.el | |||
| @@ -577,12 +577,11 @@ help buffer." | |||
| 577 | (goto-char position))))) | 577 | (goto-char position))))) |
| 578 | 578 | ||
| 579 | (defun help-go-back () | 579 | (defun help-go-back () |
| 580 | "Invoke the [back] button (if any) in the Help mode buffer." | 580 | "Go back to previous topic in this help buffer." |
| 581 | (interactive) | 581 | (interactive) |
| 582 | (let ((back-button (button-at (1- (point-max))))) | 582 | (if help-xref-stack |
| 583 | (if back-button | 583 | (help-xref-go-back (current-buffer)) |
| 584 | (button-activate back-button) | 584 | (error "No previous help buffer."))) |
| 585 | (error "No [back] button")))) | ||
| 586 | 585 | ||
| 587 | (defun help-do-xref (pos function args) | 586 | (defun help-do-xref (pos function args) |
| 588 | "Call the help cross-reference function FUNCTION with args ARGS. | 587 | "Call the help cross-reference function FUNCTION with args ARGS. |
diff --git a/lisp/international/characters.el b/lisp/international/characters.el index 7af456d1878..ebf2a3af27d 100644 --- a/lisp/international/characters.el +++ b/lisp/international/characters.el | |||
| @@ -229,6 +229,14 @@ | |||
| 229 | (modify-category-entry generic-char ?|) | 229 | (modify-category-entry generic-char ?|) |
| 230 | (setq cns-list (cdr cns-list)))) | 230 | (setq cns-list (cdr cns-list)))) |
| 231 | 231 | ||
| 232 | (let ((parens "$(G!>!?!@!A!B!C!D!E!F!G!H!I!J!K!L!M!N!O!P!Q!R!S!T!U!V!W!X!Y!Z![!\!]!^!_!`!a!b!c(B") | ||
| 233 | open close) | ||
| 234 | (dotimes (i (/ (length parens) 2)) | ||
| 235 | (setq open (aref parens (* i 2)) | ||
| 236 | close (aref parens (1+ (* i 2)))) | ||
| 237 | (modify-syntax-entry open (format "(%c" close)) | ||
| 238 | (modify-syntax-entry close (format ")%c" open)))) | ||
| 239 | |||
| 232 | ;; Cyrillic character set (ISO-8859-5) | 240 | ;; Cyrillic character set (ISO-8859-5) |
| 233 | 241 | ||
| 234 | (modify-category-entry (make-char 'cyrillic-iso8859-5) ?y) | 242 | (modify-category-entry (make-char 'cyrillic-iso8859-5) ?y) |
| @@ -584,16 +592,13 @@ | |||
| 584 | (while chars | 592 | (while chars |
| 585 | (modify-syntax-entry (car chars) "w") | 593 | (modify-syntax-entry (car chars) "w") |
| 586 | (setq chars (cdr chars)))) | 594 | (setq chars (cdr chars)))) |
| 587 | (modify-syntax-entry ?\$B!J(B "($B!K(B") | 595 | (let ((parens "$B!J!K!L!M!N!O!P!Q!R!S!T!U!V!W!X!Y!Z![(B" ) |
| 588 | (modify-syntax-entry ?\$B!N(B "($B!O(B") | 596 | open close) |
| 589 | (modify-syntax-entry ?\$B!P(B "($B!Q(B") | 597 | (dotimes (i (/ (length parens) 2)) |
| 590 | (modify-syntax-entry ?\$B!V(B "($B!W(B") | 598 | (setq open (aref parens (* i 2)) |
| 591 | (modify-syntax-entry ?\$B!X(B "($B!Y(B") | 599 | close (aref parens (1+ (* i 2)))) |
| 592 | (modify-syntax-entry ?\$B!K(B ")$B!J(B") | 600 | (modify-syntax-entry open (format "(%c" close)) |
| 593 | (modify-syntax-entry ?\$B!O(B ")$B!N(B") | 601 | (modify-syntax-entry close (format ")%c" open)))) |
| 594 | (modify-syntax-entry ?\$B!Q(B ")$B!P(B") | ||
| 595 | (modify-syntax-entry ?\$B!W(B ")$B!V(B") | ||
| 596 | (modify-syntax-entry ?\$B!Y(B ")$B!X(B") | ||
| 597 | 602 | ||
| 598 | (modify-category-entry (make-char 'japanese-jisx0208 35) ?A) | 603 | (modify-category-entry (make-char 'japanese-jisx0208 35) ?A) |
| 599 | (modify-category-entry (make-char 'japanese-jisx0208 36) ?H) | 604 | (modify-category-entry (make-char 'japanese-jisx0208 36) ?H) |
| @@ -652,6 +657,14 @@ | |||
| 652 | (modify-category-entry (make-char 'korean-ksc5601 43) ?K) | 657 | (modify-category-entry (make-char 'korean-ksc5601 43) ?K) |
| 653 | (modify-category-entry (make-char 'korean-ksc5601 44) ?Y) | 658 | (modify-category-entry (make-char 'korean-ksc5601 44) ?Y) |
| 654 | 659 | ||
| 660 | (let ((parens "$(C!2!3!4!5!6!7!8!9!:!;!<!=(B" ) | ||
| 661 | open close) | ||
| 662 | (dotimes (i (/ (length parens) 2)) | ||
| 663 | (setq open (aref parens (* i 2)) | ||
| 664 | close (aref parens (1+ (* i 2)))) | ||
| 665 | (modify-syntax-entry open (format "(%c" close)) | ||
| 666 | (modify-syntax-entry close (format ")%c" open)))) | ||
| 667 | |||
| 655 | ;; Latin character set (latin-1,2,3,4,5,8,9) | 668 | ;; Latin character set (latin-1,2,3,4,5,8,9) |
| 656 | 669 | ||
| 657 | (modify-category-entry (make-char 'latin-iso8859-1) ?l) | 670 | (modify-category-entry (make-char 'latin-iso8859-1) ?l) |
diff --git a/lisp/net/ldap.el b/lisp/net/ldap.el index 55af47e6a87..f093fb1cbcc 100644 --- a/lisp/net/ldap.el +++ b/lisp/net/ldap.el | |||
| @@ -554,7 +554,7 @@ an alist of attribute/value pairs." | |||
| 554 | (setq arglist (nconc arglist (list (format "-z%s" sizelimit))))) | 554 | (setq arglist (nconc arglist (list (format "-z%s" sizelimit))))) |
| 555 | (eval `(call-process ldap-ldapsearch-prog | 555 | (eval `(call-process ldap-ldapsearch-prog |
| 556 | nil | 556 | nil |
| 557 | buf | 557 | `(,buf nil) |
| 558 | nil | 558 | nil |
| 559 | ,@arglist | 559 | ,@arglist |
| 560 | ,@ldap-ldapsearch-args | 560 | ,@ldap-ldapsearch-args |
diff --git a/lisp/pcvs.el b/lisp/pcvs.el index 8cb21828d69..9e518d791ec 100644 --- a/lisp/pcvs.el +++ b/lisp/pcvs.el | |||
| @@ -764,7 +764,7 @@ before calling the real function `" (symbol-name fun-1) "'.\n") | |||
| 764 | (interactive) | 764 | (interactive) |
| 765 | (cvs-mode! ',fun-1))))) | 765 | (cvs-mode! ',fun-1))))) |
| 766 | 766 | ||
| 767 | (t (error "unknown style %s in `defun-cvs-mode'" style))))) | 767 | (t (error "Unknown style %s in `defun-cvs-mode'" style))))) |
| 768 | 768 | ||
| 769 | (defun-cvs-mode cvs-mode-kill-process () | 769 | (defun-cvs-mode cvs-mode-kill-process () |
| 770 | "Kill the temporary buffer and associated process." | 770 | "Kill the temporary buffer and associated process." |
diff --git a/lisp/progmodes/gdb-ui.el b/lisp/progmodes/gdb-ui.el index 19c57979130..1fa6f8f2645 100644 --- a/lisp/progmodes/gdb-ui.el +++ b/lisp/progmodes/gdb-ui.el | |||
| @@ -1728,15 +1728,15 @@ This arrangement depends on the value of `gdb-many-windows'." | |||
| 1728 | "Exit a debugging session cleanly by killing the gdb buffers and resetting | 1728 | "Exit a debugging session cleanly by killing the gdb buffers and resetting |
| 1729 | the source buffers." | 1729 | the source buffers." |
| 1730 | (dolist (buffer (buffer-list)) | 1730 | (dolist (buffer (buffer-list)) |
| 1731 | (if (not (eq buffer gud-comint-buffer)) | 1731 | (unless (eq buffer gud-comint-buffer) |
| 1732 | (with-current-buffer buffer | 1732 | (with-current-buffer buffer |
| 1733 | (if (memq gud-minor-mode '(gdba pdb)) | 1733 | (if (memq gud-minor-mode '(gdba pdb)) |
| 1734 | (if (string-match "^\*.+*$" (buffer-name)) | 1734 | (if (string-match "\\`\\*.+\\*\\'" (buffer-name)) |
| 1735 | (kill-buffer nil) | 1735 | (kill-buffer nil) |
| 1736 | (gdb-remove-breakpoint-icons (point-min) (point-max) t) | 1736 | (gdb-remove-breakpoint-icons (point-min) (point-max) t) |
| 1737 | (setq gud-minor-mode nil) | 1737 | (setq gud-minor-mode nil) |
| 1738 | (kill-local-variable 'tool-bar-map) | 1738 | (kill-local-variable 'tool-bar-map) |
| 1739 | (setq gud-running nil)))))) | 1739 | (setq gud-running nil)))))) |
| 1740 | (when (markerp gdb-overlay-arrow-position) | 1740 | (when (markerp gdb-overlay-arrow-position) |
| 1741 | (move-marker gdb-overlay-arrow-position nil) | 1741 | (move-marker gdb-overlay-arrow-position nil) |
| 1742 | (setq gdb-overlay-arrow-position nil)) | 1742 | (setq gdb-overlay-arrow-position nil)) |
| @@ -2013,5 +2013,5 @@ BUFFER nil or omitted means use the current buffer." | |||
| 2013 | 2013 | ||
| 2014 | (provide 'gdb-ui) | 2014 | (provide 'gdb-ui) |
| 2015 | 2015 | ||
| 2016 | ;;; arch-tag: e9fb00c5-74ef-469f-a088-37384caae352 | 2016 | ;; arch-tag: e9fb00c5-74ef-469f-a088-37384caae352 |
| 2017 | ;;; gdb-ui.el ends here | 2017 | ;;; gdb-ui.el ends here |
diff --git a/lisp/progmodes/gud.el b/lisp/progmodes/gud.el index 84dec78d895..eb0b887bdf3 100644 --- a/lisp/progmodes/gud.el +++ b/lisp/progmodes/gud.el | |||
| @@ -2554,12 +2554,11 @@ It is saved for when this flag is not set.") | |||
| 2554 | 2554 | ||
| 2555 | (defun gud-reset () | 2555 | (defun gud-reset () |
| 2556 | (dolist (buffer (buffer-list)) | 2556 | (dolist (buffer (buffer-list)) |
| 2557 | (if (not (eq buffer gud-comint-buffer)) | 2557 | (unless (eq buffer gud-comint-buffer) |
| 2558 | (save-excursion | 2558 | (with-current-buffer buffer |
| 2559 | (set-buffer buffer) | 2559 | (when gud-minor-mode |
| 2560 | (when gud-minor-mode | 2560 | (setq gud-minor-mode nil) |
| 2561 | (setq gud-minor-mode nil) | 2561 | (kill-local-variable 'tool-bar-map)))))) |
| 2562 | (kill-local-variable 'tool-bar-map)))))) | ||
| 2563 | 2562 | ||
| 2564 | (defun gud-display-frame () | 2563 | (defun gud-display-frame () |
| 2565 | "Find and obey the last filename-and-line marker from the debugger. | 2564 | "Find and obey the last filename-and-line marker from the debugger. |
diff --git a/lisp/simple.el b/lisp/simple.el index 95e3ab0580d..fc8553cb133 100644 --- a/lisp/simple.el +++ b/lisp/simple.el | |||
| @@ -3396,15 +3396,14 @@ Setting this variable automatically makes it local to the current buffer.") | |||
| 3396 | ;; (Actually some major modes use a different auto-fill function, | 3396 | ;; (Actually some major modes use a different auto-fill function, |
| 3397 | ;; but this one is the default one.) | 3397 | ;; but this one is the default one.) |
| 3398 | (defun do-auto-fill () | 3398 | (defun do-auto-fill () |
| 3399 | (let (fc justify bol give-up | 3399 | (let (fc justify give-up |
| 3400 | (fill-prefix fill-prefix)) | 3400 | (fill-prefix fill-prefix)) |
| 3401 | (if (or (not (setq justify (current-justification))) | 3401 | (if (or (not (setq justify (current-justification))) |
| 3402 | (null (setq fc (current-fill-column))) | 3402 | (null (setq fc (current-fill-column))) |
| 3403 | (and (eq justify 'left) | 3403 | (and (eq justify 'left) |
| 3404 | (<= (current-column) fc)) | 3404 | (<= (current-column) fc)) |
| 3405 | (save-excursion (beginning-of-line) | 3405 | (and auto-fill-inhibit-regexp |
| 3406 | (setq bol (point)) | 3406 | (save-excursion (beginning-of-line) |
| 3407 | (and auto-fill-inhibit-regexp | ||
| 3408 | (looking-at auto-fill-inhibit-regexp)))) | 3407 | (looking-at auto-fill-inhibit-regexp)))) |
| 3409 | nil ;; Auto-filling not required | 3408 | nil ;; Auto-filling not required |
| 3410 | (if (memq justify '(full center right)) | 3409 | (if (memq justify '(full center right)) |
| @@ -3427,16 +3426,15 @@ Setting this variable automatically makes it local to the current buffer.") | |||
| 3427 | ;; Determine where to split the line. | 3426 | ;; Determine where to split the line. |
| 3428 | (let* (after-prefix | 3427 | (let* (after-prefix |
| 3429 | (fill-point | 3428 | (fill-point |
| 3430 | (let ((opoint (point))) | 3429 | (save-excursion |
| 3431 | (save-excursion | 3430 | (beginning-of-line) |
| 3432 | (beginning-of-line) | 3431 | (setq after-prefix (point)) |
| 3433 | (setq after-prefix (point)) | 3432 | (and fill-prefix |
| 3434 | (and fill-prefix | 3433 | (looking-at (regexp-quote fill-prefix)) |
| 3435 | (looking-at (regexp-quote fill-prefix)) | 3434 | (setq after-prefix (match-end 0))) |
| 3436 | (setq after-prefix (match-end 0))) | 3435 | (move-to-column (1+ fc)) |
| 3437 | (move-to-column (1+ fc)) | 3436 | (fill-move-to-break-point after-prefix) |
| 3438 | (fill-move-to-break-point after-prefix) | 3437 | (point)))) |
| 3439 | (point))))) | ||
| 3440 | 3438 | ||
| 3441 | ;; See whether the place we found is any good. | 3439 | ;; See whether the place we found is any good. |
| 3442 | (if (save-excursion | 3440 | (if (save-excursion |
| @@ -4269,16 +4267,15 @@ of the differing parts is, by contrast, slightly highlighted." | |||
| 4269 | :group 'completion) | 4267 | :group 'completion) |
| 4270 | 4268 | ||
| 4271 | (defun completion-setup-function () | 4269 | (defun completion-setup-function () |
| 4272 | (save-excursion | 4270 | (let ((mainbuf (current-buffer)) |
| 4273 | (let ((mainbuf (current-buffer)) | 4271 | (mbuf-contents (minibuffer-contents))) |
| 4274 | (mbuf-contents (minibuffer-contents))) | 4272 | ;; When reading a file name in the minibuffer, |
| 4275 | ;; When reading a file name in the minibuffer, | 4273 | ;; set default-directory in the minibuffer |
| 4276 | ;; set default-directory in the minibuffer | 4274 | ;; so it will get copied into the completion list buffer. |
| 4277 | ;; so it will get copied into the completion list buffer. | 4275 | (if minibuffer-completing-file-name |
| 4278 | (if minibuffer-completing-file-name | 4276 | (with-current-buffer mainbuf |
| 4279 | (with-current-buffer mainbuf | 4277 | (setq default-directory (file-name-directory mbuf-contents)))) |
| 4280 | (setq default-directory (file-name-directory mbuf-contents)))) | 4278 | (with-current-buffer standard-output |
| 4281 | (set-buffer standard-output) | ||
| 4282 | (completion-list-mode) | 4279 | (completion-list-mode) |
| 4283 | (make-local-variable 'completion-reference-buffer) | 4280 | (make-local-variable 'completion-reference-buffer) |
| 4284 | (setq completion-reference-buffer mainbuf) | 4281 | (setq completion-reference-buffer mainbuf) |
| @@ -4287,24 +4284,23 @@ of the differing parts is, by contrast, slightly highlighted." | |||
| 4287 | ;; use the number of chars before the start of the | 4284 | ;; use the number of chars before the start of the |
| 4288 | ;; last file name component. | 4285 | ;; last file name component. |
| 4289 | (setq completion-base-size | 4286 | (setq completion-base-size |
| 4290 | (save-excursion | 4287 | (with-current-buffer mainbuf |
| 4291 | (set-buffer mainbuf) | 4288 | (save-excursion |
| 4292 | (goto-char (point-max)) | 4289 | (goto-char (point-max)) |
| 4293 | (skip-chars-backward "^/") | 4290 | (skip-chars-backward "^/") |
| 4294 | (- (point) (minibuffer-prompt-end)))) | 4291 | (- (point) (minibuffer-prompt-end))))) |
| 4295 | ;; Otherwise, in minibuffer, the whole input is being completed. | 4292 | ;; Otherwise, in minibuffer, the whole input is being completed. |
| 4296 | (save-match-data | 4293 | (if (minibufferp mainbuf) |
| 4297 | (if (minibufferp mainbuf) | 4294 | (setq completion-base-size 0))) |
| 4298 | (setq completion-base-size 0)))) | 4295 | ;; Put faces on first uncommon characters and common parts. |
| 4299 | ;; Put faces on first uncommon characters and common parts. | ||
| 4300 | (when completion-base-size | 4296 | (when completion-base-size |
| 4301 | (let* ((common-string-length (length | 4297 | (let* ((common-string-length |
| 4302 | (substring mbuf-contents | 4298 | (- (length mbuf-contents) completion-base-size)) |
| 4303 | completion-base-size))) | ||
| 4304 | (element-start (next-single-property-change | 4299 | (element-start (next-single-property-change |
| 4305 | (point-min) | 4300 | (point-min) |
| 4306 | 'mouse-face)) | 4301 | 'mouse-face)) |
| 4307 | (element-common-end (+ element-start common-string-length)) | 4302 | (element-common-end |
| 4303 | (+ (or element-start nil) common-string-length)) | ||
| 4308 | (maxp (point-max))) | 4304 | (maxp (point-max))) |
| 4309 | (while (and element-start (< element-common-end maxp)) | 4305 | (while (and element-start (< element-common-end maxp)) |
| 4310 | (when (and (get-char-property element-start 'mouse-face) | 4306 | (when (and (get-char-property element-start 'mouse-face) |
| @@ -4768,5 +4764,5 @@ works by saving the value of `buffer-invisibility-spec' and setting it to nil." | |||
| 4768 | 4764 | ||
| 4769 | (provide 'simple) | 4765 | (provide 'simple) |
| 4770 | 4766 | ||
| 4771 | ;;; arch-tag: 24af67c0-2a49-44f6-b3b1-312d8b570dfd | 4767 | ;; arch-tag: 24af67c0-2a49-44f6-b3b1-312d8b570dfd |
| 4772 | ;;; simple.el ends here | 4768 | ;;; simple.el ends here |
diff --git a/lisp/textmodes/tex-mode.el b/lisp/textmodes/tex-mode.el index 6e129987ec1..28bf9f6cf28 100644 --- a/lisp/textmodes/tex-mode.el +++ b/lisp/textmodes/tex-mode.el | |||
| @@ -1944,21 +1944,22 @@ for the error messages." | |||
| 1944 | (or (null last-filename) | 1944 | (or (null last-filename) |
| 1945 | (not (string-equal last-filename filename)))) | 1945 | (not (string-equal last-filename filename)))) |
| 1946 | (error-location | 1946 | (error-location |
| 1947 | (save-excursion | 1947 | (with-current-buffer |
| 1948 | (if (equal filename (concat tex-zap-file ".tex")) | 1948 | (if (equal filename (concat tex-zap-file ".tex")) |
| 1949 | (set-buffer tex-last-buffer-texed) | 1949 | tex-last-buffer-texed |
| 1950 | (set-buffer (find-file-noselect filename))) | 1950 | (find-file-noselect filename)) |
| 1951 | (if new-file | 1951 | (save-excursion |
| 1952 | (progn (goto-line linenum) (setq last-position nil)) | 1952 | (if new-file |
| 1953 | (goto-char last-position) | 1953 | (progn (goto-line linenum) (setq last-position nil)) |
| 1954 | (forward-line (- linenum last-linenum))) | 1954 | (goto-char last-position) |
| 1955 | ;; first try a forward search for the error text, | 1955 | (forward-line (- linenum last-linenum))) |
| 1956 | ;; then a backward search limited by the last error. | 1956 | ;; first try a forward search for the error text, |
| 1957 | (let ((starting-point (point))) | 1957 | ;; then a backward search limited by the last error. |
| 1958 | (or (re-search-forward error-text nil t) | 1958 | (let ((starting-point (point))) |
| 1959 | (re-search-backward error-text last-position t) | 1959 | (or (re-search-forward error-text nil t) |
| 1960 | (goto-char starting-point))) | 1960 | (re-search-backward error-text last-position t) |
| 1961 | (point-marker)))) | 1961 | (goto-char starting-point))) |
| 1962 | (point-marker))))) | ||
| 1962 | (goto-char this-error) | 1963 | (goto-char this-error) |
| 1963 | (if (and compilation-error-list | 1964 | (if (and compilation-error-list |
| 1964 | (or (and find-at-least | 1965 | (or (and find-at-least |
diff --git a/lisp/wid-edit.el b/lisp/wid-edit.el index b1a89e4fbef..33f1f06ba9a 100644 --- a/lisp/wid-edit.el +++ b/lisp/wid-edit.el | |||
| @@ -2294,7 +2294,7 @@ Return an alist of (TYPE MATCH)." | |||
| 2294 | 2294 | ||
| 2295 | (defun widget-radio-button-notify (widget child &optional event) | 2295 | (defun widget-radio-button-notify (widget child &optional event) |
| 2296 | ;; Tell daddy. | 2296 | ;; Tell daddy. |
| 2297 | (widget-apply (widget-get widget :parent) :action event)) | 2297 | (widget-apply (widget-get widget :parent) :action widget event)) |
| 2298 | 2298 | ||
| 2299 | ;;; The `radio-button-choice' Widget. | 2299 | ;;; The `radio-button-choice' Widget. |
| 2300 | 2300 | ||
diff --git a/lispref/ChangeLog b/lispref/ChangeLog index c46f718b5c7..c2f4f188496 100644 --- a/lispref/ChangeLog +++ b/lispref/ChangeLog | |||
| @@ -1,3 +1,7 @@ | |||
| 1 | 2004-05-19 Thien-Thi Nguyen <ttn@gnu.org> | ||
| 2 | |||
| 3 | * modes.texi (Search-based Fontification): Fix typo. | ||
| 4 | |||
| 1 | 2004-05-10 Juanma Barranquero <lektu@terra.es> | 5 | 2004-05-10 Juanma Barranquero <lektu@terra.es> |
| 2 | 6 | ||
| 3 | * modes.texi (Mode Line Variables): Fix description of | 7 | * modes.texi (Mode Line Variables): Fix description of |
diff --git a/lispref/modes.texi b/lispref/modes.texi index 4a8d83ecfa0..d92ea309ed7 100644 --- a/lispref/modes.texi +++ b/lispref/modes.texi | |||
| @@ -2001,7 +2001,7 @@ Find text by calling @var{function}, and highlight the matches | |||
| 2001 | it finds using @code{font-lock-keyword-face}. | 2001 | it finds using @code{font-lock-keyword-face}. |
| 2002 | 2002 | ||
| 2003 | When @var{function} is called, it receives one argument, the limit of | 2003 | When @var{function} is called, it receives one argument, the limit of |
| 2004 | the search; it should searching at point, and not search beyond the | 2004 | the search; it should begin searching at point, and not search beyond the |
| 2005 | limit. It should return non-@code{nil} if it succeeds, and set the | 2005 | limit. It should return non-@code{nil} if it succeeds, and set the |
| 2006 | match data to describe the match that was found. Returning @code{nil} | 2006 | match data to describe the match that was found. Returning @code{nil} |
| 2007 | indicates failure of the search. | 2007 | indicates failure of the search. |
diff --git a/man/search.texi b/man/search.texi index 303074dcf0d..fbc8d24bf23 100644 --- a/man/search.texi +++ b/man/search.texi | |||
| @@ -724,6 +724,18 @@ determines which characters these are. @xref{Syntax}. | |||
| 724 | @item \W | 724 | @item \W |
| 725 | matches any character that is not a word-constituent. | 725 | matches any character that is not a word-constituent. |
| 726 | 726 | ||
| 727 | @item \_< | ||
| 728 | matches the empty string, but only at the beginning of a symbol. A | ||
| 729 | symbol is a sequence of one or more word or symbol constituent | ||
| 730 | characters. @samp{\_<} matches at the beginning of the buffer only if | ||
| 731 | a symbol-constituent character follows. | ||
| 732 | |||
| 733 | @item \_> | ||
| 734 | matches the empty string, but only at the end of a symbol. A symbol | ||
| 735 | is a sequence of one or more word or symbol constituent characters. | ||
| 736 | @samp{\_>} matches at the end of the buffer only if the contents end | ||
| 737 | with a symbol-constituent character. | ||
| 738 | |||
| 727 | @item \s@var{c} | 739 | @item \s@var{c} |
| 728 | matches any character whose syntax is @var{c}. Here @var{c} is a | 740 | matches any character whose syntax is @var{c}. Here @var{c} is a |
| 729 | character that designates a particular syntax class: thus, @samp{w} | 741 | character that designates a particular syntax class: thus, @samp{w} |
diff --git a/src/.gdbinit b/src/.gdbinit index c976d3633de..3af7e369923 100644 --- a/src/.gdbinit +++ b/src/.gdbinit | |||
| @@ -186,9 +186,10 @@ Print $ as a buffer-local-value pointer, assuming it is an Emacs Lisp Misc value | |||
| 186 | end | 186 | end |
| 187 | 187 | ||
| 188 | define xsymbol | 188 | define xsymbol |
| 189 | xgetptr $ | 189 | set $sym = $ |
| 190 | xgetptr $sym | ||
| 190 | print (struct Lisp_Symbol *) $ptr | 191 | print (struct Lisp_Symbol *) $ptr |
| 191 | xprintsym $ | 192 | xprintsym $sym |
| 192 | echo \n | 193 | echo \n |
| 193 | end | 194 | end |
| 194 | document xsymbol | 195 | document xsymbol |
| @@ -199,7 +200,7 @@ end | |||
| 199 | define xstring | 200 | define xstring |
| 200 | xgetptr $ | 201 | xgetptr $ |
| 201 | print (struct Lisp_String *) $ptr | 202 | print (struct Lisp_String *) $ptr |
| 202 | output ($->size > 1000) ? 0 : ($->data[0])@($->size_byte < 0 ? $->size & ~gdb_array_mark_flag : $->size_byte) | 203 | xprintstr $ |
| 203 | echo \n | 204 | echo \n |
| 204 | end | 205 | end |
| 205 | document xstring | 206 | document xstring |
| @@ -372,12 +373,17 @@ document xscrollbar | |||
| 372 | Print $ as a scrollbar pointer. | 373 | Print $ as a scrollbar pointer. |
| 373 | end | 374 | end |
| 374 | 375 | ||
| 376 | define xprintstr | ||
| 377 | set $data = $arg0->data | ||
| 378 | output ($arg0->size > 1000) ? 0 : ($data[0])@($arg0->size_byte < 0 ? $arg0->size & ~gdb_array_mark_flag : $arg0->size_byte) | ||
| 379 | end | ||
| 380 | |||
| 375 | define xprintsym | 381 | define xprintsym |
| 376 | xgetptr $arg0 | 382 | xgetptr $arg0 |
| 377 | set $sym = (struct Lisp_Symbol *) $ptr | 383 | set $sym = (struct Lisp_Symbol *) $ptr |
| 378 | xgetptr $sym->xname | 384 | xgetptr $sym->xname |
| 379 | set $sym_name = (struct Lisp_String *) $ptr | 385 | set $sym_name = (struct Lisp_String *) $ptr |
| 380 | output ($sym_name->data[0])@($sym_name->size_byte < 0 ? $sym_name->size & ~gdb_array_mark_flag : $sym_name->size_byte) | 386 | xprintstr $sym_name |
| 381 | end | 387 | end |
| 382 | document xprintsym | 388 | document xprintsym |
| 383 | Print argument as a symbol. | 389 | Print argument as a symbol. |
diff --git a/src/ChangeLog b/src/ChangeLog index 7425754e042..c1f0706b928 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,47 @@ | |||
| 1 | 2004-05-19 Jim Blandy <jimb@redhat.com> | ||
| 2 | |||
| 3 | Add support for new '\_<' and '\_>' regexp operators, matching the | ||
| 4 | beginning and ends of symbols. | ||
| 5 | * regex.c (enum syntaxcode): Add Ssymbol. | ||
| 6 | (init_syntax_once): Set the syntax for '_' to Ssymbol, not Sword. | ||
| 7 | (re_opcode_t): New opcodes `symbeg' and `symend'. | ||
| 8 | (print_partial_compiled_pattern): Print the new opcodes properly. | ||
| 9 | (regex_compile): Parse the new operators. | ||
| 10 | (analyse_first): Skip symbeg and symend (they match only the empty string). | ||
| 11 | (mutually_exclusive_p): `symend' is mutually exclusive with \s_ and | ||
| 12 | \sw; `symbeg' is mutually exclusive with \S_ and \Sw. | ||
| 13 | (re_match_2_internal): Match symbeg and symend. | ||
| 14 | |||
| 15 | * search.c (trivial_regexp_p): \_ is no longer a trivial regexp. | ||
| 16 | |||
| 17 | 2004-05-19 Kim F. Storm <storm@cua.dk> | ||
| 18 | |||
| 19 | * .gdbinit (xsymbol): Fix last change. | ||
| 20 | |||
| 21 | 2004-05-18 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 22 | |||
| 23 | * .gdbinit (xprintstr): New fun. | ||
| 24 | (xstring, xprintsym): Use it. | ||
| 25 | |||
| 26 | * w32proc.c (create_child): Use INTMASK. | ||
| 27 | |||
| 28 | * alloc.c (Fgarbage_collect): Do all the marking before flushing | ||
| 29 | unmarked elements of the undo list. | ||
| 30 | |||
| 31 | 2004-05-18 David Ponce <david@dponce.com> | ||
| 32 | |||
| 33 | * print.c (print): Reset print_depth before to call print_object. | ||
| 34 | |||
| 35 | 2004-05-18 Jason Rumney <jasonr@gnu.org> | ||
| 36 | |||
| 37 | * w32console.c: Prefix RIF functions with w32con_ to avoid | ||
| 38 | namespace clash with functions in term.c and w32term.c. | ||
| 39 | |||
| 40 | * w32menu.c (add_menu_item, w32_menu_display_help) | ||
| 41 | [USE_LISP_UNION_TYPE]: Cast from Lisp_Object using i member. | ||
| 42 | |||
| 43 | * w32term.h (display_x_get_resource, vga_stdcolor_name): Add prototype. | ||
| 44 | |||
| 1 | 2004-05-18 Eli Zaretskii <eliz@gnu.org> | 45 | 2004-05-18 Eli Zaretskii <eliz@gnu.org> |
| 2 | 46 | ||
| 3 | * lisp.h (DECL_ALIGN): Remove restriction on MS-DOS systems. | 47 | * lisp.h (DECL_ALIGN): Remove restriction on MS-DOS systems. |
| @@ -97,12 +141,16 @@ | |||
| 97 | section to frame.c section. | 141 | section to frame.c section. |
| 98 | (Fxw_display_color_p, Fx_file_dialog): Declare if | 142 | (Fxw_display_color_p, Fx_file_dialog): Declare if |
| 99 | HAVE_WINDOW_SYSTEM defined. | 143 | HAVE_WINDOW_SYSTEM defined. |
| 144 | |||
| 100 | * macfns.c (Fx_create_frame): Fix int/Lisp_Object mixup. | 145 | * macfns.c (Fx_create_frame): Fix int/Lisp_Object mixup. |
| 146 | |||
| 101 | * macmenu.c (set_frame_menubar): Use NILP to test a lisp value. | 147 | * macmenu.c (set_frame_menubar): Use NILP to test a lisp value. |
| 148 | |||
| 102 | * macterm.c (mac_get_emulated_btn, mac_event_to_emacs_modifiers) | 149 | * macterm.c (mac_get_emulated_btn, mac_event_to_emacs_modifiers) |
| 103 | (mac_get_mouse_btn): Use NILP and EQ to test/compare lisp values. | 150 | (mac_get_mouse_btn): Use NILP and EQ to test/compare lisp values. |
| 104 | (XTread_socket): Fix int/Lisp_Object mixup. | 151 | (XTread_socket): Fix int/Lisp_Object mixup. |
| 105 | (mac_check_for_quit_char): Fix pointer/Lisp_Object mixup. | 152 | (mac_check_for_quit_char): Fix pointer/Lisp_Object mixup. |
| 153 | |||
| 106 | * macterm.h (struct frame, struct face, struct image) | 154 | * macterm.h (struct frame, struct face, struct image) |
| 107 | (display_x_get_resource, Fx_display_color_p) | 155 | (display_x_get_resource, Fx_display_color_p) |
| 108 | (Fx_display_grayscale_p, Fx_display_planes, x_free_gcs): | 156 | (Fx_display_grayscale_p, Fx_display_planes, x_free_gcs): |
| @@ -246,6 +294,7 @@ | |||
| 246 | around call to ReceiveEvent to avoid certain crashes. | 294 | around call to ReceiveEvent to avoid certain crashes. |
| 247 | 295 | ||
| 248 | 2004-05-07 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> | 296 | 2004-05-07 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> |
| 297 | |||
| 249 | * macterm.c (mac_draw_line_to_pixmap, XCreatePixmapFromBitmapData) | 298 | * macterm.c (mac_draw_line_to_pixmap, XCreatePixmapFromBitmapData) |
| 250 | (mac_fill_rectangle_to_pixmap, mac_draw_rectangle_to_pixmap) | 299 | (mac_fill_rectangle_to_pixmap, mac_draw_rectangle_to_pixmap) |
| 251 | (mac_copy_area_to_pixmap, mac_copy_area_with_mask_to_pixmap): | 300 | (mac_copy_area_to_pixmap, mac_copy_area_with_mask_to_pixmap): |
diff --git a/src/print.c b/src/print.c index 74f8fad8d15..0e07cd6fdd3 100644 --- a/src/print.c +++ b/src/print.c | |||
| @@ -1220,7 +1220,6 @@ print (obj, printcharfun, escapeflag) | |||
| 1220 | register Lisp_Object printcharfun; | 1220 | register Lisp_Object printcharfun; |
| 1221 | int escapeflag; | 1221 | int escapeflag; |
| 1222 | { | 1222 | { |
| 1223 | print_depth = 0; | ||
| 1224 | old_backquote_output = 0; | 1223 | old_backquote_output = 0; |
| 1225 | 1224 | ||
| 1226 | /* Reset print_number_index and Vprint_number_table only when | 1225 | /* Reset print_number_index and Vprint_number_table only when |
| @@ -1240,6 +1239,7 @@ print (obj, printcharfun, escapeflag) | |||
| 1240 | start = index = print_number_index; | 1239 | start = index = print_number_index; |
| 1241 | /* Construct Vprint_number_table. | 1240 | /* Construct Vprint_number_table. |
| 1242 | This increments print_number_index for the objects added. */ | 1241 | This increments print_number_index for the objects added. */ |
| 1242 | print_depth = 0; | ||
| 1243 | print_preprocess (obj); | 1243 | print_preprocess (obj); |
| 1244 | 1244 | ||
| 1245 | /* Remove unnecessary objects, which appear only once in OBJ; | 1245 | /* Remove unnecessary objects, which appear only once in OBJ; |
| @@ -1264,6 +1264,7 @@ print (obj, printcharfun, escapeflag) | |||
| 1264 | print_number_index = index; | 1264 | print_number_index = index; |
| 1265 | } | 1265 | } |
| 1266 | 1266 | ||
| 1267 | print_depth = 0; | ||
| 1267 | print_object (obj, printcharfun, escapeflag); | 1268 | print_object (obj, printcharfun, escapeflag); |
| 1268 | } | 1269 | } |
| 1269 | 1270 | ||
diff --git a/src/regex.c b/src/regex.c index a518ef81a0c..0c1343bf584 100644 --- a/src/regex.c +++ b/src/regex.c | |||
| @@ -2,7 +2,7 @@ | |||
| 2 | 0.12. (Implements POSIX draft P1003.2/D11.2, except for some of the | 2 | 0.12. (Implements POSIX draft P1003.2/D11.2, except for some of the |
| 3 | internationalization features.) | 3 | internationalization features.) |
| 4 | 4 | ||
| 5 | Copyright (C) 1993,94,95,96,97,98,99,2000 Free Software Foundation, Inc. | 5 | Copyright (C) 1993,94,95,96,97,98,99,2000,04 Free Software Foundation, Inc. |
| 6 | 6 | ||
| 7 | This program is free software; you can redistribute it and/or modify | 7 | This program is free software; you can redistribute it and/or modify |
| 8 | it under the terms of the GNU General Public License as published by | 8 | it under the terms of the GNU General Public License as published by |
| @@ -217,7 +217,7 @@ char *realloc (); | |||
| 217 | /* Define the syntax stuff for \<, \>, etc. */ | 217 | /* Define the syntax stuff for \<, \>, etc. */ |
| 218 | 218 | ||
| 219 | /* Sword must be nonzero for the wordchar pattern commands in re_match_2. */ | 219 | /* Sword must be nonzero for the wordchar pattern commands in re_match_2. */ |
| 220 | enum syntaxcode { Swhitespace = 0, Sword = 1 }; | 220 | enum syntaxcode { Swhitespace = 0, Sword = 1, Ssymbol = 2 }; |
| 221 | 221 | ||
| 222 | # ifdef SWITCH_ENUM_BUG | 222 | # ifdef SWITCH_ENUM_BUG |
| 223 | # define SWITCH_ENUM_CAST(x) ((int)(x)) | 223 | # define SWITCH_ENUM_CAST(x) ((int)(x)) |
| @@ -398,7 +398,7 @@ init_syntax_once () | |||
| 398 | if (ISALNUM (c)) | 398 | if (ISALNUM (c)) |
| 399 | re_syntax_table[c] = Sword; | 399 | re_syntax_table[c] = Sword; |
| 400 | 400 | ||
| 401 | re_syntax_table['_'] = Sword; | 401 | re_syntax_table['_'] = Ssymbol; |
| 402 | 402 | ||
| 403 | done = 1; | 403 | done = 1; |
| 404 | } | 404 | } |
| @@ -655,6 +655,9 @@ typedef enum | |||
| 655 | wordbound, /* Succeeds if at a word boundary. */ | 655 | wordbound, /* Succeeds if at a word boundary. */ |
| 656 | notwordbound, /* Succeeds if not at a word boundary. */ | 656 | notwordbound, /* Succeeds if not at a word boundary. */ |
| 657 | 657 | ||
| 658 | symbeg, /* Succeeds if at symbol beginning. */ | ||
| 659 | symend, /* Succeeds if at symbol end. */ | ||
| 660 | |||
| 658 | /* Matches any character whose syntax is specified. Followed by | 661 | /* Matches any character whose syntax is specified. Followed by |
| 659 | a byte which contains a syntax code, e.g., Sword. */ | 662 | a byte which contains a syntax code, e.g., Sword. */ |
| 660 | syntaxspec, | 663 | syntaxspec, |
| @@ -1094,6 +1097,14 @@ print_partial_compiled_pattern (start, end) | |||
| 1094 | case wordend: | 1097 | case wordend: |
| 1095 | fprintf (stderr, "/wordend"); | 1098 | fprintf (stderr, "/wordend"); |
| 1096 | 1099 | ||
| 1100 | case symbeg: | ||
| 1101 | printf ("/symbeg"); | ||
| 1102 | break; | ||
| 1103 | |||
| 1104 | case symend: | ||
| 1105 | printf ("/symend"); | ||
| 1106 | break; | ||
| 1107 | |||
| 1097 | case syntaxspec: | 1108 | case syntaxspec: |
| 1098 | fprintf (stderr, "/syntaxspec"); | 1109 | fprintf (stderr, "/syntaxspec"); |
| 1099 | mcnt = *p++; | 1110 | mcnt = *p++; |
| @@ -3398,6 +3409,19 @@ regex_compile (pattern, size, syntax, bufp) | |||
| 3398 | BUF_PUSH (wordend); | 3409 | BUF_PUSH (wordend); |
| 3399 | break; | 3410 | break; |
| 3400 | 3411 | ||
| 3412 | case '_': | ||
| 3413 | if (syntax & RE_NO_GNU_OPS) | ||
| 3414 | goto normal_char; | ||
| 3415 | laststart = b; | ||
| 3416 | PATFETCH (c); | ||
| 3417 | if (c == '<') | ||
| 3418 | BUF_PUSH (symbeg); | ||
| 3419 | else if (c == '>') | ||
| 3420 | BUF_PUSH (symend); | ||
| 3421 | else | ||
| 3422 | FREE_STACK_RETURN (REG_BADPAT); | ||
| 3423 | break; | ||
| 3424 | |||
| 3401 | case 'b': | 3425 | case 'b': |
| 3402 | if (syntax & RE_NO_GNU_OPS) | 3426 | if (syntax & RE_NO_GNU_OPS) |
| 3403 | goto normal_char; | 3427 | goto normal_char; |
| @@ -3890,6 +3914,8 @@ analyse_first (p, pend, fastmap, multibyte) | |||
| 3890 | case notwordbound: | 3914 | case notwordbound: |
| 3891 | case wordbeg: | 3915 | case wordbeg: |
| 3892 | case wordend: | 3916 | case wordend: |
| 3917 | case symbeg: | ||
| 3918 | case symend: | ||
| 3893 | continue; | 3919 | continue; |
| 3894 | 3920 | ||
| 3895 | 3921 | ||
| @@ -4654,14 +4680,20 @@ mutually_exclusive_p (bufp, p1, p2) | |||
| 4654 | break; | 4680 | break; |
| 4655 | 4681 | ||
| 4656 | case wordend: | 4682 | case wordend: |
| 4657 | case notsyntaxspec: | 4683 | return ((re_opcode_t) *p1 == syntaxspec && p1[1] == Sword); |
| 4684 | case symend: | ||
| 4658 | return ((re_opcode_t) *p1 == syntaxspec | 4685 | return ((re_opcode_t) *p1 == syntaxspec |
| 4659 | && p1[1] == (op2 == wordend ? Sword : p2[1])); | 4686 | && (p1[1] == Ssymbol || p1[1] == Sword)); |
| 4687 | case notsyntaxspec: | ||
| 4688 | return ((re_opcode_t) *p1 == syntaxspec && p1[1] == p2[1]); | ||
| 4660 | 4689 | ||
| 4661 | case wordbeg: | 4690 | case wordbeg: |
| 4662 | case syntaxspec: | 4691 | return ((re_opcode_t) *p1 == notsyntaxspec && p1[1] == Sword); |
| 4692 | case symbeg: | ||
| 4663 | return ((re_opcode_t) *p1 == notsyntaxspec | 4693 | return ((re_opcode_t) *p1 == notsyntaxspec |
| 4664 | && p1[1] == (op2 == wordbeg ? Sword : p2[1])); | 4694 | && (p1[1] == Ssymbol || p1[1] == Sword)); |
| 4695 | case syntaxspec: | ||
| 4696 | return ((re_opcode_t) *p1 == notsyntaxspec && p1[1] == p2[1]); | ||
| 4665 | 4697 | ||
| 4666 | case wordbound: | 4698 | case wordbound: |
| 4667 | return (((re_opcode_t) *p1 == notsyntaxspec | 4699 | return (((re_opcode_t) *p1 == notsyntaxspec |
| @@ -5803,6 +5835,92 @@ re_match_2_internal (bufp, string1, size1, string2, size2, pos, regs, stop) | |||
| 5803 | } | 5835 | } |
| 5804 | break; | 5836 | break; |
| 5805 | 5837 | ||
| 5838 | case symbeg: | ||
| 5839 | DEBUG_PRINT1 ("EXECUTING symbeg.\n"); | ||
| 5840 | |||
| 5841 | /* We FAIL in one of the following cases: */ | ||
| 5842 | |||
| 5843 | /* Case 1: D is at the end of string. */ | ||
| 5844 | if (AT_STRINGS_END (d)) | ||
| 5845 | goto fail; | ||
| 5846 | else | ||
| 5847 | { | ||
| 5848 | /* C1 is the character before D, S1 is the syntax of C1, C2 | ||
| 5849 | is the character at D, and S2 is the syntax of C2. */ | ||
| 5850 | re_wchar_t c1, c2; | ||
| 5851 | int s1, s2; | ||
| 5852 | #ifdef emacs | ||
| 5853 | int offset = PTR_TO_OFFSET (d); | ||
| 5854 | int charpos = SYNTAX_TABLE_BYTE_TO_CHAR (offset); | ||
| 5855 | UPDATE_SYNTAX_TABLE (charpos); | ||
| 5856 | #endif | ||
| 5857 | PREFETCH (); | ||
| 5858 | c2 = RE_STRING_CHAR (d, dend - d); | ||
| 5859 | s2 = SYNTAX (c2); | ||
| 5860 | |||
| 5861 | /* Case 2: S2 is neither Sword nor Ssymbol. */ | ||
| 5862 | if (s2 != Sword && s2 != Ssymbol) | ||
| 5863 | goto fail; | ||
| 5864 | |||
| 5865 | /* Case 3: D is not at the beginning of string ... */ | ||
| 5866 | if (!AT_STRINGS_BEG (d)) | ||
| 5867 | { | ||
| 5868 | GET_CHAR_BEFORE_2 (c1, d, string1, end1, string2, end2); | ||
| 5869 | #ifdef emacs | ||
| 5870 | UPDATE_SYNTAX_TABLE_BACKWARD (charpos - 1); | ||
| 5871 | #endif | ||
| 5872 | s1 = SYNTAX (c1); | ||
| 5873 | |||
| 5874 | /* ... and S1 is Sword or Ssymbol. */ | ||
| 5875 | if (s1 == Sword || s1 == Ssymbol) | ||
| 5876 | goto fail; | ||
| 5877 | } | ||
| 5878 | } | ||
| 5879 | break; | ||
| 5880 | |||
| 5881 | case symend: | ||
| 5882 | DEBUG_PRINT1 ("EXECUTING symend.\n"); | ||
| 5883 | |||
| 5884 | /* We FAIL in one of the following cases: */ | ||
| 5885 | |||
| 5886 | /* Case 1: D is at the beginning of string. */ | ||
| 5887 | if (AT_STRINGS_BEG (d)) | ||
| 5888 | goto fail; | ||
| 5889 | else | ||
| 5890 | { | ||
| 5891 | /* C1 is the character before D, S1 is the syntax of C1, C2 | ||
| 5892 | is the character at D, and S2 is the syntax of C2. */ | ||
| 5893 | re_wchar_t c1, c2; | ||
| 5894 | int s1, s2; | ||
| 5895 | #ifdef emacs | ||
| 5896 | int offset = PTR_TO_OFFSET (d) - 1; | ||
| 5897 | int charpos = SYNTAX_TABLE_BYTE_TO_CHAR (offset); | ||
| 5898 | UPDATE_SYNTAX_TABLE (charpos); | ||
| 5899 | #endif | ||
| 5900 | GET_CHAR_BEFORE_2 (c1, d, string1, end1, string2, end2); | ||
| 5901 | s1 = SYNTAX (c1); | ||
| 5902 | |||
| 5903 | /* Case 2: S1 is neither Ssymbol nor Sword. */ | ||
| 5904 | if (s1 != Sword && s1 != Ssymbol) | ||
| 5905 | goto fail; | ||
| 5906 | |||
| 5907 | /* Case 3: D is not at the end of string ... */ | ||
| 5908 | if (!AT_STRINGS_END (d)) | ||
| 5909 | { | ||
| 5910 | PREFETCH_NOLIMIT (); | ||
| 5911 | c2 = RE_STRING_CHAR (d, dend - d); | ||
| 5912 | #ifdef emacs | ||
| 5913 | UPDATE_SYNTAX_TABLE_FORWARD (charpos); | ||
| 5914 | #endif | ||
| 5915 | s2 = SYNTAX (c2); | ||
| 5916 | |||
| 5917 | /* ... and S2 is Sword or Ssymbol. */ | ||
| 5918 | if (s2 == Sword || s2 == Ssymbol) | ||
| 5919 | goto fail; | ||
| 5920 | } | ||
| 5921 | } | ||
| 5922 | break; | ||
| 5923 | |||
| 5806 | case syntaxspec: | 5924 | case syntaxspec: |
| 5807 | case notsyntaxspec: | 5925 | case notsyntaxspec: |
| 5808 | not = (re_opcode_t) *(p - 1) == notsyntaxspec; | 5926 | not = (re_opcode_t) *(p - 1) == notsyntaxspec; |
diff --git a/src/search.c b/src/search.c index c60d68b9374..e5e4c3f867a 100644 --- a/src/search.c +++ b/src/search.c | |||
| @@ -957,7 +957,7 @@ trivial_regexp_p (regexp) | |||
| 957 | { | 957 | { |
| 958 | case '|': case '(': case ')': case '`': case '\'': case 'b': | 958 | case '|': case '(': case ')': case '`': case '\'': case 'b': |
| 959 | case 'B': case '<': case '>': case 'w': case 'W': case 's': | 959 | case 'B': case '<': case '>': case 'w': case 'W': case 's': |
| 960 | case 'S': case '=': case '{': case '}': | 960 | case 'S': case '=': case '{': case '}': case '_': |
| 961 | case 'c': case 'C': /* for categoryspec and notcategoryspec */ | 961 | case 'c': case 'C': /* for categoryspec and notcategoryspec */ |
| 962 | case '1': case '2': case '3': case '4': case '5': | 962 | case '1': case '2': case '3': case '4': case '5': |
| 963 | case '6': case '7': case '8': case '9': | 963 | case '6': case '7': case '8': case '9': |
diff --git a/src/w32console.c b/src/w32console.c index b2d340d579c..74a8fd6338e 100644 --- a/src/w32console.c +++ b/src/w32console.c | |||
| @@ -53,20 +53,20 @@ extern int read_input_pending (); | |||
| 53 | extern struct frame * updating_frame; | 53 | extern struct frame * updating_frame; |
| 54 | extern int meta_key; | 54 | extern int meta_key; |
| 55 | 55 | ||
| 56 | static void move_cursor (int row, int col); | 56 | static void w32con_move_cursor (int row, int col); |
| 57 | static void clear_to_end (void); | 57 | static void w32con_clear_to_end (void); |
| 58 | void clear_frame (void); | 58 | static void w32con_clear_frame (void); |
| 59 | void clear_end_of_line (int); | 59 | static void w32con_clear_end_of_line (int); |
| 60 | static void ins_del_lines (int vpos, int n); | 60 | static void w32con_ins_del_lines (int vpos, int n); |
| 61 | void insert_glyphs (struct glyph *start, int len); | 61 | static void w32con_insert_glyphs (struct glyph *start, int len); |
| 62 | void write_glyphs (struct glyph *string, int len); | 62 | static void w32con_write_glyphs (struct glyph *string, int len); |
| 63 | void delete_glyphs (int n); | 63 | static void w32con_delete_glyphs (int n); |
| 64 | void w32_sys_ring_bell (void); | 64 | void w32_sys_ring_bell (void); |
| 65 | void reset_terminal_modes (void); | 65 | static void w32con_reset_terminal_modes (void); |
| 66 | void set_terminal_modes (void); | 66 | static void w32con_set_terminal_modes (void); |
| 67 | void set_terminal_window (int size); | 67 | static void w32con_set_terminal_window (int size); |
| 68 | void update_begin (struct frame * f); | 68 | static void w32con_update_begin (struct frame * f); |
| 69 | void update_end (struct frame * f); | 69 | static void w32con_update_end (struct frame * f); |
| 70 | static WORD w32_face_attributes (struct frame *f, int face_id); | 70 | static WORD w32_face_attributes (struct frame *f, int face_id); |
| 71 | 71 | ||
| 72 | static COORD cursor_coords; | 72 | static COORD cursor_coords; |
| @@ -104,7 +104,7 @@ ctrl_c_handler (unsigned long type) | |||
| 104 | 104 | ||
| 105 | /* Move the cursor to (row, col). */ | 105 | /* Move the cursor to (row, col). */ |
| 106 | static void | 106 | static void |
| 107 | move_cursor (int row, int col) | 107 | w32con_move_cursor (int row, int col) |
| 108 | { | 108 | { |
| 109 | cursor_coords.X = col; | 109 | cursor_coords.X = col; |
| 110 | cursor_coords.Y = row; | 110 | cursor_coords.Y = row; |
| @@ -117,17 +117,17 @@ move_cursor (int row, int col) | |||
| 117 | 117 | ||
| 118 | /* Clear from cursor to end of screen. */ | 118 | /* Clear from cursor to end of screen. */ |
| 119 | static void | 119 | static void |
| 120 | clear_to_end (void) | 120 | w32con_clear_to_end (void) |
| 121 | { | 121 | { |
| 122 | struct frame * f = PICK_FRAME (); | 122 | struct frame * f = PICK_FRAME (); |
| 123 | 123 | ||
| 124 | clear_end_of_line (FRAME_COLS (f) - 1); | 124 | w32con_clear_end_of_line (FRAME_COLS (f) - 1); |
| 125 | ins_del_lines (cursor_coords.Y, FRAME_LINES (f) - cursor_coords.Y - 1); | 125 | w32con_ins_del_lines (cursor_coords.Y, FRAME_LINES (f) - cursor_coords.Y - 1); |
| 126 | } | 126 | } |
| 127 | 127 | ||
| 128 | /* Clear the frame. */ | 128 | /* Clear the frame. */ |
| 129 | void | 129 | static void |
| 130 | clear_frame (void) | 130 | w32con_clear_frame (void) |
| 131 | { | 131 | { |
| 132 | struct frame * f = PICK_FRAME (); | 132 | struct frame * f = PICK_FRAME (); |
| 133 | COORD dest; | 133 | COORD dest; |
| @@ -144,7 +144,7 @@ clear_frame (void) | |||
| 144 | FillConsoleOutputAttribute (cur_screen, char_attr_normal, n, dest, &r); | 144 | FillConsoleOutputAttribute (cur_screen, char_attr_normal, n, dest, &r); |
| 145 | FillConsoleOutputCharacter (cur_screen, ' ', n, dest, &r); | 145 | FillConsoleOutputCharacter (cur_screen, ' ', n, dest, &r); |
| 146 | 146 | ||
| 147 | move_cursor (0, 0); | 147 | w32con_move_cursor (0, 0); |
| 148 | } | 148 | } |
| 149 | 149 | ||
| 150 | 150 | ||
| @@ -152,8 +152,8 @@ static struct glyph glyph_base[256]; | |||
| 152 | static BOOL ceol_initialized = FALSE; | 152 | static BOOL ceol_initialized = FALSE; |
| 153 | 153 | ||
| 154 | /* Clear from Cursor to end (what's "standout marker"?). */ | 154 | /* Clear from Cursor to end (what's "standout marker"?). */ |
| 155 | void | 155 | static void |
| 156 | clear_end_of_line (int end) | 156 | w32con_clear_end_of_line (int end) |
| 157 | { | 157 | { |
| 158 | if (!ceol_initialized) | 158 | if (!ceol_initialized) |
| 159 | { | 159 | { |
| @@ -164,12 +164,12 @@ clear_end_of_line (int end) | |||
| 164 | } | 164 | } |
| 165 | ceol_initialized = TRUE; | 165 | ceol_initialized = TRUE; |
| 166 | } | 166 | } |
| 167 | write_glyphs (glyph_base, end - cursor_coords.X); /* fencepost ? */ | 167 | w32con_write_glyphs (glyph_base, end - cursor_coords.X); /* fencepost ? */ |
| 168 | } | 168 | } |
| 169 | 169 | ||
| 170 | /* Insert n lines at vpos. if n is negative delete -n lines. */ | 170 | /* Insert n lines at vpos. if n is negative delete -n lines. */ |
| 171 | void | 171 | static void |
| 172 | ins_del_lines (int vpos, int n) | 172 | w32con_ins_del_lines (int vpos, int n) |
| 173 | { | 173 | { |
| 174 | int i, nb; | 174 | int i, nb; |
| 175 | SMALL_RECT scroll; | 175 | SMALL_RECT scroll; |
| @@ -212,8 +212,8 @@ ins_del_lines (int vpos, int n) | |||
| 212 | { | 212 | { |
| 213 | for (i = scroll.Bottom; i < dest.Y; i++) | 213 | for (i = scroll.Bottom; i < dest.Y; i++) |
| 214 | { | 214 | { |
| 215 | move_cursor (i, 0); | 215 | w32con_move_cursor (i, 0); |
| 216 | clear_end_of_line (FRAME_COLS (f)); | 216 | w32con_clear_end_of_line (FRAME_COLS (f)); |
| 217 | } | 217 | } |
| 218 | } | 218 | } |
| 219 | } | 219 | } |
| @@ -225,8 +225,8 @@ ins_del_lines (int vpos, int n) | |||
| 225 | { | 225 | { |
| 226 | for (i = nb; i < scroll.Top; i++) | 226 | for (i = nb; i < scroll.Top; i++) |
| 227 | { | 227 | { |
| 228 | move_cursor (i, 0); | 228 | w32con_move_cursor (i, 0); |
| 229 | clear_end_of_line (FRAME_COLS (f)); | 229 | w32con_clear_end_of_line (FRAME_COLS (f)); |
| 230 | } | 230 | } |
| 231 | } | 231 | } |
| 232 | } | 232 | } |
| @@ -275,8 +275,8 @@ scroll_line (int dist, int direction) | |||
| 275 | 275 | ||
| 276 | 276 | ||
| 277 | /* If start is zero insert blanks instead of a string at start ?. */ | 277 | /* If start is zero insert blanks instead of a string at start ?. */ |
| 278 | void | 278 | static void |
| 279 | insert_glyphs (register struct glyph *start, register int len) | 279 | w32con_insert_glyphs (register struct glyph *start, register int len) |
| 280 | { | 280 | { |
| 281 | scroll_line (len, RIGHT); | 281 | scroll_line (len, RIGHT); |
| 282 | 282 | ||
| @@ -286,16 +286,16 @@ insert_glyphs (register struct glyph *start, register int len) | |||
| 286 | /* Print the first len characters of start, cursor_coords.X adjusted | 286 | /* Print the first len characters of start, cursor_coords.X adjusted |
| 287 | by write_glyphs. */ | 287 | by write_glyphs. */ |
| 288 | 288 | ||
| 289 | write_glyphs (start, len); | 289 | w32con_write_glyphs (start, len); |
| 290 | } | 290 | } |
| 291 | else | 291 | else |
| 292 | { | 292 | { |
| 293 | clear_end_of_line (cursor_coords.X + len); | 293 | w32con_clear_end_of_line (cursor_coords.X + len); |
| 294 | } | 294 | } |
| 295 | } | 295 | } |
| 296 | 296 | ||
| 297 | void | 297 | static void |
| 298 | write_glyphs (register struct glyph *string, register int len) | 298 | w32con_write_glyphs (register struct glyph *string, register int len) |
| 299 | { | 299 | { |
| 300 | int produced, consumed; | 300 | int produced, consumed; |
| 301 | DWORD r; | 301 | DWORD r; |
| @@ -353,7 +353,7 @@ write_glyphs (register struct glyph *string, register int len) | |||
| 353 | } | 353 | } |
| 354 | 354 | ||
| 355 | cursor_coords.X += produced; | 355 | cursor_coords.X += produced; |
| 356 | move_cursor (cursor_coords.Y, cursor_coords.X); | 356 | w32con_move_cursor (cursor_coords.Y, cursor_coords.X); |
| 357 | } | 357 | } |
| 358 | len -= consumed; | 358 | len -= consumed; |
| 359 | n -= consumed; | 359 | n -= consumed; |
| @@ -391,8 +391,8 @@ write_glyphs (register struct glyph *string, register int len) | |||
| 391 | } | 391 | } |
| 392 | 392 | ||
| 393 | 393 | ||
| 394 | void | 394 | static void |
| 395 | delete_glyphs (int n) | 395 | w32con_delete_glyphs (int n) |
| 396 | { | 396 | { |
| 397 | /* delete chars means scroll chars from cursor_coords.X + n to | 397 | /* delete chars means scroll chars from cursor_coords.X + n to |
| 398 | cursor_coords.X, anything beyond the edge of the screen should | 398 | cursor_coords.X, anything beyond the edge of the screen should |
| @@ -450,8 +450,8 @@ SOUND is nil to use the normal beep. */) | |||
| 450 | return sound; | 450 | return sound; |
| 451 | } | 451 | } |
| 452 | 452 | ||
| 453 | void | 453 | static void |
| 454 | reset_terminal_modes (void) | 454 | w32con_reset_terminal_modes (void) |
| 455 | { | 455 | { |
| 456 | #ifdef USE_SEPARATE_SCREEN | 456 | #ifdef USE_SEPARATE_SCREEN |
| 457 | SetConsoleActiveScreenBuffer (prev_screen); | 457 | SetConsoleActiveScreenBuffer (prev_screen); |
| @@ -461,8 +461,8 @@ reset_terminal_modes (void) | |||
| 461 | SetConsoleMode (keyboard_handle, prev_console_mode); | 461 | SetConsoleMode (keyboard_handle, prev_console_mode); |
| 462 | } | 462 | } |
| 463 | 463 | ||
| 464 | void | 464 | static void |
| 465 | set_terminal_modes (void) | 465 | w32con_set_terminal_modes (void) |
| 466 | { | 466 | { |
| 467 | CONSOLE_CURSOR_INFO cci; | 467 | CONSOLE_CURSOR_INFO cci; |
| 468 | 468 | ||
| @@ -484,19 +484,19 @@ set_terminal_modes (void) | |||
| 484 | clumps rather than one-character-at-a-time... | 484 | clumps rather than one-character-at-a-time... |
| 485 | 485 | ||
| 486 | we'll start with not moving the cursor while an update is in progress. */ | 486 | we'll start with not moving the cursor while an update is in progress. */ |
| 487 | void | 487 | static void |
| 488 | update_begin (struct frame * f) | 488 | w32con_update_begin (struct frame * f) |
| 489 | { | 489 | { |
| 490 | } | 490 | } |
| 491 | 491 | ||
| 492 | void | 492 | static void |
| 493 | update_end (struct frame * f) | 493 | w32con_update_end (struct frame * f) |
| 494 | { | 494 | { |
| 495 | SetConsoleCursorPosition (cur_screen, cursor_coords); | 495 | SetConsoleCursorPosition (cur_screen, cursor_coords); |
| 496 | } | 496 | } |
| 497 | 497 | ||
| 498 | void | 498 | static void |
| 499 | set_terminal_window (int size) | 499 | w32con_set_terminal_window (int size) |
| 500 | { | 500 | { |
| 501 | } | 501 | } |
| 502 | 502 | ||
| @@ -574,21 +574,21 @@ initialize_w32_display (void) | |||
| 574 | { | 574 | { |
| 575 | CONSOLE_SCREEN_BUFFER_INFO info; | 575 | CONSOLE_SCREEN_BUFFER_INFO info; |
| 576 | 576 | ||
| 577 | cursor_to_hook = move_cursor; | 577 | cursor_to_hook = w32con_move_cursor; |
| 578 | raw_cursor_to_hook = move_cursor; | 578 | raw_cursor_to_hook = w32con_move_cursor; |
| 579 | clear_to_end_hook = clear_to_end; | 579 | clear_to_end_hook = w32con_clear_to_end; |
| 580 | clear_frame_hook = clear_frame; | 580 | clear_frame_hook = w32con_clear_frame; |
| 581 | clear_end_of_line_hook = clear_end_of_line; | 581 | clear_end_of_line_hook = w32con_clear_end_of_line; |
| 582 | ins_del_lines_hook = ins_del_lines; | 582 | ins_del_lines_hook = w32con_ins_del_lines; |
| 583 | insert_glyphs_hook = insert_glyphs; | 583 | insert_glyphs_hook = w32con_insert_glyphs; |
| 584 | write_glyphs_hook = write_glyphs; | 584 | write_glyphs_hook = w32con_write_glyphs; |
| 585 | delete_glyphs_hook = delete_glyphs; | 585 | delete_glyphs_hook = w32con_delete_glyphs; |
| 586 | ring_bell_hook = w32_sys_ring_bell; | 586 | ring_bell_hook = w32_sys_ring_bell; |
| 587 | reset_terminal_modes_hook = reset_terminal_modes; | 587 | reset_terminal_modes_hook = w32con_reset_terminal_modes; |
| 588 | set_terminal_modes_hook = set_terminal_modes; | 588 | set_terminal_modes_hook = w32con_set_terminal_modes; |
| 589 | set_terminal_window_hook = set_terminal_window; | 589 | set_terminal_window_hook = w32con_set_terminal_window; |
| 590 | update_begin_hook = update_begin; | 590 | update_begin_hook = w32con_update_begin; |
| 591 | update_end_hook = update_end; | 591 | update_end_hook = w32con_update_end; |
| 592 | 592 | ||
| 593 | read_socket_hook = w32_console_read_socket; | 593 | read_socket_hook = w32_console_read_socket; |
| 594 | mouse_position_hook = w32_console_mouse_position; | 594 | mouse_position_hook = w32_console_mouse_position; |
diff --git a/src/w32fns.c b/src/w32fns.c index f56ecc35cc6..c0c66a9591e 100644 --- a/src/w32fns.c +++ b/src/w32fns.c | |||
| @@ -8090,7 +8090,7 @@ DEFUN ("w32-unregister-hot-key", Fw32_unregister_hot_key, | |||
| 8090 | (WPARAM) XINT (XCAR (item)), (LPARAM) item.i)) | 8090 | (WPARAM) XINT (XCAR (item)), (LPARAM) item.i)) |
| 8091 | #else | 8091 | #else |
| 8092 | if (PostThreadMessage (dwWindowsThreadId, WM_EMACS_UNREGISTER_HOT_KEY, | 8092 | if (PostThreadMessage (dwWindowsThreadId, WM_EMACS_UNREGISTER_HOT_KEY, |
| 8093 | (WPARAM) XINT (XCAR (item)), (LPARAM) item.i)) | 8093 | (WPARAM) XINT (XCAR (item)), (LPARAM) item)) |
| 8094 | 8094 | ||
| 8095 | #endif | 8095 | #endif |
| 8096 | { | 8096 | { |
| @@ -8170,7 +8170,7 @@ is set to off if the low bit of NEW-STATE is zero, otherwise on. */) | |||
| 8170 | (WPARAM) vk_code, (LPARAM) new_state.i)) | 8170 | (WPARAM) vk_code, (LPARAM) new_state.i)) |
| 8171 | #else | 8171 | #else |
| 8172 | if (PostThreadMessage (dwWindowsThreadId, WM_EMACS_TOGGLE_LOCK_KEY, | 8172 | if (PostThreadMessage (dwWindowsThreadId, WM_EMACS_TOGGLE_LOCK_KEY, |
| 8173 | (WPARAM) vk_code, (LPARAM) new_state.i)) | 8173 | (WPARAM) vk_code, (LPARAM) new_state)) |
| 8174 | #endif | 8174 | #endif |
| 8175 | { | 8175 | { |
| 8176 | MSG msg; | 8176 | MSG msg; |
diff --git a/src/w32menu.c b/src/w32menu.c index 5f8f8a4e5e0..cc0932d7bf5 100644 --- a/src/w32menu.c +++ b/src/w32menu.c | |||
| @@ -2225,9 +2225,12 @@ add_menu_item (HMENU menu, widget_value *wv, HMENU item) | |||
| 2225 | /* Set help string for menu item. Leave it as a Lisp_Object | 2225 | /* Set help string for menu item. Leave it as a Lisp_Object |
| 2226 | until it is ready to be displayed, since GC can happen while | 2226 | until it is ready to be displayed, since GC can happen while |
| 2227 | menus are active. */ | 2227 | menus are active. */ |
| 2228 | if (wv->help) | 2228 | if (!NILP (wv->help)) |
| 2229 | info.dwItemData = (DWORD) wv->help; | 2229 | #ifdef USE_LISP_UNION_TYPE |
| 2230 | 2230 | info.dwItemData = (DWORD) (wv->help).i; | |
| 2231 | #else | ||
| 2232 | info.dwItemData = (DWORD) (wv->help); | ||
| 2233 | #endif | ||
| 2231 | if (wv->button_type == BUTTON_TYPE_RADIO) | 2234 | if (wv->button_type == BUTTON_TYPE_RADIO) |
| 2232 | { | 2235 | { |
| 2233 | /* CheckMenuRadioItem allows us to differentiate TOGGLE and | 2236 | /* CheckMenuRadioItem allows us to differentiate TOGGLE and |
| @@ -2307,7 +2310,12 @@ w32_menu_display_help (HWND owner, HMENU menu, UINT item, UINT flags) | |||
| 2307 | info.fMask = MIIM_DATA; | 2310 | info.fMask = MIIM_DATA; |
| 2308 | get_menu_item_info (menu, item, FALSE, &info); | 2311 | get_menu_item_info (menu, item, FALSE, &info); |
| 2309 | 2312 | ||
| 2313 | #ifdef USE_LISP_UNION_TYPE | ||
| 2314 | help = info.dwItemData ? (Lisp_Object) ((EMACS_INT) info.dwItemData) | ||
| 2315 | : Qnil; | ||
| 2316 | #else | ||
| 2310 | help = info.dwItemData ? (Lisp_Object) info.dwItemData : Qnil; | 2317 | help = info.dwItemData ? (Lisp_Object) info.dwItemData : Qnil; |
| 2318 | #endif | ||
| 2311 | } | 2319 | } |
| 2312 | 2320 | ||
| 2313 | /* Store the help echo in the keyboard buffer as the X toolkit | 2321 | /* Store the help echo in the keyboard buffer as the X toolkit |
diff --git a/src/w32proc.c b/src/w32proc.c index 842869726df..8452337f7e2 100644 --- a/src/w32proc.c +++ b/src/w32proc.c | |||
| @@ -1,5 +1,5 @@ | |||
| 1 | /* Process support for GNU Emacs on the Microsoft W32 API. | 1 | /* Process support for GNU Emacs on the Microsoft W32 API. |
| 2 | Copyright (C) 1992, 1995, 1999, 2000, 2001 Free Software Foundation, Inc. | 2 | Copyright (C) 1992, 95, 99, 2000, 01, 04 Free Software Foundation, Inc. |
| 3 | 3 | ||
| 4 | This file is part of GNU Emacs. | 4 | This file is part of GNU Emacs. |
| 5 | 5 | ||
| @@ -367,7 +367,7 @@ create_child (char *exe, char *cmdline, char *env, int is_gui_app, | |||
| 367 | cp->pid = -cp->pid; | 367 | cp->pid = -cp->pid; |
| 368 | 368 | ||
| 369 | /* pid must fit in a Lisp_Int */ | 369 | /* pid must fit in a Lisp_Int */ |
| 370 | cp->pid = XUINT (make_number (cp->pid)); | 370 | cp->pid = cp->pid & INTMASK; |
| 371 | 371 | ||
| 372 | *pPid = cp->pid; | 372 | *pPid = cp->pid; |
| 373 | 373 | ||
diff --git a/src/w32term.h b/src/w32term.h index f7c4c30064e..284458d4270 100644 --- a/src/w32term.h +++ b/src/w32term.h | |||
| @@ -252,6 +252,10 @@ extern int unibyte_display_via_language_environment; | |||
| 252 | 252 | ||
| 253 | struct w32_display_info *x_display_info_for_name (); | 253 | struct w32_display_info *x_display_info_for_name (); |
| 254 | 254 | ||
| 255 | Lisp_Object display_x_get_resource P_ ((struct w32_display_info *, | ||
| 256 | Lisp_Object, Lisp_Object, | ||
| 257 | Lisp_Object, Lisp_Object)); | ||
| 258 | |||
| 255 | extern struct w32_display_info *w32_term_init (); | 259 | extern struct w32_display_info *w32_term_init (); |
| 256 | 260 | ||
| 257 | extern Lisp_Object w32_list_fonts P_ ((struct frame *, Lisp_Object, int, int)); | 261 | extern Lisp_Object w32_list_fonts P_ ((struct frame *, Lisp_Object, int, int)); |
| @@ -717,6 +721,8 @@ struct face; | |||
| 717 | 721 | ||
| 718 | XGCValues *XCreateGC (void *, Window, unsigned long, XGCValues *); | 722 | XGCValues *XCreateGC (void *, Window, unsigned long, XGCValues *); |
| 719 | struct frame * check_x_frame (Lisp_Object); | 723 | struct frame * check_x_frame (Lisp_Object); |
| 724 | Lisp_Object vga_stdcolor_name (int); | ||
| 725 | |||
| 720 | EXFUN (Fx_display_color_p, 1); | 726 | EXFUN (Fx_display_color_p, 1); |
| 721 | EXFUN (Fx_display_grayscale_p, 1); | 727 | EXFUN (Fx_display_grayscale_p, 1); |
| 722 | 728 | ||