Changeset View
Changeset View
Standalone View
Standalone View
intern/ghost/intern/GHOST_ImeWin32.cpp
| Show First 20 Lines • Show All 82 Lines • ▼ Show 20 Lines | bool GHOST_ImeWin32::IsImeKeyEvent(char ascii, GHOST_TKey key) | ||||
| if (!(IsEnglishMode())) { | if (!(IsEnglishMode())) { | ||||
| /* In Chinese, Japanese, Korean, all alpha keys are processed by IME. */ | /* In Chinese, Japanese, Korean, all alpha keys are processed by IME. */ | ||||
| if ((ascii >= 'A' && ascii <= 'Z') || (ascii >= 'a' && ascii <= 'z')) { | if ((ascii >= 'A' && ascii <= 'Z') || (ascii >= 'a' && ascii <= 'z')) { | ||||
| return true; | return true; | ||||
| } | } | ||||
| if (IsLanguage(IMELANG_JAPANESE) && (ascii >= ' ' && ascii <= '~')) { | if (IsLanguage(IMELANG_JAPANESE) && (ascii >= ' ' && ascii <= '~')) { | ||||
| return true; | return true; | ||||
| } | } | ||||
| else if (IsLanguage(IMELANG_CHINESE) && ascii && strchr("!\"$'(),.:;<>?[\\]^_`/", ascii) && | if (IsLanguage(IMELANG_CHINESE)) { | ||||
| !(key == GHOST_kKeyNumpadPeriod)) { | if (ascii && strchr("!\"$'(),.:;<>?[\\]^_`/", ascii) && !(key == GHOST_kKeyNumpadPeriod)) { | ||||
| return true; | return true; | ||||
| } | } | ||||
| if (conversion_modes_ & IME_CMODE_FULLSHAPE && (ascii >= '0' && ascii <= '9')) { | |||||
| /* When in Full Width mode the number keys are also converted. */ | |||||
| return true; | |||||
| } | |||||
| } | |||||
| } | } | ||||
| return false; | return false; | ||||
| } | } | ||||
| void GHOST_ImeWin32::CreateImeWindow(HWND window_handle) | void GHOST_ImeWin32::CreateImeWindow(HWND window_handle) | ||||
| { | { | ||||
| /** | /** | ||||
| * When a user disables TSF (Text Service Framework) and CUAS (Cicero | * When a user disables TSF (Text Service Framework) and CUAS (Cicero | ||||
| ▲ Show 20 Lines • Show All 408 Lines • Show Last 20 Lines | |||||