diff --git a/ibus-m17n-stsreq.patch b/ibus-m17n-stsreq.patch new file mode 100644 index 0000000..6c2f6f8 --- /dev/null +++ b/ibus-m17n-stsreq.patch @@ -0,0 +1,33 @@ +From 02e72cdd3673c65d4217ea19fab7aa2fdfd449f6 Mon Sep 17 00:00:00 2001 +From: Daiki Ueno +Date: Tue, 14 Jun 2011 16:10:23 +0900 +Subject: [PATCH] Proclaim we will use surrounding-text, in enable(). + +--- + src/engine.c | 10 ++++++++++ + 1 files changed, 10 insertions(+), 0 deletions(-) + +diff --git a/src/engine.c b/src/engine.c +index 60816b0..b68b13e 100644 +--- a/src/engine.c ++++ b/src/engine.c +@@ -697,6 +697,16 @@ ibus_m17n_engine_enable (IBusEngine *engine) + IBusM17NEngine *m17n = (IBusM17NEngine *) engine; + + parent_class->enable (engine); ++ ++#ifdef HAVE_IBUS_ENGINE_GET_SURROUNDING_TEXT ++ /* Issue a dummy ibus_engine_get_surrounding_text() call to tell ++ input context that we will use surrounding-text. */ ++ IBusText *text; ++ guint cursor_pos; ++ ++ ibus_engine_get_surrounding_text (engine, &text, &cursor_pos); ++ g_object_unref (text); ++#endif /* HAVE_IBUS_ENGINE_GET_SURROUNDING_TEXT */ + } + + static void +-- +1.7.5.2 + diff --git a/ibus-m17n.spec b/ibus-m17n.spec index 9f10fc2..89ed649 100644 --- a/ibus-m17n.spec +++ b/ibus-m17n.spec @@ -2,7 +2,7 @@ Name: ibus-m17n Version: 1.3.2 -Release: 4%{?dist} +Release: 5%{?dist} Summary: The M17N engine for IBus platform License: GPLv2+ Group: System Environment/Libraries @@ -11,7 +11,10 @@ Source0: http://ibus.googlecode.com/files/%{name}-%{version}.tar.gz Patch0: ibus-m17n-iok.patch Patch1: ibus-m17n-HEAD.patch +# Surrounding-text support fixes. Hopefully Patch2 won't be needed +# with future IBus versions. Patch2: ibus-m17n-stscap.patch +Patch3: ibus-m17n-stsreq.patch # The following BR is for autogen and not necessary when packging # released tarballs. @@ -36,6 +39,7 @@ the input table maps from m17n-db. %patch0 -p1 -b .iok %patch1 -p1 -b .HEAD %patch2 -p1 -b .stscap +%patch3 -p1 -b .stsreq NOCONFIGURE=1 ./autogen.sh %build @@ -57,6 +61,11 @@ make DESTDIR=${RPM_BUILD_ROOT} install %{_datadir}/ibus/component/* %changelog +* Wed Jun 15 2011 Daiki Ueno - 1.3.2-5 +- Add ibus-m17n-stsreq.patch. +- Fix bug 711126 - ibus: surrounding text support fails for the first + syllable upon activation + * Tue Jun 7 2011 Daiki Ueno - 1.3.2-4 - Add ibus-m17n-stscap.patch. - Fix bug 711126 - ibus: surrounding text support fails for the first