Codebase list mozc / c19abb4
Update patch for fcitx: Fix build of Utf8SubString Signed-off-by: Nobuhiro Iwamatsu <iwamatsu@debian.org> Nobuhiro Iwamatsu 3 years ago
2 changed file(s) with 5 addition(s) and 3 deletion(s). Raw diff Collapse all Expand all
1515 * protobuf_generated_classes_no_inheritance.patch
1616 * Update 0001-Update-uim-mozc-to-c979f127acaeb7b35d3344e8b1e40848e.patch
1717 * Fix build with latest mozc.
18 * Update 0002-Support-fcitx.patch
19 * Fix build of Utf8SubString for fcitx.
1820
1921 -- Nobuhiro Iwamatsu <iwamatsu@debian.org> Sun, 27 Dec 2020 22:01:58 +0900
2022
47164716 +
47174717 + const size_t selection_start = std::min(cursor_pos, anchor_pos);
47184718 + const size_t selection_length = std::abs(info->relative_selected_length);
4719 + info->preceding_text = Util::Utf8SubString(surrounding_text, 0, selection_start);
4720 + info->selection_text = Util::Utf8SubString(surrounding_text, selection_start, selection_length);
4721 + info->following_text = Util::Utf8SubString(surrounding_text, selection_start + selection_length);
4719 + info->preceding_text = std::string(Util::Utf8SubString(surrounding_text, 0, selection_start));
4720 + info->selection_text = std::string(Util::Utf8SubString(surrounding_text, selection_start, selection_length));
4721 + info->following_text = std::string(Util::Utf8SubString(surrounding_text, selection_start + selection_length));
47224722 + return true;
47234723 +}
47244724 +