+ char))))
+
+(defun char-db-insert-char-spec (char &optional readable column)
+ (unless column
+ (setq column (current-column)))
+ (let (char-spec ret al cal key temp-char)
+ (setq char-spec (char-db-make-char-spec char))
+ ;; (cond ((characterp char)
+ ;; (cond ((and (setq ret (get-char-attribute char 'ucs))
+ ;; (not (and (<= #xE000 ret)(<= ret #xF8FF))))
+ ;; (setq char-spec (list (cons 'ucs ret)))
+ ;; (if (setq ret (get-char-attribute char 'name))
+ ;; (setq char-spec (cons (cons 'name ret) char-spec)))
+ ;; )
+ ;; ((setq ret
+ ;; (let ((default-coded-charset-priority-list
+ ;; char-db-coded-charset-priority-list))
+ ;; (split-char char)))
+ ;; (setq char-spec (list ret))
+ ;; (dolist (ccs (delq (car ret) (charset-list)))
+ ;; (if (or (and (charset-iso-final-char ccs)
+ ;; (setq ret (get-char-attribute char ccs)))
+ ;; (eq ccs 'ideograph-daikanwa))
+ ;; (setq char-spec (cons (cons ccs ret) char-spec))))
+ ;; (if (null char-spec)
+ ;; (setq char-spec (split-char char)))
+ ;; (if (setq ret (get-char-attribute char 'name))
+ ;; (setq char-spec (cons (cons 'name ret) char-spec)))
+ ;; )))
+ ;; ((consp char)
+ ;; (setq char-spec char)
+ ;; (setq char nil)))
+ (unless (or (characterp char) ; char
+ (condition-case nil
+ (setq char (find-char char-spec))
+ (error nil)))
+ ;; define temporary character
+ ;; Current implementation is dirty.
+ (setq temp-char (define-char (cons '(ideograph-daikanwa . 0)
+ char-spec)))
+ (remove-char-attribute temp-char 'ideograph-daikanwa)
+ (setq char temp-char))
+ (setq al nil
+ cal nil)
+ (while char-spec
+ (setq key (car (car char-spec)))
+ (unless (memq key char-db-ignored-attributes)
+ (if (find-charset key)
+ (if (get-char-attribute char key)
+ (setq cal (cons key cal)))
+ (setq al (cons key al))))
+ (setq char-spec (cdr char-spec)))
+ (unless cal
+ (setq char-spec (char-db-make-char-spec char))
+ (while char-spec
+ (setq key (car (car char-spec)))
+ (unless (memq key char-db-ignored-attributes)
+ (if (find-charset key)
+ (setq cal (cons key cal))
+ (setq al (cons key al))))
+ (setq char-spec (cdr char-spec)))
+ )
+ (unless (or cal
+ (memq 'ideographic-structure al))
+ (push 'ideographic-structure al))
+ (insert-char-attributes char
+ readable
+ (or al 'none) cal)
+ (when temp-char
+ ;; undefine temporary character
+ ;; Current implementation is dirty.
+ (setq char-spec (char-attribute-alist temp-char))
+ (while char-spec
+ (remove-char-attribute temp-char (car (car char-spec)))
+ (setq char-spec (cdr char-spec))))))