CN101968685A - Character conversion method - Google Patents
Character conversion method Download PDFInfo
- Publication number
- CN101968685A CN101968685A CN2010105227634A CN201010522763A CN101968685A CN 101968685 A CN101968685 A CN 101968685A CN 2010105227634 A CN2010105227634 A CN 2010105227634A CN 201010522763 A CN201010522763 A CN 201010522763A CN 101968685 A CN101968685 A CN 101968685A
- Authority
- CN
- China
- Prior art keywords
- english
- input method
- chinese
- character
- character string
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Images
Landscapes
- Document Processing Apparatus (AREA)
- Input From Keyboards Or The Like (AREA)
Abstract
The invention relates to a character conversion method for a computer input method. At present, when a computer is used, a user frequently switches between a Chinese input method and an English input method; and a Chinese input method is provided at present and can switch Chinese into English, however, in actual use, an English input method at present cannot switch the clicked English into Chinese. The method provided by the invention solves the problem that input English characters are converted into Chinese under the condition of not opening the Chinese input method in advance. The method comprises the following steps of: 1, inputting an English character string; 2, awakening a non English input method; 3, installing a HOOK program; 4, selecting the English character string by using a cursor; 5, grabbing the English character string; and 6, fetching words from a work bank by using the non English input method. Through the method, the input English characters can be converted into Chinese for output in the English input state of the computer.
Description
Affiliated field
The present invention relates to a kind of character conversion method, especially related to computer input method.
Background technology
Chinese character coding input method also claims input method of Chinese character, is meant the coding method of Chinese character being imported equipment such as computer or mobile phone and adopting, and is the important technology of Chinese information processing.Chinese character coding input method generally is to refer in particular to the inputting method of Chinese.Chinese character coding input method grew up from the 1980's, and computor-keyboard can not be made a button for each Chinese character.Therefore, people need replace Chinese character, compile input code, promptly import a Chinese character with several keys.
In present computer uses, people often want frequent switching between the Chinese and English input method, in order to solve this operation inconvenience, the Chinese character coding input method of seeing at present provides a kind of method, typing character after opening Chinese character coding input method confirms that by knocking different keys the character of being keyed in is English input or input in Chinese, as: common opens the back input character in Chinese character coding input method, knock space bar and be input in Chinese, knock enter key and be English input.
The prerequisite of above-mentioned this method is, must open Chinese character coding input method earlier, yet, in the use of reality, we are in the environment of not opening Chinese character coding input method, and the content that wants to be knocked is carried out Chinese and English and switched, and present Chinese character coding input method just can't realize.
Summary of the invention
The purpose of invention: provide a kind of input method character conversion to change method, do not opening in advance in the environment of Chinese character coding input method, the English character of being keyed in is converted to the application need of Chinese to solve.
The technical scheme that invention is adopted: the method for character conversion comprises the steps:
The input of step 1 English character string
The non-English input method of step 2 wakes up
Step 3 is installed HOOK hook program
The step 4 cursor is chosen the English character string
Step 5 grasps the English character string
Speech got in the non-English input method dictionary of step 6
Wherein said non-English input method is Chinese character coding input method preferably, and described HOOK hook program can be a keyboard hook program, also can be mouse hook program.
Computing machine user original idea will be imported Chinese, but actual key entry is English character, this computer-chronograph user does not need to delete the English character of having keyed in, but by using the good shortcut of preset in advance, wake its employed Chinese character coding input method up, at this moment input method character conversion program will be by HOOK hook sequential monitoring cursor the moving on whole screen of mouse or keyboard, the user controls cursor and chooses those will convert the English character of Chinese to, at this moment because variation has taken place in cursor position, mouse HOOK will be called, it judge mouse produced move after, will send message to the Chinese character coding input method program, variation has taken place in notice Chinese character coding input method program mouse position.After the Chinese character coding input method program is received message, the Chinese character coding input method program can be carried out the retrieval of Chinese character with the English character string that obtains in the character library of input method, after input method retrieves effective English character string input, all Chinese characters of this English character string correspondence can be shown in the character reminding frame of input method.
The beneficial effect of the invention: the present invention has changed traditional natural mode, promptly can only open under the environment of Chinese character coding input method, the Chinese and English that can carry out character switches, method provided by the invention, making computer under English input state---English input is that in fact frequency of utilization is maximum, the input state of acquiescence, the English character that does not need to have keyed in deletes, and then opens the trouble that Chinese character coding input method is re-entered the character that deleted just now again.Directly use method of the present invention, just can switch to Chinese output the English character of keying in.
Description of drawings
Fig. 1 gets the process flow diagram of speech method for the present invention.
Embodiment
Referring to accompanying drawing one
Step 1, the input of English character string
Step 2, Chinese character coding input method are waken up: the user wakes Chinese character coding input method up by shortcut (as the Shift+Ctrl Macintosh).
Step 3, installation HOOK: the function that HOOK is installed can offer the Chinese character coding input method routine call with the form in DLL storehouse, after Chinese input method is waken up, the mouse HOOK of a WH_MOUSE type at first can be installed, by this mouse HOOK, Chinese character coding input method just can monitor cursor having moved on whole screen.
Step 4, choose the English character string: the user chooses the English character string on the notepad with cursor, at this moment because variation has taken place in cursor position, mouse HOOK will be called, it judge mouse produced move after, will send message to the Chinese character coding input method program, variation has taken place in notice Chinese character coding input method program mouse position.
After the Chinese character coding input method program is received message, timer can be set, monitor the length of mouse in a certain position residence time.If mouse stops the time (as 1 second) that has surpassed certain setting, the Chinese character coding input method program will start " grasping the English character string " function, function keeps illegal state otherwise " grasp the English character string ", and the purpose of doing like this is to reduce the influence of character string extracting to system performance as far as possible.
Step 5, extracting English character string: the function that grasps the English character string can offer the Chinese character coding input method routine call with the form in DLL storehouse, when mouse after certain position residence time surpasses setting-up time, Chinese character coding input method is by calling the DLL storehouse of grasping English character string function, on the mouse position, create a wicket, hide this window then rapidly, will make the window area of mouse position produce inactive area like this, at this moment call the UpdateWindow function again and send WM_PAINT message, force wicket to carry out screen-refresh to wicket.In carrying out the process of screen-refresh, can call wicket the character string that characters output API such as ExtTextOut, TextOut upgrade the inactive area the inside.At this moment in the DLL storehouse of grasping English character string function, can get access to the address of these character output API, the entry instruction of these API can be revised in the DLL storehouse then, making wicket, actual what call is the alternative functions of the character output API that realizes in the DLL storehouse, in these alternative functions, can obtain the various parameters that the fenestella oral instructions are come in, as information such as character string address, length, output coordinate, HDC, Crop Areas, just we can obtain the actual content of English character string from these information.After alternative functions executed, the original entry instruction of character output API can be recovered in the DLL storehouse, and calls the screen-refresh that original api interface is realized wicket.
Speech got in step 6, Chinese character coding input method dictionary: after Chinese character coding input method is passed to the English character string in the DLL storehouse of extracting English character string function, the Chinese character coding input method program can be carried out the retrieval of Chinese character with the English character string that obtains in the character library of input method, after input method retrieves effective English character string input, all Chinese characters of this English character string correspondence can be shown in the character reminding frame of input method.
The Chinese character that step 7, user's selection will be imported: the user can see the prompting of many group Chinese characters in the character reminding frame of Chinese character coding input method, at this moment the user can select the Chinese character that will import by the method for clicks keyboard (0~9), Chinese character coding input method can cover the English character string of the original input of user with the Chinese character that the user selects, thereby finishes the Chinese character input.Step 8, withdraw from Chinese character coding input method: the user can withdraw from Chinese character coding input method by shortcut (as the Shift+Ctrl Macintosh).
Claims (3)
1. the method for a character conversion is characterized in that: comprise the steps:
The input of step 1 English character string
The non-English input method of step 2 wakes up
Step 3 is installed HOOK hook program
The step 4 cursor is chosen the English character string
Step 5 grasps the English character string
Speech got in the non-English input method dictionary of step 6
2. character conversion method according to claim 1 is characterized in that, described non-English input method preferably can be a Chinese character coding input method.
3. character conversion method according to claim 1 is characterized in that, described HOOK hook program can be a keyboard hook program, also can be mouse hook program.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN2010105227634A CN101968685A (en) | 2010-10-28 | 2010-10-28 | Character conversion method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN2010105227634A CN101968685A (en) | 2010-10-28 | 2010-10-28 | Character conversion method |
Publications (1)
Publication Number | Publication Date |
---|---|
CN101968685A true CN101968685A (en) | 2011-02-09 |
Family
ID=43547852
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN2010105227634A Pending CN101968685A (en) | 2010-10-28 | 2010-10-28 | Character conversion method |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN101968685A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103049098A (en) * | 2012-12-28 | 2013-04-17 | 华为技术有限公司 | Device and method for input method shifting |
-
2010
- 2010-10-28 CN CN2010105227634A patent/CN101968685A/en active Pending
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103049098A (en) * | 2012-12-28 | 2013-04-17 | 华为技术有限公司 | Device and method for input method shifting |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN103475784B (en) | A kind of application program of mobile phone window scheme display and method of operation | |
CN1201611C (en) | Communication terminal having function of prediction of edition | |
CA2572574A1 (en) | Method and arrangement for a primary action on a handheld electronic device | |
CN103037064A (en) | Individual screen unlocking method and system thereof | |
JP2009530944A (en) | Improved mobile communication terminal and method therefor | |
CN101916158A (en) | Method and device for configuring input mode according to input box of user device | |
CN102053716B (en) | Information input device with light touch retrieval-pressing confirmation function, and method | |
CN102999358A (en) | Intelligent program starting method | |
KR20100093909A (en) | Method for providing browsing history, mobile communication terminal and computer-readable recording medium with program therefor | |
CN104750378A (en) | Automatic input mode switching method and device for input method | |
CN104917904A (en) | Voice information processing method and device and electronic device | |
CN101963881A (en) | Method and system for switching icon display type and touch screen equipment | |
CN104216648A (en) | Information input method and device | |
CN103838375A (en) | Terminal input method and terminal | |
CN103475926A (en) | Input method implementation method and control system based on set top box equipment | |
CN104572512A (en) | Method and system for realizing multi-clicking functions of X-mouse button control | |
WO2014008670A1 (en) | Method and terminal for determining operation object | |
CN102736831A (en) | Input method and device applied to mobile terminal comprising virtual keyboard | |
CN101384053A (en) | Method for access corresponding function by shortcut command in mobile phone | |
CN103713813A (en) | Method for controlling functions of intelligent handheld equipment | |
CN109885236B (en) | Method for realizing interactive operation with remote system desktop based on mobile equipment | |
CN107402689B (en) | Terminal device presentation method and terminal device | |
CN101995964A (en) | Method and device for processing keyboard instruction, keyboard and terminal equipment | |
CN108737634B (en) | Voice input method and device, computer device and computer readable storage medium | |
CN202102435U (en) | Information-searching device for mobile equipment |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C02 | Deemed withdrawal of patent application after publication (patent law 2001) | ||
WD01 | Invention patent application deemed withdrawn after publication |
Application publication date: 20110209 |