From c4f57271683ec7eb98b43ee4aae94cff1b341483 Mon Sep 17 00:00:00 2001 From: Peng Wu Date: Thu, 30 Jun 2016 14:30:46 +0800 Subject: begin to add pinyin_remember_user_input function --- src/pinyin.h | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) (limited to 'src/pinyin.h') diff --git a/src/pinyin.h b/src/pinyin.h index 610070e..9599aab 100644 --- a/src/pinyin.h +++ b/src/pinyin.h @@ -994,7 +994,22 @@ bool pinyin_get_chewing_auxiliary_text(pinyin_instance_t * instance, size_t cursor, gchar ** aux_text); -/* hack here. */ +/** + * pinyin_remember_user_input: + * @instance: the pinyin instance. + * @phrase: the utf8 phrase. + * @count: the count of the phrase, -1 to use the default value. + * @returns: whether the phrase is remembered. + * + * Remember the current phrase and pinyin pair. + * + */ +bool pinyin_remember_user_input(pinyin_instance_t * instance, + const char * phrase, + gint count); + + +/* for compatibility. */ typedef ChewingKey PinyinKey; typedef ChewingKeyRest PinyinKeyPos; -- cgit