*** empty log message ***
[m17n/m17n-lib.git] / src / ChangeLog
1 2008-01-31  Kenichi Handa  <handa@ni.aist.go.jp>
2
3         * Version 1.5.1 released.
4
5 2008-01-31  Kenichi Handa  <handa@ni.aist.go.jp>
6
7         * draw.c (mdraw_glyph_list): Refer to mfont__ft_driver only when
8         HAVE_FREETYPE is defined.
9
10         * font.h (OTF_Tag): Be sure that it is defined in any cases.
11
12 2008-01-30  Kenichi Handa  <handa@ni.aist.go.jp>
13
14         * font.h (enum MFontOpenTypeTable, MFontCapability): Define them
15         unconditionally.
16
17 2008-01-25  Kenichi Handa  <handa@ni.aist.go.jp>
18
19         * input.c (parse_action_list): Handle the case "(insert INTEGER)".
20
21 2008-01-25  Kenichi Handa  <handa@ni.aist.go.jp>
22
23         * input.c (parse_action_list): Check M_candidates.
24         (get_im_info): If key is Mnil, be sure to set im_info->states to a
25         plist.
26
27 2008-01-23  Kenichi Handa  <handa@ni.aist.go.jp>
28
29         * input.c (integer_value): Fix interpretation of "@-N".
30
31 2008-01-17  Kenichi Handa  <handa@ni.aist.go.jp>
32
33         * input.c (get_following_char): Fix interpretation of POS.
34         (get_following_char): Fix interpretation of "@+N".
35
36 2008-01-15  Kenichi Handa  <handa@ni.aist.go.jp>
37
38         * font-ft.c (ft_drive_otf): Don't refer to otf_gstring if HAVE_OTF
39         is not defined.
40
41         * Makefile.am (FLT_SOURCES): Include internal-flt.h.
42
43 2008-01-07  Kenichi Handa  <handa@ni.aist.go.jp>
44
45         * m17n-flt.c (UPDATE_CLUSTER_RANGE): Don't check if clustering
46         now.
47         (run_rule): Call UPDATE_CLUSTER_RANGE when necessary.
48         (run_command): Check if clustering now before calling
49         UPDATE_CLUSTER_RANGE.
50
51 2008-01-06  Kenichi Handa  <handa@m17n.org>
52
53         * font.c (mfont__get_glyph_id): Return -1 if some code is invalid.
54
55         * font-ft.c (ft_drive_otf): Fix checking of negative feature.
56
57         * m17n-X.c (xft_find_metric): Set g->g.measured.
58
59         * m17n-flt.c (Mequal): New variable.
60         (m17n_init_flt): Initialize it.
61         (FontLayoutCmdRule): Merge members supported_glyph and otf_spec
62         into a new member facility.
63         (load_command): Modify parsing of Mfont_facility.
64         (run_rule): Adjuted for the change of FontLayoutCmdRule.
65         (run_otf): Adjusted metrics if a->back is nonzero.
66
67 2007-12-28  Kenichi Handa  <handa@ni.aist.go.jp>
68
69         * Version 1.5.0 released.
70
71 2007-12-13  Kenichi Handa  <handa@ni.aist.go.jp>
72
73         * m17n-core.c (m17n_init_core): Handle the lang. env. MDEBUG_FLT.
74
75         * m17n-flt.c (mdebug_flag): Set to MDEBUG_FLT.
76         (run_rule): Check if a font has the specific glyph correctly.
77
78         * internal.h (enum MDebugFlag): Delete MDEBUG_FONT_OTF, change
79         MDEBUG_FONT_FLT to MDEBUG_FLT.
80
81         * font.c (mfont__get_glyph_id): Encode g->g.code (not g->g.c).
82
83         * font-flt.c: Delete it.
84
85 2007-12-08  Kenichi Handa  <handa@ni.aist.go.jp>
86
87         * m17n-flt.c (run_rule): Fix printing of debug info.  Don't update
88         TO for the rule of SRC_HAS_GLYPH.
89
90         * draw.c (run_flt): Argument changed.
91         (compose_glyph_string): Adjusted for the above change.
92
93 2007-12-07  Kenichi Handa  <handa@ni.aist.go.jp>
94
95         * plist.c (read_mtext_element): Don't free the malloced buffer.
96
97 2007-12-04  Kenichi Handa  <handa@ni.aist.go.jp>
98
99         * m17n-core.h (merror_code): Extern it.
100
101         * m17n-misc.h (merror_code): Don't extern it.
102
103         * m17n.h: Handle the case of _M17N_FLT_H_ being defined.
104
105         * m17n-flt.h: Handle the case of _M17N_H_ being defined.
106
107 2007-11-22  Kenichi Handa  <handa@ni.aist.go.jp>
108
109         * draw.c (compose_glyph_string): Check g->rface->layouter, not
110         g->rface->rfont->layouter.
111
112         * font-ft.c (ft_drive_otf): Fix setting of g->g.from and g->g.to.
113
114         * m17n-flt.c (FontLayoutContext): New member encoded_offset.
115         (run_rule): Use ctx->encoded_offset.
116         (run_command): Likewise.
117         (run_stages): Set ctx->encoded_offset.
118
119 2007-11-21  Kenichi Handa  <handa@ni.aist.go.jp>
120
121         * m17n-flt.c (enum GlyphInfoMask): Adjusted for the change of
122         bit-size of MFLTGlyph->internal.
123
124 2007-11-20  Kenichi Handa  <handa@ni.aist.go.jp>
125
126         * draw.c (visual_order): Exclude the last anchor glyph from the
127         iteration.
128
129         * m17n-flt.h (MFLTGlyph): New member <adjusted>.
130
131         * m17n-flt.c (run_otf): Set adjusted flag of glyphs if necessary.
132         (run_stages): Likewise.
133         (load_flt): Unref top after checking plist.
134
135         * m17n-X.c (xft_render): Check adjusted flag of glyphs.
136
137 2007-11-12  Kenichi Handa  <handa@ni.aist.go.jp>
138
139         * font-ft.c (ft_check_otf): Fix arg to OTF_check_features.
140
141         * m17n-flt.c (Mcombining): New variable.
142         (Mfont_facility): Renamed from Mfont_has.  Referrer changed.
143         (enum FontLayoutCmdRuleSrcType): Delete SRC_EXIST, add
144         SRC_HAS_GLYPH and SRC_OTF_SPEC.
145         (FontLayoutCmdRule): Delete src.exist, add src.supported_glyph and
146         src.otf_spec.
147         (load_command): Adjusted for the above changes.
148         (run_rule): Likewise.
149         (combining_code_from_class): Delete it.
150         (mflt_get): Check flt->name against Mcombining, not Mt.
151
152         * internal-flt.h (Mcombining): Extern it.
153
154         * draw.c (compose_glyph_string): Call run_flt with Mcombining for
155         combining characters.
156
157 2007-11-09  Kenichi Handa  <handa@ni.aist.go.jp>
158
159         * face.c (mface__realize): Reset measured flag before calling
160         mfont__get_metric.
161
162         * m17n-flt.c (run_stages): Fix handing of off_x and off_y.
163         (setup_combining_coverage): New function.
164         (setup_combining_flt): New function.
165         (mflt_get): If flt is not found, return NULL.  If name if Mt,
166         call setup_combining_flt.
167         (mflt_run): For debugging, print font family name.
168
169         * font-ft.c (ft_render): Fix handling of baseline_offset.
170         (ft_encapsulate): Set metrics in 26.6 fixed pixel.
171         (ft_render): Check pixel_mode to determine anti_alias.
172
173         * m17n-X.c (xfont_find_metric): Delete invalid "continue" line.
174         (xfont_find_metric): Set metrics in 26.6 fixed pixel.
175         (xfont_render): Set baseline_offset in pixel.
176         (xft_render): Fix handling of baseline_offset.
177
178         * draw.c (run_flt): Set font.font.family.
179         (compose_glyph_string): Fix handling of combining characters.
180
181         * fontset.c (try_font_list): Check if the named flt is surely
182         available.
183
184 2007-11-07  Kenichi Handa  <handa@ni.aist.go.jp>
185
186         * draw.c (analyse_bidi_level): New function.
187         (visual_order): Do reordering using the already decided
188         bidi-level.
189         (compose_glyph_string): Decide bidi-level before calling flt.
190
191         * m17n-flt.c (mflt_run): Fix typo.
192
193         * font-ft.c (ft_drive_otf): Fix indexing gstring->glyphs.
194
195 2007-11-06  Kenichi Handa  <handa@ni.aist.go.jp>
196
197         * draw.c (visual_order): Don't rely on the width of glyphs.
198         (run_flt): Fix culculation of g->g.to.
199
200         * m17n-flt.c (run_rule): Don't set error code here.
201         (run_cond): Likewise.
202         (run_otf): Fix culculation of xoff and yoff.
203         (run_command): Don't set error code here.
204         (PREV): New macro.
205         (NEXT): New macro.
206
207         * m17n-X.c (xfont_open): Keep rfont's metrics in 26.6 fixed pixels.
208         (xfont_find_metric): Set glyph's yadv to 0.
209         (xft_find_metric): Likewise.
210
211         * font-ft.c (ft_open): Keep rfont's metrics in 26.6 fixed pixels.
212         (ft_find_metric): Adjust glyph's metrics.
213         (ft_encapsulate): Keep rfont's metrics in 26.6 fixed pixels.
214         (ft_drive_otf): Set mark glyph's xadv to 0.
215
216         * face.c (mface__for_chars): Adjusts the unit of face's ascent and
217         descent.
218
219 2007-10-29  Kenichi Handa  <handa@m17n.org>
220
221         * m17n-flt.h (struct _MFLTOtfSpec): Adjusted for the new FLT handling.
222         (mflt_get): Adjusted for the argument change.
223         (mflt_name): Adjusted for the return value change.
224
225         * m17n-flt.c (Mgenerator, Mend): New variables.
226         (flt_min_coverage, flt_max_coverage): New variables.
227         (GCPY): New macro.
228         (GDUP): Use it.
229         (Mfont_has): Renamed from Mexist.  Referrers chagned.
230         (gen_otf_tag): Handle the trailing whitespaces.
231         (otf_count_features, otf_store_features): Fix for negative features.
232         (parse_otf_command): Adjusted for the change of MFLTOtfSpec.
233         (load_otf_command): Likewise.
234         (free_flt_command): Adjusted for the change of MFLTOtfSpec.
235         (load_flt): Argument changed.  Caller changed.
236         (free_flt_list): New function.
237         (run_rule): Adjusted for the change of FontLayoutContext.
238         (mflt_run): Adjusted for the change of FontLayoutContext.
239
240         * m17n-gui.c (m17n_init_win): Call m17n_init_flt.
241         (m17n_fini_win): Call m17n_fini_flt.
242
243         * m17n-gui.h: Include m17n-flt.h.
244
245         * m17n-gd.c: Adusted for the change of MGlyph.
246
247         * m17n-X.c: Adusted for the change of MGlyph.
248         (xft_check_otf, xft_drive_otf): New functions.
249
250         * internal-gui.h (MGlyph): Modified for new FLT handling.
251
252         * fontset.c (try_font_list): Adusted for the change of MGlyph.
253
254         * font-ft.c: Adjusted for the change of MGlyph.
255         (ft_check_cap_otf): Renamed from ft_check_otf.  Callers changed.
256         (get_glyph_metric): Deleted.
257         (ft_check_otf): New function.
258         (ft_drive_otf): New fucntion.
259
260         * font.c: Adjusted for the change of MGlyph.
261         (mfont__init): Don't call mfont__flt_init.
262         (mfont__fini): Don't call mfont__flt_fini.
263         (mfont__get_glyph_id, mfont__get_metrics): New functions.
264
265         * font.h (struct MRealizedFont): New members x_ppem and y_ppem.
266         (MFLTFontForRealized): New struct.
267         (struct MFontDriver): New members check_otf and drive_otf.
268         (mfont__get_glyph_id, mfont__get_metrics): Extern them.
269
270         * face.c: Adjusted for the change of MGlyph.
271
272         * draw.c: Adjusted for the change of MGlyph.
273
274         * m17n.c (m17n_init): Don't call mchar_init.
275
276         * m17n-core.c (m17n_init_core): Call mchar_init.
277
278         * m17n-core.h (mchartable_min_char, mchartable_max_char): Extern them.
279
280         * input.c: Include "m17n.h" instead of "m17n-gui.h".
281
282         * chartab.c (mchartable): Initialize table->min_char to -1.
283         (mchartable_min_char): New function.
284         (mchartable_max_char): New function.
285
286         * Makefile.am (GUI_SOURCES): Delete font-flt.c.
287         (libm17n_gui_la_LIBADD): Add ${top_builddir}/src/libm17n-flt.la.
288
289 2007-10-12  Kenichi Handa  <handa@m17n.org>
290
291         * m17n-core.h (Mcharset): Extern it.
292         Move detabase related declarations from m17n.h.
293
294         * m17n-flt.h: Include m17n-core.h instead of m17n.h.
295         (struct _MFLTOtfFeatures): New struct.
296         (struct _MFLTOtfSpec): Delete gsub, gpos, etc, add gsub_gpos.
297         (struct _MFLTFont): Delete otf, add check_otf.
298         (MCHAR_INVALID_CODE): Define it.
299
300         * plist.c (read_mtext_element): Simplify the code.
301
302         * m17n.h: Move database related declarations to m17n-core.h
303         (Mharset): Don't extern it.
304
305         * m17n.c (m17n_init): Don't call mdatabase__init.
306
307         * m17n-gd.c (read_rgb_txt): Check also /etc/X11/rgb.txt.  Downcase
308         color names.
309
310         * m17n-flt.c: Include m17n-core.h instead of m17n.h.
311         (Mexist): New variable.
312         (enum FontLayoutCmdRuleSrcType): New enum SRC_EXIST.
313         (FontLayoutCmdRule): New member src.exist.
314         (parse_otf_command): Handle gsub_count and gpos_count separately.
315         (load_otf_command): Adjusted for the change of MFLTOtfSpec.
316         (load_command): Handle the command "exist".
317         (free_flt_command): Adjusted for the change of MFLTOtfSpec.
318         (run_rule): Handle the case SRC_EXIST.
319         (run_otf): Adjusted for the change of MFLTOtfSpec.
320         (run_command): Check the range of FROM.
321         (check_otf_spec): Delete it.
322         (m17n_init_flt): Call m17n_init_core instead of m17n_init.
323         Initialize Mexist.
324         (m17n_fini_flt): Call m17n_fini_core instead of m17n_fiini.
325         (mflt_find): Call font->check_otf instead of check_otf_spec.
326         (mflt_run): Keep the metrics in 26.6 fixed point.
327
328         * m17n-core.c (mdatabase__finder, mdatabase__loader): Delete them.
329         (m17n_init_core): Call mdatabase__init.
330
331         * m17n-X.c (device_open): Use mplist_add, not mplist_push.
332
333         * internal.h (mdatabase__finder, mdatabase__loader): Delete externs
334         of them.
335
336         * font-flt.c (Mexist): New variable.
337         (enum FontLayoutCmdRuleSrcType): New enum SRC_EXIST.
338         (FontLayoutCmdRule): New member src.exist.
339         (load_category_table): Use isalnum, not isalpha.
340         (load_command): Check the command "exist".
341         (run_rule): Hande the case SRC_EXIST.
342         (run_command): Check the range of FROM.
343         (mfont__flt_init): Initialize Mexist.
344
345         * draw.c (layout_glyphs): Fix calculation of off_x and off_y.
346
347         * database.h (mdatabase__load_charset_func): Extern it.
348
349         * database.c: Include m17n-core.h instead of m17n.h.
350         (load_chartable): Use mtext__from_data.
351         (load_charset): Moved to charset.c
352         (load_database): Call mdatabase__load_charset_func instead of
353         load_charset.
354         (mdatabase__load_charset_func): New variable.
355         (mdatabase__init): Initialize mdatabase__load_charset_func and
356         Mcharset.  Don't set mdatabase__finder and mdatabase__loader.
357         (mdatabase__save): Use fwrite, not mconv_encode_stream.
358         (Mcharset): Declare it here.
359
360         * charset.c: Include "database.h.".
361         (load_charset): Moved from database.c.
362         (mcharset__init): Initialize mdatabase__load_charset_func, don't
363         initialize Mcharset.
364
365         * character.c (mchar_define_property): Call mdatabase_find directly.
366         (mchar_get_prop): Call mdatabase_add directly.
367         (mchar_put_prop): Call mdatabase_load directly.
368         (mchar_get_prop_table): Likewise.
369
370         * Makefile.am (libm17n_core_la_SOURCES): Add database.[ch].
371         (libm17n_la_SOURCES): Remove database.[ch].
372         (libm17n_flt_la_LIBADD): Delete libm17n.la, add libm17n-core.la.
373
374 2007-09-18  Kenichi Handa  <handa@m17n.org>
375
376         * face.c (mface__realize): Try Freetype based font at first.
377
378         * font.c: Include <ctype.h>
379
380 2007-09-16  Kenichi Handa  <handa@m17n.org>
381
382         * m17n-flt.c (load_flt): New arg full.  If full is zero, load only
383         coverage.
384         (run_otf): Call font->get_metrics, not font->get_metric.
385         (run_stages): Likewise.
386         (CHECK_FLT_COVERAGE): New macro.
387         (CHECK_FLT_STAGES): Call load_flt with the second arg 1.
388         (check_otf_spec): New function.
389         (m17n_fini_flt): Unref flt->coverage.
390         (mflt_find): Argument changed.
391         (mflt_name): New function.
392         (mflt_coverage): Use CHECK_FLT_COVERAGE.
393
394         * m17n-flt.h (MFLTFont): Member get_metrics renamed from get_metric.
395         (mflt_find): Prototype adjusted.
396         (mflt_name): Extern it.
397
398 2007-09-14  Kenichi Handa  <handa@m17n.org>
399
400         * m17n-flt.h (struct _MFLTGlyph): Change signedness of members.
401
402         * font-flt.c (run_otf): Make debug info printing comaptible with
403         that of m17n-flt.c.
404         (run_command): Likewise.
405         (mfont__flt_run): Likewise.
406
407         * m17n-flt.c (UPDATE_CLUSTER_RANGE): ctx->cluster_begin_idx is
408         invalid only when it's negative.
409         (run_otf): Likewise.
410         (run_command): Likewise.
411         (mflt_run): Initialize ctx.cluster_begin_idx to -1.
412
413 2007-09-10  Kenichi Handa  <handa@m17n.org>
414
415         * m17n-flt.h (struct _MFLTGlyph): New member encoded and measured.
416         (struct _MFLTFont): Prototype of get_glyph_id changed.
417
418         * m17n-flt.c (enum GlyphInfoMask): Delete EncodedMask and
419         PositionedMask.
420         (GAPPEND): Delete this macro.
421         (GET_ENCODED, SET_ENCODED, GET_MEASURED, SET_MEASURED): Adjusted
422         for the change of MFLTGlyph.  Caller changed.
423         (run_otf): Simply calls font->get_glyph_id.
424         (run_command): Reset g->encoded and g->measured for direct code.
425         (positioning): Delete this function.
426         (run_stages): Simply calls font->get_glyph_id and font->get_metric.
427
428 2007-09-07  Kenichi Handa  <handa@m17n.org>
429
430         * draw.c (compose_glyph_string): Improve script detection.
431
432 2007-09-06  Kenichi Handa  <handa@m17n.org>
433
434         * m17n-flt.h (mflt_get): Extern it.
435
436         * m17n-flt.c (run_stages): Call positioning only if
437         font->get_metric is non-NULL.
438         (CHECK_FLT_STAGES): Fix typo.
439         (mflt_get): New function.
440
441         * font-flt.c (mfont__flt_run): Improve debug info printing.
442
443 2007-09-04  Kenichi Handa  <handa@m17n.org>
444
445         * m17n-flt.c (MFontLayoutTable): Delete this type.
446         (struct _MFLT): New member mdb and coverage.
447         (list_flt): Set flt->mdb.
448         (load_generator): Argument and return value changed.  Caller
449         changed.
450         (get_font_layout_table): Delete this function.
451         (run_stages): Argument changed.  Caller changed.
452         (CHECK_FLT_STAGES): New macro.
453         (mfont__flt_encode_char): Argument changed.
454         (mflt_find): Likewise.
455         (mflt_coverage): New function.
456         (mflt_run): Argument changed.
457         (mdebug_dump_flt): Likewise.
458
459         * m17n-flt.h (mflt_coverage): Extern it.
460         (mflt_find): Prototype adjusted.
461
462 2007-09-03  Kenichi Handa  <handa@m17n.org>
463
464         * internal.h (MTABLE_CALLOC_SAFE, MSTRUCT_CALLOC_SAFE): New macros.
465
466         * database.c (mdatabase__props): New function.
467
468         * database.h (mdatabase__props): Extern it.
469
470         * m17n-flt.h (struct _MFLTGlyphString): Delete user_data, add
471         script and langsys.
472         (struct _MFLTFont): Add suitable_p.
473         (mflt_find): Extern it.
474
475         * m17n-flt.c: Include "database.h".
476         (struct _MFLT): New struct.
477         (list_flt): New function.
478         (load_flt): Don't update flt_list.
479         (get_font_layout_table): Use flt_list.
480         (m17n_init_flt): Don't initialize flt_list.
481         (m17n_fini_flt): Adjusted for the change of flt_list.
482         (mflt_find): New function.
483         (mflt_run): Fix debug printing.
484
485 2007-08-23  Kenichi Handa  <handa@m17n.org>
486
487         * m17n-flt.c (run_otf): Remove #ifdef HAVE_OTF and #endi.
488         (run_stages): Print separator in encoded string as "|".
489
490 2007-08-23  Kenichi Handa  <handa@m17n.org>
491
492         * font-flt.c (mfont__flt_run): Don't calculate a glyph metric if
493         the glyph is already handled by OTF.
494
495 2007-08-21  Kenichi Handa  <handa@m17n.org>
496
497         * font-ft.c (ft_check_capability): Check cap->script_tag at first.
498
499 2007-08-20  Kenichi Handa  <handa@m17n.org>
500
501         * font-flt.c (mfont__flt_run): Get glyph metrics before printing
502         debug information.
503
504 2007-08-17  Kenichi Handa  <handa@m17n.org>
505
506         * m17n-flt.h (struct _MFLTGlyphString): Member pointer renamed to
507         user_data.
508         (MFLTOtfSpec): Renamed from MFLT_OTF_Spec.
509         (MFLTFont): Prototype of the member drive_otf adjusted.
510
511         * m17n-flt.c (run_stages): Fix handling of padding.
512
513         * font-ft.c (get_glyph_metric): New function.
514         (DEVICE_DELTA): Return 26.6 fixed point value.
515         (adjust_anchor): Likewise.
516         (mfont__ft_drive_otf): Use get_glyph_metric.
517
518         * font-flt.c (mfont__flt_run): Pay attention to padding on
519         printing debug info.
520
521 2007-08-16  Kenichi Handa  <handa@m17n.org>
522
523         * m17n-flt.c (run_stages): Fix typo.
524
525         * font-ft.c (adjust_anchor): Argument changed.  Calculte based on
526         26.6 fixed point.
527         (mfont__ft_drive_otf): Don't call OTF_check_features for GPOS.
528         Adjusted for the argument change of adjust_anchor.  Calculte based
529         on 26.6 fixed point.
530
531 2007-08-15  Kenichi Handa  <handa@m17n.org>
532
533         * charset.c (mcharset__load_from_database): Set mdebug_flag
534         instead of mdebug_mask.
535
536         * coding.c (mcoding__load_from_database): Set mdebug_flag instead
537         of mdebug_mask.
538
539         * database.c (load_database): Set mdebug_flag instead of
540         mdebug_mask.
541         (mdatabase__load_for_keys): Likewise.
542
543         * draw.c: Include "internal-flt.h".
544         (dump_combining_code): Don't subtract 128 from combining code
545         off_x/y.
546
547         * font-flt.c: Include "internal-flt.h".  Set mdebug_flag instead
548         of mdebug_mask.
549         (run_rule): Print debug info only when MDEBUG_FLAG is greater than
550         2.
551         (run_cond): Likewise.
552         (run_otf): Likewise.
553         (run_command): Likewise.
554         (mfont__flt_run): Change format of debug info.
555
556         * font-ft.c: Include "internal-flt.h".
557         Set mdebug_flag instead of mdebug_mask.
558         (mfont__ft_drive_otf): Fix arg to OTF_check_features.
559
560         * input.c: Set mdebug_flag instead of mdebug_mask.
561         (shift_state): New MDEBUG_FLAG macro.
562         (preedit_commit): Likewise.
563         (filter): Likewise.
564
565         * internal-flt.h: New file.
566
567         * internal-gui.h (MAKE_COMBINING_CODE, COMBINING_CODE_OFF_Y)
568         (COMBINING_CODE_OFF_X, COMBINING_CODE_BASE_X)
569         (COMBINING_CODE_BASE_Y, COMBINING_CODE_ADD_X)
570         (COMBINING_CODE_ADD_Y, MAKE_COMBINING_CODE_BY_CLASS)
571         (COMBINING_BY_CLASS_P, COMBINING_CODE_CLASS)
572         (MAKE_PRECOMPUTED_COMBINDING_CODE, COMBINING_PRECOMPUTED_P): Move
573         these macros to internal-flt.h.
574
575         * internal.h (M17N_OBJECT_ADD_ARRAY): Adjusted for the change of
576         mdebug__flags.
577         (M17N_OBJECT_REGISTER, M17N_OBJECT_UNREGISTER): Likewise.
578         (enum MDebugMaskBit): Delete this enum.
579         (enum MDebugFlag): New enum.
580         (mdebug__flag): Don't extern it.
581         (mdebug__flags): Extern it.
582         (MDEBUG_FLAG): New macro.
583         (MDEBUG_PRINT0): Use the macro MDEBUG_FLAG.
584         (MDEBUG_DUMP, MDEBUG_PUSH_TIME, MDEBUG_POP_TIME)
585         (MDEBUG_PRINT_TIME): Likewise.
586
587         * m17n-X.c (xfont_open): Set mdebug_flag instead of mdebug_mask.
588         (xfont_list): Likewise.
589
590         * m17n-core.c (mdebug__flag): Delete this variable.
591         (mdebug__flags): New variable.
592         (SET_DEBUG_FLAG): Make it a function.
593         (m17n_init_core): Set mdebug_flag instead of mdebug_mask.
594         (m17n_fini_core): Likewise.
595
596         * m17n-gui.c (m17n_init_win): Set mdebug_flag instead of mdebug_mask.
597         (m17n_fini_win): Likewise.
598
599         * m17n-misc.h (enum MErrorCode): Add MERROR_FLT.
600
601         * m17n.c (m17n_init): Set mdebug_flag instead of mdebug_mask.
602         (m17n_fini): Likewise.
603
604         * symbol.c (msymbol__free_table): Adjusted for the change of
605         mdebug__flags.
606
607         * Makefile.am (BASICBUILDS): Add libm17n-flt.la.
608         (BASICHEADERS): Add m17n-flt.h.
609         (FLT_SOURCES): New variable.
610         (libm17n_flt_la_SOURCES, libm17n_flt_la_LIBADD)
611         (libm17n_flt_la_LDFLAGS): Likewise.
612
613         * m17n-flt.h: New file.
614
615         * m17n-flt.c: New file created by modifying font-flt.c.
616
617 2007-07-13  Kenichi Handa  <handa@m17n.org>
618
619         * Version 1.4.0 released.
620
621 2007-07-12  Kenichi Handa  <handa@m17n.org>
622
623         * input.c: Fix doxygen @ref commands.
624
625 2007-07-10  Kenichi Handa  <handa@m17n.org>
626
627         * m17n-core.h (M17NFunc): Fix typo of Doxygen directive.
628
629 2007-07-09  Kenichi Handa  <handa@m17n.org>
630
631         * m17n-core.h (M17N_BEGIN_HEADER, M17N_END_HEADER): New macros.
632
633         * m17n.h: Include m17n-core.h if not yet done.  Use macros
634         M17N_BEGIN_HEADER and M17N_END_HEADER.
635
636         * m17n-gui.h: Likewise.
637
638         * m17n-misc.h: Likewise.
639
640 2007-06-13  Kenichi Handa  <handa@m17n.org>
641
642         * font-flt.c (load_command): Prepend "^" in the regular expression.
643
644 2007-06-11  Kenichi Handa  <handa@m17n.org>
645
646         * language.c (mlanguage_name_list): Fix previous change.
647
648         * coding.c (mcoding__load_from_database): Add aliases in
649         coding_definition_list.
650
651 2007-06-10  Kenichi Handa  <handa@m17n.org>
652
653         * language.c (mlanguage_name_list): Fix previous change.
654
655 2007-06-08  Kenichi Handa  <handa@m17n.org>
656
657         * input.c (update_candidate): Copy candidate_list earlier.
658         (re_init_ic): Provide pseudo initialize state if none.
659
660 2007-06-05  Kenichi Handa  <handa@m17n.org>
661
662         * input.c (preedit_insert): Print debug information.
663
664         * database.c (expand_wildcard_database): New function.
665         (mdatabase_list): Fix handling of wildcard database.
666
667         * language.c (load_lang_name): New function.
668         (mlang__fini): Cancel the last two changes.
669         (mlanguage_name_list): New arg script and territories.  Use
670         load_lang_name.
671
672         * m17n.h (mlangauge_name_list): Adjusted.
673
674 2007-06-04  Kenichi Handa  <handa@m17n.org>
675
676         * input.c (open_im): Check if the input method has at least one
677         state.
678
679 2007-06-01  Kenichi Handa  <handa@m17n.org>
680
681         * input.c (shift_state): Change the format of debug print.
682         (preedit_commit): New arg need_prefix.  Caller changed.
683         (update_candidate): Copy candidate_list.
684         (take_action_list): Likewise.
685         (handle_key): Change the format of debug print.
686
687         * font-flt.c (load_flt): Ignore unknown directives.
688
689 2007-05-25  Kenichi Handa  <handa@m17n.org>
690
691         * m17n-core.c (mdebug__unregister_object): Small optimization.
692
693         * database.c (find_file): Merged into get_database_file.
694         (get_database_file): New arg result.  Caller changed.
695         (mdatabase__check): Fix the logic.
696
697 2007-05-24  Kenichi Handa  <handa@m17n.org>
698
699         * database.c (find_database): If unprocessed wildcard database is
700         found, register database filed and recursively call find_database.
701         (free_db_info): Unref db_info->properties.
702         (register_database): New arg properties.  Delete code for
703         initializing mdatabase__list.
704         (register_databases_in_files): Argument changed.  Caller changed.
705         (mdatabase__update): Don't list files by glob here.
706         (mdatabase_list): If unprocessed wildcard database is found,
707         register database filed and recursively call mdatabase_list.
708
709         * database.h (enum MDatabaseStatus): New enum
710         MDB_STATUS_AUTO_WILDCARD.
711
712         * input.c (load_branch): Fix previous change.
713         (update_global_info): If the global database is not found, return -1.
714
715 2007-05-23  Kenichi Handa  <handa@m17n.org>
716
717         * database.c (Mversion): New variable.
718         (mdatabase__init): Initialize it.
719         (register_database): New arg properties.  Caller changed.
720         (register_databases_in_files): Don't check version here.
721         (mdatabase__update): Likewise.
722
723         * database.h (MDatabaseInfo): New member properties.
724
725 2007-05-21  Kenichi Handa  <handa@m17n.org>
726
727         * language.c: Include <ctype.h>
728         (mlanguage__info): Use strncasecmp (not memcmp).
729         (mlanguage_name): Downcase language name for backward
730         compatibility.
731
732         * input.c (filter): Don't check Mlanguage property of
733         ic->im->langauge.
734
735 2007-05-18  Kenichi Handa  <handa@m17n.org>
736
737         * language.c (mlanguage_name): Fix it to handle M-text English
738         name.
739
740         * input.c (config_command): Set NAME before using it.
741         (load_branch): Try to resolve a map name by variables.
742
743 2007-05-17  Kenichi Handa  <handa@m17n.org>
744
745         * language.c (mlang__fini): Fix previous change.
746
747 2007-05-16  Kenichi Handa  <handa@m17n.org>
748
749         * plist.c (free_plist): Cancel the last change.
750         (write_element): Check if PLIST is nested.
751         (mplist__from_plist): Label a plist as nested if appropriate.
752         (mplist__from_alist): Label a plist as nested.
753         (mplist__conc): Check the value of PL before referring it.  Label
754         a plist as nested if appropriate.
755         (mplist_copy): Label a plist as nested if appropriate.
756         (mplist_put_func): Return Mnil if KEY is a managing key.
757         (mplist_push): Label a plist as nested if appropriate.
758
759         * plist.h (MPLIST_SET_NESTED_P): Return 1 iff plist->control.flag
760         is set as nested.
761
762         * language.c (mlang__fini): Unref each element of langname_list.
763
764 2007-05-14  Kenichi Handa  <handa@m17n.org>
765
766         * language.c: Include <string.h> and <locale.h>.
767         (langname_list): New variable.
768         (load_lang_script_list): Exclude invalid list elements.
769         (mlang__init): Initialize langname_list.
770         (mlang__fini): Unref langname_list.
771         (mlanguage__info): Adjusted for the change of English
772         name (symbol->M-text).
773         (mlanguage_name): Label it as obsolete.
774         (mlanguage_name_list): New function.
775
776         * m17n.h (mlanguage_name_list): Extern it.
777
778         * locale.c (make_locale): Fix setting of members of locale.
779
780         * plist.c (free_plist): Unref also nested plist.
781
782 2007-05-11  Kenichi Handa  <handa@m17n.org>
783
784         * coding.c (mconv_reset_converter): Set internal->used to 0.
785
786 2007-05-08  Kenichi Handa  <handa@m17n.org>
787
788         * input.c (check_description): Force copying the translated text.
789
790 2007-05-02  Kenichi Handa  <handa@m17n.org>
791
792         * input.c (minput_save_config): Unref unnecessary plist.  Use
793         free_im_list to free im_config_list.
794
795 2007-04-20  Kenichi Handa  <handa@m17n.org>
796
797         * input.c (config_command): Fix previous change again.
798         (config_variable): Likewise.
799         (minput_config_command): Fix for the case of setting back to
800         default.
801         (minput_config_variable): Likewise.
802         (minput_save_config): Include nil as documentation of customized
803         command/variable.
804
805 2007-04-05  Kenichi Handa  <handa@m17n.org>
806
807         * input.c (config_command): Fix previous change.
808         (config_variable): Likewise.
809
810         * plist.c (mplist_get_func): Fix for backward compatiblity.
811
812 2007-04-04  Kenichi Handa  <handa@m17n.org>
813
814         * input.c (minput_get_command, minput_config_command): Fix example
815         codes.
816
817 2007-03-29  Kenichi Handa  <handa@m17n.org>
818
819         These changes are to avoid unsafe casting of a function pointer.
820
821         * face.h (enum MFaceProperty): Delete MFACE_HOOK_FUNC.
822         (struct MFace): New member hook.
823
824         * face.c (serialize_face): Adjusted for the change of MFace.
825         (deserialize_face): Likewise.
826         (mface__init): Likewise.  Use msymbol_put_func.
827         (mface__realize): Adjusted for the change of MFace.  Avoid
828         compiler warning.
829         (mface_get_prop): Adjusted for the change of MFace.
830         (mface_put_prop): Likewise.
831         (mface_get_hook): New function.
832         (mface_put_hook): New function.
833         (mface_update): Adjusted for the change of MFace.
834
835         * input-gui.c (win_callback): Use mplsit_get_func.
836         (minput__win_init): Use mplsit_put_func.
837
838         * input.c (take_action_list): Use mplist_get_func.
839         (init_ic_info): Likewise.
840         (fini_ic_info): Likewise.
841         (minput_callback): Likewise.
842         (minput__init): Use mplist_put_func.
843
844         * language.c (mlang__init): Use msymbol_put_func.
845
846         * m17n-core.h (M17NFunc): New function type.
847         (M17N_FUNC): New macro.
848         (msymbol_put_func, msymbol_get_func): Extern them.
849         (mplist_put_func, mplist_get_func): Extern them.
850         
851         * m17n-gui.h (mface_get_hook, mface_put_hook): Extern them.
852
853         * m17n-gui.c (mframe): Add a proper casting.
854
855         * plist.h (struct MPlist): Make the member val a union.
856         (MPLIST_VAL): Adjusted for the above change.
857         (MPLIST_FUNC): New macro.
858         (MPLIST_VAL_FUNC_P, MPLIST_SET_VAL_FUNC_P): New macros.
859
860         * plist.c (mplist_put_func, mplist_get_func): New functions.
861
862         * symbol.c (msymbol__fini): Use MPLIST_VAL.
863         (msymbol_put_func, msymbol_get_func): New functions.
864
865         * textprop.c (mtext_serialize): Use msymbol_get_func.
866         (mtext_deserialize): Likewise.
867
868 2007-03-28  Kenichi Handa  <handa@m17n.org>
869
870         * input.c (get_candidate_list): Avoid unnecessary unref.
871
872 2007-03-23  Kenichi Handa  <handa@m17n.org>
873
874         * database.c (mdatabase__update): Unref plist at the tail.
875
876 2007-03-21  Kenichi Handa  <handa@m17n.org>
877
878         * input.c (update_custom_info): Fix for the case "name == Mnil &&
879         extra != Mnil".
880         (config_command): Fix for the case that configuration is
881         cancelled.
882         (config_variable): Likewise.
883         (minput_config_command): If keyseqlist is an empty list, cancel
884         the customization.
885         (minput_config_variable) If value is an empty list, cancel the
886         customization.
887         (minput_save_config): Handle cancellation of config and customize
888         correctly.
889
890 2007-03-15  Kenichi Handa  <handa@m17n.org>
891
892         * input.c (minput_config_variable): Check custom->vars (not
893         custom->cmds).
894
895 2007-03-01  Kenichi Handa  <handa@m17n.org>
896
897         * input.c (reload_im_info): Setup cmds, vars, and title of
898         im_info.
899         (check_variable_value): Fix the return value.
900
901         * database.c (mdatabase__check): If necessary, update database and
902         find a new file.
903
904 2007-02-28  Kenichi Handa  <handa@m17n.org>
905
906         * database.c (get_dir_info): Set dir_info->status to
907         MDB_STATUS_OUTDATED.
908         (check_version): New function.
909         (register_database): Don't call find_database.
910         (register_databases_in_files): Don't register a database of
911         invalid version.
912         (mdatabase__update): Likewise.  Avoid unnecessary scanning.
913
914         * database.h (enum MDatabaseStatus): New membes MDB_STATUS_UPDATED
915         and MDB_STATUS_OUTDATED.
916
917         * font.h (struct MFont): Types of members type, source, and
918         spacing changed to unsigned.
919
920         * internal-gui.h (struct): Types of members category and type
921         changed to unsigned.
922
923         * internal.h (struct MText): Types of members format and coverage
924         changed to unsigned.
925
926         * m17n-core.h (M17NLIB_PATCH_LEVEL): Changed to 5.
927         (M17NLIB_VERSION_NAME): Changed to "1.3.5".
928
929 2007-02-23  Kenichi Handa  <handa@m17n.org>
930
931         * input.c (Mpop): New variable.
932         (fully_initialize): Initialize Mpop.
933         (parse_action_list): Handle Mpop.
934         (take_action_list): Likewise.
935         (handle_key): When a key is unhandled, shift to the initial state
936         only if the current state has no branch action.
937
938 2007-02-12  Kenichi Handa  <handa@m17n.org>
939
940         * input.c (get_preceding_char): Unref mt if necessary.
941         (get_following_char): Likewise.
942         (parse_action_list): Fix handling of `insert' action as
943         candidates.
944         (get_candidate_list): Fix for handling (("CANDIDATE1" ...)).
945         (take_action_list): Check invalid candidate list.
946
947 2007-02-06  Kenichi Handa  <handa@m17n.org>
948
949         * input.c (integer_value): Check also ic->produced for @-N.
950
951 2007-01-26  Kenichi Handa  <handa@m17n.org>
952
953         * database.c (mdatabase__update): Check mdatabase__dir_list from
954         the tail.
955
956         * font-ft.c (STRDUP_LOWER): Don't ignore the tailing spaces.
957
958 2007-01-12  Kenichi Handa  <handa@m17n.org>
959
960         * input.c (handle_key): Handle a branch action of the initial
961         state correctly.
962
963 2007-01-10  Kenichi Handa  <handa@m17n.org>
964
965         * m17n-gd.c (gd_render): Delete superfluous line.
966
967 2006-12-26  Kenichi Handa  <handa@m17n.org>
968
969         * m17n.h (minput_callback): Extern it.
970
971         * input.h (minput__callback): Delte extern.
972
973         * input.c (get_surrounding_text): Adjusted for the change of
974         minput__callback to minput_callback.
975         (delete_surrounding_text): Likewise.
976         (minput_create_ic): Likewise.
977         (minput_destroy_ic): Likewise.
978         (minput_filter): Likewise.
979         (minput_set_spot): Likewise.
980         (minput_toggle): Likewise.
981         (minput_reset_ic): Likewise.
982
983         (preedit_commit): Reset ic->candidate_index, ic->candidate_from,
984         and ic->candidate_to to 0.
985         (minput_callback): Renamed from minput__callback.
986
987         * input-gui.c (win_callback): Adjusted for the change of
988         minput__callback to minput_callback.
989
990 2006-12-15  Kenichi Handa  <handa@m17n.org>
991
992         * font-ft.c (ft_add_font): Fix typo.
993
994 2006-12-06  Kenichi Handa  <handa@m17n.org>
995
996         * Version 1.3.4 released.
997
998 2006-11-16  Kenichi Handa  <handa@m17n.org>
999
1000         * input.c (parse_action_list): Allow (undo 0).
1001         (adjust_markers): New function.
1002         (preedit_insert, preedit_delete): Call adjust_markers.
1003         (preedit_replace): New function.
1004         (update_candidate): Call preedit_replace instead of preedit_insert
1005         and preedit_delete.
1006         (filter): When ic_info->commit_key_head is nonzero, shift input
1007         event keys even if there's no committed text.
1008
1009 2006-11-10  Kenichi Handa  <handa@m17n.org>
1010
1011         * input.h (MInputContextInfo): New member commit_key_head.
1012
1013         * input.c (preedit_commit): Update ic_info->commit_key_head.
1014         (take_action_list): Reset ic_info->commit_key_head on Mundo.
1015         (filter): When committed, shift keys by ic_info->commit_key_head.
1016
1017 2006-10-30  Kenichi Handa  <handa@m17n.org>
1018
1019         * input.c (preedit_delete): Fix typo.
1020         (take_action_list): Print more debugging information.  Allow
1021         variable in arg of 'select' and `pushback'.
1022
1023         * database.c (gen_database_name): Don't put extra space.
1024         (load_database): Print debugging information.
1025         (register_databases_in_files): New arg headlen.  Callers changed.
1026         (mdatabase__load_for_keys): Shorten debugging information.
1027         (mdatabase_load): Don't print debugging information here.
1028
1029 2006-10-27  Kenichi Handa  <handa@m17n.org>
1030
1031         * input.c (marker_code): New arg surrounding.  Callers changed.
1032         (surrounding_pos): Check if name[0] == '@'.
1033         (integer_value): Fix for the change semantics of `@-N' and `@+N'.
1034         (take_action_list): Likewise.
1035         (get_preceding_char): If POS is zero, always call
1036         get_surrounding_text.
1037
1038 2006-10-19  Kenichi Handa  <handa@m17n.org>
1039
1040         * input.c (load_variables): Fix setting of `global'.
1041
1042 2006-10-16  Kenichi Handa  <handa@m17n.org>
1043
1044         * draw.c (draw_background): Be sure to set *to_x.
1045         (render_glyph_string): If from == to, just return.
1046
1047 2006-10-18  Kenichi Handa  <handa@m17n.org>
1048
1049         * database.c (get_dir_info): Return NULL if the directory name is
1050         too long.
1051         (register_databases_in_files): Call register_database with
1052         MDB_STATUS_AUTO.
1053         (mdatabase__update): Fix logic.  Call register_database with
1054         MDB_STATUS_AUTO.
1055         (mdatabase_define): Call register_database with
1056         MDB_STATUS_EXPLICIT.
1057
1058         * input.c (delete_surrounding_text): Be sure to set members
1059         preceding_text and following_text to NULL.
1060         (shift_state): Save variable values in ic_info->vars_saved.
1061         (preedit_commit): Don't print debug information here.  Don't
1062         change ic_info->keys here.
1063         (get_candidate_list): Don't ref plist.
1064         (take_action_list): Don't unref return value of
1065         get_candidate_list.  For undo, reset ic->produced and recover
1066         ic_info->vars.  Be sure to set ic->candidate_list to NULL after
1067         unref it.
1068         (init_ic_info): Set ic_info->vars_saved.
1069         (fini_ic_info): Unref ic_info->vars_saved.
1070         (re_init_ic): Be sure to set ic->candidate_list to NULL after
1071         unref it.
1072         (filter): Be sure to set members preceding_text and following_text
1073         to NULL.  Print debug information about produced text.  Delete
1074         processed keys from ic_info->keys.
1075
1076         * input.h (MInputContextInfo): New member vars_saved.
1077
1078 2006-10-16  Kenichi Handa  <handa@m17n.org>
1079
1080         * database.c (mdatabase__update): Fix the way to get db_info.
1081
1082 2006-10-02  Kenichi Handa  <handa@m17n.org>
1083
1084         * font.h (struct MFont): New member `multiple_sizes'.  Bit-size of
1085         `size' changed to 24.
1086
1087         * font.c (xlfd_unparse_name): Adjusted for the change of
1088         MFont->size.
1089         (font_score): Likewise.
1090         (mfont__set_spec_from_face): Set spec->multiple_sizes to 0.
1091
1092         * m17n-X.c (MFontX, _MFontX): Deleted.
1093         (SET_SIZE, HAVE_SIZE): Deleted.
1094         (free_display_info): Adjusted for the change of
1095         disp_info->font_list format.
1096         (xfont_registry_list): Likewise.
1097         (xfont_open): Likewise.
1098         (xfont_list): Likewise.
1099         (xfont_encode_char): Ignore size to find a realized font.
1100         (MRealizedFontXft): Change the order of members to make it
1101         compatible with MRealizedFontFT.
1102
1103 2006-09-27  Kenichi Handa  <handa@m17n.org>
1104
1105         * font.c (mfont_match_p, mfont_open, mfont_encapsulate)
1106         (mfont_close): Add comments.
1107
1108         * mtext-lbrk.c (mtext_line_break): Add comment.
1109
1110 2006-09-26  Kenichi Handa  <handa@m17n.org>
1111
1112         * input.c (minput_get_description): Handle description about
1113         inclusion-only input methods.
1114
1115 2006-09-21  Kenichi Handa  <handa@m17n.org>
1116
1117         * input.c (M_gettext): New variable.
1118         (fully_initialize): Initialize M_gettext.
1119         (check_description): New function.
1120         (load_commands): Call check_description.
1121         (config_all_commands): Be sure to unref pl.
1122         (load_variables): Call check_description.
1123         (config_all_variables): Be sure to unref pl.
1124         (load_im_info): Call check_description.
1125
1126         * internal.h [ENABLE_NLS]: Include <libintl.h> and define _.
1127
1128         * m17n-core.c (m17n_init_core) [ENABLE_NLS]: Call bindtextdoman
1129         and bind_textdomain_codeset.
1130
1131         * Makefile.am (AM_CPPFLAGS): Add -DGETTEXTDIR=...
1132
1133 2006-09-15  Kenichi Handa  <handa@m17n.org>
1134
1135         * input.c (reload_im_info): Update custom and global info.
1136         (init_ic_info): Fix previous change.
1137
1138 2006-09-14  Kenichi Handa  <handa@m17n.org>
1139
1140         * database.c: Include <libgen.h>.
1141         (mdatabase__lock): Make a directory if necessary.
1142
1143         * input.c (resolve_command): Adjusted for the format change of
1144         configured_cmds member.
1145         (load_commands, load_variables): Fix for errornous data handling.
1146         (config_command, config_variable): New function.
1147         (config_all_commands, config_all_variables): Renamed from
1148         config_commands and config_variables.  Utilize the above function.
1149         (check_variable_value): Argument changed.  Callers changed.
1150         (load_im_info): Call config_all_commands and config_all_variables.
1151         (init_ic_info): Adjusted for the format change of configured_vars
1152         member.
1153         (minput__init): Initialize Mcustomized, Mconfigured, and
1154         Minherited.
1155         (Mcustomized, Mconfigured, Minherited): New variables.
1156         (minput_get_command): Be sure to return NULL if an input method
1157         use no local command.
1158         (minput_get_variable): Be sure to return NULL if an input method
1159         use no local variable.
1160         (minput_config_command, minput_config_variable)
1161         (minput_save_config): Adjusted for the format change of
1162         configured_cmds and configured_vars members.
1163         
1164         * plist.c (write_element): Delete superfluous ':'.
1165
1166 2006-09-13  Kenichi Handa  <handa@m17n.org>
1167
1168         * m17n.h (Minherited, Mcustomized, Mconfigured): Extern them.
1169         (minput_config_file): Extern it.
1170
1171         * draw.c (Minherited): Declaration moved to input.c.
1172         (mdraw__init): Don't initialize Minherited here.
1173
1174         * database.c (mdatabase__unlock): Be sure to unlink uniq file.
1175
1176 2006-09-07  Kenichi Handa  <handa@m17n.org>
1177
1178         * textprop.c (mtext_serialize): Call mplist__serialize with the
1179         arg pretty 0.
1180
1181         * plist.h (mplist__serialize): Prototype adjusted.
1182         (mplist__assq): Extern it.
1183
1184         * plist.c: Include <ctype.h>
1185         (PUTC, PUTS): New macros.
1186         (write_symbol): New function.
1187         (write_element): New arg indent.
1188         (dump_string, dump_plist_element): Delete them.
1189         (mplist__from_string): New arg pretty.
1190         (mplist__assq): New function.
1191         (mdebug_dump_plist): Use write_element.
1192
1193         * mtext.c (mtext_cat_char): Allocate more memory.
1194         (mdebug_dump_mtext): Don't escal a newline character.
1195
1196         * m17n.h (minput_get_command, minput_get_variable)
1197         (minput_config_command, minput_config_variable)
1198         (minput_save_config): Extern them.
1199
1200         * m17n-core.c: Include <string.h>.
1201         (m17n_init_core): If the env. var. MDEBUG_OUTPUT_FILE is "stdout",
1202         use the stream stdout instead of a file of that name.
1203
1204         * m17n-X.c (mwin__parse_event): Fix handling of Shift and Control
1205         modifiers.
1206
1207         * internal.h (MFAILP, MDEBUG_PRINT0): New macros.
1208         (MDEBUG_PRINT, MDEBUG_PRINT1, MDEBUG_PRINT2, MDEBUG_PRINT3)
1209         (MDEBUG_PRINT4, MDEBUG_PRINT5): Use MDEBUG_PRINT0.
1210         (MDEBUG_DUMP): Flush the stream.
1211
1212         * input.h (struct _MInputMethodInfo): Delete member im.  New
1213         members mdb, language, name, extra, cmds, configured_cmds,
1214         bc_cmds, vars, configured_vars, bc_vars, description, and tick.
1215         (MInputContextInfo): New member tick.
1216
1217         * input.c: Big change to improve user-side input method
1218         customization.  Here, list just public API changes.
1219         (minput_get_commands, minput_get_variables)
1220         (minput_assign_command_keys, minput_set_variable): Label them
1221         obsolete.
1222         (minput_get_command, minput_get_variable)
1223         (minput_config_command, minput_config_variable)
1224         (minput_save_config): New functions.
1225         
1226         * database.h (PATH_MAX): Define it if not yet defined.
1227         (PATH_SEPARATOR): Likewise.
1228         (enum MDatabaseStatus): New enum.
1229         (struct MDatabaseInfo): Moved from database.c.  New members status,
1230         time, lock_file, and uniq_file.
1231         (mdatabase__update, mdatabase__file, mdatabase__lock, mdatabase__save)
1232         (mdatabase__unlock): Extern them.
1233
1234         * database.c: Include <time.h>.
1235         (MDB_DIR_LEN): Don't include the terminating '\0' in the length.
1236         (GEN_PATH): Args changed.  Callers changed.
1237         (struct MDatabaseInfo): Moved to database.h.
1238         (struct MDatabase, mdb_list): Deleted.
1239         (mdatabase__list): New var.
1240         (get_database_filename): Deleted.  Callers changed to use
1241         get_database_file.
1242         (find_file, get_database_file): New files.
1243         (get_dir_info): Initialize new members of MDatabaseInfo.
1244         (find_database): Arg chagnded.  Callers changed.
1245         (free_db_info, register_database, register_databases_in_files):
1246         New functions.
1247         (update_database_list): Deleted.
1248         (mdatabase__init): Initialize mdatabase__list instead of mdb_list.
1249         (mdatabase__fini): Finalize mdatabase__list instead of mdb_list.
1250         (mdatabase__update): New function.
1251         (mdatabase__check): Return value changed.
1252         (mdatabase__file, mdatabase__lock, mdatabase__save)
1253         (mdatabase__unlock): New functions.
1254
1255 2006-08-30  TAKAHASHI Naoto  <ntakahas@m17n.org>
1256
1257         * input.c (get_surrounding_text): Return -2 when surrounding text
1258         is unavailable.
1259         (get_following_char): Likewise.
1260         (get_preceding_char): Likewise.
1261         (minput__callback): Return 0 if there is a callback function,
1262         otherwise -1.
1263
1264 2006-08-17  Kenichi Handa  <handa@m17n.org>
1265
1266         * input.c (reset_ic): Use shift_state to setup the current state.
1267
1268 2006-08-02  Theppitak Karoonboonyanan  <thep@linux.thai.net>  (tiny change)
1269
1270         * Makefile.am (libm17n_la_LIBADD, libm17n_gui_la_LIBADD)
1271         (libm17n_X_la_LIBADD, libm17n_gd_la_LIBADD, linkcore_LDADD)
1272         (linkshell_LDADD, linkgui_LDADD): Use ${top_builddir}.
1273
1274 2006-08-02  Kenichi Handa  <handa@m17n.org>
1275
1276         * plist.c (mdebug_dump_plist): Fix the 2nd arg to dump_plist_element.
1277
1278         * mtext.c (mdebug_dump_mtext): If not fullp, dump just text. 
1279
1280         * font-ft.c (ft_encapsulate): Add code for debugging.
1281         (mfont__ft_drive_otf): Be sure to encode character before getting
1282         metrics.
1283
1284 2006-07-21  Kenichi Handa  <handa@m17n.org>
1285
1286         * draw.c (mdraw_text_extents): Fix previous typo.
1287
1288 2006-07-19  Kenichi Handa  <handa@m17n.org>
1289
1290         * draw.c (gstring_width): New arg lbearing.
1291         (render_glyph_string): Adjusted for the change of gstring_width.
1292         (mdraw_text_extents): Fix lbearing of ink and line metrics.
1293
1294         * m17n-core.h (Mlanguage): Extern it.
1295
1296         * m17n.h (Mlanguage): Extern deleted. 
1297
1298         * mtext.c (mtext__init): Initialize Mlanguage.
1299         (Mlanguage): Declaration moved from locale.c
1300
1301         * locale.c (mlocale__init): Don't initialize Mlanguage here.
1302         (Mlanguage): Declaration moved to mtext.c.
1303
1304         * language.c (mlang__init): Don't initialize Mlanguage here.
1305
1306         * font.c (OTF_tag_name) [! HAVE_OTF]: New function.
1307
1308 2006-07-14  Kenichi Handa  <handa@m17n.org>
1309
1310         * font-ft.c: Use FT_BDF_H macro.  Include fontconfig/fcfreetype.h.
1311         (MRealizedFontFT): New member face_encapsulated.
1312         (free_ft_rfont): Pay attention to ft_rfont->face_encapsulated.
1313         (ft_gen_font): New function.
1314         (ft_add_font): Use ft_gen_font.
1315         (ft_list_script): Store lists in ft_script_list.
1316         (ft_check_otf): New arg ft_face.  Caller changed.
1317         (ft_check_language): Likewise.
1318         (ft_check_script): Likewise.
1319         (ft_encapsulate, ft_close): New functions.
1320         (mfont__ft_driver): Initialize members encapsulate and close.
1321         (mfont__ft_drive_otf): Use OTF_open_ft_face if it is available.
1322
1323         * font.h (struct MRealizedFont): New member encapsulating.
1324         (struct MFontDriver): New members encapsulate and close.
1325
1326         * font.c (mfont__match_p): If FONT is realized, check capability
1327         by font drivers's check_capability method.
1328         (mfont_match_p, mfont_open, mfont_encapsulate, mfont_close): New
1329         functions.
1330
1331         * m17n-X.c (xfont_list_family_names): Delete unused var.  Fix
1332         declarations of foundry and fam local vars.
1333         (xft_driver): Make it static.
1334
1335         * m17n-gui.h (mfont_match_p, mfont_open, mfont_encapsulate)
1336         (mfont_close): Extern them.
1337
1338         * m17n-gd.c (device_open): Don't specify foundry and family of the
1339         default face.
1340
1341 2006-07-11  Kenichi Handa  <handa@m17n.org>
1342
1343         * m17n-gui.c (m17n_fini_win): Set null_interface.handle to NULL;
1344
1345 2006-07-13  Kenichi Handa  <handa@m17n.org>
1346
1347         * font-ft.c (fc_build_charset): Return NULL if FcCharSet can't be
1348         created.
1349         (ft_check_script): Delete unused var.
1350         (ft_list_capability): Likewise.
1351
1352         * font.c (mfont__get_capability): Setup cap->otf.
1353         (Motf): Make it global.
1354         (mfont_get_prop): Accept Mlanguage, Mscript, and Motf as key arg.
1355
1356         * font.h (MFontCapability): New member otf.
1357
1358         * language.c (mlang__fini): Delete unused vars.
1359
1360         * m17n-gui.h (Motf): Extern it.
1361
1362         * database.c (update_database_list): Delete unused vars.
1363
1364 2006-07-07  Kenichi Handa  <handa@m17n.org>
1365
1366         * font-ft.c (DEVICE_DELTA): Fix typo.
1367
1368 2006-07-06  Kenichi Handa  <handa@m17n.org>
1369
1370         * fontset.c (mfont__lookup_fontset): Don't ignore family and
1371         foundry of face.
1372
1373 2006-07-05  TAKAHASHI Naoto  <ntakahas@m17n.org>
1374
1375         * database.c: Update comments.
1376
1377 2006-07-05  Kenichi Handa  <handa@m17n.org>
1378
1379         * database.c (PATH_MAX): Define it if not yet defined.
1380         (PATH_SEPARATOR, USE_GEN_PATH, GEN_PATH, GEN_PATH_FROM_MT): New
1381         macros.
1382         (get_database_filename): Use GEN_PATH.
1383         (get_dir_info): Don't include the last '/' in directory name.
1384         (register_database): New function.
1385         (update_database_list): Use register_database.  Search all
1386         directories in mdatabase__dir_list for wildcard databases.
1387         (mdatabase__init): Check "~/.m17n.d".
1388
1389 2006-07-03  Kenichi Handa  <handa@m17n.org>
1390
1391         * input-gui.c (win_callback): If is ic->candidate_show zero, don't
1392         push reverse property.
1393
1394         * plist.c (dump_plist_element): Fix previous change.
1395
1396 2006-06-28  Kenichi Handa  <handa@m17n.org>
1397
1398         * font.c (xlfd_unparse_name): Suppress the heading '-' if not
1399         necessary.
1400
1401         * draw.c (MbidiNSM): New variable.
1402         (visual_order) [! HAVE_FRIBIDI]: Clear levels at first.  Pay
1403         attention to bidi type NSM.
1404         (mdraw__init): Initialize MbibiNSM.
1405
1406         * language.c (mscript__char_list): Fix finding a char-list element.
1407
1408         * plist.c (dump_string): Return number of printed characters.
1409         (dump_plist_element): Print elements more compactly.
1410
1411 2006-06-23  Kenichi Handa  <handa@m17n.org>
1412
1413         * Makefile.am (BUILD_LIBS): Don't increment it conditionally.
1414         (include_HEADERS): Likewise.
1415
1416 2006-06-23  TAKAHASHI Naoto  <ntakahas@m17n.org>
1417
1418         * language.c: Update documentation.
1419
1420 2006-06-23  Kenichi Handa  <handa@m17n.org>
1421
1422         * font-ft.c (struct MFontFT): Delete member lang.
1423         (free_ft_info): Don't unref member lang.  Destroy members langset
1424         and charset.
1425         (fc_parse_pattern): Last argument changed to MFontFT *.  Callers
1426         changed.  Set members langset and charset.
1427         (fc_init_font_list, fc_list_pattern, fc_build_charset): New
1428         functions.
1429         (ft_init_font_list, ft_has_char_list_p, ft_list_char_list): New
1430         functions.
1431         (ft_list_family) [HAVE_FONTCONFIG]: Include FC_CHARSET on objset.
1432         (ft_list_family) [! HAVE_FONTCONFIG]: Call ft_init_font_list.
1433         (ft_list_language) [HAVE_FONTCONFIG]: Check representative
1434         characters at first.  If it fails, try listing by language names.
1435         (ft_list_language) [! HAVE_FONTCONFIG]: Call ft_list_char_list.
1436         (ft_check_language): Renamed from ft_check_lang.  Adjusted for the
1437         change of MFontCapability.
1438         (ft_list_capability): Likewise.  Try listing by languages, then by
1439         scripts.  Check OTF at last.
1440         (ft_check_script): New function.
1441         (ft_select): Adjusted for the check of MFontCapability.
1442         (ft_list_family_names): New function.
1443         (ft_check_capability): If cap->script is not Mnil, call
1444         ft_check_script.
1445         (mfont__ft_driver): Initialize with ft_list_family_names.
1446
1447         * font.h (struct MFontDriver): New member list_fmaily_names.
1448         (struct): Change member "MSymbol *lang" to "MSymbol language".
1449
1450         * font.c: Include "language.h".
1451         (Motf): New variable.
1452         (otf_script_list, load_otf_script_list): Delete it.
1453         (find_script_from_otf_tag): Delete it.
1454         (merge_capability): New function.
1455         (mfont__init): Init Motf.
1456         (mfont__fini): Don't unref otf_script_list.
1457         (free_font_capability): Check cap->script_tag to determine if
1458         OTF-related capability is set.
1459         (mfont__get_capability): Call mscript__from_otf_tag.  Adjusted for
1460         the change of type MFontCapability.
1461         (mfont_put_prop): Call merge_capability for Mlanguage, Mscript,
1462         and Motf properties.
1463         (mfont_list): Call merge_capability for LANGUAGE arg.
1464         (mfont_list_family_names): New function.
1465
1466         * input-gui.c: Typo in comments fixed.
1467
1468         * input.c: Typo in comments fixed.
1469
1470         * language.h (mlanguage__list): Delete it.
1471         (mscript__char_list, mscript__otf_tag, mscript__from_otf_tag): New
1472         functions.
1473
1474         * language.c: Include "mtext.h".
1475         (M_script_lang_list): Delete it.
1476         (language_list, script_list): New variables.
1477         (load_lang_script_list, init_language_list, init_script_list): New
1478         functions.
1479         (mlang__init): Don't load language database here.
1480         (mlang__fini): Unref language_list and script_list if not NULL.
1481         (mlanguage__list): Delete it.
1482         (mlanguage__info, mscript__info, mscript__char_list)
1483         (mscript__otf_tag, mscript__from_otf_tag): New functions.
1484         (mlanguage_list, mlanguage_code, mlanguage_name, mlanguage_text)
1485         (mscript_list, mscript_language_list): New functions.
1486
1487         * m17n-gui.h (mfont_list_family_names): Extern it.
1488
1489         * m17n.h (mlanguage_list, mlanguage_code, mlanguage_name)
1490         (mlanguage_text, mscript_list, mscript_language_list): Extern
1491         them.
1492
1493 2006-06-21  Kenichi Handa  <handa@m17n.org>
1494
1495         * m17n-X.c (xfont_driver): Initialize with
1496         xfont_list_family_names.
1497         (xfont_list_family_names): New function.
1498         (xft_driver): Initialize with NULL for list_family_names member.
1499         (device_init): Set list_family_names member of xft_driver to that
1500         of mfont__ft_driver.
1501
1502 2006-06-06  Kenichi Handa  <handa@m17n.org>
1503
1504         * fontset.c (mfont__lookup_fontset): Don't set *num to 1 if it is 0.
1505
1506 2006-03-24  Kenichi Handa  <handa@m17n.org>
1507
1508         * font-ft.c (ft_open): Improve debug message.
1509
1510         * fontset.c (mfontset__get_font): Fix for the case that no font in
1511         per_script list is available.
1512
1513 2006-02-06  Kenichi Handa  <handa@m17n.org>
1514
1515         * Version 1.3.3 released.
1516
1517 2006-02-22  Kenichi Handa  <handa@m17n.org>
1518
1519         * textprop.c: Fix some typos in documentation.
1520
1521         * plist.c: Fix some typos in documentation.
1522
1523         * m17n-core.h: Fix some typos in documentation.
1524         (M17NLIB_PATCH_LEVEL): Updated to 3.
1525         (M17NLIB_VERSION_NAME): Updated to "1.3.3".
1526
1527         * symbol.c: Fix some typos in documentation.
1528
1529         * mtext.c: Fix some typos in documentation.
1530
1531         * input.c: Fix several typos in documentation.
1532
1533 2006-02-06  Kenichi Handa  <handa@m17n.org>
1534
1535         * Version 1.3.2 released.
1536
1537 2006-02-03  Kenichi Handa  <handa@m17n.org>
1538
1539         * m17n-core.h (M17NLIB_PATCH_LEVEL): Updated to 2.
1540         (M17NLIB_VERSION_NAME): Updated to "1.3.2".
1541
1542         * font.c (xlfd_parse_name): Fix handling of the name "nil".
1543
1544         * draw.c (layout_glyphs): Fix handling left_padding of
1545         composition's base.
1546
1547         * m17n-gd.c (read_rgb_txt): Support HTML 4.0 color names.
1548
1549 2006-02-02  Kenichi Handa  <handa@m17n.org>
1550
1551         * Makefile.am (include_HEADERS): Add m17n-gui.h and m17n-X.h only
1552         if WITH_GUI is true.
1553
1554 2006-01-25  Kenichi Handa  <handa@m17n.org>
1555
1556         * input.c (resolve_expression): If the value of PLIST is a plist,
1557         but the first element is not symbol, return 0.
1558
1559 2006-01-17  Kenichi Handa  <handa@m17n.org>
1560
1561         * m17n-gd.c (gd_render): Use gdImageColorResolveAlpha only if
1562         HAVE_GD is 2 or the greater.
1563
1564 2006-01-16  Kenichi Handa  <handa@m17n.org>
1565
1566         * Version 1.3.1 released.
1567
1568 2006-01-16  Kenichi Handa  <handa@m17n.org>
1569
1570         * m17n-gd.c (gd_render): Use gdImageColorResolveAlpha instead of
1571         simulating anti-aliasing.
1572
1573         * m17n-core.h (M17NLIB_PATCH_LEVEL): Updated to 1.
1574         (M17NLIB_VERSION_NAME): Updated to "1.3.1".
1575
1576 2006-01-12  Kenichi Handa  <handa@m17n.org>
1577
1578         * input.c (get_surrounding_text): Always pop ic->plist.
1579         (reset_ic): Don't reset ic->plist.
1580
1581 2006-01-10  Kenichi Handa  <handa@m17n.org>
1582
1583         * input.c (preedit_commit): For debugging, print only commiting
1584         charactes.  Don't set ic->candidate_show to 0.
1585         (handle_key): Don't run branch-actions just by shifting to the
1586         current state.
1587         (reset_ic): Reset state_key_head and key_head of ic_info to 0.
1588         Reset vars and plist.
1589
1590 2006-01-07  Kenichi Handa  <handa@m17n.org>
1591
1592         * input.c (load_branch): Confirm that maps is not NULL.
1593
1594 2006-01-05  Kenichi Handa  <handa@m17n.org>
1595
1596         * input-gui.c (win_filter): Try to convert arg to key only when
1597         arg is not NULL.
1598
1599         * plist.c (read_integer_element): If '#' and '-' are followed by
1600         non-integer-constituent, read them as a part of a symbol.
1601         (read_symbol_element): New arg C.
1602         (read_element): Adjust args to read_symbol_element.
1603
1604         * input.c (load_macros): On overwriting a macro, free the old
1605         definition.
1606         (minput__init): Store Mmap in load_im_info_keys.
1607         (minput_get_title_icon): If the input method has no title, be sure
1608         to return NULL.
1609         (minput_get_description): If the input method has no description,
1610         be sure to return NULL.
1611         (minput_get_variables): Fix documentation.
1612         (handle_key): Pay attention to the case that key is Mnil.
1613         (filter): Likewise.  Fix handling of such symbol as S-A.
1614
1615 2005-12-22  Kenichi Handa  <handa@m17n.org>
1616
1617         * Version 1.3.0 released.
1618
1619 2005-12-22  Kenichi Handa  <handa@m17n.org>
1620
1621         * font-ft.c (ft_list): If the specified font has no property,
1622         return all fonts.
1623
1624 2005-12-20  Kenichi Handa  <handa@m17n.org>
1625
1626         * character.c (mchar_get_prop): Check char_prop_list.
1627         (mchar_put_prop, mchar_get_prop_table): Likewise.
1628
1629 2005-12-18  Kenichi Handa  <handa@m17n.org>
1630
1631         * input.c (minput_get_title_icon): If LANGUAGE is Mt, try also a
1632         file name sans language.
1633
1634 2005-12-16  TAKAHASHI Naoto  <ntakahas@m17n.org>
1635
1636         * input.c: Fix typo in comments.
1637
1638 2005-12-14  Kenichi Handa  <handa@m17n.org>
1639
1640         * input.c (minput_get_title_icon): Check the default icon for the
1641         input method.
1642
1643 2005-12-13  Kenichi Handa  <handa@m17n.org>
1644
1645         * input.c (Mless_equal, Mgreater_equal): New variables.
1646         (parse_expression, resolve_expression, parse_action_list)
1647         (take_action_list): Handle the aboves.
1648         (filter): Treat key S-X as X.
1649         (minput__init): Initialize Mless_equal and Mgreater_equal.
1650         (minput_get_title_icon): New function.
1651
1652         * m17n.h (minput_get_title_icon): Extern it.
1653
1654         * database.c (get_database_filename): Return a filename instead of
1655         file pointer.
1656         (load_database): Adjusted for the above change.
1657         (mdatabase__load_for_keys): Likewise.
1658         (mdatabase__find_file): New function.
1659
1660         * database.h (mdatabase__find_file): Extern it.
1661
1662         * font.h (mfont__resize): Delete extern.
1663
1664         * font.c (mfont__list): Check resize ratio.
1665         (mfont__resize): Delete it.
1666         (mfont_resize_ratio): Include the code of mfont__resize.
1667
1668         * font-ft.c (ft_open): Check resize ratio.
1669
1670         * m17n-X.c (xfont_open): Check resize ratio.
1671         (xft_open): Likewise.
1672
1673 2005-12-07  Kenichi Handa  <handa@m17n.org>
1674
1675         * input.c (take_action_list): If take_action_list return -1,
1676         return -1.
1677         (handle_key): Likewise.
1678
1679         * face.c (mface__for_chars): When font is specified and layouter
1680         is found for it, if the layouter doesn't support one of a
1681         character, use a face sans layouter for it.
1682
1683 2005-12-06  Kenichi Handa  <handa@m17n.org>
1684
1685         * fontset.c (mfont__lookup_fontset): If only a fallback font is
1686         found, don't use it for more than one character.
1687
1688 2005-12-05  Kenichi Handa  <handa@m17n.org>
1689
1690         * face.c (mface__realize): Set rfont->layouter to Mnil.
1691         (mface__for_chars): Fix handling of layouter.
1692
1693         * character.h (mchar__define_prop): Extern it.
1694
1695         * database.c (update_database_list): Call mchar__define_prop if
1696         necessary.
1697
1698         * character.c (mchar__init): Don't call mchar_define_property.
1699         Instead just initialize property keys.
1700         (mchar__fini): Free char_prop_list only if it's not NULL.
1701         (mchar__define_prop): New function.
1702         (mchar_define_property): Call mchar__define_prop.
1703
1704         * m17n-core.c (m17n_fini_core): Call mtext__prop_fini at after
1705         mplist__fini.
1706
1707 2005-12-02  Kenichi Handa  <handa@m17n.org>
1708
1709         * language.c (mlang__init): Handle extra chars.
1710
1711         * m17n-gui.h (mfont_check): Adjust prototype.
1712
1713         * m17n-X.c (xfont_driver): Specify xfont_check_capability.
1714         (xfont_check_capability): New function.
1715         (xft_driver): Specify xft_check_capability.
1716         (xft_check_capability): New function.
1717
1718         * font-ft.c (M0_3): Delete it.
1719         (M0): New variable.
1720         (ft_get_charmaps): Refer to M0.
1721         (fc_parse_pattern): Fix previous change.
1722         (ft_list_language): Check also extra chars.
1723         (ft_check_otf): Define it even if HAVE_OTF is undef.
1724         (ft_check_lang): Check the result of FcLangSetHasLang against
1725         FcLangDifferentLang.  Check also extra chars.
1726         (ft_list_capability): Delete ifdef HAVE_OTF.
1727         (ft_select): Likewise.
1728         (ft_open): Improve debug information.
1729         (ft_check_capability): New function.
1730         (mfont__ft_driver): Specify ft_check_capability.
1731         (mfont__ft_init): Initialize M0.
1732
1733         * fontset.c (get_font_from_group): New function.
1734         (mfontset__get_font): New function.
1735
1736         * fontset.h (mfontset__get_font): Extern it.
1737
1738         * font.c (OTF_tag): Define it if HAVE_OTF is undef.
1739         (mfont__fini): Delete ifdef HAVE_OTF.
1740         (free_font_capability): Likewise.
1741         (mfont__get_capability): Likewise.
1742         (mfont__check_capability): New function.
1743         (mfont_check): Change the order of arguments.  Use
1744         mfontset__get_font.
1745
1746         * font.h (struct MFontDriver): New member check_capability.
1747         (MFontCapability): Delete ifdef HAVE_OTF.
1748         (mfont__check_capability): Extern it.
1749
1750         * face.c (mface__realize): Fix handling of FONT arg.
1751         (mface__for_chars): Fix handling of explicitly specified font.
1752
1753 2005-11-25  Kenichi Handa  <handa@m17n.org>
1754
1755         * font-flt.c (run_command): Print debug info for
1756         left/rigth_padding
1757
1758         * draw.c (layout_glyphs): Fix handling of left/right_padding.
1759
1760         * face.c (mface__for_chars): Check rfont before accessing the
1761         members.
1762
1763 2005-11-21  Kenichi Handa  <handa@m17n.org>
1764
1765         * Makefile.am (lib_LTLIBRARIES): Define it conditionaly on
1766         WITH_GUI.
1767
1768         * fontset.c (fontset_table): New variable.
1769         (free_fontset): Call M17N_OBJECT_UNREGISTER.
1770         (mfont__fontset_init): Add fontset_table as an object array.
1771         (mfont__realize_fontset): Ref FONTSET.
1772         (mfont__free_realized_fontset): Unref REALIZED->fontset.
1773         (mfontset): Call M17N_OBJECT_REGISTER.
1774         (mfontset_copy): Likewise.
1775
1776         * input.c (handle_key): For debugging, print information about
1777         alias key.
1778         (filter): Add an alias for Meta and Alt modifiers.
1779         (Mcond, Mplus, Mminus, Mstar, Mslush, Mand, Mor, Mnot): New
1780         variables.
1781         (minput__init): Initialize them.
1782         (parse_expression): New function.
1783         (resolve_expression): New function.
1784         (parse_action_list): Handle expressions by parse_expression.
1785         (take_action_list): Handle expressions by resolve_expression.
1786         (parse_nested_list_value): Fix previous change.
1787         (resolve_command): Fix handling of the return value of
1788         get_nested_list.
1789
1790 2005-11-18  Kenichi Handa  <handa@m17n.org>
1791
1792         * font-ft.c (ft_check_otf, otf_script_list): Define only when
1793         HAVE_OTF is defined.
1794         (ft_list_capability): Call ft_check_otf only when HAVE_OTF is
1795         defined.
1796         (ft_select): Likewise.
1797
1798         * font.c (mfont_list): Fix for the case that FONT is NULL.
1799         (OTF_tag): Delete it.
1800         (load_otf_script_list): Define only when HAVE_OTF is defined.
1801         (mfont__fini): Unref otf_script_list only when HAVE_OTF is
1802         defined.
1803
1804         * draw.c (truncate_gstring): Be sure to truncate at
1805         glapheme-cluster boundary.
1806
1807 2005-11-11  Kenichi Handa  <handa@m17n.org>
1808
1809         * input.c (delete_surrounding_text): Clear cache if necessary.
1810
1811 2005-11-09  Kenichi Handa  <handa@m17n.org>
1812
1813         * draw.c (compose_glyph_string): Update prev->rface->rfont if the
1814         glyph prev is also supported by the current flt.
1815
1816 2005-11-08  Kenichi Handa  <handa@m17n.org>
1817
1818         * m17n-X.c (xft_render): Cancel previous change.
1819
1820 2005-11-07  Kenichi Handa  <handa@m17n.org>
1821
1822         * input.c: Include <stdlib.h>.
1823         (get_surrounding_text, delete_surrounding_text)
1824         (get_preceding_char, get_following_char): New functions.
1825         (integer_value): New arg surrounding.  If it is nonzero, try to
1826         get a surrounding character.  Callers changed.
1827         (take_action_list): Check `value' before setting an element.
1828         (destroy_ic): Unref ic_info->preceding_text and
1829         ic_info->following_text.
1830         (minput__init): Initialize Minput_get_surrounding_text and
1831         Minput_delete_surrounding_text.
1832         (Minput_get_surrounding_text, Minput_delete_surrounding_text): New
1833         variables.
1834         (filter): Unref ic_info->preceding_text and
1835         ic_info->following_text.
1836
1837         * m17n.h (Minput_get_surrounding_text, Minput_delete_surrounding_text):
1838         Extern them.
1839
1840         * input.h (MInputContextInfo): New members preceding_text and
1841         following_text.
1842
1843 2005-11-04  Kenichi Handa  <handa@m17n.org>
1844
1845         * input.c (parse_nested_list_value): Fix handling of the global
1846         definition.
1847         (get_nested_list): Get global definitions by load_partial_im_info.
1848         (preedit_commit): Set ic->candidates_changed to bitwise or of enum
1849         MInputCandidatesChanged.
1850         (take_action_list): Likewise.
1851         (reset_ic): Likewise.
1852         (create_ic): Don't pay special attention to
1853         Mcandidates_group_size.
1854         (load_partial_im_info): Call mdatabase_find with correct 4th arg.
1855         (minput_set_variable): Get a definition of varible by
1856         mplist_find_by_value, not mplist_get.
1857
1858         * m17n.h (enum MInputCandidatesChanged): New enum.
1859
1860 2005-11-01  Kenichi Handa  <handa@m17n.org>
1861
1862         * m17n-X.c (xft_render): Check xft_draw's drawable before changing
1863         it.
1864         (mwin__destroy_window): If xft_draw's drawable is win, change it
1865         to device->drawable before destroying win.
1866
1867 2005-10-31  Kenichi Handa  <handa@m17n.org>
1868
1869         * input.c (load_im_info): Fix adding of state.
1870
1871         * m17n-core.c (m17n_fini_core): Fix reporting of module
1872         finalization.
1873
1874         * m17n.c (m17n_fini): Fix reporting of module finalization.
1875
1876         * m17n-gui.c (m17n_init_win): Fix reporting of module
1877         finalization.
1878
1879 2005-10-29  Kenichi Handa  <handa@m17n.org>
1880
1881         * input.c (get_candidate_list): Fix the timing of referring plist.
1882
1883 2005-10-28  Kenichi Handa  <handa@m17n.org>
1884
1885         * input.c (load_branch): Ignore an undefined map name.
1886         (load_im_info): Set im_info->title from `name' only if it's not
1887         Mnil.
1888         (shift_state): Always update ic->status.
1889         (adjust_candidates): Renamed from adjust_candidate_command.
1890         Argument changed.  Caller changed.
1891         (get_candidate_list, regularize_action): New functions.
1892         (take_action_list): Use them.  On handling Munhandle, don't set
1893         ic_info->used to 0.
1894         (handle_key): If KEY is not handled by MAP, and MAP has
1895         branch_actions, perform them.
1896
1897         * database.c (mdatabase__fini): Free dir_info->filename;
1898
1899 2005-10-20  Kenichi Handa  <handa@m17n.org>
1900
1901         * input.c (marker_code): Accept '@@'.
1902         (integer_value): Handle '@@'.
1903         (parse_action_list): Accept a symbol argument.
1904         (take_action_list): Resolve the symbol argument.  Handle the
1905         integer argument.
1906
1907 2005-10-18  Kenichi Handa  <handa@m17n.org>
1908
1909         * input.c: Include "charset.h".
1910         (M_candidates, Mcandidates_group_size, Mcandidates_charset): New
1911         variables.
1912         (MIMState): New member (M17NObject control).
1913         (lookup_nested_list, set_nested_list, parse_nested_list_value)
1914         (get_nested_list, resolve_variable): New functions.
1915         (integer_value): New arg (MPlist **value).  Set it to the plist
1916         element containing the value.
1917         (resolve_command): New function.
1918         (load_translation): New arg (MPlist *map_actions).
1919         (load_branch): New args language and name.  If `keylist' is a
1920         symbol, resolved that as a command name.
1921         (free_map): New arg top.  Free map->map_actions only if top is
1922         nonzero.
1923         (free_state): New function.
1924         (load_state): New arg name.
1925         (im_info_list): New variable.
1926         (free_im_info, get_im_info_by_tags): New functions.
1927         (load_im_info): Arg key changed to plist.  Handle `include'.
1928         Return (MInputMethodInfo *).
1929         (preedit_commit): Ref ic->candidate_list.
1930         (get_select_charset, adjust_candidate_command): New functions.
1931         (take_action_list): Handle `include'.  Adjust candidate action
1932         properly.  Handle control variables `candidates-charset' and
1933         `candidates-group-size'.
1934         (open_im): Use get_im_info.
1935         (create_ic): Get global variables.
1936         (load_partial_im_info): New function.
1937         (get_im_info): New function.
1938         (check_command_keyseq, check_command_list, check_variable_list):
1939         New functions.
1940         (minput__init): Don't handle M_database_hook and Mdetail_text.
1941         Initialize M_candidates, Mcandidates_group_size,
1942         Mcandidates_charset.
1943         (parse_variable_list, get_variable_list, parse_command_list)
1944         (get_command_list): Delete them.
1945         (MDatabaseStatList, imdir_stat_list, input_method_hook): Delete them.
1946         (minput__fini): Simply unref command_list and variable_list.
1947         (minput_get_description): Adjusted for the new form of description.
1948         (minput_get_commands): Use get_nested_list.
1949         (minput_assign_command_keys): Likewise.
1950         (minput_get_variables, minput_set_variable): Likewise.
1951
1952         * input.h (MInputMethodInfo): New members im and maps.
1953
1954         * database.h (M_database_hook): Delete extern.
1955         (MDatabaseHookFunc): Delete extern.
1956         (mdatabase__check): Extern it.
1957
1958         * database.c: Include <glob.h>.
1959         (MAX_TIME): New macro.
1960         (Masterisk): New variable.
1961         (get_database_stream): Argument changed to (MDatabaseInfo *).
1962         Callers changed.
1963         (get_dir_info): Renamed from duplicate_dirname.  Callers changed.
1964         (find_database): New function.
1965         (update_database_list): New function.
1966         (mdatabase__init): Initialize Masterisk.  Setup mdb_list by
1967         calling update_database_list.
1968         (mdatabase__check): New function.
1969         (mdatabase_find): Use update_database and find_database.  Don't
1970         handle MDatabaseHookFunc.
1971         (mdatabase_list): Call update_database at first.
1972         (mdatabase_define): Adjusted for the change of mdb->extra_info.
1973         (MDatabaseList): New type.
1974
1975         * plist.h (mplist_conv, mplist__pop_unref): Extern them.
1976
1977         * m17n.h (Mdetail_text): Delete extern.
1978
1979         * m17n-core.h (mplist_conc): Delete extern.
1980
1981         * plist.c (mplist__conc): Renamed from mplist_conc.  Don't ref
1982         tail.
1983         (mplist_conc): Renamed to mplist__conc.
1984         (mplist__pop_unref): New function.
1985
1986 2005-10-14  Kenichi Handa  <handa@m17n.org>
1987
1988         * plist.c (read_mtext_element): Ignore the sequence of '\\' and
1989         newline.
1990         (read_element): If keys is an empty plist, return any element
1991         found first.
1992         (dump_plist_element): Check if plist is nested.
1993         (mplist_conc): Always ref tail.
1994         (mplist_set): If key is a managing key, ref val in advance.
1995
1996         * plist.h (MPLIST_VAL_MANAGED_P): Delete this macro.
1997         (MPLIST_NESTED_P, MPLIST_SET_NESTED_P): New macros.
1998         (MPLIST_ADD_PLIST, MPLIST_PUSH_PLIST, MPLIST_PUT_PLIST): New
1999         macros.
2000
2001         * fontset.c (free_fontset): Unref fontset_list if necessary.
2002         (mfont__fontset_fini): Don't free fontset_list.  Unref
2003         default_fontset.
2004         (mfont__realize_fontset): Initialize request.
2005         (mfontset): Ref default_fontset or fontset only if necessary.
2006         (mfontset_copy): Don't ref copy.
2007
2008         * draw.c (render_glyphs): Check gend->type before checking
2009         gend->to.
2010
2011         * font-ft.c (mfont__ft_fini): Unref ft_default_list.  Set all
2012         unrefed plists to NULL.
2013
2014 2005-10-04  Kenichi Handa  <handa@m17n.org>
2015
2016         * textprop.c (mtext_serialize): Be sure to make mt
2017         MTEXT_FORMAT_UTF_8 and NULL terminated.
2018
2019         * m17n-gui.c (m17n_init_win): Initialize Mcolormap.
2020
2021         * draw.c (mdraw_glyph_list): Fix settting of glyphs->font->source.
2022
2023 2005-10-03  Kenichi Handa  <handa@m17n.org>
2024
2025         * draw.c (mdraw_glyph_info): Pay attention to the case that FROM
2026         is not at the beginning of line.
2027
2028 2005-09-22  Kenichi Handa  <handa@m17n.org>
2029
2030         * input.c: Include <sys/stat.h> and <unistd.h>.
2031         (Minclude, Mcommit, Munhandle): New variables.
2032         (minput__init): Initialize them.  Push only Mstate to
2033         load_im_info_keys.   Add aliases C-lowercase for C-uppercase.
2034         (parse_action_list): Allow integer arg for undo.  Handle Mcommit
2035         and Munhandle.
2036         (load_input_method): Handle "include" directive.  If no states are
2037         loaded, return -1.
2038         (shift_state): If state_name is Mt, shift back to the previous
2039         state.  Call preedit_commit to commit preedit text.
2040         (preedit_commit): New function.
2041         (take_action_list): Improve debug printing.  Handle commit and
2042         unhandle commands.
2043         (handle_key): Check the return value of take_action_list.  Don't
2044         take branch_actions just after changing to the root map.
2045         (reset_ic): Reset all ic_info members.
2046         (filter): When a key is not handled, just move ic_info->keys
2047         instead fo calling reset_ic.
2048         (load_im_info): If key is not Mstate, push Mmap to
2049         load_im_info_keys.
2050         (MDatabaseStatList): New type.
2051         (imdir_stat_list): New variable.
2052         (input_method_hook): Don't cancel the hook.  Check the
2053         modification time of directories.
2054         (minput__fini): Free imdir_stat_list;
2055
2056         * input.h (MInputContextInfo): New member prev_state.
2057
2058         * m17n-core.h (mplist_conc): Extern it.
2059
2060         * plist.c (mplist_conc): New function.
2061
2062         * mtext.c (mdebug_dump_mtext): Escape '"' and '\\' by '\\'.
2063
2064         * font.h (MRealizedFont): New member average_width.
2065
2066         * font-ft.c (ft_open): Set rface->average_width.
2067
2068         * font.c (xlfd_unparse_name): Print '*' before registry name.
2069
2070         * m17n-X.c (MDisplayInfo): New member AVERAGE_WIDTH.
2071         (xfont_open): Set rfont->average_width.
2072         (xft_open): Likewise.
2073         (device_open): Initialize disp_info->AVERAGE_WIDTH.
2074
2075         * internal-gui.h (struct MFrame): New member average_width.
2076
2077         * m17n-gui.c (mframe): Fix setting of frame->rfont.
2078         (mframe_get_prop): Return the average_width of a font.
2079
2080         * face.c (mface__realize): Set rface->average_width.
2081         (mface__update_frame_face): Set frame->average_width.
2082
2083         * face.h (MRealizedFace): New member average_width.
2084
2085 2005-09-19  Kenichi Handa  <handa@m17n.org>
2086
2087         * font.c (xlfd_unparse_name): New arg full_xlfd.
2088         (mfont__encode_char): Use shortcut only for X core fonts.
2089         (mfont_unparse_name): Call xlfd_unparse_name with full_xlfd arg 1.
2090         (mfont_put_prop): Handle `language' property.
2091         (mdebug_dump_font): Call xlfd_unparse_name with full_xlfd arg 0.
2092         Print file can capability info too.
2093
2094         * m17n-core.c (mdebug__output): New variable.
2095         (SET_DEBUG_FLAG): Unset mask if env_value is '0'.
2096         (m17n_init_core): Handle MDEBUG_ALL and MDEBUG_OUTPUT_FILE.
2097         (m17n_fini_core): Close mdebug__output if it's not stderr.
2098
2099         * m17n-X.c (MDisplayInfo): New member MULE_BASELINE_OFFSET.
2100         (xfont_open): Handle baseline_offset.
2101         (xfont_find_metric): Likewise.
2102         (xfont_render): Likewise.
2103         (xft_open): Likewise.
2104         (xft_render): Likewise.
2105
2106         * internal.h (MDebugMaskBit): Add MDEBUG_ALL.
2107         (mdebug__output): Extern it.
2108         (MDEBUG_PRINT, MDEBUG_PRINT1, MDEBUG_PRINT2, MDEBUG_PRINT3)
2109         (MDEBUG_PRINT4, MDEBUG_PRINT5): Print to medebug__output.
2110         (MDEBUG_DUMP): New macro.
2111         (MDEBUG_PRINT_TIME): Print to medebug__output.
2112
2113         * font.h (MRealizedFont): New member baseline_offset.
2114
2115         * font-ft.c (ft_get_charmaps): Check if the font support iso8859-1
2116         characters.
2117         (fc_weight_table): Add FC_WEIGHT_REGULAR.
2118         (ft_list_family): Check alias.
2119         (ft_list_language): If language is "en", don't try to the second
2120         step.
2121         (ft_default_list): New variable.
2122         (ft_list_default): New function.
2123         (ft_select): If family is not specified, try only the default
2124         fonts.  Treat the weights normal and medium same.
2125         (ft_open): Fix debug message.  If registry is not specified, try
2126         unicode-bmp.  Handle _MULE_BASELINE_OFFSET property of BDF fonts.
2127         (ft_find_metric): Likewise.
2128         (ft_render): Likewise.
2129         (ft_list): Fix debug message.  Accept the registring iso8859-1.
2130         If family is not specified, try only the default fonts.
2131
2132         * face.c (mface__realize): Fix logic of opening a font.
2133
2134 2005-09-16  Kenichi Handa  <handa@m17n.org>
2135
2136         * face.c (mface__realize): 
2137
2138         * m17n.h (Minput_focus_move, Minput_focus_in, Minput_focus_out):
2139         Extern them.
2140
2141         * input.c (shift_state): Fix the condition of taking init actions.
2142         (take_action_list): Fix handling of pushback action.
2143         (handle_key): Don't change key while checking its alias.
2144         (minput__init): Initialize new variables.
2145         (Minput_focus_move, Minput_focus_in, Minput_focus_out): New
2146         variables.
2147
2148 2005-09-12  Kenichi Handa  <handa@m17n.org>
2149
2150         * mtext.c (mtext__uppercase): Add proper open/close parens.
2151         (mtext_titlecase): Add proper casting.
2152
2153         * input.c (parse_action_list): Handle the case that the arg is a
2154         key sequence (MText or MPlist).
2155         (take_action_list): Likewise.
2156         (shift_state): Shorter debug message.
2157         (handle_key): Terminate a debug message by "\n".
2158         (reset_ic): Don't take initial actions here.
2159         (minput_open_im): Print a debug message.
2160         (minput_close_im): Likewise.
2161         (minput_create_ic): Likewise.
2162         (minput_destroy_ic): Likewise.
2163
2164 2005-09-09  TAKAHASHI Naoto  <ntakahas@m17n.org>
2165
2166         * mtext.c (mtext_lowercase, mtext_titlecase, mtext_uppercase):
2167         Change API.
2168
2169 2005-09-07  TAKAHASHI Naoto  <ntakahas@m17n.org>
2170         * character.c: Add "cased", "soft-dotted", and "case-mapping" in
2171         mchar__init ().
2172
2173         * character.c: Add Japanese documentation for
2174         mchar_get_prop_table ().
2175
2176 2005-09-06  TAKAHASHI Naoto  <ntakahas@m17n.org>
2177
2178         * mtext.c (tricky_chars, *cased, *soft_dotted, *case_mapping)
2179         (MCharTable *combining_class, Mlt, Mtr, Maz, gr03A3, lt0049,
2180         (lt004A, lt012E, lt00CC, lt00CD, lt0128, tr0130, tr0049, tr0069):
2181         New variables.
2182         (init_case_conversion): New function.
2183         (CASE_CONV_INIT, REPLACE, DELETE, LOOKUP): New macros.
2184         (uppercase_precheck, lowercase_precheck, final_sigma)
2185         (after_soft_dotted, more_above, before_dot, after_i)
2186         (mtext_uppercase, mtext_titlecase, mtext_lowercase): New functions.
2187
2188 2005-09-05  TAKAHASHI Naoto  <ntakahas@m17n.org>
2189
2190         * plist.c (read_mtext_element): Fix previous change.
2191
2192 2005-09-05  Kenichi Handa  <handa@m17n.org>
2193
2194         * plist.c (read_mtext_element): Handle \uXXXX notation.
2195
2196         * internal.h (MTABLE_MALLOC): Don't use a local variable.
2197         (MTABLE_ALLOCA): Change the name of local variable.
2198
2199         * m17n-gd.c (device_open): Define it even if HAVE_GD nor
2200         HAVE_FREETYPE are defined.
2201
2202         * m17n-X.c: Check HAVE_X11.
2203
2204         * Makefile.am (X_LD_FLAGS): Use @X11_LD_FLAGS@ instead of
2205         directory listing libraries.
2206         (noinst_PROGRAMS): Define it only in maintainer mode.
2207
2208 2005-09-02  Kenichi Handa  <handa@m17n.org>
2209
2210         * m17n-gui.h (mdraw_line_break_option): Extern it.
2211
2212         * draw.c (truncate_gstring): Use find_glyph_in_gstring to find the
2213         end of the first glyph.
2214         (GET_LB_TYPE, find_break_backward, find_break_forward): Delete
2215         them.
2216         (mdraw_line_break_option): New variable.
2217         (mdraw_default_line_break): Use mtext_line_break.
2218
2219         * mtext.h (wordseg_func_table): Don't extern it.
2220         (mtext__wseg_fini): Extern it.
2221
2222         * mtext.c: Don't include word-thai.h.
2223         (wordseg_func_table): Delete this variable.
2224         (mtext__init): Don't initialize above.  Don't call
2225         mtext__word_thai_init.
2226         (mtext__fini): Don't free wordseg_func_table.  Call
2227         mtext__wseg_fini instead fo mtext__word_thai_fini.
2228         (MTextWordsegFunc): Don't typedef it.
2229         (mtext__word_segment): Moved to mtext-wseg.c.
2230
2231         * m17n-core.h (enum MTextLineBreakOption): New enum.
2232         (mtext_line_break): Extern it.
2233
2234         * mtext-wseg.c: New file.
2235
2236         * mtext-lbrk.c: New file.
2237
2238         * Makefile.am (libm17n_core_la_SOURCES): Delete word-thai.[ch],
2239         add mtext-lbrk.c and mtext-wseg.c.
2240
2241         * textprop.c (mtext__adjust_plist_for_change): Pay attention for
2242         the case that head is NULL.
2243
2244 2005-09-01  Kenichi Handa  <handa@m17n.org>
2245
2246         * word-thai.c (wordseg_propertize): If the property value is nil,
2247         don't make the property no-merge.
2248         (thai_wordseg): Don't require *from and *to are set a priori.  Pay
2249         attention to the case that they are NULL.
2250         (mtext__word_thai_init): Make the name of Mthai_wordseg starts
2251         with two spaces.
2252
2253         * character.c (mchar_get_prop_table): New function.
2254
2255         * textprop.h (mtext__adjust_plist_for_change): Prototype adjusted.
2256
2257         * m17n-core.h (mtext_insert, mtext_replace): Extern them.
2258         (mchar_get_prop_table): Extern it.
2259
2260         * textprop.c (prepare_to_modify): New arg deleting.  Callers changed.
2261         (mtext__adjust_plist_for_change): Argument changed.  Callers changed.
2262
2263         * internal.h (enum MTextCoverage): New enum.
2264         (MText): New member coverage.
2265
2266         * mtext.c (FORMAT_COVERAGE): New macro.
2267         (insert): Copy mt2->coverage.
2268         (mtext__from_data): Initialize mt->coverage.
2269         (mtext__adjust_format): Update mt->coverage.
2270         (mtext): Initialize mt->coverage.
2271         (mtext_set_char): Adjust args to mtext__adjust_plist_for_change.
2272         Update mt->coverage if necessary.
2273         (mtext_duplicate): Copy mt->coverage.
2274         (mtext_insert, mtext_replace): New functions.
2275         (mtext_dup): Use mtext_duplicate.
2276         (mtext__word_segment): Don't set *from and *to if a word
2277         segmentation funcion is not found.
2278         (mtext_ins_char): Fix typo.
2279
2280 2005-08-25  Kenichi Handa  <handa@m17n.org>
2281
2282         * font.h (MFont): New member for_full_width.
2283
2284         * font.c (compare_font_score): Prefer a font of not
2285         for_full_width.
2286
2287         * m17n-X.c (xfont_registry_list): Set font.for_full_width if the
2288         registry charset of a font is one of CJK charsets.
2289
2290         * font-ft.c (fc_parse_pattern): Set font->for_full_width if a font
2291         supports some of CJK.
2292
2293 2005-08-24  Kenichi Handa  <handa@m17n.org>
2294
2295         * m17n-gui.h (Mascent, Mdescent): Don't extern them.
2296
2297         * m17n-gui.c (null_device_open): Check Mresolution param and set
2298         frame->dpi.
2299
2300         * m17n-gd.c (device_open): Check Mresolution param and set
2301         frame->dpi.
2302
2303         * m17n-X.c (MWDevice): New member resy.
2304         (xfont_open): Set ascent, descent, and max_advance members of
2305         rfont.
2306         (xft_open): Likewise.
2307         (device_open): Compare also screen_num to find a device.  Set
2308         device->resy and frame->dpi.
2309
2310         * internal-gui.h (MFrame): New member dpi.
2311
2312         * font.h (MRealizedFont): New member max_advance.
2313
2314         * font.c (xlfd_unparse_name): Handle the case of font->size < 0.
2315         (mfont__init): Don't initialize Mascent, Mdescent.
2316         (Mascent, Mdescent): Delete these variables.
2317         (mfont_get_prop): Fix previous change.  Check Mfont_ascent and
2318         Mfont_descent instead of Mascent and Mdescent.
2319         (mfont_put_prop): Allow negative size.
2320         (mfont_find): Handle the case of spec->size < 0.  Fix previous
2321         change.
2322         (mfont_list): Handle the case of spec->size < 0.
2323         (mfont_check): Likewise.
2324
2325         * font-ft.c (STRDUP_LOWER): Ignore the tailing spaces.
2326         (fc_get_pattern): Handle the case of font->size < 0.
2327         (ft_open): Set ascent, descent, and max_advance members of rfont.
2328         (ft_find_metric): Improve rounding.
2329         (mfont__ft_parse_name): If FC_PIXEL_SIZE is not available, set
2330         FC_SIZE.
2331
2332         * face.c (mface__realize): Handle the case of font->size < 0.
2333
2334 2005-08-22  Kenichi Handa  <handa@m17n.org>
2335
2336         * coding.c (MConverterStatus): Change the member buf to union.
2337         (mconv_buffer_converter): Add const to the arg buf.
2338         (mconv_decode_buffer, mconv_rebind_buffer): Likewise.
2339         (mconv_decode): Adjusted for the change of MConverterStatus.
2340         (mconv_encode_range): Likewise.
2341
2342         * m17n.h (mconv_buffer_converter): Prototype adjusted.
2343         (mconv_decode_buffer, mconv_rebind_buffer): Likewise.
2344
2345 2005-08-20  Kenichi Handa  <handa@m17n.org>
2346
2347         * m17n-gui.h (mfont_from_name): Prototype adjusted.
2348         (Mspacing, Mascent, Mdescent, Mmax_advance): Extern them.
2349
2350         * m17n-X.c (xfont_open): Set members ascent, descent, and
2351         max_advance of rfont.
2352         (xft_open): Likewise.
2353
2354         * font-ft.c (ft_open): Set members ascent, descent, and max_advance
2355         of rfont.
2356         (mfont__ft_parse_name): Add const to the arg name.
2357
2358         * font.c (xlfd_parse_name): Add const to the arg name.  Call
2359         mfont__set_property instead of mfont_set_spec.  Set font->spacing.
2360         (xlfd_unparse_name): Handle spacing.
2361         (mfont__init): Initialize new variables.
2362         (mfont__id): Handle spacing.
2363         (mfont__merge): Likewise.
2364         (mfont__set_spec): This function deleted.
2365         (mfont__parse_name_into_font): Add const to the arg name.  Fix the
2366         condition of calling mfont__ft_parse_name.
2367         (Mspacing, Mascent, Mdescent, Mmax_advance): New variables.
2368         (mfont_get_prop): Handle properties spacing, ascent, descent,
2369         and max-advance.
2370         (mfont_find): Return a realized font.
2371         (mfont_from_name): Add const to the arg name.
2372
2373         * font.h (enum MFontProperty): New member MFONT_SPACING.
2374         (enum MFontSpacing): New enum.
2375         (MFont): New members spacing and max_advance.
2376         (mfont__ft_parse_name): Prototype adjusted.
2377         (mfont__set_spec): Extern deleted.
2378         (mfont__parse_name_into_font): Prototype adjusted.
2379
2380 2005-08-19  Kenichi Handa  <handa@m17n.org>
2381
2382         * m17n-gui.h (mfont_parse_name): Prototype adjusted.
2383
2384         * font.c (mfont_list): If FONT is null, use a temporary font.
2385         (mfont_parse_name): Add const to the arg name.
2386
2387 2005-08-18  Kenichi Handa  <handa@m17n.org>
2388
2389         * word-thai.c: Surround code by #ifdef and #endif to escape from
2390         doxygen.
2391
2392         * font-ft.c: Mostly re-written.
2393
2394         * font-flt.c (FontLayoutCmdOTF): This type deleted.
2395         (FontLayoutCmd): Type of the member otf changed..
2396         (load_otf_command): Adjusted for the format change of otf command.
2397         (load_command): Likewise.
2398         (free_flt_command): Unref cmd->body.otf.
2399         (run_otf): Ajusted for the type change of otf_cmd.
2400         (run_command): Ajusted for the type change of otf_cmd.  On
2401         debugging, print ctx->combining_code.
2402         (mfont__flt_run): Initialize ctx's members code_offset,
2403         combining_code, and left_padding to 0.
2404
2405         * face.h (struct MRealizedFace): New member font.
2406         (mface__realize): Prototype adjusted.
2407
2408         * face.c (find_realized_face): New arg font.
2409         (find_realized_face): Adjusted for the change of MFont.
2410         (mface__init): Call M17N_OBJECT_ADD_ARRAY.
2411         (mface__fini): Don't call mdebug__report_object.
2412         (mface__realize): New arg font.
2413         (mface__for_chars): Adjusted for the change of mfont__encode_char.
2414         Optimize the latin case.
2415         (mface__free_realized): Free rface->font.
2416         (mface__update_frame_face): Adjusted for the change of mface__realize.
2417         (mface_equal): New function.
2418
2419         * draw.c (Mcommon): New variable.
2420         (visual_order): Args to mfont__encode_char changed.
2421         (compose_glyph_string): Handle Mfont text property.
2422         (layout_glyphs): Adjusted for the change of MFont.
2423         (mdraw__init): Initialize Mcommon.
2424         (mdraw_glyph_info): Adjusted for the change of MRealizedFont.
2425
2426         * font.h (enum MFontType): Members completely changed.
2427         (enum MFontProperty): Move MFONT_SIZE to the tail.
2428         (enum MFontSource): New enum.
2429         (struct MFont): New members type, source, sizes, file, capability,
2430         and encoding.
2431         (struct MRealizedFont): Type of member font changed. Members
2432         score, status, and encoding deleted.
2433         (MFontScore): New type.
2434         (MFontList): Member changed.
2435         (struct MFontDriver): New member has_char.  Types of members
2436         changed.
2437         (Miso8859_1, Miso10646_1, Municode_bmp, Municode_full)
2438         (Mapple_roman): Extern them.
2439         (OTF_Tag): Typedefed if not HAVE_OTF.
2440         (enum MFontOpenTypeTable): New enum.
2441         (MFontCapability): New type.
2442         (mfont__ft_drive_otf): Prototype adjusted.
2443         (mfont__score): Extern deleted.
2444         (mfont__merge): Extern it.
2445         (mfont__has_char): Extern it.
2446         (mfont__encode_char): Prototype adjusted.
2447         (mfont__open): Extern it.
2448         (mfont__set_spec): Prototype adjusted.
2449         (mfont__get_capability): Extern it.
2450
2451         * font.c: Include "fontset.h".
2452         (M_font_capability, M_font_list, M_font_list_len): New variables.
2453         (font_score_priority): Change order of initial elements.
2454         (font_score_shift_bits): Fix array size.
2455         (common_weight): Add "thin", "semibold", and "heavy".
2456         (common_stretch): Add "ultracondensed", "extracondensed",
2457         "extraexpanded", and "utltraexpand".
2458         (font_weight_regular, font_weight_normal, font_weight_medium): New
2459         variables.
2460         (gen_font_name): This function deleted.
2461         (find_encoding): Set font->encoding.
2462         (OTF_tag): New function.
2463         (otf_script_list): New variable.
2464         (load_otf_script_list): New function.
2465         (find_script_from_otf_tag): New function.
2466         (xlfd_parse_name): Set font->type and font->source.
2467         (mfont__free_realized): Free chains rfonts.
2468         (font_score): Renamed from mfont__score.
2469         (Miso8859_1, Miso10646_1, Municode_bmp, Municode_full)
2470         (Mapple_roman): New variables.
2471         (mfont__init): Initilize new variables.  Initalize
2472         default_encoding.encoding_name and
2473         default_encoding.encoding_charset to Municode_full and
2474         mcharset__unicode.  Use SAFE* macros for allocating filepath
2475         buffer.
2476         (mfont__fini): Free otf_script_list.
2477         (mfont__id): New function.
2478         (mfont__match_p): Check also capability member of MFont.
2479         (mfont__merge): New funciton.
2480         (mfont__set_spec_from_face): Set type and source members.
2481         (mfont__set_spec_from_plist): Set capability and type members.
2482         (mfont__select): Argument changed.
2483         (mfont__available): New function.
2484         (compare_font_score): New function.
2485         (mfont__list): New function.
2486         (mfont__open): Return a realized font.
2487         (mfont__resize): Adjusted for the change of MFont.
2488         (mfont__has_char): New function.
2489         (mfont__encode_char): Argument changed.
2490         (mfont__set_spec): Argument changed.
2491         (free_font_capability): New function.
2492         (mfont__get_capability): New function.
2493         (MFontfile): New variable.
2494         (mfont_get_prop): Adjusted for the change of MFont.
2495         (mfont_put_prop): Likewise.
2496         (mfont_set_selection_priority): Fix the way of setting
2497         font_score_priority[].
2498         (mfont_find): Use mfont__list instead of mfont__select.
2499         (mfont_resize_ratio): Adjusted for the change of MFont.
2500         (mfont_list): Use mfont__list.
2501         (mfont_check): New function.
2502         (font_score): Make it static.
2503
2504         * fontset.h (mfont__realize_fontset): Prototype adjusted.
2505         (mfont__lookup_fontset): Likewise.
2506
2507         * fontset.c (struct MFontset): Delete member font_spec_list.
2508         (struct MRealizedFontset): Type of member spec changed.  New
2509         member request.
2510         (load_font_group): Arg spec_list deleted.
2511         (load_fontset_contents): Adjusted for the change of fontset_def.
2512         (free_fontset): Fix the way of freeing fontset elements.
2513         (realize_fontset_elements): Argument changed.
2514         (get_per_script): New function.
2515         (free_realized_fontset_elements): Fix the way of feeing rfontset
2516         elements.
2517         (update_fontset_elements): Fix args to realize_fontset_elements.
2518         (mfont__realize_fontset): New arg spec.
2519         (try_font_list): New function.
2520         (try_font_group): New arg request.  Use try_font_list.
2521         (mfont__lookup_fontset): New arg ignore_fallback.  Fix arg to
2522         try_font_group.
2523         (mfontset): Adjusted for the change of MFontset.
2524         (mfontset_copy): Likewise.  Don't share plists.
2525         (mfontset_modify_entry): Adjusted for the change of MFontset.
2526         (mfontset_lookup): Call get_per_script.
2527         (mdebug_dump_fontset): Print also the address of fonts.
2528
2529         * input.c (shift_state): Don't reset ic_info->vars.
2530         (take_action_list): Call MDEBUG_PRINT fore calling
2531         take_action_list.
2532
2533         * internal-gui.h (MFontDriver): Don't typedef it here.
2534
2535         * m17n-X.c: Include <fontconfig/fcfreetype.h> if HAVE_XFT2.
2536         (MXFont): This type deleted.
2537         (MFontX): New type.
2538         (struct _MFontX): New struct.
2539         (SET_SIZE, HAVE_SIZE): Adjusted for the change of arg FONTX.
2540         (MDisplayInfo): Member base_font_list deleted.
2541         (DEFAULT_FONT): Definition changed.
2542         (FALLBACK_FONT): This maclr deleted.
2543         (free_display_info): Adjusted for the change of MDisplayInfo.
2544         (free_device): Argument to mfont__free_realized changed.
2545         (xfont_driver): Adjusted for the change of MFontDriver.
2546         (xfont_registry_list): Use MFontX instead of MXFont.
2547         (MRealizedFontX): Renamed from MXFontInfo.
2548         (xfont_select): Return the font found first.
2549         (close_xfont): Change MXFontInfo to MRealizedFontX.
2550         (xfont_open): Return the realized font.
2551         (xfont_find_metric): Get xfont from rfont->fontp.
2552         (xfont_has_char): New function.
2553         (xfont_encode_char): Adjusted for the argument change.
2554         (xfont_render): Get xfont from rfont->fontp.
2555         (xfont_list): Adjusted for the argument change.
2556         (MRealizedFontXft): Renamed from MXftFontInfo.
2557         (xft_driver): Ajusted for the change of MFontDriver.
2558         (close_xft): Change MXtfFontInfo to MRealizedFontXft
2559         (xft_open_font): Argument changed.
2560         (xft_open): Argument changed.  Return the realized font.
2561         (xft_find_metric): Get xft_font from rfont->fontp.
2562         (xft_has_char, xft_encode_char): New functions.
2563         (xft_render): Change MXftFontInfo to MRealizedFontXft.  Open a
2564         font if not yet opened.
2565         (device_open): Don't set frame->font.
2566
2567         * m17n-gd.c (gd_font_driver): Adjusted for the change of
2568         MFontDriver.
2569         (gd_font_open): New function.
2570         (gd_render): Don't use the local variable ft_info.
2571         (device_init): Adjusted for the change of gd_font_driver.
2572
2573         * textprop.c (mtext__prop_init): Initialize text_property_table.
2574         Call M17N_OBJECT_ADD_ARRAY.
2575         (mtext__prop_fini): Don't call mdebug__report_object.
2576
2577         * plist.c (mplist__init): Initialize plist_table.
2578         (mplist__init): Call M17N_OBJECT_ADD_ARRAY.
2579         (mplist__fini): Don't call mdebug__report_object.
2580
2581         * mtext.c (mtext__init): Call M17N_OBJECT_ADD_ARRAY.
2582         (mtext__fini): Don't call mdebug__report_object.
2583         (MTEXT_FORMAT_UTF_16): Correct type.
2584         (mtext_data): New function.
2585         (mtext_text): Fix calculation of limit and args to
2586         find_char_backward.
2587
2588         * language.c: Include "plist.h".
2589         (M_script_lang_list): New variable.
2590         (mlang__init): Read languages and their information from m17n
2591         database.
2592         (mlanguage__list): New function.
2593         (Miso639_1, Miso639_2): New variables.
2594
2595         * language.h (mlanguage__list): Extern it.
2596
2597         * database.c (get_database_stream): Use SAFE_* macros for
2598         allocating and freeing path.
2599         (mdatabase__init): Likewise.
2600
2601         * symbol.c (msymbol__fini): Don't free symbols here.
2602         (msymbol__free_table): New function.
2603         (msymbol_is_managing_key): New function.
2604
2605         * symbol.h (msymbol__free_table): Extern it.
2606         (msymbol__list): Extern it.
2607
2608         * internal.h (MFATAL, USE_SAFE_ALLOCA, SAFE_ALLOCA, SAFE_FREE):
2609         New macros.
2610         (M17N_OBJECT_UNREF): Change "if ... else ..." structure.
2611         (struct _M17NObjectArray): New member name and next.
2612         (mdebug__add_object_array): Extern it.
2613         (M17N_OBJECT_ADD_ARRAY): New macro.
2614         (mdebug__report_object): Don't extern it.
2615
2616         * m17n-misc.h (enum MErrorCode): New element MERROR_FONT_X.
2617
2618         * m17n-gui.c (free_frame): Don't free frame->font.
2619         (null_device_fini): Fix code for freeing
2620         null_device.realized_font_list.
2621         (m17n_fini_win): Free interface.
2622         (mframe): Cast the return value of dlsym.  Set frame->font here.
2623         (mframe_get_prop): Check frame->rface->rfont before accessing the
2624         member font.
2625
2626         * m17n-gui.h (Mfontfile): Extern it.
2627         (mfont_check): Extern it.
2628         (mface_equal): Extern it.
2629
2630         * m17n-core.c: Include "symbol.h".
2631         (report_header_printed): This variable deleted.
2632         (object_array_root): New variable.
2633         (report_object_array): New function.
2634         (mdebug__report_object): This function deleted.
2635         (mdebug__add_object_array): New function.
2636         (m17n_init_core): Call mchartable_init () before mtext_init ().
2637         (m17n_fini_core): Call report_object_array (if necessary) and
2638         msymbol__free_atable at the end.
2639
2640         * m17n-core.h (msymbol_is_managing_key): Extern it.
2641         (mtext_data): Extern it.
2642         (MTEXT_FORMAT_UTF_16): Correct type.
2643         (M17NLIB_MINOR_VERSION): Changed to 3.
2644         (M17NLIB_VERSION_NAME): Changed to "1.3.0".
2645         
2646         * chartab.c (mchartable__init): Initalize chartable_table.count.
2647         (mchartable__fini): Use N17N_OBJECT_ADD_ARRAY instead of
2648         mdebug__report_object.
2649
2650 2005-05-26  Kenichi Handa  <handa@m17n.org>
2651
2652         * m17n.h (Miso639_1, Miso639_2): Extern them.
2653
2654         * symbol.h (msymbol__list): Extern it.
2655
2656         * symbol.c (msymbol__list): New function.
2657
2658 2005-05-19  Kenichi Handa  <handa@m17n.org>
2659
2660         * input-gui.c (minput__win_init): Don't change the value of
2661         minput_driver.
2662
2663 2005-05-16  Kenichi Handa  <handa@m17n.org>
2664
2665         * m17n-core.c (m17n_object): Be sure to initialize all members.
2666
2667         * font-ft.c (fc_decode_prop): Fix args to msymbol.
2668
2669 2005-05-09  Kenichi Handa  <handa@m17n.org>
2670
2671         * m17n-X.c (mwin__close_device): Fix arg to M17N_OBJECT_UNREF.
2672
2673 2005-04-27  Kenichi Handa  <handa@m17n.org>
2674
2675         * language.c (mlang__init): Add "an" (Aragonese).
2676
2677         * word-thai.c: Add support for libthai.
2678         (mtext__word_thai_init): Initialize wordseg library conditionaly.
2679         (mtext__word_thai_fini): Finalize wordseg library conditionaly.
2680
2681         * mtext.c: Include "word-thai.h" conditionaly.
2682         (mtext__init): Call mtext__word_thai_init conditionaly.
2683         (mtext__fini): Call mtext__word_thai_fini conditionaly.
2684
2685         * Makefile.am (libm17n_core_la_LIBADD): Add THAI_WORDSEG_LD_FLAGS,
2686         not WORDCUT_LD_FLAGS.
2687
2688 2005-04-19  Kenichi Handa  <handa@m17n.org>
2689
2690         * word-thai.c (wordseg_propertize): Always unref the attached
2691         property.
2692         (thai_wordseg): Don't unref the property.
2693
2694 2005-04-18  Kenichi Handa  <handa@m17n.org>
2695
2696         * word-thai.c: Include stdlib.h.
2697         (wordseg_propertize): Add dummy function for the case that wordcut
2698         library doesn't exist.
2699         (wordseg_propertize): Fix for old wordcut library.
2700
2701 2005-04-16  Kenichi Handa  <handa@m17n.org>
2702
2703         * word-thai.c: Include <stdio.h>.
2704
2705 2005-04-15  Kenichi Handa  <handa@m17n.org>
2706
2707         * draw.c: Include mtext.h.
2708         (linebreak_table, M_break_at_space, M_break_at_word)
2709         (M_break_at_any, M_kinsoku_bol, M_kinsoku_eol): New variables.
2710         (compose_glyph_string): Check POS before getting Mface text
2711         property.
2712         (truncate_gstring): Give correct TO arg to line_break function.
2713         (GET_LB_TYPE): New macro.
2714         (find_break_backward, find_break_forward): New functions.
2715         (mdraw__init): Initialize the above new variables.
2716         (mdraw__fini): Free linebreak_table.
2717         (mdraw_default_line_break): Use find_break_backward and
2718         find_break_forward.
2719
2720         * word-thai.c: New file.
2721
2722         * word-thai.h: New file.
2723
2724         * mtext.c: Include word-thai.h.
2725         (wordseg_func_table): New variable.
2726         (mtext__init): Initialize wordseg_func_table and call
2727         mtext__word_thai_init.
2728         (mtext__fini): Call mtext__word_thai_fini, free
2729         wordseg_func_table.
2730         (MTextWordsegFunc): New type.
2731         (mtext__word_segment): New function.
2732
2733         * mtext.h (wordseg_func_table): Extern it.
2734         (mtext__word_segment): Extern it.
2735
2736         * m17n.c (m17n_init): Fix typo (== -> =).
2737
2738         * Makefile.am (libm17n_core_la_SOURCES): Include word-thai.[ch].
2739         (libm17n_core_la_LIBADD): Add @WORDCUT_LD_FLAGS@.
2740
2741         * textprop.h (MTEXTPROP_START, MTEXTPROP_END, MTEXTPROP_KEY)
2742         (MTEXTPROP_VAL): New macros.
2743
2744         * input.c (DLOPEN_SHLIB_EXT): Don't define it.
2745
2746 2005-04-07  Kenichi Handa  <handa@m17n.org>
2747
2748         * database.c (load_chartable): Fix pursing of symbol name.
2749
2750 2005-03-24  Kenichi Handa  <handa@m17n.org>
2751
2752         * m17n.c (m17n_init): Fix typo (== -> =).
2753
2754 2005-03-11  Kenichi Handa  <handa@m17n.org>
2755
2756         * m17n-gui.c (m17n_init_win): Set merror_code to MERROR_NONE at first.
2757
2758         * m17n.c (m17n_init): Set merror_code to MERROR_NONE at first.
2759
2760         * m17n-core.c (m17n_init_core): Set merror_code to MERROR_NONE at
2761         first.
2762
2763 2005-03-09  handa  <handa@m17n.org>
2764
2765         * m17n-gui.c (m17n_init_win): Set merror_code to MERROR_NONE before
2766         calling m17n_init ().
2767
2768         * m17n.c (m17n_init): Set merror_code to MERROR_NONE before
2769         calling m17n_init_core ().
2770
2771 2005-02-28  Kenichi Handa  <handa@m17n.org>
2772
2773         * font-flt.c (mfont__flt_run): Add resulting code sequence in
2774         debug info.
2775
2776 2005-02-17  Kenichi Handa  <handa@m17n.org>
2777
2778         * input.c: Include <sys/types.h>, <dirent.h>, and "database.h".
2779         (M_description, M_command, M_variable): New variables.
2780         (load_im_info_keys): New variables.
2781         (load_im_info, check_command_keyseq, get_description_advance)
2782         (parse_command_list, get_command_list, parse_variable_list)
2783         (get_variable_list, input_method_hook): New functions.
2784         (command_list, variable_list): New variables.
2785         (minput__init): Put input_method_hook to Minput_method.
2786         Initialize M_description, M_command, M_variable, Mdetail_text,
2787         load_im_info_keys, command_list, variable_list.
2788         (minput__fini): Unref command_list, variable_list, load_im_info_keys.
2789         (Mdetail_text): New variable.
2790         (minput_get_description, minput_get_commands)
2791         (minput_assign_command_keys, minput_get_variables)
2792         (minput_set_variable): New functions.
2793
2794         * m17n.h (Mdetail_text, minput_get_description, minput_get_commands)
2795         (minput_assign_command_keys, minput_get_variables)
2796         (minput_set_variable): Extern them.
2797
2798         * plist.c (UNGETC): Just decrement st->p.
2799         (read_mtext_element): New arg skip.
2800         (read_integer_element): Likewise.
2801         (read_symbol_element): Likewise.
2802         (read_element): New arg KEYS.
2803         (mplist__from_plist): Don't increment ref-count of NULL object.
2804         (mplist__from_file): New arg KEYS.
2805         (mplist_put): Don't increment ref-count of NULL object.
2806         (mplist_add): Likewise.
2807         (mplist_push): Likewise.
2808         (mplist_set): Likewise.  Call M17N_OBJECT_UNREF unconditionally.
2809
2810         * plist.h (mplist__from_file): Prototype adjusted.
2811
2812         * database.c (mdatabase__dir_list): Renamed from mdb_dir_list.
2813         (get_database_stream): New function.
2814         (load_database): Use get_database_stream.
2815         (M_database_hook): New variable
2816         (mdatabase__init): Initialize M_database_hook.
2817         (mdatabase__load_for_keys): New function.
2818         (mdatabase_find, mdatabase_list, mdatabase_define): Check hook
2819         function.
2820         (mdatabase_define): Free mdb->extra_info if necessary.
2821
2822         * database.h (mdatabase__dir_list, M_database_hook)
2823         (mdatabase__load_for_keys): Extern them.
2824         (MDatabaseHookFunc): New type.
2825
2826         * internal.h (M17N_OBJECT_UNREF): When freed, set OBJECT to NULL.
2827
2828 2004-12-27  Kenichi Handa  <handa@m17n.org>
2829
2830         * Version 1.2.0 released.
2831
2832 2004-12-27  Kenichi Handa  <handa@m17n.org>
2833
2834         * input.c (minput_filter): Don't reset ic->xxx_changed.
2835
2836         * mtext.c (mtext_from_data): Fix documentation.
2837
2838 2004-12-25  Kenichi Handa  <handa@m17n.org>
2839
2840         * m17n-core.h (M17NLIB_MINOR_VERSION): Update to 2.
2841         (M17NLIB_VERSION_NAME): Update to "1.2.".
2842
2843 2004-12-24  Kenichi Handa  <handa@m17n.org>
2844
2845         * input.c (reset_ic): Set key_unhandled to 0.
2846
2847 2004-12-21  Kenichi Handa  <handa@m17n.org>
2848
2849         * m17n-gui.h (mfont_from_spec): Delete extern.
2850
2851         * input-gui.c (win_callback): Handle Minput_reset.
2852         (minput__win_init): Register reset_ic as a callback for
2853         Minput_reset.
2854
2855         * input.c (reset_ic): New arg IGNORE which is ignored.  Caller
2856         changed.  At first, shift to the initial state.
2857         (minput__init): Initialize Minput_reset.  Register reset_ic as a
2858         callback for Minput_reset.
2859         (Minput_reset): New variable.
2860         (minput_filter): Always set ic->xxx_changed to 0.
2861         (minput_reset_ic): New function.
2862         (integer_value): Fix typo ('>' -> '<') and calculation of length
2863         of preedit text.
2864
2865         * m17n-core.c (merror_code): Change type to `int'.
2866
2867         * m17n-misc.h (merror_code): Adjust type.
2868
2869         * m17n.h (Minput_reset, minput_reset_ic): Extern them.
2870
2871         * m17n-core.h (MTEXT_FORMAT_UTF_16, MTEXT_FORMAT_UTF_32): Adjust types.
2872         (mtext_change_prop): Delete extern.
2873
2874         * mtext.c (MTEXT_FORMAT_UTF_16, MTEXT_FORMAT_UTF_32): Change types
2875         to `int'.  Move the documents to m17n-core.h.
2876
2877 2004-12-13  Kenichi Handa  <handa@m17n.org>
2878
2879         * m17n-core.h (m17n_object): Rename extern from m17n_object_setup.
2880         (MTextProperty): Document it.
2881
2882 2004-12-09  Kenichi Handa  <handa@m17n.org>
2883
2884         * m17n-core.h: Fix typo (MTextStatus -> M17NStatus).
2885
2886 2004-12-03  Kenichi Handa  <handa@m17n.org>
2887
2888         * internal.h (m17n__core_initialized, m17n__shell_initialized,
2889         m17n__gui_initialized): New externs.
2890
2891         * m17n-core.h (enum M17NStatus): New enum.
2892         (m17n_status): Extern it.
2893
2894         * m17n-core.c (core_initialized): Delete this variable.
2895         (m17n__core_initialized, m17n__shell_initialized,
2896         m17n__gui_initialized): New variables.
2897         (m17n_init_core, m17n_fini_core): Check m17n__core_initialized
2898         instead of core_initialized.
2899         (m17n_status): New function.
2900
2901         * m17n.c (shell_initialized): Delete this variable.
2902         (m17n_init, m17n_fini): Check m17n__shell_initialized instead of
2903         shell_initialized.
2904
2905         * m17n-gui.h (m17n_init_win): Adjust the prototype.
2906
2907         * m17n-gui.c (win_initialized): Delete this variable.
2908         (m17n_init_win, m17n_fini_win): Check m17n__gui_initialized
2909         instead of gui_initialized.
2910
2911 2004-11-19  Kenichi Handa  <handa@m17n.org>
2912
2913         * input.c (reset_ic): Check if ic_info->state is NULL.
2914         (filter): If ic_info->state is NULL, return 0.
2915         (load_input_method): Don't unref `maps' it it's not created.
2916
2917 2004-11-15  Kenichi Handa  <handa@m17n.org>
2918
2919         * input.c (find_candidates_group): If INDEX is -1, find the last
2920         candidate group.
2921         (take_action_list): If the previous of the first candidate is
2922         requested, select the last candidate.
2923
2924 2004-11-08  Kenichi Handa  <handa@m17n.org>
2925
2926         * m17n-X.c (device_open): Try at most 32 fonts to find a
2927         non-autoscaled font.
2928
2929         * font.c (xlfd_parse_name): Fix previous change.
2930
2931 2004-11-05  Kenichi Handa  <handa@m17n.org>
2932
2933         * font.c: (commont_style): Include dummy elements "slanted" and
2934         "rslanted" to prefer "o" to "r" if "i" is requested.
2935
2936         * font-ft.c (ft_to_prop): Fix "oblique" entry.
2937
2938 2004-10-29  Kenichi Handa  <handa@m17n.org>
2939
2940         * font.c (xlfd_parse_name): If avgwidth is 0, set the size to 0.
2941
2942         * m17n-X.c (MXFont): Change type of the member `sizes' to int.
2943         New members smallest and larger.
2944         (SET_SIZE, HAVE_SIZE): Adjusted for the above change.
2945         (xfont_registry_list): Likewise.
2946         (xfont_select): Likewise.
2947         
2948
2949 2004-10-28  Kenichi Handa  <handa@m17n.org>
2950
2951         * m17n-X.c (xfont_registry_list): Include '-' before PIXEL_SIZE in
2952         font name comparison.
2953         (xfont_select): Fix logic for selecting a larger size font.
2954
2955 2004-10-25  Kenichi Handa  <handa@m17n.org>
2956
2957         * input.c (take_action_list): Initialize `ret' to 0 for "=", "<",
2958         ">" actions.
2959
2960 2004-10-22  Kenichi Handa  <handa@m17n.org>
2961
2962         * input.c (update_candidate): Renamed from udpate_candidate.
2963         (take_action_list): Show more debugging info on arithmetic commands.
2964
2965         * m17n-X.c (device_open): Fix previous change.
2966
2967         * draw.c (compose_glyph_string): Don't get face property at the
2968         end of M-text.
2969
2970 2004-10-21  Kenichi Handa  <handa@m17n.org>
2971
2972         * draw.c (compose_glyph_string): Fix for the case of category
2973         being Mnil.
2974
2975 2004-10-19  Kenichi Handa  <handa@m17n.org>
2976
2977         * input.c (mdebug_mask): New variable.
2978         (shift_state): Print debug information.
2979         (take_action_list): Likewise.
2980         (handle_key): Likewise.
2981
2982 2004-10-14  Kenichi Handa  <handa@m17n.org>
2983
2984         * m17n-X.c (device_open): Accept Mxft as the value of key Mfont.
2985
2986 2004-10-13  Kenichi Handa  <handa@m17n.org>
2987
2988         * m17n-X.c (device_open): Be sure to register at least one font
2989         driver.
2990
2991         * font-ft.c: Include <freetype/ftbdf.h> conditionally.  Check
2992         HAVE_FTBDF_H before calling FT_Get_BDF_Property.
2993
2994 2004-10-12  Kenichi Handa  <handa@m17n.org>
2995
2996         * draw.c (alloc_gstring): Fix previous change.
2997
2998         * font-ft.c (ft_list_generic): Fix for the case of not
2999         HAVE_FONTCONFIG.
3000
3001         * m17n-X.c (mwin__parse_event): Fix for non-ASCII keys.
3002
3003         * font.c (mfont_list): If no font is found, return NULL.
3004         (load_font_encoding_table): Put entries of nil registry first.
3005         (find_encoding): Adjust for the above change.
3006
3007 2004-10-11  Kenichi Handa  <handa@m17n.org>
3008
3009         * m17n-gui.h (mfont_list): Adjust prototype.
3010
3011         * m17n-X.c (xfont_list): New arg maxnum.
3012
3013         * font.h (struct MFontDriver): Change prototype of <list>.
3014
3015         * font-ft.c (fc_generic_family_list): Delete it.
3016         (Mserif, Msans_serif, Mmonospace): Delete them.
3017         (M_generic_family_info): New variable.
3018         (enum GenericFamilyType): New enum.
3019         (struct GenericFamilyInfo): New struct.
3020         (generic_family_table): New variable.
3021         (set_font_info): New arg style. Don't check 0xA0..0xBF to decide
3022         iso8859-1.
3023         (add_font_info): Get style here.
3024         (ft_list_family): Don't initialize fc_config here.  Don't list
3025         generic families.
3026         (ft_list_generic): New function.
3027         (ft_select): Pay attention to generic familes here.
3028         (ft_open): Fix calculation of ascent and descent.
3029         (ft_list): Pay attention to generic families.
3030         (mfont__ft_init): Initialize M_generic_family_info,
3031         generic_family_table, and fc_config..
3032         (mfont__ft_fini): Finalize generic_family_table.
3033
3034         * draw.c (compose_glyph_string): Use more constant font for
3035         glyphs.  Adjust for the member change in MGlyph.
3036         (layout_glyph_string): Adjust for the member change in MGlyph.
3037         (alloc_gstring): Intilize scracth_glyph to avoid
3038         compose_glyph_string on it.
3039         (get_gstring): Don't call compose_glyph_string on scracth_glyph.
3040         (mdraw_coordinates_position): Fix previous change.
3041
3042         * internal-gui.h (glyph_category): New enum.
3043         (MGlyph): Change type of <category> to enum glyph_category.
3044
3045         * face.c (mface__realize): Delete args langauge and charset.
3046         (mface__for_chars): Fix for the case that glyphs have different
3047         rfaces.
3048         (mface__update_frame_face): Adjust for mface__realize change.
3049
3050         * face.h (mface__realize): Adjust prototype.
3051
3052 2004-10-05  Kenichi Handa  <handa@m17n.org>
3053
3054         * language.c (mlang__init): Add Akan.
3055
3056 2004-10-04  Kenichi Handa  <handa@m17n.org>
3057
3058         * font-ft.c (add_font_info): Add instead of push the element.
3059         (ft_list_family): For generic fonts, try all
3060         substituted. families.
3061
3062         * font-flt.c (UPDATE_CLUSTER_RANGE): New macro.
3063         (run_rule): Don't update cluster range here.
3064         (run_command): Update cluster range on appending a glyph.
3065         (run_otf): Update cluster range for glyphs generated by OTF.
3066
3067 2004-10-02  Kenichi Handa  <handa@m17n.org>
3068
3069         * m17n-X.c (device_open): Handle Mfont key in PLIST.
3070
3071 2004-09-30  Kenichi Handa  <handa@m17n.org>
3072
3073         * font-ft.c (ft_select): Ignore family on calling mfont__score.
3074
3075 2004-09-30  Kenichi Handa  <handa@m17n.org>
3076
3077         * font.h: Include <fontconfig/fontconfig.h>.
3078         (MFTInfo): New member langset.
3079         (mfont__encoding_list): Extern it.
3080
3081         * font.c (mfont__encoding_list): New function.
3082         (mdebug_dump_font_list): New function.
3083
3084         * font-ft.c: Don't include <fontconfig/fontconfig.h> here.
3085         (Mserif, Msans_serif, Mmonospace, Mmedium, Mr, Mnull): New
3086         variables.
3087         (ft_family_list): New variable.
3088         (set_font_info): New arg basep.  Callers changed.
3089         (fc_list): Check the return value of FcPatternGetString.
3090         (add_font_info): New arg plist.  Callers changed. Update
3091         ft_family_list.
3092         (ft_list_family): New function (merged fc_list and ft_list_all).
3093         (ft_select): Use ft_list_family.
3094         (ft_list): Likewise.  If FONT is not NULL, check all fonts.  Fix
3095         typo (== -> !=).
3096         (mfont__ft_init): Initialize above new variables.
3097         (mfont__ft_fini): Free ft_family_list.
3098         (STRDUP_LOWER): New macro.
3099         (set_font_info): Use STRDUP_LOWER.
3100         (ft_list_family): Avoid duplicate addition of font path.  Use
3101         STRDUP_LOWER.
3102         (fc_decode_prop): Fix typo.
3103
3104         * m17n-X.c (MDisplayInfo): New member all_fonts_scaned.
3105         (xfont_registry_list): Change argument disp_info to frame.
3106         Callers changed.
3107         (xfont_list_all): New function.
3108         (xfont_list): If FONT is not NULL, check all fonts.
3109
3110 2004-09-28  Kenichi Handa  <handa@m17n.org>
3111
3112         * m17n-X.c (MXFont, MXFontList): New types.
3113         (MDisplayInfo): Delete members font_registry_list,
3114         iso8859_1_family_list, iso10646_1_family_list, new members
3115         font_list, base_font_list.
3116         (free_display_info): Adusted for the change of MDisplayInfo.
3117         (xfont_driver): Initialize with xfont_list.
3118         (font_compare): New function.
3119         (build_font_list): Deleted.
3120         (xfont_registry_list): New function.
3121         (xfont_select): Use xfont_registry_list.
3122         (xfont_list): New function.
3123         (device_open): Adusted for the change of MDisplayInfo.
3124
3125         * font-ft.c (add_font_info): New arg languages.  Callers changed.
3126         (fc_list): Get languages from fonts..
3127         (ft_list_all): Renamed from ft_list.  Callers changed.
3128         (ft_list): New function.
3129         (mfont__ft_driver): Initalize with ft_list.
3130
3131         * font.c (mfont_list): New function.
3132
3133         * font.h (struct MFontDriver): New member `list'.
3134         (MFTInfo): New member languages.
3135
3136         * m17n-gui.h (mfont_list): Extern it.
3137
3138 2004-09-27  Kenichi Handa  <handa@m17n.org>
3139
3140         * internal-gui.h (struct MGlyphString): Delete members mt,
3141         sub_width, sub_lbrearing, sub_rbearing, and region.
3142
3143         * draw.c (MSubTextExtents): New type.
3144         (layout_glyphs): New arg extents.  Set its members.
3145         (layout_glyph_string): Adjusted for the above change.
3146         (alloc_gstring): Don't set gstring->mt.
3147         (truncate_gstring): Call line_break function with mt instead of
3148         gstring->mt.
3149
3150 2004-09-22  Kenichi Handa  <handa@m17n.org>
3151
3152         * mtext.c (count_utf_16_chars): Count each code of invalid
3153         surrogates as one.
3154
3155 2004-09-19  Kenichi Handa  <handa@m17n.org>
3156
3157         * mtext.c (default_utf_16, default_utf_32): Rename them to
3158         MTEXT_FORMAT_UTF_16 and MTEXT_FORMAT_UTF_32 respectively.  Caller
3159         changed.
3160
3161         * m17n-core.h (MTEXT_FORMAT_UTF_16, MTEXT_FORMAT_UTF_32): Extern
3162         them.
3163
3164 2004-09-13  Kenichi Handa  <handa@m17n.org>
3165
3166         * draw.c (Mlatin): Don't declare it here.
3167         (visual_order): Fix reordering of combining characters.
3168         (compose_glyph_string): Fix detection of script.
3169         (layout_glyphs): Don't fix reordering of combining characters
3170         here.
3171         (layout_glyph_string): Pay attention to
3172         control->disable_overlapping_adjustment.
3173         (truncate_gstring): Include at least on character in a line.
3174         (get_gstring): Always scan one full line.
3175         (mdraw__init): Don't initialize Mlatin here.
3176         (mdraw_text_per_char_extents): Fix iteration.  If a glyph doesn't
3177         have a font, use ascent/descent of an ASCII font.  Allow
3178         ink_array_return and logical_array_return to be NULL.
3179         (mdraw_coordinates_position): Fix iteration.
3180
3181         * font-ft.c (MFTtoProp): Member completely changed.
3182         (ft_to_prop): Adjusted for the above change.
3183         (ft_to_prop_size): Likewise.
3184         (set_font_info): Adjusted for the change of MFTtoProp.
3185         (fc_generic_family_list): New variable.
3186         (fc_list): Add special handling of generic font names.
3187         (mfont__ft_init): Adjusted for the change of MFTtoProp.
3188         Initialize fc_generic_family_list.
3189         (mfont__ft_fini): Don't free ft_to_prop.  Free
3190         fc_generic_family_list.
3191         (FC_vs_M17N_font_prop): New type.
3192         (fc_weight_table, fc_slant_table, fc_width_table): New variables.
3193         (fc_decode_prop, fc_encode_prop): New functions.
3194         (mfont__ft_parse_name): Use fc_decode_prop.
3195         (mfont__ft_unparse_name): Use fc_encode_prop.
3196
3197         * m17n-X.c (MDisplayInfo): Delete member realized_font_list.
3198         (MWDevice): Add member realized_font_list.
3199         (free_display_info): Don't free disp_info->realized_font_list.
3200         (free_device): Free device->realized_fontset_list.
3201         (xft_find_metric): Use gstring->frame instead of rfont->frame.
3202         (device_open): Don't initialize disp_info->realized_font_list.
3203         (device_open): Initialize device->realized_font_list and set it to
3204         frame->realized_font_list.
3205
3206         * fontset.c (try_font_group): New function.
3207         (mfont__lookup_fontset): Use try_font_group.
3208
3209         * font.c (common_weight): Change the order of "regular".
3210
3211         * face.c (Mlatin): Don't make it static.
3212         (mface__realize): Be sure to set work_gstring.frame.
3213         (mface__for_chars): Likewise.
3214
3215         * mtext.c (mdebug_dump_mtext): Fix for the case of mt->format >
3216         MTEXT_FORMAT_UTF_8.
3217
3218         * internal-gui.h (Mlatin): Extern it.
3219
3220         * m17n-gui.h (MDrawControl): New member
3221         disable_overlapping_adjustment.
3222
3223 2004-09-06  Kenichi Handa  <handa@m17n.org>
3224
3225         * font-flt.c (run_otf): Fix typo ('}'->']').
3226
3227         * internal-gui.h (MAKE_PRECOMPUTED_COMBINDING_CODE)
3228         (COMBINING_PRECOMPUTED_P): New macros.
3229
3230         * draw.c (layout_glyphs): Handle precomputed combining code.
3231
3232         * font-ft.c (mfont__ft_drive_otf): Set g->combining_code to a
3233         precomupted combining code.
3234
3235 2004-09-03  Kenichi Handa  <handa@m17n.org>
3236
3237         * font-ft.c (mfont__ft_drive_otf): Use malloc and free for
3238         otf_gstring.glyphs.
3239
3240 2004-08-27  Kenichi Handa  <handa@m17n.org>
3241
3242         * face.c (mface_put_prop): If the new value is the same as the
3243         current one, don't increment frame->tick.
3244
3245 2004-08-25  Kenichi Handa  <handa@m17n.org>
3246
3247         * fontset.c (mfontset): Initialize font_spec_list member.
3248         (mfontset_copy): Load fontset if necessary.
3249
3250         * m17n-gui.h (MDrawGlyphInfo): Change the member name 'this' to
3251         'metrics' to for C++.
3252
3253         * draw.c (mdraw_glyph_info): Adjusted for the member name change
3254         (this -> metics).
3255
3256 2004-08-16  Kenichi Handa  <handa@m17n.org>
3257
3258         * Version 1.1.0 released.
3259
3260 2004-08-13  Kenichi Handa  <handa@m17n.org>
3261
3262         * language.c (mlang__init): Add Dhivehi.
3263
3264         * m17n-gui.c (Mx, Mfreetype): Delete it.
3265         (m17n_init_win): Don't initialize Mx and Mfreetype here.
3266
3267         * m17n-gui.h (Mfreetype, Mxft): Extern them.
3268         (mfont_resize_ratio): Extern it.
3269         (MDrawGlyphInfo): New member logical_width;
3270         (MDrawGlyph): New type.
3271         (mdraw_glyph_list): Prototype adjusted.
3272
3273         * m17n-X.c (xfont_open): Set type and fontp members.
3274         (xft_open): Likewise.
3275
3276         * internal-gui.h (Mx, Mfreetype): Delete extern.
3277
3278         * font.h (struct MRealizedFont): New member type and fontp.
3279
3280         * font.c (mfont__init): Initialize Mx, Mfreetype, and Mxft.
3281         (Mx, Mfreetype): Declare here.
3282         (Mxft): New variable.
3283         (mfont_resize_ratio): New function.
3284
3285         * font-ft.c (ft_open): Set type and fontp members.
3286
3287         * draw.c (mdraw_glyph_list): Argument type changed.  Don't set
3288         glyph_code member.
3289
3290 2004-08-11  Kenichi Handa  <handa@m17n.org>
3291
3292         * font-ft.c (ft_find_metric): Call FT_Load_Glyph with
3293         FT_LOAD_DEFAULT.
3294
3295 2004-08-06  Kenichi Handa  <handa@m17n.org>
3296
3297         * font-ft.c (mfont__ft_drive_otf): Fix for the case that no GSUB
3298         feature to apply.
3299
3300         * font-flt.c (run_otf): Print debugging information if necessary.
3301
3302 2004-08-05  Kenichi Handa  <handa@m17n.org>
3303
3304         * font-ft.c (mfont__ft_drive_otf): Fix sign of g->yoff.  Support
3305         positioning_type 5 and 6.  Switch simplified.
3306
3307 2004-08-04  Kenichi Handa  <handa@m17n.org>
3308
3309         * font-ft.c (mfont__ft_drive_otf): Call OTF_drive_gdef.
3310
3311 2004-08-02  Kenichi Handa  <handa@m17n.org>
3312
3313         * font.c (mfont__score): If prop is MFONT_FOUNDRY or MFONT_FAMILY,
3314         set val to 1 even if it is greater than 1.
3315
3316         * fontset.c (mfontset_modify_entry): Fix handling of the arg `how'.
3317
3318 2004-07-29  Kenichi Handa  <handa@m17n.org>
3319
3320         * font-flt.c (run_rule, run_command, mfont__flt_run): Print more
3321         debugging information.
3322
3323         * internal.h (MDEBUG_PRINT5): New macro.
3324
3325         * draw.c (layout_glyphs): Don't combine a zero width glyph with
3326         the previous one if the zero width glyph has left or right
3327         padding.
3328
3329 2004-07-26  Kenichi Handa  <handa@m17n.org>
3330
3331         * m17n-X.c (xft_render): Pay attention to members left_padding and
3332         right_padding of MGlyph.
3333
3334         * draw.c (visual_order): Allocate one more elements for arrays as
3335         a workaround of fribidi bug.
3336         (layout_glyphs): Fix previous change. Check MGlyph->combining_code
3337         instead of MGlyph->bidi_sensitive.
3338         (layout_glyph_string): Pay attentinon to
3339         control->orientation_reversed when padding at the head or tail.
3340         Fix adjustment of space glyph width.
3341         (get_gstring): If cursor_width or cursor_bidi is changed, don't
3342         use a cache.
3343
3344         * font-ft.c (mfont__ft_drive_otf): Set MGlyph->combining_code
3345         instead of MGlyph->bidi_sensitive.
3346
3347         * internal-gui.h (MGlyph): Delete member bidi_sensitive.
3348
3349 2004-07-26  Kenichi Handa  <handa@m17n.org>
3350
3351         * draw.c (visual_order): Don't treat combined glyphs specially.
3352         (layout_glyphs): Don't get metrics glyphs that are already ready.
3353         Pay attention to MGlyph->bidi_sensitive.  Combine a glyph of zero
3354         width with the previous one. 
3355         (draw_background): Fix bar cursor position on a r2l glyph.
3356
3357         * font-flt.c (FontLayoutCmdOTF): Move back from internal-gui.h.
3358         (run_rule): Fix place of updating cluster_begin_pos and
3359         cluster_end_pos here.
3360         (run_otf): Don't set left_padding.
3361
3362         * font-ft.c (adjust_anchor): Type of argument `code' changed.
3363         Caller changed.
3364         (mfont__ft_drive_otf): Renamed back from mfont__ft_drive_gsub.
3365         Fix handling of GPOS.
3366         (mfont__ft_drive_gpos): Delete this function.
3367
3368         * font.h (mfont__ft_drive_otf): Renamed back from
3369         mfont__ft_drive_gsub.
3370         (mfont__ft_drive_gpos): Delete extern.
3371
3372         * internal-gui.h (FontLayoutCmdOTF): Move back to font-flt.c.
3373         (MGlyph): Delete member otf_cmd, add member bidi_sensitive.
3374
3375 2004-07-23  Kenichi Handa  <handa@m17n.org>
3376
3377         * draw.c (layout_glyphs): Call mfont__ft_drive_gpos with glyphs of
3378         the same bidi level.
3379
3380         * font-ft.c (mfont__ft_drive_gpos): Check bidi-level.
3381
3382 2004-07-22  Kenichi Handa  <handa@m17n.org>
3383
3384         * font-flt.c (load_flt): Treat the symbol Mend as end-of-file.
3385
3386 2004-07-20  Kenichi Handa  <handa@m17n.org>
3387
3388         * draw.c (render_glyphs): Fix checking of g->code validity.
3389
3390         * face.c (mface__realize): Set g.type.
3391
3392 2004-07-18  Kenichi Handa  <handa@m17n.org>
3393
3394         * Makefile.am: Prepend ${top_srcdir} to all *.la in
3395         *_LIBADD/*_LDADD.
3396
3397         * m17n-gui.c (mframe): Print error message give by dlopen to
3398         stderr.
3399
3400 2004-07-16  Kenichi Handa  <handa@m17n.org>
3401
3402         * draw.c (compose_glyph_string): Improve the way of deciding a
3403         script.  For a character that doesn't have script property, use
3404         the last non-latin script.
3405
3406         * font-ft.c (fc_list): Cancel previous change.
3407         (mfont__ft_init): Add more entries in ft_to_prop_name.
3408
3409 2004-07-15  Kenichi Handa  <handa@m17n.org>
3410
3411         * draw.c (mdraw_glyph_list): Add the width of padding glyphs to
3412         previous or next character glyphs.
3413
3414 2004-07-14  Kenichi Handa  <handa@m17n.org>
3415
3416         * draw.c (compose_glyph_string): Be sure to set codes for glyphs
3417         of type GLYPH_SPACE.
3418
3419         * fontset.c (mfont__lookup_fontset): If glyph type is
3420         GLYPH_SPACE, get codes for SPACE.
3421
3422         * internal-gui.h (Mfont): Delete extern.
3423
3424         * m17n-gui.h (Mfont): Delete duplicated extern.
3425
3426 2004-07-13  Kenichi Handa  <handa@m17n.org>
3427
3428         * font-ft.c (DEVICE_DELTA): New macro.
3429         (adjust_anchor): New function.
3430         (mfont__ft_drive_gsub): Renamed from mfont__ft_drive_otf.  Drive
3431         only GSUB.
3432         (mfont__ft_drive_gpos): New function.
3433
3434         * font-flt.c (FontLayoutCmdOTF): Moved to internal-gui.h.
3435         (FontLayoutContext): Delete member `rfont'.
3436         (run_otf): Set g->otf_cmd.  Call 
3437         (mfont__flt_run): Don't set ctx.rfont.  Call mfont__ft_decode_otf
3438         only whne HAVE_OTF is defined.
3439
3440         * fontset.c: Include "config.h".
3441
3442         * internal-gui.h (FontLayoutCmdOTF): Moved from font-flt.c.
3443         (MGlyph): New member otf_cmd.
3444
3445         * font.h (mfont__ft_drive_gsub): Changed from mfont__ft_drive_otf.
3446         (mfont__ft_drive_gpos): Extern it.
3447
3448         * face.c: Include "config.h".
3449
3450         * draw.c (layout_glyphs): Call mfont__ft_drive_gpos.
3451
3452         * input-gui.c: Include "config.h".
3453
3454         * plist.c: Include "config.h".
3455
3456 2004-07-06  Kenichi Handa  <handa@m17n.org>
3457
3458         * m17n-gui.c, m17n-gui.h, m17n-gd.c, m17n-X.h, m17n-X.c,
3459         internal-gui.h: Cancel previous changes.
3460
3461         * m17n-gd.h: Delete it.
3462
3463         * Makefile.am (libm17n_core_la_LIBADD): New variable.
3464         (libm17n_core_la_LDFLAGS): Add -export-dynamic, move
3465         @XML2_LD_FLAGS@ to above.
3466         (libm17n_la_LIBADD): Add -ldl.
3467         (libm17n_la_LDFLAGS): Add -export-dynamic.
3468         (X_LD_FLAGS): Fix the order of linking.
3469         (libm17n_gui_la_LIBADD): Add ${OPTIONAL_LD_FLAGS}.
3470         (libm17n_gui_la_LDFLAGS): Add -export-dynamic, delete above.
3471         (libm17n_X_la_LDFLAGS): Add -module.
3472         (libm17n_gd_la_SOURCES): Delete m17n-gd.h.
3473         (libm17n_gd_la_LIBADD): Add @GD_LD_FLAGS@.
3474         (libm17n_gd_la_LDFLAGS): Add -module.
3475         (include_HEADERS): Delete m17n-gd.h.
3476
3477 2004-06-30  Kenichi Handa  <handa@m17n.org>
3478
3479         * m17n-gui.c: Adjusted for the change of struct MDeviceDriver.
3480         (MDeviceLibraryInterface): Delete it.
3481         (register_device_library): Delete it.
3482         (m17n__device_library_list): Renamed from device_library_list.
3483
3484         * m17n-gui.h (M17N_INIT_X, M17N_INIT_GD): New macros.
3485         (m17n_init_win): Adjust prototype.
3486
3487         * m17n-gd.c: Adjusted for the change of struct MDeviceDriver.
3488         (m17n_init_gd): New function. 
3489
3490         * m17n-gd.h: New file.
3491
3492         * m17n-X.h: Include <m17n-gui.h>.
3493         (m17n_init_X): Extern it.
3494         (M17N_INIT): Redefine it.
3495
3496         * m17n-X.c: Adjusted for the change of struct MDeviceDriver.
3497         (m17n_init_X): New function.
3498
3499         * internal-gui.h (m17n__device_library_list): Extern it.
3500         (struct MDeviceDriver): New members initialized, init, and fini.
3501
3502         * Makefile.am (libm17n_X_la_LIBADD): Add ${X_LD_FLAGS} and
3503         @XFT2_LD_FLAGS@.
3504         (libm17n_X_la_LIBADD): Delete aboves.
3505         (libm17n_gd_la_SOURCES): Add m17n-gd.h.
3506         (libm17n_gd_la_LIBADD): Add @GD_LD_FLAGS@.
3507         (libm17n_gd_la_LDFLAGS): Delete it.
3508         (include_HEADERS): Add m17n-gd.h.
3509
3510 2004-06-25  Kenichi Handa  <handa@m17n.org>
3511
3512         * Makefile.am (libm17n_X_la_LDFLAGS): Cancel previous change.
3513         (libm17n_gd_la_LDFLAGS): Cancel previous change.
3514
3515         * m17n-gd.c (gd_render): Don't call FT_Get_Char_Index.
3516
3517         * font-ft.c (fc_list): If FcFontList finds no font, try
3518         FcFontMatch.
3519
3520         * draw.c (compose_glyph_string): Terminate the last loop after
3521         doing default combining if necessary.
3522
3523 2004-06-24  Kenichi Handa  <handa@m17n.org>
3524
3525         * draw.c (mdraw_glyph_list): Unref gstring->top at the tail.
3526
3527         * character.c (mchar_define_property): Add const to an arg.
3528
3529         * charset.c (mchar_define_charset): Add const to an arg.
3530
3531         * coding.c (MCodingSystem): Add const to an arg or decoder.
3532         (finish_decoding): Add const to an arg.
3533         (decode_coding_charset, decode_coding_utf_8)
3534         (decode_coding_utf_16, decode_coding_utf_32)
3535         (decode_coding_iso_2022, decode_coding_sjis)
3536         (mconv_define_coding): Likewise.
3537
3538         * m17n-X.c (xft_find_metric): Delete unused variable.
3539
3540         * m17n-core.h (mchar_define_property, mtext_from_data): Adjust
3541         prototypes.
3542
3543         * m17n.h (mchar_define_charset, mconv_define_coding): Adjust
3544         prototypes.
3545
3546         * mtext.c (count_utf_8_chars, count_utf_16_chars)
3547         (mtext__from_data, mtext_from_data): Add `const' to an arg.
3548
3549         * mtext.h (mtext__from_data): Ajust prototype.
3550
3551 2004-06-23  Kenichi Handa  <handa@m17n.org>
3552
3553         * draw.c (compose_glyph_string): Always get glyph codes by
3554         mface__for_char.
3555         (mdraw_glyph_info): Set info->glyph_code and info->logical_width.
3556         (mdraw_glyph_list): New function.
3557
3558         * font-flt.c (mfont__flt_run): Be sure to call
3559         rfont->driver->encode_char.
3560
3561         * font-ft.c (ft_find_metric): Don't call FT_Get_Char_Index.
3562         (ft_encode_char): Delete arg C.
3563         (ft_render): Don't call FT_Get_Char_Index.
3564
3565         * font.c (mfont__encodable_p): Delete it.
3566         (mfont__encode_char): Be sure to call rfont->driver->encode_char.
3567
3568         * font.h (struct MFontDriver): Delete arg C of encode_char.
3569         (mfont__encodable_p): Delete extern.
3570
3571         * m17n-X.c (xfont_encode_char): Delete arg C.
3572         (xft_find_metric): Don't cal FT_Get_Char_Index.
3573         (xft_render): Likewise.
3574
3575         * m17n-gui.h (MDrawGlyphInfo): New members glyph_code and
3576         logical_width.
3577         (mdraw_glyph_list): Extern it.
3578
3579         * Makefile.am (libm17n_X_la_LDFLAGS): Don't include ${X_LD_FLAGS}.
3580
3581 2004-06-22  Kenichi Handa  <handa@m17n.org>
3582
3583         * m17n-gui.h (mfontset_lookup): Extern it.
3584
3585         * m17n-gui.c (m17n_init_win): Delete unnecessary printing.
3586
3587         * fontset.c (realize_fontset_elements)
3588         (free_realized_fontset_elements, update_fontset_elements): New
3589         functions.
3590         (mfont__realize_fontset): Call realize_fontset_elements.
3591         (mfont__free_realized_fontset): Call free_realized_fontset_elements.
3592         (mfont__lookup_fontset): If a fontset was modified, update
3593         the realized fontset.
3594         (mfontset_modify_entry): Increment fontset->tick.
3595         (mfontset_lookup): New function.
3596
3597 2004-06-21  Kenichi Handa  <handa@m17n.org>
3598
3599         * font-ft.c (mfont__ft_parse_name): Cast the arg to FcNameParse.
3600
3601         * mtext.c (mtext_dup, mtext_cat, mtext_ncat, mtext_cpy)
3602         (mtext_ncpy, mtext_duplicate): Pay attention to the case that the
3603         length of source text 0.
3604
3605 2004-06-21  Kenichi Handa  <handa@m17n.org>
3606
3607         * mtext.c (INC_POSITION): Use CHAR_UNITS_BY_HEAD_UTF16.
3608         (compare): Pay attention to format other than utf-8.
3609         (copy): Delete this function.
3610         (count_by_utf_8, count_by_utf_16, insert): New functions.
3611         (count_utf_16_chars): Fix handling of a surrogate pair.
3612         (find_char_forward, find_char_backward): Likewise.
3613         (mtext__from_data): Delete unnecessary check.  Fix number of
3614         allocated bytes.
3615         (mtext_from_data): Don't count items.
3616         (mtext_ref_char): Optimize the code.
3617         (mtext_set_char): Pay attention to format other than utf-8.
3618         (mtext_cat_char): Likewise.
3619         (mtext_dup): Don't call copy, instead do allocation here.
3620         (mtext_cat): Call insert instead of copy.
3621         (mtext_ncat): Likewise.
3622         (mtext_cpy): Delete character at first and call insert instead of
3623         copy.
3624         (mtext_ncpy): Likewise.
3625         (mtext_copy): Likewise.
3626         (mtext_duplicate): Call insert instead of copy.
3627         (mtext_del): Pay attention to format other than utf-8.
3628         (mtext_ins): Simply call insert.
3629         (mtext_ins_char): Pay attention to format other than utf-8.
3630         (mtext_tok): Call insert instead of copy.
3631         (mtext_text): Call UNIT_BYTES.
3632
3633         * textprop.c (mtext__adjust_plist_for_change): New function.
3634
3635         * character.h (USHORT_SIZE, UINT_SIZE, UNIT_BYTES): New macros.
3636         (CHAR_UNITS_UTF16, CHAR_UNITS): Simplified.
3637         (CHAR_UNITS_AT): Fix typo.
3638         (CHAR_UNITS_BY_HEAD): Fix typo.
3639         (STRING_CHAR_AND_UNITS): Fix typo.
3640
3641         * internal.h (MTEXT_READ_ONLY_P): New macro. 
3642
3643         * mtext.h (mtext__replace): Delete the extern.
3644         (mtext__adjust_foramt): Adjust prototype.
3645
3646         * plist.c (mplist_deserialize): Adjust the format of MT to utf-8
3647         if possible.  Otherwise make a copy of mmt.
3648
3649         * coding.c (mconv_decode, mconv_gets): Adjust the format of MT to
3650         utf-8.
3651
3652 2004-06-18  Kenichi Handa  <handa@m17n.org>
3653
3654         * character.h (CHAR_STRING_UTF16): Fix syntax.
3655
3656 2004-06-16  Kenichi Handa  <handa@m17n.org>
3657
3658         * Makefile.am (libm17n_gd_la_LIBADD): Delete it.
3659         (libm17n_X_la_LIBADD): Delete it.
3660         (libm17n_gd_la_LDFLAGS): Don't include @GD_LD_FLAGS@.
3661
3662         * m17n-X.c (device_open): Add parens in `if' condition.
3663
3664         * mtext.c (INC_POSITION): Handle format other than utf8 and utf16.
3665         (DEC_POSITION): Likewise.
3666         (compare): Fix case that mt1->format is MTEXT_FORMAT_UTF_8.
3667
3668 2004-06-15  Kenichi Handa  <handa@m17n.org>
3669
3670         * fontset.c (mfont__lookup_fontset): Fix selection of font groups
3671         by language.
3672
3673         * draw.c (compose_glyph_string): If langauge is specified, call
3674         mface__for_chars even if a text is all latin.  Fix condition for
3675         setting non_ascii_found.
3676
3677         * m17n-X.c (xft_find_metric): Fix setting of g->lbrearing.
3678
3679         * m17n.h (minput_char_to_key): Delete extern.
3680
3681         * m17n-gui.h (minput_event_to_key): Cancel previous change.
3682
3683         * m17n-gui.c (null_device_open): Set several members of frame.
3684
3685 2004-06-14  Kenichi Handa  <handa@m17n.org>
3686
3687         * m17n-gui.h (minput_event_to_key): Delete extern.
3688
3689         * symbol.h (struct MSymbolStruct): Renamed from MSymbol.
3690
3691         * m17n-core.h (MSymbol): Defined as "struct MSymbolStruct *".
3692
3693         * Makefile.am (AM_CPPFLAGS): Refer to @M17NDIR@.
3694
3695 2004-06-08  Kenichi Handa  <handa@m17n.org>
3696
3697         * character.c (mchar_put_prop): Don't increment the ref-count of
3698         record->table.
3699
3700 2004-06-04  Kenichi Handa  <handa@m17n.org>
3701
3702         * m17n-core.c (mdebug__register_object): New function.
3703         (mdebug__unregister_object): Likewise.
3704
3705         * internal.h (mdebug__register_object, mdebug__unregister_object):
3706         Extern them.
3707         (M17N_OBJECT_REGISTER, M17N_OBJECT_UNREGISTER): Call them
3708         respectively.
3709
3710         * charset.c (mcharset__load_from_database): Don't call
3711         mconv__register_charset_coding here.
3712
3713         * coding.c (find_coding): Get a real name from an element of
3714         coding_definition_list.
3715         (mconv__register_charset_coding): Set the real name at the top of
3716         param.
3717         (mcoding__load_from_database): Likewise.
3718         (mconv_list_codings): Adjusted for the above change.
3719
3720 2004-06-03  Kenichi Handa  <handa@m17n.org>
3721
3722         * coding.c (find_coding): Find by canonicalized name.  Don't have
3723         to modify the element of coding_definition_list by
3724         mplist__from_plist.
3725         (mconv__define_coding_from_charset): Delete it.
3726         (mconv__register_charset_coding): Canonicalize sym.
3727         (mcoding__load_from_database): Register plist modified by
3728         mplist__from_plist.
3729
3730         * coding.h (mconv__define_coding_from_charset): Don't extern it.
3731
3732         * font-ft.c (ft_open): Fix setting of rfont->descent.
3733
3734 2004-06-02  Kenichi Handa  <handa@m17n.org>
3735
3736         * font.c (enum xlfd_field_idx): Moved from m17n-X.c.
3737         (xlfd_parse_name): Merge split_font_name and xfont_parse_name.
3738         (xlfd_unparse_name): Renamed from xfont_build_name.
3739         (mfont__init): Initialized Mfontconfig.
3740         (mfont__free_realized): Unconditionally unref rfont->info.
3741         (mfont__select): Free `this' if it's not best.
3742         (mfont__open): Don't check frame->realized_font_list.
3743         (mfont__parse_name_into_font): New function.
3744         (Mfontconfig): New variable.
3745         (mfont_from_name): Call mfont_parse_name.
3746         (mfont_name): Call mfont_unparse_name.
3747         (mdebug_dump_font): Likewise.
3748
3749         * font.h (struct MFontDriver): Delete members parse_name and
3750         build_name.
3751         (mfont__ft_parse_name, mfont__ft_unparse_name): Extern them.
3752         (mfont__parse_name_into_font): Extern it.
3753
3754         * font-ft.c: Include "symbol.h".
3755         (close_ft): Unconditionally free filename and charmap_list of
3756         ft_into.
3757         (ft_open): Duplicate base->filename.  Increment ref-count of
3758         ft_info->charmap_list.  Free ft_info->charmap_list and
3759         ft_info->filename on error.
3760         (mfont__ft_parse_name, mfont__ft_unparse_name): New functions.
3761
3762         * m17n-X.c (xfont_driver): Don't include xfont_parse_name and
3763         xfont_build_name.
3764         (enum xlfd_field_idx): Moved to font.c.
3765         (split_font_name, build_font_name): Likewise.
3766         (build_font_list): Call mfont__parse_name_info_font.
3767         (xfont_open): Call mfont__unparse_name.  Free name.
3768         (xfont_parse_name, xfont_build_name): Moved to font.c
3769         (xft_select): Prototype deleted.
3770         (device_open): Check HAVE_FREETYPE on using mfont__ft_driver.
3771         Call mfont_pase_name.
3772
3773         * m17n-gui.c (free_frame): Unref frame->font_driver_list.
3774         (m17n_fini_win): Add check HAVE_FREETYPE on using null_interface.
3775         (mframe): Likewise.
3776
3777         * m17n-gui.h (mfont_parse_name, mfont_unparse_name, Mfontconfig):
3778         Extern them.
3779
3780         * Makefile.am (linkgui_LDADD): Add libm17n-X.la and libm17n-gd.la.
3781
3782 2004-06-01  Kenichi Handa  <handa@m17n.org>
3783
3784         * fontset.c (mfontset_modify_entry): Pay attention to the case
3785         that fontset->font_spec_list is NULL.
3786
3787 2004-05-31  Kenichi Handa  <handa@m17n.org>
3788
3789         * m17n-gui.c: Include <dlfcn.h> only when HAVE_DLFCN_H is defined.
3790
3791         * input.c: Include <dlfcn.h> only when HAVE_DLFCN_H is defined.
3792
3793         * font.c (mfont__select): Print score the a font for debugging.
3794
3795         * Makefile.am (libm17n_la_LIBADD): Delete -ldl.
3796
3797         * coding.c (reset_coding_sjis): Check kanji and kana instead of
3798         kanji_sym and kana_sym.
3799
3800 2004-05-28  Kenichi Handa  <handa@m17n.org>
3801
3802         * Makefile.am (VINFO): New variable.
3803         (libm17n_core_la_LDFLAGS, libm17n_la_LDFLAGS)
3804         (libm17n_gd_la_LDFLAGS): Include ${VINFO}.
3805
3806 2004-05-27  Kenichi Handa  <handa@m17n.org>
3807
3808         The following chanages are to make device dependent functions
3809         accessible only from MDeviceDriver structure, and to add GD and
3810         null device drivers.  Font drivers get also device dependent.
3811
3812         * m17n.c (m17n_init): Increament shell_initialized.
3813         (m17n_fini): Decremented shell_initialized.
3814
3815         * m17n-misc.h (enum MErrorCode): New element MERROR_GD.
3816
3817         * m17n-gui.h (Mdevice, Mdisplay, Mscreen, Mdrawable, Mdepth)
3818         (Mwidget, Mcolormap, Mx): Extern them.
3819
3820         * m17n-gui.c: Include <dlfcn.h> and "config.h".
3821         (free_frame): Call frame->driver->close instead of
3822         mwin__close_device.
3823         (DLOPEN_SHLIB_EXT): New macro.
3824         (MDeviceLibraryInterface): New type.
3825         (device_library_list): New variable.
3826         (register_device_library): New function.
3827         (null_device): New variable.
3828         (null_device_close, null_device_get_prop)
3829         (null_device_realize_face, null_device_free_realized_face): New
3830         function.
3831         (null_driver): New variable.
3832         (null_device_init, null_device_fini, null_device_open): New
3833         functions.
3834         (null_interface): New variable.
3835         (Mfreetype, Mdevice): Declare them.
3836         (m17n_init_win): Increment win_initialized.  Initialize Mx, Mgd,
3837         Mfreetype, Mdevice, Mdisplay, Mscreen, Mdrawable, Mdevice, and
3838         Mwin__Close_Device.  Register drivers for Mx and Mgd.
3839         (m17n_fini_win): Decremented win_initialized.  Call "fini"
3840         function of all opened devices.  Don't call mwin__fini.
3841         (Mdisplay, Mscreen, Mdrawable, Mdepth, Mwidget, Mcolormap):
3842         Declare them here.
3843         (mframe): Handle Mdevice key of PLIST.
3844         (mframe_get_prop): Call frame->device->get_prop instead of
3845         mwin__device_get_prop.
3846
3847         * m17n-gd.c: New file.
3848
3849         * m17n-core.h (M17NLIB_MAJOR_VERSION, M17NLIB_MINOR_VERSION)
3850         (M17NLIB_PATCH_LEVEL, M17NLIB_VERSION_NAME): Updated to 1.1.0.
3851
3852         * m17n-core.c (m17n_init_core): Increate core_initialized.
3853         (m17n_fini_core): Decremented core_initialized.
3854
3855         * m17n-X.h (Mdisplay, Mscreen, Mdrawable, Mdepth, Mwidget)
3856         (Mcolormap): Don't extern them here.
3857
3858         * m17n-X.c (FRAME_DEVICE): New macro.
3859         (FRAME_DISPLAY, FRAME_SCREEN, FRAME_CMAP): Use FRAME_DEVICE.
3860         (free_display_info): Use MPLIST_DO.
3861         (free_device): Free rface->info.
3862         (xft_close): Delete it.
3863         (device_init): Renamed from mwin__init.
3864         (device_fini): Renamed from mwin__fini.
3865         (device_open): Renamed from mwin__open_device.
3866         (x_driver): New variable.
3867         (MXFontInfo): Delete member frame, add member display.
3868         (Mdisplay, Mscreen, Mdrawable, Mdepth, Mwidget, Mcolormap, Mxim):
3869         Don't declare them here.
3870
3871         * internal-gui.h (MDeviceType): New enum.
3872         (MWDefice): Delete it.
3873         (struct MFrame): Change type of device to void *.  New members
3874         device_type, driver, font_driver_list.
3875         (M_CHECK_WRITABLE, M_CHECK_READABLE): New macros.
3876         (MDeviceDriver): New type.
3877         (Mx, Mgd, Mfreetype): Extern them.
3878         (mwin__XXX): Delete all of them.
3879
3880         * input-gui.c (win_create_ic): Call frame->driver->XXX instead of
3881         mwin__XXX.
3882         (win_destroy_ic): Likewise.
3883         (adjust_window_and_draw): Likewise.
3884         (win_callback): Likewise.
3885         (Mxim): Declare it here.
3886         (minput_event_to_key): Call M_CHECK_READABLE.
3887
3888         * fontset.c (mfont__lookup_fontset): Delete local variable
3889         font_group.
3890
3891         * font.h (struct MFontDriver): Delete member close, add members
3892         parse_name and build_name.
3893         (mfont__driver_list): Delete extern.
3894         (mfont__close): Delete extern.
3895
3896         * font.c (mfont__init): Don't set mfont__driver_list.
3897         (mfont__fini): Don't unref mfont__driver_list.
3898         (mfont__select): Try font drivers in frame->font_driver_list.  Set
3899         driver member of a realized font.
3900         (mfont__close): Delete it.
3901         (mfont_from_name, mfont_name, mdebug_dump_font): Call driver
3902         functions of the default frame.
3903
3904         * font-ft.c (close_ft): Check ft_info->ft_face and work
3905         differently.
3906         (add_font_info): Allocate ft_info by M17N_OBJECT.
3907         (ft_close): Delete it.
3908         (mfont__ft_driver): Don't set ft_close.
3909         (ft_select): Increment ref-count of best_font.
3910         (ft_open): Decremented ref-count of base.  On error, call
3911         FT_Done_Face and free ft_info.
3912         (ft_find_metric): Always use XXX_MONO in load_flags.
3913         (ft_render): Fix setting of width.  Call
3914         frame->driver->draw_points instead of mwin__draw_points.
3915         (ft_to_prop): Don't set mfont__driver_list.
3916         (mfont__ft_fini): Just unref ft_info.
3917
3918         * face.c (mface__init): Exchange foreground and background of
3919         mface__default.  Call mface_put_prop to set hline of
3920         mface_underline,
3921         (mface__realize): Call frame->driver->XXX instead of mwin__XXX.
3922         (mface__free_realized): Don't call mwin__free_realized_face.
3923
3924         * draw.c (Mdepth): Don't declare it here.
3925         (draw_background): Call frame->driver->XXX instead of mwin__XXX.
3926         (render_glyphs, render_glyph_string): Likewise.
3927         (mdraw__init): Don't set Mdepth.
3928         (mdraw_text, mdraw_image_text, mdraw_text_with_control): Call
3929         M_CHECK_WRITABLE.
3930         (mdraw_text_per_char_extents): Return 0 on success and -1 on
3931         error.
3932         (mdraw_text_items): Check FRAME is writable.
3933         (mdraw_per_char_extents): Implement body.
3934
3935         * Makefile.am (lib_LTLIBRARIES): Include libm17n-gui.la and
3936         libm17n-gd.la.
3937         (OPTIONAL_LD_FLAGS): Include @FONTCONFIG_LD_FLAGS@.
3938         (GUI_SOURCES): Delete it.
3939         (libm17n_X_la_SOURCES): Don't include ${GUI_SOURCES}.
3940         (libm17n_gui_la_SOURCES, libm17n_gui_la_LIBADD)
3941         (libm17n_gui_la_LDFLAGS, libm17n_gd_la_SOURCES)
3942         (libm17n_gd_la_LIBADD, libm17n_gd_la_LDFLAGS): New targets.
3943         (linkgui_LDADD): Set to libm17n-gui.la
3944         (linkgui_LDFLAGS): New target.
3945         (SRC): Include ${libm17n_gui_la_SOURCES} and
3946         ${libm17n_gd_la_SOURCES}.
3947
3948 2004-05-24  Kenichi Handa  <handa@m17n.org>
3949
3950         * draw.c (draw_background): Don't draw background even if
3951         rface->face.property[MFACE_BACKGROUND] is not Mnil.
3952
3953 2004-05-22  Kenichi Handa  <handa@m17n.org>
3954
3955         * m17n-X.c (xft_open_font): Fix anti_alias setting.
3956
3957 2004-05-20  Kenichi Handa  <handa@m17n.org>
3958
3959         * m17n-gui.h (MFaceHookFunc): Change this function type to void.
3960
3961         * m17n-gui.c: Include "plist.h".
3962         (mframe): If PLIST is NULL, initialize it to emply plist.
3963
3964         * m17n-X.c (build_font_list): Don't set property[MFONT_TYPE].
3965         (xft_driver): New variable.
3966         (xft_select, close_xft, xft_open_font, xft_open, xft_close)
3967         (xft_find_metric, xft_render): New function.
3968         (mwin__init): Adjusted for the new mfont__driver_list.
3969         (mwin__open_device): Assume arg PARAM is not NULL.  Push a newly
3970         generated face to PARAM.
3971         (mwin__realize_face): Fix setting of box colors.  Don't call hook
3972         function here.
3973         (mwin__draw_hline): New function.
3974         (mwin__xft_close, mwin__xft_open, mwin__xft_get_metric)
3975         (mwin__xft_render): Delete these function.
3976
3977         * internal-gui.h (struct MFrame): New member tick.
3978         (struct MGlyphString): New member tick.
3979         (mwin__draw_rect, mwin__draw_empty_boxes): Extern them.
3980         (mwin__xft_open, mwin__xft_close, mwin__xft_get_metric)
3981         (mwin__xft_render): Delete extern.
3982
3983         * fontset.c (mfont__lookup_fontset): Make the code simpler.
3984         (mfontset): Always increment the reference count of returned
3985         object.
3986
3987         * font-ft.c (mfont__ft_fini): Don't include <otf.h> here.
3988         (MFTInfo): Moved to font.h.
3989         (ft_iso8859_1_font_list): Delete this variable.
3990         (set_font_info): Don't set font->property[MFONT_TYPE].
3991         (set_font_info): Don't udpate ft_iso8859_1_font_list.
3992         (add_font_info): Change type to void.
3993         (fc_list): Change anme from xft_list.  Caller changed.  Include
3994         FC_FOUNDRY and FC_PIXEL_SIZE in FcObjectSet.
3995         (mfont__ft_driver): Change name from ft_driver.  Caller changed.
3996         (ft_select): Check HAVE_FONTCONFIG instead of HAVE_XFT2.
3997         (close_ft): Don't call mwin__xft_close.  Unref
3998         ft_info->extra_info.
3999         (ft_open): Don't setup ft_info->fontname.  Don't call
4000         mwin__xft_open.
4001         (ft_find_metric): Don't call mwin__xft_get_metric.
4002         (ft_encode_char): Call rfont->driver->open instead of ft_open.
4003         (ft_render): Don't check HAVE_XFT2.  Don't call mwin__xft_render.
4004         (mfont__ft_init): Adjusted for new mfont__driver_list.
4005         (mfont__ft_fini): Don't unref ft_iso8859_1_font_list.
4006
4007         * font.c (mfont__driver_list): Make it MPlist.
4008         (mfont__init): Adjust initialization of mfont__driver_list.
4009         (mfont__fini): Free mfont__driver_list.
4010         (mfont__set_spec_from_face): Don't set spec->property[MFONT_TYPE].
4011         (mfont__select): Adjusted for the new mfont__driver_list.
4012
4013         * font.h (enum MFontProperty): Delete MFONT_TYPE.
4014         (mfont__drirver_list): Adjust prototype.
4015         (MFTInfo): Move to here from fron.c.  Deleve member fontname.
4016
4017         * face.h (struct MFace): Delete member realized_face_list, add
4018         member frame_list.
4019         (struct MRealizedFace): Delete member need_update
4020         andnofont_rface, add member non_ascii_list.
4021         (mface__update_frame_face): Extern it.
4022
4023         * face.c (hline_prop_list, box_prop_list, noop_hook): New
4024         variables.
4025         (get_hline_create, get_box_create): New functions.
4026         (find_realized_face): Cancel previous change.  Arg RFONT deleted.
4027         Use memcmp.
4028         (free_face): Cancep previous change.  Free face->frame_list.
4029         (serialize_hline): Do nothing if hline->width is zero.
4030         (serialize_box): Do nothing if box->width is zero.
4031         (mface__init): Setup all properties of mface__default.
4032         (mface__fini): Free hline_prop_list and box_prop_list.
4033         (mface__realize): Cancel previous change.  Update
4034         face->frame_list.  Setup rface->non_ascii_list.
4035         (mface__for_chars): Update rface->non_ascii_list.
4036         (mface__free_realized): Free rface->non_ascii_list.
4037         (mface__update_frame_face): New function.
4038         (mface): Initialize face->frame_list.
4039         (mface_copy): Likewise.  Just copy MFACE_HLINE and MFACE_BOX
4040         properties.
4041         (mface_merge): Likewise.
4042         (mface_put_prop): If key is Mhline or Mbox, get value by
4043         get_hline_create or get_box_create respectively.
4044         (mface_put_prop): Update frame->tick and call
4045         mface__update_frame_face if necessary.
4046         (mface_update): Do nothing if func is noop_hook.
4047
4048         * draw.c (render_glyphs): If a font is not found, use
4049         mwin__draw_empty_boxes.
4050         (alloc_gstring): Initialize gstring->tick.
4051         (get_gstring): Check gstring->tick.
4052
4053 2004-05-17  Kenichi Handa  <handa@m17n.org>
4054
4055         * face.c (find_realized_face): Return value changed.  If RFONT is
4056         NULL, avoid unnecessary checking.
4057         (free_face): Free face->realized_face_list.
4058         (mface__realize): Adjusted for the change of find_realized_face.
4059         If it returns a realized face that needs update, free it and
4060         realize a new one.  Push a new realized face to
4061         frame->realized_face_list instead of appending.
4062         (mface__for_chars): Adjusted for the change of find_realized_face.
4063         Short cut if the required font is in rface->ascii_rface.
4064         (mface_put_prop): Free old value if necessary.  Set need_update
4065         member of realized faces to 1.
4066
4067         * face.h (struct MFace): Delete member tick, add member
4068         realized_face_list.
4069         (struct MRealizedFace): Delete member tick, add member
4070         need_update.
4071
4072 2004-05-13  Kenichi Handa  <handa@m17n.org>
4073
4074         * m17n-X.c (mwin__xft_open): Destroy unnecessary patterns.
4075
4076 2004-05-12  Kenichi Handa  <handa@m17n.org>
4077
4078         * internal-gui.h (mwin__xft_open): Arguemnt name changed.
4079
4080         * m17n-X.c (mwin__xft_open): Argument changed to fontname and
4081         parse it XftNameParse.
4082
4083         * font-ft.c (MFTInfo) [HAVE_XFT2]: New member fontname.
4084         (all_fonts_scaned): New variable.
4085         (set_font_info): FAMILY may be Mnil.
4086         (add_font_info): Argument changed.
4087         (xft_list): Call add_font_info in it.
4088         (ft_list): Likewise.
4089         (ft_select): Make it work in the case family is Mnil.
4090         (ft_open) [HAVE_XFT2]: Setup ft_info->fontname.
4091         (mfont__ft_fini): Set all_fonts_scaned to 0.
4092
4093         * fontset.c (mfont__lookup_fontset): Don't repeatedly try a font
4094         that is failed to open.
4095
4096 2004-05-10  Kenichi Handa  <handa@m17n.org>
4097
4098         * m17n-X.c (mwin__xft_render): Don't use anti-alias if the
4099         device's depth is 1 (i.e. monochrome).
4100
4101         * Makefile.am (OPTIONAL_LD_FLAGS): Change the order of elements
4102         to work around the problem of libtool.
4103
4104         * font-ft.c: Include <freetype/ftbdf.h>.
4105         (Municode_bmp, Municode_full, Miso10646_1, Miso8859_1): New
4106         variables.
4107         (mfont__ft_init): Initialize them.
4108         (ft_iso8859_1_font_list): New variable.
4109         (set_font_info): Detect a font containing iso8859-1 glyphs and
4110         register it in ft_iso8859_1_font_list.  If the font is not
4111         scalable, assume it as BDF or PCF font and setup SIZE and RESY
4112         properties of the font from its properties.
4113         (add_font_list): If the font is not scalable, check if it is BDF
4114         or PCF font.  If not, ignore it.
4115         (ft_select): If FAMILY is Mnil, return NULL only if the requested
4116         registry is not iso8859-1.
4117         (ft_select) [not HAVE_XFT2]: If FAMILY is Mnil, select one from
4118         ft_iso8859_1_font_list.
4119         (ft_find_metric): If the font is not scalable, assume it as BDF
4120         or PCF, and get a metric from its properties.
4121         (mfont__ft_fini): Free ft_iso8859_1_font_list.
4122
4123 2004-05-07  Kenichi Handa  <handa@redhat.m17n.org>
4124
4125         * Makefile.am (libm17n_la_LIBADD): Include -ldl.
4126         (libm17n_la_LDFLAGS): Delete it.
4127         (noinst_PROGRAMS): Renamed from bin_PROGRAMS.
4128         (install-binPROGRAMS, uninstall-binPROGRAMS): Delete them.
4129
4130 2004-05-06  Kenichi Handa  <handa@m17n.org>
4131
4132         * draw.c (compose_glyph_string): Fix previous change.
4133
4134 2004-04-30  Kenichi Handa  <handa@m17n.org>
4135
4136         * font-ft.c (ft_list): Delete unused variable `result'.
4137         (ft_render): Fix for the case that bitmap.pitch < bitmap.width.
4138
4139 2004-04-27  Kenichi Handa  <handa@m17n.org>
4140
4141         * m17n-X.c: Include config.h
4142         [HAVE_XFT2]: Include <X11/Xft/Xft.h>.
4143         (GCInfo) [HAVE_XFT2]: New member xft_color_fore, xft_color_back.
4144         (MWDevice) [HAVE_XFT2]: New member xft_draw.
4145         (FRAME_CMAP, FRAME_VISUAL): New macros.
4146         (free_device) [HAVE_XFT2]: Destroy device->xft_draw.
4147         (xfont_driver): Make it static.
4148         (mwin__open_device) [HAVE_XFT2]: Setup device->xft_draw.
4149         (mwin__realize_face) [HAVE_XFT2]: Setup info->xft_color_fore and
4150         info->xft_color_back.
4151         (MXftFontInfo) [HAVE_XFT2]: New type.
4152         (mwin__xft_close) [HAVE_XFT2]: New function.
4153         (mwin__xft_open) [HAVE_XFT2]: New function.
4154         (mwin__xft_get_metric) [HAVE_XFT2]: New function.
4155         (mwin__xft_render) [HAVE_XFT2]: New function.
4156
4157         * internal-gui.h [HAVE_FREETYPE]: Include FT_FREETYPE_H.
4158         (mwin__xft_open, mwin__xft_close) [HAVE_FREETYPE]: New externs.
4159         (mwin__xft_get_metric, mwin__xft_render) [HAVE_FREETYPE]: New
4160         externs.
4161
4162         * font.h [HAVE_FREETYPE]: Include FT_FREETYPE_H.
4163
4164         * font-ft.c: Don't include FT_FREETYPE_H here.
4165         [HAVE_XFT2]: Include <fontconfig/fontconfig.h>.
4166         (fontconfig_initialized, fc_config) [HAVE_XFT2]: New variables.
4167         (MFTInfo): New member charmap_index.
4168         (MFTInfo) [HAVE_XFT2]: New member xft_info.
4169         (check_otf_filename): Renamed from check_filename.  Return value
4170         changed.
4171         (ft_set_property): This function deleted.
4172         (set_font_info): New function.
4173         (add_font_list): Argument changed.  Add multiple fonts.
4174         (xft_list) [HAVE_XFT2]: New function.
4175         (ft_list) [not HAVE_XFT2]: New function.
4176         (ft_select): Add code for Xft.
4177         (close_ft): Likewise.
4178         (ft_open): Likewise.
4179         (ft_find_metric): Likewise.
4180         (ft_encode_char): Likewise.
4181         (ft_render): Likewise.
4182
4183         * makefile.am (OPTIONAL_LD_FLAGS): Include @XFT2_LD_FLAGS@.
4184
4185 2004-04-26  Kenichi Handa  <handa@m17n.org>
4186
4187         * textprop.c (mtext_attach_property): Declare the return type as
4188         `int'.
4189
4190 2004-04-21  Kenichi Handa  <handa@m17n.org>
4191
4192         * Makefile.am (OPTIONAL_LD_FLAGS): Include @XFT2_LD_FLAGS@
4193
4194 2004-04-09  Kenichi Handa  <handa@m17n.org>
4195
4196         * font-flt.c (struct): New members seq_beg, seq_end, seq_from,
4197         seq_to.
4198         (load_command): Setup above members.
4199
4200 2004-04-05  Kenichi Handa  <handa@m17n.org>
4201
4202         * m17n-X.c (xfont_encode_char): Fix checking of byte1 and byte2.
4203
4204 2004-03-30  Kenichi Handa  <handa@m17n.org>
4205
4206         * m17n-X.c (xfont_encode_char): Return MCHAR_INVALID_CODE if code
4207         >= 0x10000.
4208
4209         * m17n-core.h (M17NLIB_PATCH_LEVEL): Changed to 2.
4210         (M17NLIB_VERSION_NAME): Changed to 1.0.2.
4211
4212 2004-03-29  Kenichi Handa  <handa@m17n.org>
4213
4214         * Version 1.0 Patch Level 2 released.
4215
4216 2004-03-29  Kenichi Handa  <handa@m17n.org>
4217
4218         * charset.c (make_charset): Set charset->fully_loaded and
4219         charset->simple correctly.  Don't try to get charset->min_char and
4220         charset->max_char for a charset of method subset and superset.
4221         Don't load a mapping file here.
4222         (mcharset__init): Set unified_max.
4223         (mcharset__load_from_database): Free a working plist.
4224
4225         * coding.c (mcoding__fini): Free all malloced data.
4226
4227         * input-gui.c (win_create_ic): Set control.as_image for preediting
4228         to 0.
4229
4230         * internal.h (M17N_OBJECT_REGISTER): Check the member `used' (not
4231         `count') to initialize the array.
4232
4233         * locale.c (mlocale_set): Fix the order of M17N_OBJECT_REF and
4234         M17N_OBJECT_UNREF.
4235
4236         * m17n-X.c (xfont_render): If rface->rfont is null, draw a
4237         rectangle.
4238         (mwin__create_window): Fix bug of setting a background pixel of a
4239         new window.
4240         (mwin__adjust_window): Clear the window before drawing.
4241
4242         * m17n-core.c (mdebug__report_object): Free array->objectes if
4243         necessary.
4244         (m17n_init_core): Don't set report_header_printed to 0 here.
4245         Fix debugging information.
4246         (m17n_fini_core): Set report_header_printed to 0 here.
4247
4248         * m17n-core.h (mplist_deserialize): Extern it.
4249
4250         * m17n-gui.c (m17n_fini_win): Fix debugging information.
4251
4252         * m17n.c (m17n_fini): Fix debugging information.
4253
4254         * mtext.c (mtext__adjust_foramt): New function.
4255
4256         * mtext.h (mtext__adjust_foramt): Extern it.
4257
4258         * plist.c (mplist_deserialize): Renamed from mplist__deserialize.
4259
4260         * plist.h (mplist__deserialize): Don't extern it.
4261
4262         * symbol.c (msymbol__fini): Set freed_symbols to 0.  Set all
4263         elements of symbol_table to NULL.  Report about created and freed
4264         symbols if MDEBUG_FINI is set.
4265
4266 2004-03-22  Kenichi Handa  <handa@m17n.org>
4267
4268         * m17n-core.c (m17n_init_core): Set merror_code to MERROR_NONE.
4269
4270         * m17n.c (m17n_init): Fix the way of checking merror_code.
4271
4272         * m17n-gui.c (m17n_init_win): Fix the way of checking merror_code.
4273
4274 2004-03-22  Kenichi Handa  <handa@m17n.org>
4275
4276         * fontset.c (realize_font_group): Adjust the font size by
4277         mfont__resize before selecting a font.
4278
4279         * font-ft.c (mfont__ft_init): Add oblique and boldoblique.
4280
4281 2004-03-19  Kenichi Handa  <handa@m17n.org>
4282
4283         * Version 1.0 Patch Level 1 released.
4284
4285 2004-03-19  Kenichi Handa  <handa@m17n.org>
4286
4287         * m17n-core.h (M17NLIB_PATCH_LEVEL): New macro.
4288
4289         * m17n-core.c (M17NLIB_PATCH_LEVEL): Describe it.
4290
4291 2004-03-19  Kenichi Handa  <handa@m17n.org>
4292
4293         Re-apply the changes forgotten in the released version.
4294
4295         * charset.c (mcharset__load_from_database): Call
4296         mchar_define_charset.
4297
4298         * coding.c (encode_unsupporeted_char): Put Mcoding text property.
4299         (mconv_encode_range): Put Mcoding text property.
4300
4301 2004-03-18  Kenichi Handa  <handa@m17n.org>
4302
4303         * draw.c (Mdepth): New variable.
4304         (visual_order): Delete unused local var `pos'.
4305         (compose_glyph_string): Fix for the case that gstring->glyphs is
4306         realloced.  Stop generating glyphs at TO.  Fix handling of
4307         control charaters.
4308         (layout_glyphs): Get metrics of all glyphs in advance.  Set
4309         lbearing and rbearing of base of composition glyph correctly.
4310         Handle left-overhang glyphs correctly.
4311         (alloc_gstring): New arg frame.  Set gstring->anti_alias.  Caller
4312         changed.
4313         (dump_combining_code): Change the defualt off_x character to ".".
4314         (mdraw__init): Initialize Mdepth.
4315
4316         * face.c (work_gstring): New variable
4317         (mface__init): Initialize work_gstring.
4318         (mface__fini): Free work_gstring.glyphs.
4319         (mface__realize): Don't handle videomode property here.  Adjusted
4320         for the change of mfont__get_metric.
4321         (mface__for_chars): Adjusted for the change of mfont__get_metric.
4322
4323         * face.h (enum face_gc): Moved to m17n-X.c.
4324
4325         * font.h (struct MFontDriver): Arguments of find_metric changed.
4326         (mfont__select): Prototype adjusted.
4327         (mfont__get_metric): Likewise.
4328         (mfont__ft_drive_otf): Likewise.
4329         (mfont__flt_run): Likewise.
4330         
4331         * font.c (mfont__select): New argument layouter.  If layouter is
4332         different in the registered font, make a new copy of realized
4333         font.
4334         (mfont__get_metric): Argument changed.  Get metrics of multiple
4335         glyphs.
4336         (mfont_find): Call mfont__select with layouter as Mnil.
4337
4338         * font-flt.c (FontLayoutContext): New member rfont.
4339         (run_otf): Adjusted for the change of mfont__ft_drive_otf.
4340         (mfont__flt_run): Argument changed.  Initialize ctx.rfont.
4341
4342         * font-ft.c (ft_find_metric): Arguments changed.  Get metrics of
4343         multiple glyphs.
4344         (NUM_POINTS): New macro.
4345         (MPointTable): New type.
4346         (ft_render): Use mwin__draw_points instead of mwin__draw_bitmap.
4347         (mfont__ft_drive_otf): New argument rfont.
4348
4349         * fontset.c (realize_font_group): Adjusted for the changed of
4350         mfont__select.
4351         (check_fontset_element): This function deleted.
4352
4353         * input-gui.c (adjust_window_and_draw): Locate a preedit window
4354         off the parent window if the preedit text is zero length.
4355
4356         * internal-gui.h (struct MFrame): New members foreground,
4357         background, videomode, font.
4358         (struct MGlyphString): New member anti_alias.
4359         (MDrawPoint): New type.
4360         (mwin__draw_bitmap): Prototype deleted.
4361         (mwin__draw_points): Prototype added.
4362
4363         * m17n-gui.h (MDrawControl): New member anti_alias.
4364
4365         * m17n-gui.c (free_frame): Free frame->font.
4366         (mframe): Set the fontset of frame->face to the default fontset.
4367
4368         * m17n-X.c (RGB_GC): New type.
4369         (enum gc_index): Renamed from enum face_gc.  Member names changed.
4370         (GCInfo): New typel
4371         (struct MWDevice): Members foreground and background deleted.  New
4372         member scratch_gc, gc_list.
4373         (DEFAULT_FONT, FALLBACK_FONT): New macros.
4374         (free_device): Free GCs in device->gc_list.
4375         (get_rgb_gc): New function.
4376         (get_gc): Renamed and argument changed from get_color.
4377         (get_gc_for_anti_alias): New function.
4378         (xfont_find_metric): Arguments changed.  Get metrics of multiple
4379         glyphs.
4380         (set_region): Argument changed.  Caller changed.
4381         (xfont_render): Allways set a font in gc.
4382         (x_error_handler, x_io_error_handler): Define only if
4383         X_SET_ERROR_HANDLER is defined.
4384         (mwin__open_device): Create device->scratch_gc.  Set members
4385         foreground, background, and videomode of frame.  Call
4386         XSetErrorHandler and XSetIOErrorHandler only if
4387         X_SET_ERROR_HANDLER is defined.
4388         (struct gc_list): Deleted.
4389         (REGISTER_GC, UNREGISTER_GC): These macros deleted.
4390         (mwin__realize_face): Adjusted for the change of the format of
4391         rface->info and the charge of set_region.
4392         (mwin__free_realized_face, mwin__fill_space, mwin__draw_hline)
4393         (mwin__draw_box): Likewise.
4394         (mwin__draw_bitmap): This function deleted.
4395         (mwin__draw_points): New function.
4396         (mwin__verify_region): Adjusted for the change of the format of
4397         rface->info and the charge of set_region.
4398         (mwin__create_window): Inherit backgound pixel from parent.
4399         (mwin__dump_gc): Adjusted for the change of the format of
4400         rface->info.
4401
4402 2004-03-16  Kenichi Handa  <handa@m17n.org>
4403
4404         * m17n-X.c (mwin__parse_event): Fix handling of modifier keys.
4405
4406         * input.c (M_key_alias): New variable.
4407         (handle_key): Try M_key_alias property of a key too.
4408         (minput__init): Initialize M_key_alias.  Give that property to
4409         symbols in one_char_symbol.  Fix bug of initializing
4410         one_char_symbol.
4411
4412         * draw.c (compose_glyph_string): Don't handle
4413         ignore_formatting_char here.  Include formatting characters in the
4414         range processed by a FTL.
4415         (layout_glyph_string): Handle ignore_formatting_char here.
4416
4417 2004-03-12  Kenichi Handa  <handa@m17n.org>
4418
4419         * input-gui.c (win_create_ic): Enable bidi in status control.
4420
4421         * draw.c (visual_order): Avoid re-ordering of combining glyphs only.
4422
4423 2004-03-09  Kenichi Handa  <handa@m17n.org>
4424
4425         * input.c (load_input_method): If title is not specified, use the
4426         input method name as title.
4427
4428         * m17n-X.c (get_color): Make it static.
4429         (xim_create_ic, xim_destroy_ic, x_error_handler)
4430         (x_io_error_handler): Likewise.
4431
4432 2004-03-01  Kenichi Handa  <handa@m17n.org>
4433
4434         * Version 1.0 released.
4435
4436 \f
4437 Copyright (C) 2003, 2004
4438   National Institute of Advanced Industrial Science and Technology (AIST)
4439   Registration Number H15PRO112
4440
4441 This file is part of the m17n library.
4442
4443 The m17n library is free software; you can redistribute it and/or
4444 modify it under the terms of the GNU Lesser General Public License
4445 as published by the Free Software Foundation; either version 2.1 of
4446 the License, or (at your option) any later version.
4447
4448 The m17n library is distributed in the hope that it will be useful,
4449 but WITHOUT ANY WARRANTY; without even the implied warranty of
4450 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
4451 Lesser General Public License for more details.
4452
4453 You should have received a copy of the GNU Lesser General Public
4454 License along with the m17n library; if not, write to the Free
4455 Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
4456 Boston, MA 02110-1301, USA.