diff options
| author | Dave Love | 2002-06-24 19:06:43 +0000 |
|---|---|---|
| committer | Dave Love | 2002-06-24 19:06:43 +0000 |
| commit | e84839b3391f179bcc367f11ecca6ffe6c736d78 (patch) | |
| tree | 5e7a8c738f2caf089a7d200a7c5bcfd28ea01814 | |
| parent | f1bf026ea492cb57597c0dd0ddea228001a7bdff (diff) | |
| download | emacs-e84839b3391f179bcc367f11ecca6ffe6c736d78.tar.gz emacs-e84839b3391f179bcc367f11ecca6ffe6c736d78.zip | |
(mm-mule4-p, mm-enable-multibyte-mule4)
(mm-disable-multibyte-mule4)
(mm-with-unibyte-current-buffer-mule4): Deleted.
| -rw-r--r-- | lisp/gnus/mm-util.el | 44 |
1 files changed, 3 insertions, 41 deletions
diff --git a/lisp/gnus/mm-util.el b/lisp/gnus/mm-util.el index f63829eaba8..3ae754c2462 100644 --- a/lisp/gnus/mm-util.el +++ b/lisp/gnus/mm-util.el | |||
| @@ -368,12 +368,7 @@ used as the line break code type of the coding system." | |||
| 368 | (boundp 'default-enable-multibyte-characters) | 368 | (boundp 'default-enable-multibyte-characters) |
| 369 | default-enable-multibyte-characters | 369 | default-enable-multibyte-characters |
| 370 | (fboundp 'set-buffer-multibyte)) | 370 | (fboundp 'set-buffer-multibyte)) |
| 371 | "Emacs mule.") | 371 | "True in Emacs with Mule.") |
| 372 | |||
| 373 | (defvar mm-mule4-p (and mm-emacs-mule | ||
| 374 | (fboundp 'charsetp) | ||
| 375 | (not (charsetp 'eight-bit-control))) | ||
| 376 | "Mule version 4.") | ||
| 377 | 372 | ||
| 378 | (if mm-emacs-mule | 373 | (if mm-emacs-mule |
| 379 | (defun mm-enable-multibyte () | 374 | (defun mm-enable-multibyte () |
| @@ -388,21 +383,7 @@ non-nil. This is a no-op in XEmacs." | |||
| 388 | "Unset the multibyte flag of in the current buffer. | 383 | "Unset the multibyte flag of in the current buffer. |
| 389 | This is a no-op in XEmacs." | 384 | This is a no-op in XEmacs." |
| 390 | (set-buffer-multibyte nil)) | 385 | (set-buffer-multibyte nil)) |
| 391 | (defalias 'mm-disable-multibyte 'ignore)) | 386 | (defalias 'mm-disable-multibyte 'ignore))) |
| 392 | |||
| 393 | (if mm-mule4-p | ||
| 394 | (defun mm-enable-multibyte-mule4 () | ||
| 395 | "Enable multibyte in the current buffer. | ||
| 396 | Only used in Emacs Mule 4." | ||
| 397 | (set-buffer-multibyte t)) | ||
| 398 | (defalias 'mm-enable-multibyte-mule4 'ignore)) | ||
| 399 | |||
| 400 | (if mm-mule4-p | ||
| 401 | (defun mm-disable-multibyte-mule4 () | ||
| 402 | "Disable multibyte in the current buffer. | ||
| 403 | Only used in Emacs Mule 4." | ||
| 404 | (set-buffer-multibyte nil)) | ||
| 405 | (defalias 'mm-disable-multibyte-mule4 'ignore))) | ||
| 406 | 387 | ||
| 407 | (defun mm-preferred-coding-system (charset) | 388 | (defun mm-preferred-coding-system (charset) |
| 408 | ;; A typo in some Emacs versions. | 389 | ;; A typo in some Emacs versions. |
| @@ -419,7 +400,7 @@ If the charset is `composition', return the actual one." | |||
| 419 | (setq charset 'ascii) | 400 | (setq charset 'ascii) |
| 420 | ;; charset-after is fake in some Emacsen. | 401 | ;; charset-after is fake in some Emacsen. |
| 421 | (setq charset (and (fboundp 'char-charset) (char-charset char))) | 402 | (setq charset (and (fboundp 'char-charset) (char-charset char))) |
| 422 | (if (eq charset 'composition) | 403 | (if (eq charset 'composition) ; Mule 4 |
| 423 | (let ((p (or pos (point)))) | 404 | (let ((p (or pos (point)))) |
| 424 | (cadr (find-charset-region p (1+ p)))) | 405 | (cadr (find-charset-region p (1+ p)))) |
| 425 | (if (and charset (not (memq charset '(ascii eight-bit-control | 406 | (if (and charset (not (memq charset '(ascii eight-bit-control |
| @@ -575,25 +556,6 @@ Equivalent to `progn' in XEmacs" | |||
| 575 | (put 'mm-with-unibyte-current-buffer 'lisp-indent-function 0) | 556 | (put 'mm-with-unibyte-current-buffer 'lisp-indent-function 0) |
| 576 | (put 'mm-with-unibyte-current-buffer 'edebug-form-spec '(body)) | 557 | (put 'mm-with-unibyte-current-buffer 'edebug-form-spec '(body)) |
| 577 | 558 | ||
| 578 | (defmacro mm-with-unibyte-current-buffer-mule4 (&rest forms) | ||
| 579 | "Evaluate FORMS there like `progn' in current buffer. | ||
| 580 | Mule4 only." | ||
| 581 | (let ((multibyte (make-symbol "multibyte")) | ||
| 582 | (buffer (make-symbol "buffer"))) | ||
| 583 | `(if mm-mule4-p | ||
| 584 | (let ((,multibyte enable-multibyte-characters) | ||
| 585 | (,buffer (current-buffer))) | ||
| 586 | (unwind-protect | ||
| 587 | (let (default-enable-multibyte-characters) | ||
| 588 | (set-buffer-multibyte nil) | ||
| 589 | ,@forms) | ||
| 590 | (set-buffer ,buffer) | ||
| 591 | (set-buffer-multibyte ,multibyte))) | ||
| 592 | (let (default-enable-multibyte-characters) | ||
| 593 | ,@forms)))) | ||
| 594 | (put 'mm-with-unibyte-current-buffer-mule4 'lisp-indent-function 0) | ||
| 595 | (put 'mm-with-unibyte-current-buffer-mule4 'edebug-form-spec '(body)) | ||
| 596 | |||
| 597 | (defmacro mm-with-unibyte (&rest forms) | 559 | (defmacro mm-with-unibyte (&rest forms) |
| 598 | "Eval the FORMS with the default value of `enable-multibyte-characters' nil, ." | 560 | "Eval the FORMS with the default value of `enable-multibyte-characters' nil, ." |
| 599 | `(let (default-enable-multibyte-characters) | 561 | `(let (default-enable-multibyte-characters) |