diff options
| author | Karl Heuer | 1997-02-20 05:46:22 +0000 |
|---|---|---|
| committer | Karl Heuer | 1997-02-20 05:46:22 +0000 |
| commit | f46d509102db41ce32caca2e1611bfc5d8b37506 (patch) | |
| tree | 5487d1163f020cd9a4357b03fdc5f4526d5497e3 | |
| parent | 0634ea78a020dca9b0b01f02898af2f9ff8f8d4d (diff) | |
| download | emacs-f46d509102db41ce32caca2e1611bfc5d8b37506.tar.gz emacs-f46d509102db41ce32caca2e1611bfc5d8b37506.zip | |
(isearch-mode-map): Define
isearch-toggle-input-method and
isearch-toggle-specified-input-method in the map.
(isearch-multibyte-characters-flag): New variable.
(isearch-mode): Initialize it to nil.
(isearch-printing-char): Handle multibyte characters.
(isearch-message-prefix): Include title of input method if
necessary in the prefix of message.
| -rw-r--r-- | lisp/isearch.el | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/lisp/isearch.el b/lisp/isearch.el index 9e5ad7d4a2e..28e2c1884b2 100644 --- a/lisp/isearch.el +++ b/lisp/isearch.el | |||
| @@ -255,6 +255,9 @@ Default value, nil, means edit the string instead.") | |||
| 255 | (define-key map [delete-frame] nil) | 255 | (define-key map [delete-frame] nil) |
| 256 | (define-key map [iconify-frame] nil) | 256 | (define-key map [iconify-frame] nil) |
| 257 | (define-key map [make-frame-visible] nil) | 257 | (define-key map [make-frame-visible] nil) |
| 258 | ;; For searching multilingual text. | ||
| 259 | (define-key map "\C-\\" 'isearch-toggle-input-method) | ||
| 260 | (define-key map "\C-^" 'isearch-toggle-specified-input-method) | ||
| 258 | 261 | ||
| 259 | (setq isearch-mode-map map) | 262 | (setq isearch-mode-map map) |
| 260 | )) | 263 | )) |
| @@ -316,6 +319,9 @@ Default value, nil, means edit the string instead.") | |||
| 316 | ;; Flag to indicate a yank occurred, so don't move the cursor. | 319 | ;; Flag to indicate a yank occurred, so don't move the cursor. |
| 317 | (defvar isearch-yank-flag nil) | 320 | (defvar isearch-yank-flag nil) |
| 318 | 321 | ||
| 322 | ;; Flag to indicate that we are searching multibyte characaters. | ||
| 323 | (defvar isearch-multibyte-characters-flag nil) | ||
| 324 | |||
| 319 | ;;; A function to be called after each input character is processed. | 325 | ;;; A function to be called after each input character is processed. |
| 320 | ;;; (It is not called after characters that exit the search.) | 326 | ;;; (It is not called after characters that exit the search.) |
| 321 | ;;; It is only set from an optional argument to `isearch-mode'. | 327 | ;;; It is only set from an optional argument to `isearch-mode'. |
| @@ -463,6 +469,7 @@ is treated as a regexp. See \\[isearch-forward] for more info." | |||
| 463 | isearch-other-end nil | 469 | isearch-other-end nil |
| 464 | isearch-small-window nil | 470 | isearch-small-window nil |
| 465 | isearch-just-started t | 471 | isearch-just-started t |
| 472 | isearch-multibyte-characters-flag nil | ||
| 466 | 473 | ||
| 467 | isearch-opoint (point) | 474 | isearch-opoint (point) |
| 468 | search-ring-yank-pointer nil | 475 | search-ring-yank-pointer nil |
| @@ -1100,7 +1107,9 @@ Obsolete." | |||
| 1100 | (defun isearch-printing-char () | 1107 | (defun isearch-printing-char () |
| 1101 | "Add this ordinary printing character to the search string and search." | 1108 | "Add this ordinary printing character to the search string and search." |
| 1102 | (interactive) | 1109 | (interactive) |
| 1103 | (isearch-process-search-char (isearch-last-command-char))) | 1110 | (if isearch-multibyte-characters-flag |
| 1111 | (isearch-process-search-multibyte-characters (isearch-last-command-char)) | ||
| 1112 | (isearch-process-search-char (isearch-last-command-char)))) | ||
| 1104 | 1113 | ||
| 1105 | (defun isearch-whitespace-chars () | 1114 | (defun isearch-whitespace-chars () |
| 1106 | "Match all whitespace chars, if in regexp mode. | 1115 | "Match all whitespace chars, if in regexp mode. |
| @@ -1331,7 +1340,10 @@ If there is no completion possible, say so and continue searching." | |||
| 1331 | (if isearch-word "word " "") | 1340 | (if isearch-word "word " "") |
| 1332 | (if isearch-regexp "regexp " "") | 1341 | (if isearch-regexp "regexp " "") |
| 1333 | (if nonincremental "search" "I-search") | 1342 | (if nonincremental "search" "I-search") |
| 1334 | (if isearch-forward ": " " backward: ") | 1343 | (if isearch-forward "" " backward") |
| 1344 | (if isearch-multibyte-characters-flag | ||
| 1345 | (concat " [" default-input-method-title "]: ") | ||
| 1346 | ": ") | ||
| 1335 | ))) | 1347 | ))) |
| 1336 | (aset m 0 (upcase (aref m 0))) | 1348 | (aset m 0 (upcase (aref m 0))) |
| 1337 | m)) | 1349 | m)) |