├── AUTHORS ├── README ├── config.h.in ├── data ├── hangul.png ├── hanja_active.png ├── hanja_inactive.png ├── CMakeLists.txt └── symbol.txt ├── .gitignore ├── src ├── hangul.conf.in ├── keyboard.c ├── fcitx-hangul.conf.in ├── keyboard.h ├── CMakeLists.txt ├── fcitx-hangul.desc ├── config.c ├── ustring.h ├── eim.h ├── ustring.c └── eim.c ├── list ├── CMakeLists.txt └── gen_list.c ├── po ├── CMakeLists.txt ├── getdescpo ├── fcitx-hangul.pot ├── da.po ├── ja.po ├── zh_TW.po ├── tr.po ├── de.po ├── zh_CN.po ├── ca.po ├── ru.po └── ko.po ├── INSTALL ├── cmake ├── cmake_uninstall.cmake.in └── FindHangul.cmake ├── CMakeLists.txt └── COPYING /AUTHORS: -------------------------------------------------------------------------------- 1 | Weng Xuetian 2 | -------------------------------------------------------------------------------- /README: -------------------------------------------------------------------------------- 1 | fcitx-hangul 2 | Hangul Wrapper for Fcitx. 3 | -------------------------------------------------------------------------------- /config.h.in: -------------------------------------------------------------------------------- 1 | #define CHEWING_DATADIR "@CHEWING_DATADIR@" -------------------------------------------------------------------------------- /data/hangul.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fcitx/fcitx-hangul/HEAD/data/hangul.png -------------------------------------------------------------------------------- /data/hanja_active.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fcitx/fcitx-hangul/HEAD/data/hanja_active.png -------------------------------------------------------------------------------- /data/hanja_inactive.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fcitx/fcitx-hangul/HEAD/data/hanja_inactive.png -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | build/* 2 | *.kdev4 3 | .kdev_include_paths 4 | .directory 5 | *.kate-swp 6 | *.orig 7 | *~ 8 | -------------------------------------------------------------------------------- /src/hangul.conf.in: -------------------------------------------------------------------------------- 1 | [InputMethod] 2 | UniqueName=hangul 3 | _Name=Hangul 4 | IconName=hangul 5 | Priority=1 6 | LangCode=ko 7 | Parent=fcitx-hangul 8 | -------------------------------------------------------------------------------- /list/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | 2 | include_directories (${HANGUL_INCLUDE_DIR}) 3 | 4 | add_executable(gen_list gen_list.c) 5 | target_link_libraries (gen_list ${HANGUL_LIBRARIES}) 6 | -------------------------------------------------------------------------------- /src/keyboard.c: -------------------------------------------------------------------------------- 1 | /* generated */ 2 | 3 | const char* keyboard[] = { 4 | "2", 5 | "2y", 6 | "39", 7 | "3f", 8 | "3s", 9 | "3y", 10 | "32", 11 | "ro", 12 | "ahn" 13 | }; -------------------------------------------------------------------------------- /src/fcitx-hangul.conf.in: -------------------------------------------------------------------------------- 1 | [Addon] 2 | Name=fcitx-hangul 3 | _GeneralName=Hangul 4 | _Comment=Hangul Wrapper For Fcitx 5 | Category=InputMethod 6 | Enabled=True 7 | Library=fcitx-hangul.so 8 | Type=SharedLibrary 9 | IMRegisterMethod=ConfigFile -------------------------------------------------------------------------------- /po/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | file(GLOB PO_FILES RELATIVE "${CMAKE_CURRENT_SOURCE_DIR}" *.po) 2 | 3 | foreach(po_file ${PO_FILES}) 4 | string(REPLACE ".po" "" po_lang "${po_file}") 5 | fcitx_translate_add_po_file("${po_lang}" "${po_file}") 6 | endforeach() 7 | fcitx_translate_set_pot_target(pot fcitx-hangul fcitx-hangul.pot) 8 | -------------------------------------------------------------------------------- /src/keyboard.h: -------------------------------------------------------------------------------- 1 | /* generated */ 2 | 3 | #ifndef FCITX_HANGUL_KEYBOARD_H 4 | #define FCITX_HANGUL_KEYBOARD_H 5 | 6 | typedef enum _FcitxHangulKeyboard 7 | { 8 | Dubeolsik = 0, 9 | Dubeolsik_Yetgeul, 10 | Sebeolsik_390, 11 | Sebeolsik_Final, 12 | Sebeolsik_Noshift, 13 | Sebeolsik_Yetgeul, 14 | Sebeolsik_Dubeol_Layout, 15 | Romaja, 16 | Ahnmatae, 17 | } FcitxHangulKeyboard; 18 | 19 | extern const char* keyboard[]; 20 | 21 | #endif -------------------------------------------------------------------------------- /INSTALL: -------------------------------------------------------------------------------- 1 | fcitx-hangul install instructions 2 | ================================================= 3 | 4 | To compile and install, go in the source directory and type: 5 | mkdir build; cd build 6 | cmake .. 7 | (If you want to install in a different path, use instead: 8 | cmake .. -DCMAKE_INSTALL_PREFIX=/install/path) 9 | make 10 | 11 | To install, become root if required: 12 | 13 | make install 14 | 15 | Once installed, you can restart fcitx and it will be enabled by default. 16 | -------------------------------------------------------------------------------- /data/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | install(FILES symbol.txt DESTINATION ${FCITX4_PREFIX}/share/fcitx/hangul/) 2 | install(FILES hangul.png DESTINATION ${FCITX4_PREFIX}/share/fcitx/imicon/) 3 | install(FILES hangul.png RENAME fcitx-hangul.png DESTINATION share/icons/hicolor/64x64/apps/) 4 | install(FILES hanja_active.png RENAME fcitx-hanja-active.png DESTINATION share/icons/hicolor/48x48/status/) 5 | install(FILES hanja_inactive.png RENAME fcitx-hanja-inactive.png DESTINATION share/icons/hicolor/48x48/status/) 6 | -------------------------------------------------------------------------------- /src/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | 2 | include_directories (${HANGUL_INCLUDE_DIR} 3 | ${FCITX4_FCITX_CONFIG_INCLUDE_DIRS} 4 | ${FCITX4_FCITX_INCLUDE_DIRS} 5 | ${PROJECT_BINARY_DIR}) 6 | 7 | set( fcitx_hangul_sources 8 | ustring.c 9 | eim.c 10 | config.c 11 | keyboard.c 12 | ) 13 | 14 | add_definitions( -DLOCALEDIR=\"${CMAKE_INSTALL_PREFIX}/share/locale\" ) 15 | 16 | fcitx_add_addon_full(hangul 17 | DESC 18 | IM_CONFIG hangul.conf 19 | SOURCES ${fcitx_hangul_sources} 20 | LINK_LIBS ${HANGUL_LIBRARIES} 21 | ) 22 | -------------------------------------------------------------------------------- /src/fcitx-hangul.desc: -------------------------------------------------------------------------------- 1 | [Hangul/Keyboard] 2 | Type=Enum 3 | DefaultValue=Dubeolsik 4 | Description=Keyboard Layout 5 | EnumCount=9 6 | Enum0=Dubeolsik 7 | Enum1=Dubeolsik Yetgeul 8 | Enum2=Sebeolsik 390 9 | Enum3=Sebeolsik Final 10 | Enum4=Sebeolsik Noshift 11 | Enum5=Sebeolsik Yetgeul 12 | Enum6=Sebeolsik Dubeol Layout 13 | Enum7=Romaja 14 | Enum8=Ahnmatae 15 | 16 | 17 | [Hangul/HanjaModeToggleKey] 18 | Type=Hotkey 19 | DefaultValue=HANGULHANJA F9 20 | Description=Hanja Mode Toggle Key 21 | 22 | [Hangul/AutoReorder] 23 | Type=Boolean 24 | DefaultValue=True 25 | Description=Auto Reorder 26 | 27 | [Hangul/WordCommit] 28 | Type=Boolean 29 | DefaultValue=False 30 | Description=Word Commit 31 | 32 | [Hangul/HanjaMode] 33 | Type=Boolean 34 | DefaultValue=False 35 | Description=Hanja Mode 36 | 37 | [DescriptionFile] 38 | LocaleDomain=fcitx-hangul -------------------------------------------------------------------------------- /cmake/cmake_uninstall.cmake.in: -------------------------------------------------------------------------------- 1 | if (NOT EXISTS "@CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt") 2 | message(FATAL_ERROR "Cannot find install manifest: \"@CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt\"") 3 | endif(NOT EXISTS "@CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt") 4 | 5 | file(READ "@CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt" files) 6 | string(REGEX REPLACE "\n" ";" files "${files}") 7 | foreach (file ${files}) 8 | message(STATUS "Uninstalling \"$ENV{DESTDIR}${file}\"") 9 | if (EXISTS "$ENV{DESTDIR}${file}" OR IS_SYMLINK "$ENV{DESTDIR}${file}") 10 | execute_process( 11 | COMMAND @CMAKE_COMMAND@ -E remove "$ENV{DESTDIR}${file}" 12 | OUTPUT_VARIABLE rm_out 13 | RESULT_VARIABLE rm_retval 14 | ) 15 | if(NOT ${rm_retval} EQUAL 0) 16 | message(FATAL_ERROR "Problem when removing \"$ENV{DESTDIR}${file}\"") 17 | endif (NOT ${rm_retval} EQUAL 0) 18 | else (EXISTS "$ENV{DESTDIR}${file}" OR IS_SYMLINK "$ENV{DESTDIR}${file}") 19 | message(STATUS "File \"$ENV{DESTDIR}${file}\" does not exist.") 20 | endif (EXISTS "$ENV{DESTDIR}${file}" OR IS_SYMLINK "$ENV{DESTDIR}${file}") 21 | endforeach(file) -------------------------------------------------------------------------------- /cmake/FindHangul.cmake: -------------------------------------------------------------------------------- 1 | # - Try to find the Libpinyin libraries 2 | # Once done this will define 3 | # 4 | # HANGUL_FOUND - system has HANGUL 5 | # HANGUL_INCLUDE_DIR - the HANGUL include directory 6 | # HANGUL_LIBRARIES - HANGUL library 7 | # 8 | # Copyright (c) 2012 CSSlayer 9 | # 10 | # Redistribution and use is allowed according to the terms of the BSD license. 11 | # For details see the accompanying COPYING-CMAKE-SCRIPTS file. 12 | 13 | if(HANGUL_INCLUDE_DIR AND HANGUL_LIBRARIES) 14 | # Already in cache, be silent 15 | set(HANGUL_FIND_QUIETLY TRUE) 16 | endif(HANGUL_INCLUDE_DIR AND HANGUL_LIBRARIES) 17 | 18 | find_package(PkgConfig REQUIRED) 19 | pkg_check_modules(PC_LIBHANGUL "libhangul>=0.0.12") 20 | 21 | find_path(HANGUL_MAIN_INCLUDE_DIR 22 | NAMES hangul.h 23 | HINTS ${PC_LIBHANGUL_INCLUDE_DIRS}) 24 | 25 | find_library(HANGUL_LIBRARIES 26 | NAMES hangul 27 | HINTS ${PC_LIBHANGUL_LIBDIR}) 28 | 29 | set(HANGUL_INCLUDE_DIR "${HANGUL_MAIN_INCLUDE_DIR}") 30 | 31 | include(FindPackageHandleStandardArgs) 32 | find_package_handle_standard_args(Hangul DEFAULT_MSG 33 | HANGUL_LIBRARIES 34 | HANGUL_MAIN_INCLUDE_DIR 35 | ) 36 | 37 | mark_as_advanced(HANGUL_INCLUDE_DIR HANGUL_LIBRARIES) 38 | -------------------------------------------------------------------------------- /CMakeLists.txt: -------------------------------------------------------------------------------- 1 | cmake_minimum_required (VERSION 2.6) 2 | 3 | project(fcitx-hangul) 4 | 5 | set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake" ${CMAKE_MODULE_PATH}) 6 | 7 | FIND_PACKAGE(Gettext REQUIRED) 8 | FIND_PACKAGE(Fcitx 4.2.7 REQUIRED) 9 | find_package(Hangul REQUIRED) 10 | 11 | # uninstall target 12 | configure_file( 13 | "${CMAKE_CURRENT_SOURCE_DIR}/cmake/cmake_uninstall.cmake.in" 14 | "${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake" 15 | IMMEDIATE @ONLY) 16 | 17 | add_custom_target(uninstall 18 | COMMAND ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake) 19 | 20 | set(CMAKE_C_FLAGS "-Wall -Wextra -Wno-sign-compare -Wno-unused-parameter -fvisibility=hidden ${CMAKE_C_FLAGS}") 21 | set(CMAKE_CXX_FLAGS "-Wall -Wextra -Wno-sign-compare -Wno-unused-parameter -fvisibility=hidden ${CMAKE_CXX_FLAGS}") 22 | set(CMAKE_SHARED_LINKER_FLAGS "-Wl,--as-needed ${CMAKE_SHARED_LINKER_FLAGS}") 23 | set(CMAKE_MODULE_LINKER_FLAGS "-Wl,--as-needed ${CMAKE_MODULE_LINKER_FLAGS}") 24 | add_definitions("-D_GNU_SOURCE") 25 | 26 | if(NOT DEFINED LIB_INSTALL_DIR) 27 | set(LIB_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}/lib) 28 | endif() 29 | 30 | configure_file( 31 | "${CMAKE_CURRENT_SOURCE_DIR}/config.h.in" 32 | "${CMAKE_CURRENT_BINARY_DIR}/config.h" 33 | ) 34 | 35 | set(libdir ${LIB_INSTALL_DIR}) 36 | 37 | add_subdirectory(po) 38 | add_subdirectory(src) 39 | add_subdirectory(data) 40 | add_subdirectory(list) -------------------------------------------------------------------------------- /po/getdescpo: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | filename=desc.po 3 | indir=$1 4 | outdir=$2 5 | 6 | cd "$outdir" 7 | 8 | rm -f "$outdir/$filename"; touch "$outdir/$filename" 9 | 10 | cat > "$outdir/$filename" <, YEAR. 15 | # 16 | #, fuzzy 17 | msgid "" 18 | msgstr "" 19 | "Project-Id-Version: PACKAGE VERSION\n" 20 | "Report-Msgid-Bugs-To: fcitx-dev@googlegroups.com\n" 21 | "POT-Creation-Date: 2010-11-17 11:48+0800\n" 22 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" 23 | "Last-Translator: FULL NAME \n" 24 | "Language-Team: LANGUAGE \n" 25 | "Language: \n" 26 | "MIME-Version: 1.0\n" 27 | "Content-Type: text/plain; charset=UTF-8\n" 28 | "Content-Transfer-Encoding: 8bit\n" 29 | EOF 30 | 31 | cd $indir 32 | 33 | descfiles=`find "$indir" -name ".hg" -prune -or -name "test" -prune -or -iname "*.desc" | grep desc` 34 | 35 | # Extract Description 36 | for f in $descfiles 37 | do 38 | awk '/^[\t ]*Description=/ { print "\n#: '$f':" NR"\n" "msgid \"" substr($0, 13)"\"\n" "msgstr \"\""}' "$f" >> "$outdir/$filename" 39 | done 40 | 41 | # Extract Group Name 42 | grep -nH '^\[' $descfiles | grep -v 'DescriptionFile' | awk ' "^[" { split($0, a, ":"); split(a[3], b, "/"); print substr(b[1], 2); }' | sort | uniq | awk '{ print "# unknown\nmsgid \""$0"\"\nmsgstr \"\"\n"; }' >> "$outdir/$filename" 43 | 44 | # Extract Enum Name 45 | grep -h 'Enum[0-9]' $descfiles | sed -e 's/Enum[0-9]=//g' | sort | uniq | awk '{ print "#: unknown\nmsgid \""$0"\"\nmsgstr \"\"\n"; }' >> "$outdir/$filename" 46 | 47 | -------------------------------------------------------------------------------- /list/gen_list.c: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (C) 2012~2012 by CSSlayer * 3 | * wengxt@gmail.com * 4 | * * 5 | * This program is free software; you can redistribute it and/or modify * 6 | * it under the terms of the GNU General Public License as published by * 7 | * the Free Software Foundation; either version 2 of the License, or * 8 | * (at your option) any later version. * 9 | * * 10 | * This program is distributed in the hope that it will be useful, * 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of * 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * 13 | * GNU General Public License for more details. * 14 | * * 15 | * You should have received a copy of the GNU General Public License * 16 | * along with this program; if not, write to the * 17 | * Free Software Foundation, Inc., * 18 | * 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. * 19 | ***************************************************************************/ 20 | 21 | #include 22 | #include 23 | 24 | int main(int argc, char* argv[]) 25 | { 26 | unsigned int nkeyboard = hangul_ic_get_n_keyboards(), i; 27 | for (i = 0 ; i < nkeyboard ; i ++) 28 | printf("\"%s\" \"%s\"\n", hangul_ic_get_keyboard_name(i), hangul_ic_get_keyboard_id(i)); 29 | return 0; 30 | } -------------------------------------------------------------------------------- /src/config.c: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (C) 2010~2012 by CSSlayer * 3 | * wengxt@gmail.com * 4 | * * 5 | * This program is free software; you can redistribute it and/or modify * 6 | * it under the terms of the GNU General Public License as published by * 7 | * the Free Software Foundation; either version 2 of the License, or * 8 | * (at your option) any later version. * 9 | * * 10 | * This program is distributed in the hope that it will be useful, * 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of * 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * 13 | * GNU General Public License for more details. * 14 | * * 15 | * You should have received a copy of the GNU General Public License * 16 | * along with this program; if not, write to the * 17 | * Free Software Foundation, Inc., * 18 | * 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. * 19 | ***************************************************************************/ 20 | 21 | #include "eim.h" 22 | 23 | /* USE fcitx provided macro to bind config and variable */ 24 | CONFIG_BINDING_BEGIN(FcitxHangulConfig) 25 | CONFIG_BINDING_REGISTER("Hangul", "Keyboard", keyboardLayout) 26 | CONFIG_BINDING_REGISTER("Hangul", "HanjaModeToggleKey", hkHanjaMode) 27 | CONFIG_BINDING_REGISTER("Hangul", "HanjaMode", hanjaMode) 28 | CONFIG_BINDING_REGISTER("Hangul", "AutoReorder", autoReorder) 29 | CONFIG_BINDING_REGISTER("Hangul", "WordCommit", wordCommit) 30 | CONFIG_BINDING_END() -------------------------------------------------------------------------------- /src/ustring.h: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (C) 2012~2012 by CSSlayer * 3 | * wengxt@gmail.com * 4 | * * 5 | * This program is free software; you can redistribute it and/or modify * 6 | * it under the terms of the GNU General Public License as published by * 7 | * the Free Software Foundation; either version 2 of the License, or * 8 | * (at your option) any later version. * 9 | * * 10 | * This program is distributed in the hope that it will be useful, * 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of * 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * 13 | * GNU General Public License for more details. * 14 | * * 15 | * You should have received a copy of the GNU General Public License * 16 | * along with this program; if not, write to the * 17 | * Free Software Foundation, Inc., * 18 | * 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. * 19 | ***************************************************************************/ 20 | 21 | #ifndef USTRING_H 22 | #define USTRING_H 23 | 24 | #include 25 | #include 26 | 27 | typedef UT_array UString; 28 | 29 | UString* ustring_new(); 30 | UString* ustring_dup(const UString* str); 31 | void ustring_delete(UString* str); 32 | 33 | void ustring_clear(UString* str); 34 | UString* ustring_erase(UString* str, size_t pos, size_t len); 35 | 36 | ucschar* ustring_begin(UString* str); 37 | ucschar* ustring_end(UString* str); 38 | unsigned ustring_length(const UString* str); 39 | 40 | UString* ustring_append(UString* str, const UString* s); 41 | UString* ustring_append_ucs4(UString* str, const ucschar* s); 42 | UString* ustring_append_utf8(UString* str, const char* utf8); 43 | 44 | #endif -------------------------------------------------------------------------------- /po/fcitx-hangul.pot: -------------------------------------------------------------------------------- 1 | # SOME DESCRIPTIVE TITLE. 2 | # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER 3 | # This file is distributed under the same license as the PACKAGE package. 4 | # FIRST AUTHOR , YEAR. 5 | # 6 | #, fuzzy 7 | msgid "" 8 | msgstr "" 9 | "Project-Id-Version: PACKAGE VERSION\n" 10 | "Report-Msgid-Bugs-To: fcitx-dev@googlegroups.com\n" 11 | "POT-Creation-Date: 2017-06-13 12:02-0700\n" 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" 13 | "Last-Translator: FULL NAME \n" 14 | "Language-Team: LANGUAGE \n" 15 | "Language: LANG\n" 16 | "MIME-Version: 1.0\n" 17 | "Content-Type: text/plain; charset=utf-8\n" 18 | "Content-Transfer-Encoding: 8bit\n" 19 | 20 | #: src/eim.c:764 src/fcitx-hangul.conf.in:3 src/hangul.conf.in:3 21 | #: src/fcitx-hangul.desc:1 src/fcitx-hangul.desc:17 src/fcitx-hangul.desc:22 22 | #: src/fcitx-hangul.desc:27 src/fcitx-hangul.desc:32 23 | msgid "Hangul" 24 | msgstr "" 25 | 26 | #: src/eim.c:815 27 | msgid "Use Hanja" 28 | msgstr "" 29 | 30 | #: src/eim.c:818 31 | msgid "Use Hangul" 32 | msgstr "" 33 | 34 | #: src/fcitx-hangul.conf.in:4 35 | msgid "Hangul Wrapper For Fcitx" 36 | msgstr "" 37 | 38 | #: src/fcitx-hangul.desc:4 39 | msgid "Keyboard Layout" 40 | msgstr "" 41 | 42 | #: src/fcitx-hangul.desc:6 43 | msgid "Dubeolsik" 44 | msgstr "" 45 | 46 | #: src/fcitx-hangul.desc:7 47 | msgid "Dubeolsik Yetgeul" 48 | msgstr "" 49 | 50 | #: src/fcitx-hangul.desc:8 51 | msgid "Sebeolsik 390" 52 | msgstr "" 53 | 54 | #: src/fcitx-hangul.desc:9 55 | msgid "Sebeolsik Final" 56 | msgstr "" 57 | 58 | #: src/fcitx-hangul.desc:10 59 | msgid "Sebeolsik Noshift" 60 | msgstr "" 61 | 62 | #: src/fcitx-hangul.desc:11 63 | msgid "Sebeolsik Yetgeul" 64 | msgstr "" 65 | 66 | #: src/fcitx-hangul.desc:12 67 | msgid "Sebeolsik Dubeol Layout" 68 | msgstr "" 69 | 70 | #: src/fcitx-hangul.desc:13 71 | msgid "Romaja" 72 | msgstr "" 73 | 74 | #: src/fcitx-hangul.desc:14 75 | msgid "Ahnmatae" 76 | msgstr "" 77 | 78 | #: src/fcitx-hangul.desc:20 79 | msgid "Hanja Mode Toggle Key" 80 | msgstr "" 81 | 82 | #: src/fcitx-hangul.desc:25 83 | msgid "Auto Reorder" 84 | msgstr "" 85 | 86 | #: src/fcitx-hangul.desc:30 87 | msgid "Word Commit" 88 | msgstr "" 89 | 90 | #: src/fcitx-hangul.desc:35 91 | msgid "Hanja Mode" 92 | msgstr "" 93 | -------------------------------------------------------------------------------- /po/da.po: -------------------------------------------------------------------------------- 1 | # SOME DESCRIPTIVE TITLE. 2 | # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER 3 | # This file is distributed under the same license as the PACKAGE package. 4 | # 5 | # Translators: 6 | # scootergrisen, 2017 7 | msgid "" 8 | msgstr "" 9 | "Project-Id-Version: fcitx\n" 10 | "Report-Msgid-Bugs-To: fcitx-dev@googlegroups.com\n" 11 | "POT-Creation-Date: 2017-11-10 16:03-0800\n" 12 | "PO-Revision-Date: 2017-11-10 22:10+0000\n" 13 | "Last-Translator: scootergrisen\n" 14 | "Language-Team: Danish (http://www.transifex.com/fcitx/fcitx/language/da/)\n" 15 | "Language: da\n" 16 | "MIME-Version: 1.0\n" 17 | "Content-Type: text/plain; charset=UTF-8\n" 18 | "Content-Transfer-Encoding: 8bit\n" 19 | "Plural-Forms: nplurals=2; plural=(n != 1);\n" 20 | 21 | #: src/fcitx-hangul.desc:14 22 | msgid "Ahnmatae" 23 | msgstr "Ahnmatae" 24 | 25 | #: src/fcitx-hangul.desc:25 26 | msgid "Auto Reorder" 27 | msgstr "Automatisk genplacering" 28 | 29 | #: src/fcitx-hangul.desc:6 30 | msgid "Dubeolsik" 31 | msgstr "Dubeolsik" 32 | 33 | #: src/fcitx-hangul.desc:7 34 | msgid "Dubeolsik Yetgeul" 35 | msgstr "Dubeolsik Yetgeul" 36 | 37 | #: src/eim.c:764 src/fcitx-hangul.conf.in:3 src/hangul.conf.in:3 38 | #: src/fcitx-hangul.desc:1 src/fcitx-hangul.desc:17 src/fcitx-hangul.desc:22 39 | #: src/fcitx-hangul.desc:27 src/fcitx-hangul.desc:32 40 | msgid "Hangul" 41 | msgstr "Hangul" 42 | 43 | #: src/fcitx-hangul.conf.in:4 44 | msgid "Hangul Wrapper For Fcitx" 45 | msgstr "Hangul-wrapper til Fcitx" 46 | 47 | #: src/fcitx-hangul.desc:35 48 | msgid "Hanja Mode" 49 | msgstr "Hanja-tilstand" 50 | 51 | #: src/fcitx-hangul.desc:20 52 | msgid "Hanja Mode Toggle Key" 53 | msgstr "Tast til at skifte Hanja-tilstand" 54 | 55 | #: src/fcitx-hangul.desc:4 56 | msgid "Keyboard Layout" 57 | msgstr "Tastaturlayout" 58 | 59 | #: src/fcitx-hangul.desc:13 60 | msgid "Romaja" 61 | msgstr "Romaja" 62 | 63 | #: src/fcitx-hangul.desc:8 64 | msgid "Sebeolsik 390" 65 | msgstr "Sebeolsik 390" 66 | 67 | #: src/fcitx-hangul.desc:12 68 | msgid "Sebeolsik Dubeol Layout" 69 | msgstr "Sebeolsik Dubeol-layout" 70 | 71 | #: src/fcitx-hangul.desc:9 72 | msgid "Sebeolsik Final" 73 | msgstr "Sebeolsik Final" 74 | 75 | #: src/fcitx-hangul.desc:10 76 | msgid "Sebeolsik Noshift" 77 | msgstr "Sebeolsik Noshift" 78 | 79 | #: src/fcitx-hangul.desc:11 80 | msgid "Sebeolsik Yetgeul" 81 | msgstr "Sebeolsik Yetgeul" 82 | 83 | #: src/eim.c:818 84 | msgid "Use Hangul" 85 | msgstr "Brug Hangul" 86 | 87 | #: src/eim.c:815 88 | msgid "Use Hanja" 89 | msgstr "Brug Hanja" 90 | 91 | #: src/fcitx-hangul.desc:30 92 | msgid "Word Commit" 93 | msgstr "Ordudfør" 94 | -------------------------------------------------------------------------------- /po/ja.po: -------------------------------------------------------------------------------- 1 | # SOME DESCRIPTIVE TITLE. 2 | # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER 3 | # This file is distributed under the same license as the PACKAGE package. 4 | # 5 | # Translators: 6 | # WAKAYAMA Shirou , 2013 7 | # csslayer , 2013 8 | msgid "" 9 | msgstr "" 10 | "Project-Id-Version: fcitx\n" 11 | "Report-Msgid-Bugs-To: fcitx-dev@googlegroups.com\n" 12 | "POT-Creation-Date: 2015-08-03 18:01+0200\n" 13 | "PO-Revision-Date: 2013-06-27 00:23+0000\n" 14 | "Last-Translator: csslayer \n" 15 | "Language-Team: Japanese (http://www.transifex.com/fcitx/fcitx/language/ja/)\n" 16 | "Language: ja\n" 17 | "MIME-Version: 1.0\n" 18 | "Content-Type: text/plain; charset=UTF-8\n" 19 | "Content-Transfer-Encoding: 8bit\n" 20 | "Plural-Forms: nplurals=1; plural=0;\n" 21 | 22 | #: src/fcitx-hangul.desc:14 23 | msgid "Ahnmatae" 24 | msgstr "Ahnmatae" 25 | 26 | #: src/fcitx-hangul.desc:25 27 | msgid "Auto Reorder" 28 | msgstr "自動並び替え" 29 | 30 | #: src/fcitx-hangul.desc:6 31 | msgid "Dubeolsik" 32 | msgstr "Dubeolsik" 33 | 34 | #: src/fcitx-hangul.desc:7 35 | msgid "Dubeolsik Yetgeul" 36 | msgstr "Dubeolsik Yetgeul" 37 | 38 | #: src/eim.c:764 src/fcitx-hangul.conf.in:3 src/hangul.conf.in:3 39 | #: src/fcitx-hangul.desc:1 src/fcitx-hangul.desc:17 src/fcitx-hangul.desc:22 40 | #: src/fcitx-hangul.desc:27 src/fcitx-hangul.desc:32 41 | msgid "Hangul" 42 | msgstr "ハングル" 43 | 44 | #: src/fcitx-hangul.conf.in:4 45 | msgid "Hangul Wrapper For Fcitx" 46 | msgstr "Fcitx 用 ハングルラッパー" 47 | 48 | #: src/fcitx-hangul.desc:35 49 | msgid "Hanja Mode" 50 | msgstr "朝鮮漢字モード" 51 | 52 | #: src/fcitx-hangul.desc:20 53 | msgid "Hanja Mode Toggle Key" 54 | msgstr "朝鮮漢字モードのトリガーとなるキー" 55 | 56 | #: src/fcitx-hangul.desc:4 57 | msgid "Keyboard Layout" 58 | msgstr "キーボードレイアウト" 59 | 60 | #: src/fcitx-hangul.desc:13 61 | msgid "Romaja" 62 | msgstr "Romaja" 63 | 64 | #: src/fcitx-hangul.desc:8 65 | msgid "Sebeolsik 390" 66 | msgstr "Sebeolsik 390" 67 | 68 | #: src/fcitx-hangul.desc:12 69 | msgid "Sebeolsik Dubeol Layout" 70 | msgstr "Sebeolsik Dubeol レイアウト" 71 | 72 | #: src/fcitx-hangul.desc:9 73 | msgid "Sebeolsik Final" 74 | msgstr "Sebeolsik Final" 75 | 76 | #: src/fcitx-hangul.desc:10 77 | msgid "Sebeolsik Noshift" 78 | msgstr "Sebeolsik Noshift" 79 | 80 | #: src/fcitx-hangul.desc:11 81 | msgid "Sebeolsik Yetgeul" 82 | msgstr "Sebeolsik Yetgeul" 83 | 84 | #: src/eim.c:818 85 | msgid "Use Hangul" 86 | msgstr "ハングルを使う" 87 | 88 | #: src/eim.c:815 89 | msgid "Use Hanja" 90 | msgstr "朝鮮漢字を使う" 91 | 92 | #: src/fcitx-hangul.desc:30 93 | msgid "Word Commit" 94 | msgstr "単語確定" 95 | -------------------------------------------------------------------------------- /po/zh_TW.po: -------------------------------------------------------------------------------- 1 | # SOME DESCRIPTIVE TITLE. 2 | # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER 3 | # This file is distributed under the same license as the PACKAGE package. 4 | # 5 | # Translators: 6 | # Alisha , 2012 7 | # Jeff Huang , 2015 8 | # csslayer , 2013 9 | msgid "" 10 | msgstr "" 11 | "Project-Id-Version: fcitx\n" 12 | "Report-Msgid-Bugs-To: fcitx-dev@googlegroups.com\n" 13 | "POT-Creation-Date: 2017-06-13 12:02-0700\n" 14 | "PO-Revision-Date: 2015-09-28 14:32+0000\n" 15 | "Last-Translator: Jeff Huang \n" 16 | "Language-Team: Chinese (Taiwan) (http://www.transifex.com/fcitx/fcitx/" 17 | "language/zh_TW/)\n" 18 | "Language: zh_TW\n" 19 | "MIME-Version: 1.0\n" 20 | "Content-Type: text/plain; charset=UTF-8\n" 21 | "Content-Transfer-Encoding: 8bit\n" 22 | "Plural-Forms: nplurals=1; plural=0;\n" 23 | 24 | #: src/fcitx-hangul.desc:14 25 | msgid "Ahnmatae" 26 | msgstr "安馬太鍵盤" 27 | 28 | #: src/fcitx-hangul.desc:25 29 | msgid "Auto Reorder" 30 | msgstr "自動排序" 31 | 32 | #: src/fcitx-hangul.desc:6 33 | msgid "Dubeolsik" 34 | msgstr "Dubeolsik" 35 | 36 | #: src/fcitx-hangul.desc:7 37 | msgid "Dubeolsik Yetgeul" 38 | msgstr "Dubeolsik Yetgeul" 39 | 40 | #: src/eim.c:764 src/fcitx-hangul.conf.in:3 src/hangul.conf.in:3 41 | #: src/fcitx-hangul.desc:1 src/fcitx-hangul.desc:17 src/fcitx-hangul.desc:22 42 | #: src/fcitx-hangul.desc:27 src/fcitx-hangul.desc:32 43 | msgid "Hangul" 44 | msgstr "韓文" 45 | 46 | #: src/fcitx-hangul.conf.in:4 47 | msgid "Hangul Wrapper For Fcitx" 48 | msgstr "Fcitx 的韓文封裝" 49 | 50 | #: src/fcitx-hangul.desc:35 51 | msgid "Hanja Mode" 52 | msgstr "漢字模式" 53 | 54 | #: src/fcitx-hangul.desc:20 55 | msgid "Hanja Mode Toggle Key" 56 | msgstr "漢字模式切換鍵" 57 | 58 | #: src/fcitx-hangul.desc:4 59 | msgid "Keyboard Layout" 60 | msgstr "鍵盤配置" 61 | 62 | #: src/fcitx-hangul.desc:13 63 | msgid "Romaja" 64 | msgstr "羅馬字" 65 | 66 | #: src/fcitx-hangul.desc:8 67 | msgid "Sebeolsik 390" 68 | msgstr "Sebeolsik 390" 69 | 70 | #: src/fcitx-hangul.desc:12 71 | msgid "Sebeolsik Dubeol Layout" 72 | msgstr "Sebeolsik Dubeol Layout" 73 | 74 | #: src/fcitx-hangul.desc:9 75 | msgid "Sebeolsik Final" 76 | msgstr "Sebeolsik Final" 77 | 78 | #: src/fcitx-hangul.desc:10 79 | msgid "Sebeolsik Noshift" 80 | msgstr "Sebeolsik Noshift" 81 | 82 | #: src/fcitx-hangul.desc:11 83 | msgid "Sebeolsik Yetgeul" 84 | msgstr "Sebeolsik Yetgeul" 85 | 86 | #: src/eim.c:818 87 | msgid "Use Hangul" 88 | msgstr "使用韓文" 89 | 90 | #: src/eim.c:815 91 | msgid "Use Hanja" 92 | msgstr "使用漢字" 93 | 94 | #: src/fcitx-hangul.desc:30 95 | msgid "Word Commit" 96 | msgstr "單字提交" 97 | -------------------------------------------------------------------------------- /po/tr.po: -------------------------------------------------------------------------------- 1 | # SOME DESCRIPTIVE TITLE. 2 | # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER 3 | # This file is distributed under the same license as the PACKAGE package. 4 | # 5 | # Translators: 6 | # Gökhan Kalayci , 2017 7 | msgid "" 8 | msgstr "" 9 | "Project-Id-Version: fcitx\n" 10 | "Report-Msgid-Bugs-To: fcitx-dev@googlegroups.com\n" 11 | "POT-Creation-Date: 2013-06-26 20:12-0400\n" 12 | "PO-Revision-Date: 2017-04-20 20:35+0000\n" 13 | "Last-Translator: Gökhan Kalayci \n" 14 | "Language-Team: Turkish (http://www.transifex.com/fcitx/fcitx/language/tr/)\n" 15 | "MIME-Version: 1.0\n" 16 | "Content-Type: text/plain; charset=UTF-8\n" 17 | "Content-Transfer-Encoding: 8bit\n" 18 | "Language: tr\n" 19 | "Plural-Forms: nplurals=2; plural=(n > 1);\n" 20 | 21 | #: src/eim.c:763 src/fcitx-hangul.conf.in:3 src/hangul.conf.in:3 22 | #: src/fcitx-hangul.desc:1 src/fcitx-hangul.desc:17 src/fcitx-hangul.desc:22 23 | #: src/fcitx-hangul.desc:27 src/fcitx-hangul.desc:32 24 | msgid "Hangul" 25 | msgstr "Hangul" 26 | 27 | #: src/eim.c:814 28 | msgid "Use Hanja" 29 | msgstr "Hanja Kullan" 30 | 31 | #: src/eim.c:817 32 | msgid "Use Hangul" 33 | msgstr "Hangul Kullan" 34 | 35 | #: src/fcitx-hangul.conf.in:4 36 | msgid "Hangul Wrapper For Fcitx" 37 | msgstr "Fcitx için Hangul Wrapper" 38 | 39 | #: src/fcitx-hangul.desc:4 40 | msgid "Keyboard Layout" 41 | msgstr "Klavye Düzeni " 42 | 43 | #: src/fcitx-hangul.desc:6 44 | msgid "Dubeolsik" 45 | msgstr "Dubeolsik" 46 | 47 | #: src/fcitx-hangul.desc:7 48 | msgid "Dubeolsik Yetgeul" 49 | msgstr "Dubeolsik Yetgeul" 50 | 51 | #: src/fcitx-hangul.desc:8 52 | msgid "Sebeolsik 390" 53 | msgstr "Sebeolsik 390" 54 | 55 | #: src/fcitx-hangul.desc:9 56 | msgid "Sebeolsik Final" 57 | msgstr "Sebeolsik Final" 58 | 59 | #: src/fcitx-hangul.desc:10 60 | msgid "Sebeolsik Noshift" 61 | msgstr "Sebeolsik Noshift" 62 | 63 | #: src/fcitx-hangul.desc:11 64 | msgid "Sebeolsik Yetgeul" 65 | msgstr "Sebeolsik Yetgeul" 66 | 67 | #: src/fcitx-hangul.desc:12 68 | msgid "Sebeolsik Dubeol Layout" 69 | msgstr "Sebeolsik Dubeol Layout" 70 | 71 | #: src/fcitx-hangul.desc:13 72 | msgid "Romaja" 73 | msgstr "Romaja" 74 | 75 | #: src/fcitx-hangul.desc:14 76 | msgid "Ahnmatae" 77 | msgstr "Ahnmatae" 78 | 79 | #: src/fcitx-hangul.desc:20 80 | msgid "Hanja Mode Toggle Key" 81 | msgstr "Haja Modu Anahtar Değişimi" 82 | 83 | #: src/fcitx-hangul.desc:25 84 | msgid "Auto Reorder" 85 | msgstr "Otomatik Tekrar Sıralama" 86 | 87 | #: src/fcitx-hangul.desc:30 88 | msgid "Word Commit" 89 | msgstr "Kelime İşleme" 90 | 91 | #: src/fcitx-hangul.desc:35 92 | msgid "Hanja Mode" 93 | msgstr "Hanja Modu" 94 | -------------------------------------------------------------------------------- /po/de.po: -------------------------------------------------------------------------------- 1 | # SOME DESCRIPTIVE TITLE. 2 | # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER 3 | # This file is distributed under the same license as the PACKAGE package. 4 | # 5 | # Translators: 6 | # mar well , 2013 7 | # csslayer , 2013 8 | msgid "" 9 | msgstr "" 10 | "Project-Id-Version: fcitx\n" 11 | "Report-Msgid-Bugs-To: fcitx-dev@googlegroups.com\n" 12 | "POT-Creation-Date: 2015-08-03 18:01+0200\n" 13 | "PO-Revision-Date: 2013-09-16 03:04+0000\n" 14 | "Last-Translator: mar well \n" 15 | "Language-Team: German (http://www.transifex.com/fcitx/fcitx/language/de/)\n" 16 | "Language: de\n" 17 | "MIME-Version: 1.0\n" 18 | "Content-Type: text/plain; charset=UTF-8\n" 19 | "Content-Transfer-Encoding: 8bit\n" 20 | "Plural-Forms: nplurals=2; plural=(n != 1);\n" 21 | 22 | #: src/fcitx-hangul.desc:14 23 | msgid "Ahnmatae" 24 | msgstr "Ahnmatae" 25 | 26 | #: src/fcitx-hangul.desc:25 27 | msgid "Auto Reorder" 28 | msgstr "Automatisch neu sortieren" 29 | 30 | #: src/fcitx-hangul.desc:6 31 | msgid "Dubeolsik" 32 | msgstr "Dubeolsik" 33 | 34 | #: src/fcitx-hangul.desc:7 35 | msgid "Dubeolsik Yetgeul" 36 | msgstr "Dubeolsik Yetgeul" 37 | 38 | #: src/eim.c:764 src/fcitx-hangul.conf.in:3 src/hangul.conf.in:3 39 | #: src/fcitx-hangul.desc:1 src/fcitx-hangul.desc:17 src/fcitx-hangul.desc:22 40 | #: src/fcitx-hangul.desc:27 src/fcitx-hangul.desc:32 41 | msgid "Hangul" 42 | msgstr "Hangul" 43 | 44 | #: src/fcitx-hangul.conf.in:4 45 | msgid "Hangul Wrapper For Fcitx" 46 | msgstr "Hangul Wrapper für Fcitx" 47 | 48 | #: src/fcitx-hangul.desc:35 49 | msgid "Hanja Mode" 50 | msgstr "Hanja Modus" 51 | 52 | #: src/fcitx-hangul.desc:20 53 | msgid "Hanja Mode Toggle Key" 54 | msgstr "Hanja Modus Umschalttaste" 55 | 56 | #: src/fcitx-hangul.desc:4 57 | msgid "Keyboard Layout" 58 | msgstr "Tastaturlayout" 59 | 60 | #: src/fcitx-hangul.desc:13 61 | msgid "Romaja" 62 | msgstr "Romaja" 63 | 64 | #: src/fcitx-hangul.desc:8 65 | msgid "Sebeolsik 390" 66 | msgstr "Sebeolsik 390" 67 | 68 | #: src/fcitx-hangul.desc:12 69 | msgid "Sebeolsik Dubeol Layout" 70 | msgstr "Sebeolsik Dubeol Layout" 71 | 72 | #: src/fcitx-hangul.desc:9 73 | msgid "Sebeolsik Final" 74 | msgstr "Sebeolsik Final" 75 | 76 | #: src/fcitx-hangul.desc:10 77 | msgid "Sebeolsik Noshift" 78 | msgstr "Sebeolsik Noshift" 79 | 80 | #: src/fcitx-hangul.desc:11 81 | msgid "Sebeolsik Yetgeul" 82 | msgstr "Sebeolsik Yetgeul" 83 | 84 | #: src/eim.c:818 85 | msgid "Use Hangul" 86 | msgstr "Hangul benutzen" 87 | 88 | #: src/eim.c:815 89 | msgid "Use Hanja" 90 | msgstr "Hanja benutzen" 91 | 92 | #: src/fcitx-hangul.desc:30 93 | msgid "Word Commit" 94 | msgstr "Wort übergeben" 95 | -------------------------------------------------------------------------------- /po/zh_CN.po: -------------------------------------------------------------------------------- 1 | # SOME DESCRIPTIVE TITLE. 2 | # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER 3 | # This file is distributed under the same license as the PACKAGE package. 4 | # 5 | # Translators: 6 | # Christopher Meng , 2012 7 | # marguerite su , 2012 8 | # csslayer , 2013 9 | # csslayer , 2012 10 | # csslayer , 2010-2012 11 | msgid "" 12 | msgstr "" 13 | "Project-Id-Version: fcitx\n" 14 | "Report-Msgid-Bugs-To: fcitx-dev@googlegroups.com\n" 15 | "POT-Creation-Date: 2017-06-13 12:02-0700\n" 16 | "PO-Revision-Date: 2013-06-27 00:22+0000\n" 17 | "Last-Translator: csslayer \n" 18 | "Language-Team: Chinese (China) (http://www.transifex.com/fcitx/fcitx/" 19 | "language/zh_CN/)\n" 20 | "Language: zh_CN\n" 21 | "MIME-Version: 1.0\n" 22 | "Content-Type: text/plain; charset=UTF-8\n" 23 | "Content-Transfer-Encoding: 8bit\n" 24 | "Plural-Forms: nplurals=1; plural=0;\n" 25 | 26 | #: src/fcitx-hangul.desc:14 27 | msgid "Ahnmatae" 28 | msgstr "安马太键盘" 29 | 30 | #: src/fcitx-hangul.desc:25 31 | msgid "Auto Reorder" 32 | msgstr "自动排序" 33 | 34 | #: src/fcitx-hangul.desc:6 35 | msgid "Dubeolsik" 36 | msgstr "Dubeolsik" 37 | 38 | #: src/fcitx-hangul.desc:7 39 | msgid "Dubeolsik Yetgeul" 40 | msgstr "Dubeolsik Yetgeul" 41 | 42 | #: src/eim.c:764 src/fcitx-hangul.conf.in:3 src/hangul.conf.in:3 43 | #: src/fcitx-hangul.desc:1 src/fcitx-hangul.desc:17 src/fcitx-hangul.desc:22 44 | #: src/fcitx-hangul.desc:27 src/fcitx-hangul.desc:32 45 | msgid "Hangul" 46 | msgstr "韩文" 47 | 48 | #: src/fcitx-hangul.conf.in:4 49 | msgid "Hangul Wrapper For Fcitx" 50 | msgstr "Fcitx 的韩文封装" 51 | 52 | #: src/fcitx-hangul.desc:35 53 | msgid "Hanja Mode" 54 | msgstr "汉字模式" 55 | 56 | #: src/fcitx-hangul.desc:20 57 | msgid "Hanja Mode Toggle Key" 58 | msgstr "汉字模式切换键" 59 | 60 | #: src/fcitx-hangul.desc:4 61 | msgid "Keyboard Layout" 62 | msgstr "键盘布局" 63 | 64 | #: src/fcitx-hangul.desc:13 65 | msgid "Romaja" 66 | msgstr "Romaja" 67 | 68 | #: src/fcitx-hangul.desc:8 69 | msgid "Sebeolsik 390" 70 | msgstr "Sebeolsik 390" 71 | 72 | #: src/fcitx-hangul.desc:12 73 | msgid "Sebeolsik Dubeol Layout" 74 | msgstr "Sebeolsik Dubeol 布局" 75 | 76 | #: src/fcitx-hangul.desc:9 77 | msgid "Sebeolsik Final" 78 | msgstr "Sebeolsik Final" 79 | 80 | #: src/fcitx-hangul.desc:10 81 | msgid "Sebeolsik Noshift" 82 | msgstr "Sebeolsik Noshift" 83 | 84 | #: src/fcitx-hangul.desc:11 85 | msgid "Sebeolsik Yetgeul" 86 | msgstr "三套式古文" 87 | 88 | #: src/eim.c:818 89 | msgid "Use Hangul" 90 | msgstr "使用韩文" 91 | 92 | #: src/eim.c:815 93 | msgid "Use Hanja" 94 | msgstr "使用汉字" 95 | 96 | #: src/fcitx-hangul.desc:30 97 | msgid "Word Commit" 98 | msgstr "单词提交" 99 | -------------------------------------------------------------------------------- /po/ca.po: -------------------------------------------------------------------------------- 1 | # SOME DESCRIPTIVE TITLE. 2 | # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER 3 | # This file is distributed under the same license as the PACKAGE package. 4 | # 5 | # Translators: 6 | # Robert Antoni Buj Gelonch , 2017 7 | # Walter Garcia-Fontes , 2016 8 | msgid "" 9 | msgstr "" 10 | "Project-Id-Version: fcitx\n" 11 | "Report-Msgid-Bugs-To: fcitx-dev@googlegroups.com\n" 12 | "POT-Creation-Date: 2017-12-09 00:03-0800\n" 13 | "PO-Revision-Date: 2017-12-08 19:28+0000\n" 14 | "Last-Translator: Robert Antoni Buj Gelonch \n" 15 | "Language-Team: Catalan (http://www.transifex.com/fcitx/fcitx/language/ca/)\n" 16 | "Language: ca\n" 17 | "MIME-Version: 1.0\n" 18 | "Content-Type: text/plain; charset=UTF-8\n" 19 | "Content-Transfer-Encoding: 8bit\n" 20 | "Plural-Forms: nplurals=2; plural=(n != 1);\n" 21 | 22 | #: src/fcitx-hangul.desc:14 23 | msgid "Ahnmatae" 24 | msgstr "Ahnmatae" 25 | 26 | #: src/fcitx-hangul.desc:25 27 | msgid "Auto Reorder" 28 | msgstr "Reordenament automàtic" 29 | 30 | #: src/fcitx-hangul.desc:6 31 | msgid "Dubeolsik" 32 | msgstr "Dubeolsik" 33 | 34 | #: src/fcitx-hangul.desc:7 35 | msgid "Dubeolsik Yetgeul" 36 | msgstr "Dubeolsik yetgeul" 37 | 38 | #: src/eim.c:764 src/fcitx-hangul.conf.in:3 src/hangul.conf.in:3 39 | #: src/fcitx-hangul.desc:1 src/fcitx-hangul.desc:17 src/fcitx-hangul.desc:22 40 | #: src/fcitx-hangul.desc:27 src/fcitx-hangul.desc:32 41 | msgid "Hangul" 42 | msgstr "Hangul" 43 | 44 | #: src/fcitx-hangul.conf.in:4 45 | msgid "Hangul Wrapper For Fcitx" 46 | msgstr "Contenidor hangul per a fcitx" 47 | 48 | #: src/fcitx-hangul.desc:35 49 | msgid "Hanja Mode" 50 | msgstr "Mode hanja" 51 | 52 | #: src/fcitx-hangul.desc:20 53 | msgid "Hanja Mode Toggle Key" 54 | msgstr "Tecla de commutació de mode hanja" 55 | 56 | #: src/fcitx-hangul.desc:4 57 | msgid "Keyboard Layout" 58 | msgstr "Disposició de teclat" 59 | 60 | #: src/fcitx-hangul.desc:13 61 | msgid "Romaja" 62 | msgstr "Romaja" 63 | 64 | #: src/fcitx-hangul.desc:8 65 | msgid "Sebeolsik 390" 66 | msgstr "Sebeolsik 390" 67 | 68 | #: src/fcitx-hangul.desc:12 69 | msgid "Sebeolsik Dubeol Layout" 70 | msgstr "Disposició sebeolsik dubeol" 71 | 72 | #: src/fcitx-hangul.desc:9 73 | msgid "Sebeolsik Final" 74 | msgstr "Sebeolsik final" 75 | 76 | #: src/fcitx-hangul.desc:10 77 | msgid "Sebeolsik Noshift" 78 | msgstr "Sebeolsik sense desplaçament" 79 | 80 | #: src/fcitx-hangul.desc:11 81 | msgid "Sebeolsik Yetgeul" 82 | msgstr "Sebeolsik yetgeul" 83 | 84 | #: src/eim.c:818 85 | msgid "Use Hangul" 86 | msgstr "Utilitza hangul" 87 | 88 | #: src/eim.c:815 89 | msgid "Use Hanja" 90 | msgstr "Utilitza hanja" 91 | 92 | #: src/fcitx-hangul.desc:30 93 | msgid "Word Commit" 94 | msgstr "Enviament de paraula" 95 | -------------------------------------------------------------------------------- /po/ru.po: -------------------------------------------------------------------------------- 1 | # SOME DESCRIPTIVE TITLE. 2 | # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER 3 | # This file is distributed under the same license as the PACKAGE package. 4 | # 5 | # Translators: 6 | # Dmitry , 2023 7 | # TotalCaesar659 , 2016 8 | # TotalCaesar659 , 2016 9 | msgid "" 10 | msgstr "" 11 | "Project-Id-Version: fcitx\n" 12 | "Report-Msgid-Bugs-To: fcitx-dev@googlegroups.com\n" 13 | "POT-Creation-Date: 2023-07-25 20:26+0000\n" 14 | "PO-Revision-Date: 2012-03-17 06:22+0000\n" 15 | "Last-Translator: Dmitry , 2023\n" 16 | "Language-Team: Russian (http://app.transifex.com/fcitx/fcitx/language/ru/)\n" 17 | "Language: ru\n" 18 | "MIME-Version: 1.0\n" 19 | "Content-Type: text/plain; charset=UTF-8\n" 20 | "Content-Transfer-Encoding: 8bit\n" 21 | "Plural-Forms: nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && " 22 | "n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || " 23 | "(n%100>=11 && n%100<=14)? 2 : 3);\n" 24 | 25 | #: src/fcitx-hangul.desc:14 26 | msgid "Ahnmatae" 27 | msgstr "Ahnmatae" 28 | 29 | #: src/fcitx-hangul.desc:25 30 | msgid "Auto Reorder" 31 | msgstr "Автоматическая пересортировка" 32 | 33 | #: src/fcitx-hangul.desc:6 34 | msgid "Dubeolsik" 35 | msgstr "Dubeolsik" 36 | 37 | #: src/fcitx-hangul.desc:7 38 | msgid "Dubeolsik Yetgeul" 39 | msgstr "Dubeolsik Yetgeul" 40 | 41 | #: src/eim.c:764 src/fcitx-hangul.conf.in:3 src/hangul.conf.in:3 42 | #: src/fcitx-hangul.desc:1 src/fcitx-hangul.desc:17 src/fcitx-hangul.desc:22 43 | #: src/fcitx-hangul.desc:27 src/fcitx-hangul.desc:32 44 | msgid "Hangul" 45 | msgstr "Хангыль" 46 | 47 | #: src/fcitx-hangul.conf.in:4 48 | msgid "Hangul Wrapper For Fcitx" 49 | msgstr "Обёртка Хангыль для Fcitx" 50 | 51 | #: src/fcitx-hangul.desc:35 52 | msgid "Hanja Mode" 53 | msgstr "Режим Ханча" 54 | 55 | #: src/fcitx-hangul.desc:20 56 | msgid "Hanja Mode Toggle Key" 57 | msgstr "Клавиша переключения режима Ханча" 58 | 59 | #: src/fcitx-hangul.desc:4 60 | msgid "Keyboard Layout" 61 | msgstr "Раскладка клавиатуры" 62 | 63 | #: src/fcitx-hangul.desc:13 64 | msgid "Romaja" 65 | msgstr "Romaja" 66 | 67 | #: src/fcitx-hangul.desc:8 68 | msgid "Sebeolsik 390" 69 | msgstr "Sebeolsik 390" 70 | 71 | #: src/fcitx-hangul.desc:12 72 | msgid "Sebeolsik Dubeol Layout" 73 | msgstr "Раскладка Sebeolsik Dubeol" 74 | 75 | #: src/fcitx-hangul.desc:9 76 | msgid "Sebeolsik Final" 77 | msgstr "Sebeolsik Final" 78 | 79 | #: src/fcitx-hangul.desc:10 80 | msgid "Sebeolsik Noshift" 81 | msgstr "Sebeolsik Noshift" 82 | 83 | #: src/fcitx-hangul.desc:11 84 | msgid "Sebeolsik Yetgeul" 85 | msgstr "Sebeolsik Yetgeul" 86 | 87 | #: src/eim.c:818 88 | msgid "Use Hangul" 89 | msgstr "Использовать Хангыль" 90 | 91 | #: src/eim.c:815 92 | msgid "Use Hanja" 93 | msgstr "Использовать Ханча" 94 | 95 | #: src/fcitx-hangul.desc:30 96 | msgid "Word Commit" 97 | msgstr "Добавить слово" 98 | -------------------------------------------------------------------------------- /po/ko.po: -------------------------------------------------------------------------------- 1 | # SOME DESCRIPTIVE TITLE. 2 | # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER 3 | # This file is distributed under the same license as the PACKAGE package. 4 | # 5 | # Translators: 6 | # Bon Keun Seo , 2017 7 | # Junghee Lee , 2021 8 | # csslayer , 2012-2013 9 | # Junghee Lee , 2020 10 | # Junghee Lee , 2022 11 | # Junghee Lee , 2020 12 | # perillamint , 2021 13 | # csslayer , 2013 14 | # csslayer , 2012 15 | # csslayer , 2012 16 | msgid "" 17 | msgstr "" 18 | "Project-Id-Version: fcitx\n" 19 | "Report-Msgid-Bugs-To: fcitx-dev@googlegroups.com\n" 20 | "POT-Creation-Date: 2022-04-10 20:28+0000\n" 21 | "PO-Revision-Date: 2012-03-17 06:22+0000\n" 22 | "Last-Translator: Junghee Lee , 2022\n" 23 | "Language-Team: Korean (http://www.transifex.com/fcitx/fcitx/language/ko/)\n" 24 | "Language: ko\n" 25 | "MIME-Version: 1.0\n" 26 | "Content-Type: text/plain; charset=UTF-8\n" 27 | "Content-Transfer-Encoding: 8bit\n" 28 | "Plural-Forms: nplurals=1; plural=0;\n" 29 | 30 | #: src/fcitx-hangul.desc:14 31 | msgid "Ahnmatae" 32 | msgstr "안마태" 33 | 34 | #: src/fcitx-hangul.desc:25 35 | msgid "Auto Reorder" 36 | msgstr "자동 재배열" 37 | 38 | #: src/fcitx-hangul.desc:6 39 | msgid "Dubeolsik" 40 | msgstr "두벌식" 41 | 42 | #: src/fcitx-hangul.desc:7 43 | msgid "Dubeolsik Yetgeul" 44 | msgstr "두벌식 옛글" 45 | 46 | #: src/eim.c:764 src/fcitx-hangul.conf.in:3 src/hangul.conf.in:3 47 | #: src/fcitx-hangul.desc:1 src/fcitx-hangul.desc:17 src/fcitx-hangul.desc:22 48 | #: src/fcitx-hangul.desc:27 src/fcitx-hangul.desc:32 49 | msgid "Hangul" 50 | msgstr "한글" 51 | 52 | #: src/fcitx-hangul.conf.in:4 53 | msgid "Hangul Wrapper For Fcitx" 54 | msgstr "Fcitx용 한글 래퍼" 55 | 56 | #: src/fcitx-hangul.desc:35 57 | msgid "Hanja Mode" 58 | msgstr "한자 모드" 59 | 60 | #: src/fcitx-hangul.desc:20 61 | msgid "Hanja Mode Toggle Key" 62 | msgstr "한자 모드 변환 키" 63 | 64 | #: src/fcitx-hangul.desc:4 65 | msgid "Keyboard Layout" 66 | msgstr "키보드 자판" 67 | 68 | #: src/fcitx-hangul.desc:13 69 | msgid "Romaja" 70 | msgstr "로마자" 71 | 72 | #: src/fcitx-hangul.desc:8 73 | msgid "Sebeolsik 390" 74 | msgstr "세벌식 390" 75 | 76 | #: src/fcitx-hangul.desc:12 77 | msgid "Sebeolsik Dubeol Layout" 78 | msgstr "세벌식 두벌 자판" 79 | 80 | #: src/fcitx-hangul.desc:9 81 | msgid "Sebeolsik Final" 82 | msgstr "세벌식 최종" 83 | 84 | #: src/fcitx-hangul.desc:10 85 | msgid "Sebeolsik Noshift" 86 | msgstr "세벌식 순아래" 87 | 88 | #: src/fcitx-hangul.desc:11 89 | msgid "Sebeolsik Yetgeul" 90 | msgstr "세벌식 옛글" 91 | 92 | #: src/eim.c:818 93 | msgid "Use Hangul" 94 | msgstr "한글 사용" 95 | 96 | #: src/eim.c:815 97 | msgid "Use Hanja" 98 | msgstr "한자 사용" 99 | 100 | #: src/fcitx-hangul.desc:30 101 | msgid "Word Commit" 102 | msgstr "단어 단위 입력" 103 | -------------------------------------------------------------------------------- /src/eim.h: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (C) 2010~2010 by CSSlayer * 3 | * wengxt@gmail.com * 4 | * * 5 | * This program is free software; you can redistribute it and/or modify * 6 | * it under the terms of the GNU General Public License as published by * 7 | * the Free Software Foundation; either version 2 of the License, or * 8 | * (at your option) any later version. * 9 | * * 10 | * This program is distributed in the hope that it will be useful, * 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of * 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * 13 | * GNU General Public License for more details. * 14 | * * 15 | * You should have received a copy of the GNU General Public License * 16 | * along with this program; if not, write to the * 17 | * Free Software Foundation, Inc., * 18 | * 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. * 19 | ***************************************************************************/ 20 | 21 | #ifndef EIM_H 22 | #define EIM_H 23 | 24 | #include 25 | #include 26 | #include 27 | #include 28 | #include 29 | #include 30 | #include "ustring.h" 31 | #include "keyboard.h" 32 | 33 | #define _(x) dgettext("fcitx-hangul", x) 34 | 35 | typedef struct _FcitxHangulConfig 36 | { 37 | FcitxGenericConfig gconfig; 38 | FcitxHangulKeyboard keyboardLayout; 39 | boolean hanjaMode; 40 | boolean autoReorder; 41 | boolean wordCommit; 42 | FcitxHotkey hkHanjaMode[2]; 43 | } FcitxHangulConfig; 44 | 45 | CONFIG_BINDING_DECLARE(FcitxHangulConfig); 46 | void* FcitxHangulCreate(FcitxInstance* instance); 47 | void FcitxHangulDestroy(void* arg); 48 | INPUT_RETURN_VALUE FcitxHangulDoInput(void* arg, FcitxKeySym sym, unsigned int state); 49 | INPUT_RETURN_VALUE FcitxHangulGetCandWords (void *arg); 50 | INPUT_RETURN_VALUE FcitxHangulGetCandWord (void *arg, FcitxCandidateWord* candWord); 51 | void FcitxHangulOnClose(void* arg, FcitxIMCloseEventType event); 52 | boolean FcitxHangulInit(void*); 53 | void ReloadConfigFcitxHangul(void*); 54 | 55 | typedef enum _LookupMethod 56 | { 57 | LOOKUP_METHOD_PREFIX, 58 | LOOKUP_METHOD_EXACT, 59 | LOOKUP_METHOD_SUFFIX 60 | } LookupMethod; 61 | 62 | typedef struct _FcitxHangul 63 | { 64 | FcitxHangulConfig fh; 65 | FcitxInstance* owner; 66 | HanjaTable* table; 67 | HangulInputContext* ic; 68 | HanjaTable* symbolTable; 69 | UString* preedit; 70 | iconv_t conv; 71 | HanjaList* hanjaList; 72 | LookupMethod lastLookupMethod; 73 | } FcitxHangul; 74 | 75 | #endif 76 | -------------------------------------------------------------------------------- /src/ustring.c: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (C) 2012~2012 by CSSlayer * 3 | * wengxt@gmail.com * 4 | * * 5 | * This program is free software; you can redistribute it and/or modify * 6 | * it under the terms of the GNU General Public License as published by * 7 | * the Free Software Foundation; either version 2 of the License, or * 8 | * (at your option) any later version. * 9 | * * 10 | * This program is distributed in the hope that it will be useful, * 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of * 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * 13 | * GNU General Public License for more details. * 14 | * * 15 | * You should have received a copy of the GNU General Public License * 16 | * along with this program; if not, write to the * 17 | * Free Software Foundation, Inc., * 18 | * 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. * 19 | ***************************************************************************/ 20 | 21 | #include "ustring.h" 22 | #include 23 | #include 24 | 25 | static const UT_icd ucs_icd = { sizeof(ucschar), NULL, NULL, NULL}; 26 | 27 | UString* 28 | ustring_new() 29 | { 30 | UString* str; 31 | utarray_new(str, &ucs_icd); 32 | return str; 33 | } 34 | 35 | UString* 36 | ustring_dup(const UString* str) 37 | { 38 | UString* dup; 39 | dup = ustring_new(); 40 | ustring_append(dup, str); 41 | return dup; 42 | } 43 | 44 | void 45 | ustring_delete(UString* str) 46 | { 47 | utarray_free(str); 48 | } 49 | 50 | void 51 | ustring_clear(UString* str) 52 | { 53 | utarray_clear(str); 54 | } 55 | 56 | UString* 57 | ustring_erase(UString* str, size_t pos, size_t len) 58 | { 59 | if (len > 0) 60 | utarray_erase(str, pos, len); 61 | return str; 62 | } 63 | 64 | ucschar* 65 | ustring_begin(UString* str) 66 | { 67 | return (ucschar*) utarray_front(str); 68 | } 69 | 70 | ucschar* 71 | ustring_end(UString* str) 72 | { 73 | return (ucschar*) utarray_eltptr(str, utarray_len(str)); 74 | } 75 | 76 | unsigned 77 | ustring_length(const UString* str) 78 | { 79 | return utarray_len(str); 80 | } 81 | 82 | UString* 83 | ustring_append(UString* str, const UString* s) 84 | { 85 | utarray_concat(str, s); 86 | return str; 87 | } 88 | 89 | UString* 90 | ustring_append_ucs4(UString* str, const ucschar* s) 91 | { 92 | const ucschar*p = s; 93 | while (*p != 0) { 94 | utarray_push_back(str, p); 95 | p++; 96 | } 97 | 98 | return str; 99 | } 100 | 101 | UString* 102 | ustring_append_utf8(UString* str, const char* utf8) 103 | { 104 | while (*utf8 != '\0') { 105 | ucschar c; 106 | utf8 = fcitx_utf8_get_char(utf8, (uint32_t*) &c); 107 | utarray_push_back(str, &c); 108 | } 109 | return str; 110 | } 111 | -------------------------------------------------------------------------------- /data/symbol.txt: -------------------------------------------------------------------------------- 1 | # Copyright (c) 2005,2006 Choe Hwanjin 2 | # All rights reserved. 3 | # 4 | # Redistribution and use in source and binary forms, with or without 5 | # modification, are permitted provided that the following conditions are met: 6 | # 7 | # 1. Redistributions of source code must retain the above copyright notice, 8 | # this list of conditions and the following disclaimer. 9 | # 2. Redistributions in binary form must reproduce the above copyright notice, 10 | # this list of conditions and the following disclaimer in the documentation 11 | # and/or other materials provided with the distribution. 12 | # 3. Neither the name of the author nor the names of its contributors 13 | # may be used to endorse or promote products derived from this software 14 | # without specific prior written permission. 15 | # 16 | # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 17 | # AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 18 | # IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 19 | # ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE 20 | # LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 21 | # CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 22 | # SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 23 | # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 24 | # CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 25 | # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 26 | # POSSIBILITY OF SUCH DAMAGE. 27 | 28 | ㄱ: : 29 | ㄱ:!: 30 | ㄱ:': 31 | ㄱ:,: 32 | ㄱ:.: 33 | ㄱ:/: 34 | ㄱ::: 35 | ㄱ:;: 36 | ㄱ:?: 37 | ㄱ:^: 38 | ㄱ:_: 39 | ㄱ:`: 40 | ㄱ:|: 41 | ㄱ: ̄: 42 | ㄱ:、: 43 | ㄱ:。: 44 | ㄱ:·: 45 | ㄱ:‥: 46 | ㄱ:…: 47 | ㄱ:¨: 48 | ㄱ:〃: 49 | ㄱ:­: 50 | ㄱ:―: 51 | ㄱ:∥: 52 | ㄱ:\: 53 | ㄱ:∼: 54 | ㄱ:´: 55 | ㄱ:~: 56 | ㄱ:ˇ: 57 | ㄱ:˘: 58 | ㄱ:˝: 59 | ㄱ:˚: 60 | ㄱ:˙: 61 | ㄱ:¸: 62 | ㄱ:˛: 63 | ㄱ:¡: 64 | ㄱ:¿: 65 | ㄱ:ː: 66 | ㄲ:Æ: 67 | ㄲ:Ð: 68 | ㄲ:Ħ: 69 | ㄲ:IJ: 70 | ㄲ:Ŀ: 71 | ㄲ:Ł: 72 | ㄲ:Ø: 73 | ㄲ:Œ: 74 | ㄲ:Þ: 75 | ㄲ:Ŧ: 76 | ㄲ:Ŋ: 77 | ㄲ:æ: 78 | ㄲ:đ: 79 | ㄲ:ð: 80 | ㄲ:ħ: 81 | ㄲ:ı: 82 | ㄲ:ij: 83 | ㄲ:ĸ: 84 | ㄲ:ŀ: 85 | ㄲ:ł: 86 | ㄲ:ø: 87 | ㄲ:œ: 88 | ㄲ:ß: 89 | ㄲ:þ: 90 | ㄲ:ŧ: 91 | ㄲ:ŋ: 92 | ㄲ:ʼn: 93 | ㄴ:": 94 | ㄴ:(: 95 | ㄴ:): 96 | ㄴ:[: 97 | ㄴ:]: 98 | ㄴ:{: 99 | ㄴ:}: 100 | ㄴ:‘: 101 | ㄴ:’: 102 | ㄴ:“: 103 | ㄴ:”: 104 | ㄴ:〔: 105 | ㄴ:〕: 106 | ㄴ:〈: 107 | ㄴ:〉: 108 | ㄴ:《: 109 | ㄴ:》: 110 | ㄴ:「: 111 | ㄴ:」: 112 | ㄴ:『: 113 | ㄴ:』: 114 | ㄴ:【: 115 | ㄴ:】: 116 | ㄷ:+: 117 | ㄷ:-: 118 | ㄷ:<: 119 | ㄷ:=: 120 | ㄷ:>: 121 | ㄷ:±: 122 | ㄷ:×: 123 | ㄷ:÷: 124 | ㄷ:≠: 125 | ㄷ:≤: 126 | ㄷ:≥: 127 | ㄷ:∞: 128 | ㄷ:∴: 129 | ㄷ:♂: 130 | ㄷ:♀: 131 | ㄷ:∠: 132 | ㄷ:⊥: 133 | ㄷ:⌒: 134 | ㄷ:∂: 135 | ㄷ:∇: 136 | ㄷ:≡: 137 | ㄷ:≒: 138 | ㄷ:≪: 139 | ㄷ:≫: 140 | ㄷ:√: 141 | ㄷ:∽: 142 | ㄷ:∝: 143 | ㄷ:∵: 144 | ㄷ:∫: 145 | ㄷ:∬: 146 | ㄷ:∈: 147 | ㄷ:∋: 148 | ㄷ:⊆: 149 | ㄷ:⊇: 150 | ㄷ:⊂: 151 | ㄷ:⊃: 152 | ㄷ:∪: 153 | ㄷ:∩: 154 | ㄷ:∧: 155 | ㄷ:∨: 156 | ㄷ:¬: 157 | ㄷ:⇒: 158 | ㄷ:⇔: 159 | ㄷ:∀: 160 | ㄷ:∃: 161 | ㄷ:∮: 162 | ㄷ:∑: 163 | ㄷ:∏: 164 | ㄸ:ぁ: 165 | ㄸ:あ: 166 | ㄸ:ぃ: 167 | ㄸ:い: 168 | ㄸ:ぅ: 169 | ㄸ:う: 170 | ㄸ:ぇ: 171 | ㄸ:え: 172 | ㄸ:ぉ: 173 | ㄸ:お: 174 | ㄸ:か: 175 | ㄸ:が: 176 | ㄸ:き: 177 | ㄸ:ぎ: 178 | ㄸ:く: 179 | ㄸ:ぐ: 180 | ㄸ:け: 181 | ㄸ:げ: 182 | ㄸ:こ: 183 | ㄸ:ご: 184 | ㄸ:さ: 185 | ㄸ:ざ: 186 | ㄸ:し: 187 | ㄸ:じ: 188 | ㄸ:す: 189 | ㄸ:ず: 190 | ㄸ:せ: 191 | ㄸ:ぜ: 192 | ㄸ:そ: 193 | ㄸ:ぞ: 194 | ㄸ:た: 195 | ㄸ:だ: 196 | ㄸ:ち: 197 | ㄸ:ぢ: 198 | ㄸ:っ: 199 | ㄸ:つ: 200 | ㄸ:づ: 201 | ㄸ:て: 202 | ㄸ:で: 203 | ㄸ:と: 204 | ㄸ:ど: 205 | ㄸ:な: 206 | ㄸ:に: 207 | ㄸ:ぬ: 208 | ㄸ:ね: 209 | ㄸ:の: 210 | ㄸ:は: 211 | ㄸ:ば: 212 | ㄸ:ぱ: 213 | ㄸ:ひ: 214 | ㄸ:び: 215 | ㄸ:ぴ: 216 | ㄸ:ふ: 217 | ㄸ:ぶ: 218 | ㄸ:ぷ: 219 | ㄸ:へ: 220 | ㄸ:べ: 221 | ㄸ:ぺ: 222 | ㄸ:ほ: 223 | ㄸ:ぼ: 224 | ㄸ:ぽ: 225 | ㄸ:ま: 226 | ㄸ:み: 227 | ㄸ:む: 228 | ㄸ:め: 229 | ㄸ:も: 230 | ㄸ:ゃ: 231 | ㄸ:や: 232 | ㄸ:ゅ: 233 | ㄸ:ゆ: 234 | ㄸ:ょ: 235 | ㄸ:よ: 236 | ㄸ:ら: 237 | ㄸ:り: 238 | ㄸ:る: 239 | ㄸ:れ: 240 | ㄸ:ろ: 241 | ㄸ:ゎ: 242 | ㄸ:わ: 243 | ㄸ:ゐ: 244 | ㄸ:ゑ: 245 | ㄸ:を: 246 | ㄸ:ん: 247 | ㄹ:$: 248 | ㄹ:%: 249 | ㄹ:₩: 250 | ㄹ:F: 251 | ㄹ:′: 252 | ㄹ:″: 253 | ㄹ:℃: 254 | ㄹ:Å: 255 | ㄹ:¢: 256 | ㄹ:£: 257 | ㄹ:¥: 258 | ㄹ:¤: 259 | ㄹ:℉: 260 | ㄹ:‰: 261 | ㄹ:?: 262 | ㄹ:㎕: 263 | ㄹ:㎖: 264 | ㄹ:㎗: 265 | ㄹ:㎘: 266 | ㄹ:㏄: 267 | ㄹ:㎣: 268 | ㄹ:㎤: 269 | ㄹ:㎥: 270 | ㄹ:㎦: 271 | ㄹ:㎙: 272 | ㄹ:㎚: 273 | ㄹ:㎛: 274 | ㄹ:㎜: 275 | ㄹ:㎝: 276 | ㄹ:㎞: 277 | ㄹ:㎟: 278 | ㄹ:㎠: 279 | ㄹ:㎡: 280 | ㄹ:㎢: 281 | ㄹ:㏊: 282 | ㄹ:㎍: 283 | ㄹ:㎎: 284 | ㄹ:㎏: 285 | ㄹ:㏏: 286 | ㄹ:㎈: 287 | ㄹ:㎉: 288 | ㄹ:㏈: 289 | ㄹ:㎧: 290 | ㄹ:㎨: 291 | ㄹ:㎰: 292 | ㄹ:㎱: 293 | ㄹ:㎲: 294 | ㄹ:㎳: 295 | ㄹ:㎴: 296 | ㄹ:㎵: 297 | ㄹ:㎶: 298 | ㄹ:㎷: 299 | ㄹ:㎸: 300 | ㄹ:㎹: 301 | ㄹ:㎀: 302 | ㄹ:㎁: 303 | ㄹ:㎂: 304 | ㄹ:㎃: 305 | ㄹ:㎄: 306 | ㄹ:㎺: 307 | ㄹ:㎻: 308 | ㄹ:㎼: 309 | ㄹ:㎽: 310 | ㄹ:㎾: 311 | ㄹ:㎿: 312 | ㄹ:㎐: 313 | ㄹ:㎑: 314 | ㄹ:㎒: 315 | ㄹ:㎓: 316 | ㄹ:㎔: 317 | ㄹ:Ω: 318 | ㄹ:㏀: 319 | ㄹ:㏁: 320 | ㄹ:㎊: 321 | ㄹ:㎋: 322 | ㄹ:㎌: 323 | ㄹ:㏖: 324 | ㄹ:㏅: 325 | ㄹ:㎭: 326 | ㄹ:㎮: 327 | ㄹ:㎯: 328 | ㄹ:㏛: 329 | ㄹ:㎩: 330 | ㄹ:㎪: 331 | ㄹ:㎫: 332 | ㄹ:㎬: 333 | ㄹ:㏝: 334 | ㄹ:㏐: 335 | ㄹ:㏓: 336 | ㄹ:㏃: 337 | ㄹ:㏉: 338 | ㄹ:㏜: 339 | ㄹ:㏆: 340 | ㅁ:#: 341 | ㅁ:&: 342 | ㅁ:*: 343 | ㅁ:@: 344 | ㅁ:§: 345 | ㅁ:※: 346 | ㅁ:☆: 347 | ㅁ:★: 348 | ㅁ:○: 349 | ㅁ:●: 350 | ㅁ:◎: 351 | ㅁ:◇: 352 | ㅁ:◆: 353 | ㅁ:□: 354 | ㅁ:■: 355 | ㅁ:△: 356 | ㅁ:▲: 357 | ㅁ:▽: 358 | ㅁ:▼: 359 | ㅁ:→: 360 | ㅁ:←: 361 | ㅁ:↑: 362 | ㅁ:↓: 363 | ㅁ:↔: 364 | ㅁ:〓: 365 | ㅁ:▷: 366 | ㅁ:◀: 367 | ㅁ:▷: 368 | ㅁ:▶: 369 | ㅁ:♤: 370 | ㅁ:♠: 371 | ㅁ:♡: 372 | ㅁ:♥: 373 | ㅁ:♧: 374 | ㅁ:⊙: 375 | ㅁ:◈: 376 | ㅁ:▣: 377 | ㅁ:◐: 378 | ㅁ:◑: 379 | ㅁ:▒: 380 | ㅁ:▤: 381 | ㅁ:▥: 382 | ㅁ:▨: 383 | ㅁ:▧: 384 | ㅁ:▦: 385 | ㅁ:▩: 386 | ㅁ:♨: 387 | ㅁ:☏: 388 | ㅁ:☎: 389 | ㅁ:☜: 390 | ㅁ:☞: 391 | ㅁ:¶: 392 | ㅁ:†: 393 | ㅁ:‡: 394 | ㅁ:↕: 395 | ㅁ:↗: 396 | ㅁ:↙: 397 | ㅁ:↖: 398 | ㅁ:↘: 399 | ㅁ:♭: 400 | ㅁ:♩: 401 | ㅁ:♪: 402 | ㅁ:♬: 403 | ㅁ:㉿: 404 | ㅁ:㈜: 405 | ㅁ:№: 406 | ㅁ:㏇: 407 | ㅁ:™: 408 | ㅁ:㏂: 409 | ㅁ:㏘: 410 | ㅁ:℡: 411 | ㅁ:?: 412 | ㅁ:ª: 413 | ㅁ:º: 414 | ㅂ:─: 415 | ㅂ:│: 416 | ㅂ:┌: 417 | ㅂ:┐: 418 | ㅂ:┘: 419 | ㅂ:└: 420 | ㅂ:├: 421 | ㅂ:┬: 422 | ㅂ:┤: 423 | ㅂ:┴: 424 | ㅂ:┼: 425 | ㅂ:━: 426 | ㅂ:┃: 427 | ㅂ:┏: 428 | ㅂ:┓: 429 | ㅂ:┛: 430 | ㅂ:┗: 431 | ㅂ:┣: 432 | ㅂ:┳: 433 | ㅂ:┫: 434 | ㅂ:┻: 435 | ㅂ:╋: 436 | ㅂ:┠: 437 | ㅂ:┯: 438 | ㅂ:┨: 439 | ㅂ:┷: 440 | ㅂ:┿: 441 | ㅂ:┝: 442 | ㅂ:┰: 443 | ㅂ:┥: 444 | ㅂ:┸: 445 | ㅂ:╂: 446 | ㅂ:┒: 447 | ㅂ:┑: 448 | ㅂ:┚: 449 | ㅂ:┙: 450 | ㅂ:┖: 451 | ㅂ:┕: 452 | ㅂ:┎: 453 | ㅂ:┍: 454 | ㅂ:┞: 455 | ㅂ:┟: 456 | ㅂ:┡: 457 | ㅂ:┢: 458 | ㅂ:┦: 459 | ㅂ:┧: 460 | ㅂ:┩: 461 | ㅂ:┪: 462 | ㅂ:┭: 463 | ㅂ:┮: 464 | ㅂ:┲: 465 | ㅂ:┵: 466 | ㅂ:┶: 467 | ㅂ:┹: 468 | ㅂ:┺: 469 | ㅂ:┽: 470 | ㅂ:┾: 471 | ㅂ:╀: 472 | ㅂ:╁: 473 | ㅂ:╃: 474 | ㅂ:╄: 475 | ㅂ:╅: 476 | ㅂ:╆: 477 | ㅂ:╇: 478 | ㅂ:╈: 479 | ㅂ:╉: 480 | ㅂ:╊: 481 | ㅃ:ァ: 482 | ㅃ:ア: 483 | ㅃ:ィ: 484 | ㅃ:イ: 485 | ㅃ:ゥ: 486 | ㅃ:ウ: 487 | ㅃ:ェ: 488 | ㅃ:エ: 489 | ㅃ:ォ: 490 | ㅃ:オ: 491 | ㅃ:カ: 492 | ㅃ:ガ: 493 | ㅃ:キ: 494 | ㅃ:ギ: 495 | ㅃ:ク: 496 | ㅃ:グ: 497 | ㅃ:ケ: 498 | ㅃ:ゲ: 499 | ㅃ:コ: 500 | ㅃ:ゴ: 501 | ㅃ:サ: 502 | ㅃ:ザ: 503 | ㅃ:シ: 504 | ㅃ:ジ: 505 | ㅃ:ス: 506 | ㅃ:ズ: 507 | ㅃ:セ: 508 | ㅃ:ゼ: 509 | ㅃ:ソ: 510 | ㅃ:ゾ: 511 | ㅃ:タ: 512 | ㅃ:ダ: 513 | ㅃ:チ: 514 | ㅃ:ヂ: 515 | ㅃ:ッ: 516 | ㅃ:ツ: 517 | ㅃ:ヅ: 518 | ㅃ:テ: 519 | ㅃ:デ: 520 | ㅃ:ト: 521 | ㅃ:ド: 522 | ㅃ:ナ: 523 | ㅃ:ニ: 524 | ㅃ:ヌ: 525 | ㅃ:ネ: 526 | ㅃ:ノ: 527 | ㅃ:ハ: 528 | ㅃ:バ: 529 | ㅃ:パ: 530 | ㅃ:ヒ: 531 | ㅃ:ビ: 532 | ㅃ:ピ: 533 | ㅃ:フ: 534 | ㅃ:ブ: 535 | ㅃ:プ: 536 | ㅃ:ヘ: 537 | ㅃ:ベ: 538 | ㅃ:ペ: 539 | ㅃ:ホ: 540 | ㅃ:ボ: 541 | ㅃ:ポ: 542 | ㅃ:マ: 543 | ㅃ:ミ: 544 | ㅃ:ム: 545 | ㅃ:メ: 546 | ㅃ:モ: 547 | ㅃ:ャ: 548 | ㅃ:ヤ: 549 | ㅃ:ュ: 550 | ㅃ:ユ: 551 | ㅃ:ョ: 552 | ㅃ:ヨ: 553 | ㅃ:ラ: 554 | ㅃ:リ: 555 | ㅃ:ル: 556 | ㅃ:レ: 557 | ㅃ:ロ: 558 | ㅃ:ヮ: 559 | ㅃ:ワ: 560 | ㅃ:ヰ: 561 | ㅃ:ヱ: 562 | ㅃ:ヲ: 563 | ㅃ:ン: 564 | ㅃ:ヴ: 565 | ㅃ:ヵ: 566 | ㅃ:ヶ: 567 | ㅅ:㉠: 568 | ㅅ:㉡: 569 | ㅅ:㉢: 570 | ㅅ:㉣: 571 | ㅅ:㉤: 572 | ㅅ:㉥: 573 | ㅅ:㉦: 574 | ㅅ:㉧: 575 | ㅅ:㉨: 576 | ㅅ:㉩: 577 | ㅅ:㉪: 578 | ㅅ:㉫: 579 | ㅅ:㉬: 580 | ㅅ:㉭: 581 | ㅅ:㉮: 582 | ㅅ:㉯: 583 | ㅅ:㉰: 584 | ㅅ:㉱: 585 | ㅅ:㉲: 586 | ㅅ:㉳: 587 | ㅅ:㉴: 588 | ㅅ:㉵: 589 | ㅅ:㉶: 590 | ㅅ:㉷: 591 | ㅅ:㉸: 592 | ㅅ:㉹: 593 | ㅅ:㉺: 594 | ㅅ:㉻: 595 | ㅅ:㈀: 596 | ㅅ:㈁: 597 | ㅅ:㈂: 598 | ㅅ:㈃: 599 | ㅅ:㈄: 600 | ㅅ:㈅: 601 | ㅅ:㈆: 602 | ㅅ:㈇: 603 | ㅅ:㈈: 604 | ㅅ:㈉: 605 | ㅅ:㈊: 606 | ㅅ:㈋: 607 | ㅅ:㈌: 608 | ㅅ:㈍: 609 | ㅅ:㈎: 610 | ㅅ:㈏: 611 | ㅅ:㈐: 612 | ㅅ:㈑: 613 | ㅅ:㈒: 614 | ㅅ:㈓: 615 | ㅅ:㈔: 616 | ㅅ:㈕: 617 | ㅅ:㈖: 618 | ㅅ:㈗: 619 | ㅅ:㈘: 620 | ㅅ:㈙: 621 | ㅅ:㈚: 622 | ㅅ:㈛: 623 | ㅆ:А: 624 | ㅆ:Б: 625 | ㅆ:В: 626 | ㅆ:Г: 627 | ㅆ:Д: 628 | ㅆ:Е: 629 | ㅆ:Ё: 630 | ㅆ:Ж: 631 | ㅆ:З: 632 | ㅆ:И: 633 | ㅆ:Й: 634 | ㅆ:К: 635 | ㅆ:Л: 636 | ㅆ:М: 637 | ㅆ:Н: 638 | ㅆ:О: 639 | ㅆ:П: 640 | ㅆ:Р: 641 | ㅆ:С: 642 | ㅆ:Т: 643 | ㅆ:У: 644 | ㅆ:Ф: 645 | ㅆ:Х: 646 | ㅆ:Ц: 647 | ㅆ:Ч: 648 | ㅆ:Ш: 649 | ㅆ:Щ: 650 | ㅆ:Ъ: 651 | ㅆ:Ы: 652 | ㅆ:Ь: 653 | ㅆ:Э: 654 | ㅆ:Ю: 655 | ㅆ:Я: 656 | ㅆ:а: 657 | ㅆ:б: 658 | ㅆ:в: 659 | ㅆ:г: 660 | ㅆ:д: 661 | ㅆ:е: 662 | ㅆ:ё: 663 | ㅆ:ж: 664 | ㅆ:з: 665 | ㅆ:и: 666 | ㅆ:й: 667 | ㅆ:к: 668 | ㅆ:л: 669 | ㅆ:м: 670 | ㅆ:н: 671 | ㅆ:о: 672 | ㅆ:п: 673 | ㅆ:р: 674 | ㅆ:с: 675 | ㅆ:т: 676 | ㅆ:у: 677 | ㅆ:ф: 678 | ㅆ:х: 679 | ㅆ:ц: 680 | ㅆ:ч: 681 | ㅆ:ш: 682 | ㅆ:щ: 683 | ㅆ:ъ: 684 | ㅆ:ы: 685 | ㅆ:ь: 686 | ㅆ:э: 687 | ㅆ:ю: 688 | ㅆ:я: 689 | ㅇ:ⓐ: 690 | ㅇ:ⓑ: 691 | ㅇ:ⓒ: 692 | ㅇ:ⓓ: 693 | ㅇ:ⓔ: 694 | ㅇ:ⓕ: 695 | ㅇ:ⓖ: 696 | ㅇ:ⓗ: 697 | ㅇ:ⓘ: 698 | ㅇ:ⓙ: 699 | ㅇ:ⓚ: 700 | ㅇ:ⓛ: 701 | ㅇ:ⓜ: 702 | ㅇ:ⓝ: 703 | ㅇ:ⓞ: 704 | ㅇ:ⓟ: 705 | ㅇ:ⓠ: 706 | ㅇ:ⓡ: 707 | ㅇ:ⓢ: 708 | ㅇ:ⓣ: 709 | ㅇ:ⓤ: 710 | ㅇ:ⓥ: 711 | ㅇ:ⓦ: 712 | ㅇ:ⓧ: 713 | ㅇ:ⓨ: 714 | ㅇ:ⓩ: 715 | ㅇ:①: 716 | ㅇ:②: 717 | ㅇ:③: 718 | ㅇ:④: 719 | ㅇ:⑤: 720 | ㅇ:⑥: 721 | ㅇ:⑦: 722 | ㅇ:⑧: 723 | ㅇ:⑨: 724 | ㅇ:⑩: 725 | ㅇ:⑪: 726 | ㅇ:⑫: 727 | ㅇ:⑬: 728 | ㅇ:⑭: 729 | ㅇ:⑮: 730 | ㅇ:⒜: 731 | ㅇ:⒝: 732 | ㅇ:⒞: 733 | ㅇ:⒟: 734 | ㅇ:⒠: 735 | ㅇ:⒡: 736 | ㅇ:⒢: 737 | ㅇ:⒣: 738 | ㅇ:⒤: 739 | ㅇ:⒥: 740 | ㅇ:⒦: 741 | ㅇ:⒧: 742 | ㅇ:⒨: 743 | ㅇ:⒩: 744 | ㅇ:⒪: 745 | ㅇ:⒫: 746 | ㅇ:⒬: 747 | ㅇ:⒭: 748 | ㅇ:⒮: 749 | ㅇ:⒯: 750 | ㅇ:⒰: 751 | ㅇ:⒱: 752 | ㅇ:⒲: 753 | ㅇ:⒳: 754 | ㅇ:⒴: 755 | ㅇ:⒵: 756 | ㅇ:⑴: 757 | ㅇ:⑵: 758 | ㅇ:⑶: 759 | ㅇ:⑷: 760 | ㅇ:⑸: 761 | ㅇ:⑹: 762 | ㅇ:⑺: 763 | ㅇ:⑻: 764 | ㅇ:⑼: 765 | ㅇ:⑽: 766 | ㅇ:⑾: 767 | ㅇ:⑿: 768 | ㅇ:⒀: 769 | ㅇ:⒁: 770 | ㅇ:⒂: 771 | ㅈ:0: 772 | ㅈ:1: 773 | ㅈ:2: 774 | ㅈ:3: 775 | ㅈ:4: 776 | ㅈ:5: 777 | ㅈ:6: 778 | ㅈ:7: 779 | ㅈ:8: 780 | ㅈ:9: 781 | ㅈ:ⅰ: 782 | ㅈ:ⅱ: 783 | ㅈ:ⅲ: 784 | ㅈ:ⅳ: 785 | ㅈ:ⅴ: 786 | ㅈ:ⅵ: 787 | ㅈ:ⅶ: 788 | ㅈ:ⅷ: 789 | ㅈ:ⅸ: 790 | ㅈ:ⅹ: 791 | ㅈ:Ⅰ: 792 | ㅈ:Ⅱ: 793 | ㅈ:Ⅲ: 794 | ㅈ:Ⅳ: 795 | ㅈ:Ⅴ: 796 | ㅈ:Ⅵ: 797 | ㅈ:Ⅶ: 798 | ㅈ:Ⅷ: 799 | ㅈ:Ⅸ: 800 | ㅈ:Ⅹ: 801 | ㅊ:½: 802 | ㅊ:⅓: 803 | ㅊ:⅔: 804 | ㅊ:¼: 805 | ㅊ:¾: 806 | ㅊ:⅛: 807 | ㅊ:⅜: 808 | ㅊ:⅝: 809 | ㅊ:⅞: 810 | ㅊ:¹: 811 | ㅊ:²: 812 | ㅊ:³: 813 | ㅊ:⁴: 814 | ㅊ:ⁿ: 815 | ㅊ:₁: 816 | ㅊ:₂: 817 | ㅊ:₃: 818 | ㅊ:₄: 819 | ㅋ:ㄱ: 820 | ㅋ:ㄲ: 821 | ㅋ:ㄳ: 822 | ㅋ:ㄴ: 823 | ㅋ:ㄵ: 824 | ㅋ:ㄶ: 825 | ㅋ:ㄷ: 826 | ㅋ:ㄸ: 827 | ㅋ:ㄹ: 828 | ㅋ:ㄺ: 829 | ㅋ:ㄻ: 830 | ㅋ:ㄼ: 831 | ㅋ:ㄽ: 832 | ㅋ:ㄾ: 833 | ㅋ:ㄿ: 834 | ㅋ:ㅀ: 835 | ㅋ:ㅁ: 836 | ㅋ:ㅂ: 837 | ㅋ:ㅃ: 838 | ㅋ:ㅄ: 839 | ㅋ:ㅅ: 840 | ㅋ:ㅆ: 841 | ㅋ:ㅇ: 842 | ㅋ:ㅈ: 843 | ㅋ:ㅉ: 844 | ㅋ:ㅊ: 845 | ㅋ:ㅋ: 846 | ㅋ:ㅌ: 847 | ㅋ:ㅍ: 848 | ㅋ:ㅎ: 849 | ㅋ:ㅏ: 850 | ㅋ:ㅐ: 851 | ㅋ:ㅑ: 852 | ㅋ:ㅒ: 853 | ㅋ:ㅓ: 854 | ㅋ:ㅔ: 855 | ㅋ:ㅕ: 856 | ㅋ:ㅖ: 857 | ㅋ:ㅗ: 858 | ㅋ:ㅘ: 859 | ㅋ:ㅙ: 860 | ㅋ:ㅚ: 861 | ㅋ:ㅛ: 862 | ㅋ:ㅜ: 863 | ㅋ:ㅝ: 864 | ㅋ:ㅞ: 865 | ㅋ:ㅟ: 866 | ㅋ:ㅠ: 867 | ㅋ:ㅡ: 868 | ㅋ:ㅢ: 869 | ㅋ:ㅣ: 870 | ㅌ:ㅥ: 871 | ㅌ:ㅦ: 872 | ㅌ:ㅧ: 873 | ㅌ:ㅨ: 874 | ㅌ:ㅩ: 875 | ㅌ:ㅪ: 876 | ㅌ:ㅫ: 877 | ㅌ:ㅬ: 878 | ㅌ:ㅭ: 879 | ㅌ:ㅮ: 880 | ㅌ:ㅯ: 881 | ㅌ:ㅰ: 882 | ㅌ:ㅱ: 883 | ㅌ:ㅲ: 884 | ㅌ:ㅳ: 885 | ㅌ:ㅴ: 886 | ㅌ:ㅵ: 887 | ㅌ:ㅶ: 888 | ㅌ:ㅷ: 889 | ㅌ:ㅸ: 890 | ㅌ:ㅹ: 891 | ㅌ:ㅺ: 892 | ㅌ:ㆄ: 893 | ㅌ:ㅼ: 894 | ㅌ:ㅽ: 895 | ㅌ:ㅾ: 896 | ㅌ:ㅿ: 897 | ㅌ:ㆀ: 898 | ㅌ:ㆁ: 899 | ㅌ:ㆂ: 900 | ㅌ:ㆃ: 901 | ㅌ:ㆄ: 902 | ㅌ:ㆅ: 903 | ㅌ:ㆆ: 904 | ㅌ:ㆇ: 905 | ㅌ:ㆈ: 906 | ㅌ:ㆉ: 907 | ㅌ:ㆊ: 908 | ㅌ:ㆋ: 909 | ㅌ:ㆌ: 910 | ㅌ:ㆍ: 911 | ㅌ:ㆎ: 912 | ㅍ:A: 913 | ㅍ:B: 914 | ㅍ:C: 915 | ㅍ:D: 916 | ㅍ:E: 917 | ㅍ:F: 918 | ㅍ:G: 919 | ㅍ:H: 920 | ㅍ:I: 921 | ㅍ:J: 922 | ㅍ:K: 923 | ㅍ:L: 924 | ㅍ:M: 925 | ㅍ:N: 926 | ㅍ:O: 927 | ㅍ:P: 928 | ㅍ:Q: 929 | ㅍ:R: 930 | ㅍ:S: 931 | ㅍ:T: 932 | ㅍ:U: 933 | ㅍ:V: 934 | ㅍ:W: 935 | ㅍ:X: 936 | ㅍ:Y: 937 | ㅍ:Z: 938 | ㅍ:a: 939 | ㅍ:b: 940 | ㅍ:c: 941 | ㅍ:d: 942 | ㅍ:e: 943 | ㅍ:f: 944 | ㅍ:g: 945 | ㅍ:h: 946 | ㅍ:i: 947 | ㅍ:j: 948 | ㅍ:k: 949 | ㅍ:l: 950 | ㅍ:m: 951 | ㅍ:n: 952 | ㅍ:o: 953 | ㅍ:p: 954 | ㅍ:q: 955 | ㅍ:r: 956 | ㅍ:s: 957 | ㅍ:t: 958 | ㅍ:u: 959 | ㅍ:v: 960 | ㅍ:w: 961 | ㅍ:x: 962 | ㅍ:y: 963 | ㅍ:z: 964 | ㅎ:Α: 965 | ㅎ:Β: 966 | ㅎ:Γ: 967 | ㅎ:Δ: 968 | ㅎ:Ε: 969 | ㅎ:Ζ: 970 | ㅎ:Η: 971 | ㅎ:Θ: 972 | ㅎ:Ι: 973 | ㅎ:Κ: 974 | ㅎ:Λ: 975 | ㅎ:Μ: 976 | ㅎ:Ν: 977 | ㅎ:Ξ: 978 | ㅎ:Ο: 979 | ㅎ:Π: 980 | ㅎ:Ρ: 981 | ㅎ:Σ: 982 | ㅎ:Τ: 983 | ㅎ:Υ: 984 | ㅎ:Φ: 985 | ㅎ:Χ: 986 | ㅎ:Ψ: 987 | ㅎ:Ω: 988 | ㅎ:α: 989 | ㅎ:β: 990 | ㅎ:γ: 991 | ㅎ:δ: 992 | ㅎ:ε: 993 | ㅎ:ζ: 994 | ㅎ:η: 995 | ㅎ:θ: 996 | ㅎ:ι: 997 | ㅎ:κ: 998 | ㅎ:λ: 999 | ㅎ:μ: 1000 | ㅎ:ν: 1001 | ㅎ:ξ: 1002 | ㅎ:ο: 1003 | ㅎ:π: 1004 | ㅎ:ρ: 1005 | ㅎ:σ: 1006 | ㅎ:τ: 1007 | ㅎ:υ: 1008 | ㅎ:φ: 1009 | ㅎ:χ: 1010 | ㅎ:ψ: 1011 | ㅎ:ω: 1012 | -------------------------------------------------------------------------------- /COPYING: -------------------------------------------------------------------------------- 1 | GNU GENERAL PUBLIC LICENSE 2 | Version 2, June 1991 3 | 4 | Copyright (C) 1989, 1991 Free Software Foundation, Inc. 5 | 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. 6 | Everyone is permitted to copy and distribute verbatim copies 7 | of this license document, but changing it is not allowed. 8 | 9 | Preamble 10 | 11 | The licenses for most software are designed to take away your 12 | freedom to share and change it. By contrast, the GNU General Public 13 | License is intended to guarantee your freedom to share and change free 14 | software--to make sure the software is free for all its users. This 15 | General Public License applies to most of the Free Software 16 | Foundation's software and to any other program whose authors commit to 17 | using it. (Some other Free Software Foundation software is covered by 18 | the GNU Library General Public License instead.) You can apply it to 19 | your programs, too. 20 | 21 | When we speak of free software, we are referring to freedom, not 22 | price. Our General Public Licenses are designed to make sure that you 23 | have the freedom to distribute copies of free software (and charge for 24 | this service if you wish), that you receive source code or can get it 25 | if you want it, that you can change the software or use pieces of it 26 | in new free programs; and that you know you can do these things. 27 | 28 | To protect your rights, we need to make restrictions that forbid 29 | anyone to deny you these rights or to ask you to surrender the rights. 30 | These restrictions translate to certain responsibilities for you if you 31 | distribute copies of the software, or if you modify it. 32 | 33 | For example, if you distribute copies of such a program, whether 34 | gratis or for a fee, you must give the recipients all the rights that 35 | you have. You must make sure that they, too, receive or can get the 36 | source code. And you must show them these terms so they know their 37 | rights. 38 | 39 | We protect your rights with two steps: (1) copyright the software, and 40 | (2) offer you this license which gives you legal permission to copy, 41 | distribute and/or modify the software. 42 | 43 | Also, for each author's protection and ours, we want to make certain 44 | that everyone understands that there is no warranty for this free 45 | software. If the software is modified by someone else and passed on, we 46 | want its recipients to know that what they have is not the original, so 47 | that any problems introduced by others will not reflect on the original 48 | authors' reputations. 49 | 50 | Finally, any free program is threatened constantly by software 51 | patents. We wish to avoid the danger that redistributors of a free 52 | program will individually obtain patent licenses, in effect making the 53 | program proprietary. To prevent this, we have made it clear that any 54 | patent must be licensed for everyone's free use or not licensed at all. 55 | 56 | The precise terms and conditions for copying, distribution and 57 | modification follow. 58 | 59 | GNU GENERAL PUBLIC LICENSE 60 | TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 61 | 62 | 0. This License applies to any program or other work which contains 63 | a notice placed by the copyright holder saying it may be distributed 64 | under the terms of this General Public License. The "Program", below, 65 | refers to any such program or work, and a "work based on the Program" 66 | means either the Program or any derivative work under copyright law: 67 | that is to say, a work containing the Program or a portion of it, 68 | either verbatim or with modifications and/or translated into another 69 | language. (Hereinafter, translation is included without limitation in 70 | the term "modification".) Each licensee is addressed as "you". 71 | 72 | Activities other than copying, distribution and modification are not 73 | covered by this License; they are outside its scope. The act of 74 | running the Program is not restricted, and the output from the Program 75 | is covered only if its contents constitute a work based on the 76 | Program (independent of having been made by running the Program). 77 | Whether that is true depends on what the Program does. 78 | 79 | 1. You may copy and distribute verbatim copies of the Program's 80 | source code as you receive it, in any medium, provided that you 81 | conspicuously and appropriately publish on each copy an appropriate 82 | copyright notice and disclaimer of warranty; keep intact all the 83 | notices that refer to this License and to the absence of any warranty; 84 | and give any other recipients of the Program a copy of this License 85 | along with the Program. 86 | 87 | You may charge a fee for the physical act of transferring a copy, and 88 | you may at your option offer warranty protection in exchange for a fee. 89 | 90 | 2. You may modify your copy or copies of the Program or any portion 91 | of it, thus forming a work based on the Program, and copy and 92 | distribute such modifications or work under the terms of Section 1 93 | above, provided that you also meet all of these conditions: 94 | 95 | a) You must cause the modified files to carry prominent notices 96 | stating that you changed the files and the date of any change. 97 | 98 | b) You must cause any work that you distribute or publish, that in 99 | whole or in part contains or is derived from the Program or any 100 | part thereof, to be licensed as a whole at no charge to all third 101 | parties under the terms of this License. 102 | 103 | c) If the modified program normally reads commands interactively 104 | when run, you must cause it, when started running for such 105 | interactive use in the most ordinary way, to print or display an 106 | announcement including an appropriate copyright notice and a 107 | notice that there is no warranty (or else, saying that you provide 108 | a warranty) and that users may redistribute the program under 109 | these conditions, and telling the user how to view a copy of this 110 | License. (Exception: if the Program itself is interactive but 111 | does not normally print such an announcement, your work based on 112 | the Program is not required to print an announcement.) 113 | 114 | These requirements apply to the modified work as a whole. If 115 | identifiable sections of that work are not derived from the Program, 116 | and can be reasonably considered independent and separate works in 117 | themselves, then this License, and its terms, do not apply to those 118 | sections when you distribute them as separate works. But when you 119 | distribute the same sections as part of a whole which is a work based 120 | on the Program, the distribution of the whole must be on the terms of 121 | this License, whose permissions for other licensees extend to the 122 | entire whole, and thus to each and every part regardless of who wrote it. 123 | 124 | Thus, it is not the intent of this section to claim rights or contest 125 | your rights to work written entirely by you; rather, the intent is to 126 | exercise the right to control the distribution of derivative or 127 | collective works based on the Program. 128 | 129 | In addition, mere aggregation of another work not based on the Program 130 | with the Program (or with a work based on the Program) on a volume of 131 | a storage or distribution medium does not bring the other work under 132 | the scope of this License. 133 | 134 | 3. You may copy and distribute the Program (or a work based on it, 135 | under Section 2) in object code or executable form under the terms of 136 | Sections 1 and 2 above provided that you also do one of the following: 137 | 138 | a) Accompany it with the complete corresponding machine-readable 139 | source code, which must be distributed under the terms of Sections 140 | 1 and 2 above on a medium customarily used for software interchange; or, 141 | 142 | b) Accompany it with a written offer, valid for at least three 143 | years, to give any third party, for a charge no more than your 144 | cost of physically performing source distribution, a complete 145 | machine-readable copy of the corresponding source code, to be 146 | distributed under the terms of Sections 1 and 2 above on a medium 147 | customarily used for software interchange; or, 148 | 149 | c) Accompany it with the information you received as to the offer 150 | to distribute corresponding source code. (This alternative is 151 | allowed only for noncommercial distribution and only if you 152 | received the program in object code or executable form with such 153 | an offer, in accord with Subsection b above.) 154 | 155 | The source code for a work means the preferred form of the work for 156 | making modifications to it. For an executable work, complete source 157 | code means all the source code for all modules it contains, plus any 158 | associated interface definition files, plus the scripts used to 159 | control compilation and installation of the executable. However, as a 160 | special exception, the source code distributed need not include 161 | anything that is normally distributed (in either source or binary 162 | form) with the major components (compiler, kernel, and so on) of the 163 | operating system on which the executable runs, unless that component 164 | itself accompanies the executable. 165 | 166 | If distribution of executable or object code is made by offering 167 | access to copy from a designated place, then offering equivalent 168 | access to copy the source code from the same place counts as 169 | distribution of the source code, even though third parties are not 170 | compelled to copy the source along with the object code. 171 | 172 | 4. You may not copy, modify, sublicense, or distribute the Program 173 | except as expressly provided under this License. Any attempt 174 | otherwise to copy, modify, sublicense or distribute the Program is 175 | void, and will automatically terminate your rights under this License. 176 | However, parties who have received copies, or rights, from you under 177 | this License will not have their licenses terminated so long as such 178 | parties remain in full compliance. 179 | 180 | 5. You are not required to accept this License, since you have not 181 | signed it. However, nothing else grants you permission to modify or 182 | distribute the Program or its derivative works. These actions are 183 | prohibited by law if you do not accept this License. Therefore, by 184 | modifying or distributing the Program (or any work based on the 185 | Program), you indicate your acceptance of this License to do so, and 186 | all its terms and conditions for copying, distributing or modifying 187 | the Program or works based on it. 188 | 189 | 6. Each time you redistribute the Program (or any work based on the 190 | Program), the recipient automatically receives a license from the 191 | original licensor to copy, distribute or modify the Program subject to 192 | these terms and conditions. You may not impose any further 193 | restrictions on the recipients' exercise of the rights granted herein. 194 | You are not responsible for enforcing compliance by third parties to 195 | this License. 196 | 197 | 7. If, as a consequence of a court judgment or allegation of patent 198 | infringement or for any other reason (not limited to patent issues), 199 | conditions are imposed on you (whether by court order, agreement or 200 | otherwise) that contradict the conditions of this License, they do not 201 | excuse you from the conditions of this License. If you cannot 202 | distribute so as to satisfy simultaneously your obligations under this 203 | License and any other pertinent obligations, then as a consequence you 204 | may not distribute the Program at all. For example, if a patent 205 | license would not permit royalty-free redistribution of the Program by 206 | all those who receive copies directly or indirectly through you, then 207 | the only way you could satisfy both it and this License would be to 208 | refrain entirely from distribution of the Program. 209 | 210 | If any portion of this section is held invalid or unenforceable under 211 | any particular circumstance, the balance of the section is intended to 212 | apply and the section as a whole is intended to apply in other 213 | circumstances. 214 | 215 | It is not the purpose of this section to induce you to infringe any 216 | patents or other property right claims or to contest validity of any 217 | such claims; this section has the sole purpose of protecting the 218 | integrity of the free software distribution system, which is 219 | implemented by public license practices. Many people have made 220 | generous contributions to the wide range of software distributed 221 | through that system in reliance on consistent application of that 222 | system; it is up to the author/donor to decide if he or she is willing 223 | to distribute software through any other system and a licensee cannot 224 | impose that choice. 225 | 226 | This section is intended to make thoroughly clear what is believed to 227 | be a consequence of the rest of this License. 228 | 229 | 8. If the distribution and/or use of the Program is restricted in 230 | certain countries either by patents or by copyrighted interfaces, the 231 | original copyright holder who places the Program under this License 232 | may add an explicit geographical distribution limitation excluding 233 | those countries, so that distribution is permitted only in or among 234 | countries not thus excluded. In such case, this License incorporates 235 | the limitation as if written in the body of this License. 236 | 237 | 9. The Free Software Foundation may publish revised and/or new versions 238 | of the General Public License from time to time. Such new versions will 239 | be similar in spirit to the present version, but may differ in detail to 240 | address new problems or concerns. 241 | 242 | Each version is given a distinguishing version number. If the Program 243 | specifies a version number of this License which applies to it and "any 244 | later version", you have the option of following the terms and conditions 245 | either of that version or of any later version published by the Free 246 | Software Foundation. If the Program does not specify a version number of 247 | this License, you may choose any version ever published by the Free Software 248 | Foundation. 249 | 250 | 10. If you wish to incorporate parts of the Program into other free 251 | programs whose distribution conditions are different, write to the author 252 | to ask for permission. For software which is copyrighted by the Free 253 | Software Foundation, write to the Free Software Foundation; we sometimes 254 | make exceptions for this. Our decision will be guided by the two goals 255 | of preserving the free status of all derivatives of our free software and 256 | of promoting the sharing and reuse of software generally. 257 | 258 | NO WARRANTY 259 | 260 | 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY 261 | FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN 262 | OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES 263 | PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED 264 | OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 265 | MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS 266 | TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE 267 | PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, 268 | REPAIR OR CORRECTION. 269 | 270 | 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING 271 | WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR 272 | REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, 273 | INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING 274 | OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED 275 | TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY 276 | YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER 277 | PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE 278 | POSSIBILITY OF SUCH DAMAGES. 279 | 280 | END OF TERMS AND CONDITIONS 281 | 282 | How to Apply These Terms to Your New Programs 283 | 284 | If you develop a new program, and you want it to be of the greatest 285 | possible use to the public, the best way to achieve this is to make it 286 | free software which everyone can redistribute and change under these terms. 287 | 288 | To do so, attach the following notices to the program. It is safest 289 | to attach them to the start of each source file to most effectively 290 | convey the exclusion of warranty; and each file should have at least 291 | the "copyright" line and a pointer to where the full notice is found. 292 | 293 | 294 | Copyright (C) 295 | 296 | This program is free software; you can redistribute it and/or modify 297 | it under the terms of the GNU General Public License as published by 298 | the Free Software Foundation; either version 2 of the License, or 299 | (at your option) any later version. 300 | 301 | This program is distributed in the hope that it will be useful, 302 | but WITHOUT ANY WARRANTY; without even the implied warranty of 303 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 304 | GNU General Public License for more details. 305 | 306 | You should have received a copy of the GNU General Public License 307 | along with this program; if not, write to the Free Software 308 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. 309 | 310 | 311 | Also add information on how to contact you by electronic and paper mail. 312 | 313 | If the program is interactive, make it output a short notice like this 314 | when it starts in an interactive mode: 315 | 316 | Gnomovision version 69, Copyright (C) year name of author 317 | Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. 318 | This is free software, and you are welcome to redistribute it 319 | under certain conditions; type `show c' for details. 320 | 321 | The hypothetical commands `show w' and `show c' should show the appropriate 322 | parts of the General Public License. Of course, the commands you use may 323 | be called something other than `show w' and `show c'; they could even be 324 | mouse-clicks or menu items--whatever suits your program. 325 | 326 | You should also get your employer (if you work as a programmer) or your 327 | school, if any, to sign a "copyright disclaimer" for the program, if 328 | necessary. Here is a sample; alter the names: 329 | 330 | Yoyodyne, Inc., hereby disclaims all copyright interest in the program 331 | `Gnomovision' (which makes passes at compilers) written by James Hacker. 332 | 333 | , 1 April 1989 334 | Ty Coon, President of Vice 335 | 336 | This General Public License does not permit incorporating your program into 337 | proprietary programs. If your program is a subroutine library, you may 338 | consider it more useful to permit linking proprietary applications with the 339 | library. If this is what you want to do, use the GNU Library General 340 | Public License instead of this License. 341 | -------------------------------------------------------------------------------- /src/eim.c: -------------------------------------------------------------------------------- 1 | /*************************************************************************** 2 | * Copyright (C) 2010~2012 by CSSlayer * 3 | * wengxt@gmail.com * 4 | * * 5 | * This program is free software; you can redistribute it and/or modify * 6 | * it under the terms of the GNU General Public License as published by * 7 | * the Free Software Foundation; either version 2 of the License, or * 8 | * (at your option) any later version. * 9 | * * 10 | * This program is distributed in the hope that it will be useful, * 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of * 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * 13 | * GNU General Public License for more details. * 14 | * * 15 | * You should have received a copy of the GNU General Public License * 16 | * along with this program; if not, write to the * 17 | * Free Software Foundation, Inc., * 18 | * 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. * 19 | ***************************************************************************/ 20 | 21 | #include 22 | #include 23 | #include 24 | #include 25 | #include 26 | #include 27 | 28 | #include 29 | #include 30 | #include 31 | #include 32 | #include 33 | #include 34 | #include 35 | #include 36 | #include 37 | #include 38 | 39 | #include 40 | 41 | #include "eim.h" 42 | #include "keyboard.h" 43 | 44 | #define MAX_LENGTH 40 45 | 46 | FCITX_EXPORT_API 47 | FcitxIMClass ime = { 48 | FcitxHangulCreate, 49 | FcitxHangulDestroy 50 | }; 51 | FCITX_EXPORT_API 52 | int ABI_VERSION = FCITX_ABI_VERSION; 53 | 54 | static const FcitxHotkey FCITX_HANGUL_GRAVE[2] = { 55 | {NULL, FcitxKey_grave, FcitxKeyState_None}, 56 | {NULL, 0, 0}, 57 | }; 58 | 59 | CONFIG_DESC_DEFINE(GetHangulConfigDesc, "fcitx-hangul.desc") 60 | 61 | boolean LoadHangulConfig(FcitxHangulConfig* fs); 62 | static void SaveHangulConfig(FcitxHangulConfig* fs); 63 | static void ConfigHangul(FcitxHangul* hangul); 64 | static void FcitxHangulUpdatePreedit(FcitxHangul* hangul); 65 | static void FcitxHangulCleanLookupTable(FcitxHangul* hangul); 66 | static void FcitxHangulUpdateLookupTable(FcitxHangul* hangul, boolean checkSurrounding); 67 | static void FcitxHangulFlush(FcitxHangul* hangul); 68 | static void FcitxHangulToggleHanja(void* arg); 69 | static boolean FcitxHangulGetHanja(void* arg); 70 | static void FcitxHangulResetEvent(void* arg); 71 | static char* FcitxHangulUcs4ToUtf8(FcitxHangul* hangul, const ucschar* ucsstr, int length); 72 | static void FcitxHangulUpdateHanjaStatus(FcitxHangul* hangul); 73 | 74 | static inline void FcitxHangulFreeHanjaList(FcitxHangul* hangul) { 75 | if (hangul->hanjaList) { 76 | hanja_list_delete (hangul->hanjaList); 77 | hangul->hanjaList = NULL; 78 | } 79 | } 80 | 81 | static inline size_t ucs4_strlen(const ucschar* str) 82 | { 83 | size_t len = 0; 84 | while(*str) { 85 | len ++; 86 | str ++; 87 | } 88 | return len; 89 | } 90 | 91 | static boolean 92 | FcitxHangulOnTransition (HangulInputContext *hic, 93 | ucschar c, 94 | const ucschar *preedit, 95 | void *data) 96 | { 97 | FcitxHangul* hangul = (FcitxHangul*) data; 98 | if (!hangul->fh.autoReorder) { 99 | if (hangul_is_choseong (c)) { 100 | if (hangul_ic_has_jungseong (hic) || hangul_ic_has_jongseong (hic)) 101 | return false; 102 | } 103 | 104 | if (hangul_is_jungseong (c)) { 105 | if (hangul_ic_has_jongseong (hic)) 106 | return false; 107 | } 108 | } 109 | 110 | return true; 111 | } 112 | 113 | char* FcitxHangulUcs4ToUtf8(FcitxHangul* hangul, const ucschar* ucsstr, int length) 114 | { 115 | if (!ucsstr) 116 | return NULL; 117 | 118 | size_t ucslen; 119 | if (length < 0) 120 | ucslen = ucs4_strlen(ucsstr); 121 | else 122 | ucslen = length; 123 | size_t len = UTF8_MAX_LENGTH * ucslen; 124 | char* str = (char*) fcitx_utils_malloc0(sizeof(char) * len + 1); 125 | len *= sizeof(char); 126 | ucslen *= sizeof(ucschar); 127 | char* p = str; 128 | iconv(hangul->conv, (char**) &ucsstr, &ucslen, &p, &len); 129 | return str; 130 | } 131 | 132 | /** 133 | * @brief Reset the status. 134 | * 135 | **/ 136 | void FcitxHangulReset (void* arg) 137 | { 138 | FcitxHangul* hangul = (FcitxHangul*) arg; 139 | ustring_clear(hangul->preedit); 140 | hangul_ic_reset(hangul->ic); 141 | if (hangul->hanjaList) { 142 | FcitxHangulCleanLookupTable(hangul); 143 | } 144 | } 145 | 146 | /** 147 | * @brief Process Key Input and return the status 148 | * 149 | * @param keycode keycode from XKeyEvent 150 | * @param state state from XKeyEvent 151 | * @param count count from XKeyEvent 152 | * @return INPUT_RETURN_VALUE 153 | **/ 154 | INPUT_RETURN_VALUE FcitxHangulDoInput(void* arg, FcitxKeySym sym, unsigned int state) 155 | { 156 | FcitxHangul* hangul = (FcitxHangul*) arg; 157 | FcitxInstance* instance = hangul->owner; 158 | 159 | if (FcitxHotkeyIsHotKey(sym, state, hangul->fh.hkHanjaMode)) { 160 | if (hangul->hanjaList == NULL) { 161 | FcitxHangulUpdateLookupTable(hangul, true); 162 | } 163 | else { 164 | FcitxHangulCleanLookupTable(hangul); 165 | } 166 | return IRV_DISPLAY_MESSAGE; 167 | } 168 | 169 | if (sym == FcitxKey_Shift_L || sym == FcitxKey_Shift_R) 170 | return IRV_TO_PROCESS; 171 | 172 | FcitxGlobalConfig* config = FcitxInstanceGetGlobalConfig(hangul->owner); 173 | const FcitxHotkey* prevPage = FcitxConfigPrevPageKey(instance, config); 174 | const FcitxHotkey* nextPage = FcitxConfigNextPageKey(instance, config); 175 | int s = hangul->fh.hkHanjaMode[0].state | hangul->fh.hkHanjaMode[1].state 176 | | config->prevWord[0].state | config->prevWord[1].state 177 | | config->nextWord[0].state | config->nextWord[1].state 178 | | prevPage[0].state | prevPage[1].state 179 | | nextPage[0].state | nextPage[1].state; 180 | 181 | if (s & FcitxKeyState_Ctrl) { 182 | if (sym == FcitxKey_Control_L || sym == FcitxKey_Control_R) 183 | return IRV_TO_PROCESS; 184 | } 185 | if (s & FcitxKeyState_Alt) { 186 | if (sym == FcitxKey_Alt_L || sym == FcitxKey_Alt_R) 187 | return IRV_TO_PROCESS; 188 | } 189 | if (s & FcitxKeyState_Shift) { 190 | if (sym == FcitxKey_Shift_L || sym == FcitxKey_Shift_R) 191 | return IRV_TO_PROCESS; 192 | } 193 | if (s & FcitxKeyState_Super) { 194 | if (sym == FcitxKey_Super_L || sym == FcitxKey_Super_R) 195 | return IRV_TO_PROCESS; 196 | } 197 | if (s & FcitxKeyState_Hyper) { 198 | if (sym == FcitxKey_Hyper_L || sym == FcitxKey_Hyper_R) 199 | return IRV_TO_PROCESS; 200 | } 201 | 202 | FcitxInputState* input = FcitxInstanceGetInputState(hangul->owner); 203 | FcitxCandidateWordList* candList = FcitxInputStateGetCandidateList(input); 204 | int candSize = FcitxCandidateWordGetListSize(candList); 205 | 206 | if (candSize > 0) { 207 | if (FcitxHotkeyIsHotKey(sym, state, prevPage)) { 208 | if (FcitxCandidateWordHasPrev(candList)) { 209 | FcitxCandidateWordGetFocus(candList, true); 210 | } 211 | if (FcitxCandidateWordGoPrevPage(candList)) { 212 | FcitxCandidateWordSetType(FcitxCandidateWordGetByIndex(candList, 0), MSG_CANDIATE_CURSOR); 213 | return IRV_FLAG_UPDATE_INPUT_WINDOW; 214 | } else { 215 | return IRV_DO_NOTHING; 216 | } 217 | } else if (FcitxHotkeyIsHotKey(sym, state, nextPage)) { 218 | if (FcitxCandidateWordHasNext(candList)) { 219 | FcitxCandidateWordGetFocus(candList, true); 220 | } 221 | if (FcitxCandidateWordGoNextPage(candList)) { 222 | FcitxCandidateWordSetType(FcitxCandidateWordGetByIndex(candList, 0), MSG_CANDIATE_CURSOR); 223 | return IRV_FLAG_UPDATE_INPUT_WINDOW; 224 | } else { 225 | return IRV_DO_NOTHING; 226 | } 227 | } 228 | 229 | FcitxCandidateWord* candWord = NULL; 230 | if (FcitxHotkeyIsHotKey(sym, state, config->nextWord)) { 231 | candWord = FcitxCandidateWordGetFocus(candList, true); 232 | candWord = FcitxCandidateWordGetNext(candList, candWord); 233 | if (!candWord) { 234 | FcitxCandidateWordSetPage(candList, 0); 235 | candWord = FcitxCandidateWordGetCurrentWindow(candList); 236 | } else { 237 | FcitxCandidateWordSetFocus( 238 | candList, FcitxCandidateWordGetIndex(candList, 239 | candWord)); 240 | } 241 | } else if (FcitxHotkeyIsHotKey(sym, state, config->prevWord)) { 242 | candWord = FcitxCandidateWordGetFocus(candList, true); 243 | candWord = FcitxCandidateWordGetPrev(candList, candWord); 244 | if (!candWord) { 245 | candWord = FcitxCandidateWordGetLast(candList); 246 | } 247 | FcitxCandidateWordSetFocus( 248 | candList, FcitxCandidateWordGetIndex(candList, 249 | candWord)); 250 | } 251 | if (candWord) { 252 | FcitxCandidateWordSetType(candWord, MSG_CANDIATE_CURSOR); 253 | return IRV_FLAG_UPDATE_INPUT_WINDOW; 254 | } 255 | 256 | if (FcitxHotkeyIsHotKeyDigit(sym, state)) 257 | return IRV_TO_PROCESS; 258 | 259 | if (FcitxHotkeyIsHotKey(sym, state , FCITX_ENTER)) { 260 | do { 261 | candWord = FcitxCandidateWordGetFocus(candList, true); 262 | if (!candWord) { 263 | break; 264 | } 265 | // FcitxLog(INFO, "%d", FcitxCandidateWordGetIndex(candList, candWord)); 266 | return FcitxCandidateWordChooseByTotalIndex(candList, 267 | FcitxCandidateWordGetIndex(candList, candWord)); 268 | } while(0); 269 | return FcitxCandidateWordChooseByIndex(candList, 0); 270 | } 271 | 272 | if (!hangul->fh.hanjaMode) { 273 | FcitxHangulCleanLookupTable(hangul); 274 | } 275 | } 276 | 277 | s = FcitxKeyState_Ctrl | FcitxKeyState_Alt | FcitxKeyState_Shift | FcitxKeyState_Super | FcitxKeyState_Hyper; 278 | if (state & s) { 279 | FcitxHangulFlush (hangul); 280 | FcitxHangulUpdatePreedit(hangul); 281 | FcitxUIUpdateInputWindow(hangul->owner); 282 | return IRV_TO_PROCESS; 283 | } 284 | 285 | bool keyUsed = false; 286 | if (FcitxHotkeyIsHotKey(sym, state, FCITX_BACKSPACE)) { 287 | keyUsed = hangul_ic_backspace (hangul->ic); 288 | if (!keyUsed) { 289 | unsigned int preedit_len = ustring_length (hangul->preedit); 290 | if (preedit_len > 0) { 291 | ustring_erase (hangul->preedit, preedit_len - 1, 1); 292 | keyUsed = true; 293 | } 294 | } 295 | } else { 296 | if (ustring_length(hangul->preedit) >= MAX_LENGTH) { 297 | FcitxHangulFlush(hangul); 298 | } 299 | 300 | keyUsed = hangul_ic_process(hangul->ic, sym); 301 | boolean notFlush = false; 302 | 303 | const ucschar* str = hangul_ic_get_commit_string (hangul->ic); 304 | if (hangul->fh.wordCommit || hangul->fh.hanjaMode) { 305 | const ucschar* hic_preedit; 306 | 307 | hic_preedit = hangul_ic_get_preedit_string (hangul->ic); 308 | if (hic_preedit != NULL && hic_preedit[0] != 0) { 309 | ustring_append_ucs4 (hangul->preedit, str); 310 | } else { 311 | ustring_append_ucs4 (hangul->preedit, str); 312 | if (ustring_length (hangul->preedit) > 0) { 313 | char* commit = FcitxHangulUcs4ToUtf8(hangul, ustring_begin(hangul->preedit), ustring_length(hangul->preedit)); 314 | if (commit) { 315 | FcitxInstanceCleanInputWindowUp(hangul->owner); 316 | size_t len = fcitx_utf8_strlen(commit); 317 | if (len > 0) { 318 | char* p = fcitx_utf8_get_nth_char(commit, len - 1); 319 | if ((strcmp(p, "`") == 0 && FcitxHotkeyIsHotKey(sym, state, FCITX_HANGUL_GRAVE)) 320 | || (strcmp(p, ";") == 0 && FcitxHotkeyIsHotKey(sym, state, FCITX_SEMICOLON))) { 321 | keyUsed = false; 322 | notFlush = true; 323 | *p = 0; 324 | } 325 | } 326 | FcitxInstanceCommitString(hangul->owner, FcitxInstanceGetCurrentIC(hangul->owner), commit); 327 | free(commit); 328 | } 329 | } 330 | ustring_clear (hangul->preedit); 331 | } 332 | } else { 333 | if (str != NULL && str[0] != 0) { 334 | char* commit = FcitxHangulUcs4ToUtf8(hangul, str, -1); 335 | if (commit) { 336 | FcitxInstanceCleanInputWindowUp(hangul->owner); 337 | if ((strcmp(commit, "`") == 0 && FcitxHotkeyIsHotKey(sym, state, FCITX_HANGUL_GRAVE)) 338 | || (strcmp(commit, ";") == 0 && FcitxHotkeyIsHotKey(sym, state, FCITX_SEMICOLON))) { 339 | keyUsed = false; 340 | notFlush = true; 341 | } 342 | else { 343 | FcitxInstanceCommitString(hangul->owner, FcitxInstanceGetCurrentIC(hangul->owner), commit); 344 | } 345 | free(commit); 346 | } 347 | } 348 | } 349 | 350 | FcitxHangulGetCandWords(hangul); 351 | FcitxUIUpdateInputWindow(hangul->owner); 352 | if (!keyUsed && !notFlush) 353 | FcitxHangulFlush (hangul); 354 | } 355 | 356 | if (!keyUsed) 357 | return IRV_TO_PROCESS; 358 | else 359 | return IRV_DISPLAY_CANDWORDS; 360 | } 361 | 362 | void FcitxHangulUpdatePreedit(FcitxHangul* hangul) 363 | { 364 | FcitxInputState* input = FcitxInstanceGetInputState(hangul->owner); 365 | FcitxMessages* preedit = FcitxInputStateGetPreedit(input); 366 | FcitxMessages* clientPreedit = FcitxInputStateGetClientPreedit(input); 367 | FcitxInstanceCleanInputWindowUp(hangul->owner); 368 | FcitxInputStateSetShowCursor(input, true); 369 | const ucschar *hic_preedit = hangul_ic_get_preedit_string (hangul->ic); 370 | 371 | char* pre1 = FcitxHangulUcs4ToUtf8(hangul, ustring_begin(hangul->preedit), ustring_length(hangul->preedit)); 372 | char* pre2 = FcitxHangulUcs4ToUtf8(hangul, hic_preedit, -1); 373 | FcitxInputContext* ic = FcitxInstanceGetCurrentIC(hangul->owner); 374 | FcitxProfile* profile = FcitxInstanceGetProfile(hangul->owner); 375 | 376 | size_t preeditLen = 0; 377 | 378 | boolean clientPreeditNotAvail = (ic && ((ic->contextCaps & CAPACITY_PREEDIT) == 0 || !profile->bUsePreedit)); 379 | 380 | if (pre1 && pre1[0] != 0) { 381 | size_t len1 = strlen(pre1); 382 | if (clientPreeditNotAvail) 383 | FcitxMessagesAddMessageAtLast(preedit, MSG_INPUT, "%s", pre1); 384 | FcitxMessagesAddMessageAtLast(clientPreedit, MSG_INPUT, "%s", pre1); 385 | preeditLen += len1; 386 | } 387 | 388 | if (pre2 && pre2[0] != '\0') { 389 | size_t len2 = strlen(pre2); 390 | if (clientPreeditNotAvail) 391 | FcitxMessagesAddMessageAtLast(preedit, MSG_INPUT | MSG_HIGHLIGHT, "%s", pre2); 392 | FcitxMessagesAddMessageAtLast(clientPreedit, MSG_INPUT | MSG_HIGHLIGHT, "%s", pre2); 393 | preeditLen += len2; 394 | } 395 | 396 | FcitxInputStateSetCursorPos(input, clientPreeditNotAvail ? preeditLen : 0); 397 | FcitxInputStateSetClientCursorPos(input, preeditLen); 398 | 399 | if (pre1) 400 | free(pre1); 401 | 402 | if (pre2) 403 | free(pre2); 404 | } 405 | 406 | HanjaList* FcitxHangulLookupTable(FcitxHangul* hangul, const char* key, int method) 407 | { 408 | HanjaList* list = NULL; 409 | 410 | if (key == NULL) 411 | return NULL; 412 | 413 | switch (method) { 414 | case LOOKUP_METHOD_EXACT: 415 | if (hangul->symbolTable != NULL) 416 | list = hanja_table_match_exact (hangul->symbolTable, key); 417 | 418 | if (list == NULL) 419 | list = hanja_table_match_exact (hangul->table, key); 420 | 421 | break; 422 | case LOOKUP_METHOD_PREFIX: 423 | if (hangul->symbolTable != NULL) 424 | list = hanja_table_match_prefix (hangul->symbolTable, key); 425 | 426 | if (list == NULL) 427 | list = hanja_table_match_prefix (hangul->table, key); 428 | 429 | break; 430 | case LOOKUP_METHOD_SUFFIX: 431 | if (hangul->symbolTable != NULL) 432 | list = hanja_table_match_suffix (hangul->symbolTable, key); 433 | 434 | if (list == NULL) 435 | list = hanja_table_match_suffix (hangul->table, key); 436 | 437 | break; 438 | } 439 | 440 | return list; 441 | } 442 | 443 | #define FCITX_HANGUL_MAX(a, b) ((a) > (b)? (a) : (b)) 444 | #define FCITX_HANGUL_MIN(a, b) ((a) < (b)? (a) : (b)) 445 | #define FCITX_HANGUL_ABS(a) ((a) >= (0)? (a) : -(a)) 446 | 447 | static char* 448 | GetSubstring (const char* str, long p1, long p2) 449 | { 450 | const char* begin; 451 | const char* end; 452 | char* substring; 453 | long limit; 454 | long pos; 455 | long n; 456 | 457 | if (str == NULL || str[0] == '\0') 458 | return NULL; 459 | 460 | limit = strlen(str) + 1; 461 | 462 | p1 = FCITX_HANGUL_MAX(0, p1); 463 | p2 = FCITX_HANGUL_MAX(0, p2); 464 | 465 | pos = FCITX_HANGUL_MIN(p1, p2); 466 | n = FCITX_HANGUL_ABS(p2 - p1); 467 | 468 | if (pos + n > limit) 469 | n = limit - pos; 470 | 471 | begin = fcitx_utf8_get_nth_char ((char*)str, pos); 472 | end = fcitx_utf8_get_nth_char ((char*)begin, n); 473 | 474 | substring = strndup (begin, end - begin); 475 | return substring; 476 | } 477 | 478 | void FcitxHangulCleanLookupTable(FcitxHangul* hangul) { 479 | FcitxInstanceCleanInputWindowDown(hangul->owner); 480 | // FcitxUIUpdateInputWindow(hangul->owner); 481 | FcitxHangulFreeHanjaList(hangul); 482 | } 483 | 484 | void FcitxHangulUpdateLookupTable(FcitxHangul* hangul, boolean checkSurrounding) 485 | { 486 | char* surroundingStr = NULL; 487 | char* utf8; 488 | char* hanjaKey = NULL; 489 | LookupMethod lookupMethod = LOOKUP_METHOD_PREFIX; 490 | const ucschar* hic_preedit; 491 | UString* preedit; 492 | unsigned int cursorPos; 493 | unsigned int anchorPos; 494 | 495 | FcitxHangulFreeHanjaList(hangul); 496 | 497 | hic_preedit = hangul_ic_get_preedit_string (hangul->ic); 498 | 499 | preedit = ustring_dup (hangul->preedit); 500 | ustring_append_ucs4 (preedit, hic_preedit); 501 | if (ustring_length(preedit) > 0) { 502 | utf8 = FcitxHangulUcs4ToUtf8 (hangul, ustring_begin(preedit), ustring_length(preedit)); 503 | if (hangul->fh.wordCommit || hangul->fh.hanjaMode) { 504 | hanjaKey = utf8; 505 | lookupMethod = LOOKUP_METHOD_PREFIX; 506 | } else { 507 | char* substr; 508 | FcitxInstanceGetSurroundingText(hangul->owner, FcitxInstanceGetCurrentIC(hangul->owner), &surroundingStr, &cursorPos, &anchorPos); 509 | 510 | substr = GetSubstring (surroundingStr, (long) cursorPos - 64, cursorPos); 511 | 512 | if (substr != NULL) { 513 | asprintf(&hanjaKey, "%s%s", substr, utf8); 514 | free (utf8); 515 | free (substr); 516 | } else { 517 | hanjaKey = utf8; 518 | } 519 | lookupMethod = LOOKUP_METHOD_SUFFIX; 520 | } 521 | } else { 522 | if (checkSurrounding) { 523 | FcitxInstanceGetSurroundingText(hangul->owner, FcitxInstanceGetCurrentIC(hangul->owner), &surroundingStr, &cursorPos, &anchorPos); 524 | if (cursorPos != anchorPos) { 525 | // If we have selection in surrounding text, we use that. 526 | hanjaKey = GetSubstring(surroundingStr, cursorPos, anchorPos); 527 | lookupMethod = LOOKUP_METHOD_EXACT; 528 | } else { 529 | hanjaKey = GetSubstring (surroundingStr, (long) cursorPos - 64, cursorPos); 530 | lookupMethod = LOOKUP_METHOD_SUFFIX; 531 | } 532 | } 533 | } 534 | 535 | if (hanjaKey != NULL) { 536 | hangul->hanjaList = FcitxHangulLookupTable (hangul, hanjaKey, lookupMethod); 537 | hangul->lastLookupMethod = lookupMethod; 538 | free (hanjaKey); 539 | } 540 | ustring_delete (preedit); 541 | 542 | if (surroundingStr) 543 | free(surroundingStr); 544 | 545 | if (hangul->hanjaList) { 546 | HanjaList* list = hangul->hanjaList; 547 | if (list != NULL) { 548 | int i, n; 549 | n = hanja_list_get_size (list); 550 | 551 | FcitxInputState* input = FcitxInstanceGetInputState(hangul->owner); 552 | FcitxCandidateWordList* candList = FcitxInputStateGetCandidateList(input); 553 | FcitxGlobalConfig* config = FcitxInstanceGetGlobalConfig(hangul->owner); 554 | FcitxCandidateWordSetPageSize(candList, config->iMaxCandWord); 555 | FcitxCandidateWordSetChoose(candList, "1234567890"); 556 | FcitxCandidateWord word; 557 | FcitxCandidateWordReset(candList); 558 | for (i = 0; i < n; i++) { 559 | const char* value = hanja_list_get_nth_value (list, i); 560 | unsigned int* idx = fcitx_utils_malloc0(sizeof(unsigned int)); 561 | *idx = i; 562 | word.strWord = strdup(value); 563 | word.wordType = (i == 0) ? MSG_CANDIATE_CURSOR : MSG_INPUT; 564 | word.strExtra = NULL; 565 | word.extraType = MSG_INPUT; 566 | word.priv = idx; 567 | word.owner = hangul; 568 | word.callback = FcitxHangulGetCandWord; 569 | FcitxCandidateWordAppend(candList, &word); 570 | } 571 | 572 | FcitxCandidateWordSetFocus(candList, 0); 573 | } 574 | } 575 | } 576 | 577 | void FcitxHangulFlush(FcitxHangul* hangul) 578 | { 579 | const ucschar *str; 580 | 581 | FcitxHangulCleanLookupTable(hangul); 582 | 583 | str = hangul_ic_flush (hangul->ic); 584 | 585 | ustring_append_ucs4 (hangul->preedit, str); 586 | 587 | if (ustring_length (hangul->preedit) == 0) 588 | return; 589 | 590 | str = ustring_begin (hangul->preedit); 591 | char* utf8 = FcitxHangulUcs4ToUtf8(hangul, str, ustring_length(hangul->preedit)); 592 | if (utf8) { 593 | FcitxInstanceCommitString(hangul->owner, FcitxInstanceGetCurrentIC(hangul->owner), utf8); 594 | free(utf8); 595 | } 596 | 597 | ustring_clear(hangul->preedit); 598 | } 599 | 600 | boolean FcitxHangulInit(void* arg) 601 | { 602 | FcitxHangul* hangul = (FcitxHangul*) arg; 603 | boolean flag = true; 604 | FcitxInstanceSetContext(hangul->owner, CONTEXT_IM_KEYBOARD_LAYOUT, "us"); 605 | FcitxInstanceSetContext(hangul->owner, CONTEXT_DISABLE_AUTO_FIRST_CANDIDATE_HIGHTLIGHT, &flag); 606 | return true; 607 | } 608 | 609 | 610 | /** 611 | * @brief function DoInput has done everything for us. 612 | * 613 | * @param searchMode 614 | * @return INPUT_RETURN_VALUE 615 | **/ 616 | INPUT_RETURN_VALUE FcitxHangulGetCandWords(void* arg) 617 | { 618 | FcitxHangul* hangul = (FcitxHangul* )arg; 619 | FcitxHangulUpdatePreedit(hangul); 620 | 621 | if (hangul->fh.hanjaMode) { 622 | FcitxHangulUpdateLookupTable(hangul, false); 623 | } else { 624 | FcitxHangulCleanLookupTable(hangul); 625 | } 626 | 627 | return IRV_DISPLAY_CANDWORDS; 628 | } 629 | 630 | /** 631 | * @brief get the candidate word by index 632 | * 633 | * @param iIndex index of candidate word 634 | * @return the string of canidate word 635 | **/ 636 | INPUT_RETURN_VALUE FcitxHangulGetCandWord (void* arg, FcitxCandidateWord* candWord) 637 | { 638 | FcitxHangul* hangul = (FcitxHangul* )arg; 639 | unsigned int pos = *(unsigned int*) candWord->priv; 640 | const char* key; 641 | const char* value; 642 | const ucschar* hic_preedit; 643 | int key_len; 644 | int preedit_len; 645 | int hic_preedit_len; 646 | 647 | key = hanja_list_get_nth_key (hangul->hanjaList, pos); 648 | value = hanja_list_get_nth_value (hangul->hanjaList, pos); 649 | hic_preedit = hangul_ic_get_preedit_string (hangul->ic); 650 | 651 | if (!key || !value || !hic_preedit) 652 | return IRV_CLEAN; 653 | 654 | // FcitxLog(INFO, "%s", key); 655 | key_len = fcitx_utf8_strlen(key); 656 | preedit_len = ustring_length(hangul->preedit); 657 | hic_preedit_len = ucs4_strlen (hic_preedit); 658 | 659 | boolean surrounding = false; 660 | if (hangul->lastLookupMethod == LOOKUP_METHOD_PREFIX) { 661 | if (preedit_len == 0 && hic_preedit_len == 0) { 662 | /* remove surrounding_text */ 663 | if (key_len > 0) { 664 | FcitxInstanceDeleteSurroundingText (hangul->owner, FcitxInstanceGetCurrentIC(hangul->owner), -key_len , key_len); 665 | surrounding = true; 666 | } 667 | } else { 668 | /* remove preedit text */ 669 | if (key_len > 0) { 670 | long n = FCITX_HANGUL_MIN(key_len, preedit_len); 671 | ustring_erase (hangul->preedit, 0, n); 672 | key_len -= preedit_len; 673 | } 674 | 675 | /* remove hic preedit text */ 676 | if (key_len > 0) { 677 | hangul_ic_reset (hangul->ic); 678 | key_len -= hic_preedit_len; 679 | } 680 | } 681 | } else { 682 | /* remove hic preedit text */ 683 | if (hic_preedit_len > 0) { 684 | hangul_ic_reset (hangul->ic); 685 | key_len -= hic_preedit_len; 686 | } 687 | 688 | /* remove ibus preedit text */ 689 | if (key_len > preedit_len) { 690 | ustring_erase (hangul->preedit, 0, preedit_len); 691 | key_len -= preedit_len; 692 | } else if (key_len > 0) { 693 | ustring_erase (hangul->preedit, 0, key_len); 694 | key_len = 0; 695 | } 696 | 697 | /* remove surrounding_text */ 698 | if (LOOKUP_METHOD_EXACT != hangul->lastLookupMethod && key_len > 0) { 699 | FcitxInstanceDeleteSurroundingText (hangul->owner, FcitxInstanceGetCurrentIC(hangul->owner), -key_len , key_len); 700 | surrounding = true; 701 | } 702 | } 703 | 704 | FcitxInstanceCommitString(hangul->owner, FcitxInstanceGetCurrentIC(hangul->owner), value); 705 | if (surrounding) { 706 | FcitxInstanceCleanInputWindowUp(hangul->owner); 707 | FcitxHangulCleanLookupTable(hangul); 708 | return IRV_DISPLAY_MESSAGE; 709 | } 710 | else { 711 | return IRV_DISPLAY_CANDWORDS; 712 | } 713 | } 714 | 715 | /** 716 | * @brief initialize the extra input method 717 | * 718 | * @param arg 719 | * @return successful or not 720 | **/ 721 | void* FcitxHangulCreate (FcitxInstance* instance) 722 | { 723 | FcitxHangul* hangul = (FcitxHangul*) fcitx_utils_malloc0(sizeof(FcitxHangul)); 724 | bindtextdomain("fcitx-hangul", LOCALEDIR); 725 | bind_textdomain_codeset("fcitx-hangul", "UTF-8"); 726 | hangul->owner = instance; 727 | hangul->lastLookupMethod = LOOKUP_METHOD_PREFIX; 728 | if (!LoadHangulConfig(&hangul->fh)) 729 | { 730 | free(hangul); 731 | return NULL; 732 | } 733 | 734 | hangul->conv = iconv_open("UTF-8", "UCS-4LE"); 735 | hangul->preedit = ustring_new(); 736 | 737 | ConfigHangul(hangul); 738 | 739 | hangul->table = hanja_table_load(NULL); 740 | char* path; 741 | FILE* fp = FcitxXDGGetFileWithPrefix("hangul", "symbol.txt", "r", &path); 742 | if (fp) 743 | fclose(fp); 744 | hangul->symbolTable = hanja_table_load ( path ); 745 | 746 | free(path); 747 | 748 | hangul->ic = hangul_ic_new(keyboard[hangul->fh.keyboardLayout]); 749 | hangul_ic_connect_callback (hangul->ic, "transition", 750 | FcitxHangulOnTransition, hangul); 751 | 752 | FcitxIMIFace iface; 753 | memset(&iface, 0, sizeof(FcitxIMIFace)); 754 | iface.Init = FcitxHangulInit; 755 | iface.ResetIM = FcitxHangulReset; 756 | iface.DoInput = FcitxHangulDoInput; 757 | iface.GetCandWords = FcitxHangulGetCandWords; 758 | iface.ReloadConfig = ReloadConfigFcitxHangul; 759 | iface.OnClose = FcitxHangulOnClose; 760 | 761 | FcitxInstanceRegisterIMv2(instance, 762 | hangul, 763 | "hangul", 764 | _("Hangul"), 765 | "hangul", 766 | iface, 767 | 5, 768 | "ko" 769 | ); 770 | 771 | FcitxIMEventHook hk; 772 | hk.arg = hangul; 773 | hk.func = FcitxHangulResetEvent; 774 | 775 | FcitxInstanceRegisterResetInputHook(instance, hk); 776 | 777 | FcitxUIRegisterStatus( 778 | instance, 779 | hangul, 780 | "hanja", 781 | "", 782 | "", 783 | FcitxHangulToggleHanja, 784 | FcitxHangulGetHanja 785 | ); 786 | 787 | FcitxHangulUpdateHanjaStatus(hangul); 788 | 789 | return hangul; 790 | } 791 | 792 | void FcitxHangulOnClose(void* arg, FcitxIMCloseEventType event) 793 | { 794 | FcitxHangul* hangul = arg; 795 | if (event == CET_LostFocus) { 796 | } else if (event == CET_ChangeByInactivate) { 797 | FcitxHangulFlush(hangul); 798 | } else if (event == CET_ChangeByUser) { 799 | FcitxHangulFlush(hangul); 800 | } 801 | } 802 | 803 | 804 | void FcitxHangulToggleHanja(void* arg) 805 | { 806 | FcitxHangul* hangul = (FcitxHangul*) arg; 807 | hangul->fh.hanjaMode = !hangul->fh.hanjaMode; 808 | FcitxHangulUpdateHanjaStatus(hangul); 809 | SaveHangulConfig(&hangul->fh); 810 | } 811 | 812 | void FcitxHangulUpdateHanjaStatus(FcitxHangul* hangul) 813 | { 814 | if (hangul->fh.hanjaMode) { 815 | FcitxUISetStatusString(hangul->owner, "hanja", "\xe9\x9f\x93", _("Use Hanja")); 816 | } 817 | else { 818 | FcitxUISetStatusString(hangul->owner, "hanja", "\xed\x95\x9c", _("Use Hangul")); 819 | } 820 | FcitxHangulFlush(hangul); 821 | FcitxHangulUpdatePreedit(hangul); 822 | FcitxUIUpdateInputWindow(hangul->owner); 823 | } 824 | 825 | boolean FcitxHangulGetHanja(void* arg) 826 | { 827 | FcitxHangul* hangul = (FcitxHangul*) arg; 828 | return hangul->fh.hanjaMode; 829 | } 830 | 831 | /** 832 | * @brief Destroy the input method while unload it. 833 | * 834 | * @return int 835 | **/ 836 | void FcitxHangulDestroy (void* arg) 837 | { 838 | FcitxHangul* hangul = (FcitxHangul*) arg; 839 | hanja_table_delete(hangul->table); 840 | 841 | hanja_table_delete(hangul->symbolTable); 842 | free(arg); 843 | } 844 | 845 | /** 846 | * @brief Load the config file for fcitx-hangul 847 | * 848 | * @param Bool is reload or not 849 | **/ 850 | boolean LoadHangulConfig(FcitxHangulConfig* fs) 851 | { 852 | FcitxConfigFileDesc *configDesc = GetHangulConfigDesc(); 853 | if (!configDesc) 854 | return false; 855 | 856 | FILE *fp = FcitxXDGGetFileUserWithPrefix("conf", "fcitx-hangul.config", "r", NULL); 857 | 858 | if (!fp) 859 | { 860 | if (errno == ENOENT) 861 | SaveHangulConfig(fs); 862 | } 863 | FcitxConfigFile *cfile = FcitxConfigParseConfigFileFp(fp, configDesc); 864 | 865 | FcitxHangulConfigConfigBind(fs, cfile, configDesc); 866 | FcitxConfigBindSync(&fs->gconfig); 867 | 868 | if (fp) 869 | fclose(fp); 870 | return true; 871 | } 872 | 873 | void ConfigHangul(FcitxHangul* hangul) 874 | { 875 | FcitxLog(DEBUG, "Hangul Layout: %s", keyboard[hangul->fh.keyboardLayout]); 876 | hangul_ic_select_keyboard(hangul->ic, keyboard[hangul->fh.keyboardLayout]); 877 | } 878 | 879 | void ReloadConfigFcitxHangul(void* arg) 880 | { 881 | FcitxHangul* hangul = (FcitxHangul*) arg; 882 | LoadHangulConfig(&hangul->fh); 883 | ConfigHangul(hangul); 884 | } 885 | 886 | /** 887 | * @brief Save the config 888 | * 889 | * @return void 890 | **/ 891 | void SaveHangulConfig(FcitxHangulConfig* fa) 892 | { 893 | FcitxConfigFileDesc *configDesc = GetHangulConfigDesc(); 894 | FILE *fp = FcitxXDGGetFileUserWithPrefix("conf", "fcitx-hangul.config", "w", NULL); 895 | FcitxConfigSaveConfigFileFp(fp, &fa->gconfig, configDesc); 896 | if (fp) 897 | fclose(fp); 898 | } 899 | 900 | void FcitxHangulResetEvent(void* arg) 901 | { 902 | FcitxHangul* hangul = (FcitxHangul*) arg; 903 | FcitxIM* im = FcitxInstanceGetCurrentIM(hangul->owner); 904 | if (!im || strcmp(im->uniqueName, "hangul") != 0) { 905 | FcitxUISetStatusVisable(hangul->owner, "hanja", false); 906 | } 907 | else { 908 | FcitxUISetStatusVisable(hangul->owner, "hanja", true); 909 | } 910 | } 911 | --------------------------------------------------------------------------------