diff --git a/scim-wnn/src/scim_wnn_imengine.cpp b/scim-wnn/src/scim_wnn_imengine.cpp index 6272883..d7b01f7 100644 --- a/scim-wnn/src/scim_wnn_imengine.cpp +++ b/scim-wnn/src/scim_wnn_imengine.cpp @@ -595,7 +595,7 @@ } return(true); } else - if (isprint(key.code)) { + if (key.get_ascii_code()) { if (key.mask & (SCIM_KEY_AltMask | SCIM_KEY_ControlMask)) return(false); if (m_lookup) { char numk[] = "1234567890"; @@ -650,6 +650,14 @@ return(true); } + if (k_lookup_pageup.comp(key)) { + lookup_table_page_up(); + return(true); + } else + if (k_lookup_pagedown.comp(key)) { + lookup_table_page_down(); + return(true); + } else if (k_conversion_next.comp(key) || k_conversion_prev.comp(key) || k_select_yosoku.comp(key)) { k_conversion_prev.comp(key) ? m_convList.pos --: m_convList.pos ++; if (m_convList.pos >= m_convList.count) m_convList.pos = 0; @@ -675,6 +683,17 @@ return(true); } if (!key.get_ascii_code()) return(true); + if (!(key.is_control_down() || key.is_alt_down() || key.is_shift_down())) { + char numk[] = "1234567890"; + for(int numc = 0;numk[numc]; ++ numc) { + if (key.get_ascii_code() == numk[numc]) { + if (m_lookup_table.get_current_page_size() > numc) + select_candidate((unsigned int)numc); + return(true); + } + } + } + m_yosoku = false; commit_string(m_convList.kouho.at(m_convList.pos)); m_preeditor->reset();