*** empty log message ***
[m17n/m17n-lib.git] / src / ChangeLog
index 74b95c0..736aac4 100644 (file)
+2007-05-18  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (config_command): Set NAME before using it.
+
+2007-05-17  Kenichi Handa  <handa@m17n.org>
+
+       * language.c (mlang__fini): Fix previous change.
+
+2007-05-16  Kenichi Handa  <handa@m17n.org>
+
+       * plist.c (free_plist): Cancel the last change.
+       (write_element): Check if PLIST is nested.
+       (mplist__from_plist): Label a plist as nested if appropriate.
+       (mplist__from_alist): Label a plist as nested.
+       (mplist__conc): Check the value of PL before referring it.  Label
+       a plist as nested if appropriate.
+       (mplist_copy): Label a plist as nested if appropriate.
+       (mplist_put_func): Return Mnil if KEY is a managing key.
+       (mplist_push): Label a plist as nested if appropriate.
+
+       * plist.h (MPLIST_SET_NESTED_P): Return 1 iff plist->control.flag
+       is set as nested.
+
+       * language.c (mlang__fini): Unref each element of langname_list.
+
+2007-05-14  Kenichi Handa  <handa@m17n.org>
+
+       * language.c: Include <string.h> and <locale.h>.
+       (langname_list): New variable.
+       (load_lang_script_list): Exclude invalid list elements.
+       (mlang__init): Initialize langname_list.
+       (mlang__fini): Unref langname_list.
+       (mlanguage__info): Adjusted for the change of English
+       name (symbol->M-text).
+       (mlanguage_name): Label it as obsolete.
+       (mlanguage_name_list): New function.
+
+       * m17n.h (mlanguage_name_list): Extern it.
+
+       * locale.c (make_locale): Fix setting of members of locale.
+
+       * plist.c (free_plist): Unref also nested plist.
+
+2007-05-11  Kenichi Handa  <handa@m17n.org>
+
+       * coding.c (mconv_reset_converter): Set internal->used to 0.
+
+2007-05-08  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (check_description): Force copying the translated text.
+
+2007-05-02  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (minput_save_config): Unref unnecessary plist.  Use
+       free_im_list to free im_config_list.
+
+2007-04-20  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (config_command): Fix previous change again.
+       (config_variable): Likewise.
+       (minput_config_command): Fix for the case of setting back to
+       default.
+       (minput_config_variable): Likewise.
+       (minput_save_config): Include nil as documentation of customized
+       command/variable.
+
+2007-04-05  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (config_command): Fix previous change.
+       (config_variable): Likewise.
+
+       * plist.c (mplist_get_func): Fix for backward compatiblity.
+
+2007-04-04  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (minput_get_command, minput_config_command): Fix example
+       codes.
+
+2007-03-29  Kenichi Handa  <handa@m17n.org>
+
+       These changes are to avoid unsafe casting of a function pointer.
+
+       * face.h (enum MFaceProperty): Delete MFACE_HOOK_FUNC.
+       (struct MFace): New member hook.
+
+       * face.c (serialize_face): Adjusted for the change of MFace.
+       (deserialize_face): Likewise.
+       (mface__init): Likewise.  Use msymbol_put_func.
+       (mface__realize): Adjusted for the change of MFace.  Avoid
+       compiler warning.
+       (mface_get_prop): Adjusted for the change of MFace.
+       (mface_put_prop): Likewise.
+       (mface_get_hook): New function.
+       (mface_put_hook): New function.
+       (mface_update): Adjusted for the change of MFace.
+
+       * input-gui.c (win_callback): Use mplsit_get_func.
+       (minput__win_init): Use mplsit_put_func.
+
+       * input.c (take_action_list): Use mplist_get_func.
+       (init_ic_info): Likewise.
+       (fini_ic_info): Likewise.
+       (minput_callback): Likewise.
+       (minput__init): Use mplist_put_func.
+
+       * language.c (mlang__init): Use msymbol_put_func.
+
+       * m17n-core.h (M17NFunc): New function type.
+       (M17N_FUNC): New macro.
+       (msymbol_put_func, msymbol_get_func): Extern them.
+       (mplist_put_func, mplist_get_func): Extern them.
+       
+       * m17n-gui.h (mface_get_hook, mface_put_hook): Extern them.
+
+       * m17n-gui.c (mframe): Add a proper casting.
+
+       * plist.h (struct MPlist): Make the member val a union.
+       (MPLIST_VAL): Adjusted for the above change.
+       (MPLIST_FUNC): New macro.
+       (MPLIST_VAL_FUNC_P, MPLIST_SET_VAL_FUNC_P): New macros.
+
+       * plist.c (mplist_put_func, mplist_get_func): New functions.
+
+       * symbol.c (msymbol__fini): Use MPLIST_VAL.
+       (msymbol_put_func, msymbol_get_func): New functions.
+
+       * textprop.c (mtext_serialize): Use msymbol_get_func.
+       (mtext_deserialize): Likewise.
+
+2007-03-28  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (get_candidate_list): Avoid unnecessary unref.
+
+2007-03-23  Kenichi Handa  <handa@m17n.org>
+
+       * database.c (mdatabase__update): Unref plist at the tail.
+
+2007-03-21  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (update_custom_info): Fix for the case "name == Mnil &&
+       extra != Mnil".
+       (config_command): Fix for the case that configuration is
+       cancelled.
+       (config_variable): Likewise.
+       (minput_config_command): If keyseqlist is an empty list, cancel
+       the customization.
+       (minput_config_variable) If value is an empty list, cancel the
+       customization.
+       (minput_save_config): Handle cancellation of config and customize
+       correctly.
+
+2007-03-15  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (minput_config_variable): Check custom->vars (not
+       custom->cmds).
+
+2007-03-01  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (reload_im_info): Setup cmds, vars, and title of
+       im_info.
+       (check_variable_value): Fix the return value.
+
+       * database.c (mdatabase__check): If necessary, update database and
+       find a new file.
+
+2007-02-28  Kenichi Handa  <handa@m17n.org>
+
+       * database.c (get_dir_info): Set dir_info->status to
+       MDB_STATUS_OUTDATED.
+       (check_version): New function.
+       (register_database): Don't call find_database.
+       (register_databases_in_files): Don't register a database of
+       invalid version.
+       (mdatabase__update): Likewise.  Avoid unnecessary scanning.
+
+       * database.h (enum MDatabaseStatus): New membes MDB_STATUS_UPDATED
+       and MDB_STATUS_OUTDATED.
+
+       * font.h (struct MFont): Types of members type, source, and
+       spacing changed to unsigned.
+
+       * internal-gui.h (struct): Types of members category and type
+       changed to unsigned.
+
+       * internal.h (struct MText): Types of members format and coverage
+       changed to unsigned.
+
+       * m17n-core.h (M17NLIB_PATCH_LEVEL): Changed to 5.
+       (M17NLIB_VERSION_NAME): Changed to "1.3.5".
+
+2007-02-23  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (Mpop): New variable.
+       (fully_initialize): Initialize Mpop.
+       (parse_action_list): Handle Mpop.
+       (take_action_list): Likewise.
+       (handle_key): When a key is unhandled, shift to the initial state
+       only if the current state has no branch action.
+
+2007-02-12  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (get_preceding_char): Unref mt if necessary.
+       (get_following_char): Likewise.
+       (parse_action_list): Fix handling of `insert' action as
+       candidates.
+       (get_candidate_list): Fix for handling (("CANDIDATE1" ...)).
+       (take_action_list): Check invalid candidate list.
+
+2007-02-06  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (integer_value): Check also ic->produced for @-N.
+
+2007-01-26  Kenichi Handa  <handa@m17n.org>
+
+       * database.c (mdatabase__update): Check mdatabase__dir_list from
+       the tail.
+
+       * font-ft.c (STRDUP_LOWER): Don't ignore the tailing spaces.
+
+2007-01-12  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (handle_key): Handle a branch action of the initial
+       state correctly.
+
+2007-01-10  Kenichi Handa  <handa@m17n.org>
+
+       * m17n-gd.c (gd_render): Delete superfluous line.
+
+2006-12-26  Kenichi Handa  <handa@m17n.org>
+
+       * m17n.h (minput_callback): Extern it.
+
+       * input.h (minput__callback): Delte extern.
+
+       * input.c (get_surrounding_text): Adjusted for the change of
+       minput__callback to minput_callback.
+       (delete_surrounding_text): Likewise.
+       (minput_create_ic): Likewise.
+       (minput_destroy_ic): Likewise.
+       (minput_filter): Likewise.
+       (minput_set_spot): Likewise.
+       (minput_toggle): Likewise.
+       (minput_reset_ic): Likewise.
+
+       (preedit_commit): Reset ic->candidate_index, ic->candidate_from,
+       and ic->candidate_to to 0.
+       (minput_callback): Renamed from minput__callback.
+
+       * input-gui.c (win_callback): Adjusted for the change of
+       minput__callback to minput_callback.
+
+2006-12-15  Kenichi Handa  <handa@m17n.org>
+
+       * font-ft.c (ft_add_font): Fix typo.
+
+2006-12-06  Kenichi Handa  <handa@m17n.org>
+
+       * Version 1.3.4 released.
+
+2006-11-16  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (parse_action_list): Allow (undo 0).
+       (adjust_markers): New function.
+       (preedit_insert, preedit_delete): Call adjust_markers.
+       (preedit_replace): New function.
+       (update_candidate): Call preedit_replace instead of preedit_insert
+       and preedit_delete.
+       (filter): When ic_info->commit_key_head is nonzero, shift input
+       event keys even if there's no committed text.
+
+2006-11-10  Kenichi Handa  <handa@m17n.org>
+
+       * input.h (MInputContextInfo): New member commit_key_head.
+
+       * input.c (preedit_commit): Update ic_info->commit_key_head.
+       (take_action_list): Reset ic_info->commit_key_head on Mundo.
+       (filter): When committed, shift keys by ic_info->commit_key_head.
+
+2006-10-30  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (preedit_delete): Fix typo.
+       (take_action_list): Print more debugging information.  Allow
+       variable in arg of 'select' and `pushback'.
+
+       * database.c (gen_database_name): Don't put extra space.
+       (load_database): Print debugging information.
+       (register_databases_in_files): New arg headlen.  Callers changed.
+       (mdatabase__load_for_keys): Shorten debugging information.
+       (mdatabase_load): Don't print debugging information here.
+
+2006-10-27  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (marker_code): New arg surrounding.  Callers changed.
+       (surrounding_pos): Check if name[0] == '@'.
+       (integer_value): Fix for the change semantics of `@-N' and `@+N'.
+       (take_action_list): Likewise.
+       (get_preceding_char): If POS is zero, always call
+       get_surrounding_text.
+
+2006-10-19  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (load_variables): Fix setting of `global'.
+
+2006-10-16  Kenichi Handa  <handa@m17n.org>
+
+       * draw.c (draw_background): Be sure to set *to_x.
+       (render_glyph_string): If from == to, just return.
+
+2006-10-18  Kenichi Handa  <handa@m17n.org>
+
+       * database.c (get_dir_info): Return NULL if the directory name is
+       too long.
+       (register_databases_in_files): Call register_database with
+       MDB_STATUS_AUTO.
+       (mdatabase__update): Fix logic.  Call register_database with
+       MDB_STATUS_AUTO.
+       (mdatabase_define): Call register_database with
+       MDB_STATUS_EXPLICIT.
+
+       * input.c (delete_surrounding_text): Be sure to set members
+       preceding_text and following_text to NULL.
+       (shift_state): Save variable values in ic_info->vars_saved.
+       (preedit_commit): Don't print debug information here.  Don't
+       change ic_info->keys here.
+       (get_candidate_list): Don't ref plist.
+       (take_action_list): Don't unref return value of
+       get_candidate_list.  For undo, reset ic->produced and recover
+       ic_info->vars.  Be sure to set ic->candidate_list to NULL after
+       unref it.
+       (init_ic_info): Set ic_info->vars_saved.
+       (fini_ic_info): Unref ic_info->vars_saved.
+       (re_init_ic): Be sure to set ic->candidate_list to NULL after
+       unref it.
+       (filter): Be sure to set members preceding_text and following_text
+       to NULL.  Print debug information about produced text.  Delete
+       processed keys from ic_info->keys.
+
+       * input.h (MInputContextInfo): New member vars_saved.
+
+2006-10-16  Kenichi Handa  <handa@m17n.org>
+
+       * database.c (mdatabase__update): Fix the way to get db_info.
+
+2006-10-02  Kenichi Handa  <handa@m17n.org>
+
+       * font.h (struct MFont): New member `multiple_sizes'.  Bit-size of
+       `size' changed to 24.
+
+       * font.c (xlfd_unparse_name): Adjusted for the change of
+       MFont->size.
+       (font_score): Likewise.
+       (mfont__set_spec_from_face): Set spec->multiple_sizes to 0.
+
+       * m17n-X.c (MFontX, _MFontX): Deleted.
+       (SET_SIZE, HAVE_SIZE): Deleted.
+       (free_display_info): Adjusted for the change of
+       disp_info->font_list format.
+       (xfont_registry_list): Likewise.
+       (xfont_open): Likewise.
+       (xfont_list): Likewise.
+       (xfont_encode_char): Ignore size to find a realized font.
+       (MRealizedFontXft): Change the order of members to make it
+       compatible with MRealizedFontFT.
+
+2006-09-27  Kenichi Handa  <handa@m17n.org>
+
+       * font.c (mfont_match_p, mfont_open, mfont_encapsulate)
+       (mfont_close): Add comments.
+
+       * mtext-lbrk.c (mtext_line_break): Add comment.
+
+2006-09-26  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (minput_get_description): Handle description about
+       inclusion-only input methods.
+
+2006-09-21  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (M_gettext): New variable.
+       (fully_initialize): Initialize M_gettext.
+       (check_description): New function.
+       (load_commands): Call check_description.
+       (config_all_commands): Be sure to unref pl.
+       (load_variables): Call check_description.
+       (config_all_variables): Be sure to unref pl.
+       (load_im_info): Call check_description.
+
+       * internal.h [ENABLE_NLS]: Include <libintl.h> and define _.
+
+       * m17n-core.c (m17n_init_core) [ENABLE_NLS]: Call bindtextdoman
+       and bind_textdomain_codeset.
+
+       * Makefile.am (AM_CPPFLAGS): Add -DGETTEXTDIR=...
+
+2006-09-15  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (reload_im_info): Update custom and global info.
+       (init_ic_info): Fix previous change.
+
+2006-09-14  Kenichi Handa  <handa@m17n.org>
+
+       * database.c: Include <libgen.h>.
+       (mdatabase__lock): Make a directory if necessary.
+
+       * input.c (resolve_command): Adjusted for the format change of
+       configured_cmds member.
+       (load_commands, load_variables): Fix for errornous data handling.
+       (config_command, config_variable): New function.
+       (config_all_commands, config_all_variables): Renamed from
+       config_commands and config_variables.  Utilize the above function.
+       (check_variable_value): Argument changed.  Callers changed.
+       (load_im_info): Call config_all_commands and config_all_variables.
+       (init_ic_info): Adjusted for the format change of configured_vars
+       member.
+       (minput__init): Initialize Mcustomized, Mconfigured, and
+       Minherited.
+       (Mcustomized, Mconfigured, Minherited): New variables.
+       (minput_get_command): Be sure to return NULL if an input method
+       use no local command.
+       (minput_get_variable): Be sure to return NULL if an input method
+       use no local variable.
+       (minput_config_command, minput_config_variable)
+       (minput_save_config): Adjusted for the format change of
+       configured_cmds and configured_vars members.
+       
+       * plist.c (write_element): Delete superfluous ':'.
+
+2006-09-13  Kenichi Handa  <handa@m17n.org>
+
+       * m17n.h (Minherited, Mcustomized, Mconfigured): Extern them.
+       (minput_config_file): Extern it.
+
+       * draw.c (Minherited): Declaration moved to input.c.
+       (mdraw__init): Don't initialize Minherited here.
+
+       * database.c (mdatabase__unlock): Be sure to unlink uniq file.
+
+2006-09-07  Kenichi Handa  <handa@m17n.org>
+
+       * textprop.c (mtext_serialize): Call mplist__serialize with the
+       arg pretty 0.
+
+       * plist.h (mplist__serialize): Prototype adjusted.
+       (mplist__assq): Extern it.
+
+       * plist.c: Include <ctype.h>
+       (PUTC, PUTS): New macros.
+       (write_symbol): New function.
+       (write_element): New arg indent.
+       (dump_string, dump_plist_element): Delete them.
+       (mplist__from_string): New arg pretty.
+       (mplist__assq): New function.
+       (mdebug_dump_plist): Use write_element.
+
+       * mtext.c (mtext_cat_char): Allocate more memory.
+       (mdebug_dump_mtext): Don't escal a newline character.
+
+       * m17n.h (minput_get_command, minput_get_variable)
+       (minput_config_command, minput_config_variable)
+       (minput_save_config): Extern them.
+
+       * m17n-core.c: Include <string.h>.
+       (m17n_init_core): If the env. var. MDEBUG_OUTPUT_FILE is "stdout",
+       use the stream stdout instead of a file of that name.
+
+       * m17n-X.c (mwin__parse_event): Fix handling of Shift and Control
+       modifiers.
+
+       * internal.h (MFAILP, MDEBUG_PRINT0): New macros.
+       (MDEBUG_PRINT, MDEBUG_PRINT1, MDEBUG_PRINT2, MDEBUG_PRINT3)
+       (MDEBUG_PRINT4, MDEBUG_PRINT5): Use MDEBUG_PRINT0.
+       (MDEBUG_DUMP): Flush the stream.
+
+       * input.h (struct _MInputMethodInfo): Delete member im.  New
+       members mdb, language, name, extra, cmds, configured_cmds,
+       bc_cmds, vars, configured_vars, bc_vars, description, and tick.
+       (MInputContextInfo): New member tick.
+
+       * input.c: Big change to improve user-side input method
+       customization.  Here, list just public API changes.
+       (minput_get_commands, minput_get_variables)
+       (minput_assign_command_keys, minput_set_variable): Label them
+       obsolete.
+       (minput_get_command, minput_get_variable)
+       (minput_config_command, minput_config_variable)
+       (minput_save_config): New functions.
+       
+       * database.h (PATH_MAX): Define it if not yet defined.
+       (PATH_SEPARATOR): Likewise.
+       (enum MDatabaseStatus): New enum.
+       (struct MDatabaseInfo): Moved from database.c.  New members status,
+       time, lock_file, and uniq_file.
+       (mdatabase__update, mdatabase__file, mdatabase__lock, mdatabase__save)
+       (mdatabase__unlock): Extern them.
+
+       * database.c: Include <time.h>.
+       (MDB_DIR_LEN): Don't include the terminating '\0' in the length.
+       (GEN_PATH): Args changed.  Callers changed.
+       (struct MDatabaseInfo): Moved to database.h.
+       (struct MDatabase, mdb_list): Deleted.
+       (mdatabase__list): New var.
+       (get_database_filename): Deleted.  Callers changed to use
+       get_database_file.
+       (find_file, get_database_file): New files.
+       (get_dir_info): Initialize new members of MDatabaseInfo.
+       (find_database): Arg chagnded.  Callers changed.
+       (free_db_info, register_database, register_databases_in_files):
+       New functions.
+       (update_database_list): Deleted.
+       (mdatabase__init): Initialize mdatabase__list instead of mdb_list.
+       (mdatabase__fini): Finalize mdatabase__list instead of mdb_list.
+       (mdatabase__update): New function.
+       (mdatabase__check): Return value changed.
+       (mdatabase__file, mdatabase__lock, mdatabase__save)
+       (mdatabase__unlock): New functions.
+
+2006-08-30  TAKAHASHI Naoto  <ntakahas@m17n.org>
+
+       * input.c (get_surrounding_text): Return -2 when surrounding text
+       is unavailable.
+       (get_following_char): Likewise.
+       (get_preceding_char): Likewise.
+       (minput__callback): Return 0 if there is a callback function,
+       otherwise -1.
+
+2006-08-17  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (reset_ic): Use shift_state to setup the current state.
+
+2006-08-02  Theppitak Karoonboonyanan  <thep@linux.thai.net>  (tiny change)
+
+       * Makefile.am (libm17n_la_LIBADD, libm17n_gui_la_LIBADD)
+       (libm17n_X_la_LIBADD, libm17n_gd_la_LIBADD, linkcore_LDADD)
+       (linkshell_LDADD, linkgui_LDADD): Use ${top_builddir}.
+
+2006-08-02  Kenichi Handa  <handa@m17n.org>
+
+       * plist.c (mdebug_dump_plist): Fix the 2nd arg to dump_plist_element.
+
+       * mtext.c (mdebug_dump_mtext): If not fullp, dump just text. 
+
+       * font-ft.c (ft_encapsulate): Add code for debugging.
+       (mfont__ft_drive_otf): Be sure to encode character before getting
+       metrics.
+
+2006-07-21  Kenichi Handa  <handa@m17n.org>
+
+       * draw.c (mdraw_text_extents): Fix previous typo.
+
+2006-07-19  Kenichi Handa  <handa@m17n.org>
+
+       * draw.c (gstring_width): New arg lbearing.
+       (render_glyph_string): Adjusted for the change of gstring_width.
+       (mdraw_text_extents): Fix lbearing of ink and line metrics.
+
+       * m17n-core.h (Mlanguage): Extern it.
+
+       * m17n.h (Mlanguage): Extern deleted. 
+
+       * mtext.c (mtext__init): Initialize Mlanguage.
+       (Mlanguage): Declaration moved from locale.c
+
+       * locale.c (mlocale__init): Don't initialize Mlanguage here.
+       (Mlanguage): Declaration moved to mtext.c.
+
+       * language.c (mlang__init): Don't initialize Mlanguage here.
+
+       * font.c (OTF_tag_name) [! HAVE_OTF]: New function.
+
+2006-07-14  Kenichi Handa  <handa@m17n.org>
+
+       * font-ft.c: Use FT_BDF_H macro.  Include fontconfig/fcfreetype.h.
+       (MRealizedFontFT): New member face_encapsulated.
+       (free_ft_rfont): Pay attention to ft_rfont->face_encapsulated.
+       (ft_gen_font): New function.
+       (ft_add_font): Use ft_gen_font.
+       (ft_list_script): Store lists in ft_script_list.
+       (ft_check_otf): New arg ft_face.  Caller changed.
+       (ft_check_language): Likewise.
+       (ft_check_script): Likewise.
+       (ft_encapsulate, ft_close): New functions.
+       (mfont__ft_driver): Initialize members encapsulate and close.
+       (mfont__ft_drive_otf): Use OTF_open_ft_face if it is available.
+
+       * font.h (struct MRealizedFont): New member encapsulating.
+       (struct MFontDriver): New members encapsulate and close.
+
+       * font.c (mfont__match_p): If FONT is realized, check capability
+       by font drivers's check_capability method.
+       (mfont_match_p, mfont_open, mfont_encapsulate, mfont_close): New
+       functions.
+
+       * m17n-X.c (xfont_list_family_names): Delete unused var.  Fix
+       declarations of foundry and fam local vars.
+       (xft_driver): Make it static.
+
+       * m17n-gui.h (mfont_match_p, mfont_open, mfont_encapsulate)
+       (mfont_close): Extern them.
+
+       * m17n-gd.c (device_open): Don't specify foundry and family of the
+       default face.
+
+2006-07-11  Kenichi Handa  <handa@m17n.org>
+
+       * m17n-gui.c (m17n_fini_win): Set null_interface.handle to NULL;
+
+2006-07-13  Kenichi Handa  <handa@m17n.org>
+
+       * font-ft.c (fc_build_charset): Return NULL if FcCharSet can't be
+       created.
+       (ft_check_script): Delete unused var.
+       (ft_list_capability): Likewise.
+
+       * font.c (mfont__get_capability): Setup cap->otf.
+       (Motf): Make it global.
+       (mfont_get_prop): Accept Mlanguage, Mscript, and Motf as key arg.
+
+       * font.h (MFontCapability): New member otf.
+
+       * language.c (mlang__fini): Delete unused vars.
+
+       * m17n-gui.h (Motf): Extern it.
+
+       * database.c (update_database_list): Delete unused vars.
+
+2006-07-07  Kenichi Handa  <handa@m17n.org>
+
+       * font-ft.c (DEVICE_DELTA): Fix typo.
+
+2006-07-06  Kenichi Handa  <handa@m17n.org>
+
+       * fontset.c (mfont__lookup_fontset): Don't ignore family and
+       foundry of face.
+
+2006-07-05  TAKAHASHI Naoto  <ntakahas@m17n.org>
+
+       * database.c: Update comments.
+
+2006-07-05  Kenichi Handa  <handa@m17n.org>
+
+       * database.c (PATH_MAX): Define it if not yet defined.
+       (PATH_SEPARATOR, USE_GEN_PATH, GEN_PATH, GEN_PATH_FROM_MT): New
+       macros.
+       (get_database_filename): Use GEN_PATH.
+       (get_dir_info): Don't include the last '/' in directory name.
+       (register_database): New function.
+       (update_database_list): Use register_database.  Search all
+       directories in mdatabase__dir_list for wildcard databases.
+       (mdatabase__init): Check "~/.m17n.d".
+
+2006-07-03  Kenichi Handa  <handa@m17n.org>
+
+       * input-gui.c (win_callback): If is ic->candidate_show zero, don't
+       push reverse property.
+
+       * plist.c (dump_plist_element): Fix previous change.
+
+2006-06-28  Kenichi Handa  <handa@m17n.org>
+
+       * font.c (xlfd_unparse_name): Suppress the heading '-' if not
+       necessary.
+
+       * draw.c (MbidiNSM): New variable.
+       (visual_order) [! HAVE_FRIBIDI]: Clear levels at first.  Pay
+       attention to bidi type NSM.
+       (mdraw__init): Initialize MbibiNSM.
+
+       * language.c (mscript__char_list): Fix finding a char-list element.
+
+       * plist.c (dump_string): Return number of printed characters.
+       (dump_plist_element): Print elements more compactly.
+
+2006-06-23  Kenichi Handa  <handa@m17n.org>
+
+       * Makefile.am (BUILD_LIBS): Don't increment it conditionally.
+       (include_HEADERS): Likewise.
+
+2006-06-23  TAKAHASHI Naoto  <ntakahas@m17n.org>
+
+       * language.c: Update documentation.
+
+2006-06-23  Kenichi Handa  <handa@m17n.org>
+
+       * font-ft.c (struct MFontFT): Delete member lang.
+       (free_ft_info): Don't unref member lang.  Destroy members langset
+       and charset.
+       (fc_parse_pattern): Last argument changed to MFontFT *.  Callers
+       changed.  Set members langset and charset.
+       (fc_init_font_list, fc_list_pattern, fc_build_charset): New
+       functions.
+       (ft_init_font_list, ft_has_char_list_p, ft_list_char_list): New
+       functions.
+       (ft_list_family) [HAVE_FONTCONFIG]: Include FC_CHARSET on objset.
+       (ft_list_family) [! HAVE_FONTCONFIG]: Call ft_init_font_list.
+       (ft_list_language) [HAVE_FONTCONFIG]: Check representative
+       characters at first.  If it fails, try listing by language names.
+       (ft_list_language) [! HAVE_FONTCONFIG]: Call ft_list_char_list.
+       (ft_check_language): Renamed from ft_check_lang.  Adjusted for the
+       change of MFontCapability.
+       (ft_list_capability): Likewise.  Try listing by languages, then by
+       scripts.  Check OTF at last.
+       (ft_check_script): New function.
+       (ft_select): Adjusted for the check of MFontCapability.
+       (ft_list_family_names): New function.
+       (ft_check_capability): If cap->script is not Mnil, call
+       ft_check_script.
+       (mfont__ft_driver): Initialize with ft_list_family_names.
+
+       * font.h (struct MFontDriver): New member list_fmaily_names.
+       (struct): Change member "MSymbol *lang" to "MSymbol language".
+
+       * font.c: Include "language.h".
+       (Motf): New variable.
+       (otf_script_list, load_otf_script_list): Delete it.
+       (find_script_from_otf_tag): Delete it.
+       (merge_capability): New function.
+       (mfont__init): Init Motf.
+       (mfont__fini): Don't unref otf_script_list.
+       (free_font_capability): Check cap->script_tag to determine if
+       OTF-related capability is set.
+       (mfont__get_capability): Call mscript__from_otf_tag.  Adjusted for
+       the change of type MFontCapability.
+       (mfont_put_prop): Call merge_capability for Mlanguage, Mscript,
+       and Motf properties.
+       (mfont_list): Call merge_capability for LANGUAGE arg.
+       (mfont_list_family_names): New function.
+
+       * input-gui.c: Typo in comments fixed.
+
+       * input.c: Typo in comments fixed.
+
+       * language.h (mlanguage__list): Delete it.
+       (mscript__char_list, mscript__otf_tag, mscript__from_otf_tag): New
+       functions.
+
+       * language.c: Include "mtext.h".
+       (M_script_lang_list): Delete it.
+       (language_list, script_list): New variables.
+       (load_lang_script_list, init_language_list, init_script_list): New
+       functions.
+       (mlang__init): Don't load language database here.
+       (mlang__fini): Unref language_list and script_list if not NULL.
+       (mlanguage__list): Delete it.
+       (mlanguage__info, mscript__info, mscript__char_list)
+       (mscript__otf_tag, mscript__from_otf_tag): New functions.
+       (mlanguage_list, mlanguage_code, mlanguage_name, mlanguage_text)
+       (mscript_list, mscript_language_list): New functions.
+
+       * m17n-gui.h (mfont_list_family_names): Extern it.
+
+       * m17n.h (mlanguage_list, mlanguage_code, mlanguage_name)
+       (mlanguage_text, mscript_list, mscript_language_list): Extern
+       them.
+
+2006-06-21  Kenichi Handa  <handa@m17n.org>
+
+       * m17n-X.c (xfont_driver): Initialize with
+       xfont_list_family_names.
+       (xfont_list_family_names): New function.
+       (xft_driver): Initialize with NULL for list_family_names member.
+       (device_init): Set list_family_names member of xft_driver to that
+       of mfont__ft_driver.
+
+2006-06-06  Kenichi Handa  <handa@m17n.org>
+
+       * fontset.c (mfont__lookup_fontset): Don't set *num to 1 if it is 0.
+
+2006-03-24  Kenichi Handa  <handa@m17n.org>
+
+       * font-ft.c (ft_open): Improve debug message.
+
+       * fontset.c (mfontset__get_font): Fix for the case that no font in
+       per_script list is available.
+
+2006-02-06  Kenichi Handa  <handa@m17n.org>
+
+       * Version 1.3.3 released.
+
+2006-02-22  Kenichi Handa  <handa@m17n.org>
+
+       * textprop.c: Fix some typos in documentation.
+
+       * plist.c: Fix some typos in documentation.
+
+       * m17n-core.h: Fix some typos in documentation.
+       (M17NLIB_PATCH_LEVEL): Updated to 3.
+       (M17NLIB_VERSION_NAME): Updated to "1.3.3".
+
+       * symbol.c: Fix some typos in documentation.
+
+       * mtext.c: Fix some typos in documentation.
+
+       * input.c: Fix several typos in documentation.
+
+2006-02-06  Kenichi Handa  <handa@m17n.org>
+
+       * Version 1.3.2 released.
+
+2006-02-03  Kenichi Handa  <handa@m17n.org>
+
+       * m17n-core.h (M17NLIB_PATCH_LEVEL): Updated to 2.
+       (M17NLIB_VERSION_NAME): Updated to "1.3.2".
+
+       * font.c (xlfd_parse_name): Fix handling of the name "nil".
+
+       * draw.c (layout_glyphs): Fix handling left_padding of
+       composition's base.
+
+       * m17n-gd.c (read_rgb_txt): Support HTML 4.0 color names.
+
+2006-02-02  Kenichi Handa  <handa@m17n.org>
+
+       * Makefile.am (include_HEADERS): Add m17n-gui.h and m17n-X.h only
+       if WITH_GUI is true.
+
+2006-01-25  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (resolve_expression): If the value of PLIST is a plist,
+       but the first element is not symbol, return 0.
+
+2006-01-17  Kenichi Handa  <handa@m17n.org>
+
+       * m17n-gd.c (gd_render): Use gdImageColorResolveAlpha only if
+       HAVE_GD is 2 or the greater.
+
+2006-01-16  Kenichi Handa  <handa@m17n.org>
+
+       * Version 1.3.1 released.
+
+2006-01-16  Kenichi Handa  <handa@m17n.org>
+
+       * m17n-gd.c (gd_render): Use gdImageColorResolveAlpha instead of
+       simulating anti-aliasing.
+
+       * m17n-core.h (M17NLIB_PATCH_LEVEL): Updated to 1.
+       (M17NLIB_VERSION_NAME): Updated to "1.3.1".
+
+2006-01-12  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (get_surrounding_text): Always pop ic->plist.
+       (reset_ic): Don't reset ic->plist.
+
+2006-01-10  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (preedit_commit): For debugging, print only commiting
+       charactes.  Don't set ic->candidate_show to 0.
+       (handle_key): Don't run branch-actions just by shifting to the
+       current state.
+       (reset_ic): Reset state_key_head and key_head of ic_info to 0.
+       Reset vars and plist.
+
+2006-01-07  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (load_branch): Confirm that maps is not NULL.
+
+2006-01-05  Kenichi Handa  <handa@m17n.org>
+
+       * input-gui.c (win_filter): Try to convert arg to key only when
+       arg is not NULL.
+
+       * plist.c (read_integer_element): If '#' and '-' are followed by
+       non-integer-constituent, read them as a part of a symbol.
+       (read_symbol_element): New arg C.
+       (read_element): Adjust args to read_symbol_element.
+
+       * input.c (load_macros): On overwriting a macro, free the old
+       definition.
+       (minput__init): Store Mmap in load_im_info_keys.
+       (minput_get_title_icon): If the input method has no title, be sure
+       to return NULL.
+       (minput_get_description): If the input method has no description,
+       be sure to return NULL.
+       (minput_get_variables): Fix documentation.
+       (handle_key): Pay attention to the case that key is Mnil.
+       (filter): Likewise.  Fix handling of such symbol as S-A.
+
+2005-12-22  Kenichi Handa  <handa@m17n.org>
+
+       * Version 1.3.0 released.
+
+2005-12-22  Kenichi Handa  <handa@m17n.org>
+
+       * font-ft.c (ft_list): If the specified font has no property,
+       return all fonts.
+
+2005-12-20  Kenichi Handa  <handa@m17n.org>
+
+       * character.c (mchar_get_prop): Check char_prop_list.
+       (mchar_put_prop, mchar_get_prop_table): Likewise.
+
+2005-12-18  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (minput_get_title_icon): If LANGUAGE is Mt, try also a
+       file name sans language.
+
+2005-12-16  TAKAHASHI Naoto  <ntakahas@m17n.org>
+
+       * input.c: Fix typo in comments.
+
+2005-12-14  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (minput_get_title_icon): Check the default icon for the
+       input method.
+
+2005-12-13  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (Mless_equal, Mgreater_equal): New variables.
+       (parse_expression, resolve_expression, parse_action_list)
+       (take_action_list): Handle the aboves.
+       (filter): Treat key S-X as X.
+       (minput__init): Initialize Mless_equal and Mgreater_equal.
+       (minput_get_title_icon): New function.
+
+       * m17n.h (minput_get_title_icon): Extern it.
+
+       * database.c (get_database_filename): Return a filename instead of
+       file pointer.
+       (load_database): Adjusted for the above change.
+       (mdatabase__load_for_keys): Likewise.
+       (mdatabase__find_file): New function.
+
+       * database.h (mdatabase__find_file): Extern it.
+
+       * font.h (mfont__resize): Delete extern.
+
+       * font.c (mfont__list): Check resize ratio.
+       (mfont__resize): Delete it.
+       (mfont_resize_ratio): Include the code of mfont__resize.
+
+       * font-ft.c (ft_open): Check resize ratio.
+
+       * m17n-X.c (xfont_open): Check resize ratio.
+       (xft_open): Likewise.
+
+2005-12-07  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (take_action_list): If take_action_list return -1,
+       return -1.
+       (handle_key): Likewise.
+
+       * face.c (mface__for_chars): When font is specified and layouter
+       is found for it, if the layouter doesn't support one of a
+       character, use a face sans layouter for it.
+
+2005-12-06  Kenichi Handa  <handa@m17n.org>
+
+       * fontset.c (mfont__lookup_fontset): If only a fallback font is
+       found, don't use it for more than one character.
+
+2005-12-05  Kenichi Handa  <handa@m17n.org>
+
+       * face.c (mface__realize): Set rfont->layouter to Mnil.
+       (mface__for_chars): Fix handling of layouter.
+
+       * character.h (mchar__define_prop): Extern it.
+
+       * database.c (update_database_list): Call mchar__define_prop if
+       necessary.
+
+       * character.c (mchar__init): Don't call mchar_define_property.
+       Instead just initialize property keys.
+       (mchar__fini): Free char_prop_list only if it's not NULL.
+       (mchar__define_prop): New function.
+       (mchar_define_property): Call mchar__define_prop.
+
+       * m17n-core.c (m17n_fini_core): Call mtext__prop_fini at after
+       mplist__fini.
+
+2005-12-02  Kenichi Handa  <handa@m17n.org>
+
+       * language.c (mlang__init): Handle extra chars.
+
+       * m17n-gui.h (mfont_check): Adjust prototype.
+
+       * m17n-X.c (xfont_driver): Specify xfont_check_capability.
+       (xfont_check_capability): New function.
+       (xft_driver): Specify xft_check_capability.
+       (xft_check_capability): New function.
+
+       * font-ft.c (M0_3): Delete it.
+       (M0): New variable.
+       (ft_get_charmaps): Refer to M0.
+       (fc_parse_pattern): Fix previous change.
+       (ft_list_language): Check also extra chars.
+       (ft_check_otf): Define it even if HAVE_OTF is undef.
+       (ft_check_lang): Check the result of FcLangSetHasLang against
+       FcLangDifferentLang.  Check also extra chars.
+       (ft_list_capability): Delete ifdef HAVE_OTF.
+       (ft_select): Likewise.
+       (ft_open): Improve debug information.
+       (ft_check_capability): New function.
+       (mfont__ft_driver): Specify ft_check_capability.
+       (mfont__ft_init): Initialize M0.
+
+       * fontset.c (get_font_from_group): New function.
+       (mfontset__get_font): New function.
+
+       * fontset.h (mfontset__get_font): Extern it.
+
+       * font.c (OTF_tag): Define it if HAVE_OTF is undef.
+       (mfont__fini): Delete ifdef HAVE_OTF.
+       (free_font_capability): Likewise.
+       (mfont__get_capability): Likewise.
+       (mfont__check_capability): New function.
+       (mfont_check): Change the order of arguments.  Use
+       mfontset__get_font.
+
+       * font.h (struct MFontDriver): New member check_capability.
+       (MFontCapability): Delete ifdef HAVE_OTF.
+       (mfont__check_capability): Extern it.
+
+       * face.c (mface__realize): Fix handling of FONT arg.
+       (mface__for_chars): Fix handling of explicitly specified font.
+
+2005-11-25  Kenichi Handa  <handa@m17n.org>
+
+       * font-flt.c (run_command): Print debug info for
+       left/rigth_padding
+
+       * draw.c (layout_glyphs): Fix handling of left/right_padding.
+
+       * face.c (mface__for_chars): Check rfont before accessing the
+       members.
+
+2005-11-21  Kenichi Handa  <handa@m17n.org>
+
+       * Makefile.am (lib_LTLIBRARIES): Define it conditionaly on
+       WITH_GUI.
+
+       * fontset.c (fontset_table): New variable.
+       (free_fontset): Call M17N_OBJECT_UNREGISTER.
+       (mfont__fontset_init): Add fontset_table as an object array.
+       (mfont__realize_fontset): Ref FONTSET.
+       (mfont__free_realized_fontset): Unref REALIZED->fontset.
+       (mfontset): Call M17N_OBJECT_REGISTER.
+       (mfontset_copy): Likewise.
+
+       * input.c (handle_key): For debugging, print information about
+       alias key.
+       (filter): Add an alias for Meta and Alt modifiers.
+       (Mcond, Mplus, Mminus, Mstar, Mslush, Mand, Mor, Mnot): New
+       variables.
+       (minput__init): Initialize them.
+       (parse_expression): New function.
+       (resolve_expression): New function.
+       (parse_action_list): Handle expressions by parse_expression.
+       (take_action_list): Handle expressions by resolve_expression.
+       (parse_nested_list_value): Fix previous change.
+       (resolve_command): Fix handling of the return value of
+       get_nested_list.
+
+2005-11-18  Kenichi Handa  <handa@m17n.org>
+
+       * font-ft.c (ft_check_otf, otf_script_list): Define only when
+       HAVE_OTF is defined.
+       (ft_list_capability): Call ft_check_otf only when HAVE_OTF is
+       defined.
+       (ft_select): Likewise.
+
+       * font.c (mfont_list): Fix for the case that FONT is NULL.
+       (OTF_tag): Delete it.
+       (load_otf_script_list): Define only when HAVE_OTF is defined.
+       (mfont__fini): Unref otf_script_list only when HAVE_OTF is
+       defined.
+
+       * draw.c (truncate_gstring): Be sure to truncate at
+       glapheme-cluster boundary.
+
+2005-11-11  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (delete_surrounding_text): Clear cache if necessary.
+
+2005-11-09  Kenichi Handa  <handa@m17n.org>
+
+       * draw.c (compose_glyph_string): Update prev->rface->rfont if the
+       glyph prev is also supported by the current flt.
+
+2005-11-08  Kenichi Handa  <handa@m17n.org>
+
+       * m17n-X.c (xft_render): Cancel previous change.
+
+2005-11-07  Kenichi Handa  <handa@m17n.org>
+
+       * input.c: Include <stdlib.h>.
+       (get_surrounding_text, delete_surrounding_text)
+       (get_preceding_char, get_following_char): New functions.
+       (integer_value): New arg surrounding.  If it is nonzero, try to
+       get a surrounding character.  Callers changed.
+       (take_action_list): Check `value' before setting an element.
+       (destroy_ic): Unref ic_info->preceding_text and
+       ic_info->following_text.
+       (minput__init): Initialize Minput_get_surrounding_text and
+       Minput_delete_surrounding_text.
+       (Minput_get_surrounding_text, Minput_delete_surrounding_text): New
+       variables.
+       (filter): Unref ic_info->preceding_text and
+       ic_info->following_text.
+
+       * m17n.h (Minput_get_surrounding_text, Minput_delete_surrounding_text):
+       Extern them.
+
+       * input.h (MInputContextInfo): New members preceding_text and
+       following_text.
+
+2005-11-04  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (parse_nested_list_value): Fix handling of the global
+       definition.
+       (get_nested_list): Get global definitions by load_partial_im_info.
+       (preedit_commit): Set ic->candidates_changed to bitwise or of enum
+       MInputCandidatesChanged.
+       (take_action_list): Likewise.
+       (reset_ic): Likewise.
+       (create_ic): Don't pay special attention to
+       Mcandidates_group_size.
+       (load_partial_im_info): Call mdatabase_find with correct 4th arg.
+       (minput_set_variable): Get a definition of varible by
+       mplist_find_by_value, not mplist_get.
+
+       * m17n.h (enum MInputCandidatesChanged): New enum.
+
+2005-11-01  Kenichi Handa  <handa@m17n.org>
+
+       * m17n-X.c (xft_render): Check xft_draw's drawable before changing
+       it.
+       (mwin__destroy_window): If xft_draw's drawable is win, change it
+       to device->drawable before destroying win.
+
+2005-10-31  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (load_im_info): Fix adding of state.
+
+       * m17n-core.c (m17n_fini_core): Fix reporting of module
+       finalization.
+
+       * m17n.c (m17n_fini): Fix reporting of module finalization.
+
+       * m17n-gui.c (m17n_init_win): Fix reporting of module
+       finalization.
+
+2005-10-29  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (get_candidate_list): Fix the timing of referring plist.
+
+2005-10-28  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (load_branch): Ignore an undefined map name.
+       (load_im_info): Set im_info->title from `name' only if it's not
+       Mnil.
+       (shift_state): Always update ic->status.
+       (adjust_candidates): Renamed from adjust_candidate_command.
+       Argument changed.  Caller changed.
+       (get_candidate_list, regularize_action): New functions.
+       (take_action_list): Use them.  On handling Munhandle, don't set
+       ic_info->used to 0.
+       (handle_key): If KEY is not handled by MAP, and MAP has
+       branch_actions, perform them.
+
+       * database.c (mdatabase__fini): Free dir_info->filename;
+
+2005-10-20  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (marker_code): Accept '@@'.
+       (integer_value): Handle '@@'.
+       (parse_action_list): Accept a symbol argument.
+       (take_action_list): Resolve the symbol argument.  Handle the
+       integer argument.
+
+2005-10-18  Kenichi Handa  <handa@m17n.org>
+
+       * input.c: Include "charset.h".
+       (M_candidates, Mcandidates_group_size, Mcandidates_charset): New
+       variables.
+       (MIMState): New member (M17NObject control).
+       (lookup_nested_list, set_nested_list, parse_nested_list_value)
+       (get_nested_list, resolve_variable): New functions.
+       (integer_value): New arg (MPlist **value).  Set it to the plist
+       element containing the value.
+       (resolve_command): New function.
+       (load_translation): New arg (MPlist *map_actions).
+       (load_branch): New args language and name.  If `keylist' is a
+       symbol, resolved that as a command name.
+       (free_map): New arg top.  Free map->map_actions only if top is
+       nonzero.
+       (free_state): New function.
+       (load_state): New arg name.
+       (im_info_list): New variable.
+       (free_im_info, get_im_info_by_tags): New functions.
+       (load_im_info): Arg key changed to plist.  Handle `include'.
+       Return (MInputMethodInfo *).
+       (preedit_commit): Ref ic->candidate_list.
+       (get_select_charset, adjust_candidate_command): New functions.
+       (take_action_list): Handle `include'.  Adjust candidate action
+       properly.  Handle control variables `candidates-charset' and
+       `candidates-group-size'.
+       (open_im): Use get_im_info.
+       (create_ic): Get global variables.
+       (load_partial_im_info): New function.
+       (get_im_info): New function.
+       (check_command_keyseq, check_command_list, check_variable_list):
+       New functions.
+       (minput__init): Don't handle M_database_hook and Mdetail_text.
+       Initialize M_candidates, Mcandidates_group_size,
+       Mcandidates_charset.
+       (parse_variable_list, get_variable_list, parse_command_list)
+       (get_command_list): Delete them.
+       (MDatabaseStatList, imdir_stat_list, input_method_hook): Delete them.
+       (minput__fini): Simply unref command_list and variable_list.
+       (minput_get_description): Adjusted for the new form of description.
+       (minput_get_commands): Use get_nested_list.
+       (minput_assign_command_keys): Likewise.
+       (minput_get_variables, minput_set_variable): Likewise.
+
+       * input.h (MInputMethodInfo): New members im and maps.
+
+       * database.h (M_database_hook): Delete extern.
+       (MDatabaseHookFunc): Delete extern.
+       (mdatabase__check): Extern it.
+
+       * database.c: Include <glob.h>.
+       (MAX_TIME): New macro.
+       (Masterisk): New variable.
+       (get_database_stream): Argument changed to (MDatabaseInfo *).
+       Callers changed.
+       (get_dir_info): Renamed from duplicate_dirname.  Callers changed.
+       (find_database): New function.
+       (update_database_list): New function.
+       (mdatabase__init): Initialize Masterisk.  Setup mdb_list by
+       calling update_database_list.
+       (mdatabase__check): New function.
+       (mdatabase_find): Use update_database and find_database.  Don't
+       handle MDatabaseHookFunc.
+       (mdatabase_list): Call update_database at first.
+       (mdatabase_define): Adjusted for the change of mdb->extra_info.
+       (MDatabaseList): New type.
+
+       * plist.h (mplist_conv, mplist__pop_unref): Extern them.
+
+       * m17n.h (Mdetail_text): Delete extern.
+
+       * m17n-core.h (mplist_conc): Delete extern.
+
+       * plist.c (mplist__conc): Renamed from mplist_conc.  Don't ref
+       tail.
+       (mplist_conc): Renamed to mplist__conc.
+       (mplist__pop_unref): New function.
+
+2005-10-14  Kenichi Handa  <handa@m17n.org>
+
+       * plist.c (read_mtext_element): Ignore the sequence of '\\' and
+       newline.
+       (read_element): If keys is an empty plist, return any element
+       found first.
+       (dump_plist_element): Check if plist is nested.
+       (mplist_conc): Always ref tail.
+       (mplist_set): If key is a managing key, ref val in advance.
+
+       * plist.h (MPLIST_VAL_MANAGED_P): Delete this macro.
+       (MPLIST_NESTED_P, MPLIST_SET_NESTED_P): New macros.
+       (MPLIST_ADD_PLIST, MPLIST_PUSH_PLIST, MPLIST_PUT_PLIST): New
+       macros.
+
+       * fontset.c (free_fontset): Unref fontset_list if necessary.
+       (mfont__fontset_fini): Don't free fontset_list.  Unref
+       default_fontset.
+       (mfont__realize_fontset): Initialize request.
+       (mfontset): Ref default_fontset or fontset only if necessary.
+       (mfontset_copy): Don't ref copy.
+
+       * draw.c (render_glyphs): Check gend->type before checking
+       gend->to.
+
+       * font-ft.c (mfont__ft_fini): Unref ft_default_list.  Set all
+       unrefed plists to NULL.
+
+2005-10-04  Kenichi Handa  <handa@m17n.org>
+
+       * textprop.c (mtext_serialize): Be sure to make mt
+       MTEXT_FORMAT_UTF_8 and NULL terminated.
+
+       * m17n-gui.c (m17n_init_win): Initialize Mcolormap.
+
+       * draw.c (mdraw_glyph_list): Fix settting of glyphs->font->source.
+
+2005-10-03  Kenichi Handa  <handa@m17n.org>
+
+       * draw.c (mdraw_glyph_info): Pay attention to the case that FROM
+       is not at the beginning of line.
+
+2005-09-22  Kenichi Handa  <handa@m17n.org>
+
+       * input.c: Include <sys/stat.h> and <unistd.h>.
+       (Minclude, Mcommit, Munhandle): New variables.
+       (minput__init): Initialize them.  Push only Mstate to
+       load_im_info_keys.   Add aliases C-lowercase for C-uppercase.
+       (parse_action_list): Allow integer arg for undo.  Handle Mcommit
+       and Munhandle.
+       (load_input_method): Handle "include" directive.  If no states are
+       loaded, return -1.
+       (shift_state): If state_name is Mt, shift back to the previous
+       state.  Call preedit_commit to commit preedit text.
+       (preedit_commit): New function.
+       (take_action_list): Improve debug printing.  Handle commit and
+       unhandle commands.
+       (handle_key): Check the return value of take_action_list.  Don't
+       take branch_actions just after changing to the root map.
+       (reset_ic): Reset all ic_info members.
+       (filter): When a key is not handled, just move ic_info->keys
+       instead fo calling reset_ic.
+       (load_im_info): If key is not Mstate, push Mmap to
+       load_im_info_keys.
+       (MDatabaseStatList): New type.
+       (imdir_stat_list): New variable.
+       (input_method_hook): Don't cancel the hook.  Check the
+       modification time of directories.
+       (minput__fini): Free imdir_stat_list;
+
+       * input.h (MInputContextInfo): New member prev_state.
+
+       * m17n-core.h (mplist_conc): Extern it.
+
+       * plist.c (mplist_conc): New function.
+
+       * mtext.c (mdebug_dump_mtext): Escape '"' and '\\' by '\\'.
+
+       * font.h (MRealizedFont): New member average_width.
+
+       * font-ft.c (ft_open): Set rface->average_width.
+
+       * font.c (xlfd_unparse_name): Print '*' before registry name.
+
+       * m17n-X.c (MDisplayInfo): New member AVERAGE_WIDTH.
+       (xfont_open): Set rfont->average_width.
+       (xft_open): Likewise.
+       (device_open): Initialize disp_info->AVERAGE_WIDTH.
+
+       * internal-gui.h (struct MFrame): New member average_width.
+
+       * m17n-gui.c (mframe): Fix setting of frame->rfont.
+       (mframe_get_prop): Return the average_width of a font.
+
+       * face.c (mface__realize): Set rface->average_width.
+       (mface__update_frame_face): Set frame->average_width.
+
+       * face.h (MRealizedFace): New member average_width.
+
+2005-09-19  Kenichi Handa  <handa@m17n.org>
+
+       * font.c (xlfd_unparse_name): New arg full_xlfd.
+       (mfont__encode_char): Use shortcut only for X core fonts.
+       (mfont_unparse_name): Call xlfd_unparse_name with full_xlfd arg 1.
+       (mfont_put_prop): Handle `language' property.
+       (mdebug_dump_font): Call xlfd_unparse_name with full_xlfd arg 0.
+       Print file can capability info too.
+
+       * m17n-core.c (mdebug__output): New variable.
+       (SET_DEBUG_FLAG): Unset mask if env_value is '0'.
+       (m17n_init_core): Handle MDEBUG_ALL and MDEBUG_OUTPUT_FILE.
+       (m17n_fini_core): Close mdebug__output if it's not stderr.
+
+       * m17n-X.c (MDisplayInfo): New member MULE_BASELINE_OFFSET.
+       (xfont_open): Handle baseline_offset.
+       (xfont_find_metric): Likewise.
+       (xfont_render): Likewise.
+       (xft_open): Likewise.
+       (xft_render): Likewise.
+
+       * internal.h (MDebugMaskBit): Add MDEBUG_ALL.
+       (mdebug__output): Extern it.
+       (MDEBUG_PRINT, MDEBUG_PRINT1, MDEBUG_PRINT2, MDEBUG_PRINT3)
+       (MDEBUG_PRINT4, MDEBUG_PRINT5): Print to medebug__output.
+       (MDEBUG_DUMP): New macro.
+       (MDEBUG_PRINT_TIME): Print to medebug__output.
+
+       * font.h (MRealizedFont): New member baseline_offset.
+
+       * font-ft.c (ft_get_charmaps): Check if the font support iso8859-1
+       characters.
+       (fc_weight_table): Add FC_WEIGHT_REGULAR.
+       (ft_list_family): Check alias.
+       (ft_list_language): If language is "en", don't try to the second
+       step.
+       (ft_default_list): New variable.
+       (ft_list_default): New function.
+       (ft_select): If family is not specified, try only the default
+       fonts.  Treat the weights normal and medium same.
+       (ft_open): Fix debug message.  If registry is not specified, try
+       unicode-bmp.  Handle _MULE_BASELINE_OFFSET property of BDF fonts.
+       (ft_find_metric): Likewise.
+       (ft_render): Likewise.
+       (ft_list): Fix debug message.  Accept the registring iso8859-1.
+       If family is not specified, try only the default fonts.
+
+       * face.c (mface__realize): Fix logic of opening a font.
+
+2005-09-16  Kenichi Handa  <handa@m17n.org>
+
+       * face.c (mface__realize): 
+
+       * m17n.h (Minput_focus_move, Minput_focus_in, Minput_focus_out):
+       Extern them.
+
+       * input.c (shift_state): Fix the condition of taking init actions.
+       (take_action_list): Fix handling of pushback action.
+       (handle_key): Don't change key while checking its alias.
+       (minput__init): Initialize new variables.
+       (Minput_focus_move, Minput_focus_in, Minput_focus_out): New
+       variables.
+
+2005-09-12  Kenichi Handa  <handa@m17n.org>
+
+       * mtext.c (mtext__uppercase): Add proper open/close parens.
+       (mtext_titlecase): Add proper casting.
+
+       * input.c (parse_action_list): Handle the case that the arg is a
+       key sequence (MText or MPlist).
+       (take_action_list): Likewise.
+       (shift_state): Shorter debug message.
+       (handle_key): Terminate a debug message by "\n".
+       (reset_ic): Don't take initial actions here.
+       (minput_open_im): Print a debug message.
+       (minput_close_im): Likewise.
+       (minput_create_ic): Likewise.
+       (minput_destroy_ic): Likewise.
+
+2005-09-09  TAKAHASHI Naoto  <ntakahas@m17n.org>
+
+       * mtext.c (mtext_lowercase, mtext_titlecase, mtext_uppercase):
+       Change API.
+
+2005-09-07  TAKAHASHI Naoto  <ntakahas@m17n.org>
+       * character.c: Add "cased", "soft-dotted", and "case-mapping" in
+       mchar__init ().
+
+       * character.c: Add Japanese documentation for
+       mchar_get_prop_table ().
+
+2005-09-06  TAKAHASHI Naoto  <ntakahas@m17n.org>
+
+       * mtext.c (tricky_chars, *cased, *soft_dotted, *case_mapping)
+       (MCharTable *combining_class, Mlt, Mtr, Maz, gr03A3, lt0049,
+       (lt004A, lt012E, lt00CC, lt00CD, lt0128, tr0130, tr0049, tr0069):
+       New variables.
+       (init_case_conversion): New function.
+       (CASE_CONV_INIT, REPLACE, DELETE, LOOKUP): New macros.
+       (uppercase_precheck, lowercase_precheck, final_sigma)
+       (after_soft_dotted, more_above, before_dot, after_i)
+       (mtext_uppercase, mtext_titlecase, mtext_lowercase): New functions.
+
+2005-09-05  TAKAHASHI Naoto  <ntakahas@m17n.org>
+
+       * plist.c (read_mtext_element): Fix previous change.
+
+2005-09-05  Kenichi Handa  <handa@m17n.org>
+
+       * plist.c (read_mtext_element): Handle \uXXXX notation.
+
+       * internal.h (MTABLE_MALLOC): Don't use a local variable.
+       (MTABLE_ALLOCA): Change the name of local variable.
+
+       * m17n-gd.c (device_open): Define it even if HAVE_GD nor
+       HAVE_FREETYPE are defined.
+
+       * m17n-X.c: Check HAVE_X11.
+
+       * Makefile.am (X_LD_FLAGS): Use @X11_LD_FLAGS@ instead of
+       directory listing libraries.
+       (noinst_PROGRAMS): Define it only in maintainer mode.
+
+2005-09-02  Kenichi Handa  <handa@m17n.org>
+
+       * m17n-gui.h (mdraw_line_break_option): Extern it.
+
+       * draw.c (truncate_gstring): Use find_glyph_in_gstring to find the
+       end of the first glyph.
+       (GET_LB_TYPE, find_break_backward, find_break_forward): Delete
+       them.
+       (mdraw_line_break_option): New variable.
+       (mdraw_default_line_break): Use mtext_line_break.
+
+       * mtext.h (wordseg_func_table): Don't extern it.
+       (mtext__wseg_fini): Extern it.
+
+       * mtext.c: Don't include word-thai.h.
+       (wordseg_func_table): Delete this variable.
+       (mtext__init): Don't initialize above.  Don't call
+       mtext__word_thai_init.
+       (mtext__fini): Don't free wordseg_func_table.  Call
+       mtext__wseg_fini instead fo mtext__word_thai_fini.
+       (MTextWordsegFunc): Don't typedef it.
+       (mtext__word_segment): Moved to mtext-wseg.c.
+
+       * m17n-core.h (enum MTextLineBreakOption): New enum.
+       (mtext_line_break): Extern it.
+
+       * mtext-wseg.c: New file.
+
+       * mtext-lbrk.c: New file.
+
+       * Makefile.am (libm17n_core_la_SOURCES): Delete word-thai.[ch],
+       add mtext-lbrk.c and mtext-wseg.c.
+
+       * textprop.c (mtext__adjust_plist_for_change): Pay attention for
+       the case that head is NULL.
+
+2005-09-01  Kenichi Handa  <handa@m17n.org>
+
+       * word-thai.c (wordseg_propertize): If the property value is nil,
+       don't make the property no-merge.
+       (thai_wordseg): Don't require *from and *to are set a priori.  Pay
+       attention to the case that they are NULL.
+       (mtext__word_thai_init): Make the name of Mthai_wordseg starts
+       with two spaces.
+
+       * character.c (mchar_get_prop_table): New function.
+
+       * textprop.h (mtext__adjust_plist_for_change): Prototype adjusted.
+
+       * m17n-core.h (mtext_insert, mtext_replace): Extern them.
+       (mchar_get_prop_table): Extern it.
+
+       * textprop.c (prepare_to_modify): New arg deleting.  Callers changed.
+       (mtext__adjust_plist_for_change): Argument changed.  Callers changed.
+
+       * internal.h (enum MTextCoverage): New enum.
+       (MText): New member coverage.
+
+       * mtext.c (FORMAT_COVERAGE): New macro.
+       (insert): Copy mt2->coverage.
+       (mtext__from_data): Initialize mt->coverage.
+       (mtext__adjust_format): Update mt->coverage.
+       (mtext): Initialize mt->coverage.
+       (mtext_set_char): Adjust args to mtext__adjust_plist_for_change.
+       Update mt->coverage if necessary.
+       (mtext_duplicate): Copy mt->coverage.
+       (mtext_insert, mtext_replace): New functions.
+       (mtext_dup): Use mtext_duplicate.
+       (mtext__word_segment): Don't set *from and *to if a word
+       segmentation funcion is not found.
+       (mtext_ins_char): Fix typo.
+
+2005-08-25  Kenichi Handa  <handa@m17n.org>
+
+       * font.h (MFont): New member for_full_width.
+
+       * font.c (compare_font_score): Prefer a font of not
+       for_full_width.
+
+       * m17n-X.c (xfont_registry_list): Set font.for_full_width if the
+       registry charset of a font is one of CJK charsets.
+
+       * font-ft.c (fc_parse_pattern): Set font->for_full_width if a font
+       supports some of CJK.
+
+2005-08-24  Kenichi Handa  <handa@m17n.org>
+
+       * m17n-gui.h (Mascent, Mdescent): Don't extern them.
+
+       * m17n-gui.c (null_device_open): Check Mresolution param and set
+       frame->dpi.
+
+       * m17n-gd.c (device_open): Check Mresolution param and set
+       frame->dpi.
+
+       * m17n-X.c (MWDevice): New member resy.
+       (xfont_open): Set ascent, descent, and max_advance members of
+       rfont.
+       (xft_open): Likewise.
+       (device_open): Compare also screen_num to find a device.  Set
+       device->resy and frame->dpi.
+
+       * internal-gui.h (MFrame): New member dpi.
+
+       * font.h (MRealizedFont): New member max_advance.
+
+       * font.c (xlfd_unparse_name): Handle the case of font->size < 0.
+       (mfont__init): Don't initialize Mascent, Mdescent.
+       (Mascent, Mdescent): Delete these variables.
+       (mfont_get_prop): Fix previous change.  Check Mfont_ascent and
+       Mfont_descent instead of Mascent and Mdescent.
+       (mfont_put_prop): Allow negative size.
+       (mfont_find): Handle the case of spec->size < 0.  Fix previous
+       change.
+       (mfont_list): Handle the case of spec->size < 0.
+       (mfont_check): Likewise.
+
+       * font-ft.c (STRDUP_LOWER): Ignore the tailing spaces.
+       (fc_get_pattern): Handle the case of font->size < 0.
+       (ft_open): Set ascent, descent, and max_advance members of rfont.
+       (ft_find_metric): Improve rounding.
+       (mfont__ft_parse_name): If FC_PIXEL_SIZE is not available, set
+       FC_SIZE.
+
+       * face.c (mface__realize): Handle the case of font->size < 0.
+
+2005-08-22  Kenichi Handa  <handa@m17n.org>
+
+       * coding.c (MConverterStatus): Change the member buf to union.
+       (mconv_buffer_converter): Add const to the arg buf.
+       (mconv_decode_buffer, mconv_rebind_buffer): Likewise.
+       (mconv_decode): Adjusted for the change of MConverterStatus.
+       (mconv_encode_range): Likewise.
+
+       * m17n.h (mconv_buffer_converter): Prototype adjusted.
+       (mconv_decode_buffer, mconv_rebind_buffer): Likewise.
+
+2005-08-20  Kenichi Handa  <handa@m17n.org>
+
+       * m17n-gui.h (mfont_from_name): Prototype adjusted.
+       (Mspacing, Mascent, Mdescent, Mmax_advance): Extern them.
+
+       * m17n-X.c (xfont_open): Set members ascent, descent, and
+       max_advance of rfont.
+       (xft_open): Likewise.
+
+       * font-ft.c (ft_open): Set members ascent, descent, and max_advance
+       of rfont.
+       (mfont__ft_parse_name): Add const to the arg name.
+
+       * font.c (xlfd_parse_name): Add const to the arg name.  Call
+       mfont__set_property instead of mfont_set_spec.  Set font->spacing.
+       (xlfd_unparse_name): Handle spacing.
+       (mfont__init): Initialize new variables.
+       (mfont__id): Handle spacing.
+       (mfont__merge): Likewise.
+       (mfont__set_spec): This function deleted.
+       (mfont__parse_name_into_font): Add const to the arg name.  Fix the
+       condition of calling mfont__ft_parse_name.
+       (Mspacing, Mascent, Mdescent, Mmax_advance): New variables.
+       (mfont_get_prop): Handle properties spacing, ascent, descent,
+       and max-advance.
+       (mfont_find): Return a realized font.
+       (mfont_from_name): Add const to the arg name.
+
+       * font.h (enum MFontProperty): New member MFONT_SPACING.
+       (enum MFontSpacing): New enum.
+       (MFont): New members spacing and max_advance.
+       (mfont__ft_parse_name): Prototype adjusted.
+       (mfont__set_spec): Extern deleted.
+       (mfont__parse_name_into_font): Prototype adjusted.
+
+2005-08-19  Kenichi Handa  <handa@m17n.org>
+
+       * m17n-gui.h (mfont_parse_name): Prototype adjusted.
+
+       * font.c (mfont_list): If FONT is null, use a temporary font.
+       (mfont_parse_name): Add const to the arg name.
+
+2005-08-18  Kenichi Handa  <handa@m17n.org>
+
+       * word-thai.c: Surround code by #ifdef and #endif to escape from
+       doxygen.
+
+       * font-ft.c: Mostly re-written.
+
+       * font-flt.c (FontLayoutCmdOTF): This type deleted.
+       (FontLayoutCmd): Type of the member otf changed..
+       (load_otf_command): Adjusted for the format change of otf command.
+       (load_command): Likewise.
+       (free_flt_command): Unref cmd->body.otf.
+       (run_otf): Ajusted for the type change of otf_cmd.
+       (run_command): Ajusted for the type change of otf_cmd.  On
+       debugging, print ctx->combining_code.
+       (mfont__flt_run): Initialize ctx's members code_offset,
+       combining_code, and left_padding to 0.
+
+       * face.h (struct MRealizedFace): New member font.
+       (mface__realize): Prototype adjusted.
+
+       * face.c (find_realized_face): New arg font.
+       (find_realized_face): Adjusted for the change of MFont.
+       (mface__init): Call M17N_OBJECT_ADD_ARRAY.
+       (mface__fini): Don't call mdebug__report_object.
+       (mface__realize): New arg font.
+       (mface__for_chars): Adjusted for the change of mfont__encode_char.
+       Optimize the latin case.
+       (mface__free_realized): Free rface->font.
+       (mface__update_frame_face): Adjusted for the change of mface__realize.
+       (mface_equal): New function.
+
+       * draw.c (Mcommon): New variable.
+       (visual_order): Args to mfont__encode_char changed.
+       (compose_glyph_string): Handle Mfont text property.
+       (layout_glyphs): Adjusted for the change of MFont.
+       (mdraw__init): Initialize Mcommon.
+       (mdraw_glyph_info): Adjusted for the change of MRealizedFont.
+
+       * font.h (enum MFontType): Members completely changed.
+       (enum MFontProperty): Move MFONT_SIZE to the tail.
+       (enum MFontSource): New enum.
+       (struct MFont): New members type, source, sizes, file, capability,
+       and encoding.
+       (struct MRealizedFont): Type of member font changed. Members
+       score, status, and encoding deleted.
+       (MFontScore): New type.
+       (MFontList): Member changed.
+       (struct MFontDriver): New member has_char.  Types of members
+       changed.
+       (Miso8859_1, Miso10646_1, Municode_bmp, Municode_full)
+       (Mapple_roman): Extern them.
+       (OTF_Tag): Typedefed if not HAVE_OTF.
+       (enum MFontOpenTypeTable): New enum.
+       (MFontCapability): New type.
+       (mfont__ft_drive_otf): Prototype adjusted.
+       (mfont__score): Extern deleted.
+       (mfont__merge): Extern it.
+       (mfont__has_char): Extern it.
+       (mfont__encode_char): Prototype adjusted.
+       (mfont__open): Extern it.
+       (mfont__set_spec): Prototype adjusted.
+       (mfont__get_capability): Extern it.
+
+       * font.c: Include "fontset.h".
+       (M_font_capability, M_font_list, M_font_list_len): New variables.
+       (font_score_priority): Change order of initial elements.
+       (font_score_shift_bits): Fix array size.
+       (common_weight): Add "thin", "semibold", and "heavy".
+       (common_stretch): Add "ultracondensed", "extracondensed",
+       "extraexpanded", and "utltraexpand".
+       (font_weight_regular, font_weight_normal, font_weight_medium): New
+       variables.
+       (gen_font_name): This function deleted.
+       (find_encoding): Set font->encoding.
+       (OTF_tag): New function.
+       (otf_script_list): New variable.
+       (load_otf_script_list): New function.
+       (find_script_from_otf_tag): New function.
+       (xlfd_parse_name): Set font->type and font->source.
+       (mfont__free_realized): Free chains rfonts.
+       (font_score): Renamed from mfont__score.
+       (Miso8859_1, Miso10646_1, Municode_bmp, Municode_full)
+       (Mapple_roman): New variables.
+       (mfont__init): Initilize new variables.  Initalize
+       default_encoding.encoding_name and
+       default_encoding.encoding_charset to Municode_full and
+       mcharset__unicode.  Use SAFE* macros for allocating filepath
+       buffer.
+       (mfont__fini): Free otf_script_list.
+       (mfont__id): New function.
+       (mfont__match_p): Check also capability member of MFont.
+       (mfont__merge): New funciton.
+       (mfont__set_spec_from_face): Set type and source members.
+       (mfont__set_spec_from_plist): Set capability and type members.
+       (mfont__select): Argument changed.
+       (mfont__available): New function.
+       (compare_font_score): New function.
+       (mfont__list): New function.
+       (mfont__open): Return a realized font.
+       (mfont__resize): Adjusted for the change of MFont.
+       (mfont__has_char): New function.
+       (mfont__encode_char): Argument changed.
+       (mfont__set_spec): Argument changed.
+       (free_font_capability): New function.
+       (mfont__get_capability): New function.
+       (MFontfile): New variable.
+       (mfont_get_prop): Adjusted for the change of MFont.
+       (mfont_put_prop): Likewise.
+       (mfont_set_selection_priority): Fix the way of setting
+       font_score_priority[].
+       (mfont_find): Use mfont__list instead of mfont__select.
+       (mfont_resize_ratio): Adjusted for the change of MFont.
+       (mfont_list): Use mfont__list.
+       (mfont_check): New function.
+       (font_score): Make it static.
+
+       * fontset.h (mfont__realize_fontset): Prototype adjusted.
+       (mfont__lookup_fontset): Likewise.
+
+       * fontset.c (struct MFontset): Delete member font_spec_list.
+       (struct MRealizedFontset): Type of member spec changed.  New
+       member request.
+       (load_font_group): Arg spec_list deleted.
+       (load_fontset_contents): Adjusted for the change of fontset_def.
+       (free_fontset): Fix the way of freeing fontset elements.
+       (realize_fontset_elements): Argument changed.
+       (get_per_script): New function.
+       (free_realized_fontset_elements): Fix the way of feeing rfontset
+       elements.
+       (update_fontset_elements): Fix args to realize_fontset_elements.
+       (mfont__realize_fontset): New arg spec.
+       (try_font_list): New function.
+       (try_font_group): New arg request.  Use try_font_list.
+       (mfont__lookup_fontset): New arg ignore_fallback.  Fix arg to
+       try_font_group.
+       (mfontset): Adjusted for the change of MFontset.
+       (mfontset_copy): Likewise.  Don't share plists.
+       (mfontset_modify_entry): Adjusted for the change of MFontset.
+       (mfontset_lookup): Call get_per_script.
+       (mdebug_dump_fontset): Print also the address of fonts.
+
+       * input.c (shift_state): Don't reset ic_info->vars.
+       (take_action_list): Call MDEBUG_PRINT fore calling
+       take_action_list.
+
+       * internal-gui.h (MFontDriver): Don't typedef it here.
+
+       * m17n-X.c: Include <fontconfig/fcfreetype.h> if HAVE_XFT2.
+       (MXFont): This type deleted.
+       (MFontX): New type.
+       (struct _MFontX): New struct.
+       (SET_SIZE, HAVE_SIZE): Adjusted for the change of arg FONTX.
+       (MDisplayInfo): Member base_font_list deleted.
+       (DEFAULT_FONT): Definition changed.
+       (FALLBACK_FONT): This maclr deleted.
+       (free_display_info): Adjusted for the change of MDisplayInfo.
+       (free_device): Argument to mfont__free_realized changed.
+       (xfont_driver): Adjusted for the change of MFontDriver.
+       (xfont_registry_list): Use MFontX instead of MXFont.
+       (MRealizedFontX): Renamed from MXFontInfo.
+       (xfont_select): Return the font found first.
+       (close_xfont): Change MXFontInfo to MRealizedFontX.
+       (xfont_open): Return the realized font.
+       (xfont_find_metric): Get xfont from rfont->fontp.
+       (xfont_has_char): New function.
+       (xfont_encode_char): Adjusted for the argument change.
+       (xfont_render): Get xfont from rfont->fontp.
+       (xfont_list): Adjusted for the argument change.
+       (MRealizedFontXft): Renamed from MXftFontInfo.
+       (xft_driver): Ajusted for the change of MFontDriver.
+       (close_xft): Change MXtfFontInfo to MRealizedFontXft
+       (xft_open_font): Argument changed.
+       (xft_open): Argument changed.  Return the realized font.
+       (xft_find_metric): Get xft_font from rfont->fontp.
+       (xft_has_char, xft_encode_char): New functions.
+       (xft_render): Change MXftFontInfo to MRealizedFontXft.  Open a
+       font if not yet opened.
+       (device_open): Don't set frame->font.
+
+       * m17n-gd.c (gd_font_driver): Adjusted for the change of
+       MFontDriver.
+       (gd_font_open): New function.
+       (gd_render): Don't use the local variable ft_info.
+       (device_init): Adjusted for the change of gd_font_driver.
+
+       * textprop.c (mtext__prop_init): Initialize text_property_table.
+       Call M17N_OBJECT_ADD_ARRAY.
+       (mtext__prop_fini): Don't call mdebug__report_object.
+
+       * plist.c (mplist__init): Initialize plist_table.
+       (mplist__init): Call M17N_OBJECT_ADD_ARRAY.
+       (mplist__fini): Don't call mdebug__report_object.
+
+       * mtext.c (mtext__init): Call M17N_OBJECT_ADD_ARRAY.
+       (mtext__fini): Don't call mdebug__report_object.
+       (MTEXT_FORMAT_UTF_16): Correct type.
+       (mtext_data): New function.
+       (mtext_text): Fix calculation of limit and args to
+       find_char_backward.
+
+       * language.c: Include "plist.h".
+       (M_script_lang_list): New variable.
+       (mlang__init): Read languages and their information from m17n
+       database.
+       (mlanguage__list): New function.
+       (Miso639_1, Miso639_2): New variables.
+
+       * language.h (mlanguage__list): Extern it.
+
+       * database.c (get_database_stream): Use SAFE_* macros for
+       allocating and freeing path.
+       (mdatabase__init): Likewise.
+
+       * symbol.c (msymbol__fini): Don't free symbols here.
+       (msymbol__free_table): New function.
+       (msymbol_is_managing_key): New function.
+
+       * symbol.h (msymbol__free_table): Extern it.
+       (msymbol__list): Extern it.
+
+       * internal.h (MFATAL, USE_SAFE_ALLOCA, SAFE_ALLOCA, SAFE_FREE):
+       New macros.
+       (M17N_OBJECT_UNREF): Change "if ... else ..." structure.
+       (struct _M17NObjectArray): New member name and next.
+       (mdebug__add_object_array): Extern it.
+       (M17N_OBJECT_ADD_ARRAY): New macro.
+       (mdebug__report_object): Don't extern it.
+
+       * m17n-misc.h (enum MErrorCode): New element MERROR_FONT_X.
+
+       * m17n-gui.c (free_frame): Don't free frame->font.
+       (null_device_fini): Fix code for freeing
+       null_device.realized_font_list.
+       (m17n_fini_win): Free interface.
+       (mframe): Cast the return value of dlsym.  Set frame->font here.
+       (mframe_get_prop): Check frame->rface->rfont before accessing the
+       member font.
+
+       * m17n-gui.h (Mfontfile): Extern it.
+       (mfont_check): Extern it.
+       (mface_equal): Extern it.
+
+       * m17n-core.c: Include "symbol.h".
+       (report_header_printed): This variable deleted.
+       (object_array_root): New variable.
+       (report_object_array): New function.
+       (mdebug__report_object): This function deleted.
+       (mdebug__add_object_array): New function.
+       (m17n_init_core): Call mchartable_init () before mtext_init ().
+       (m17n_fini_core): Call report_object_array (if necessary) and
+       msymbol__free_atable at the end.
+
+       * m17n-core.h (msymbol_is_managing_key): Extern it.
+       (mtext_data): Extern it.
+       (MTEXT_FORMAT_UTF_16): Correct type.
+       (M17NLIB_MINOR_VERSION): Changed to 3.
+       (M17NLIB_VERSION_NAME): Changed to "1.3.0".
+       
+       * chartab.c (mchartable__init): Initalize chartable_table.count.
+       (mchartable__fini): Use N17N_OBJECT_ADD_ARRAY instead of
+       mdebug__report_object.
+
+2005-05-26  Kenichi Handa  <handa@m17n.org>
+
+       * m17n.h (Miso639_1, Miso639_2): Extern them.
+
+       * symbol.h (msymbol__list): Extern it.
+
+       * symbol.c (msymbol__list): New function.
+
+2005-05-19  Kenichi Handa  <handa@m17n.org>
+
+       * input-gui.c (minput__win_init): Don't change the value of
+       minput_driver.
+
+2005-05-16  Kenichi Handa  <handa@m17n.org>
+
+       * m17n-core.c (m17n_object): Be sure to initialize all members.
+
+       * font-ft.c (fc_decode_prop): Fix args to msymbol.
+
+2005-05-09  Kenichi Handa  <handa@m17n.org>
+
+       * m17n-X.c (mwin__close_device): Fix arg to M17N_OBJECT_UNREF.
+
+2005-04-27  Kenichi Handa  <handa@m17n.org>
+
+       * language.c (mlang__init): Add "an" (Aragonese).
+
+       * word-thai.c: Add support for libthai.
+       (mtext__word_thai_init): Initialize wordseg library conditionaly.
+       (mtext__word_thai_fini): Finalize wordseg library conditionaly.
+
+       * mtext.c: Include "word-thai.h" conditionaly.
+       (mtext__init): Call mtext__word_thai_init conditionaly.
+       (mtext__fini): Call mtext__word_thai_fini conditionaly.
+
+       * Makefile.am (libm17n_core_la_LIBADD): Add THAI_WORDSEG_LD_FLAGS,
+       not WORDCUT_LD_FLAGS.
+
+2005-04-19  Kenichi Handa  <handa@m17n.org>
+
+       * word-thai.c (wordseg_propertize): Always unref the attached
+       property.
+       (thai_wordseg): Don't unref the property.
+
+2005-04-18  Kenichi Handa  <handa@m17n.org>
+
+       * word-thai.c: Include stdlib.h.
+       (wordseg_propertize): Add dummy function for the case that wordcut
+       library doesn't exist.
+       (wordseg_propertize): Fix for old wordcut library.
+
+2005-04-16  Kenichi Handa  <handa@m17n.org>
+
+       * word-thai.c: Include <stdio.h>.
+
+2005-04-15  Kenichi Handa  <handa@m17n.org>
+
+       * draw.c: Include mtext.h.
+       (linebreak_table, M_break_at_space, M_break_at_word)
+       (M_break_at_any, M_kinsoku_bol, M_kinsoku_eol): New variables.
+       (compose_glyph_string): Check POS before getting Mface text
+       property.
+       (truncate_gstring): Give correct TO arg to line_break function.
+       (GET_LB_TYPE): New macro.
+       (find_break_backward, find_break_forward): New functions.
+       (mdraw__init): Initialize the above new variables.
+       (mdraw__fini): Free linebreak_table.
+       (mdraw_default_line_break): Use find_break_backward and
+       find_break_forward.
+
+       * word-thai.c: New file.
+
+       * word-thai.h: New file.
+
+       * mtext.c: Include word-thai.h.
+       (wordseg_func_table): New variable.
+       (mtext__init): Initialize wordseg_func_table and call
+       mtext__word_thai_init.
+       (mtext__fini): Call mtext__word_thai_fini, free
+       wordseg_func_table.
+       (MTextWordsegFunc): New type.
+       (mtext__word_segment): New function.
+
+       * mtext.h (wordseg_func_table): Extern it.
+       (mtext__word_segment): Extern it.
+
+       * m17n.c (m17n_init): Fix typo (== -> =).
+
+       * Makefile.am (libm17n_core_la_SOURCES): Include word-thai.[ch].
+       (libm17n_core_la_LIBADD): Add @WORDCUT_LD_FLAGS@.
+
+       * textprop.h (MTEXTPROP_START, MTEXTPROP_END, MTEXTPROP_KEY)
+       (MTEXTPROP_VAL): New macros.
+
+       * input.c (DLOPEN_SHLIB_EXT): Don't define it.
+
+2005-04-07  Kenichi Handa  <handa@m17n.org>
+
+       * database.c (load_chartable): Fix pursing of symbol name.
+
+2005-03-24  Kenichi Handa  <handa@m17n.org>
+
+       * m17n.c (m17n_init): Fix typo (== -> =).
+
+2005-03-11  Kenichi Handa  <handa@m17n.org>
+
+       * m17n-gui.c (m17n_init_win): Set merror_code to MERROR_NONE at first.
+
+       * m17n.c (m17n_init): Set merror_code to MERROR_NONE at first.
+
+       * m17n-core.c (m17n_init_core): Set merror_code to MERROR_NONE at
+       first.
+
+2005-03-09  handa  <handa@m17n.org>
+
+       * m17n-gui.c (m17n_init_win): Set merror_code to MERROR_NONE before
+       calling m17n_init ().
+
+       * m17n.c (m17n_init): Set merror_code to MERROR_NONE before
+       calling m17n_init_core ().
+
+2005-02-28  Kenichi Handa  <handa@m17n.org>
+
+       * font-flt.c (mfont__flt_run): Add resulting code sequence in
+       debug info.
+
+2005-02-17  Kenichi Handa  <handa@m17n.org>
+
+       * input.c: Include <sys/types.h>, <dirent.h>, and "database.h".
+       (M_description, M_command, M_variable): New variables.
+       (load_im_info_keys): New variables.
+       (load_im_info, check_command_keyseq, get_description_advance)
+       (parse_command_list, get_command_list, parse_variable_list)
+       (get_variable_list, input_method_hook): New functions.
+       (command_list, variable_list): New variables.
+       (minput__init): Put input_method_hook to Minput_method.
+       Initialize M_description, M_command, M_variable, Mdetail_text,
+       load_im_info_keys, command_list, variable_list.
+       (minput__fini): Unref command_list, variable_list, load_im_info_keys.
+       (Mdetail_text): New variable.
+       (minput_get_description, minput_get_commands)
+       (minput_assign_command_keys, minput_get_variables)
+       (minput_set_variable): New functions.
+
+       * m17n.h (Mdetail_text, minput_get_description, minput_get_commands)
+       (minput_assign_command_keys, minput_get_variables)
+       (minput_set_variable): Extern them.
+
+       * plist.c (UNGETC): Just decrement st->p.
+       (read_mtext_element): New arg skip.
+       (read_integer_element): Likewise.
+       (read_symbol_element): Likewise.
+       (read_element): New arg KEYS.
+       (mplist__from_plist): Don't increment ref-count of NULL object.
+       (mplist__from_file): New arg KEYS.
+       (mplist_put): Don't increment ref-count of NULL object.
+       (mplist_add): Likewise.
+       (mplist_push): Likewise.
+       (mplist_set): Likewise.  Call M17N_OBJECT_UNREF unconditionally.
+
+       * plist.h (mplist__from_file): Prototype adjusted.
+
+       * database.c (mdatabase__dir_list): Renamed from mdb_dir_list.
+       (get_database_stream): New function.
+       (load_database): Use get_database_stream.
+       (M_database_hook): New variable
+       (mdatabase__init): Initialize M_database_hook.
+       (mdatabase__load_for_keys): New function.
+       (mdatabase_find, mdatabase_list, mdatabase_define): Check hook
+       function.
+       (mdatabase_define): Free mdb->extra_info if necessary.
+
+       * database.h (mdatabase__dir_list, M_database_hook)
+       (mdatabase__load_for_keys): Extern them.
+       (MDatabaseHookFunc): New type.
+
+       * internal.h (M17N_OBJECT_UNREF): When freed, set OBJECT to NULL.
+
+2004-12-27  Kenichi Handa  <handa@m17n.org>
+
+       * Version 1.2.0 released.
+
+2004-12-27  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (minput_filter): Don't reset ic->xxx_changed.
+
+       * mtext.c (mtext_from_data): Fix documentation.
+
+2004-12-25  Kenichi Handa  <handa@m17n.org>
+
+       * m17n-core.h (M17NLIB_MINOR_VERSION): Update to 2.
+       (M17NLIB_VERSION_NAME): Update to "1.2.".
+
+2004-12-24  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (reset_ic): Set key_unhandled to 0.
+
+2004-12-21  Kenichi Handa  <handa@m17n.org>
+
+       * m17n-gui.h (mfont_from_spec): Delete extern.
+
+       * input-gui.c (win_callback): Handle Minput_reset.
+       (minput__win_init): Register reset_ic as a callback for
+       Minput_reset.
+
+       * input.c (reset_ic): New arg IGNORE which is ignored.  Caller
+       changed.  At first, shift to the initial state.
+       (minput__init): Initialize Minput_reset.  Register reset_ic as a
+       callback for Minput_reset.
+       (Minput_reset): New variable.
+       (minput_filter): Always set ic->xxx_changed to 0.
+       (minput_reset_ic): New function.
+       (integer_value): Fix typo ('>' -> '<') and calculation of length
+       of preedit text.
+
+       * m17n-core.c (merror_code): Change type to `int'.
+
+       * m17n-misc.h (merror_code): Adjust type.
+
+       * m17n.h (Minput_reset, minput_reset_ic): Extern them.
+
+       * m17n-core.h (MTEXT_FORMAT_UTF_16, MTEXT_FORMAT_UTF_32): Adjust types.
+       (mtext_change_prop): Delete extern.
+
+       * mtext.c (MTEXT_FORMAT_UTF_16, MTEXT_FORMAT_UTF_32): Change types
+       to `int'.  Move the documents to m17n-core.h.
+
+2004-12-13  Kenichi Handa  <handa@m17n.org>
+
+       * m17n-core.h (m17n_object): Rename extern from m17n_object_setup.
+       (MTextProperty): Document it.
+
+2004-12-09  Kenichi Handa  <handa@m17n.org>
+
+       * m17n-core.h: Fix typo (MTextStatus -> M17NStatus).
+
+2004-12-03  Kenichi Handa  <handa@m17n.org>
+
+       * internal.h (m17n__core_initialized, m17n__shell_initialized,
+       m17n__gui_initialized): New externs.
+
+       * m17n-core.h (enum M17NStatus): New enum.
+       (m17n_status): Extern it.
+
+       * m17n-core.c (core_initialized): Delete this variable.
+       (m17n__core_initialized, m17n__shell_initialized,
+       m17n__gui_initialized): New variables.
+       (m17n_init_core, m17n_fini_core): Check m17n__core_initialized
+       instead of core_initialized.
+       (m17n_status): New function.
+
+       * m17n.c (shell_initialized): Delete this variable.
+       (m17n_init, m17n_fini): Check m17n__shell_initialized instead of
+       shell_initialized.
+
+       * m17n-gui.h (m17n_init_win): Adjust the prototype.
+
+       * m17n-gui.c (win_initialized): Delete this variable.
+       (m17n_init_win, m17n_fini_win): Check m17n__gui_initialized
+       instead of gui_initialized.
+
+2004-11-19  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (reset_ic): Check if ic_info->state is NULL.
+       (filter): If ic_info->state is NULL, return 0.
+       (load_input_method): Don't unref `maps' it it's not created.
+
+2004-11-15  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (find_candidates_group): If INDEX is -1, find the last
+       candidate group.
+       (take_action_list): If the previous of the first candidate is
+       requested, select the last candidate.
+
+2004-11-08  Kenichi Handa  <handa@m17n.org>
+
+       * m17n-X.c (device_open): Try at most 32 fonts to find a
+       non-autoscaled font.
+
+       * font.c (xlfd_parse_name): Fix previous change.
+
+2004-11-05  Kenichi Handa  <handa@m17n.org>
+
+       * font.c: (commont_style): Include dummy elements "slanted" and
+       "rslanted" to prefer "o" to "r" if "i" is requested.
+
+       * font-ft.c (ft_to_prop): Fix "oblique" entry.
+
+2004-10-29  Kenichi Handa  <handa@m17n.org>
+
+       * font.c (xlfd_parse_name): If avgwidth is 0, set the size to 0.
+
+       * m17n-X.c (MXFont): Change type of the member `sizes' to int.
+       New members smallest and larger.
+       (SET_SIZE, HAVE_SIZE): Adjusted for the above change.
+       (xfont_registry_list): Likewise.
+       (xfont_select): Likewise.
+       
+
+2004-10-28  Kenichi Handa  <handa@m17n.org>
+
+       * m17n-X.c (xfont_registry_list): Include '-' before PIXEL_SIZE in
+       font name comparison.
+       (xfont_select): Fix logic for selecting a larger size font.
+
+2004-10-25  Kenichi Handa  <handa@m17n.org>
+
+       * input.c (take_action_list): Initialize `ret' to 0 for "=", "<",
+       ">" actions.
+
 2004-10-22  Kenichi Handa  <handa@m17n.org>
 
        * input.c (update_candidate): Renamed from udpate_candidate.
@@ -1493,5 +3714,5 @@ Lesser General Public License for more details.
 
 You should have received a copy of the GNU Lesser General Public
 License along with the m17n library; if not, write to the Free
-Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
-02111-1307, USA.
+Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+Boston, MA 02110-1301, USA.