411 |
(limit (if string (length string) (point-max))) |
(limit (if string (length string) (point-max))) |
412 |
ch func newpos) |
ch func newpos) |
413 |
(setq limit (or (text-property-any pos limit 'auto-composed t string) |
(setq limit (or (text-property-any pos limit 'auto-composed t string) |
414 |
limit)) |
limit) |
415 |
(catch 'tag |
pos (catch 'tag |
416 |
(if string |
(if string |
417 |
(while (< pos limit) |
(while (< pos limit) |
418 |
(setq ch (aref string pos)) |
(setq ch (aref string pos)) |
419 |
(if (= ch ?\n) |
(if (= ch ?\n) |
420 |
(throw 'tag nil)) |
(throw 'tag (1+ pos))) |
421 |
(setq func (aref composition-function-table ch)) |
(setq func (aref composition-function-table ch)) |
422 |
(if (and (functionp func) |
(if (and (functionp func) |
423 |
(setq newpos (funcall func pos string)) |
(setq newpos (funcall func pos string)) |
424 |
(> newpos pos)) |
(> newpos pos)) |
425 |
(setq pos newpos) |
(setq pos newpos) |
426 |
(setq pos (1+ pos)))) |
(setq pos (1+ pos)))) |
427 |
(while (< pos limit) |
(while (< pos limit) |
428 |
(setq ch (char-after pos)) |
(setq ch (char-after pos)) |
429 |
(if (= ch ?\n) |
(if (= ch ?\n) |
430 |
(throw 'tag nil)) |
(throw 'tag (1+ pos))) |
431 |
(setq func (aref composition-function-table ch)) |
(setq func (aref composition-function-table ch)) |
432 |
(if (and (functionp func) |
(if (and (functionp func) |
433 |
(setq newpos (funcall func pos string)) |
(setq newpos (funcall func pos string)) |
434 |
(> newpos pos)) |
(> newpos pos)) |
435 |
(setq pos newpos) |
(setq pos newpos) |
436 |
(setq pos (1+ pos)))))) |
(setq pos (1+ pos))))) |
437 |
|
limit)) |
438 |
(put-text-property start pos 'auto-composed t string)))))) |
(put-text-property start pos 'auto-composed t string)))))) |
439 |
|
|
440 |
(setq auto-composition-function 'auto-compose-chars) |
(setq auto-composition-function 'auto-compose-chars) |