diff options
| author | Kenichi Handa | 2000-07-04 07:38:15 +0000 |
|---|---|---|
| committer | Kenichi Handa | 2000-07-04 07:38:15 +0000 |
| commit | 33f37824466d8deaf4780a15a0694e45e9ae96c6 (patch) | |
| tree | 461bfe25611daa8e5fd0f70449bbb71641e6e9dc /src | |
| parent | be17069b715f28617d6375ef898f06450c80e6ad (diff) | |
| download | emacs-33f37824466d8deaf4780a15a0694e45e9ae96c6.tar.gz emacs-33f37824466d8deaf4780a15a0694e45e9ae96c6.zip | |
(concat): While copying text properties, make each composition
property value a copy.
Diffstat (limited to 'src')
| -rw-r--r-- | src/fns.c | 16 |
1 files changed, 13 insertions, 3 deletions
| @@ -826,12 +826,22 @@ concat (nargs, args, target_type, last_special) | |||
| 826 | 826 | ||
| 827 | if (num_textprops > 0) | 827 | if (num_textprops > 0) |
| 828 | { | 828 | { |
| 829 | Lisp_Object props; | ||
| 830 | |||
| 829 | for (argnum = 0; argnum < num_textprops; argnum++) | 831 | for (argnum = 0; argnum < num_textprops; argnum++) |
| 830 | { | 832 | { |
| 831 | this = args[textprops[argnum].argnum]; | 833 | this = args[textprops[argnum].argnum]; |
| 832 | copy_text_properties (make_number (textprops[argnum].from), | 834 | props = text_property_list (this, |
| 833 | make_number (XSTRING (this)->size), this, | 835 | make_number (0), |
| 834 | make_number (textprops[argnum].to), val, Qnil); | 836 | make_number (XSTRING (this)->size), |
| 837 | Qnil); | ||
| 838 | /* If successive arguments have properites, be sure that the | ||
| 839 | value of `composition' property be the copy. */ | ||
| 840 | if (argnum > 0 | ||
| 841 | && textprops[argnum - 1].argnum + 1 == textprops[argnum].argnum) | ||
| 842 | make_composition_value_copy (props); | ||
| 843 | add_text_properties_from_list (val, props, | ||
| 844 | make_number (textprops[argnum].to)); | ||
| 835 | } | 845 | } |
| 836 | } | 846 | } |
| 837 | return val; | 847 | return val; |