CN103941979B - A kind of method and apparatus for inputting word in a mobile device - Google Patents
A kind of method and apparatus for inputting word in a mobile device Download PDFInfo
- Publication number
- CN103941979B CN103941979B CN201410143794.7A CN201410143794A CN103941979B CN 103941979 B CN103941979 B CN 103941979B CN 201410143794 A CN201410143794 A CN 201410143794A CN 103941979 B CN103941979 B CN 103941979B
- Authority
- CN
- China
- Prior art keywords
- word
- candidate
- screen
- input
- key
- 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.)
- Active
Links
Landscapes
- Input From Keyboards Or The Like (AREA)
Abstract
An embodiment of the present invention provides a kind of method and apparatus for inputting word in a mobile device, the method is included when listening to the trigger event specified, and obtains the corresponding key-press input string of word for having selected screen recently;According to the length for the word for having selected upper screen recently and the key-press input string, deleted in current interface described in selected the word that shields;Return to the input information of the corresponding candidate of the key-press input string.The embodiment of the present invention pre-saves key-press input string when shielding on selecting word, pass through trigger event, the word selected is deleted in current interface, and return to the input information of the corresponding candidate of key-press input string, reduce user to delete the word that has selected and multiple operating procedures such as re-enter, make input operation more simple and efficient, improve the efficiency of word input, and more secondary responses of the mobile equipment when user re-enters are avoided, reduce the system resources consumption of mobile equipment.
Description
Technical field
The present invention relates to the technical field of mobile equipment, more particularly to a kind of method for inputting word in a mobile device
With a kind of device for inputting word in a mobile device.
Background technology
Widely available with mobile equipment, user is commonly used mobile equipment and handles this or that, for example, chat, on
Net, hair microblogging etc., user often needs to use input method and inputs word content therewith.
Use habit is inputted according to mobile equipment, user carries out commonly using input method nine grids keyboard as shown in Figure 1
Input, it has comfortable generous thumb key, can rapidly input word content, and error rate when reducing input.
Input method system would generally carry out matching phonetic according to numeral input by user, and search corresponding word or word, then select certain
On current first screen candidate interface, other candidate characters are included by specifying function as preferred candidate text importing for a little words
On the Expansion Interface of button pop-up.It is logical such as " hello " in Fig. 1, " you dare ", " you number " and " you are dry " be preferred candidate word
Cross on the right of click " you dry " "》" button, Expansion Interface can be ejected, shows other candidate characters.
User is when word is inputted, in fact it could happen that diverts attention or position clicks on the reasons such as mistake and causes maloperation, select
It is not required word to have selected.Such as in Fig. 2, it is assumed that user what is desired is that " you dare " or other, but due to by mistake grasp
Elected " hello " carry out inputting screen.At this time, current interface only shows " hello " selected, other preferred candidate words are removed
Sell, other candidate words of Expansion Interface are also cancelled.
But the word selected due to maloperation is not that user is required, user in order to select need word,
On the one hand, it is necessary to delete the word selected, on the other hand, it is necessary to re-enter pinyin string and then go to select again.This is not only
So that user's operation is cumbersome, the efficiency of word input is reduced, and re-enters the occupancy that can increase mobile device resource.
The content of the invention
The technical problem to be solved is that provide a kind of method for inputting word in a mobile device, side for the embodiment of the present invention
Just user's operation, lifts input efficiency and reduces the occupancy of device resource.Correspondingly, the embodiment of the present invention additionally provides one kind
The device of word is inputted in a mobile device, to ensure the realization of the above method and application.To solve the above-mentioned problems,
The embodiment of the invention discloses a kind of method for inputting word in a mobile device, including:
When listening to the trigger event specified, the corresponding key-press input string of word for having selected screen recently is obtained;
According to the length for the word for having selected upper screen recently and the key-press input string, deleted in current interface described in
The word shielded in selection;
Return to the input information of the corresponding candidate of the key-press input string.
Preferably, the trigger event specified includes but not limited to following at least one:
In the specified gesture event for specifying region, the function button event specified, mobile equipment rollover event, the language specified
Sound event.
Preferably, described the step of obtaining the word corresponding key-press input string for having selected screen recently, includes:
Extraction is buffered in the heap region of mobile device memory in advance in word candidate recently, described to have selected recently
The corresponding key-press input string of word of upper screen.
Preferably, the foundation has selected the length of the word of screen and the key-press input string recently, in current interface
The step of word that screen has been selected described in middle deletion, includes:
Obtain the length for the word for having selected screen recently;
Using in InputConnection objects getTextBeforeCursor methods obtain current cursor before with institute
State the identical text information of length;
When the characters matching that the text information has selected upper screen with described, call in InputConnection classes
DeleteSurroundingText methods delete the text information.
Preferably, the input information of the candidate is included in the first screen candidate character set that current interface is shown;
It is described return to the corresponding candidate of the key-press input string word the step of include:
Search the corresponding first screen candidate character set of the key-press input string;
In first screen candidate character set described in current first screen candidate's interface display.
Preferably, the input information of the candidate is included in the first screen candidate character set that current interface is shown;
It is described return to the corresponding candidate of the key-press input string word the step of include:
The word for having selected upper screen recently is removed from the first screen candidate character set;
Other candidate characters are added in the first screen candidate character set;
First screen candidate character set after current first screen candidate's interface display with the addition of other candidate characters.
The embodiment of the invention also discloses a kind of method for inputting word in a mobile device, including:
When listening to the trigger event specified, word segmentation processing is carried out to the word for having selected upper screen recently, is inputted
Participle;
When receiving the selection instruction for the input participle, obtain the input and segment corresponding key-press input
String;
According to the length of the input participle and the key-press input string, the input participle is deleted in current interface;
Return to the input information of the corresponding candidate of the key-press input string.
Preferably, the trigger event specified includes but not limited to following at least one:
In the specified gesture event for specifying region, the function button event specified, mobile equipment rollover event, the language specified
Sound event.
Preferably, described the step of obtaining the input participle corresponding key-press input string, includes:
Extraction is buffered in the heap region of mobile device memory in advance in word candidate recently, the input participle pair
The key-press input string answered.
Preferably, the length according to the input participle and the key-press input string, delete institute in current interface
The step of stating input participle includes:
Obtain the length of the input participle;
Using in InputConnection objects getTextBeforeCursor methods obtain current cursor before with institute
State the identical text information of length;
When the text information is matched with the input participle, call in InputConnection classes
DeleteSurroundingText methods delete the text information.
Preferably, the input information of the candidate is included in the first screen candidate character set that current interface is shown;
It is described return to the corresponding candidate of the key-press input string word the step of include:
Search the corresponding first screen candidate character set of the key-press input string;
In first screen candidate character set described in current first screen candidate's interface display.
Preferably, the input information of the candidate is included in the first screen candidate character set that current interface is shown;
It is described return to the corresponding candidate of the key-press input string word the step of include:
The input participle is removed from the first screen candidate character set;
Other candidate characters are added in the first screen candidate character set;
First screen candidate character set after current first screen candidate's interface display with the addition of other candidate characters.
The embodiment of the invention also discloses a kind of device for inputting word in a mobile device, including:
First acquisition module, for when listening to the trigger event specified, obtaining the word pair for having selected screen recently
The key-press input string answered;
First removing module, for the length according to the word for having selected upper screen recently and the key-press input string, is working as
The word of screen has been selected described in being deleted in front interface;
First returns to module, for returning to the input information of the corresponding candidate of the key-press input string.
Preferably, the trigger event specified includes but not limited to following at least one:
In the specified gesture event for specifying region, the function button event specified, mobile equipment rollover event, the language specified
Sound event.
Preferably, first acquisition module includes:
First extracting sub-module, the heap region of mobile device memory is buffered in for extracting in advance in word candidate recently
In, the corresponding key-press input string of word for having selected screen recently.
Preferably, first removing module includes:
First length acquisition submodule, for obtaining the length for the word for having selected upper screen recently;
First text information acquisition submodule, for using in InputConnection classes
The text information identical with the length before getTextBeforeCursor methods acquisition current cursor;
First text information deletes submodule, in the text information and the characters matching for having selected to shield
When, call the deleteSurroundingText methods in InputConnection objects to delete the text information.
Preferably, the input information of the candidate is included in the first screen candidate character collection of current first screen candidate's interface display
Close;The first return module includes:
First searches submodule, for searching the corresponding first screen candidate character set of the key-press input string;
First display sub-module, in first screen candidate character set described in current first screen candidate's interface display.
Preferably, the input information of the candidate is included in the first screen candidate character collection of current first screen candidate's interface display
Close, the first return module includes:
First deletes submodule, for the word for having selected upper screen recently to be deleted from the preferred candidate character set
Remove;
First addition submodule, for adding other candidate characters in the first screen candidate character set;
Second display sub-module, for the first screen after with the addition of other candidate characters in current first screen candidate's interface display
Candidate character set.
The embodiment of the invention also discloses a kind of device for inputting word in a mobile device, including:
Word-dividing mode, for when listening to the trigger event specified, being segmented to the word for having selected upper screen recently
Processing, obtains input participle;
Second acquisition module, for when receiving the selection instruction for the input participle, obtaining the input point
The corresponding key-press input string of word;
Second removing module, for the length according to the input participle and the key-press input string, in current interface
Delete the input participle;
Second returns to module, for returning to the input information of the corresponding candidate of the key-press input string.
Preferably, the trigger event specified includes but not limited to following at least one:
In the specified gesture event for specifying region, the function button event specified, mobile equipment rollover event, the language specified
Sound event.
Preferably, second acquisition module includes:
Second extracting sub-module, the heap region of mobile device memory is buffered in for extracting in advance in word candidate recently
In, the input segments corresponding key-press input string.
Preferably, second removing module includes:
Second length acquisition submodule, for obtaining the length of the input participle;
Second text information acquisition submodule, for using in InputConnection classes
The text information identical with the length before getTextBeforeCursor methods acquisition current cursor;
Second text information deletes submodule, for when the text information is matched with the input participle, calling
DeleteSurroundingText methods in InputConnection objects delete the text information.
Preferably, the input information of the candidate is included in the first screen candidate character collection of current first screen candidate's interface display
Close;The second return module includes:
Second searches submodule, for searching the corresponding first screen candidate character set of the key-press input string;
3rd display sub-module, in first screen candidate character set described in current first screen candidate's interface display.
Preferably, the input information of the candidate is included in the first screen candidate character collection of current first screen candidate's interface display
Close, the second return module includes:
Second deletes submodule, for the input participle to be removed from the candidate character set;
Second addition submodule, for adding other candidate characters in the first screen candidate character set;
4th display sub-module, for the first screen after with the addition of other candidate characters in current first screen candidate's interface display
Candidate character set.
Compared with prior art, the embodiment of the present invention includes advantages below:
The embodiment of the present invention pre-saves key-press input string when shielding on selecting word, by trigger event, is working as prezone
The word selected is deleted in face, and returns to the input information of the corresponding candidate of key-press input string, reduces user and deletes
The word of selection and multiple operating procedures such as re-enter, make input operation more simple and efficient, improve the effect of word input
Rate, and more secondary responses of the mobile equipment when user re-enters are avoided, reduce the system resources consumption of mobile equipment.
Further, the embodiment of the present invention is moved the word selected using negative sense frequency modulation by the hint of user's operation
Go out current first screen candidate's interface display, that is, eliminate unwanted candidate character, improve the time needed in current interface display
The probability of selection word, further increases the efficiency of word input.
Further, the embodiment of the present invention pre-saves key-press input string when shielding on selecting word, in input long word
When there is maloperation, by trigger event, long word is segmented, the input participle of user's selection is deleted in current interface,
And return to the input information of the corresponding candidate of key-press input string, reduce user's deletion input participle and re-enter etc. and is multiple
Operating procedure, makes input operation more simple and efficient, improves the efficiency of word input, and avoid mobile equipment in user
More secondary responses when re-entering, reduce the system resources consumption of mobile equipment.
Brief description of the drawings
Fig. 1 is a kind of exemplary plot for inputting word;
Fig. 2 is the exemplary plot shielded on a kind of word;
Fig. 3 is a kind of step flow chart of embodiment of the method 1 for inputting word in a mobile device of the present invention;
Fig. 4 is a kind of step flow chart of embodiment of the method 2 for inputting word in a mobile device of the present invention;
Fig. 5 is a kind of structure diagram of device embodiment 1 for inputting word in a mobile device of the present invention;
Fig. 6 is a kind of structure diagram of device embodiment 2 for inputting word in a mobile device of the present invention.
Embodiment
In order to make the foregoing objectives, features and advantages of the present invention clearer and more comprehensible, it is below in conjunction with the accompanying drawings and specific real
Applying mode, the present invention is described in further detail.
Reference Fig. 3, shows a kind of step flow of embodiment of the method 1 for inputting word in a mobile device of the present invention
Figure, specifically may include steps of:
Step 301, when listening to the trigger event specified, acquisition has selected the corresponding button of word of screen defeated recently
Enter string;
It should be noted that in embodiments of the present invention, mobile equipment can be tablet computer, personal digital assistant, hand
The various mobile equipment such as machine, the embodiment of the present invention are not restricted this.
In the concrete realization, the trigger event specified can include but is not limited to following at least one:
Specifying the specified gesture event in region;
In a kind of example of the embodiment of the present invention, specified region can be preset function button where region, example
Such as delete key.When specified gesture event for left/right/up/down when slide when, trigger event can be left/right/
Up/down etc. slides delete key.This exemplary operation is the gesture behaviour for dummy keyboard delete key in mobile equipment
Make, user can slide since any screen area in delete key, when listen to this slide for left/right/upwards/to
The follow-up process of the embodiment of the present invention is triggered during inferior slip.
In another example of the embodiment of the present invention, specified region can be except where above-mentioned preset function button
Region outside region, such as move the region in equipment where dummy keyboard, user can define one not with currently
The gesture operation of the gesture conflict of definition, user can slide since any screen area in dummy keyboard, when listening to
This slip triggers the follow-up process of the embodiment of the present invention when being user-defined gesture operation.
The function button event specified;
A function button specified can be pre-defined, user can click on the function button specified, and when monitoring
The follow-up process of the embodiment of the present invention is triggered when clicking on the operation for the function button specified to user.
Mobile equipment rollover event;
Mobile equipment is needed with gravity sensor and normally-open, the triggering present invention when listening to mobile equipment upset
The follow-up process of embodiment.Below with Android(Android)Illustrated exemplified by the mobile equipment of system.
1st, the example of SensorManager is obtained, gravity sensor is obtained using the method for the example
(getDefaultSensor(Sensor.TYPE_ACCELEROMETER));
2nd, the event sniffer of a gravity sensor is created, SensorEventListener classes is inherited from, rewrites such
OnSensorChanged methods, judge whether mobile phone overturns according to the relevant parameter of SensorEvent inside this method;
3rd, the gravity sensor event of establishment is supervised using the registerListener methods of SensorManager examples
Device is listened to be bound with gravity sensor, gravity sensor changes the OnSensorChanged methods that will adjust back monitor, judges hand
Whether machine overturns.
The speech events specified.
The speech events specified can be pre-defined, user can input voice number by sound pick-up outfits such as microphones
According to, and the follow-up process of the embodiment of the present invention is triggered when listening to voice data input by user and being the speech events specified.
Certainly, above-mentioned trigger event is intended only as example, when implementing the embodiment of the present invention, can be set according to actual conditions
Other trigger events are put, the embodiment of the present invention is not any limitation as this.In addition, in addition to above-mentioned trigger event, art technology
Personnel can also use other trigger events according to being actually needed, and the embodiment of the present invention is not also any limitation as this.
In one preferred embodiment of the invention, the step 301 can include following sub-step:
Sub-step S11, extraction is buffered in the heap region of mobile device memory in advance in word candidate recently, described
The corresponding key-press input string of word of screen has been selected recently.
Using the embodiment of the present invention, user inputs key-press input string, and input method application program can return to one or more
The word of candidate, when user selects to shield on one of word, can cache this and select the corresponding button of the word of screen
Input string.
Below with Android(Android)Illustrated exemplified by the mobile equipment of system.
The corresponding DVM of input method(Android virtual machines, each Android APP(Application, third-party application
Program)All correspond to an Android virtual machine)Apply a block length for acquiescence input maximum length in system heap memories
Memory space, preserves corresponding key-press input string when shielding on the last selection candidate character.Shield on selection candidate character
When, it is the space for needing to empty saving button input string, and before key-press input string can be copied to before emptying
In the memory space of application.
For example, in the input method nine grids input through keyboard key-press input string " 64426 " shown in Fig. 1, input method application program
The candidate character of the corresponding Pinyin Input of key-press input string " 64426 " such as " hello ", " you dare ", " you number " is returned, is selected in fig. 2
Select when shielding on " hello ", key-press input string " 64426 " has been buffered in the heap region of mobile device memory.
In another example in input method nine grids input through keyboard key-press input string " 9426 ", input method application program returns to " west
The candidate character of the corresponding Pinyin Input of key-press input string " 9426 " such as peace ", " elder generation ", " small ", " looking for ";Inputted in Chinese nine grids
Key-press input string " 948736 ", input method application program return to the key-press input strings such as " director ", " owner ", " helping others ", " living in people "
The candidate character of " 948736 " corresponding Pinyin Input.
Since the candidate character such as " Xi'an ", " elder generation ", " small ", " looking for ", " director ", " owner ", " helping others ", " living in people " is normal
With word, word, and key-press input string is identical, may be further nearly word form(Such as " owner " and " live in people " nearly word form each other), make
Easily there is maloperation when select candidate character in user, such as user's original idea selection " small ", but mistakenly have selected
Shield in " elder generation ", at this time, key-press input string " 9426 " is buffered in the heap region of mobile device memory;And for example user's original idea selects
" owner ", but mistakenly have selected and shield in " living in people ", at this time, key-press input string " 948736 " is buffered in mobile equipment
In the heap region deposited.
It should be noted that key-press input string can be phonetic, five, stroke, the corresponding button of input mode such as English
Input string, the embodiment of the present invention are not any limitation as this.
Step 302, according to the length for the word for having selected upper screen recently and the key-press input string, deleted in current interface
Except the word for having selected upper screen;
The candidate character of selection may be displayed on the edit box of various APP or mobile equipment inherent function after upper screen
In object, such as text box in browser, the chat window of instant messaging, short message page etc., therefore, it is necessary first to delete
The word selected.
Below with Android(Android)Illustrated exemplified by the mobile equipment of system.
In one preferred embodiment of the invention, the step 302 can include following sub-step:
Sub-step S21, obtains the length for the word for having selected screen recently;
Sub-step S22, is obtained current using the getTextBeforeCursor methods in InputConnection objects
The text information identical with the length before cursor;
Sub-step S23, when the characters matching that the text information has selected upper screen with described, is called
DeleteSurroundingText methods in InputConnection objects delete the text information.
In the concrete realization, one can be passed through between input method application program and edit box object
InputConnection objects are contacted.Specifically, InputConnection objects are input method application programs with receiving
The communication pipe of the application program of its input content, the text around cursor is such as read for execution, submits text to text box
And this is to operations such as application program transmission KeyEvents, and InputConnection objects can pass through
GetCurrentInputConnection methods obtain.
When deletion has selected the word shielded, the length for having selected the word of screen to be pre-saved in upper screen is obtained first
Degree, as selected to shield on word " hello ", the length of 2 unit distances.Then InputConnection objects are called
GetTextBeforeCursor methods obtain the identical text information of length before the cursor of current edit box object, by itself and it
The word for having selected screen of preceding preservation compares, if identical, calls the InputConnection objects that get
DeleteSurroundingText methods delete the identical word of length before current edit box object cursor;Sentence after if
Disconnected difference, then abandon this delete operation.
Step 303, the input information of the corresponding candidate of the key-press input string is returned.
In embodiments of the present invention, by returning to the input information of the corresponding candidate of key-press input string, realize in revocation
Shield the operation of word.
In one preferred embodiment of the invention, the input information of the candidate can be included in what current interface was shown
Head screen candidate character set;Step 303 can include following sub-step:
Sub-step S31, searches the corresponding first screen candidate character set of the key-press input string;
Sub-step S32, in first screen candidate character set described in current first screen candidate's interface display.
In the concrete realization, the key-press input string pre-saved can be transmitted to input method application program kernel again, by
Setting environment identical in input method application program, then input method application program kernel will be returned inputs phase with last user
With candidate input information, such as phonetic/stroke, the word etc. shown in current interface passing through specified function button
Phonetic/stroke, the word that triggering Expansion Interface is shown, then update the input information of interface exhibition candidate.
For example, user selects after shielding on word " hello " in fig. 2, using the embodiment of the present invention, " you can deleted
It is good " after, return to input results same as in figure 1.
In another preferred embodiment of the invention, user will be moved back by trigger event to have deleted the word of upper screen
State when shielding on non-selected candidate character is returned to, the word of screen has been selected before having may indicate that and non-user is wanted at this time
The word shielded in input, if still the word to be deleted this is put back in first screen candidate at this time, will take other may be
User wants to input probability of the candidate character in first screen display of screen, and user sometimes has to carry out page turning just find and wants
The candidate character of input, such as general first screen show five candidate characters, if the character arranging that user needs to input at the 6th,
So, user would have to page turning and carries out candidate.
In this embodiment, the input information of the candidate can be included in the first screen candidate character collection that current interface is shown
Close, step 303 can include following sub-step:
Sub-step S41, the word for having selected upper screen recently is removed from the candidate character set;
Sub-step S42, other candidate characters are added in the first screen candidate character set;
Sub-step S43, the first screen candidate character after current first screen candidate's interface display with the addition of other candidate characters
Set.
It should be noted that the input information of the corresponding candidate of key-press input string can include first screen candidate character set and
Other words, wherein first screen candidate character set includes the highest one or more words of priority, in current first screen candidate
Interface display, the priority of other words is relatively low, and triggering Expansion Interface by specified function button is shown.
In embodiments of the present invention, in order to show the required word of more users in current interface, can use
Negative sense frequency modulation is by the word of upper screen removes first screen before, you can be by the priority of this word(Such as candidate's score value)Drop
It is low, first screen candidate character set is removed, can preferably not touched in current first screen candidate's interface display by specified function button
Hair Expansion Interface is shown, then, the probability that the word that can increase user needs to input at this time shows in first screen, so as to carry
User's input efficiency has been risen, and has improved the input experience of user.
So-called negative sense frequency modulation, can be that candidate character is reduced the priority of candidate character, made its row with the punishment of word frequency
The mode informed against outside shielding.
For example, in the current interface shown in Fig. 1, " hello ", " you dare ", " you number " and " you are dry " composition candidate character collection
Close, select in fig. 2 after shielding on " hello ", can be after " hello " be deleted, by candidate character collection using the embodiment of the present invention
" hello " in conjunction deletes, other words " drafting " are added in candidate character set, then current interface show " drafting ",
" you dare ", " you number " and " you are dry ".
The embodiment of the present invention pre-saves key-press input string when shielding on selecting word, by trigger event, is working as prezone
The word selected is deleted in face, and returns to the input information of the corresponding candidate of key-press input string, reduces user and deletes
The word of selection and multiple operating procedures such as re-enter, make input operation more simple and efficient, improve the effect of word input
Rate, and more secondary responses of the mobile equipment when user re-enters are avoided, reduce the system resources consumption of mobile equipment.
The word selected is removed current first screen by the embodiment of the present invention by the hint of user's operation using negative sense frequency modulation
Candidate's interface display, that is, eliminate unwanted candidate character, improves and shows the general of the candidate character of needs in current interface
Rate, further increases the efficiency of word input.
Reference Fig. 4, shows a kind of step flow of embodiment of the method 2 for inputting word in a mobile device of the present invention
Figure, specifically may include steps of:
Step 401, when listening to the trigger event specified, word segmentation processing is carried out to the word selected recently, is obtained
Input participle;
It should be noted that in the embodiment of the present invention, user can carry out long word input, the wherein partial words in long word
And/or word is not needed for user.For example, user inputs long word " golden field weather is fine ", wherein " golden field " is the mistake of " today "
Input, is not needed for user.
In addition, in long word input, consider for input is simple, can carry out simplifying input, at this time key-press input string
For the key-press input string of abbreviation.For example, user can input simplified PINYIN form " zr " when inputting " owner ", it is corresponded to
Key-press input string be " 97 ".
And in embodiments of the present invention, mobile equipment can be the various movements such as tablet computer, personal digital assistant, mobile phone
Equipment, the embodiment of the present invention are not restricted this.
Some common segmenting methods are described below:
1st, the segmenting method based on string matching:Refer to the Chinese character string that is analysed to according to certain strategy and one it is pre-
Entry in the machine dictionary put is matched, if finding some character string, successful match in dictionary(Identify one
Word).The Words partition system of actual use, be all using mechanical Chinese word segmentation as a kind of just departure section, need to also be by using various other
Language message further improves the accuracy rate of cutting, such as can combine between word frequency, word on the basis of word match
Two/N members relation, context, user thesaurus(The dictionary made based on user's use habit), the analysis of the combined factors such as personalization,
Cutting.
2nd, the segmenting method of feature based scanning or mark cutting:Refer to preferentially identification and cutting in character string to be analyzed
Go out some words for carrying obvious characteristic, using these words as breakpoint, former character string can be divided into less string and come again into machinery point
Word, so as to reduce matched error rate;Or combine participle and part-of-speech tagging, using abundant grammatical category information to participle
Decision-making provides help, and tests, adjusts to word segmentation result in turn again in annotation process, so as to improve the standard of cutting
True rate.
3rd, the segmenting method based on understanding:Refer to, by allowing the understanding of computer mould personification distich, reach identification word
Effect.Its basic thought is exactly to carry out syntax, semantic analysis while participle, is handled using syntactic information and semantic information
Ambiguity.It generally includes three parts:Segment subsystem, syntactic-semantic subsystem, master control part.Association in master control part
Under tune, participle subsystem can obtain the syntax and semantic information in relation to word, sentence etc. to judge segmentation ambiguity, i.e., it
Simulate understanding process of the people to sentence.This segmenting method needs to use substantial amounts of linguistry and information.
4th, the segmenting method based on statistics:Refer to, due to the frequency or probability energy of word co-occurrence adjacent with word in Chinese information
Confidence level of enough preferable reflections into word, it is possible to unite to the frequency of each combinatorics on words of adjacent co-occurrence in language material
Meter, calculates their information that appears alternatively, and calculates the adjacent co-occurrence probabilities of two Chinese characters X, Y.The information that appears alternatively can embody Chinese character
Between marriage relation tightness degree.When tightness degree is higher than some threshold value, it can think that this word group may constitute one
A word.This method need to only count the word group frequency in language material, it is not necessary to cutting dictionary.
By taking " golden field weather is fine " as an example, carry out word segmentation processing after, can obtain input participle " golden field ", " weather " and
" fine ".
In the concrete realization, the trigger event specified can include following at least one:
Specifying the specified gesture event in region;
In a kind of example of the embodiment of the present invention, specified region can be preset function button where region, example
Such as delete key.When specified gesture event for left/right/up/down when slide when, trigger event can be left/right/
Up/down etc. slides delete key.This exemplary operation is the gesture behaviour for dummy keyboard delete key in mobile equipment
Make, user can slide since any screen area in delete key, when listen to this slide for left/right/upwards/to
The follow-up process of the embodiment of the present invention is triggered during inferior slip.
In another example of the embodiment of the present invention, specified region can be except where above-mentioned preset function button
Region outside region, such as move the region in equipment where dummy keyboard, user can define one not with currently
The gesture operation of the gesture conflict of definition, user can slide since any screen area in dummy keyboard, when monitor this
Slide to trigger the follow-up process of the embodiment of the present invention during user-defined gesture operation.
The function button event specified;
A function button specified can be pre-defined, user can work as monitoring from the function button specified is clicked on
The follow-up process of the embodiment of the present invention is triggered when clicking on the operation for the function button specified to user.
Mobile equipment rollover event;
Mobile equipment is needed with gravity sensor and normally-open, the triggering present invention when listening to mobile equipment upset
The follow-up process of embodiment.
Below with Android(Android)Illustrated exemplified by the mobile equipment of system.
1st, the example of SensorManager is obtained, gravity sensor is obtained using the method for the example
(getDefaultSensor(Sensor.TYPE_ACCELEROMETER));
2nd, the event sniffer of a gravity sensor is created, SensorEventListener classes is inherited from, rewrites such
OnSensorChanged methods, judge whether mobile phone overturns according to the relevant parameter of SensorEvent inside this method;
3rd, the gravity sensor event of establishment is supervised using the registerListener methods of SensorManager examples
Device is listened to be bound with gravity sensor, gravity sensor changes the OnSensorChanged methods that will adjust back monitor, judges hand
Whether machine overturns.
The speech events specified.
The speech events specified can be pre-defined, user can input voice number by sound pick-up outfits such as microphones
According to, and the follow-up process of the embodiment of the present invention is triggered when listening to voice data input by user and being the speech events specified.
Certainly, above-mentioned trigger event is intended only as example, when implementing the embodiment of the present invention, can be set according to actual conditions
Other trigger events are put, the embodiment of the present invention is not any limitation as this.In addition, in addition to above-mentioned trigger event, art technology
Personnel can also use other trigger events according to being actually needed, and the embodiment of the present invention is not also any limitation as this.
Step 402, when receiving the selection instruction for the input participle, the acquisition input participle is corresponding to be pressed
Key input string;
Selection instruction can refer to the instruction for selecting some input participle that user sends.For example, user can pass through a little
Hitting selection, certain inputs participle, or selects some input participle etc. by specified selection function button.When user clicks on certain
During input participle, it is equivalent to have received the selection instruction that user selects input participle;Equally, when listening to the choosing specified
When selecting function button, also correspond to have received the selection instruction that user selects input participle.
For in the example of " golden field weather is fine ", the corresponding input participle of selection instruction can be " golden field ".
In the concrete realization, user can determine to need the position of the input participle of selection by operating gesture, then can be with
Preset the distance of operating gesture slip, position, direction etc..
In one preferred embodiment of the invention, the step 402 can include following sub-step:
Sub-step S51, extraction is buffered in the heap region of mobile device memory in advance in word candidate recently, described
Input segments corresponding key-press input string.
Using the embodiment of the present invention, user inputs key-press input string, and input method application program can return to one or more
The word of candidate, when user selects to shield on one of word, can cache this and select the corresponding button of the word of screen
Input string.
Below with Android(Android)Illustrated exemplified by the mobile equipment of system.
The corresponding DVM of input method(Android virtual machines, each Android APP(Application, third-party application
Program)All correspond to an Android virtual machine)Apply a block length for acquiescence input maximum length in system heap memories
Memory space, preserves corresponding key-press input string when shielding on the last selection word.It is to need when shielding on selecting word
Empty the space of saving button input string, and the storage applied before key-press input string can be copied to before emptying
In space.
For example, in input method nine grids input through keyboard key-press input string " 5468426842674436426 ", user is selecting
When shielding on the key-press input string corresponding " golden field weather is fine ", key-press input string " 5468426842674436426 " is cached
In the heap region of mobile device memory.Wherein, user selection input participle " golden field " corresponding key-press input string for
“5468426”
It should be noted that key-press input string can be phonetic, five, stroke, the corresponding button of input mode such as English
Input string, the embodiment of the present invention are not any limitation as this.
Step 403, according to the length of the input participle and the key-press input string, deleted in current interface described defeated
Enter participle;
The candidate character of selection may be displayed on the edit box of various APP or mobile equipment inherent function after upper screen
In object, such as text box in browser, the chat window of instant messaging, short message page etc., therefore, it is necessary first to delete
The word selected.
Below with Android(Android)Illustrated exemplified by the mobile equipment of system.
In one preferred embodiment of the invention, the step 403 can include following sub-step:
Sub-step S61, obtains the length of the input participle;
Sub-step S62, is obtained current using the getTextBeforeCursor methods in InputConnection objects
The text information identical with the length before cursor;
Sub-step S63, when the text information is matched with the input participle, is called in InputConnection classes
DeleteSurroundingText methods the text information is deleted.
In the concrete realization, one can be passed through between input method application program and edit box object
InputConnection objects are contacted.Specifically, InputConnection objects are input method application programs with receiving
The communication pipe of the application program of its input content, the text around cursor is such as read for execution, submits text to text box
And this is to operations such as application program transmission KeyEvents, and InputConnection objects can pass through
GetCurrentInputConnection methods obtain.
When deletion has selected the word shielded, the length for having selected the word of screen to be pre-saved in upper screen is obtained first
Degree, as selected to shield on word " hello ", the length of 2 unit distances.Then InputConnection objects are called
GetTextBeforeCursor methods obtain the identical text information of length before the cursor of current edit box object, by itself and it
The word for having selected screen of preceding preservation compares, if identical, calls the InputConnection objects that get
DeleteSurroundingText methods delete the identical word of length before current edit box object cursor;Sentence after if
Disconnected difference, then abandon this delete operation.
Step 404, the input information of the corresponding candidate of the key-press input string is returned.
In embodiments of the present invention, by returning to the input information of the corresponding candidate of key-press input string, realize in revocation
Shield the operation of word.
In one preferred embodiment of the invention, the input information of the candidate can be included in current Shou Ping candidates circle
The first screen candidate character set that face is shown;Step 303 can include following sub-step:
Sub-step S71, searches the corresponding first screen candidate character set of the key-press input string;
Sub-step S72, in first screen candidate character set described in current first screen candidate's interface display.
In the concrete realization, the key input string pre-saved can be transmitted to input method application program kernel again, due to
Input method application program is identical in setting environment, then input method application program kernel will return identical when being inputted with last user
Candidate input information, such as phonetic/stroke, the word etc. shown in current interface touch by specified function button
Phonetic/stroke, the word that hair Expansion Interface is shown, then update the input information of interface exhibition candidate.
For example, after user is shielded on selection word " golden field weather is fine ", using the embodiment of the present invention, can delete
After " golden field ", return the input information " today " of key-press input string " 5468426 " corresponding candidate, " gold bar ", " golden field " and
" Jin Tian ".
In another preferred embodiment of the invention, user will be moved back by trigger event to have deleted the word of upper screen
State when shielding on non-selected candidate character is returned to, the word of screen has been selected before having may indicate that and non-user is wanted at this time
The word shielded in input, if still the word to be deleted this is put back in first screen candidate at this time, will take other may be
User wants to input probability of the candidate character in first screen display of screen, and user sometimes has to carry out page turning just find and wants
The candidate character of input, such as general first screen show five candidate characters, if the character arranging that user needs to input at the 6th,
So, user would have to page turning and carries out candidate.
In this embodiment, the input information of the candidate can be included in the current first first screen for shielding candidate's interface display and wait
Selection word set, step 404 can include following sub-step:
Sub-step S81, the input participle is deleted from the candidate character set;
Sub-step S82, other candidate characters are added in the candidate character set;
Sub-step S83, the candidate character set after current first screen candidate's interface display with the addition of other candidate characters.
It should be noted that the input information of the corresponding candidate of key-press input string can include first screen candidate character set and
Other words, wherein first screen candidate character set includes the highest one or more words of priority, in current first screen candidate
Interface display, the priority of other words is relatively low, and triggering Expansion Interface by specified function button is shown.
In embodiments of the present invention, in order to show the required word of more users in current interface, can use
Negative sense frequency modulation is by the word of upper screen removes first screen before, you can be by the priority of this word(Such as candidate's score value)Drop
It is low, first screen candidate character set is removed, can preferably not touched in current first screen candidate's interface display by specified function button
Hair Expansion Interface is shown, then, the probability that the word that can increase user needs to input at this time shows in first screen, so as to carry
User's input efficiency has been risen, and has improved the input experience of user.
So-called negative sense frequency modulation, can be that candidate character is reduced the priority of candidate character, made its row with the punishment of word frequency
The mode informed against outside shielding.
For example, the input information " today " of the corresponding candidate of key-press input string " 5468426 ", " gold bar ", " golden field " and " gold
My god " composition candidate character set, after user is shielded in selection " golden field weather is fine ", using the embodiment of the present invention, it can delete
After " golden field ", " the golden field " in candidate character set is deleted, other words " Kintian " are added in candidate character set,
Then shown " today ", " gold bar ", " Kintian " and " Jin Tian " in current interface.
The embodiment of the present invention pre-saves key-press input string when shielding on selecting word, maloperation occurs in input long word
When, by trigger event, long word is segmented, the input participle of user's selection is deleted in current interface, and returns and presses
The input information of the corresponding candidate of key input string, reduces user and deletes input participle and multiple operating procedures such as re-enter,
Make input operation more simple and efficient, improve the efficiency of word input, and avoid mobile equipment and re-entered in user
When more secondary responses, reduce the system resources consumption of mobile equipment.
The word selected is removed current first screen by the embodiment of the present invention by the hint of user's operation using negative sense frequency modulation
Candidate's interface display, that is, eliminate unwanted candidate character, improves and shows the general of the candidate character of needs in current interface
Rate, further increases the efficiency of word input.
It should be noted that for embodiment of the method, in order to be briefly described, therefore it is all expressed as to a series of action group
Close, but those skilled in the art should know, the embodiment of the present invention and from the limitation of described sequence of movement, because according to
According to the embodiment of the present invention, some steps can use other orders or be carried out at the same time.Secondly, those skilled in the art also should
Know, embodiment described in this description belongs to preferred embodiment, and the involved action not necessarily present invention is implemented
Necessary to example.
With reference to Fig. 5, a kind of structure diagram for the device embodiment 1 for inputting word in a mobile device of the present invention is shown,
Following module can specifically be included:
First acquisition module 501, for when listening to the trigger event specified, obtaining the word for having selected screen recently
Corresponding key-press input string;
First removing module 502, the length of the word of upper screen and the key-press input string have been selected for basis recently,
The word of screen has been selected described in being deleted in current interface;
First returns to module 503, for returning to the input information of the corresponding candidate of the key-press input string.
In one preferred embodiment of the invention, the trigger event specified can include but is not limited to it is following extremely
Few one kind:
In the specified gesture event for specifying region, the function button event specified, mobile equipment rollover event, the language specified
Sound event.
In one preferred embodiment of the invention, first acquisition module 501 can include following submodule:
First extracting sub-module, the heap region of mobile device memory is buffered in for extracting in advance in word candidate recently
In, the corresponding key-press input string of word for having selected screen recently.
In one preferred embodiment of the invention, first removing module 502 can include following submodule:
First length acquisition submodule, for obtaining the length for the word for having selected upper screen recently;
First text information acquisition submodule, for using in InputConnection classes
The text information identical with the length before getTextBeforeCursor methods acquisition current cursor;
First text information deletes submodule, in the text information and the characters matching for having selected to shield
When, call the deleteSurroundingText methods in InputConnection objects to delete the text information.
In one preferred embodiment of the invention, the input information of the candidate can be included in current Shou Ping candidates circle
The first screen candidate character set that face is shown, the first return module 503 can include following submodule:
First searches submodule, for searching the corresponding first screen candidate character set of the key-press input string;
First display sub-module, in first screen candidate character set described in current first screen candidate's interface display.
In one preferred embodiment of the invention, the input information of the candidate can be included in current Shou Ping candidates circle
The first screen candidate character set that face is shown, the first return module 503 can include following submodule:
First deletes submodule, for the word for having selected upper screen recently to be deleted from the first screen candidate character set
Remove;
First addition submodule, for adding other candidate characters in the first screen candidate character set;
Second display sub-module, for the first screen after with the addition of other candidate characters in current first screen candidate's interface display
Candidate character set.
With reference to Fig. 6, a kind of structure diagram for the device embodiment 2 for inputting word in a mobile device of the present invention is shown,
Following module can specifically be included:
Word-dividing mode 601, for when listening to the trigger event specified, dividing the word for having selected upper screen recently
Word processing, obtains input participle;
Second acquisition module 602, for when receiving the selection instruction for the input participle, obtaining the input
Segment corresponding key-press input string;
Second removing module 603, for the length according to the input participle and the key-press input string, in current interface
It is middle to delete the input participle;
Second returns to module 604, for returning to the input information of the corresponding candidate of the key-press input string.
In one preferred embodiment of the invention, the trigger event specified can include but is not limited to it is following extremely
Few one kind:
In the specified gesture event for specifying region, the function button event specified, mobile equipment rollover event, the language specified
Sound event.
In one preferred embodiment of the invention, second acquisition module 602 can include following submodule:
Second extracting sub-module, the heap region of mobile device memory is buffered in for extracting in advance in word candidate recently
In, the input segments corresponding key-press input string.
In one preferred embodiment of the invention, second removing module 603 can include following submodule:
Second length acquisition submodule, for obtaining the length of the input participle;
Second text information acquisition submodule, for using in InputConnection classes
The text information identical with the length before getTextBeforeCursor methods acquisition current cursor;
Second text information deletes submodule, for when the text information is matched with the input participle, calling
DeleteSurroundingText methods in InputConnection objects delete the text information.
In one preferred embodiment of the invention, the input information of the candidate can be included in what current interface was shown
Head screen candidate character set;The second return module 604 can include following submodule:
Second searches submodule, for searching the corresponding first screen candidate character set of the key-press input string;
3rd display sub-module, in first screen candidate character set described in current first screen candidate's interface display.
In one preferred embodiment of the invention, the input information of the candidate can be included in current Shou Ping candidates circle
The candidate character set of the first screen of face display, the second return module 604 can include following submodule:
Second deletes submodule, for the input participle to be removed from the candidate character set;
Second addition submodule, for adding other candidate characters in the first screen candidate character set;
Second display sub-module, for the first screen after with the addition of other candidate characters in current first screen candidate's interface display
Candidate character set.
For device embodiment, since it is substantially similar to embodiment of the method, so description is fairly simple, it is related
Part illustrates referring to the part of embodiment of the method.
Each embodiment in this specification is described by the way of progressive, what each embodiment stressed be with
The difference of other embodiment, between each embodiment identical similar part mutually referring to.
It should be understood by those skilled in the art that, the embodiment of the embodiment of the present invention can be provided as method, apparatus or calculate
Machine program product.Therefore, the embodiment of the present invention can use complete hardware embodiment, complete software embodiment or combine software and
The form of the embodiment of hardware aspect.Moreover, the embodiment of the present invention can use one or more wherein include computer can
With in the computer-usable storage medium (including but not limited to magnetic disk storage, CD-ROM, optical memory etc.) of program code
The form of the computer program product of implementation.
The embodiment of the present invention be with reference to according to the method for the embodiment of the present invention, terminal device (system) and computer program
The flowchart and/or the block diagram of product describes.It should be understood that it can realize flowchart and/or the block diagram by computer program instructions
In each flow and/or block and flowchart and/or the block diagram in flow and/or square frame combination.These can be provided
Computer program instructions are set to all-purpose computer, special purpose computer, Embedded Processor or other programmable data processing terminals
Standby processor is to produce a machine so that is held by the processor of computer or other programmable data processing terminal equipments
Capable instruction is produced and is used for realization in one flow of flow chart or multiple flows and/or one square frame of block diagram or multiple square frames
The device for the function of specifying.
These computer program instructions, which may also be stored in, can guide computer or other programmable data processing terminal equipments
In the computer-readable memory to work in a specific way so that the instruction being stored in the computer-readable memory produces bag
The manufacture of command device is included, which realizes in one flow of flow chart or multiple flows and/or one side of block diagram
The function of being specified in frame or multiple square frames.
These computer program instructions can be also loaded into computer or other programmable data processing terminal equipments so that
Series of operation steps is performed on computer or other programmable terminal equipments to produce computer implemented processing, so that
The instruction performed on computer or other programmable terminal equipments is provided and is used for realization in one flow of flow chart or multiple flows
And/or specified in one square frame of block diagram or multiple square frames function the step of.
Although having been described for the preferred embodiment of the embodiment of the present invention, those skilled in the art once know base
This creative concept, then can make these embodiments other change and modification.So appended claims are intended to be construed to
Including preferred embodiment and fall into all change and modification of range of embodiment of the invention.
Finally, it is to be noted that, herein, relational terms such as first and second and the like be used merely to by
One entity or operation are distinguished with another entity or operation, without necessarily requiring or implying these entities or operation
Between there are any actual relationship or order.Moreover, term " comprising ", "comprising" or its any other variant meaning
Covering non-exclusive inclusion, so that process, method, article or terminal device including a series of elements are not only wrapped
Those key elements are included, but also including other elements that are not explicitly listed, or further include as this process, method, article
Or the key element that terminal device is intrinsic.In the absence of more restrictions, wanted by what sentence "including a ..." limited
Element, it is not excluded that also there are other identical element in the process including the key element, method, article or terminal device.
Above to a kind of method for inputting word in a mobile device provided by the present invention and one kind in a mobile device
Input the device of word, be described in detail, specific case used herein to the principle of the present invention and embodiment into
Elaboration is gone, the explanation of above example is only intended to help to understand the method and its core concept of the present invention;Meanwhile for this
The those skilled in the art in field, according to the thought of the present invention, there will be changes in specific embodiments and applications,
In conclusion this specification content should not be construed as limiting the invention.
Claims (24)
- A kind of 1. method for inputting word in a mobile device, it is characterised in that including:When listening to the trigger event specified, the corresponding key-press input string of word for having selected screen recently is obtained;According to the length for the word for having selected upper screen recently and the key-press input string, deleted in current interface it is described recently The word shielded in selection;Return to the input information of the corresponding candidate of the key-press input string;Wherein, the input information of the candidate includes:In the first screen candidate character set that current interface is shown, the first screen candidate Word set does not include the word for having selected screen recently.
- 2. according to the method described in claim 1, it is characterized in that, the trigger event specified include but not limited to it is following It is at least one:In the specified gesture event for specifying region, the function button event specified, mobile equipment rollover event, the voice thing specified Part.
- 3. according to the method described in claim 1, it is characterized in that, the acquisition has selected the word of screen is corresponding to press recently The step of key input string, includes:Extraction is buffered in the heap region of mobile device memory in advance in word candidate recently, described to have selected to shield recently The corresponding key-press input string of word.
- 4. according to the method described in claim 1, it is characterized in that, the basis selected recently the word of screen length and The key-press input string, is deleted described the step of having selected the word shielded recently in current interface, including:Obtain the length for the word for having selected screen recently;Using in InputConnection objects getTextBeforeCursor methods obtain current cursor before with the length Spend identical text information;When the characters matching that the text information has selected upper screen with described recently, call in InputConnection classes DeleteSurroundingText methods delete the text information.
- 5. according to the method described in claim 1 or 2 or 3 or 4, it is characterised in that the input information of the candidate, which is included in, to be worked as The first screen candidate character set that front interface is shown;It is described return to the corresponding candidate of the key-press input string input information the step of include:Search the corresponding first screen candidate character set of the key-press input string;In first screen candidate character set described in current first screen candidate's interface display.
- 6. according to the method described in claim 1 or 2 or 3 or 4, it is characterised in that the input information of the candidate, which is included in, to be worked as The first screen candidate character set that front interface is shown;It is described return to the corresponding candidate of the key-press input string input information the step of include:The word for having selected upper screen recently is removed from the first screen candidate character set;Other candidate characters are added in the first screen candidate character set;First screen candidate character set after current first screen candidate's interface display with the addition of other candidate characters.
- A kind of 7. method for inputting word in a mobile device, it is characterised in that including:When listening to the trigger event specified, word segmentation processing is carried out to the word for having selected upper screen recently, obtains input participle;When receiving the selection instruction for the input participle, obtain the input and segment corresponding key-press input string;According to the length of the input participle and the key-press input string, the input participle is deleted in current interface;Return to the input information of the corresponding candidate of the key-press input string;Wherein, the input information of the candidate includes:In the first screen candidate character set that current interface is shown, the first screen candidate Word set does not include the input and segments.
- 8. the method according to the description of claim 7 is characterized in that the trigger event specified include but not limited to it is following It is at least one:In the specified gesture event for specifying region, the function button event specified, mobile equipment rollover event, the voice thing specified Part.
- 9. the method according to the description of claim 7 is characterized in that described obtain the corresponding key-press input string of the input participle The step of include:Extraction is buffered in the heap region of mobile device memory in advance in word candidate recently, and the input participle is corresponding Key-press input string.
- 10. the method according to the description of claim 7 is characterized in that the length according to the input participle and described press Key input string, deletes the step of input segments in current interface, including:Obtain the length of the input participle;Using in InputConnection objects getTextBeforeCursor methods obtain current cursor before with the length Spend identical text information;When the text information is matched with the input participle, call in InputConnection classes DeleteSurroundingText methods delete the text information.
- 11. according to the method described in claim 7 or 8 or 9 or 10, it is characterised in that the input information of the candidate is included in The first screen candidate character set that current interface is shown;It is described return to the corresponding candidate of the key-press input string input information the step of include:Search the corresponding first screen candidate character set of the key-press input string;In first screen candidate character set described in current first screen candidate's interface display.
- 12. according to the method described in claim 7 or 8 or 9 or 10, it is characterised in that the input information of the candidate is included in The first screen candidate character set that current interface is shown;It is described return to the corresponding candidate of the key-press input string input information the step of include:The input participle is removed from the first screen candidate character set;Other candidate characters are added in the first screen candidate character set;First screen candidate character set after current first screen candidate's interface display with the addition of other candidate characters.
- A kind of 13. device for inputting word in a mobile device, it is characterised in that including:First acquisition module, for when listening to the trigger event specified, acquisition to have selected the word of screen corresponding recently Key-press input string;First removing module, for the length according to the word for having selected upper screen recently and the key-press input string, is working as prezone The word for having selected screen recently is deleted in face;First returns to module, for returning to the input information of the corresponding candidate of the key-press input string;Wherein, the input information of the candidate includes:In the first screen candidate character set that current interface is shown, the first screen candidate Word set does not include the word for having selected screen recently.
- 14. device according to claim 13, it is characterised in that the trigger event specified includes but not limited to following At least one:In the specified gesture event for specifying region, the function button event specified, mobile equipment rollover event, the voice thing specified Part.
- 15. device according to claim 13, it is characterised in that first acquisition module includes:First extracting sub-module, is buffered in the heap region of mobile device memory in advance in word candidate recently for extracting , the corresponding key-press input string of word for having selected screen recently.
- 16. device according to claim 13, it is characterised in that first removing module includes:First length acquisition submodule, for obtaining the length for the word for having selected upper screen recently;First text information acquisition submodule, for using the getTextBeforeCursor side in InputConnection classes The text information identical with the length before method acquisition current cursor;First text information deletes submodule, in the text information and the characters matching for having selected to shield recently When, call the deleteSurroundingText methods in InputConnection objects to delete the text information.
- 17. according to the device described in claim 13 or 14 or 15 or 16, it is characterised in that the input information of the candidate includes In the first screen candidate character set of current first screen candidate's interface display;The first return module includes:First searches submodule, for searching the corresponding first screen candidate character set of the key-press input string;First display sub-module, in first screen candidate character set described in current first screen candidate's interface display.
- 18. according to the device described in claim 13 or 14 or 15 or 16, it is characterised in that the input information of the candidate includes In the first screen candidate character set of current first screen candidate's interface display, the first return module includes:First deletes submodule, for the word for having selected upper screen recently to be deleted from the first screen candidate character set;First addition submodule, for adding other candidate characters in the first screen candidate character set;Second display sub-module, for the first screen candidate after with the addition of other candidate characters in current first screen candidate's interface display Word set.
- A kind of 19. device for inputting word in a mobile device, it is characterised in that including:Word-dividing mode, for when listening to the trigger event specified, word segmentation processing to be carried out to the word for having selected upper screen recently, Obtain input participle;Second acquisition module, for when receiving the selection instruction for the input participle, obtaining the input participle pair The key-press input string answered;Second removing module, for the length according to the input participle and the key-press input string, is deleted in current interface The input participle;Second returns to module, for returning to the input information of the corresponding candidate of the key-press input string;Wherein, the input information of the candidate includes:In the first screen candidate character set that current interface is shown, the first screen candidate Word set does not include the input and segments.
- 20. device according to claim 19, it is characterised in that the trigger event specified includes but not limited to following At least one:In the specified gesture event for specifying region, the function button event specified, mobile equipment rollover event, the voice thing specified Part.
- 21. device according to claim 19, it is characterised in that second acquisition module includes:Second extracting sub-module, is buffered in the heap region of mobile device memory in advance in word candidate recently for extracting , the input segments corresponding key-press input string.
- 22. device according to claim 19, it is characterised in that second removing module includes:Second length acquisition submodule, for obtaining the length of the input participle;Second text information acquisition submodule, for using the getTextBeforeCursor side in InputConnection classes The text information identical with the length before method acquisition current cursor;Second text information deletes submodule, for when the text information is matched with the input participle, calling DeleteSurroundingText methods in InputConnection objects delete the text information.
- 23. according to the device described in claim 19 or 20 or 21 or 22, it is characterised in that the input information of the candidate includes In the first screen candidate character set of current first screen candidate's interface display;The second return module includes:Second searches submodule, for searching the corresponding first screen candidate character set of the key-press input string;3rd display sub-module, in first screen candidate character set described in current first screen candidate's interface display.
- 24. according to the device described in claim 19 or 20 or 21 or 22, it is characterised in that the input information of the candidate includes In the first screen candidate character set of current first screen candidate's interface display, the second return module includes:Second deletes submodule, for the input participle to be removed from the first screen candidate character set;Second addition submodule, for adding other candidate characters in the first screen candidate character set;4th display sub-module, for the first screen candidate after with the addition of other candidate characters in current first screen candidate's interface display Word set.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410143794.7A CN103941979B (en) | 2014-04-10 | 2014-04-10 | A kind of method and apparatus for inputting word in a mobile device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410143794.7A CN103941979B (en) | 2014-04-10 | 2014-04-10 | A kind of method and apparatus for inputting word in a mobile device |
Publications (2)
Publication Number | Publication Date |
---|---|
CN103941979A CN103941979A (en) | 2014-07-23 |
CN103941979B true CN103941979B (en) | 2018-05-04 |
Family
ID=51189665
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201410143794.7A Active CN103941979B (en) | 2014-04-10 | 2014-04-10 | A kind of method and apparatus for inputting word in a mobile device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN103941979B (en) |
Families Citing this family (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104461056B (en) * | 2014-12-22 | 2018-06-01 | 联想(北京)有限公司 | A kind of information processing method and electronic equipment |
CN104571863A (en) * | 2014-12-30 | 2015-04-29 | 北京奇虎科技有限公司 | Cursor operation method and device for input method |
CN106383594A (en) * | 2016-09-30 | 2017-02-08 | 珠海市魅族科技有限公司 | Input method and device |
CN109471539B (en) * | 2018-10-23 | 2023-06-06 | 维沃移动通信有限公司 | Input content modification method and mobile terminal |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101387919A (en) * | 2008-10-17 | 2009-03-18 | 腾讯科技(深圳)有限公司 | System and method for resuming deleted characters |
CN101694608A (en) * | 2008-12-04 | 2010-04-14 | 北京搜狗科技发展有限公司 | Input method and system of same |
CN102193645A (en) * | 2010-03-16 | 2011-09-21 | 腾讯科技(深圳)有限公司 | Character inputting method and system |
CN102810095A (en) * | 2011-06-02 | 2012-12-05 | 北京搜狗科技发展有限公司 | Word learning method and device |
CN103365905A (en) * | 2012-04-06 | 2013-10-23 | 腾讯科技(深圳)有限公司 | Method and device for correcting word bank data of input method |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US8564541B2 (en) * | 2009-03-16 | 2013-10-22 | Apple Inc. | Zhuyin input interface on a device |
-
2014
- 2014-04-10 CN CN201410143794.7A patent/CN103941979B/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101387919A (en) * | 2008-10-17 | 2009-03-18 | 腾讯科技(深圳)有限公司 | System and method for resuming deleted characters |
CN101694608A (en) * | 2008-12-04 | 2010-04-14 | 北京搜狗科技发展有限公司 | Input method and system of same |
CN102193645A (en) * | 2010-03-16 | 2011-09-21 | 腾讯科技(深圳)有限公司 | Character inputting method and system |
CN102810095A (en) * | 2011-06-02 | 2012-12-05 | 北京搜狗科技发展有限公司 | Word learning method and device |
CN103365905A (en) * | 2012-04-06 | 2013-10-23 | 腾讯科技(深圳)有限公司 | Method and device for correcting word bank data of input method |
Also Published As
Publication number | Publication date |
---|---|
CN103941979A (en) | 2014-07-23 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN104090652B (en) | A kind of pronunciation inputting method and device | |
CN108664201B (en) | Text editing method and device and electronic equipment | |
CN103324674B (en) | Web page contents choosing method and device | |
CN103902057B (en) | Webpage input method and device for mobile terminal device | |
CN103941979B (en) | A kind of method and apparatus for inputting word in a mobile device | |
CN112817676B (en) | Information processing method and electronic device | |
KR20160125401A (en) | Inline and context aware query box | |
CN104461348B (en) | Information choosing method and device | |
CN107368511A (en) | A kind of information displaying method and device | |
CN104182469A (en) | Method for annotating document and input system | |
CN104199606A (en) | Sliding input method and device | |
CN104216646A (en) | Method and device for creating application program based on gesture | |
CN104133815B (en) | The method and system of input and search | |
CN105117159B (en) | A kind of character processing method and terminal | |
CN105069013A (en) | Control method and device for providing input interface in search interface | |
CN104063071A (en) | Content input method and device | |
CN106033301B (en) | Application program desktop management method and touch screen terminal | |
CN102902711B (en) | The generation of the general masterplate of a kind of pragmatic keyword, application process and device | |
CN103399766A (en) | Method and device for updating input method system | |
CN102981689B (en) | A kind of methods, devices and systems for realizing default focus positioning | |
CN104267867A (en) | Content input method and device | |
CN104298654A (en) | Method and device for displaying information | |
US10140265B2 (en) | Apparatuses and methods for phone number processing | |
CN105589570B (en) | A kind of method and apparatus handling input error | |
CN105843414A (en) | Input correction method for input method and input method device |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |