CN106293368B - Data processing method and electronic equipment - Google Patents

Data processing method and electronic equipment Download PDF

Info

Publication number
CN106293368B
CN106293368B CN201510274973.9A CN201510274973A CN106293368B CN 106293368 B CN106293368 B CN 106293368B CN 201510274973 A CN201510274973 A CN 201510274973A CN 106293368 B CN106293368 B CN 106293368B
Authority
CN
China
Prior art keywords
symbol
target
document
target symbol
input
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
Application number
CN201510274973.9A
Other languages
Chinese (zh)
Other versions
CN106293368A (en
Inventor
戴海生
过晓冰
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Lenovo Beijing Ltd
Original Assignee
Lenovo Beijing Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Lenovo Beijing Ltd filed Critical Lenovo Beijing Ltd
Priority to CN201510274973.9A priority Critical patent/CN106293368B/en
Publication of CN106293368A publication Critical patent/CN106293368A/en
Application granted granted Critical
Publication of CN106293368B publication Critical patent/CN106293368B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • User Interface Of Digital Computer (AREA)
  • Document Processing Apparatus (AREA)

Abstract

The invention discloses a data processing method and electronic equipment, wherein the method comprises the following steps: receiving first input content of a user on a document; determining the cursor position in the document according to the first input content; determining a first target symbol in the document based on the cursor position; acquiring a second target symbol input by a user; replacing the first target symbol with the second target symbol. The invention completes the modification of the first target symbol, namely, the modification to the second target symbol under the condition of not needing the operation of selecting or deleting the first target symbol by the user, therefore, compared with the technical scheme that the user needs to manually select or delete the first target symbol and then input the second target symbol during document editing in the prior art, the invention can obviously save the operation steps and improve the editing efficiency.

Description

Data processing method and electronic equipment
Technical Field
The present invention relates to the field of data processing technologies, and in particular, to a data processing method and an electronic device.
Background
In the existing text paragraph editing scheme, when punctuation marks need to be modified, a user is usually required to manually delete punctuation marks to be modified and then input correct punctuation marks, or the punctuation marks to be modified need to be selected and then input correct punctuation marks, so that the operation is complex and the efficiency is low.
Disclosure of Invention
The invention aims to provide a data processing method and electronic equipment, which are used for solving the technical problems of complex operation and low efficiency when punctuation marks need to be modified in a text paragraph editing scheme in the prior art.
The invention provides a data processing method, which comprises the following steps:
receiving first input content of a user on a document;
determining the cursor position in the document according to the first input content;
determining a first target symbol in the document based on the cursor position;
acquiring a second target symbol input by a user;
replacing the first target symbol with the second target symbol.
The method preferably, the receiving of the first input content of the document by the user includes:
receiving voice input information of a user to a document;
first input content in the speech input information is identified.
The method preferably further includes, after the obtaining the second target symbol input by the user, the step of:
and judging whether the text information corresponding to the cursor position in the document meets a preset symbol modification rule, if so, replacing the first target symbol with the second target symbol, and otherwise, writing the second target symbol into the cursor position.
The method preferably further comprises the following steps: and the text information corresponding to the cursor position only has the first target symbol.
The method preferably further comprises the following steps: and the first target symbol in the text information corresponding to the cursor position does not belong to any symbol combination meeting the symbol combination rule.
The method preferably further comprises, after replacing the first target symbol with the second target symbol:
displaying a symbol candidate area in a display interface of the document, wherein the symbol candidate area comprises at least one candidate symbol;
acquiring selection operation data of a user on the symbol candidate area;
and writing the target candidate symbol corresponding to the selection operation data into the document.
In the above method, preferably, the acquiring the second target symbol input by the user includes:
receiving touch operation data of a user;
identifying an operation track in the touch operation data;
and matching the operation track with each symbol in a preset symbol list one by one to obtain a second target symbol of which the matching degree with the operation track meets a preset matching rule.
Preferably, in the above method, when the matching degree between each symbol in the symbol list and the operation track does not satisfy the matching rule, the method further includes:
and determining the symbol with the highest matching degree with the operation track as a second target symbol.
The present invention also provides an electronic device, comprising:
the content receiving unit is used for receiving first input content of a user on a document;
the cursor determining unit is used for determining the cursor position in the document according to the first input content;
a symbol determination unit for determining a first target symbol in the document based on the cursor position;
the symbol obtaining unit is used for obtaining a second target symbol input by a user;
a symbol replacing unit for replacing the first target symbol with the second target symbol.
In the above electronic device, preferably, the content receiving unit includes:
the voice receiving subunit is used for receiving voice input information of a user to the document;
and the voice recognition subunit is used for recognizing the first input content in the voice input information.
The electronic device preferably further includes:
the rule judging unit is used for judging whether the text information corresponding to the cursor position in the document meets a preset symbol modification rule or not after the symbol acquiring unit acquires a second target symbol input by a user, if so, the symbol replacing unit is triggered, and if not, the symbol writing unit is triggered;
and the symbol writing unit is used for writing the second target symbol into the cursor position.
In the electronic device, preferably, the symbol modification rule includes: the text information corresponding to the cursor position comprises only the first target symbol;
in the electronic device, preferably, the symbol modification rule includes: and the first target symbol in the text information corresponding to the cursor position does not belong to any symbol combination meeting the symbol combination rule.
The electronic device preferably further includes:
a candidate display unit, configured to display a symbol candidate region in a display interface of the document after the symbol replacing unit replaces the first target symbol with the second target symbol, where the symbol candidate region includes at least one candidate symbol;
an operation acquisition unit for acquiring selection operation data of a user on the symbol candidate region;
and the candidate writing unit is used for writing the target candidate symbol corresponding to the selection operation data into the document.
Preferably, in the electronic device, the symbol acquiring unit includes:
the touch receiving subunit is used for receiving touch operation data of a user;
a track identification subunit, configured to identify an operation track in the touch operation data;
and the symbol matching subunit is used for matching the operation track with each symbol in a preset symbol list one by one to obtain a second target symbol, wherein the matching degree of the second target symbol with the operation track meets a preset matching rule.
In the above electronic device, preferably, the symbol acquiring unit further includes:
and the symbol determining subunit is used for determining the symbol with the highest matching degree with the operation track as a second target symbol.
According to the above scheme, the data processing method and the electronic device provided by the invention have the advantages that the current cursor position in the document is determined after the first input content of the document by the user is received, the first target symbol corresponding to the cursor position is further determined, the first target symbol can be replaced by the second target symbol after the second target symbol input by the user is obtained, and the modification of the first target symbol is completed, namely the second target symbol is modified under the condition that the user does not need to select the first target symbol or delete the first target symbol.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the provided drawings without creative efforts.
Fig. 1 is a flowchart of a first embodiment of a data processing method according to the present invention;
FIG. 2 is a partial flowchart of a second embodiment of a data processing method according to the present invention;
FIG. 3 is a flowchart of a third embodiment of a data processing method according to the present invention
FIG. 4 is a flowchart illustrating a fourth embodiment of a data processing method according to the present invention;
FIG. 5 is a partial flowchart of a fifth embodiment of a data processing method according to the present invention;
fig. 6 is a partial flowchart of a sixth embodiment of a data processing method according to the present invention;
fig. 7 is a schematic structural diagram of a seventh embodiment of an electronic device according to the present invention;
fig. 8 is a schematic partial structural diagram of an eighth embodiment of an electronic device according to the present invention;
fig. 9 is a schematic structural diagram of a ninth embodiment of an electronic device according to the present invention;
fig. 10 is a schematic structural diagram of a tenth embodiment of an electronic device according to the present invention;
fig. 11 is a schematic partial structural diagram of an eleventh electronic device according to an embodiment of the present invention;
fig. 12 is a schematic partial structural diagram of a twelfth embodiment of an electronic device according to the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Referring to fig. 1, a flowchart of a first embodiment of a data processing method provided by the present invention is shown, where the method in this embodiment is suitable for an application of modifying a special symbol in a document, such as a punctuation mark or a mathematical symbol.
In this embodiment, the method may include the steps of:
step 101: first input content of a user to a document is received.
The first input content may be a content that is input through a voice device and is further recognized, or may be a content that is input through a keyboard device or a touch device and is further recognized. In practical applications, the first input content may include character contents such as chinese characters and english words, and contents such as punctuation marks following the character contents.
In addition, the first input content may be, besides the content recognized and input in the above manner, an operation input that the user clicks a certain position in the document, for example, the user clicks a certain position in the document through a mouse, and the click operation input is received by the embodiment, and the corresponding symbol needs to be modified in the position.
Step 102: and determining the cursor position in the document according to the first input content.
Specifically, in this embodiment, the last input position in the first input content is determined, and the position after the last input position is determined as the current cursor position of the document.
Step 103: based on the cursor position, a first target symbol in the document is determined.
Specifically, in this embodiment, the previous character or the next character of the cursor position may be determined as the first target symbol in the document, that is, the symbol that needs to be modified.
Step 104: and acquiring a second target symbol input by the user.
Specifically, in this embodiment, an input operation of the user may be received through the touch sensing device, and then the second target symbol corresponding to the input operation is recognized, for example, the user writes or clicks the input exclamation mark "| through the touch screen! ", this symbol is recognized in this embodiment and determined as the second target symbol.
Step 105: replacing the first target symbol with the second target symbol.
That is to say, in this embodiment, after receiving first input content of a document by a user, a current cursor position in the document is determined, and then a first target symbol corresponding to the cursor position is determined, and after obtaining the second target symbol input by the user, the first target symbol may be replaced by the second target symbol, and the first target symbol may be modified, that is, modified into the second target symbol, without an operation of selecting or deleting the first target symbol by the user.
It can be seen from the foregoing solution that, in the first embodiment of the data processing method provided by the present invention, after receiving a first input content of a document by a user, a current cursor position in the document is determined, and then a first target symbol corresponding to the cursor position is determined, and after a second target symbol input by the user is obtained, the first target symbol may be replaced by the second target symbol, and under a condition that the user does not need to select the first target symbol or delete the first target symbol, the first target symbol is modified, that is, the second target symbol is modified.
Referring to fig. 2, it is a flowchart of the implementation of step 101 in the second embodiment of the data processing method provided by the present invention, where step 101 may be implemented by the following steps:
step 111: and receiving voice input information of a user to the document.
Specifically, in this embodiment, the voice input information of the user is received through a voice collecting device such as a microphone.
Step 112: first input content in the speech input information is identified.
Specifically, in this embodiment, characters such as chinese characters or letters in the voice input information are recognized by the voice recognition device to obtain character contents in the first input content, and then punctuation marks corresponding to the character contents are generated according to a preset semantic rule, for example, the character contents "you are eating" in the first input content are recognized by the voice recognition device, and the punctuation marks corresponding to the character contents are generated by the voice recognition device according to the semantic rule. "character content" you have a meal "and punctuation". "constitutes the first input content.
Wherein, the embodiment determines the cursor position in the document after receiving the input content, such as determining that the first input content "you are eating. "the latter position is the cursor position, and further determines the first target symbol corresponding to the cursor position". "followed by a second target symbol of user input"? "replace the first target symbol". ", for the purpose of modification of punctuation symbols automatically output for speech recognition.
Referring to fig. 3, a flowchart of a third embodiment of a data processing method provided by the present invention is shown, where after the step 104 and before the step 105, the method further includes the following steps:
step 106: and judging whether the text information corresponding to the cursor position in the document meets a preset symbol modification rule, if so, executing the step 105, and otherwise, executing the step 107.
The text information corresponding to the cursor position refers to text information at a position adjacent to the cursor position, such as symbol or character information before and after the cursor.
Specifically, the preset symbol modification rule may be: and the text information corresponding to the cursor position only has the first target symbol.
For example, in this embodiment, it is determined whether there is one and only one symbol, that is, the first target symbol, in the symbols or characters before and after the cursor position, and when there is one and only the first target symbol in the symbols or characters before and after the cursor position, the step 105 is executed, and when there are other symbols, that is, at least two consecutive symbols, in addition to the first target symbol, in the symbols or characters before and after the cursor position, the step 107 is executed.
In addition, the preset symbol modification rule may also be: and the first target symbol in the text information corresponding to the cursor position does not belong to any symbol combination meeting the symbol combination rule.
For example, in this embodiment, it is determined whether the first target symbol in the symbols or characters before and after the cursor position does not belong to any symbol combination satisfying the symbol combination rule, for example, it is determined whether the first target symbol is a partial symbol composition in a certain symbol combination, such as a partial symbol in a common symbol combination (double quotation marks) where the double quotation marks are the former double quotation marks, when the first target symbol does not belong to any symbol combination, step 105 is executed, and when the first target symbol belongs to a certain symbol combination, step 107 is executed.
Step 107: writing the second target symbol to the cursor position.
That is to say, in this embodiment, it is determined whether the text information corresponding to the cursor position satisfies a symbol modification rule, and if not, the text information is not modified, but the second target symbol is written into the cursor position, and only if so, the step 105 is executed to replace the first target symbol with the second target symbol.
For example, in this embodiment, it is determined whether symbols before and after the cursor position are consecutive punctuation symbols or belong to a certain symbol combination, when the symbols before and after the cursor are consecutive punctuation symbols or belong to a certain symbol combination, the second target symbol is written into the cursor position without performing symbol modification, and only when the first target symbol before and after the cursor is a single symbol and does not belong to any symbol combination, the symbol modification is performed, and the first target symbol is replaced with the second target symbol.
Referring to fig. 4, a flowchart of a fourth embodiment of the data processing method provided by the present invention is shown, where after the step 105, the method may further include the following steps:
step 108: and displaying a symbol candidate area in a display interface of the document, wherein the symbol candidate area comprises at least one candidate symbol.
The candidate symbols in the symbol candidate area may include the first target symbol, that is, in this embodiment, the replaced first target symbol is placed in the symbol candidate area, and is selected by the user to determine whether to perform writing.
It should be noted that the position of the symbol candidate region may correspond to the cursor position in the document, for example, the symbol candidate region is located at the lower right of the cursor position, i.e., the upper left corner of the symbol candidate region is opposite to or adjacent to the lower right corner of the cursor position.
Preferably, the first target symbol in the symbol candidate region is located at the first position of the symbol candidate region, and is used as a prompt for user preference.
Step 109: and acquiring selection operation data of the user on the symbol candidate area.
That is to say, in this embodiment, at least one candidate symbol is displayed on the symbol candidate region, where the candidate symbol may include the first target symbol, and may also include other candidate symbols whose similarity with the first target symbol or with the second target symbol satisfies a similarity threshold, and a user performs a selection operation on the symbol candidate region to select a candidate symbol that the user wants to write, where this embodiment acquires selection operation data of the user.
Step 110: and writing the target candidate symbol corresponding to the selection operation data into the document.
That is, after acquiring the selection operation data of the user, the present embodiment identifies this selection operation data to obtain that the target candidate symbol corresponding to the selection operation data is written into the document, for example, the first target symbol selected by the user is written into the document.
Specifically, in this embodiment, the target candidate symbol may be written in front of the second target symbol, or behind the second target symbol, and this selection may be set by the user in advance according to habits or requirements.
Referring to fig. 5, a flowchart of implementing the step 104 in a fifth embodiment of the data processing method provided by the present invention is shown, where the step 104 may include the following steps:
step 141: and receiving touch operation data of a user.
The touch operation data may be operation data written by a user on the touch screen, or may be click operation data on the touch screen.
Step 142: and identifying an operation track in the touch operation data.
The operation track is a writing track of a user on the touch screen.
Step 143: and matching the operation track with each symbol in a preset symbol list one by one to obtain a second target symbol of which the matching degree with the operation track meets a preset matching rule.
The symbol list may include a plurality of punctuation symbols, so as to achieve the purpose of identifying the corresponding punctuation symbols from the operation track. That is to say, in this embodiment, symbols such as punctuation marks are preferentially identified for the operation tracks in the touch operation data of the user, so that a symbol whose matching degree with the operation track satisfies the matching rule (for example, a symbol whose matching degree is higher than a preset matching threshold) is used as a second target symbol, and the first target symbol is replaced with the second target symbol in the following process.
In addition, when the matching degree between the operation track and any one of the symbols in the symbol list cannot reach the matching threshold, the subsequent replacement step is not executed, and the characters corresponding to the operation track or other alphabetic characters are identified and written into the document.
Referring to fig. 6, a flowchart of step 104 in a sixth embodiment of the data processing method provided by the present invention is shown, where in step 143, when a matching degree between each symbol in the symbol list and the operation track does not satisfy the matching rule, the method may further include the following steps:
step 144: and determining the symbol with the highest matching degree with the operation track as a second target symbol.
That is to say, in the present embodiment, when the operation trajectory is identified, only punctuation marks are identified, and therefore, even if the matching degree between each symbol in the symbol sequence and the operation trajectory does not satisfy the matching rule, the symbol with the highest matching degree is determined as the second target symbol, and a subsequent symbol replacement scheme is executed, thereby implementing the present embodiment.
Referring to fig. 7, a schematic structural diagram of a seventh embodiment of the electronic device according to the present invention is provided, where the electronic device is suitable for an application of modifying a special symbol of a document other than a character, such as a punctuation mark or a mathematical symbol.
In this embodiment, the electronic device may include the following structure:
a content receiving unit 701, configured to receive a first input content of a document by a user.
The first input content may be a content that is input through a voice device and is further recognized, or may be a content that is input through a keyboard device or a touch device and is further recognized. In practical applications, the first input content may include character contents such as chinese characters and english words, and contents such as punctuation marks following the character contents.
In addition, the first input content may be, besides the content recognized and input in the above manner, an operation input that the user clicks a certain position in the document, for example, the user clicks a certain position in the document through a mouse, and the click operation input is received by the embodiment, and the corresponding symbol needs to be modified in the position.
A cursor determining unit 702, configured to determine a cursor position in the document according to the first input content.
Specifically, in this embodiment, the last input position in the first input content is determined, and the position after the last input position is determined as the current cursor position of the document.
A symbol determining unit 703, configured to determine a first target symbol in the document based on the cursor position.
Specifically, in this embodiment, the previous character or the next character of the cursor position may be determined as the first target symbol in the document, that is, the symbol that needs to be modified.
A symbol obtaining unit 704, configured to obtain a second target symbol input by the user.
Specifically, in this embodiment, an input operation of the user may be received through the touch sensing device, and then the second target symbol corresponding to the input operation is recognized, for example, the user writes or clicks the input exclamation mark "| through the touch screen! ", this symbol is recognized in this embodiment and determined as the second target symbol.
A symbol replacing unit 705, configured to replace the first target symbol with the second target symbol.
That is to say, in this embodiment, after receiving first input content of a document by a user, a current cursor position in the document is determined, and then a first target symbol corresponding to the cursor position is determined, and after obtaining the second target symbol input by the user, the first target symbol may be replaced by the second target symbol, and the first target symbol may be modified, that is, modified into the second target symbol, without an operation of selecting or deleting the first target symbol by the user.
It can be seen from the foregoing that, in an embodiment of the electronic device provided by the present invention, after receiving first input content of a document by a user, a current cursor position in the document is determined, and then a first target symbol corresponding to the cursor position is determined, and after a second target symbol input by the user is obtained, the first target symbol may be replaced by the second target symbol, and under a condition that an operation of selecting or deleting the first target symbol by the user is not required, a modification of the first target symbol is completed, that is, the first target symbol is modified to the second target symbol.
Referring to fig. 8, a schematic structural diagram of the content receiving unit 701 in an eighth embodiment of the electronic device provided by the present invention is shown, where the content receiving unit 701 may include the following structures:
and a voice receiving subunit 711, configured to receive voice input information of the document from the user.
Specifically, in this embodiment, the voice input information of the user is received through a voice collecting device such as a microphone.
And a speech recognition subunit 712, configured to recognize the first input content in the speech input information.
Specifically, in this embodiment, characters such as chinese characters or letters in the voice input information are recognized by the voice recognition device to obtain character contents in the first input content, and then punctuation marks corresponding to the character contents are generated according to a preset semantic rule, for example, the character contents "you are eating" in the first input content are recognized by the voice recognition device, and the punctuation marks corresponding to the character contents are generated by the voice recognition device according to the semantic rule. "character content" you have a meal "and punctuation". "constitutes the first input content.
Wherein, the embodiment determines the cursor position in the document after receiving the input content, such as determining that the first input content "you are eating. "the latter position is the cursor position, and further determines the first target symbol corresponding to the cursor position". "followed by a second target symbol of user input"? "replace the first target symbol". ", for the purpose of modification of punctuation symbols automatically output for speech recognition.
Referring to fig. 9, a schematic structural diagram of a ninth embodiment of an electronic device provided by the present invention is shown, where the electronic device may include the following structures:
a rule determining unit 706, configured to determine, after the symbol obtaining unit 704 obtains a second target symbol input by a user, whether text information corresponding to the cursor position in the document meets a preset symbol modification rule, if so, trigger the symbol replacing unit 705, and otherwise, trigger the symbol writing unit 707.
The text information corresponding to the cursor position refers to text information at a position adjacent to the cursor position, such as symbol or character information before and after the cursor.
Specifically, the preset symbol modification rule may be: and the text information corresponding to the cursor position only has the first target symbol.
For example, in this embodiment, it is determined whether there is one and only one symbol, that is, the first target symbol, in the symbols or characters before and after the cursor position, and then when there is one and only the first target symbol in the symbols or characters before and after the cursor, the symbol replacement unit 705 is triggered, and when there are other symbols, that is, at least two consecutive symbols, in addition to the first target symbol, in the symbols or characters before and after the cursor, the symbol writing unit 707 is triggered.
In addition, the preset symbol modification rule may also be: and the first target symbol in the text information corresponding to the cursor position does not belong to any symbol combination meeting the symbol combination rule.
For example, in this embodiment, it is determined whether a first target symbol in the symbols or characters before and after the cursor position does not belong to any symbol combination that satisfies the symbol combination rule, for example, it is determined whether the first target symbol is a partial symbol composition in a certain symbol combination, such as a partial symbol in a common symbol combination (double quotation marks) with a double quotation mark, when the first target symbol does not belong to any symbol combination, the symbol replacement unit 705 is triggered, and when the first target symbol belongs to a certain symbol combination, the symbol writing unit 707 is triggered.
A symbol writing unit 707 for writing the second target symbol to the cursor position.
That is to say, in this embodiment, it is determined whether the text information corresponding to the cursor position satisfies a symbol modification rule, and if not, the text information is not modified, but the second target symbol is written into the cursor position, and only if it is satisfied, the symbol replacement unit 705 is triggered to replace the first target symbol with the second target symbol.
For example, in this embodiment, it is determined whether symbols before and after the cursor position are consecutive punctuation symbols or belong to a certain symbol combination, when the symbols before and after the cursor are consecutive punctuation symbols or belong to a certain symbol combination, the second target symbol is written into the cursor position without performing symbol modification, and only when the first target symbol before and after the cursor is a single symbol and does not belong to any symbol combination, the symbol modification is performed, and the first target symbol is replaced with the second target symbol.
Referring to fig. 10, a schematic structural diagram of an electronic device according to a tenth embodiment of the present invention is shown, where the electronic device may further include the following structure:
a candidate displaying unit 708, configured to display a symbol candidate region in the display interface of the document after the symbol replacing unit 705 replaces the first target symbol with the second target symbol, where the symbol candidate region includes at least one candidate symbol.
The candidate symbols in the symbol candidate area may include the first target symbol, that is, in this embodiment, the replaced first target symbol is placed in the symbol candidate area, and is selected by the user to determine whether to perform writing.
It should be noted that the position of the symbol candidate region may correspond to the cursor position in the document, for example, the symbol candidate region is located at the lower right of the cursor position, i.e., the upper left corner of the symbol candidate region is opposite to or adjacent to the lower right corner of the cursor position.
Preferably, the first target symbol in the symbol candidate region is located at the first position of the symbol candidate region, and is used as a prompt for user preference.
An operation acquiring unit 709, configured to acquire selection operation data of the user on the symbol candidate area.
That is to say, in this embodiment, at least one candidate symbol is displayed on the symbol candidate region, where the candidate symbol may include the first target symbol, and may also include other candidate symbols whose similarity with the first target symbol or with the second target symbol satisfies a similarity threshold, and a user performs a selection operation on the symbol candidate region to select a candidate symbol that the user wants to write, where this embodiment acquires selection operation data of the user.
A candidate writing unit 710, configured to write the target candidate symbol corresponding to the selection operation data into the document.
That is, after acquiring the selection operation data of the user, the present embodiment identifies this selection operation data to obtain that the target candidate symbol corresponding to the selection operation data is written into the document, for example, the first target symbol selected by the user is written into the document.
Specifically, in this embodiment, the target candidate symbol may be written in front of the second target symbol, or behind the second target symbol, and this selection may be set by the user in advance according to habits or requirements.
Referring to fig. 11, a schematic structural diagram of the symbol obtaining unit 704 in an eleventh embodiment of the electronic device provided by the present invention is shown, where the symbol obtaining unit 704 may include the following structure:
the touch receiving subunit 741 is configured to receive touch operation data of a user.
The touch operation data may be operation data written by a user on the touch screen, or may be click operation data on the touch screen.
A track identifying subunit 742 is configured to identify an operation track in the touch operation data.
The operation track is a writing track of a user on the touch screen.
The symbol matching subunit 743 is configured to match the operation trajectory with each symbol in a preset symbol list one by one, so as to obtain a second target symbol whose matching degree with the operation trajectory satisfies a preset matching rule.
The symbol list may include a plurality of punctuation symbols, so as to achieve the purpose of identifying the corresponding punctuation symbols from the operation track. That is to say, in this embodiment, symbols such as punctuation marks are preferentially identified for the operation tracks in the touch operation data of the user, so that a symbol whose matching degree with the operation track satisfies the matching rule (for example, a symbol whose matching degree is higher than a preset matching threshold) is used as a second target symbol, and the first target symbol is replaced with the second target symbol in the following process.
In addition, when the matching degree between the operation track and any one of the symbols in the symbol list cannot reach the matching threshold, the subsequent replacement step is not executed, and the characters corresponding to the operation track or other alphabetic characters are identified and written into the document.
Referring to fig. 12, a schematic structural diagram of the symbol obtaining unit 704 in an electronic device according to a twelfth embodiment of the present invention is shown, where the symbol obtaining unit 704 may further include the following structure:
a symbol determination subunit 744, configured to determine, when the matching degree of each symbol in the symbol list and the operation trajectory by the symbol matching subunit 743 does not satisfy the matching rule, a symbol with the highest matching degree with the operation trajectory as a second target symbol.
That is to say, in the present embodiment, when the operation trajectory is identified, only punctuation marks are identified, and therefore, even if the matching degree between each symbol in the symbol sequence and the operation trajectory does not satisfy the matching rule, the symbol with the highest matching degree is determined as the second target symbol, and a subsequent symbol replacement scheme is executed, thereby implementing the present embodiment.
It should be noted that, in the present specification, the embodiments are all described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments may be referred to each other.
Finally, it should also be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
The data processing method and the electronic device provided by the present application are introduced in detail above, and a specific example is applied in the present application to explain the principle and the implementation of the present application, and the description of the above embodiment is only used to help understand the method and the core idea of the present application; meanwhile, for a person skilled in the art, according to the idea of the present application, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present application.

Claims (12)

1. A method of data processing, the method comprising:
receiving first input content of a document by a user, wherein the first input content comprises operation input of the user aiming at a certain position in the document;
according to the first input content, determining a cursor position in the document, wherein the cursor position comprises a last input position in the first input content, and the position behind the input position is determined as the current cursor position of the document;
determining a first target symbol in the document based on the cursor position;
acquiring a second target symbol input by a user through touch operation;
judging whether the text information corresponding to the cursor position in the document meets a preset symbol modification rule, if so, replacing the first target symbol with the second target symbol;
otherwise, writing the second target symbol into the cursor position;
wherein, after replacing the first target symbol with the second target symbol, further comprising: displaying a symbol candidate region in a display interface of the document, wherein the symbol candidate region comprises at least one candidate symbol, and a first target symbol in the symbol candidate region is positioned at a first position of the symbol candidate region;
acquiring selection operation data of a user on the symbol candidate area;
and writing the target candidate symbol corresponding to the selection operation data into the document.
2. The method of claim 1, wherein receiving a first input of a document from a user comprises:
receiving voice input information of a user to a document;
first input content in the speech input information is identified.
3. The method of claim 1, wherein the symbol modification rule comprises: and the text information corresponding to the cursor position only has the first target symbol.
4. The method of claim 1, wherein the symbol modification rule comprises: and the first target symbol in the text information corresponding to the cursor position does not belong to any symbol combination meeting the symbol combination rule.
5. The method of claim 1, wherein obtaining the second target symbol input by the user comprises:
receiving touch operation data of a user;
identifying an operation track in the touch operation data;
and matching the operation track with each symbol in a preset symbol list one by one to obtain a second target symbol of which the matching degree with the operation track meets a preset matching rule.
6. The method according to claim 5, wherein when the matching degree of each symbol in the symbol list with the operation track does not satisfy the matching rule, the method further comprises:
and determining the symbol with the highest matching degree with the operation track as a second target symbol.
7. An electronic device, comprising:
the content receiving unit is used for receiving first input content of a document by a user, wherein the first input content comprises an operation input of the user aiming at a certain position in the document;
the cursor determining unit is used for determining the cursor position in the document according to the first input content, determining the last input position in the first input content, and determining the position behind the input position as the current cursor position of the document;
a symbol determination unit for determining a first target symbol in the document based on the cursor position;
the symbol acquisition unit is used for acquiring a second target symbol input by a user through touch operation;
the rule judging unit is used for judging whether the text information corresponding to the cursor position in the document meets a preset symbol modification rule or not after the symbol acquiring unit acquires a second target symbol input by a user, if so, the symbol replacing unit is triggered, and if not, the symbol writing unit is triggered;
a symbol replacing unit for replacing the first target symbol with the second target symbol;
a symbol writing unit for writing the second target symbol into the cursor position;
a candidate display unit, configured to display a symbol candidate region in a display interface of the document after the symbol replacing unit replaces the first target symbol with the second target symbol, where the symbol candidate region includes at least one candidate symbol;
an operation acquisition unit for acquiring selection operation data of a user on the symbol candidate region;
and the candidate writing unit is used for writing the target candidate symbol corresponding to the selection operation data into the document.
8. The electronic device according to claim 7, wherein the content receiving unit includes:
the voice receiving subunit is used for receiving voice input information of a user to the document;
and the voice recognition subunit is used for recognizing the first input content in the voice input information.
9. The electronic device of claim 7, wherein the symbol modification rule comprises: and the text information corresponding to the cursor position only has the first target symbol.
10. The electronic device of claim 7, wherein the symbol modification rule comprises: and the first target symbol in the text information corresponding to the cursor position does not belong to any symbol combination meeting the symbol combination rule.
11. The electronic device of claim 7, wherein the symbol acquisition unit comprises:
the touch receiving subunit is used for receiving touch operation data of a user;
a track identification subunit, configured to identify an operation track in the touch operation data;
and the symbol matching subunit is used for matching the operation track with each symbol in a preset symbol list one by one to obtain a second target symbol, wherein the matching degree of the second target symbol with the operation track meets a preset matching rule.
12. The electronic device of claim 11, wherein the symbol acquisition unit further comprises:
and the symbol determining subunit is used for determining the symbol with the highest matching degree with the operation track as a second target symbol.
CN201510274973.9A 2015-05-26 2015-05-26 Data processing method and electronic equipment Active CN106293368B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510274973.9A CN106293368B (en) 2015-05-26 2015-05-26 Data processing method and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510274973.9A CN106293368B (en) 2015-05-26 2015-05-26 Data processing method and electronic equipment

Publications (2)

Publication Number Publication Date
CN106293368A CN106293368A (en) 2017-01-04
CN106293368B true CN106293368B (en) 2020-05-26

Family

ID=57634782

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510274973.9A Active CN106293368B (en) 2015-05-26 2015-05-26 Data processing method and electronic equipment

Country Status (1)

Country Link
CN (1) CN106293368B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111563118B (en) * 2019-02-14 2023-09-12 桂林电子科技大学 Automatic data input method and system for obtaining data in real time
CN111859871A (en) * 2020-07-22 2020-10-30 中国联合网络通信集团有限公司 Data processing method, device, equipment and computer readable storage medium

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102866852A (en) * 2012-07-30 2013-01-09 成都西可科技有限公司 Handwriting character input method based on body-sensing technology
CN103473003A (en) * 2013-09-12 2013-12-25 天津三星通信技术研究有限公司 Character input error correction method and device
CN103903618A (en) * 2012-12-28 2014-07-02 联想(北京)有限公司 Voice input method and electronic device

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102866852A (en) * 2012-07-30 2013-01-09 成都西可科技有限公司 Handwriting character input method based on body-sensing technology
CN103903618A (en) * 2012-12-28 2014-07-02 联想(北京)有限公司 Voice input method and electronic device
CN103473003A (en) * 2013-09-12 2013-12-25 天津三星通信技术研究有限公司 Character input error correction method and device

Also Published As

Publication number Publication date
CN106293368A (en) 2017-01-04

Similar Documents

Publication Publication Date Title
US20210406578A1 (en) Handwriting-based predictive population of partial virtual keyboards
US8756527B2 (en) Method, apparatus and computer program product for providing a word input mechanism
US10838513B2 (en) Responding to selection of a displayed character string
CN106325688B (en) Text processing method and device
CN107679032A (en) Voice changes error correction method and device
CN111052064B (en) Method for automatically providing gesture-based auto-completion suggestion and electronic device thereof
CN107861932B (en) Text editing method, device and system and terminal equipment
TW201447731A (en) Ink to text representation conversion
CN102830924B (en) A kind of method and device adjusting entering method keyboard
JP2007265251A (en) Information retrieval device
US20140207453A1 (en) Method and apparatus for editing voice recognition results in portable device
CN109074547B (en) Text message ordering based on message content
CN105138586A (en) File searching method and apparatus
CN105183184A (en) Character processing method and terminal
JP2014149612A (en) Voice recognition error correction device and its program
CN107346183B (en) Vocabulary recommendation method and electronic equipment
CN107977155B (en) Handwriting recognition method, device, equipment and storage medium
WO2016041428A1 (en) Method and device for inputting english
CN111984589A (en) Document processing method, document processing device and electronic equipment
CN105117159A (en) Character processing method and terminal
US20140325350A1 (en) Target area estimation apparatus, method and program
CN104363349A (en) Short message processing method and portable terminal using same
CN106293368B (en) Data processing method and electronic equipment
US20230054848A1 (en) Structural decomposition in handwriting
US10169648B2 (en) Method and device for inputting handwriting character

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