From: Gerd Moellmann Date: Fri, 17 Aug 2001 09:02:29 +0000 (+0000) Subject: (find-composition): Check if (char-after POS) X-Git-Tag: emacs-pretest-21.0.105~159 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=64ed6f7182ba6a98482f9b6ae05f2c8e342c8ee9;p=emacs.git (find-composition): Check if (char-after POS) returns a valid character. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b92af6254a0..cd04a63cc79 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2001-08-16 Vinicius Jose Latorre + + * ps-mule.el: (find-composition): Check if (char-after POS) + returns a valid character. + 2001-08-16 Eli Zaretskii * hexl.el (hexl-mode, hexl-mode-exit): Adjust hexl-max-address and diff --git a/lisp/ps-mule.el b/lisp/ps-mule.el index 91997c9610c..58f8de3d81f 100644 --- a/lisp/ps-mule.el +++ b/lisp/ps-mule.el @@ -7,7 +7,7 @@ ;; Maintainer: Kenichi Handa (multi-byte characters) ;; Vinicius Jose Latorre ;; 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