]> git.eshelyaron.com Git - emacs.git/commitdiff
(find-composition): Check if (char-after POS)
authorGerd Moellmann <gerd@gnu.org>
Fri, 17 Aug 2001 09:02:29 +0000 (09:02 +0000)
committerGerd Moellmann <gerd@gnu.org>
Fri, 17 Aug 2001 09:02:29 +0000 (09:02 +0000)
returns a valid character.

lisp/ChangeLog
lisp/ps-mule.el

index b92af6254a0e3b2fe6030f4c3463b9867bc0dd1c..cd04a63cc79af5604d27e2a749aad1c37b094304 100644 (file)
@@ -1,3 +1,8 @@
+2001-08-16  Vinicius Jose Latorre  <vinicius@cpqd.com.br>
+
+       * ps-mule.el: (find-composition): Check if (char-after POS)
+       returns a valid character.
+
 2001-08-16  Eli Zaretskii  <eliz@is.elta.co.il>
 
        * hexl.el (hexl-mode, hexl-mode-exit): Adjust hexl-max-address and
index 91997c9610cd11eae5f34cb72347fabd9daa6e2f..58f8de3d81fd4bf4a0732fbc77b85c3dc2e00ccc 100644 (file)
@@ -7,7 +7,7 @@
 ;; Maintainer: Kenichi Handa <handa@etl.go.jp> (multi-byte characters)
 ;;     Vinicius Jose Latorre <vinicius@cpqd.com.br>
 ;; Keywords: wp, print, PostScript, multibyte, mule
-;; Time-stamp: <2001/08/07 13:50:53 vinicius>
+;; Time-stamp: <2001/08/15 15:34:11 vinicius>
 
 ;; This file is part of GNU Emacs.
 
@@ -242,11 +242,11 @@ Any other value is treated as nil."
          (+ (* (car rule) 12) (cdr rule)))
        (defun find-composition (pos &rest ignore)
          (let ((ch (char-after pos)))
-           (if (eq (char-charset ch) 'composition)
-               (let ((components (decompose-composite-char ch 'vector t)))
-                 (list pos (ps-mule-next-point pos) components
-                       (integerp (aref components 1)) nil
-                       (char-width ch)))))))
+           (and ch (eq (char-charset ch) 'composition)
+                (let ((components (decompose-composite-char ch 'vector t)))
+                  (list pos (ps-mule-next-point pos) components
+                        (integerp (aref components 1)) nil
+                        (char-width ch)))))))
     ;; mule package isn't loaded
     (or (fboundp 'encode-composition-rule)
        (defun encode-composition-rule (rule)
@@ -1130,10 +1130,10 @@ the sequence."
        } ifelse } ifelse } ifelse
     } forall ] /components exch def
     grestore
-    
+
     %% Reflect special effects.
     SpecialEffect
-    
+
     %% Draw components while ignoring effects other than shadow and outline.
     components ShowComponents