# HG changeset patch # User Kenichi Handa # Date 871186023 0 # Node ID 6122dbba797f712ac8880d917d4a64ff414be2af # Parent 9d34beb088bfbf3e475352f8db587ee5594bec96 (prefer-coding-system): Moved to mule-util.el. diff -r 9d34beb088bf -r 6122dbba797f lisp/international/mule-util.el --- a/lisp/international/mule-util.el Sun Aug 10 04:07:03 1997 +0000 +++ b/lisp/international/mule-util.el Sun Aug 10 04:07:03 1997 +0000 @@ -318,28 +318,6 @@ (equal (coding-system-plist coding-system-1) (coding-system-plist coding-system-2)))) -;;;###autoload -(defun prefer-coding-system (coding-system) - "Add CODING-SYSTEM at the front of the priority list for automatic detection." - (interactive "zPrefer coding system: ") - (if (not (and coding-system (coding-system-p coding-system))) - (error "Invalid coding system `%s'" coding-system)) - (let ((coding-category (coding-system-category coding-system)) - (parent (coding-system-parent coding-system))) - (if (not coding-category) - ;; CODING-SYSTEM is no-conversion or undecided. - (error "Can't prefer the coding system `%s'" coding-system)) - (set coding-category (or parent coding-system)) - (if (not (eq coding-category (car coding-category-list))) - ;; We must change the order. - (setq coding-category-list - (cons coding-category - (delq coding-category coding-category-list)))) - (if (and parent (interactive-p)) - (message "Highest priority is set to %s (parent of %s)" - parent coding-system)) - (setq-default buffer-file-coding-system (or parent coding-system)))) - ;;; Composite charcater manipulations. @@ -375,6 +353,19 @@ (insert (decompose-composite-char (string-to-char str))))))) ;;;###autoload +(defun decompose-string (string) + "Decompose all composite characters in STRING." + (let* ((l (string-to-list string)) + (tail l) + ch) + (while tail + (setq ch (car tail)) + (setcar tail (if (cmpcharp ch) (decompose-composite-char ch) + (char-to-string ch))) + (setq tail (cdr tail))) + (apply 'concat l))) + +;;;###autoload (defconst reference-point-alist '((tl . 0) (tc . 1) (tr . 2) (ml . 3) (mc . 4) (mr . 5)