File: group__m17nTextProperty.html

package info (click to toggle)
m17n-docs 1.8.4-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 53,736 kB
  • sloc: javascript: 7,609; sh: 1,256; makefile: 351; ansic: 206
file content (1269 lines) | stat: -rw-r--r-- 79,729 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.9.1"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>The m17n Library: Text Property</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">The m17n Library
   &#160;<span id="projectnumber">1.8.4</span>
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.9.1 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search','.html');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
</div><!-- top -->
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#typedef-members">Typedefs</a> &#124;
<a href="#enum-members">Enumerations</a> &#124;
<a href="#func-members">Functions</a> &#124;
<a href="#var-members">Variables</a>  </div>
  <div class="headertitle">
<div class="title">Text Property<div class="ingroups"><a class="el" href="group__m17nCore.html">CORE API</a></div></div>  </div>
</div><!--header-->
<div class="contents">

<p>Function to handle text properties.  
<a href="#details">More...</a></p>
<div class="dynheader">
Collaboration diagram for Text Property:</div>
<div class="dyncontent">
<div class="center"><img src="group__m17nTextProperty.png" border="0" usemap="#agroup____m17nTextProperty" alt=""/></div>
<map name="agroup____m17nTextProperty" id="agroup____m17nTextProperty">
<area shape="rect" title="Function to handle text properties." alt="" coords="136,5,244,31"/>
<area shape="rect" href="group__m17nCore.html" title="API provided by libm17n&#45;core.so" alt="" coords="5,5,88,31"/>
</map>
</div>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="typedef-members"></a>
Typedefs</h2></td></tr>
<tr class="memitem:gaff9cca52bfb7587ce765ac50d16f665b"><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="structMPlist.html">MPlist</a> *(*&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#gaff9cca52bfb7587ce765ac50d16f665b">MTextPropSerializeFunc</a>) (void *val)</td></tr>
<tr class="memdesc:gaff9cca52bfb7587ce765ac50d16f665b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Type of serializer functions.  <a href="group__m17nTextProperty.html#gaff9cca52bfb7587ce765ac50d16f665b">More...</a><br /></td></tr>
<tr class="separator:gaff9cca52bfb7587ce765ac50d16f665b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga8db0a5d860d1b8b1fcd7f0e25230df39"><td class="memItemLeft" align="right" valign="top">typedef void *(*&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#ga8db0a5d860d1b8b1fcd7f0e25230df39">MTextPropDeserializeFunc</a>) (<a class="el" href="structMPlist.html">MPlist</a> *plist)</td></tr>
<tr class="memdesc:ga8db0a5d860d1b8b1fcd7f0e25230df39"><td class="mdescLeft">&#160;</td><td class="mdescRight">Type of deserializer functions.  <a href="group__m17nTextProperty.html#ga8db0a5d860d1b8b1fcd7f0e25230df39">More...</a><br /></td></tr>
<tr class="separator:ga8db0a5d860d1b8b1fcd7f0e25230df39"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="enum-members"></a>
Enumerations</h2></td></tr>
<tr class="memitem:ga5b33fa00eaa5a08531732df88a24a9a9"><td class="memItemLeft" align="right" valign="top">enum &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#ga5b33fa00eaa5a08531732df88a24a9a9">MTextPropertyControl</a> { <br />
&#160;&#160;<a class="el" href="group__m17nTextProperty.html#gga5b33fa00eaa5a08531732df88a24a9a9a12cbd712f80075cc687d5f901ea47c5a">MTEXTPROP_FRONT_STICKY</a> = 0x01
, <br />
&#160;&#160;<a class="el" href="group__m17nTextProperty.html#gga5b33fa00eaa5a08531732df88a24a9a9a3acb63f56ef54332511eded4e7d6fb6d">MTEXTPROP_REAR_STICKY</a> = 0x02
, <br />
&#160;&#160;<a class="el" href="group__m17nTextProperty.html#gga5b33fa00eaa5a08531732df88a24a9a9a82c87bdf72b1a175e58908c9279af7be">MTEXTPROP_VOLATILE_WEAK</a> = 0x04
, <br />
&#160;&#160;<a class="el" href="group__m17nTextProperty.html#gga5b33fa00eaa5a08531732df88a24a9a9a6359a5ae58e92c371f08539c7559c16e">MTEXTPROP_VOLATILE_STRONG</a> = 0x08
, <br />
&#160;&#160;<a class="el" href="group__m17nTextProperty.html#gga5b33fa00eaa5a08531732df88a24a9a9a9cf177c28dc6f80836f805d0825e1839">MTEXTPROP_NO_MERGE</a> = 0x10
, <br />
&#160;&#160;<a class="el" href="group__m17nTextProperty.html#gga5b33fa00eaa5a08531732df88a24a9a9a9c1f2de18de1e6e9823ef7943e2670e9">MTEXTPROP_CONTROL_MAX</a> = 0x1F
<br />
 }</td></tr>
<tr class="memdesc:ga5b33fa00eaa5a08531732df88a24a9a9"><td class="mdescLeft">&#160;</td><td class="mdescRight">Flag bits to control text property.  <a href="group__m17nTextProperty.html#ga5b33fa00eaa5a08531732df88a24a9a9">More...</a><br /></td></tr>
<tr class="separator:ga5b33fa00eaa5a08531732df88a24a9a9"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:ga3b37b8a451e0618b8393402a88123a5c"><td class="memItemLeft" align="right" valign="top">void *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#ga3b37b8a451e0618b8393402a88123a5c">mtext_get_prop</a> (<a class="el" href="structMText.html">MText</a> *mt, int pos, MSymbol key)</td></tr>
<tr class="memdesc:ga3b37b8a451e0618b8393402a88123a5c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the value of the topmost text property.  <a href="group__m17nTextProperty.html#ga3b37b8a451e0618b8393402a88123a5c">More...</a><br /></td></tr>
<tr class="separator:ga3b37b8a451e0618b8393402a88123a5c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga7649d0794df9829ece537861eaff87cf"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#ga7649d0794df9829ece537861eaff87cf">mtext_get_prop_values</a> (<a class="el" href="structMText.html">MText</a> *mt, int pos, MSymbol key, void **values, int num)</td></tr>
<tr class="memdesc:ga7649d0794df9829ece537861eaff87cf"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get multiple values of a text property.  <a href="group__m17nTextProperty.html#ga7649d0794df9829ece537861eaff87cf">More...</a><br /></td></tr>
<tr class="separator:ga7649d0794df9829ece537861eaff87cf"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga0072b994eed0eefd66be053484bf1dc9"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#ga0072b994eed0eefd66be053484bf1dc9">mtext_get_prop_keys</a> (<a class="el" href="structMText.html">MText</a> *mt, int pos, MSymbol **keys)</td></tr>
<tr class="memdesc:ga0072b994eed0eefd66be053484bf1dc9"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get a list of text property keys at a position of an M-text.  <a href="group__m17nTextProperty.html#ga0072b994eed0eefd66be053484bf1dc9">More...</a><br /></td></tr>
<tr class="separator:ga0072b994eed0eefd66be053484bf1dc9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga0ebfee8b550cc5ccaefd6f091fc5695f"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#ga0ebfee8b550cc5ccaefd6f091fc5695f">mtext_put_prop</a> (<a class="el" href="structMText.html">MText</a> *mt, int from, int to, MSymbol key, void *val)</td></tr>
<tr class="separator:ga0ebfee8b550cc5ccaefd6f091fc5695f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaa027998420efcfa94b5e91140ea08787"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#gaa027998420efcfa94b5e91140ea08787">mtext_put_prop_values</a> (<a class="el" href="structMText.html">MText</a> *mt, int from, int to, MSymbol key, void **values, int num)</td></tr>
<tr class="memdesc:gaa027998420efcfa94b5e91140ea08787"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set multiple text properties with the same key.  <a href="group__m17nTextProperty.html#gaa027998420efcfa94b5e91140ea08787">More...</a><br /></td></tr>
<tr class="separator:gaa027998420efcfa94b5e91140ea08787"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga1525f066294eb2645b5c2e41b68e0a65"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#ga1525f066294eb2645b5c2e41b68e0a65">mtext_push_prop</a> (<a class="el" href="structMText.html">MText</a> *mt, int from, int to, MSymbol key, void *val)</td></tr>
<tr class="separator:ga1525f066294eb2645b5c2e41b68e0a65"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaa63265ad53bc7fddf62631fa8f3fb0d5"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#gaa63265ad53bc7fddf62631fa8f3fb0d5">mtext_pop_prop</a> (<a class="el" href="structMText.html">MText</a> *mt, int from, int to, MSymbol key)</td></tr>
<tr class="separator:gaa63265ad53bc7fddf62631fa8f3fb0d5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gae023984f61bfb4198f9ac70350bdb8d4"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#gae023984f61bfb4198f9ac70350bdb8d4">mtext_prop_range</a> (<a class="el" href="structMText.html">MText</a> *mt, MSymbol key, int pos, int *from, int *to, int deeper)</td></tr>
<tr class="memdesc:gae023984f61bfb4198f9ac70350bdb8d4"><td class="mdescLeft">&#160;</td><td class="mdescRight">Find the range where the value of a text property is the same.  <a href="group__m17nTextProperty.html#gae023984f61bfb4198f9ac70350bdb8d4">More...</a><br /></td></tr>
<tr class="separator:gae023984f61bfb4198f9ac70350bdb8d4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gad94bf3a0a1384c2a7b5a759c7a93b88b"><td class="memItemLeft" align="right" valign="top"><a class="el" href="structMTextProperty.html">MTextProperty</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#gad94bf3a0a1384c2a7b5a759c7a93b88b">mtext_property</a> (MSymbol key, void *val, int control_bits)</td></tr>
<tr class="memdesc:gad94bf3a0a1384c2a7b5a759c7a93b88b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Create a text property.  <a href="group__m17nTextProperty.html#gad94bf3a0a1384c2a7b5a759c7a93b88b">More...</a><br /></td></tr>
<tr class="separator:gad94bf3a0a1384c2a7b5a759c7a93b88b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga0c227387edfda07824c6822e9e27435a"><td class="memItemLeft" align="right" valign="top"><a class="el" href="structMText.html">MText</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#ga0c227387edfda07824c6822e9e27435a">mtext_property_mtext</a> (<a class="el" href="structMTextProperty.html">MTextProperty</a> *prop)</td></tr>
<tr class="memdesc:ga0c227387edfda07824c6822e9e27435a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return the M-text of a text property.  <a href="group__m17nTextProperty.html#ga0c227387edfda07824c6822e9e27435a">More...</a><br /></td></tr>
<tr class="separator:ga0c227387edfda07824c6822e9e27435a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga1faaffce04424f85f5a78461ad9bfaec"><td class="memItemLeft" align="right" valign="top">MSymbol&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#ga1faaffce04424f85f5a78461ad9bfaec">mtext_property_key</a> (<a class="el" href="structMTextProperty.html">MTextProperty</a> *prop)</td></tr>
<tr class="memdesc:ga1faaffce04424f85f5a78461ad9bfaec"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return the key of a text property.  <a href="group__m17nTextProperty.html#ga1faaffce04424f85f5a78461ad9bfaec">More...</a><br /></td></tr>
<tr class="separator:ga1faaffce04424f85f5a78461ad9bfaec"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga5d3bbf3edab14ee3d26be9158b41bb31"><td class="memItemLeft" align="right" valign="top">void *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#ga5d3bbf3edab14ee3d26be9158b41bb31">mtext_property_value</a> (<a class="el" href="structMTextProperty.html">MTextProperty</a> *prop)</td></tr>
<tr class="memdesc:ga5d3bbf3edab14ee3d26be9158b41bb31"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return the value of a text property.  <a href="group__m17nTextProperty.html#ga5d3bbf3edab14ee3d26be9158b41bb31">More...</a><br /></td></tr>
<tr class="separator:ga5d3bbf3edab14ee3d26be9158b41bb31"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gac03079958c4de03ebc72766cf27bca25"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#gac03079958c4de03ebc72766cf27bca25">mtext_property_start</a> (<a class="el" href="structMTextProperty.html">MTextProperty</a> *prop)</td></tr>
<tr class="memdesc:gac03079958c4de03ebc72766cf27bca25"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return the start position of a text property.  <a href="group__m17nTextProperty.html#gac03079958c4de03ebc72766cf27bca25">More...</a><br /></td></tr>
<tr class="separator:gac03079958c4de03ebc72766cf27bca25"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga550abffc59e78bfa137e44469af2f102"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#ga550abffc59e78bfa137e44469af2f102">mtext_property_end</a> (<a class="el" href="structMTextProperty.html">MTextProperty</a> *prop)</td></tr>
<tr class="memdesc:ga550abffc59e78bfa137e44469af2f102"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return the end position of a text property.  <a href="group__m17nTextProperty.html#ga550abffc59e78bfa137e44469af2f102">More...</a><br /></td></tr>
<tr class="separator:ga550abffc59e78bfa137e44469af2f102"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga857bf31decfcc6063f33183373901c3e"><td class="memItemLeft" align="right" valign="top"><a class="el" href="structMTextProperty.html">MTextProperty</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#ga857bf31decfcc6063f33183373901c3e">mtext_get_property</a> (<a class="el" href="structMText.html">MText</a> *mt, int pos, MSymbol key)</td></tr>
<tr class="memdesc:ga857bf31decfcc6063f33183373901c3e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the topmost text property.  <a href="group__m17nTextProperty.html#ga857bf31decfcc6063f33183373901c3e">More...</a><br /></td></tr>
<tr class="separator:ga857bf31decfcc6063f33183373901c3e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaa08e0d0924274c37f28fca9afb0d7d58"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#gaa08e0d0924274c37f28fca9afb0d7d58">mtext_get_properties</a> (<a class="el" href="structMText.html">MText</a> *mt, int pos, MSymbol key, <a class="el" href="structMTextProperty.html">MTextProperty</a> **props, int num)</td></tr>
<tr class="memdesc:gaa08e0d0924274c37f28fca9afb0d7d58"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get multiple text properties.  <a href="group__m17nTextProperty.html#gaa08e0d0924274c37f28fca9afb0d7d58">More...</a><br /></td></tr>
<tr class="separator:gaa08e0d0924274c37f28fca9afb0d7d58"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga80333ace7a285d5a09ed0575cda75d84"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#ga80333ace7a285d5a09ed0575cda75d84">mtext_attach_property</a> (<a class="el" href="structMText.html">MText</a> *mt, int from, int to, <a class="el" href="structMTextProperty.html">MTextProperty</a> *prop)</td></tr>
<tr class="memdesc:ga80333ace7a285d5a09ed0575cda75d84"><td class="mdescLeft">&#160;</td><td class="mdescRight">Attach a text property to an M-text.  <a href="group__m17nTextProperty.html#ga80333ace7a285d5a09ed0575cda75d84">More...</a><br /></td></tr>
<tr class="separator:ga80333ace7a285d5a09ed0575cda75d84"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga6e4c9702d75cde94c6bfc9f44ea13258"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#ga6e4c9702d75cde94c6bfc9f44ea13258">mtext_detach_property</a> (<a class="el" href="structMTextProperty.html">MTextProperty</a> *prop)</td></tr>
<tr class="memdesc:ga6e4c9702d75cde94c6bfc9f44ea13258"><td class="mdescLeft">&#160;</td><td class="mdescRight">Detach a text property from an M-text.  <a href="group__m17nTextProperty.html#ga6e4c9702d75cde94c6bfc9f44ea13258">More...</a><br /></td></tr>
<tr class="separator:ga6e4c9702d75cde94c6bfc9f44ea13258"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga1db069da9e058d3129a6469f4d359c0f"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#ga1db069da9e058d3129a6469f4d359c0f">mtext_push_property</a> (<a class="el" href="structMText.html">MText</a> *mt, int from, int to, <a class="el" href="structMTextProperty.html">MTextProperty</a> *prop)</td></tr>
<tr class="memdesc:ga1db069da9e058d3129a6469f4d359c0f"><td class="mdescLeft">&#160;</td><td class="mdescRight">Push a text property onto an M-text.  <a href="group__m17nTextProperty.html#ga1db069da9e058d3129a6469f4d359c0f">More...</a><br /></td></tr>
<tr class="separator:ga1db069da9e058d3129a6469f4d359c0f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga4830a8a120aeed2185d6da8fd2daa05e"><td class="memItemLeft" align="right" valign="top"><a class="el" href="structMText.html">MText</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#ga4830a8a120aeed2185d6da8fd2daa05e">mtext_serialize</a> (<a class="el" href="structMText.html">MText</a> *mt, int from, int to, <a class="el" href="structMPlist.html">MPlist</a> *property_list)</td></tr>
<tr class="separator:ga4830a8a120aeed2185d6da8fd2daa05e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga82e022961a26f82ddf580782a50d94bf"><td class="memItemLeft" align="right" valign="top"><a class="el" href="structMText.html">MText</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#ga82e022961a26f82ddf580782a50d94bf">mtext_deserialize</a> (<a class="el" href="structMText.html">MText</a> *mt)</td></tr>
<tr class="separator:ga82e022961a26f82ddf580782a50d94bf"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="var-members"></a>
Variables</h2></td></tr>
<tr class="memitem:ga759ba1a6ac36d9847bc6b4d431ae3735"><td class="memItemLeft" align="right" valign="top">MSymbol&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#ga759ba1a6ac36d9847bc6b4d431ae3735">Mtext_prop_serializer</a></td></tr>
<tr class="memdesc:ga759ba1a6ac36d9847bc6b4d431ae3735"><td class="mdescLeft">&#160;</td><td class="mdescRight">Symbol for specifying serializer functions.  <a href="group__m17nTextProperty.html#ga759ba1a6ac36d9847bc6b4d431ae3735">More...</a><br /></td></tr>
<tr class="separator:ga759ba1a6ac36d9847bc6b4d431ae3735"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga97f4c75b4ebf8ff252948dbf068bc077"><td class="memItemLeft" align="right" valign="top">MSymbol&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nTextProperty.html#ga97f4c75b4ebf8ff252948dbf068bc077">Mtext_prop_deserializer</a></td></tr>
<tr class="memdesc:ga97f4c75b4ebf8ff252948dbf068bc077"><td class="mdescLeft">&#160;</td><td class="mdescRight">Symbol for specifying deserializer functions.  <a href="group__m17nTextProperty.html#ga97f4c75b4ebf8ff252948dbf068bc077">More...</a><br /></td></tr>
<tr class="separator:ga97f4c75b4ebf8ff252948dbf068bc077"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<p>Function to handle text properties. </p>
<p>Each character in an M-text can have properties called <em>text</em> <em>properties</em>. Text properties store various kinds of information attached to parts of an M-text to provide application programs with a unified view of those information. As rich information can be stored in M-texts in the form of text properties, functions in application programs can be simple.</p>
<p>A text property consists of a <em>key</em> and <em>values</em>, where key is a symbol and values are anything that can be cast to <code>(void *) </code>. Unlike other types of properties, a text property can have multiple values. "The text property whose key is K" may be shortened to "K property". <br  />
 </p>
<h2 class="groupheader">Typedef Documentation</h2>
<a id="gaff9cca52bfb7587ce765ac50d16f665b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gaff9cca52bfb7587ce765ac50d16f665b">&#9670;&nbsp;</a></span>MTextPropSerializeFunc</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">typedef <a class="el" href="structMPlist.html">MPlist</a>*(* MTextPropSerializeFunc) (void *val)</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Type of serializer functions. </p>
<p>This is the type of serializer functions. If the key of a symbol property is <a class="el" href="group__m17nTextProperty.html#ga759ba1a6ac36d9847bc6b4d431ae3735" title="Symbol for specifying serializer functions.">Mtext_prop_serializer</a>, the value must be of this type.</p>
<dl class="section user"><dt>See Also:</dt><dd><a class="el" href="group__m17nTextProperty.html#ga4830a8a120aeed2185d6da8fd2daa05e">mtext_serialize()</a>, <a class="el" href="group__m17nTextProperty.html#ga759ba1a6ac36d9847bc6b4d431ae3735" title="Symbol for specifying serializer functions.">Mtext_prop_serializer</a> </dd></dl>

</div>
</div>
<a id="ga8db0a5d860d1b8b1fcd7f0e25230df39"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga8db0a5d860d1b8b1fcd7f0e25230df39">&#9670;&nbsp;</a></span>MTextPropDeserializeFunc</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">typedef void*(* MTextPropDeserializeFunc) (<a class="el" href="structMPlist.html">MPlist</a> *plist)</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Type of deserializer functions. </p>
<p>This is the type of deserializer functions. If the key of a symbol property is <a class="el" href="group__m17nTextProperty.html#ga97f4c75b4ebf8ff252948dbf068bc077" title="Symbol for specifying deserializer functions.">Mtext_prop_deserializer</a>, the value must be of this type.</p>
<dl class="section user"><dt>See Also:</dt><dd><a class="el" href="group__m17nTextProperty.html#ga82e022961a26f82ddf580782a50d94bf">mtext_deserialize()</a>, <a class="el" href="group__m17nTextProperty.html#ga97f4c75b4ebf8ff252948dbf068bc077" title="Symbol for specifying deserializer functions.">Mtext_prop_deserializer</a> </dd></dl>

</div>
</div>
<h2 class="groupheader">Enumeration Type Documentation</h2>
<a id="ga5b33fa00eaa5a08531732df88a24a9a9"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga5b33fa00eaa5a08531732df88a24a9a9">&#9670;&nbsp;</a></span>MTextPropertyControl</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">enum <a class="el" href="group__m17nTextProperty.html#ga5b33fa00eaa5a08531732df88a24a9a9">MTextPropertyControl</a></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Flag bits to control text property. </p>
<p>The <a class="el" href="group__m17nTextProperty.html#gad94bf3a0a1384c2a7b5a759c7a93b88b" title="Create a text property.">mtext_property()</a> function accepts logical OR of these flag bits as an argument. They control the behaviour of the created text property as described in the documentation of each flag bit. <br  />
 </p>
<table class="fieldtable">
<tr><th colspan="2">Enumerator</th></tr><tr><td class="fieldname"><a id="gga5b33fa00eaa5a08531732df88a24a9a9a12cbd712f80075cc687d5f901ea47c5a"></a>MTEXTPROP_FRONT_STICKY&#160;</td><td class="fielddoc"><p>If this flag bit is on, an M-text inserted at the start position or at the middle of the text property inherits the text property. <br  />
 </p>
</td></tr>
<tr><td class="fieldname"><a id="gga5b33fa00eaa5a08531732df88a24a9a9a3acb63f56ef54332511eded4e7d6fb6d"></a>MTEXTPROP_REAR_STICKY&#160;</td><td class="fielddoc"><p>If this flag bit is on, an M-text inserted at the end position or at the middle of the text property inherits the text property. <br  />
 </p>
</td></tr>
<tr><td class="fieldname"><a id="gga5b33fa00eaa5a08531732df88a24a9a9a82c87bdf72b1a175e58908c9279af7be"></a>MTEXTPROP_VOLATILE_WEAK&#160;</td><td class="fielddoc"><p>If this flag bit is on, the text property is removed if a text in its region is modified. <br  />
 </p>
</td></tr>
<tr><td class="fieldname"><a id="gga5b33fa00eaa5a08531732df88a24a9a9a6359a5ae58e92c371f08539c7559c16e"></a>MTEXTPROP_VOLATILE_STRONG&#160;</td><td class="fielddoc"><p>If this flag bit is on, the text property is removed if a text or the other text property in its region is modified. <br  />
 </p>
</td></tr>
<tr><td class="fieldname"><a id="gga5b33fa00eaa5a08531732df88a24a9a9a9cf177c28dc6f80836f805d0825e1839"></a>MTEXTPROP_NO_MERGE&#160;</td><td class="fielddoc"><p>If this flag bit is on, the text property is not automatically merged with the others. <br  />
 </p>
</td></tr>
<tr><td class="fieldname"><a id="gga5b33fa00eaa5a08531732df88a24a9a9a9c1f2de18de1e6e9823ef7943e2670e9"></a>MTEXTPROP_CONTROL_MAX&#160;</td><td class="fielddoc"></td></tr>
</table>

</div>
</div>
<h2 class="groupheader">Function Documentation</h2>
<a id="ga3b37b8a451e0618b8393402a88123a5c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga3b37b8a451e0618b8393402a88123a5c">&#9670;&nbsp;</a></span>mtext_get_prop()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void* mtext_get_prop </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structMText.html">MText</a> *&#160;</td>
          <td class="paramname"><em>mt</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>pos</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">MSymbol&#160;</td>
          <td class="paramname"><em>key</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Get the value of the topmost text property. </p>
<p>The <a class="el" href="group__m17nTextProperty.html#ga3b37b8a451e0618b8393402a88123a5c" title="Get the value of the topmost text property.">mtext_get_prop()</a> function searches the character at <b>pos</b> in M-text <b>mt</b> for the text property whose key is <b>key</b>.</p>
<dl class="section user"><dt>Return value:</dt><dd>If a text property is found, <a class="el" href="group__m17nTextProperty.html#ga3b37b8a451e0618b8393402a88123a5c" title="Get the value of the topmost text property.">mtext_get_prop()</a> returns the value of the property. If the property has multiple values, it returns the topmost one. If no such property is found, it returns <code>NULL</code> without changing the external variable <a class="el" href="group__m17nError.html#ga995a2e373cfd6a8e5eaca8686b5b0a73" title="External variable to hold error code of the m17n library.">merror_code</a>.</dd></dl>
<p>If an error is detected, <a class="el" href="group__m17nTextProperty.html#ga3b37b8a451e0618b8393402a88123a5c" title="Get the value of the topmost text property.">mtext_get_prop()</a> returns <code>NULL</code> and assigns an error code to the external variable <a class="el" href="group__m17nError.html#ga995a2e373cfd6a8e5eaca8686b5b0a73" title="External variable to hold error code of the m17n library.">merror_code</a>.</p>
<dl class="section note"><dt>Note</dt><dd>If <code>NULL</code> is returned without an error, there are two possibilities:</dd></dl>
<ul>
<li>the character at <b>pos</b> does not have a property whose key is <b>key</b>, or</li>
</ul>
<ul>
<li>the character does have such a property and its value is <code>NULL</code>. <br  />
</li>
</ul>
<p>If you need to distinguish these two cases, use the <a class="el" href="group__m17nTextProperty.html#ga7649d0794df9829ece537861eaff87cf" title="Get multiple values of a text property.">mtext_get_prop_values()</a> function instead. <br  />
</p>
<dl class="section user"><dt>Errors:</dt><dd><code>MERROR_RANGE</code>, <code>MERROR_SYMBOL</code> </dd></dl>
<dl class="section user"><dt>See Also:</dt><dd><a class="el" href="group__m17nTextProperty.html#ga7649d0794df9829ece537861eaff87cf" title="Get multiple values of a text property.">mtext_get_prop_values()</a>, <a class="el" href="group__m17nTextProperty.html#ga0ebfee8b550cc5ccaefd6f091fc5695f">mtext_put_prop()</a>, <a class="el" href="group__m17nTextProperty.html#gaa027998420efcfa94b5e91140ea08787" title="Set multiple text properties with the same key.">mtext_put_prop_values()</a>, <a class="el" href="group__m17nTextProperty.html#ga1525f066294eb2645b5c2e41b68e0a65">mtext_push_prop()</a>, <a class="el" href="group__m17nTextProperty.html#gaa63265ad53bc7fddf62631fa8f3fb0d5">mtext_pop_prop()</a>, <a class="el" href="group__m17nTextProperty.html#gae023984f61bfb4198f9ac70350bdb8d4" title="Find the range where the value of a text property is the same.">mtext_prop_range()</a> <br  />
 </dd></dl>

</div>
</div>
<a id="ga7649d0794df9829ece537861eaff87cf"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga7649d0794df9829ece537861eaff87cf">&#9670;&nbsp;</a></span>mtext_get_prop_values()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int mtext_get_prop_values </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structMText.html">MText</a> *&#160;</td>
          <td class="paramname"><em>mt</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>pos</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">MSymbol&#160;</td>
          <td class="paramname"><em>key</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void **&#160;</td>
          <td class="paramname"><em>values</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>num</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Get multiple values of a text property. </p>
<p>The <a class="el" href="group__m17nTextProperty.html#ga7649d0794df9829ece537861eaff87cf" title="Get multiple values of a text property.">mtext_get_prop_values()</a> function searches the character at <b>pos</b> in M-text <b>mt</b> for the property whose key is <b>key</b>. If such a property is found, its values are stored in the memory area pointed to by <b>values</b>. <b>num</b> limits the maximum number of stored values.</p>
<dl class="section user"><dt>Return value:</dt><dd>If the operation was successful, <a class="el" href="group__m17nTextProperty.html#ga7649d0794df9829ece537861eaff87cf" title="Get multiple values of a text property.">mtext_get_prop_values()</a> returns the number of actually stored values. If the character at <b>pos</b> does not have a property whose key is <b>key</b>, the return value is 0. If an error is detected, <a class="el" href="group__m17nTextProperty.html#ga7649d0794df9829ece537861eaff87cf" title="Get multiple values of a text property.">mtext_get_prop_values()</a> returns -1 and assigns an error code to the external variable <a class="el" href="group__m17nError.html#ga995a2e373cfd6a8e5eaca8686b5b0a73" title="External variable to hold error code of the m17n library.">merror_code</a>. <br  />
</dd></dl>
<dl class="section user"><dt>Errors:</dt><dd><code>MERROR_RANGE</code>, <code>MERROR_SYMBOL</code> </dd></dl>
<dl class="section user"><dt>See Also:</dt><dd><a class="el" href="group__m17nTextProperty.html#ga3b37b8a451e0618b8393402a88123a5c" title="Get the value of the topmost text property.">mtext_get_prop()</a>, <a class="el" href="group__m17nTextProperty.html#ga0ebfee8b550cc5ccaefd6f091fc5695f">mtext_put_prop()</a>, <a class="el" href="group__m17nTextProperty.html#gaa027998420efcfa94b5e91140ea08787" title="Set multiple text properties with the same key.">mtext_put_prop_values()</a>, <a class="el" href="group__m17nTextProperty.html#ga1525f066294eb2645b5c2e41b68e0a65">mtext_push_prop()</a>, <a class="el" href="group__m17nTextProperty.html#gaa63265ad53bc7fddf62631fa8f3fb0d5">mtext_pop_prop()</a>, <a class="el" href="group__m17nTextProperty.html#gae023984f61bfb4198f9ac70350bdb8d4" title="Find the range where the value of a text property is the same.">mtext_prop_range()</a> <br  />
 </dd></dl>

</div>
</div>
<a id="ga0072b994eed0eefd66be053484bf1dc9"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga0072b994eed0eefd66be053484bf1dc9">&#9670;&nbsp;</a></span>mtext_get_prop_keys()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int mtext_get_prop_keys </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structMText.html">MText</a> *&#160;</td>
          <td class="paramname"><em>mt</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>pos</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">MSymbol **&#160;</td>
          <td class="paramname"><em>keys</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Get a list of text property keys at a position of an M-text. </p>
<p>The <a class="el" href="group__m17nTextProperty.html#ga0072b994eed0eefd66be053484bf1dc9" title="Get a list of text property keys at a position of an M-text.">mtext_get_prop_keys()</a> function creates an array whose elements are the keys of text properties found at position <b>pos</b> in M-text <b>mt</b>, and sets *<b>keys</b> to the address of the created array. The user is responsible to free the memory allocated for the array.</p>
<dl class="section user"><dt>Return value:</dt><dd>If the operation was successful, <a class="el" href="group__m17nTextProperty.html#ga0072b994eed0eefd66be053484bf1dc9" title="Get a list of text property keys at a position of an M-text.">mtext_get_prop_keys()</a> returns the length of the key list. Otherwise it returns -1 and assigns an error code to the external variable <a class="el" href="group__m17nError.html#ga995a2e373cfd6a8e5eaca8686b5b0a73" title="External variable to hold error code of the m17n library.">merror_code</a>.</dd></dl>
<dl class="section user"><dt>Errors:</dt><dd><code>MERROR_RANGE</code> </dd></dl>
<dl class="section user"><dt>See Also:</dt><dd><a class="el" href="group__m17nTextProperty.html#ga3b37b8a451e0618b8393402a88123a5c" title="Get the value of the topmost text property.">mtext_get_prop()</a>, <a class="el" href="group__m17nTextProperty.html#ga0ebfee8b550cc5ccaefd6f091fc5695f">mtext_put_prop()</a>, <a class="el" href="group__m17nTextProperty.html#gaa027998420efcfa94b5e91140ea08787" title="Set multiple text properties with the same key.">mtext_put_prop_values()</a>, <a class="el" href="group__m17nTextProperty.html#ga7649d0794df9829ece537861eaff87cf" title="Get multiple values of a text property.">mtext_get_prop_values()</a>, <a class="el" href="group__m17nTextProperty.html#ga1525f066294eb2645b5c2e41b68e0a65">mtext_push_prop()</a>, <a class="el" href="group__m17nTextProperty.html#gaa63265ad53bc7fddf62631fa8f3fb0d5">mtext_pop_prop()</a> <br  />
 </dd></dl>

</div>
</div>
<a id="ga0ebfee8b550cc5ccaefd6f091fc5695f"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga0ebfee8b550cc5ccaefd6f091fc5695f">&#9670;&nbsp;</a></span>mtext_put_prop()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int mtext_put_prop </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structMText.html">MText</a> *&#160;</td>
          <td class="paramname"><em>mt</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>from</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>to</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">MSymbol&#160;</td>
          <td class="paramname"><em>key</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void *&#160;</td>
          <td class="paramname"><em>val</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<pre class="fragment">@brief Set a text property.

The mtext_put_prop() function sets a text property to the
characters between @b from (inclusive) and @b to (exclusive) in M-text
@b mt.  @b key and @b val specify the key and the value of the text
property.  With this function,
</pre> <pre class="fragment">                     FROM                   TO
M-text: |&lt;------------|-------- MT ---------|------------&gt;|
PROP  :  &lt;------------------ OLD_VAL --------------------&gt;
</pre><p>becomes</p>
<pre class="fragment">                     FROM                   TO
M-text: |&lt;------------|-------- MT ---------|------------&gt;|
PROP  :  &lt;-- OLD_VAL-&gt;&lt;-------- VAL -------&gt;&lt;-- OLD_VAL--&gt;
</pre> <pre class="fragment">@par Return value:
If the operation was successful, mtext_put_prop() returns 0.
Otherwise it returns -1 and assigns an error code to the external
variable #merror_code.   

@par Errors:
@c MERROR_RANGE, @c MERROR_SYMBOL

@par See Also:
mtext_put_prop_values(), mtext_get_prop(),
mtext_get_prop_values(), mtext_push_prop(),
mtext_pop_prop(), mtext_prop_range()   
</pre> 
</div>
</div>
<a id="gaa027998420efcfa94b5e91140ea08787"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gaa027998420efcfa94b5e91140ea08787">&#9670;&nbsp;</a></span>mtext_put_prop_values()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int mtext_put_prop_values </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structMText.html">MText</a> *&#160;</td>
          <td class="paramname"><em>mt</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>from</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>to</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">MSymbol&#160;</td>
          <td class="paramname"><em>key</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void **&#160;</td>
          <td class="paramname"><em>values</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>num</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Set multiple text properties with the same key. </p>
<p>The <a class="el" href="group__m17nTextProperty.html#gaa027998420efcfa94b5e91140ea08787" title="Set multiple text properties with the same key.">mtext_put_prop_values()</a> function sets a text property to the characters between <b>from</b> (inclusive) and <b>to</b> (exclusive) in M-text <b>mt</b>. <b>key</b> and <b>values</b> specify the key and the values of the text property. <b>num</b> specifies the number of property values to be set.</p>
<dl class="section user"><dt>Return value:</dt><dd>If the operation was successful, <a class="el" href="group__m17nTextProperty.html#gaa027998420efcfa94b5e91140ea08787" title="Set multiple text properties with the same key.">mtext_put_prop_values()</a> returns 0. Otherwise it returns -1 and assigns an error code to the external variable <a class="el" href="group__m17nError.html#ga995a2e373cfd6a8e5eaca8686b5b0a73" title="External variable to hold error code of the m17n library.">merror_code</a>. <br  />
</dd></dl>
<dl class="section user"><dt>Errors:</dt><dd><code>MERROR_RANGE</code>, <code>MERROR_SYMBOL</code> </dd></dl>
<dl class="section user"><dt>See Also:</dt><dd><a class="el" href="group__m17nTextProperty.html#ga0ebfee8b550cc5ccaefd6f091fc5695f">mtext_put_prop()</a>, <a class="el" href="group__m17nTextProperty.html#ga3b37b8a451e0618b8393402a88123a5c" title="Get the value of the topmost text property.">mtext_get_prop()</a>, <a class="el" href="group__m17nTextProperty.html#ga7649d0794df9829ece537861eaff87cf" title="Get multiple values of a text property.">mtext_get_prop_values()</a>, <a class="el" href="group__m17nTextProperty.html#ga1525f066294eb2645b5c2e41b68e0a65">mtext_push_prop()</a>, <a class="el" href="group__m17nTextProperty.html#gaa63265ad53bc7fddf62631fa8f3fb0d5">mtext_pop_prop()</a>, <a class="el" href="group__m17nTextProperty.html#gae023984f61bfb4198f9ac70350bdb8d4" title="Find the range where the value of a text property is the same.">mtext_prop_range()</a> <br  />
 </dd></dl>

</div>
</div>
<a id="ga1525f066294eb2645b5c2e41b68e0a65"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga1525f066294eb2645b5c2e41b68e0a65">&#9670;&nbsp;</a></span>mtext_push_prop()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int mtext_push_prop </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structMText.html">MText</a> *&#160;</td>
          <td class="paramname"><em>mt</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>from</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>to</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">MSymbol&#160;</td>
          <td class="paramname"><em>key</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void *&#160;</td>
          <td class="paramname"><em>val</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<pre class="fragment">@brief Push a text property.

The mtext_push_prop() function pushes a text property whose key
is @b key and value is @b val to the characters between @b from
(inclusive) and @b to (exclusive) in M-text @b mt.  With this
function,
</pre> <pre class="fragment">                    FROM                    TO
M-text: |&lt;------------|-------- MT ---------|------------&gt;|
PROP  :  &lt;------------------ OLD_VAL --------------------&gt;
</pre> <pre class="fragment">becomes
</pre> <pre class="fragment">                    FROM                    TO
M-text: |&lt;------------|-------- MT ---------|------------&gt;|
PROP  :  &lt;------------------- OLD_VAL -------------------&gt;
PROP  :               &lt;-------- VAL -------&gt;
</pre> <pre class="fragment">@par Return value:
If the operation was successful, mtext_push_prop() returns 0.
Otherwise it returns -1 and assigns an error code to the external
variable #merror_code.   

@par Errors:
@c MERROR_RANGE, @c MERROR_SYMBOL

@par See Also:
mtext_put_prop(), mtext_put_prop_values(),
mtext_get_prop(), mtext_get_prop_values(),
mtext_pop_prop(), mtext_prop_range()   
</pre> 
</div>
</div>
<a id="gaa63265ad53bc7fddf62631fa8f3fb0d5"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gaa63265ad53bc7fddf62631fa8f3fb0d5">&#9670;&nbsp;</a></span>mtext_pop_prop()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int mtext_pop_prop </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structMText.html">MText</a> *&#160;</td>
          <td class="paramname"><em>mt</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>from</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>to</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">MSymbol&#160;</td>
          <td class="paramname"><em>key</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<pre class="fragment">@brief Pop a text property.

The mtext_pop_prop() function removes the topmost text property
whose key is @b key from the characters between @b from (inclusive)
and and @b to (exclusive) in @b mt.

This function does nothing if characters in the region have no
such text property. With this function,
</pre> <pre class="fragment">                    FROM                    TO
M-text: |&lt;------------|-------- MT ---------|------------&gt;|
PROP  :  &lt;------------------ OLD_VAL --------------------&gt;
</pre> <pre class="fragment">becomes
</pre> <pre class="fragment">                    FROM                    TO
M-text: |&lt;------------|-------- MT ---------|------------&gt;|
PROP  :  &lt;--OLD_VAL--&gt;|                     |&lt;--OLD_VAL--&gt;|
</pre> <pre class="fragment">@par Return value:
If the operation was successful, mtext_pop_prop() return 0.
Otherwise it returns -1 and assigns an error code to the external
variable #merror_code.   

@par Errors:
@c MERROR_RANGE, @c MERROR_SYMBOL

@par See Also:
mtext_put_prop(), mtext_put_prop_values(),
mtext_get_prop(), mtext_get_prop_values(),
mtext_push_prop(), mtext_prop_range()   
</pre> 
</div>
</div>
<a id="gae023984f61bfb4198f9ac70350bdb8d4"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gae023984f61bfb4198f9ac70350bdb8d4">&#9670;&nbsp;</a></span>mtext_prop_range()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int mtext_prop_range </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structMText.html">MText</a> *&#160;</td>
          <td class="paramname"><em>mt</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">MSymbol&#160;</td>
          <td class="paramname"><em>key</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>pos</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int *&#160;</td>
          <td class="paramname"><em>from</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int *&#160;</td>
          <td class="paramname"><em>to</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>deeper</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Find the range where the value of a text property is the same. </p>
<p>The <a class="el" href="group__m17nTextProperty.html#gae023984f61bfb4198f9ac70350bdb8d4" title="Find the range where the value of a text property is the same.">mtext_prop_range()</a> function investigates the extent where all characters have the same value for a text property. It first finds the value of the property specified by <b>key</b> of the character at <b>pos</b> in M-text <b>mt</b>. Then it checks if adjacent characters have the same value for the property <b>key</b>. The beginning and the end of the found range are stored to the variable pointed to by <b>from</b> and <b>to</b>. The character position stored in <b>from</b> is inclusive but that in <b>to</b> is exclusive; this fashion is compatible with the range specification in the <a class="el" href="group__m17nTextProperty.html#ga0ebfee8b550cc5ccaefd6f091fc5695f">mtext_put_prop()</a> function, etc.</p>
<p>If <b>deeper</b> is not 0, not only the topmost but also all the stacked properties whose key is <b>key</b> are compared.</p>
<p>If <b>from</b> is <code>NULL</code>, the beginning of range is not searched for. If <b>to</b> is <code>NULL</code>, the end of range is not searched for.</p>
<dl class="section user"><dt>Return value:</dt><dd></dd></dl>
<p>If the operation was successful, <a class="el" href="group__m17nTextProperty.html#gae023984f61bfb4198f9ac70350bdb8d4" title="Find the range where the value of a text property is the same.">mtext_prop_range()</a> returns the number of values the property <b>key</b> has at pos. Otherwise it returns -1 and assigns an error code to the external variable <code>merror_code</code>. <br  />
</p>
<dl class="section user"><dt>Errors:</dt><dd><code>MERROR_RANGE</code>, <code>MERROR_SYMBOL</code> </dd></dl>
<dl class="section user"><dt>See Also:</dt><dd><a class="el" href="group__m17nTextProperty.html#ga0ebfee8b550cc5ccaefd6f091fc5695f">mtext_put_prop()</a>, <a class="el" href="group__m17nTextProperty.html#gaa027998420efcfa94b5e91140ea08787" title="Set multiple text properties with the same key.">mtext_put_prop_values()</a>, <a class="el" href="group__m17nTextProperty.html#ga3b37b8a451e0618b8393402a88123a5c" title="Get the value of the topmost text property.">mtext_get_prop()</a>, <a class="el" href="group__m17nTextProperty.html#ga7649d0794df9829ece537861eaff87cf" title="Get multiple values of a text property.">mtext_get_prop_values()</a>, <a class="el" href="group__m17nTextProperty.html#gaa63265ad53bc7fddf62631fa8f3fb0d5">mtext_pop_prop()</a>, <a class="el" href="group__m17nTextProperty.html#ga1525f066294eb2645b5c2e41b68e0a65">mtext_push_prop()</a> <br  />
 </dd></dl>

</div>
</div>
<a id="gad94bf3a0a1384c2a7b5a759c7a93b88b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gad94bf3a0a1384c2a7b5a759c7a93b88b">&#9670;&nbsp;</a></span>mtext_property()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="structMTextProperty.html">MTextProperty</a>* mtext_property </td>
          <td>(</td>
          <td class="paramtype">MSymbol&#160;</td>
          <td class="paramname"><em>key</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void *&#160;</td>
          <td class="paramname"><em>val</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>control_bits</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Create a text property. </p>
<p>The <a class="el" href="group__m17nTextProperty.html#gad94bf3a0a1384c2a7b5a759c7a93b88b" title="Create a text property.">mtext_property()</a> function returns a newly allocated text property whose key is <b>key</b> and value is <b>val</b>. The created text property is not attached to any M-text, i.e. it is detached.</p>
<p><b>control_bits</b> must be 0 or logical OR of <code>enum</code> <code>MTextPropertyControl</code>. <br  />
 </p>

</div>
</div>
<a id="ga0c227387edfda07824c6822e9e27435a"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga0c227387edfda07824c6822e9e27435a">&#9670;&nbsp;</a></span>mtext_property_mtext()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="structMText.html">MText</a>* mtext_property_mtext </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structMTextProperty.html">MTextProperty</a> *&#160;</td>
          <td class="paramname"><em>prop</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Return the M-text of a text property. </p>
<p>The <a class="el" href="group__m17nTextProperty.html#ga0c227387edfda07824c6822e9e27435a" title="Return the M-text of a text property.">mtext_property_mtext()</a> function returns the M-text to which text property <b>prop</b> is attached. If <b>prop</b> is currently detached, NULL is returned. <br  />
 </p>

</div>
</div>
<a id="ga1faaffce04424f85f5a78461ad9bfaec"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga1faaffce04424f85f5a78461ad9bfaec">&#9670;&nbsp;</a></span>mtext_property_key()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">MSymbol mtext_property_key </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structMTextProperty.html">MTextProperty</a> *&#160;</td>
          <td class="paramname"><em>prop</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Return the key of a text property. </p>
<p>The <a class="el" href="group__m17nTextProperty.html#ga1faaffce04424f85f5a78461ad9bfaec" title="Return the key of a text property.">mtext_property_key()</a> function returns the key (symbol) of text property <b>prop</b>. <br  />
 </p>

</div>
</div>
<a id="ga5d3bbf3edab14ee3d26be9158b41bb31"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga5d3bbf3edab14ee3d26be9158b41bb31">&#9670;&nbsp;</a></span>mtext_property_value()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void* mtext_property_value </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structMTextProperty.html">MTextProperty</a> *&#160;</td>
          <td class="paramname"><em>prop</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Return the value of a text property. </p>
<p>The <a class="el" href="group__m17nTextProperty.html#ga5d3bbf3edab14ee3d26be9158b41bb31" title="Return the value of a text property.">mtext_property_value()</a> function returns the value of text property <b>prop</b>. <br  />
 </p>

</div>
</div>
<a id="gac03079958c4de03ebc72766cf27bca25"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gac03079958c4de03ebc72766cf27bca25">&#9670;&nbsp;</a></span>mtext_property_start()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int mtext_property_start </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structMTextProperty.html">MTextProperty</a> *&#160;</td>
          <td class="paramname"><em>prop</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Return the start position of a text property. </p>
<p>The <a class="el" href="group__m17nTextProperty.html#gac03079958c4de03ebc72766cf27bca25" title="Return the start position of a text property.">mtext_property_start()</a> function returns the start position of text property <b>prop</b>. The start position is a character position of an M-text where <b>prop</b> begins. If <b>prop</b> is detached, it returns -1. <br  />
 </p>

</div>
</div>
<a id="ga550abffc59e78bfa137e44469af2f102"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga550abffc59e78bfa137e44469af2f102">&#9670;&nbsp;</a></span>mtext_property_end()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int mtext_property_end </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structMTextProperty.html">MTextProperty</a> *&#160;</td>
          <td class="paramname"><em>prop</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Return the end position of a text property. </p>
<p>The <a class="el" href="group__m17nTextProperty.html#ga550abffc59e78bfa137e44469af2f102" title="Return the end position of a text property.">mtext_property_end()</a> function returns the end position of text property <b>prop</b>. The end position is a character position of an M-text where <b>prop</b> ends. If <b>prop</b> is detached, it returns -1. <br  />
 </p>

</div>
</div>
<a id="ga857bf31decfcc6063f33183373901c3e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga857bf31decfcc6063f33183373901c3e">&#9670;&nbsp;</a></span>mtext_get_property()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="structMTextProperty.html">MTextProperty</a>* mtext_get_property </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structMText.html">MText</a> *&#160;</td>
          <td class="paramname"><em>mt</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>pos</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">MSymbol&#160;</td>
          <td class="paramname"><em>key</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Get the topmost text property. </p>
<p>The <a class="el" href="group__m17nTextProperty.html#ga857bf31decfcc6063f33183373901c3e" title="Get the topmost text property.">mtext_get_property()</a> function searches the character at position <b>pos</b> in M-text <b>mt</b> for a text property whose key is <b>key</b>.</p>
<dl class="section user"><dt>Return value:</dt><dd>If a text property is found, <a class="el" href="group__m17nTextProperty.html#ga857bf31decfcc6063f33183373901c3e" title="Get the topmost text property.">mtext_get_property()</a> returns it. If there are multiple text properties, it returns the topmost one. If no such property is found, it returns <code>NULL</code> without changing the external variable <a class="el" href="group__m17nError.html#ga995a2e373cfd6a8e5eaca8686b5b0a73" title="External variable to hold error code of the m17n library.">merror_code</a>.</dd></dl>
<p>If an error is detected, <a class="el" href="group__m17nTextProperty.html#ga857bf31decfcc6063f33183373901c3e" title="Get the topmost text property.">mtext_get_property()</a> returns <code>NULL</code> and assigns an error code to the external variable <a class="el" href="group__m17nError.html#ga995a2e373cfd6a8e5eaca8686b5b0a73" title="External variable to hold error code of the m17n library.">merror_code</a>. <br  />
 </p>

</div>
</div>
<a id="gaa08e0d0924274c37f28fca9afb0d7d58"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gaa08e0d0924274c37f28fca9afb0d7d58">&#9670;&nbsp;</a></span>mtext_get_properties()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int mtext_get_properties </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structMText.html">MText</a> *&#160;</td>
          <td class="paramname"><em>mt</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>pos</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">MSymbol&#160;</td>
          <td class="paramname"><em>key</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structMTextProperty.html">MTextProperty</a> **&#160;</td>
          <td class="paramname"><em>props</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>num</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Get multiple text properties. </p>
<p>The <a class="el" href="group__m17nTextProperty.html#gaa08e0d0924274c37f28fca9afb0d7d58" title="Get multiple text properties.">mtext_get_properties()</a> function searches the character at <b>pos</b> in M-text <b>mt</b> for properties whose key is <b>key</b>. If such properties are found, they are stored in the memory area pointed to by <b>props</b>. <b>num</b> limits the maximum number of stored properties.</p>
<dl class="section user"><dt>Return value:</dt><dd>If the operation was successful, <a class="el" href="group__m17nTextProperty.html#gaa08e0d0924274c37f28fca9afb0d7d58" title="Get multiple text properties.">mtext_get_properties()</a> returns the number of actually stored properties. If the character at <b>pos</b> does not have a property whose key is <b>key</b>, the return value is 0. If an error is detected, <a class="el" href="group__m17nTextProperty.html#gaa08e0d0924274c37f28fca9afb0d7d58" title="Get multiple text properties.">mtext_get_properties()</a> returns -1 and assigns an error code to the external variable <a class="el" href="group__m17nError.html#ga995a2e373cfd6a8e5eaca8686b5b0a73" title="External variable to hold error code of the m17n library.">merror_code</a>. <br  />
 </dd></dl>

</div>
</div>
<a id="ga80333ace7a285d5a09ed0575cda75d84"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga80333ace7a285d5a09ed0575cda75d84">&#9670;&nbsp;</a></span>mtext_attach_property()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int mtext_attach_property </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structMText.html">MText</a> *&#160;</td>
          <td class="paramname"><em>mt</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>from</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>to</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structMTextProperty.html">MTextProperty</a> *&#160;</td>
          <td class="paramname"><em>prop</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Attach a text property to an M-text. </p>
<p>The <a class="el" href="group__m17nTextProperty.html#ga80333ace7a285d5a09ed0575cda75d84" title="Attach a text property to an M-text.">mtext_attach_property()</a> function attaches text property <b>prop</b> to the range between <b>from</b> and <b>to</b> in M-text <b>mt</b>. If <b>prop</b> is already attached to an M-text, it is detached before attached to <b>mt</b>.</p>
<dl class="section user"><dt>Return value:</dt><dd>If the operation was successful, <a class="el" href="group__m17nTextProperty.html#ga80333ace7a285d5a09ed0575cda75d84" title="Attach a text property to an M-text.">mtext_attach_property()</a> returns 0. Otherwise it returns -1 and assigns an error code to the external variable <a class="el" href="group__m17nError.html#ga995a2e373cfd6a8e5eaca8686b5b0a73" title="External variable to hold error code of the m17n library.">merror_code</a>. <br  />
 </dd></dl>

</div>
</div>
<a id="ga6e4c9702d75cde94c6bfc9f44ea13258"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga6e4c9702d75cde94c6bfc9f44ea13258">&#9670;&nbsp;</a></span>mtext_detach_property()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int mtext_detach_property </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structMTextProperty.html">MTextProperty</a> *&#160;</td>
          <td class="paramname"><em>prop</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Detach a text property from an M-text. </p>
<p>The <a class="el" href="group__m17nTextProperty.html#ga6e4c9702d75cde94c6bfc9f44ea13258" title="Detach a text property from an M-text.">mtext_detach_property()</a> function makes text property <b>prop</b> detached.</p>
<dl class="section user"><dt>Return value:</dt><dd>This function always returns 0. <br  />
 </dd></dl>

</div>
</div>
<a id="ga1db069da9e058d3129a6469f4d359c0f"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga1db069da9e058d3129a6469f4d359c0f">&#9670;&nbsp;</a></span>mtext_push_property()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int mtext_push_property </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structMText.html">MText</a> *&#160;</td>
          <td class="paramname"><em>mt</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>from</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>to</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structMTextProperty.html">MTextProperty</a> *&#160;</td>
          <td class="paramname"><em>prop</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Push a text property onto an M-text. </p>
<p>The <a class="el" href="group__m17nTextProperty.html#ga1db069da9e058d3129a6469f4d359c0f" title="Push a text property onto an M-text.">mtext_push_property()</a> function pushes text property <b>prop</b> to the characters between <b>from</b> (inclusive) and <b>to</b> (exclusive) in M-text <b>mt</b>.</p>
<dl class="section user"><dt>Return value:</dt><dd>If the operation was successful, <a class="el" href="group__m17nTextProperty.html#ga1db069da9e058d3129a6469f4d359c0f" title="Push a text property onto an M-text.">mtext_push_property()</a> returns 0. Otherwise it returns -1 and assigns an error code to the external variable <a class="el" href="group__m17nError.html#ga995a2e373cfd6a8e5eaca8686b5b0a73" title="External variable to hold error code of the m17n library.">merror_code</a>. <br  />
 </dd></dl>

</div>
</div>
<a id="ga4830a8a120aeed2185d6da8fd2daa05e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga4830a8a120aeed2185d6da8fd2daa05e">&#9670;&nbsp;</a></span>mtext_serialize()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="structMText.html">MText</a>* mtext_serialize </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structMText.html">MText</a> *&#160;</td>
          <td class="paramname"><em>mt</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>from</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>to</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structMPlist.html">MPlist</a> *&#160;</td>
          <td class="paramname"><em>property_list</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<pre class="fragment">@brief Serialize text properties in an M-text.

The mtext_serialize() function serializes the text between @b from
and @b to in M-text @b mt.  The serialized result is an M-text in a
form of XML.  @b property_list limits the text properties to be
serialized. Only those text properties whose key 

@li appears as the value of an element in @b property_list, and
@li has the symbol property #Mtext_prop_serializer

are serialized as a "property" element in the resulting XML
representation.

The DTD of the generated XML is as follows:
</pre> <pre class="fragment">&lt;!DOCTYPE mtext [
  &lt;!ELEMENT mtext (property*,body+)&gt;
  &lt;!ELEMENT property EMPTY&gt;
  &lt;!ELEMENT body (#PCDATA)&gt;
  &lt;!ATTLIST property key CDATA #REQUIRED&gt;
  &lt;!ATTLIST property value CDATA #REQUIRED&gt;
  &lt;!ATTLIST property from CDATA #REQUIRED&gt;
  &lt;!ATTLIST property to CDATA #REQUIRED&gt;
  &lt;!ATTLIST property control CDATA #REQUIRED&gt;
 ]&gt;
</pre> <pre class="fragment">This function depends on the libxml2 library.  If the m17n library
is configured without libxml2, this function always fails.

@par Return value:
If the operation was successful, mtext_serialize() returns an
M-text in the form of XML.  Otherwise it returns @c NULL and assigns an
error code to the external variable #merror_code.

@par See Also:
mtext_deserialize(), #Mtext_prop_serializer   
</pre> 
</div>
</div>
<a id="ga82e022961a26f82ddf580782a50d94bf"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga82e022961a26f82ddf580782a50d94bf">&#9670;&nbsp;</a></span>mtext_deserialize()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="structMText.html">MText</a>* mtext_deserialize </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structMText.html">MText</a> *&#160;</td>
          <td class="paramname"><em>mt</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">
<pre class="fragment">@brief Deserialize text properties in an M-text.

The mtext_deserialize() function deserializes M-text @b mt.  @b mt
must be an XML having the following DTD.
</pre> <pre class="fragment">&lt;!DOCTYPE mtext [
  &lt;!ELEMENT mtext (property*,body+)&gt;
  &lt;!ELEMENT property EMPTY&gt;
  &lt;!ELEMENT body (#PCDATA)&gt;
  &lt;!ATTLIST property key CDATA #REQUIRED&gt;
  &lt;!ATTLIST property value CDATA #REQUIRED&gt;
  &lt;!ATTLIST property from CDATA #REQUIRED&gt;
  &lt;!ATTLIST property to CDATA #REQUIRED&gt;
  &lt;!ATTLIST property control CDATA #REQUIRED&gt;
 ]&gt;
</pre> <pre class="fragment">This function depends on the libxml2 library.  If the m17n library
is configured without libxml2, this function always fail.

@par Return value:
If the operation was successful, mtext_deserialize() returns the
resulting M-text.  Otherwise it returns @c NULL and assigns an error
code to the external variable #merror_code.

@par See Also:
mtext_serialize(), #Mtext_prop_deserializer   
</pre> 
</div>
</div>
<h2 class="groupheader">Variable Documentation</h2>
<a id="ga759ba1a6ac36d9847bc6b4d431ae3735"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga759ba1a6ac36d9847bc6b4d431ae3735">&#9670;&nbsp;</a></span>Mtext_prop_serializer</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">MSymbol Mtext_prop_serializer</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Symbol for specifying serializer functions. </p>
<p>To serialize a text property, the user must supply a serializer function for that text property. This is done by giving a symbol property whose key is <a class="el" href="group__m17nTextProperty.html#ga759ba1a6ac36d9847bc6b4d431ae3735" title="Symbol for specifying serializer functions.">Mtext_prop_serializer</a> and value is a pointer to an appropriate serializer function.</p>
<dl class="section user"><dt>See Also:</dt><dd><a class="el" href="group__m17nTextProperty.html#ga4830a8a120aeed2185d6da8fd2daa05e">mtext_serialize()</a>, <a class="el" href="group__m17nTextProperty.html#gaff9cca52bfb7587ce765ac50d16f665b" title="Type of serializer functions.">MTextPropSerializeFunc</a> </dd></dl>

</div>
</div>
<a id="ga97f4c75b4ebf8ff252948dbf068bc077"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga97f4c75b4ebf8ff252948dbf068bc077">&#9670;&nbsp;</a></span>Mtext_prop_deserializer</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">MSymbol Mtext_prop_deserializer</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Symbol for specifying deserializer functions. </p>
<p>To deserialize a text property, the user must supply a deserializer function for that text property. This is done by giving a symbol property whose key is <a class="el" href="group__m17nTextProperty.html#ga97f4c75b4ebf8ff252948dbf068bc077" title="Symbol for specifying deserializer functions.">Mtext_prop_deserializer</a> and value is a pointer to an appropriate deserializer function.</p>
<dl class="section user"><dt>See Also:</dt><dd><a class="el" href="group__m17nTextProperty.html#ga82e022961a26f82ddf580782a50d94bf">mtext_deserialize()</a>, <a class="el" href="group__m17nTextProperty.html#gaff9cca52bfb7587ce765ac50d16f665b" title="Type of serializer functions.">MTextPropSerializeFunc</a> </dd></dl>

</div>
</div>
</div><!-- contents -->
<hr>
<ADDRESS>
<a href="http://www.m17n.org/m17n-lib-en/index.html" target="mulewindow"><img src="parrot.png" align=bottom alt="m17n-lib Home" border=0></a>
</ADDRESS>
</body>
</HTML>
<!-- Copyright information
Copyright (C) 2001 Information-technology Promotion Agency (IPA)
Copyright (C) 2001-2011
  National Institute of Advanced Industrial Science and Technology (AIST)
This file is part of the m17n library documentation.
Permission is granted to copy, distribute and/or modify this document
under the terms of the GNU Free Documentation License, Version 1.2 or
any later version published by the Free Software Foundation; with no
Invariant Section, no Front-Cover Texts,
and no Back-Cover Texts.  A copy of the license is included in the
appendix entitled "GNU Free Documentation License".
-->