CN106951168B - Word processing method and mobile terminal - Google Patents

Word processing method and mobile terminal Download PDF

Info

Publication number
CN106951168B
CN106951168B CN201710123919.3A CN201710123919A CN106951168B CN 106951168 B CN106951168 B CN 106951168B CN 201710123919 A CN201710123919 A CN 201710123919A CN 106951168 B CN106951168 B CN 106951168B
Authority
CN
China
Prior art keywords
sentences
target
preset
character
coordinate
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
CN201710123919.3A
Other languages
Chinese (zh)
Other versions
CN106951168A (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.)
Yulong Computer Telecommunication Scientific Shenzhen Co Ltd
Original Assignee
Yulong Computer Telecommunication Scientific Shenzhen Co 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 Yulong Computer Telecommunication Scientific Shenzhen Co Ltd filed Critical Yulong Computer Telecommunication Scientific Shenzhen Co Ltd
Priority to CN201710123919.3A priority Critical patent/CN106951168B/en
Publication of CN106951168A publication Critical patent/CN106951168A/en
Application granted granted Critical
Publication of CN106951168B publication Critical patent/CN106951168B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0487Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser
    • G06F3/0488Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures
    • G06F3/04883Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures for inputting data by handwriting, e.g. gesture or text
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0484Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
    • G06F3/04842Selection of displayed objects or displayed text elements
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0487Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser
    • G06F3/0488Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures
    • G06F3/04886Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures by partitioning the display area of the touch-screen or the surface of the digitising tablet into independently controllable areas, e.g. virtual keyboards or menus
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/10Text processing
    • G06F40/166Editing, e.g. inserting or deleting

Abstract

The embodiment of the invention provides a word processing method and a mobile terminal, wherein the method comprises the following steps: determining a target character area in a current displayed page of the touch screen according to the target operation gesture; dividing the characters in the target character area into N sentences according to the position of a preset punctuation mark in the target character area, wherein N is a positive integer; configuring a color for each sentence in the N sentences; and displaying N check boxes at preset positions of the N sentences so that a user can select M sentences in the N sentences, wherein each check box in the N check boxes corresponds to one sentence, and M is a positive integer less than or equal to N. The embodiment of the invention can quickly select any plurality of discontinuous sentences in the target character area to carry out target operation.

Description

