/[emacs]/emacs/lisp/international/mule.el
ViewVC logotype

Diff of /emacs/lisp/international/mule.el

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.214 by kfstorm, Wed Feb 9 15:50:37 2005 UTC revision 1.215 by handa, Mon Feb 21 12:50:06 2005 UTC
# Line 1467  If FROM is a string, or if the current b Line 1467  If FROM is a string, or if the current b
1467  by encode-coding-string, generate a new temp buffer, insert the  by encode-coding-string, generate a new temp buffer, insert the
1468  text, and convert it in the temporary buffer.  Otherwise, convert in-place."  text, and convert it in the temporary buffer.  Otherwise, convert in-place."
1469    (save-match-data    (save-match-data
1470      ;; Setup a working buffer if necessary.      (let ((workbuf (get-buffer-create " *code-conversion-work*")))
1471      (cond ((stringp from)        ;; Setup a working buffer if necessary.
1472             (let ((buf (current-buffer)))        (cond ((stringp from)
1473               (set-buffer (generate-new-buffer " *temp"))               (set-buffer workbuf)
1474                 (erase-buffer)
1475               (set-buffer-multibyte (multibyte-string-p from))               (set-buffer-multibyte (multibyte-string-p from))
1476               (insert from)))               (insert from))
1477            ((not (string= (buffer-name) " *code-converting-work*"))              ((not (eq (current-buffer) workbuf))
1478             (let ((buf (current-buffer))               (let ((buf (current-buffer))
1479                   (multibyte enable-multibyte-characters))                     (multibyte enable-multibyte-characters))
1480               (set-buffer (generate-new-buffer " *temp"))                 (set-buffer workbuf)
1481               (set-buffer-multibyte multibyte)                 (erase-buffer)
1482               (insert-buffer-substring buf from to))))                 (set-buffer-multibyte multibyte)
1483                   (insert-buffer-substring buf from to)))))
1484    
1485      ;; Now we can encode the whole buffer.      ;; Now we can encode the whole buffer.
1486      (let ((encoding-table (ctext-non-standard-encodings-table))      (let ((encoding-table (ctext-non-standard-encodings-table))

Legend:
Removed from v.1.214  
changed lines
  Added in v.1.215

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26