Word processing method and mobile terminal
Technical Field
The invention relates to the field of data processing, in particular to a word processing method and a mobile terminal.
Background
In the prior art, a mobile terminal (e.g., a mobile phone, a tablet computer, etc.) can only select one character or one word when the mobile terminal is to process (e.g., copy, share, scribe, etc.) characters displayed on a current screen page, and if a sentence is to be selected, a long-press selection is required, which takes a long time and has a low accuracy. If a plurality of discontinuous sentences need to be processed, the sentences can only be processed for a plurality of times after being selected for a plurality of times, or unnecessary sentences in the sentences can be deleted after a whole section of contents is selected, so that the process is complicated, the operation time is long, and the efficiency is low.
Disclosure of Invention
The embodiment of the invention provides a character processing method and a mobile terminal, which can quickly select any plurality of discontinuous sentences in a target character area.
A first aspect of an embodiment of the present invention provides a method for processing a word, including:
determining a target character area in a current displayed page of the touch screen according to the target operation gesture;
dividing the characters in the target character area into N sentences according to the position of a preset punctuation mark in the target character area, wherein N is a positive integer;
configuring a color for each sentence in the N sentences;
and displaying N check boxes at preset positions of the N sentences so that a user can select M sentences in the N sentences, wherein each check box in the N check boxes corresponds to one sentence, and M is a positive integer less than or equal to N.
With reference to the first aspect of the embodiments of the present invention, in a first possible implementation manner of the first aspect, the target operation gesture is performed by two fingers;
the determining of the target text area in the current page displayed by the touch screen according to the target operation gesture comprises the following steps:
recording a coordinate A and a coordinate B when the two fingers contact a current displayed page of the touch screen and a coordinate C and a coordinate D when the two fingers leave the touch screen;
and determining a page area among the coordinate A, the coordinate B, the coordinate C and the coordinate D as the target character area.
With reference to the first possible implementation manner of the first aspect of the embodiment of the present invention, in a second possible implementation manner of the first aspect, the determining, as the target text area, a page area between the coordinate a, the coordinate B, the coordinate C, and the coordinate D includes:
judging whether the previous character of the initial character in the target character area is a preset punctuation mark or not;
if the previous character of the initial character in the target character area is not the preset punctuation mark, extending the starting point of the target character area to the character on the right side of the previous preset punctuation mark closest to the initial character;
judging whether the ending characters in the target character area are the preset punctuation marks or not;
and if the next character of the ending character in the target character area is not the preset punctuation mark, extending the end point of the target character area to the last next preset punctuation mark of the ending character.
With reference to any one of the first aspect to the second possible implementation manner of the embodiment of the present invention, in a third possible implementation manner of the first aspect, the dividing the text in the target text area into N sentences according to the position of the preset punctuation mark in the target text area includes:
traversing the characters in the target character area, detecting N preset punctuations, and marking the positions of the N preset punctuations;
and dividing the characters in the target character area into N sentences by taking the positions of the N preset punctuations as breakpoints, wherein each sentence comprises one preset punctuation.
With reference to the first aspect of the present invention to any one of the second possible implementation manner of the first aspect, in a fourth possible implementation manner of the first aspect, the configuring, for each sentence of the N sentences, a color includes:
determining the character display color in the target character area;
configuring each sentence in the N sentences with a color different from the display color of the characters;
changing the font color of the N sentences into a configured corresponding color, or changing the filling color of the N sentences into the configured corresponding color.
A second aspect of an embodiment of the present invention provides a mobile terminal, including:
the first determining unit is used for determining a target character area in a current displayed page of the touch screen according to the target operation gesture;
a second determining unit, configured to divide the characters in the target character region into N sentences according to the positions of preset punctuation marks in the target character region, where N is a positive integer;
a configuration unit, configured to configure a color for each sentence in the N sentences;
and the display unit is used for displaying N check boxes at preset positions of the N sentences so that a user can select M sentences in the N sentences, wherein each check box in the N check boxes corresponds to one sentence, and M is a positive integer less than or equal to N.
With reference to the second aspect of the embodiments of the present invention, in a first possible implementation manner of the second aspect, the target operation gesture is performed by two fingers;
the first determination unit includes:
the recording module is used for recording a coordinate A and a coordinate B when the two fingers contact the current displayed page of the touch screen and a coordinate C and a coordinate D when the two fingers leave the current displayed page of the touch screen;
and the first determining module is used for determining a page area among the coordinate A, the coordinate B, the coordinate C and the coordinate D as the target character area.
With reference to the first possible implementation manner of the second aspect of the embodiment of the present invention, in a second possible implementation manner of the second aspect, the first determining module includes:
the first judgment module is used for judging whether the previous character of the initial character in the target character area is a preset punctuation mark or not;
a first extending module, configured to extend the starting point of the target text region to a text on the right side of the previous preset punctuation mark closest to the starting text if the previous text of the starting text in the target text region is not the preset punctuation mark;
the second judgment module is used for judging whether the ending character in the target character area is the preset punctuation mark or not;
and the second extension module is used for extending the end point of the target character area to the last preset punctuation mark nearest to the ending character if the last character of the ending character in the target character area is not the preset punctuation mark.
With reference to any one possible implementation manner of the second aspect of the second embodiment of the present invention to the second aspect of the second embodiment, in a third possible implementation manner of the second aspect, the second determining unit includes:
the detection module is used for traversing the characters in the target character area, detecting N preset punctuations and marking the positions of the N preset punctuations;
and the second determining module is used for dividing the characters in the target character area into N sentences by taking the positions of the N preset punctuations as breakpoints, wherein each sentence comprises one preset punctuation.
With reference to any one possible implementation manner of the second aspect of the second embodiment of the present invention to the second kind of implementation manner of the second aspect, in a fourth possible implementation manner of the second aspect, the configuration unit includes:
the third determining module is used for determining the character display color in the target character area;
a configuration module for configuring a color different from the display color of the character for each sentence in the N sentences;
and the execution module is used for changing the font color of the N sentences into a configured corresponding color, or changing the filling color of the N sentences into the configured corresponding color.
The embodiment of the invention has the following beneficial effects:
according to the embodiment of the invention, the target character area in the current displayed page of the touch screen is determined according to the target operation gesture; dividing the characters in the target character area into N sentences according to the position of a preset punctuation mark in the target character area, wherein N is a positive integer; configuring a color for each sentence in the N sentences; and displaying N check boxes at preset positions of the N sentences so that a user can select M sentences in the N sentences, wherein each check box in the N check boxes corresponds to one sentence, and M is a positive integer less than or equal to N. Therefore, any plurality of discontinuous sentences in the target character area can be quickly selected to perform target operation.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings needed to be used in the description of the embodiments are briefly introduced below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
FIG. 1 is a flowchart illustrating a word processing method according to a first embodiment of the present invention;
FIG. 1-1 is a schematic flow chart illustrating a refinement of step 101 depicted in FIG. 1 according to an embodiment of the present invention;
FIGS. 1-2 are schematic diagrams of a detailed flow chart of step 102 depicted in FIG. 1 provided by an embodiment of the present invention;
FIGS. 1-3 are schematic diagrams of a detailed flow chart of step 103 depicted in FIG. 1 provided by an embodiment of the present invention;
FIGS. 1-4 are schematic diagrams illustrating a target operation gesture of a mobile terminal according to an embodiment of the present invention;
fig. 1-5 are schematic diagrams illustrating a target text area selection performed by a mobile terminal according to an embodiment of the present invention;
fig. 2a is a schematic structural diagram of a mobile terminal according to a first embodiment of the present invention;
fig. 2b is a schematic structural diagram of a first determining unit of the mobile terminal depicted in fig. 2a according to an embodiment of the present invention;
fig. 2c is a schematic structural diagram of a second determining unit of the mobile terminal depicted in fig. 2a according to an embodiment of the present invention;
fig. 2d is a schematic structural diagram of a configuration unit of the mobile terminal depicted in fig. 2a according to an embodiment of the present invention;
fig. 3 is a schematic structural diagram of a mobile terminal according to a second embodiment of 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 some, not all, embodiments of the present invention. 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.
The terms "first," "second," "third," and "fourth," etc. in the description and claims of the invention and in the accompanying drawings are used for distinguishing between different objects and not for describing a particular order. Furthermore, the terms "include" and "have," as well as any variations thereof, are intended to cover non-exclusive inclusions. For example, a process, method, system, article, or apparatus that comprises a list of steps or elements is not limited to only those steps or elements listed, but may alternatively include other steps or elements not listed, or inherent to such process, method, article, or apparatus.
Reference herein to "an embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment can be included in at least one embodiment of the invention. The appearances of the phrase in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. It is explicitly and implicitly understood by one skilled in the art that the embodiments described herein can be combined with other embodiments.
The mobile terminal described in the embodiment of the present invention may include a smart Phone (such as an Android Phone, an iOS Phone, a Windows Phone, etc.), a tablet computer, a palm computer, a notebook computer, a mobile internet device (MID, mobile internet Devices), or a wearable device, and the mobile terminal is merely an example, and is not exhaustive and includes but is not limited to the mobile terminal.
It should be noted that the preset punctuation mark may be. ","! ","? The ' and ' say. ' etc. represent any punctuation mark for ending a complete sentence, so that how many complete sentences exist in the target character area can be determined according to the number of the preset punctuation marks in the target character area.
Fig. 1 is a flowchart illustrating a word processing method according to a first embodiment of the present invention. The word processing method described in this embodiment includes the following steps:
101. and determining a target character area in the current displayed page of the touch screen according to the target operation gesture.
The method comprises the steps that a target operation gesture of a user is used for triggering the mobile terminal to determine a target character area in a currently displayed page, the mobile terminal is preset with an operation gesture, and when the target operation gesture is matched with the operation gesture preset by the mobile terminal, the terminal can execute the determination of the target character area in the currently displayed page.
Alternatively, the target operation gesture may be a sliding of two fingers in the left-right direction of the display screen, as shown in fig. 1-4, and fig. 1-4 are schematic diagrams of a thumb and an index finger of a right hand sliding from left to right on a display page of the display screen. Of course, the target operation gesture may also be other gestures, and the user may implement an effective target operation gesture after performing the setting.
Optionally, as shown in fig. 1-1, the step of determining a target text area in a page currently displayed on the touch screen according to the target operation gesture may include the following steps:
1011. recording a coordinate A and a coordinate B when the two fingers contact a current displayed page of the touch screen and a coordinate C and a coordinate D when the two fingers leave the touch screen;
1012. and determining a page area among the coordinate A, the coordinate B, the coordinate C and the coordinate D as the target character area.
The terminal records position coordinates A and coordinates B when the two fingers just touch the touch screen and position coordinates C and coordinates D when the two fingers leave the touch screen after detecting the target operation gesture.
Alternatively, after determining the coordinate a, the coordinate B, the coordinate C, and the coordinate D, a page area between the four coordinates may be determined as a target text area, and the width of the target text area should be the width of the text displayed on the currently displayed page.
Optionally, the determining a page area among the coordinate a, the coordinate B, the coordinate C, and the coordinate D as the target text area includes:
judging whether the previous character of the initial character in the target character area is a preset punctuation mark or not;
if the previous character of the initial character in the target character area is not the preset punctuation mark, extending the starting point of the target character area to the character on the right side of the previous preset punctuation mark closest to the initial character;
judging whether the ending characters in the target character area are the preset punctuation marks or not;
and if the next character of the ending character in the target character area is not the preset punctuation mark, extending the end point of the target character area to the next preset punctuation mark closest to the ending character.
In this case, it is determined whether the first word in the target word area is a predetermined punctuation mark, where the predetermined punctuation mark may be a period ("-"), an exclamation mark ("|), a question mark ("?, an ellipsis ("..... -") or any punctuation mark representing the end of a complete sentence. If the previous character of the initial character is not the preset punctuation mark, which indicates that the initial character is not the first character of a complete sentence, the starting point of the target character region needs to be extended to the right character of the previous preset punctuation mark closest to the initial character, and the right character is used as a new initial character, which is also the first character of a complete sentence.
Optionally, if the previous word of the initial word is the predetermined punctuation mark, the initial word is the first word of a complete sentence, and the starting point of the target word region does not need to be extended. As shown in fig. 1-4, the starting word is "this" and the word preceding "this" is. ", and". "is a preset punctuation mark, so the starting point of the target character area does not need to be extended.
Optionally, it is determined whether an ending character in the target character region, that is, the last character is a preset punctuation mark, if the ending character is not the preset punctuation mark, it is indicated that a sentence where the ending character is located in the target character region is not a complete sentence, the end point of the target character region needs to be extended, and the end point of the target character region is extended to the next preset punctuation mark closest to the ending character.
Optionally, if the ending character in the target character region is a preset punctuation mark, it represents that the last sentence in the target character region is a complete sentence, and there is no need to extend the end point of the target character region. As shown in fig. 1-4, the end word is. ",". "is a preset punctuation mark, so the end point of the target text region does not need to be extended.
102. And dividing the characters in the target character area into N sentences according to the positions of preset punctuations in the target character area, wherein N is a positive integer.
The number of sentences in the target character area can be determined according to the number of preset punctuation marks representing a complete sentence, such as periods, exclamation marks, question marks, ellipses and the like in the target character area.
Optionally, as shown in fig. 1-2, the dividing the text in the target text area into N sentences according to the position of the preset punctuation mark in the target text area may include the following steps:
1021. traversing the characters in the target character area, detecting N preset punctuations, and marking the positions of the N preset punctuations;
1022. and dividing the characters in the target character area into N sentences by taking the positions of the N preset punctuations as breakpoints, wherein each sentence comprises one preset punctuation.
The method comprises the steps of checking each character in a target character area, marking the position of a preset punctuation mark when the preset punctuation mark is detected, dividing the character in the target area into N sentences by taking the position of the preset punctuation mark as a breakpoint, and dividing each preset punctuation mark into sentences on the left side, wherein each sentence contains one preset punctuation mark. For example, as shown in fig. 1-4, in the target text area in fig. 1-4, the start text is "this" and the end text is ". ", in the target text region, 3 preset punctuation marks are detected". ", according to". "the position divides the text in the target text region into 3 sentences.
103. A color is configured for each of the N sentences.
The color can be configured for each sentence of the determined N sentences in the target character area for distinguishing display, so that a user can know the starting position and the ending position of each sentence at a glance.
Optionally, as shown in fig. 1 to 3, the configuring a color for each sentence in the N sentences may include the following steps:
1031. determining the character display color in the target character area;
1032. configuring each sentence in the N sentences with a color different from the display color of the characters;
1033. changing the font color of the N sentences into a configured corresponding color, or changing the filling color of the N sentences into the configured corresponding color.
The display color of the characters in the current target character area is determined, then a color different from the display color of the current characters is configured for the N sentences, the font color of each sentence in the N sentences can be changed into the configured corresponding color, or the filling color of each sentence in the N sentences can be changed into the configured corresponding color. As shown in fig. 1 to 4, there are 3 sentences in the target text region, the current text display color is black, the first sentence can be configured with green, the second sentence can be configured with yellow, the third sentence can be configured with red, after the color configuration is completed, the filling color of the first sentence can be changed into green, the filling color of the second sentence can be changed into yellow, the filling color of the third sentence can be changed into red, and after each sentence is color-distinguished, the user can read a single sentence in the target text region at a glance.
104. And displaying N check boxes at preset positions of the N sentences so that a user can select M sentences in the N sentences, wherein each check box in the N check boxes corresponds to one sentence, and M is a positive integer less than or equal to N.
The N check boxes can be displayed at preset positions of the N sentences, each sentence corresponds to one check box, the preset positions can be at the beginning of the sentence, in the middle of the sentence or at the end of the sentence, and a user can set the check boxes according to the user himself or drag each sentence on a display page. As shown in fig. 1-5, the checkbox is located at the beginning of each sentence.
Optionally, the user may check M sentences of the N sentences to perform the target operation. The target operation can be operations of marking, copying, sharing, inquiring, editing and the like. As shown in fig. 1 to 5, rectangular boxes for line drawing, copying and sharing are displayed on the page, and the user selects two checkboxes, the first checkbox and the third checkbox, from three checkboxes, so that any one of the three operations can be performed on the first sentence and the third sentence. Meanwhile, by implementing the embodiment of the invention, the user can select a plurality of discontinuous sentences at one time, the target operation can be conveniently executed on the plurality of discontinuous sentences, and the user experience is improved.
Therefore, according to the embodiment of the invention, the target character area in the current displayed page of the touch screen is determined according to the target operation gesture; dividing the characters in the target character area into N sentences according to the position of a preset punctuation mark in the target character area, wherein N is a positive integer; configuring a color for each sentence in the N sentences; and displaying N check boxes at preset positions of the N sentences so that a user can select M sentences in the N sentences, wherein each check box in the N check boxes corresponds to one sentence, and M is a positive integer less than or equal to N. Therefore, any plurality of discontinuous sentences in the target character area can be quickly selected to perform target operation.
In accordance with the above, the following is a device for implementing the word processing method according to the embodiment of the present invention, and specifically includes:
please refer to fig. 2a, which is a schematic structural diagram of an embodiment of a mobile terminal according to an embodiment of the present invention. The mobile terminal described in this embodiment includes: the first determining unit 201, the second determining unit 202, the configuring unit 203 and the displaying unit 204 are as follows:
the first determining unit 201 is configured to determine a target text area in a currently displayed page of the touch screen according to the target operation gesture;
a second determining unit 202, configured to divide the text in the target text region into N sentences according to the position of a preset punctuation mark in the target text region, where N is a positive integer;
a configuration unit 203, configured to configure a color for each sentence in the N sentences;
the display unit 204 is configured to display N check boxes at preset positions of the N sentences for a user to select M sentences of the N sentences, where each check box of the N check boxes corresponds to one sentence, and M is a positive integer smaller than or equal to N.
Alternatively, as shown in fig. 2b, the first determining unit 201 of the mobile terminal depicted in fig. 2a may include: the recording module 2011 and the first determining module 2012 are as follows:
a recording module 2011, configured to record a coordinate a and a coordinate B when the two fingers contact the currently displayed page of the touch screen, and a coordinate C and a coordinate D when the two fingers leave the currently displayed page of the touch screen;
a first determining module 2012, configured to determine a page area between the coordinate a, the coordinate B, the coordinate C, and the coordinate D as the target text area.
Further, the first determining module 2012 may include: the first determining module (not shown), the first extending module (not shown), the second determining module (not shown) and the second extending module (not shown) are as follows:
the first judgment module is used for judging whether the previous character of the initial character in the target character area is a preset punctuation mark or not;
a first extending module, configured to extend the starting point of the target text region to a text on the right side of the previous preset punctuation mark closest to the starting text if the previous text of the starting text in the target text region is not the preset punctuation mark;
the second judgment module is used for judging whether the ending character in the target character area is the preset punctuation mark or not;
and the second extension module is used for extending the end point of the target character area to the last preset punctuation mark nearest to the ending character if the last character of the ending character in the target character area is not the preset punctuation mark.
Alternatively, as shown in fig. 2c, the second determining unit 202 of the mobile terminal depicted in fig. 2a may comprise: the detection module 2021 and the second determination module 2022 are specifically as follows:
the detection module 2021 is configured to traverse the text in the target text region, detect N preset punctuations, and mark positions of the N preset punctuations;
the second determining module 2022 is configured to divide the text in the target text region into N sentences with the positions of the N preset punctuations as breakpoints, where each sentence includes one preset punctuation.
Alternatively, as shown in fig. 2d, the configuration unit 203 of the mobile terminal depicted in fig. 2a may include: the third determining module 2031, the configuring module 2032, and the executing module 2033 are specifically as follows:
a third determining module 2031, configured to determine a text display color in the target text area;
a configuring module 2032, configured to configure, for each sentence in the N sentences, a color different from the display color of the text;
an executing module 2033, configured to change the font color of the N sentences into a configured corresponding color, or change the filling color of the N sentences into the configured corresponding color.
Therefore, according to the embodiment of the invention, the target character area in the current displayed page of the touch screen is determined according to the target operation gesture; dividing the characters in the target character area into N sentences according to the position of a preset punctuation mark in the target character area, wherein N is a positive integer; configuring a color for each sentence in the N sentences; and displaying N check boxes at preset positions of the N sentences so that a user can select M sentences in the N sentences, wherein each check box in the N check boxes corresponds to one sentence, and M is a positive integer less than or equal to N. Therefore, any plurality of discontinuous sentences in the target character area can be quickly selected to perform target operation.
Please refer to fig. 3, which is a schematic structural diagram of a mobile terminal according to a second embodiment of the present invention. The mobile terminal described in this embodiment includes: at least one input device 1000; at least one output device 2000; at least one processor 3000, e.g., a CPU; and a memory 4000, the input device 1000, the output device 2000, the processor 3000, and the memory 4000 being connected by a bus 5000.
The input device 1000 may be a touch panel, a physical button, or a mouse.
The output device 2000 may be a display screen.
The memory 4000 may be a high-speed RAM memory or a non-volatile memory (e.g., a magnetic disk memory). The memory 4000 is used for storing a set of program codes, and the input device 1000, the output device 2000 and the processor 3000 are used for calling the program codes stored in the memory 4000 to execute the following operations:
the processor 3000 is configured to:
determining a target character area in a current displayed page of the touch screen according to the target operation gesture;
dividing the characters in the target character area into N sentences according to the position of a preset punctuation mark in the target character area, wherein N is a positive integer;
configuring a color for each sentence in the N sentences;
and displaying N check boxes at preset positions of the N sentences so that a user can select M sentences in the N sentences, wherein each check box in the N check boxes corresponds to one sentence, and M is a positive integer less than or equal to N.
Optionally, the processor 3000 determines, according to the target operation gesture, a target text area in a currently displayed page of the touch screen, where the determining includes:
recording a coordinate A and a coordinate B when the two fingers contact a current displayed page of the touch screen and a coordinate C and a coordinate D when the two fingers leave the touch screen;
and determining a page area among the coordinate A, the coordinate B, the coordinate C and the coordinate D as the target character area.
Optionally, the processor 3000 determines a page area among the coordinate a, the coordinate B, the coordinate C, and the coordinate D as the target text area, and includes:
judging whether the previous character of the initial character in the target character area is a preset punctuation mark or not;
if the previous character of the initial character in the target character area is not the preset punctuation mark, extending the starting point of the target character area to the character on the right side of the previous preset punctuation mark closest to the initial character;
judging whether the ending characters in the target character area are the preset punctuation marks or not;
and if the next character of the ending character in the target character area is not the preset punctuation mark, extending the end point of the target character area to the last next preset punctuation mark of the ending character.
Optionally, the processor 3000 divides the text in the target text area into N sentences according to the position of the preset punctuation mark in the target text area, including:
traversing the characters in the target character area, detecting N preset punctuations, and marking the positions of the N preset punctuations;
and dividing the characters in the target character area into N sentences by taking the positions of the N preset punctuations as breakpoints, wherein each sentence comprises one preset punctuation.
Optionally, the processor 3000 configures a color for each of the N sentences, including:
determining the character display color in the target character area;
configuring each sentence in the N sentences with a color different from the display color of the characters;
changing the font color of the N sentences into a configured corresponding color, or changing the filling color of the N sentences into the configured corresponding color.
An embodiment of the present invention further provides a computer storage medium, where the computer storage medium may store a program, and when the program is executed, the program includes some or all of the steps of any one of the word processing methods described in the above method embodiments.
While the invention has been described in connection with various embodiments, other variations to the disclosed embodiments can be understood and effected by those skilled in the art in practicing the claimed invention, from a review of the drawings, the disclosure, and the appended claims. In the claims, the word "comprising" does not exclude other elements or steps, and the word "a" or "an" does not exclude a plurality. A single processor or other unit may fulfill the functions of several items recited in the claims. The mere fact that certain measures are recited in mutually different dependent claims does not indicate that a combination of these measures cannot be used to advantage.
As will be appreciated by one skilled in the art, embodiments of the present invention may be provided as a method, apparatus (device), or computer program product. Accordingly, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein. A computer program stored/distributed on a suitable medium supplied together with or as part of other hardware, may also take other distributed forms, such as via the Internet or other wired or wireless telecommunication systems.
The present invention has been described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (devices) and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
While the invention has been described in conjunction with specific features and embodiments thereof, it will be evident that various modifications and combinations can be made thereto without departing from the spirit and scope of the invention. Accordingly, the specification and figures are merely exemplary of the invention as defined in the appended claims and are intended to cover any and all modifications, variations, combinations, or equivalents within the scope of the invention. It will be apparent to those skilled in the art that various changes and modifications may be made in the present invention without departing from the spirit and scope of the invention. Thus, if such modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include such modifications and variations.

Claims (10)

1. A method of word processing, comprising:
determining a target character area in a current displayed page of the touch screen according to the target operation gesture;
dividing characters in the target character area into N sentences according to the positions of preset punctuations in the target character area, wherein N is a positive integer, the preset punctuations are punctuations representing the end of a complete sentence, the initial characters of the target character area are the first characters of the complete sentence, and the end characters are the preset punctuations;
configuring a color for each sentence in the N sentences;
and displaying N check boxes at preset positions of the N sentences so that a user can select M sentences in the N sentences, wherein each check box in the N check boxes corresponds to one sentence, and M is a positive integer less than or equal to N.
2. The method according to claim 1, wherein the target operation gesture is performed by two fingers;
the determining of the target text area in the current page displayed by the touch screen according to the target operation gesture comprises the following steps:
recording a coordinate A and a coordinate B when the two fingers contact a current displayed page of the touch screen and a coordinate C and a coordinate D when the two fingers leave the touch screen;
and determining a page area among the coordinate A, the coordinate B, the coordinate C and the coordinate D as the target character area.
3. The method of claim 2, wherein determining a page area between the coordinates a, B, C, and D as the target text area comprises:
judging whether the previous character of the initial character in the target character area is a preset punctuation mark or not;
if the previous character of the initial character in the target character area is not the preset punctuation mark, extending the starting point of the target character area to the character on the right side of the previous preset punctuation mark closest to the initial character;
judging whether the ending characters in the target character area are the preset punctuation marks or not;
and if the next character of the ending character in the target character area is not the preset punctuation mark, extending the end point of the target character area to the last next preset punctuation mark of the ending character.
4. The method according to any one of claims 1 to 3, wherein the dividing the text in the target text region into N sentences according to the position of the pre-set punctuation mark in the target text region comprises:
traversing the characters in the target character area, detecting N preset punctuations, and marking the positions of the N preset punctuations;
and dividing the characters in the target character area into N sentences by taking the positions of the N preset punctuations as breakpoints, wherein each sentence comprises one preset punctuation.
5. The method according to any one of claims 1 to 3, wherein said configuring a color for each of said N sentences comprises:
determining the character display color in the target character area;
configuring each sentence in the N sentences with a color different from the display color of the characters;
changing the font color of the N sentences into a configured corresponding color, or changing the filling color of the N sentences into the configured corresponding color.
6. A mobile terminal, comprising:
the first determining unit is used for determining a target character area in a current displayed page of the touch screen according to the target operation gesture;
a second determining unit, configured to divide the characters in the target character region into N sentences according to positions of preset punctuation marks in the target character region, where N is a positive integer, the preset punctuation marks are punctuation marks representing an end of a complete sentence, a start character of the target character region is a first character of the complete sentence, and an end character is the preset punctuation mark;
a configuration unit, configured to configure a color for each sentence in the N sentences;
and the display unit is used for displaying N check boxes at preset positions of the N sentences so that a user can select M sentences in the N sentences, wherein each check box in the N check boxes corresponds to one sentence, and M is a positive integer less than or equal to N.
7. The mobile terminal according to claim 6, wherein the target operation gesture is performed by two fingers;
the first determination unit includes:
the recording module is used for recording a coordinate A and a coordinate B when the two fingers contact the current displayed page of the touch screen and a coordinate C and a coordinate D when the two fingers leave the current displayed page of the touch screen;
and the first determining module is used for determining a page area among the coordinate A, the coordinate B, the coordinate C and the coordinate D as the target character area.
8. The mobile terminal of claim 7, wherein the first determining module comprises:
the first judgment module is used for judging whether the previous character of the initial character in the target character area is a preset punctuation mark or not;
a first extending module, configured to extend the starting point of the target text region to a text on the right side of the previous preset punctuation mark closest to the starting text if the previous text of the starting text in the target text region is not the preset punctuation mark;
the second judgment module is used for judging whether the ending character in the target character area is the preset punctuation mark or not;
and the second extension module is used for extending the end point of the target character area to the last preset punctuation mark nearest to the ending character if the last character of the ending character in the target character area is not the preset punctuation mark.
9. The mobile terminal according to any of claims 6 to 8, wherein the second determining unit comprises:
the detection module is used for traversing the characters in the target character area, detecting N preset punctuations and marking the positions of the N preset punctuations;
and the second determining module is used for dividing the characters in the target character area into N sentences by taking the positions of the N preset punctuations as breakpoints, wherein each sentence comprises one preset punctuation.
10. The mobile terminal according to any of claims 6 to 8, wherein the configuration unit comprises:
the third determining module is used for determining the character display color in the target character area;
a configuration module for configuring a color different from the display color of the character for each sentence in the N sentences;
and the execution module is used for changing the font color of the N sentences into a configured corresponding color, or changing the filling color of the N sentences into the configured corresponding color.
CN201710123919.3A 2017-03-03 2017-03-03 Word processing method and mobile terminal Active CN106951168B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710123919.3A CN106951168B (en) 2017-03-03 2017-03-03 Word processing method and mobile terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710123919.3A CN106951168B (en) 2017-03-03 2017-03-03 Word processing method and mobile terminal

Publications (2)

Publication Number Publication Date
CN106951168A CN106951168A (en) 2017-07-14
CN106951168B true CN106951168B (en) 2020-05-19

Family

ID=59467738

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710123919.3A Active CN106951168B (en) 2017-03-03 2017-03-03 Word processing method and mobile terminal

Country Status (1)

Country Link
CN (1) CN106951168B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108572776B (en) * 2018-05-02 2020-11-03 广州视源电子科技股份有限公司 Rendering processing method, device and equipment based on special characters and storage medium
CN108959248A (en) * 2018-06-21 2018-12-07 北京明略软件系统有限公司 A kind of entity mask method and device, computer readable storage medium
CN111610901B (en) * 2020-05-11 2021-10-12 上海翎腾智能科技有限公司 AI vision-based English lesson auxiliary teaching method and system

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20100110688A (en) * 2009-04-04 2010-10-13 허인수 The english verbs function indication method
CN103631877A (en) * 2013-11-08 2014-03-12 四川长虹电器股份有限公司 Webpage table processing method
CN105786309A (en) * 2014-12-26 2016-07-20 广州市动景计算机科技有限公司 Text selection method and device
CN106126052A (en) * 2016-06-23 2016-11-16 北京小米移动软件有限公司 Text selection method and device

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20100110688A (en) * 2009-04-04 2010-10-13 허인수 The english verbs function indication method
CN103631877A (en) * 2013-11-08 2014-03-12 四川长虹电器股份有限公司 Webpage table processing method
CN105786309A (en) * 2014-12-26 2016-07-20 广州市动景计算机科技有限公司 Text selection method and device
CN106126052A (en) * 2016-06-23 2016-11-16 北京小米移动软件有限公司 Text selection method and device

Also Published As

Publication number Publication date
CN106951168A (en) 2017-07-14

Similar Documents

Publication Publication Date Title
US10203871B2 (en) Method for touch input and device therefore
US11042290B2 (en) Touch screen track recognition method and apparatus
US10606474B2 (en) Touch screen finger tracing device
KR101825154B1 (en) Overlapped handwriting input method
WO2017054623A1 (en) Method and device for starting application program, and electronic device
TWI507968B (en) Method and non-transitory computer-readable medium for controlling electronic device with touch screen and electronic device thereof
US20060212812A1 (en) Tool for selecting ink and other objects in an electronic document
US20170109917A1 (en) Method and device for erasing a writing path on an infrared electronic white board, and a system for writing on an infrared electronic white board
CN105868166B (en) Regular expression generation method and system
CN103076982B (en) The method and device that in a kind of mobile terminal, cursor controls
JP6448639B2 (en) Text selection method, apparatus and terminal
CN106951168B (en) Word processing method and mobile terminal
CN104020948A (en) Method and device for determining position of cursor on touch screen
CN104007920A (en) Method for selecting waveforms on electronic test equipment
US9524568B2 (en) Movement of position indicator on touchscreen
CN104077065A (en) Method for displaying virtual keyboard by touch screen terminal and touch screen terminal
CN103744609B (en) A kind of data extraction method and device
CN105653131A (en) Application search method and terminal
CN111143731B (en) Display method and device for webpage interface zooming and terminal equipment
CN103150118A (en) Method, device and mobile terminal for selecting contents based on multi-point touch technology
EP3118731A1 (en) Method and electronic device for inputting character
CN110096200A (en) Text handling method and device, storage medium, electronic equipment
JP2016148887A (en) Ladder program edition device enabling edition with gesture operation of touch panel
KR102438823B1 (en) Method and Apparatus for executing function for plural items on list
CN110647263B (en) Mobile terminal desktop icon moving method, device, medium and equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant