WO2011003262A1 - Mobile terminal and method thereof for implementing image and text editing function - Google Patents

Mobile terminal and method thereof for implementing image and text editing function Download PDF

Info

Publication number
WO2011003262A1
WO2011003262A1 PCT/CN2009/075855 CN2009075855W WO2011003262A1 WO 2011003262 A1 WO2011003262 A1 WO 2011003262A1 CN 2009075855 W CN2009075855 W CN 2009075855W WO 2011003262 A1 WO2011003262 A1 WO 2011003262A1
Authority
WO
WIPO (PCT)
Prior art keywords
operation command
editing operation
stroke
text
input stroke
Prior art date
Application number
PCT/CN2009/075855
Other languages
French (fr)
Chinese (zh)
Inventor
杨蒙
Original Assignee
中兴通讯股份有限公司
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 中兴通讯股份有限公司 filed Critical 中兴通讯股份有限公司
Publication of WO2011003262A1 publication Critical patent/WO2011003262A1/en

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T11/002D [Two Dimensional] image generation
    • G06T11/60Editing figures and text; Combining figures or text
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/724User interfaces specially adapted for cordless or mobile telephones
    • H04M1/72403User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality

Definitions

  • the present invention relates to the field of mobile communication terminals, and in particular, to a mobile terminal and a method for implementing the image editing function. Background technique
  • the main object of the present invention is to provide a mobile terminal and an implementation picture thereof.
  • the function method enables the user to edit the graphic according to the habit of hand operation on the touch screen mobile terminal, and the editing process is completed.
  • the present invention provides a method for implementing a graphic editing function, the method comprising:
  • the text or graphic of the input stroke closure is processed according to the editing operation command, and the processing result is fed back to the user.
  • the editing operation command collectively stores a correspondence between a stroke and an editing operation command; the editing operation command is divided into a text editing operation command and a picture editing operation command; and the text editing operation command includes at least deleting, adding, moving, and Inverting command; the picture editing operation command includes at least a delete, add, move, invert, and zoom command.
  • the method further includes: classifying all editing operation commands in the editing operation command set according to the number of strokes of the stroke to obtain a subset of the editing operation commands.
  • the process of searching for an edit operation command corresponding to the input stroke from the edit operation command set includes:
  • the key geometric feature points of the input stroke are matched with the key geometric feature points of the stroke corresponding to the editing operation command subset edit operation command, and the editing operation command corresponding to the input stroke is found.
  • the method further includes: confirming to the user whether to execute the editing operation command, and if yes, performing the text or graphic of the input stroke closing package Processing, otherwise, waiting for the user to re-enter the input stroke.
  • the method further includes: releasing key geometric feature points of the input stroke and refreshing the display interface of the mobile terminal.
  • the present invention also provides a mobile terminal for implementing a graphic editing function, comprising an input module, an editing operation command identification module, a storage module and a processing module, wherein:
  • the input module is configured to: when the text editing function is enabled, record an input stroke input by the user, and provide the input stroke to the editing operation command identification module;
  • the editing operation command identifying module is configured to search for an editing operation command corresponding to the input stroke from the editing operation command set according to the key geometric feature point of the input stroke, and provide the editing operation command to the processing module;
  • the storage module is configured to store the edit operation command set
  • the processing module is configured to process the text or graphics of the input stroke closure according to the editing operation command, and feed back the processing result to the user.
  • the editing operation command set stored in the storage module is a correspondence between the editing operation command and the stroke; the editing operation command is divided into a text editing operation command and a picture editing operation command, wherein the text editing operation command includes at least Delete, add, move, and invert commands; the picture editing operation commands include at least delete, add, move, invert, and zoom commands.
  • the storage module is further configured to classify all the editing operation commands in the editing operation command set according to the number of strokes of the stroke to obtain a subset of the editing operation commands. .
  • the editing operation command identification module is further configured to calculate a number of strokes of the input stroke, and find a corresponding subset of the editing operation command from the editing operation command set according to the number of strokes; and key geometry of the input stroke The feature point is matched with a key geometric feature point of the stroke corresponding to the edit operation command subset edit operation command, and an edit operation command corresponding to the input stroke is found.
  • the processing module searches for an edit corresponding to the input stroke in the edit operation command recognition module After the operation command is used, it is also used to confirm to the user whether to execute the edit operation command, and if so, to process the text or graphics of the input stroke closure, otherwise, wait for the user to perform the operation of inputting the stroke again.
  • the processing module is further configured to release the feature points of the input stroke after processing the text or graphics of the input stroke closure, and refresh the display interface.
  • the technical solution of the present invention introduces the editing mode in the writing of the human pen and paper into the mobile terminal, so that the user performs a corresponding editing operation on the independent object such as text or graphics on the mobile terminal by using the stylus pen or the finger.
  • the cumbersome steps of the user looking for menu items on the mobile terminal are avoided, providing a better user experience.
  • FIG. 1 is a schematic structural diagram of a mobile terminal according to the present invention.
  • the mobile terminal having the graphic editing function includes an input module 10, an editing operation command identification module 20, a storage module 30, and a processing module 40, wherein:
  • the input module 10 is configured to record a stroke input by a user through a stylus or a finger (hereinafter referred to as an input stroke) when the graphic editing function is enabled, in particular, record a key geometric feature point of the input stroke, and send it to the editing operation command to identify Module 20; the key geometric feature points of the input stroke, such as the starting point, the inflection point and the ending point of the stroke, and the combination of the key geometric feature points of the input stroke, indicating the input stroke;
  • the editing operation command identification module 20 is configured to receive key geometric feature points of the input stroke, and identify and input the input stroke from the storage module 30 according to the key geometric feature points of the input stroke data. Corresponding editing operation command, and sending the editing operation command and the key geometric feature points of the input stroke to the processing module 40;
  • the storage module 30 is configured to store a correspondence between a stroke and an editing operation command (which may be referred to as an editing operation command set), wherein the stroke is composed of key geometric feature points; the key geometric feature points of the input stroke and the editing operation command are concentrated The key geometric feature points are matched, and the corresponding editing operation command can be obtained;
  • the processing module 40 is configured to process the text or graphics of the input stroke closure according to the editing operation command, and feed back the processing result to the user.
  • the text or graphic of the input stroke closure is the text or graphic to be processed, wherein there is a certain relationship between the closure area of the text or the graphic and the closure area of the input stroke, which will be explained by the following embodiments. .
  • the processing module 40 may further confirm to the user whether to execute the editing operation command, and if so, process the text or graphics of the input stroke closing package, otherwise, wait The user re-enters the input stroke.
  • the editing operation command stored in the storage module 30 may be further divided into a text editing operation command and a picture editing operation command; wherein the text editing operation command further includes commands such as deleting, adding, moving, and inverting, and the image editing operation command Further include commands such as delete, add, move, invert, and scale.
  • the storage module 30 may further classify the editing operation command corresponding to the key geometric feature point of the stroke according to the number of strokes of the stroke in the editing operation command set, so that the editing operation command identifies
  • the module 20 is further configured to calculate the number of strokes of the input stroke, and find all the editing operation commands corresponding to the number of the strokes from the storage module 30 according to the number of strokes, and then input the strokes.
  • the key geometric feature points are matched with the key geometric feature points of the strokes in the edit operation command set, thereby identifying corresponding editing operation commands.
  • Step 201 The mobile terminal enables the graphic editing function to record key geometric feature points of the input stroke.
  • the mobile terminal When the mobile terminal enables the text editing function according to the user operation, the input stroke of the user is recorded.
  • the mobile terminal thinks that the user wants to edit the text or the graphic, and immediately enables the graphic editing function; or the mobile terminal provides There is a graphic editing function option.
  • the mobile terminal When the user selects the graphic editing function option, the mobile terminal immediately enables the graphic editing function, and the user can input the stroke through the editing interface provided by the mobile terminal.
  • the mobile terminal can use a timer to record the key geometric feature points of each stroke (the storage form is InputPointlnfo) when the pen is dropped and the pen is lifted during the user input, specifically
  • the timer initial value of the timer may be a default value of the mobile terminal (ie, the default value is confirmed by a test result of a normal user of a certain duration), or may be a preset value selected by the user.
  • Int strokeld //Identifies the stroke of the key geometric feature point.
  • the storage form of a single input stroke is as follows:
  • Strokelnfo of input strokes constitutes Strokelnfo linked list.
  • Step 202 The mobile terminal calculates the number of input strokes.
  • the storage form of the input stroke provided in step 201 when the user inputs a stroke, the storage form of Strokelnfo is used, that is, one input stroke corresponds to one StrokeInfo. Therefore, the number of input strokes can be determined based on the number of StrokeInfos on the Strokelnfo list.
  • Step 203 The mobile terminal identifies the subset of the editing operation command according to the number of input strokes.
  • the corresponding editing operation command classification is recognized from the editing operation command set, for example, the number of strokes is 1 corresponding to a type of editing operation command, and each editing operation command in the editing operation command includes only one stroke. For example, when the number of input strokes is 2, a corresponding type of editing operation command can be identified, and each editing operation command in the type of editing operation command includes two strokes.
  • a type of editing operation command can be called an editing operation command.
  • the storage form of an editing operation command is as follows:
  • Strokelnfo *Strokeinfo / / store the information of each stroke included in the edit operation command, that is, Strokelnfo corresponding to each stroke According to OperatorCommandStrokeNumber, the edit operation command can be classified according to the number of strokes it contains.
  • Step 204 The mobile terminal identifies an edit operation command according to a key geometric feature point of the input stroke.
  • the mobile terminal identifies the corresponding editing operation command from the editing operation command classification identified in step 203 according to the key geometric feature point of the input stroke recorded in step 201, that is, the key geometric feature point of the stroke is input, and the editing operation is performed. Match the key geometric feature points of the strokes corresponding to all edit operation commands in the command.
  • a type of editing operation command that is, a subset of the editing operation command, is stored as follows:
  • OperatorCommandlnfo * OperatorCommandInfo II stores the information of all editing operation commands, that is, the OperatorCommandInfo of each editing operation command, the input of the key geometric feature points and the matching of the key geometric feature points corresponding to the editing operation command, which can be input in the prior art.
  • the matching method between the stroke and the stroke stored in the terminal is performed, and details are not described herein again.
  • the mobile terminal may further confirm to the user whether to execute the editing operation command, and if yes, process the text or graphics of the input stroke closing package, otherwise, wait for the user to re-execute Perform the operation of entering a stroke.
  • Step 205 The mobile terminal processes the edit operation object according to the recognized edit operation command.
  • the mobile terminal performs result feedback processing according to the geometric relationship between the edit operation command corresponding to the input stroke and the closure of the operated text or graphic.
  • Editing the closure area of the operation command that is, the graphic or text within the closure area is the processing object of the operation command. If there is a pixel inside the closed area of the input editing operation command, corresponding feedback is performed according to the relationship between the text (graphic) of the pixel in the closure area and the inflection point of the key geometric feature point of the input editing operation command.
  • Processing that is, processing of the input editing operation command for the character (graphic) to which the pixel belongs; if there is no pixel inside the closed area of the input editing operation command, but the closed area exists within a certain range of pixels Point, then corresponding feedback processing is performed according to the adjacent pixel points.
  • the processing method of the present invention is: when the editing operation command is closed When the ratio of the area of the package to the area of the closure and the area of the closure of the closure is between 3/2 and 2/1, it is considered to be the inclusion relationship; when the editing operation command is closed, the area of the closure and the area of the closure of the graphic is ' j, considered to be an adjacent relationship at 3/2.
  • Step 206 The mobile terminal feeds back the processed result to the user, and releases the key geometric feature point of the input stroke.
  • the mobile terminal releases the recorded key geometric feature points of the current input stroke and refreshes the editing interface, that is, does not leave any operation trace on the editing interface.
  • the process of refreshing the editing interface is actually the process of destroying the operation command variable OperatorCommandInfo.
  • step 203 when the editing operation command is recognized, the operation of step 203 may not be performed, and the corresponding editing operation command is directly recognized in the editing operation command set according to the key geometric feature points of the input stroke.
  • the above storage operation command subset is also stored in the edit operation command set.
  • Application 1 Delete the processed object.
  • Can be set The geometric features of the delete operation command are divided into two cases: a way of drawing a fork, That is, the two strokes are drawn as a straight line and intersect at a point, such as ACD. At the same time, there are pixels of text or graphics in the range of the stroke closure, indicating that the character "B" is to be deleted; and another way of drawing irregular lines, such as ⁇ *CD, When there is a pixel of text or graphic in the range of the stroke closure, it means that the character "AB" is to be deleted.
  • the mobile terminal performs a delete operation according to the number of the edit operation command corresponding to the input stroke. Specifically, the mobile terminal calculates the input stroke, that is, the edit operation command, by using the boundary point of the input stroke and the key geometric feature point.
  • Closing area then determining the pixel of the text or graphic in the closure area, deleting the text or graphic in the closing area, and refreshing the editing interface after deleting, and feeding back the deleted state to the user, wherein
  • the input stroke closure area can be calculated according to the prior art; specifically, the deletion process of the text or graphics in the closure area is actually when the editing operation command closure area and the closure area of the text or graphics in the closure area are When a relationship or a neighbor relationship is included, the text or figure corresponding to the pixel within the closure range is released.
  • Application 2 Add an operation. Can be set: The geometric feature of the add operation is that the two strokes are straight lines and intersect at one point. At the same time, when the two stroke operation commands are displayed on the interface, there is no text or graphics in the closure range.
  • the pixels, such as ⁇ P CD indicate that you need to add between the words "AB” and add a force between the words "CD”.
  • the mobile terminal performs an adding operation according to the editing operation command corresponding to the input stroke. Specifically, first, the relationship between the closing area of the editing operation command and the closing area of the editing operation text is calculated, if the ratio between the two is less than 3/ 2, the mobile terminal scans the position of the vertex in the left neighboring direction of the added stroke by using the vertex position of the added stroke (ie, the intersection of the two strokes), and moves the text in the right adjacent direction of the added stroke back.
  • the mobile terminal performs a moving operation according to the editing operation command corresponding to the input stroke. Specifically, first, the relationship between the closed area of the mobile editing operation command and the closed area of the editing operation text is calculated, if the ratio between the two is 3/ When the relationship between 2 and 2/1 is considered to be an inclusion relationship, the mobile terminal saves the text information in the closed area between the end position of the input stroke (the right neighbor of "home") and the circle of the input stroke (ie, " The people, , ), then use the area of the circle recorded by the input stroke to scan the position of the pixel, extract the text information in the area, and then replace the text information between the input stroke end position and the input circle stroke with the extracted circle area.
  • the internal text, and finally the text area between the last saved moving action end position and the moving working circle stroke is built in the circle area, and the further insertion process is a normal input character process.
  • the geometric feature of the inverted editing operation command is a stroke
  • the angle value between the key geometric feature points (referring to the inflection point and the starting point) of the stroke has at least two near right angles (ie, the angle value is within a certain range, the present invention
  • the range of the setting is the number ⁇ )
  • the sum of the two near-right angles is close to ⁇ (that is, within a certain range, the range set by the present invention is ⁇ ), for example, indicating that the "person” and the "people” need to be inverted. .
  • the relationship between the closure area of the inverted editing operation command and the closure area of the editing operation text is calculated. If the ratio between the two is between 3/2 and 2/1, it is considered to be an inclusion relationship, then the mobile terminal according to Enter the editing operation command corresponding to the stroke to perform the inversion operation. Specifically, the mobile terminal separately stores the text information in the area of the first half of the fold line closure, and the second half of the fold line is closed.
  • the text information in the package area is specifically determined according to the position of the inflection point of the inversion operation and the position information of the start point and the end point, and the closure area of the front and rear half fold lines is determined, and then the position of the text in the closure is determined according to the pixel points scanned within the closure area; Further, the text information in the front and rear half of the fold line closure area is interchanged. Specifically, the exchange process first saves the text information and the character position in the front and rear half of the fold line closure area as temporary variables, and then The position variable of the text information in the front and rear half of the fold line closure area is swapped.
  • the mobile terminal writes the text information in the original half of the fold line closure area in the original half of the fold line closure area, and the first half of the fold line is closed. Write the text information in the original half of the fold line closure area within the package area.
  • the mobile terminal can determine the text information in the closed area of the half fold line according to the prior art, and the relationship between the front and rear half of the fold line closure and the text information in the closed package is determined according to the closure relationship between the two. adjacent.
  • the geometric feature of the operation of changing the graphic size is a straight line, and there is no pixel on the terminal to modify the text or the graphic in the closure area of the editing operation command. Further, the present invention distinguishes the input editing operation command stroke from the modified text or graphic by the pixel dot color.
  • the mobile terminal changes the size (length, width, etc.) of the graphic according to the end point coordinate position of the input stroke (here, the stroke corresponding to the modified editing operation command, the modified stroke of the cartridge), and redraws the graphic with the latest size attribute information; Further, in this step, the default mobile terminal has saved the length and width information of the graphic or the vertex information on the diagonal line, and then calculates the length and width according to the coordinate position of the end point of the modified stroke and the coordinate position of the modified graphic and the modified stroke intersection. The difference is added to the length and width of the original graphic, or subtracted to obtain the length and width information of the modified new graphic, and the mobile terminal repaints the graphic according to the latest size attribute.
  • the technical solution of the present invention increases the writing editing, symbols and logos used by humans through the geometric relationship of the singles in the mobile terminal, so that the user can naturally express the intention and avoid searching for menu items, etc.
  • Complex operations streamline user operations and improve the user experience of the software.
  • the invention may, of course, be embodied in a variety of embodiments, and any modifications, equivalents, and improvements made within the spirit and scope of the invention are included in the present invention.

Abstract

A mobile terminal and a method thereof for implementing image and text editing function are disclosed by the present invention. The method comprises the following steps: when an image and text editing function is enabled, the mobile terminal records strokes inputted by a user; according to key geometrical feature points of the inputted strokes, the mobile terminal searches editing operation commands set for an editing operation command corresponding to the inputted strokes; the mobile terminal processes the text or image enclosed by the inputted strokes according to the editing operation command, and feeds the processing result back to the user. The technical solutions of the present invention adds handwriting editing, symbols and identifiers which is accustomedly used by human to the mobile terminal according to the simple geometrical relation, enables user to express intentions naturally, avoids complex operations for seeking menu items, simplifies user operations, and raises user experience of software.

Description

一种移动终端及其实现图文编辑功能的方法 技术领域  Mobile terminal and method for realizing graphic editing function thereof
本发明涉及移动通信终端领域, 尤其涉及了一种移动终端及其实现图 文编辑功能的方法。 背景技术  The present invention relates to the field of mobile communication terminals, and in particular, to a mobile terminal and a method for implementing the image editing function. Background technique
目前移动终端的用途越来越多, 有^艮多应用程序在移动终端上运行。 随着移动终端的处理能力越来越强大, 它已经具有了对很多软件的计算处 理能力, 并且非常便捷。 在触摸屏移动终端上软件的操作结果都是由菜单 命令得到的, 随着移动终端功能的增多, 菜单项也越来越多, 菜单深度也 越来越深, 从而使得用户为了操作触摸屏移动终端上的文字和图形首先要 聚焦要操作的对象, 然后再寻找相应的菜单选项, 最后通过操作菜单项实 现相应的操作。 这一过程与人类几千年来使用手直接操作实物的习惯不符, 特别是对于文本和图形的输入, 在生活中一直是使用纸和笔。  At present, the use of mobile terminals is increasing, and there are many applications running on mobile terminals. As mobile terminals become more powerful, they already have the computational power of many software and are very convenient. The operation results of the software on the touch screen mobile terminal are all obtained by the menu command. As the function of the mobile terminal increases, the menu items are more and more, and the menu depth is deeper and deeper, so that the user operates the touch screen on the mobile terminal. The text and graphics first focus on the object to be manipulated, then look for the corresponding menu options, and finally operate the menu items to achieve the corresponding operation. This process is inconsistent with the habits of humans using hands to directly manipulate objects for thousands of years, especially for the input of text and graphics, which has been using paper and pen in life.
但是这种使用笔在纸上操作的方式也有缺点:  But there are disadvantages to using this pen on paper:
1、对文本和图形的修改是用橡皮擦掉再重新书写,以达到修改的目的, 且操作步骤较复杂。  1. The modification of the text and graphics is erased with an eraser and then rewritten to achieve the purpose of modification, and the operation steps are more complicated.
2、 有时候人们也会采用一些熟悉的操作或动作直接在纸上保留下修改 的痕迹, 例如需要将某个文字去掉时, 直接在该文字上画叉等方式, 来修 改文字, 但同时修改的痕迹和结果都保留在纸上了, 看起来比较零乱, 也 不能直接反馈修改后的结果。 发明内容  2. Sometimes people will use some familiar operations or actions to keep the traces of the changes directly on the paper. For example, when you need to remove a text, you can directly modify the text on the text to modify the text, but at the same time modify it. The traces and results are kept on paper, which seems to be messy and cannot directly feedback the modified results. Summary of the invention
有鉴于此, 本发明的主要目的在于提供一种移动终端及其实现图文编 辑功能的方法, 使用户在触摸屏移动终端上能够按照用手操作的习惯编辑 图文, 筒化了编辑过程。 In view of this, the main object of the present invention is to provide a mobile terminal and an implementation picture thereof. The function method enables the user to edit the graphic according to the habit of hand operation on the touch screen mobile terminal, and the editing process is completed.
为了解决上述技术问题, 本发明的技术方案是这样实现的:  In order to solve the above technical problem, the technical solution of the present invention is implemented as follows:
本发明提供了一种实现图文编辑功能的方法, 该方法包括:  The present invention provides a method for implementing a graphic editing function, the method comprising:
在启用图文编辑功能时, 记录用户输入的输入笔划;  When the graphic editing function is enabled, the input stroke input by the user is recorded;
根据所述输入笔划的关键几何特征点, 从编辑操作命令集中查找与所 述输入笔划对应的编辑操作命令;  And searching for an editing operation command corresponding to the input stroke from the editing operation command set according to the key geometric feature point of the input stroke;
根据所述编辑操作命令, 对所述输入笔划闭包的文字或者图形进行处 理, 将处理结果反馈给用户。  The text or graphic of the input stroke closure is processed according to the editing operation command, and the processing result is fed back to the user.
其中, 所述编辑操作命令集中存储有笔划与编辑操作命令的对应关系; 所述编辑操作命令分为文字编辑操作命令和图片编辑操作命令; 所述文字编辑操作命令至少包括删除、 添加、 移动和倒置命令; 所述图片编辑操作命令至少包括删除、 添加、 移动、 倒置和缩放命令。 该方法进一步包括: 依据笔划的笔划数目, 将编辑操作命令集中的所 有编辑操作命令进行分类, 得到编辑操作命令子集。  The editing operation command collectively stores a correspondence between a stroke and an editing operation command; the editing operation command is divided into a text editing operation command and a picture editing operation command; and the text editing operation command includes at least deleting, adding, moving, and Inverting command; the picture editing operation command includes at least a delete, add, move, invert, and zoom command. The method further includes: classifying all editing operation commands in the editing operation command set according to the number of strokes of the stroke to obtain a subset of the editing operation commands.
从所述编辑操作命令集中查找与所述输入笔划相对应的编辑操作命令 的过程包括:  The process of searching for an edit operation command corresponding to the input stroke from the edit operation command set includes:
计算所述输入笔划的笔划数目;  Calculating the number of strokes of the input stroke;
依据所述输入笔划的笔划数目从所述编辑操作命令集中查找出对应的 编辑操作命令子集;  Finding a corresponding subset of the editing operation command from the edit operation command set according to the number of strokes of the input stroke;
将所述输入笔划的关键几何特征点, 与所述编辑操作命令子集中编辑 操作命令对应的笔划的关键几何特征点进行匹配, 查找出与所述输入笔划 对应的编辑操作命令。  The key geometric feature points of the input stroke are matched with the key geometric feature points of the stroke corresponding to the editing operation command subset edit operation command, and the editing operation command corresponding to the input stroke is found.
查找到所述编辑操作命令后, 该方法进一步包括: 向用户确认是否执 行该编辑操作命令, 如果是, 再对所述输入笔划闭包的文字或者图形进行 处理, 否则, 等待用户重新进行输入笔划的操作。 After the editing operation command is found, the method further includes: confirming to the user whether to execute the editing operation command, and if yes, performing the text or graphic of the input stroke closing package Processing, otherwise, waiting for the user to re-enter the input stroke.
对所述输入笔划闭包的文字或者图形进行处理后, 该方法进一步包括: 释放所述输入笔划的关键几何特征点, 并刷新移动终端显示界面。  After processing the text or graphics of the input stroke closure, the method further includes: releasing key geometric feature points of the input stroke and refreshing the display interface of the mobile terminal.
本发明还提供了一种实现图文编辑功能的移动终端, 包括输入模块、 编辑操作命令识别模块、 存储模块和处理模块, 其中:  The present invention also provides a mobile terminal for implementing a graphic editing function, comprising an input module, an editing operation command identification module, a storage module and a processing module, wherein:
所述输入模块, 用于在启用图文编辑功能时, 记录用户输入的输入笔 划, 并将所述输入笔划提供给所述编辑操作命令识别模块;  The input module is configured to: when the text editing function is enabled, record an input stroke input by the user, and provide the input stroke to the editing operation command identification module;
所述编辑操作命令识别模块, 用于根据所述输入笔划的关键几何特征 点, 从编辑操作命令集中查找与所述输入笔划对应的编辑操作命令, 提供 给所述处理模块;  The editing operation command identifying module is configured to search for an editing operation command corresponding to the input stroke from the editing operation command set according to the key geometric feature point of the input stroke, and provide the editing operation command to the processing module;
所述存储模块, 用于存储所述编辑操作命令集;  The storage module is configured to store the edit operation command set;
所述处理模块, 用于根据所述编辑操作命令, 对输入笔划闭包的文字 或者图形进行处理, 将处理结果反馈给用户。  The processing module is configured to process the text or graphics of the input stroke closure according to the editing operation command, and feed back the processing result to the user.
所述存储模块中所存储的编辑操作命令集, 为编辑操作命令与笔划的 对应关系; 所述编辑操作命令分为文字编辑操作命令和图片编辑操作命令, 其中, 所述文字编辑操作命令至少包括删除、 添加、 移动和倒置命令; 所 述图片编辑操作命令至少包括删除、 添加、 移动、 倒置和缩放命令。  The editing operation command set stored in the storage module is a correspondence between the editing operation command and the stroke; the editing operation command is divided into a text editing operation command and a picture editing operation command, wherein the text editing operation command includes at least Delete, add, move, and invert commands; the picture editing operation commands include at least delete, add, move, invert, and zoom commands.
所述存储模块, 进一步用于依据笔划的笔划数目, 将编辑操作命令集 中的所有编辑操作命令进行分类, 得到编辑操作命令子集。 。  The storage module is further configured to classify all the editing operation commands in the editing operation command set according to the number of strokes of the stroke to obtain a subset of the editing operation commands. .
所述编辑操作命令识别模块, 还用于计算所述输入笔划的笔划数目, 根据该笔划数目从所述编辑操作命令集中查找出对应的编辑操作命令子 集; 并将所述输入笔划的关键几何特征点, 与所述编辑操作命令子集中编 辑操作命令对应的笔划的关键几何特征点进行匹配, 查找出与所述输入笔 划对应的编辑操作命令。  The editing operation command identification module is further configured to calculate a number of strokes of the input stroke, and find a corresponding subset of the editing operation command from the editing operation command set according to the number of strokes; and key geometry of the input stroke The feature point is matched with a key geometric feature point of the stroke corresponding to the edit operation command subset edit operation command, and an edit operation command corresponding to the input stroke is found.
所述处理模块, 在编辑操作命令识别模块查找出与输入笔划对应的编 辑操作命令后, 还用于向用户确认是否执行该编辑操作命令, 如果是, 再 对所述输入笔划闭包的文字或者图形进行处理, 否则, 等待用户重新进行 输入笔划的操作。 The processing module searches for an edit corresponding to the input stroke in the edit operation command recognition module After the operation command is used, it is also used to confirm to the user whether to execute the edit operation command, and if so, to process the text or graphics of the input stroke closure, otherwise, wait for the user to perform the operation of inputting the stroke again.
所述处理模块, 在对所述输入笔划闭包的文字或者图形进行处理后, 还用于释放所述输入笔划的特征点, 并刷新显示界面。  The processing module is further configured to release the feature points of the input stroke after processing the text or graphics of the input stroke closure, and refresh the display interface.
与现有技术相比, 本发明技术方案将人类纸笔书写中的编辑方式引入 了移动终端, 这样, 用户使用手写笔或者手指对移动终端上的文字或者图 形等独立对象进行相应的编辑操作, 避免了用户在移动终端上寻找菜单项 的繁瑣步骤, 提供了更好的用户体验。 附图说明  Compared with the prior art, the technical solution of the present invention introduces the editing mode in the writing of the human pen and paper into the mobile terminal, so that the user performs a corresponding editing operation on the independent object such as text or graphics on the mobile terminal by using the stylus pen or the finger. The cumbersome steps of the user looking for menu items on the mobile terminal are avoided, providing a better user experience. DRAWINGS
图 1为本发明中移动终端的结构示意图;  1 is a schematic structural diagram of a mobile terminal according to the present invention;
图 2为本发明的详细方法流程示意图。 具体实施方式  2 is a schematic flow chart of a detailed method of the present invention. detailed description
下面结合附图及具体实施例对本发明技术方案作进一步详细说明。 本发明具有图文编辑功能的移动终端, 特别是指触摸屏移动终端, 如 图 1所示, 包括输入模块 10、 编辑操作命令识别模块 20、 存储模块 30、 和 处理模块 40, 其中:  The technical solutions of the present invention are further described in detail below with reference to the accompanying drawings and specific embodiments. The mobile terminal having the graphic editing function, in particular, the touch screen mobile terminal, as shown in FIG. 1, includes an input module 10, an editing operation command identification module 20, a storage module 30, and a processing module 40, wherein:
输入模块 10, 用于在启用图文编辑功能时, 记录用户通过手写笔或者 手指输入的笔划 (后续称为输入笔划) , 特别是记录输入笔划的关键几何 特征点, 并发送给编辑操作命令识别模块 20; 上述输入笔划的关键几何特 征点、 如该笔划的起始点、 拐点和结束点等, 输入笔划的关键几何特征点 的组合即表示输入笔划;  The input module 10 is configured to record a stroke input by a user through a stylus or a finger (hereinafter referred to as an input stroke) when the graphic editing function is enabled, in particular, record a key geometric feature point of the input stroke, and send it to the editing operation command to identify Module 20; the key geometric feature points of the input stroke, such as the starting point, the inflection point and the ending point of the stroke, and the combination of the key geometric feature points of the input stroke, indicating the input stroke;
编辑操作命令识别模块 20, 用于接收输入笔划的关键几何特征点, 并 根据输入笔划数据的关键几何特征点, 从存储模块 30中识别与该输入笔划 相对应的编辑操作命令, 并将编辑操作命令以及输入笔划的关键几何特征 点发送给处理模块 40; The editing operation command identification module 20 is configured to receive key geometric feature points of the input stroke, and identify and input the input stroke from the storage module 30 according to the key geometric feature points of the input stroke data. Corresponding editing operation command, and sending the editing operation command and the key geometric feature points of the input stroke to the processing module 40;
存储模块 30, 用于存储笔划与编辑操作命令的对应关系 (可以称为编 辑操作命令集) , 其中, 笔划的由关键几何特征点组成; 将输入笔划的关 键几何特征点和编辑操作命令集中笔划的关键几何特征点进行匹配, 就可 以得到对应的编辑操作命令;  The storage module 30 is configured to store a correspondence between a stroke and an editing operation command (which may be referred to as an editing operation command set), wherein the stroke is composed of key geometric feature points; the key geometric feature points of the input stroke and the editing operation command are concentrated The key geometric feature points are matched, and the corresponding editing operation command can be obtained;
处理模块 40, 用于依据该编辑操作命令, 对输入笔划闭包的文字或者 图形进行处理, 将处理结果反馈给用户。 所述输入笔划闭包的文字或者图 形即为所要处理的文字或图形, 其中文字或图形的闭包面积与输入笔划的 闭包面积之间存在一定关系, 此处将通过后面的实施例进行说明。  The processing module 40 is configured to process the text or graphics of the input stroke closure according to the editing operation command, and feed back the processing result to the user. The text or graphic of the input stroke closure is the text or graphic to be processed, wherein there is a certain relationship between the closure area of the text or the graphic and the closure area of the input stroke, which will be explained by the following embodiments. .
当编辑操作命令识别模块 20识别出编辑操作命令后, 处理模块 40还 可以向用户确认是否执行该编辑操作命令, 如果是, 再对所述输入笔划闭 包的文字或者图形进行处理, 否则, 等待用户重新进行输入笔划的操作。  After the editing operation command recognition module 20 recognizes the editing operation command, the processing module 40 may further confirm to the user whether to execute the editing operation command, and if so, process the text or graphics of the input stroke closing package, otherwise, wait The user re-enters the input stroke.
进一步地, 存储模块 30中所存储的编辑操作命令可以进一步地分为文 字编辑操作命令和图片编辑操作命令; 其中, 文字编辑操作命令进一步包 括删除、 添加、 移动和倒置等命令, 图片编辑操作命令进一步包括删除、 添加、 移动、 倒置和缩放等命令。  Further, the editing operation command stored in the storage module 30 may be further divided into a text editing operation command and a picture editing operation command; wherein the text editing operation command further includes commands such as deleting, adding, moving, and inverting, and the image editing operation command Further include commands such as delete, add, move, invert, and scale.
为了提高识别输入笔划相对应的编辑操作命令的准确度, 存储模块 30 还可以在编辑操作命令集中按照笔划的笔划数目分类保存笔划的关键几何 特征点对应的编辑操作命令, 这样, 编辑操作命令识别模块 20在接收到输 入笔划的关键几何特征点后, 还用于计算该输入笔划的笔划数目, 根据笔 划数目从存储模块 30中查找出该笔划数目对应的所有编辑操作命令, 再将 该输入笔划的关键几何特征点与编辑操作命令集中的笔划的关键几何特征 点进行匹配, 从而识别出对应的编辑操作命令。  In order to improve the accuracy of the editing operation command corresponding to the recognition input stroke, the storage module 30 may further classify the editing operation command corresponding to the key geometric feature point of the stroke according to the number of strokes of the stroke in the editing operation command set, so that the editing operation command identifies After receiving the key geometric feature points of the input stroke, the module 20 is further configured to calculate the number of strokes of the input stroke, and find all the editing operation commands corresponding to the number of the strokes from the storage module 30 according to the number of strokes, and then input the strokes. The key geometric feature points are matched with the key geometric feature points of the strokes in the edit operation command set, thereby identifying corresponding editing operation commands.
下面具体介绍移动终端实现图文编辑功能的过程, 如图 2所示, 包括 以下步骤: The process of implementing the graphic editing function of the mobile terminal is specifically described below, as shown in FIG. 2, including The following steps:
步骤 201 , 移动终端启用图文编辑功能, 记录输入笔划的关键几何特征 点。  Step 201: The mobile terminal enables the graphic editing function to record key geometric feature points of the input stroke.
移动终端根据用户操作启用图文编辑功能时, 记录用户的输入笔划。 该步骤中, 用户可以使用手写笔或手指用力按压移动终端的显示屏幕到达 某一个阀值时, 移动终端认为用户要进行文字或者图形的编辑, 即刻启用 图文编辑功能; 也可以是移动终端提供有图文编辑功能选项, 当用户选择 该图文编辑功能选项时, 移动终端即刻启用图文编辑功能, 此时用户可以 通过移动终端提供的编辑界面输入笔划。  When the mobile terminal enables the text editing function according to the user operation, the input stroke of the user is recorded. In this step, when the user can press the display screen of the mobile terminal to reach a certain threshold by using the stylus or the finger, the mobile terminal thinks that the user wants to edit the text or the graphic, and immediately enables the graphic editing function; or the mobile terminal provides There is a graphic editing function option. When the user selects the graphic editing function option, the mobile terminal immediately enables the graphic editing function, and the user can input the stroke through the editing interface provided by the mobile terminal.
在记录用户的输入笔划时, 移动终端可以利用一个计时器 Timer, 在计 时器时间内, 记录用户输入过程中落笔和抬笔时每个笔划的关键几何特征 点 (存储形式为 InputPointlnfo ) , 具体地, 计时器的计时初始值可以是移 动终端的默认值(即通过对某个特定时长的普通用户的试验结果来确认该 默认值) , 也可以是用户选择的预设值。  When recording the user's input stroke, the mobile terminal can use a timer to record the key geometric feature points of each stroke (the storage form is InputPointlnfo) when the pen is dropped and the pen is lifted during the user input, specifically The timer initial value of the timer may be a default value of the mobile terminal (ie, the default value is confirmed by a test result of a normal user of a certain duration), or may be a preset value selected by the user.
具体的, 单个关键几何特征点的存储形式如下:  Specifically, the storage form of a single key geometric feature point is as follows:
Struct InputPointlnfo  Struct InputPointInfo
Point < Int positionx, Int positiony >; 〃关键几何特征点的坐标位置 Int PointColor //标识像素点的像素颜色, 操作命令、 输入笔划的 像素点颜色在终端上是唯一的 Point < Int positionx, Int positiony >; 坐标Coordinate position of key geometric feature points Int PointColor //Identifies the pixel color of the pixel. The pixel of the operation command and input stroke is unique on the terminal.
Int strokeld; //标识关键几何特征点所属笔划 具体的, 单个输入笔划的存储形式如下:  Int strokeld; //Identifies the stroke of the key geometric feature point. Specifically, the storage form of a single input stroke is as follows:
Struct Strokelnfo  Struct Strokelnfo
Int strokeld; //标识每个笔划的 id InputPointlnfo *inputPontinfo; 〃存储该输入笔划包含的多个关键几 何特征点的链表 Int strokeld; / / identify the id of each stroke InputPointlnfo *inputPontinfo; 〃 Store the linked list of multiple key geometric feature points contained in the input stroke
In OperatorCommandld; 个输入笔划的 Strokelnfo组成 Strokelnfo链表。  In OperatorCommandld; Strokelnfo of input strokes constitutes Strokelnfo linked list.
步骤 202, 移动终端计算输入笔划的数目。  Step 202: The mobile terminal calculates the number of input strokes.
根据步骤 201中提供的输入笔划的存储形式, 当用户输入一个笔划时, 就采用 Strokelnfo 的存储形式进行存储, 即一个输入笔划对应一个 StrokeInfo。 因此,可以根据 Strokelnfo链表上 Strokelnfo的数量来确定输入 笔划的数目。  According to the storage form of the input stroke provided in step 201, when the user inputs a stroke, the storage form of Strokelnfo is used, that is, one input stroke corresponds to one StrokeInfo. Therefore, the number of input strokes can be determined based on the number of StrokeInfos on the Strokelnfo list.
步骤 203 , 移动终端根据输入笔划的数目识别编辑操作命令子集。  Step 203: The mobile terminal identifies the subset of the editing operation command according to the number of input strokes.
根据输入笔划的数目从编辑操作命令集中识别出对应的编辑操作命令 分类、 如笔划数目为 1 对应一类编辑操作命令, 该类编辑操作命令中每一 个编辑操作命令都只包含一个笔划。 例如, 输入笔划的数目为 2 时, 就可 以识别出对应的一类编辑操作命令, 该类编辑操作命令中每一个编辑操作 命令都包含两个笔划。 可以将一类编辑操作命令称为一个编辑操作命令子 具体的, 一个编辑操作命令的存储形式如下: According to the number of input strokes, the corresponding editing operation command classification is recognized from the editing operation command set, for example, the number of strokes is 1 corresponding to a type of editing operation command, and each editing operation command in the editing operation command includes only one stroke. For example, when the number of input strokes is 2, a corresponding type of editing operation command can be identified, and each editing operation command in the type of editing operation command includes two strokes. A type of editing operation command can be called an editing operation command. The storage form of an editing operation command is as follows:
Figure imgf000009_0001
Figure imgf000009_0001
Int OperatorCommandld; //标识该编辑操作命令的 id Int OperatorCommandld; / / identify the id of the edit operation command
Int OperatorCommandStrokeNumber; 〃标识该编辑操作命令对应的 笔划数目  Int OperatorCommandStrokeNumber; 〃 identifies the number of strokes corresponding to the edit operation command
Strokelnfo *Strokeinfo; //存储该编辑操作命令包含的每个笔划的信 息、 即每个笔划对应的 Strokelnfo 则根据 OperatorCommandStrokeNumber ,就可以将编辑操作命令按照其 包含的笔划数目进行分类。 Strokelnfo *Strokeinfo; / / store the information of each stroke included in the edit operation command, that is, Strokelnfo corresponding to each stroke According to OperatorCommandStrokeNumber, the edit operation command can be classified according to the number of strokes it contains.
步骤 204 , 移动终端根据输入笔划的关键几何特征点识别编辑操作命 令。  Step 204: The mobile terminal identifies an edit operation command according to a key geometric feature point of the input stroke.
移动终端根据步骤 201 中记录的输入笔划的关键几何特征点, 从步骤 203中识别出的编辑操作命令分类中识别出对应的编辑操作命令,即将输入 笔划的关键几何特征点, 与该类编辑操作命令中所有编辑操作命令对应的 笔划的关键几何特征点进行匹配。  The mobile terminal identifies the corresponding editing operation command from the editing operation command classification identified in step 203 according to the key geometric feature point of the input stroke recorded in step 201, that is, the key geometric feature point of the stroke is input, and the editing operation is performed. Match the key geometric feature points of the strokes corresponding to all edit operation commands in the command.
具体地, 一类编辑操作命令、 即编辑操作命令子集的存储形式如下:
Figure imgf000010_0001
Specifically, a type of editing operation command, that is, a subset of the editing operation command, is stored as follows:
Figure imgf000010_0001
Int OperaotCommandFlag; //如分别使用 0: 删除, 1 : 移动, 2: 倒 置, 3: 插入, 4: 修改; 以后还可以随着编辑操作命令增多而增加 Int OperaotCommandFlag; //If using 0: delete, 1 : move, 2: invert, 3: insert, 4: modify; can also be increased later with the increase of editing operation commands
OperatorCommandlnfo * OperatorCommandlnfo; II存储所有编辑操 作命令的信息、 即每个编辑操作命令的 OperatorCommandlnfo 具体的, 输入的关键几何特征点和编辑操作命令对应的关键几何特征 点的匹配, 可以采用现有技术中输入笔划与终端存储的笔划的匹配方法进 行, 此处不再赘述。  OperatorCommandlnfo * OperatorCommandInfo; II stores the information of all editing operation commands, that is, the OperatorCommandInfo of each editing operation command, the input of the key geometric feature points and the matching of the key geometric feature points corresponding to the editing operation command, which can be input in the prior art. The matching method between the stroke and the stroke stored in the terminal is performed, and details are not described herein again.
需要指出的是, 在识别出编辑操作命令后, 移动终端还可以向用户确 认是否执行该编辑操作命令, 如果是, 再对所述输入笔划闭包的文字或者 图形进行处理, 否则, 等待用户重新进行输入笔划的操作。  It should be noted that after the editing operation command is recognized, the mobile terminal may further confirm to the user whether to execute the editing operation command, and if yes, process the text or graphics of the input stroke closing package, otherwise, wait for the user to re-execute Perform the operation of entering a stroke.
步骤 205 ,移动终端根据识别出的编辑操作命令对编辑操作对象进行处 理。  Step 205: The mobile terminal processes the edit operation object according to the recognized edit operation command.
该步骤中, 移动终端根据输入笔划对应的编辑操作命令与被操作文字 或图形的闭包之间的几何关系进行结果反馈处理。 编辑操作命令的闭包面积, 即该闭包面积内的图形或文字为该操作命 令的处理对象。 如果输入的编辑操作命令的闭包面积内部存在像素点, 则 依据闭包面积内该像素点所属的文字 (图形)和该输入的编辑操作命令的 关键几何特征点中拐点的关系进行相应的反馈处理、 即对该像素点所属的 文字 (图形)进行该输入的编辑操作命令的处理; 如果输入的编辑操作命 令的闭包面积内部不存在像素点, 但是闭包面积相邻一定范围内存在像素 点, 则根据该相邻像素点进行相应的反馈处理。 In this step, the mobile terminal performs result feedback processing according to the geometric relationship between the edit operation command corresponding to the input stroke and the closure of the operated text or graphic. Editing the closure area of the operation command, that is, the graphic or text within the closure area is the processing object of the operation command. If there is a pixel inside the closed area of the input editing operation command, corresponding feedback is performed according to the relationship between the text (graphic) of the pixel in the closure area and the inflection point of the key geometric feature point of the input editing operation command. Processing, that is, processing of the input editing operation command for the character (graphic) to which the pixel belongs; if there is no pixel inside the closed area of the input editing operation command, but the closed area exists within a certain range of pixels Point, then corresponding feedback processing is performed according to the adjacent pixel points.
此步骤存在用户输入不精确的情况, 即编辑操作命令闭包面积与所要 处理的文字、 图形闭包面积不是完全标准的包含关系或者相邻关系, 本发 明的处理方式是: 当编辑操作命令闭包面积与闭包内文字、 图形闭包面积 的比例为 3/2~2/1之间时则认为是包含关系; 当编辑操作命令闭包面积与闭 包内文字、 图形闭包面积比例 ' j、于 3/2时认为是相邻关系。  In this step, there is a case where the user input is inaccurate, that is, the editing operation command closure area and the text to be processed, the graphic closure area are not completely standard inclusion relationships or adjacent relations, and the processing method of the present invention is: when the editing operation command is closed When the ratio of the area of the package to the area of the closure and the area of the closure of the closure is between 3/2 and 2/1, it is considered to be the inclusion relationship; when the editing operation command is closed, the area of the closure and the area of the closure of the graphic is ' j, considered to be an adjacent relationship at 3/2.
步骤 206, 移动终端将处理后的结果反馈给用户, 并释放输入笔划的关 键几何特征点。  Step 206: The mobile terminal feeds back the processed result to the user, and releases the key geometric feature point of the input stroke.
移动终端在将处理结果反馈给用户的同时, 释放掉所记录的当前输入 笔划的关键几何特征点、 并刷新编辑界面、 即在编辑界面上不留下任何操 作痕迹。 刷新编辑界面 的过程实 际是销毁操作命令变量 OperatorCommandlnfo的过程。  While the processing result is fed back to the user, the mobile terminal releases the recorded key geometric feature points of the current input stroke and refreshes the editing interface, that is, does not leave any operation trace on the editing interface. The process of refreshing the editing interface is actually the process of destroying the operation command variable OperatorCommandInfo.
需要指出的是, 在进行编辑操作命令的识别时, 也可以不执行步骤 203 的操作, 而直接根据输入笔划的关键几何特征点在编辑操作命令集中识别 对应的编辑操作命令。 上述编辑操作命令子集的存储方式也适用于编辑操 作命令集。  It should be noted that, when the editing operation command is recognized, the operation of step 203 may not be performed, and the corresponding editing operation command is directly recognized in the editing operation command set according to the key geometric feature points of the input stroke. The above storage operation command subset is also stored in the edit operation command set.
下面结合几个具体应用, 介绍上述图文编辑功能的具体实现: 应用一: 对处理的对象进行删除操作。  The following describes the specific implementation of the above graphic editing function in combination with several specific applications: Application 1: Delete the processed object.
可以设置: 删除操作命令的几何特征分两种情况: 一种画叉的方式, 即两笔划为直线且相交于一点,如 A C D , 同时该笔划闭包范围内存在文 字或图形的像素点, 表示要删除文字 "B" ; 另一种画不规则直线方式、 如 ≠*C D , 时该笔划闭包范围内存在文字或图形的像素点,表示要删除文字 "AB" „ Can be set: The geometric features of the delete operation command are divided into two cases: a way of drawing a fork, That is, the two strokes are drawn as a straight line and intersect at a point, such as ACD. At the same time, there are pixels of text or graphics in the range of the stroke closure, indicating that the character "B" is to be deleted; and another way of drawing irregular lines, such as ≠*CD, When there is a pixel of text or graphic in the range of the stroke closure, it means that the character "AB" is to be deleted.
该步骤中, 移动终端根据与输入笔划相对应的编辑操作命令的编号, 进行删除操作, 具体地, 移动终端利用该输入笔划的边界点和关键几何特 征点计算该输入笔划、 即编辑操作命令的闭包面积; 然后确定闭包面积内 文字或图形的像素点, 对闭包面积内的文字或图形进行删除, 删除后对编 辑界面进行刷新操作, 并将删除后的状态反馈给用户, 其中, 可以按照现 有技术计算该输入笔划闭包面积; 具体地对闭包面积内的文字或图形进行 删除过程, 实际是当编辑操作命令闭包面积与闭包面积内的文字或图形闭 包面积为包含关系或相邻关系时, 此时释放闭包范围内像素点对应的文字 或图形。  In this step, the mobile terminal performs a delete operation according to the number of the edit operation command corresponding to the input stroke. Specifically, the mobile terminal calculates the input stroke, that is, the edit operation command, by using the boundary point of the input stroke and the key geometric feature point. Closing area; then determining the pixel of the text or graphic in the closure area, deleting the text or graphic in the closing area, and refreshing the editing interface after deleting, and feeding back the deleted state to the user, wherein The input stroke closure area can be calculated according to the prior art; specifically, the deletion process of the text or graphics in the closure area is actually when the editing operation command closure area and the closure area of the text or graphics in the closure area are When a relationship or a neighbor relationship is included, the text or figure corresponding to the pixel within the closure range is released.
应用二: 添加操作。 可以设置: 添加操作的几何特征是两笔划为直线且相交于一点, 同时 该两笔划操作命令在界面上显示完成时, 其闭包范围内不存在文字或图形  Application 2: Add an operation. Can be set: The geometric feature of the add operation is that the two strokes are straight lines and intersect at one point. At the same time, when the two stroke operation commands are displayed on the interface, there is no text or graphics in the closure range.
V  V
的像素点, 如^ P C D , 表示需要在文字 "AB" 之间添加, 在文字 "CD" 之间添力口。 移动终端根据与输入笔划相对应的编辑操作命令, 进行添加操作, 具 体地, 首先计算添加编辑操作命令闭包面积与编辑操作文字的闭包面积的 关系, 如果二者之间的比例小于 3/2, 则移动终端利用该添加笔划的顶点位 置 (即两个笔划的交点) 向左方向上扫描查找添加笔划的左邻方向上的文 字位置, 并将添加笔划的右邻方向上的文字后移, 然后在左邻方向上的文 字位置后添加编辑操作命令闭包内的文字, 即添加笔划正下方或正上方新 输入的文字, 并将添加后的状态反馈给用户; 具体地反馈给用户是记录添 加笔划正下方或正上方新输入的文字。 The pixels, such as ^ P CD , indicate that you need to add between the words "AB" and add a force between the words "CD". The mobile terminal performs an adding operation according to the editing operation command corresponding to the input stroke. Specifically, first, the relationship between the closing area of the editing operation command and the closing area of the editing operation text is calculated, if the ratio between the two is less than 3/ 2, the mobile terminal scans the position of the vertex in the left neighboring direction of the added stroke by using the vertex position of the added stroke (ie, the intersection of the two strokes), and moves the text in the right adjacent direction of the added stroke back. Then, add the text in the editing operation command closure after the text position in the left neighboring direction, that is, add the newly input text directly below or directly above the stroke, and feed back the added state to the user; specifically feedback to the user is Record Tim Add the newly entered text directly below or directly above the stroke.
应用三、 移动操作。  Application three, mobile operation.
可以设置, 移动编辑操作命令的几何特征是一条弧线和一条椭圆或圆 相交, 并设置椭圆或圆内的文字或图像需要移动到弧线所指的位置, 如
Figure imgf000013_0001
, 表示需要将 "人民" 移动到 "家" 的右邻位置。
You can set the geometric feature of the move edit operation command to be an arc intersecting an ellipse or a circle, and set the text or image inside the ellipse or circle to move to the position indicated by the arc, such as
Figure imgf000013_0001
, indicating that the "people" needs to be moved to the right neighbor of the "home".
移动终端根据与输入笔划相对应的编辑操作命令, 进行移动操作, 具 体地, 首先计算移动编辑操作命令闭包面积与编辑操作文字的闭包面积的 关系, 如果二者之间的比例在 3/2和 2/1之间时则认为是包含关系, 那么移 动终端提前保存输入笔划的终点位置 ( "家" 的右邻处)和输入笔划的圆 圈之间闭包面积内的文字信息 (即 "人民,, ) , 然后利用输入笔划记录的 圆圈面积扫描像素点的位置, 提取该面积内的文字信息, 接着再将输入笔 划终点位置和输入的圆圈笔划之间的文字信息替换为提取的圆圈面积内文 字, 最后再在圆圈面积内置入最开始保存的移动动作终点位置和移动工作 圆圈笔划之间的文字信息, 进一步地置入过程为普通输入字符过程。  The mobile terminal performs a moving operation according to the editing operation command corresponding to the input stroke. Specifically, first, the relationship between the closed area of the mobile editing operation command and the closed area of the editing operation text is calculated, if the ratio between the two is 3/ When the relationship between 2 and 2/1 is considered to be an inclusion relationship, the mobile terminal saves the text information in the closed area between the end position of the input stroke (the right neighbor of "home") and the circle of the input stroke (ie, " The people, , ), then use the area of the circle recorded by the input stroke to scan the position of the pixel, extract the text information in the area, and then replace the text information between the input stroke end position and the input circle stroke with the extracted circle area. The internal text, and finally the text area between the last saved moving action end position and the moving working circle stroke is built in the circle area, and the further insertion process is a normal input character process.
应用四: 倒置操作。  Application 4: Inverted operation.
可以设置, 倒置编辑操作命令的几何特征是一笔划, 同时该笔划的关 键几何特征点 (指拐点与始末点)之间角度值至少存在 2个接近直角 (即 角度值在一定范围内, 本发明设置的范围是号± ), 且这 2个接近直角角 度之和接近 π (即在一定范围内,本发明设置的范围是 π士 )、如 , 表示需要将 "人" 和 "民" 进行倒置。  It can be set that the geometric feature of the inverted editing operation command is a stroke, and the angle value between the key geometric feature points (referring to the inflection point and the starting point) of the stroke has at least two near right angles (ie, the angle value is within a certain range, the present invention The range of the setting is the number ±), and the sum of the two near-right angles is close to π (that is, within a certain range, the range set by the present invention is π), for example, indicating that the "person" and the "people" need to be inverted. .
首先, 计算倒置编辑操作命令闭包面积与编辑操作文字的闭包面积的 关系, 如果二者之间的比例在 3/2和 2/1之间时则认为是包含关系, 那么移 动终端根据与输入笔划相对应的编辑操作命令, 进行倒置操作。 具体地, 移动终端分别保存前半个折线闭包面积内的文字信息, 以及后半个折线闭 包面积内的文字信息, 具体地是首先根据倒置操作拐点位置和始末点的位 置信息, 确定前后半个折线的闭包面积, 然后根据闭包面积内扫描的像素 点确定闭包内文字位置; 进一步地, 将前、 后半个折线闭包面积内的文字 信息进行互换, 具体地, 互换过程是首先分别保存前后半个折线闭包面积 内文字信息以及文字位置为临时变量, 然后对前后半个折线闭包面积内文 字信息的位置变量对换, 进一步地, 移动终端在原来后半个折线闭包面积 内写入原前半个折线闭包面积内文字信息, 在原来前半个折线闭包面积内 写入原后半个折线闭包面积内的文字信息。 其中, 移动终端可以按照现有 技术确定半个折线闭包面积内的文字信息, 且前后半个折线闭包与其闭包 内文字信息的关系根据二者之间的闭包关系决定是包含还是相邻。 First, the relationship between the closure area of the inverted editing operation command and the closure area of the editing operation text is calculated. If the ratio between the two is between 3/2 and 2/1, it is considered to be an inclusion relationship, then the mobile terminal according to Enter the editing operation command corresponding to the stroke to perform the inversion operation. Specifically, the mobile terminal separately stores the text information in the area of the first half of the fold line closure, and the second half of the fold line is closed. The text information in the package area is specifically determined according to the position of the inflection point of the inversion operation and the position information of the start point and the end point, and the closure area of the front and rear half fold lines is determined, and then the position of the text in the closure is determined according to the pixel points scanned within the closure area; Further, the text information in the front and rear half of the fold line closure area is interchanged. Specifically, the exchange process first saves the text information and the character position in the front and rear half of the fold line closure area as temporary variables, and then The position variable of the text information in the front and rear half of the fold line closure area is swapped. Further, the mobile terminal writes the text information in the original half of the fold line closure area in the original half of the fold line closure area, and the first half of the fold line is closed. Write the text information in the original half of the fold line closure area within the package area. The mobile terminal can determine the text information in the closed area of the half fold line according to the prior art, and the relationship between the front and rear half of the fold line closure and the text information in the closed package is determined according to the closure relationship between the two. adjacent.
应用五: 改变图形大小。  Application 5: Change the size of the graphic.
可以设置, 改变图形大小操作的几何特征是直线, 且该编辑操作命令 的闭包面积内不存在终端上要修改文字或图形的像素点。 进一步地, 本发 明通过像素点颜色来区分输入的编辑操作命令笔划与修改的文字或图形。  It can be set that the geometric feature of the operation of changing the graphic size is a straight line, and there is no pixel on the terminal to modify the text or the graphic in the closure area of the editing operation command. Further, the present invention distinguishes the input editing operation command stroke from the modified text or graphic by the pixel dot color.
移动终端根据输入笔划 (此处为修改编辑操作命令对应的笔划、 筒称 修改笔划) 的终点坐标位置, 改变图形的大小 (长、 宽等大小) 并以最新 的大小属性信息重画该图形; 进一步地, 该步骤中默认移动终端已经保存 要修改图形的长宽信息或者对角线上的顶点信息, 接着根据修改笔划的终 点坐标位置和修改图形与修改笔划交点坐标位置, 计算长和宽的差值, 将 差值与原图形的长宽相加, 或者相减则可得出修改后新图形的长宽信息, 移动终端按照最新大小属性重新绘制图形。  The mobile terminal changes the size (length, width, etc.) of the graphic according to the end point coordinate position of the input stroke (here, the stroke corresponding to the modified editing operation command, the modified stroke of the cartridge), and redraws the graphic with the latest size attribute information; Further, in this step, the default mobile terminal has saved the length and width information of the graphic or the vertex information on the diagonal line, and then calculates the length and width according to the coordinate position of the end point of the modified stroke and the coordinate position of the modified graphic and the modified stroke intersection. The difference is added to the length and width of the original graphic, or subtracted to obtain the length and width information of the modified new graphic, and the mobile terminal repaints the graphic according to the latest size attribute.
从上述实施例可以看出, 本发明技术方案在移动终端中通过筒单的几 何关系增加了人类习惯使用的书写编辑、 符号以及标识等, 使用户能够自 然地表达意图, 避免了寻找菜单项等复杂的操作, 筒化了用户操作, 并提 高了软件的用户体验。 当然, 本发明还可有多种实施方式, 在不背离本发明精神及其实质的 但凡在本发明的精神和原则之内所作的任何修改、 等同替换、 改进, 均应 包含在本发明所附的权利要求的保护范围之内。 It can be seen from the above embodiments that the technical solution of the present invention increases the writing editing, symbols and logos used by humans through the geometric relationship of the singles in the mobile terminal, so that the user can naturally express the intention and avoid searching for menu items, etc. Complex operations streamline user operations and improve the user experience of the software. The invention may, of course, be embodied in a variety of embodiments, and any modifications, equivalents, and improvements made within the spirit and scope of the invention are included in the present invention. Within the scope of protection of the claims.

Claims

权利要求书 Claim
1、 一种实现图文编辑功能的方法, 其特征在于, 该方法包括: 在启用图文编辑功能时, 记录用户输入的输入笔划;  A method for implementing a graphic editing function, the method comprising: recording an input stroke input by a user when the graphic editing function is enabled;
根据所述输入笔划的关键几何特征点, 从编辑操作命令集中查找与所 述输入笔划对应的编辑操作命令;  And searching for an editing operation command corresponding to the input stroke from the editing operation command set according to the key geometric feature point of the input stroke;
根据所述编辑操作命令, 对所述输入笔划闭包的文字或者图形进行处 理, 将处理结果反馈给用户。  The text or graphic of the input stroke closure is processed according to the editing operation command, and the processing result is fed back to the user.
2、 如权利要求 1所述的方法, 其特征在于, 所述编辑操作命令集中存 储有笔划与编辑操作命令的对应关系;  2. The method according to claim 1, wherein the editing operation command stores a correspondence between a stroke and an editing operation command in a centralized manner;
所述编辑操作命令分为文字编辑操作命令和图片编辑操作命令; 所述文字编辑操作命令至少包括删除、 添加、 移动和倒置命令; 所述图片编辑操作命令至少包括删除、 添加、 移动、 倒置和缩放命令。 The editing operation command is divided into a text editing operation command and a picture editing operation command; the text editing operation command includes at least a delete, add, move, and invert command; the image editing operation command includes at least deleting, adding, moving, inverting, and Zoom command.
3、 如权利要求 2所述的方法, 其特征在于, 该方法进一步包括: 依据 笔划的笔划数目, 将编辑操作命令集中的所有编辑操作命令进行分类, 得 到编辑操作命令子集。 3. The method of claim 2, wherein the method further comprises: classifying all of the editing operation commands in the editing operation command set according to the number of strokes of the stroke to obtain a subset of the editing operation commands.
4、 如权利要求 3所述的方法, 其特征在于, 从所述编辑操作命令集中 查找与所述输入笔划相对应的编辑操作命令的过程包括:  4. The method according to claim 3, wherein the process of searching for an editing operation command corresponding to the input stroke from the editing operation command set comprises:
计算所述输入笔划的笔划数目;  Calculating the number of strokes of the input stroke;
依据所述输入笔划的笔划数目从所述编辑操作命令集中查找出对应的 编辑操作命令子集;  Finding a corresponding subset of the editing operation command from the edit operation command set according to the number of strokes of the input stroke;
将所述输入笔划的关键几何特征点, 与所述编辑操作命令子集中编辑 操作命令对应的笔划的关键几何特征点进行匹配, 查找出与所述输入笔划 对应的编辑操作命令。  The key geometric feature points of the input stroke are matched with the key geometric feature points of the stroke corresponding to the editing operation command subset edit operation command, and the editing operation command corresponding to the input stroke is found.
5、 如权利要求 3所述的方法, 其特征在于, 查找到所述编辑操作命令 后, 该方法进一步包括: 向用户确认是否执行该编辑操作命令, 如果是, 再对所述输入笔划闭包的文字或者图形进行处理, 否则, 等待用户重新进 行输入笔划的操作。 5. The method according to claim 3, wherein after the editing operation command is found, the method further comprises: confirming to the user whether to execute the editing operation command, and if so, The text or graphics of the input stroke closure are processed again, otherwise, the user is waited for the operation of inputting the stroke again.
6、 如权利要求 1或 2所述的方法, 其特征在于, 对所述输入笔划闭包 的文字或者图形进行处理后, 该方法进一步包括: 释放所述输入笔划的关 键几何特征点, 并刷新移动终端显示界面。  The method according to claim 1 or 2, wherein after processing the text or graphics of the input stroke closure, the method further comprises: releasing key geometric feature points of the input stroke and refreshing Mobile terminal display interface.
7、 一种实现图文编辑功能的移动终端, 其特征在于, 包括输入模块、 编辑操作命令识别模块、 存储模块和处理模块, 其中:  7. A mobile terminal for implementing a graphic editing function, comprising: an input module, an editing operation command identification module, a storage module, and a processing module, wherein:
所述输入模块, 用于在启用图文编辑功能时, 记录用户输入的输入笔 划, 并将所述输入笔划提供给所述编辑操作命令识别模块;  The input module is configured to: when the text editing function is enabled, record an input stroke input by the user, and provide the input stroke to the editing operation command identification module;
所述编辑操作命令识别模块, 用于根据所述输入笔划的关键几何特征 点, 从编辑操作命令集中查找与所述输入笔划对应的编辑操作命令, 提供 给所述处理模块;  The editing operation command identifying module is configured to search for an editing operation command corresponding to the input stroke from the editing operation command set according to the key geometric feature point of the input stroke, and provide the editing operation command to the processing module;
所述存储模块, 用于存储所述编辑操作命令集;  The storage module is configured to store the edit operation command set;
所述处理模块, 用于根据所述编辑操作命令, 对输入笔划闭包的文字 或者图形进行处理, 将处理结果反馈给用户。  The processing module is configured to process the text or graphics of the input stroke closure according to the editing operation command, and feed back the processing result to the user.
8、 如权利要求 7所述的移动终端, 其特征在于,  8. The mobile terminal of claim 7, wherein
所述存储模块中所存储的编辑操作命令集, 为编辑操作命令与笔划的 对应关系; 所述编辑操作命令分为文字编辑操作命令和图片编辑操作命令, 其中, 所述文字编辑操作命令至少包括删除、 添加、 移动和倒置命令; 所 述图片编辑操作命令至少包括删除、 添加、 移动、 倒置和缩放命令。  The editing operation command set stored in the storage module is a correspondence between the editing operation command and the stroke; the editing operation command is divided into a text editing operation command and a picture editing operation command, wherein the text editing operation command includes at least Delete, add, move, and invert commands; the picture editing operation commands include at least delete, add, move, invert, and zoom commands.
9、 如权利要求 8所述的移动终端, 其特征在于,  9. The mobile terminal of claim 8, wherein
所述存储模块, 进一步用于依据笔划的笔划数目, 将编辑操作命令集 中的所有编辑操作命令进行分类, 得到编辑操作命令子集。 。  The storage module is further configured to classify all the editing operation commands in the editing operation command set according to the number of strokes of the stroke to obtain a subset of the editing operation commands. .
10、 如权利要求 9所述的移动终端, 其特征在于,  10. The mobile terminal of claim 9, wherein
所述编辑操作命令识别模块, 还用于计算所述输入笔划的笔划数目, 根据该笔划数目从所述编辑操作命令集中查找出对应的编辑操作命令子 集; 并将所述输入笔划的关键几何特征点, 与所述编辑操作命令子集中编 辑操作命令对应的笔划的关键几何特征点进行匹配, 查找出与所述输入笔 划对应的编辑操作命令。 The editing operation command identification module is further configured to calculate a number of strokes of the input stroke, And searching for a corresponding subset of the editing operation command from the editing operation command set according to the number of strokes; and key geometrical feature points of the input stroke and a key geometry of the stroke corresponding to the editing operation command subset editing operation command The feature points are matched, and an editing operation command corresponding to the input stroke is found.
11、 如权利要求 9所述的移动终端, 其特征在于,  11. The mobile terminal of claim 9, wherein
所述处理模块, 在编辑操作命令识别模块查找出与输入笔划对应的编 辑操作命令后, 还用于向用户确认是否执行该编辑操作命令, 如果是, 再 对所述输入笔划闭包的文字或者图形进行处理, 否则, 等待用户重新进行 输入笔划的操作。  The processing module, after the editing operation command identification module searches for an editing operation command corresponding to the input stroke, is further used to confirm to the user whether to execute the editing operation command, and if so, the text of the input stroke closing or The graphics are processed, otherwise, the user is waiting for the input stroke to be re-executed.
12、 如权利要求 7~11任一项所述的移动终端, 其特征在于, 所述处理模块, 在对所述输入笔划闭包的文字或者图形进行处理后, 还用于释放所述输入笔划的特征点, 并刷新显示界面。  The mobile terminal according to any one of claims 7 to 11, wherein the processing module is further configured to release the input stroke after processing the text or graphics of the input stroke closure Feature points, and refresh the display interface.
PCT/CN2009/075855 2009-07-10 2009-12-22 Mobile terminal and method thereof for implementing image and text editing function WO2011003262A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CNA2009101585257A CN101605176A (en) 2009-07-10 2009-07-10 The method of a kind of portable terminal and realization video text editing function thereof
CN200910158525.7 2009-07-10

Publications (1)

Publication Number Publication Date
WO2011003262A1 true WO2011003262A1 (en) 2011-01-13

Family

ID=41470720

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2009/075855 WO2011003262A1 (en) 2009-07-10 2009-12-22 Mobile terminal and method thereof for implementing image and text editing function

Country Status (2)

Country Link
CN (1) CN101605176A (en)
WO (1) WO2011003262A1 (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101605176A (en) * 2009-07-10 2009-12-16 中兴通讯股份有限公司 The method of a kind of portable terminal and realization video text editing function thereof
CN102455869B (en) * 2011-09-29 2014-10-22 北京壹人壹本信息科技有限公司 Method and device for editing characters by using gestures
CN103513852A (en) * 2012-06-21 2014-01-15 深圳富泰宏精密工业有限公司 Text editing system and method of electronic device
CN103677637B (en) * 2013-12-06 2018-10-12 上海斐讯数据通信技术有限公司 Delete the method and electronic equipment of the word of display on the touchscreen
CN108932095A (en) * 2018-07-06 2018-12-04 深圳点猫科技有限公司 A kind of method, electronic equipment handling figure by shortcut key based on artificial intelligence

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1117170A (en) * 1994-08-17 1996-02-21 财团法人工业技术研究院 System of taking stroke character as edit instruction
EP0607926B1 (en) * 1993-01-18 2000-04-26 Sharp Kabushiki Kaisha Information processing apparatus with a gesture editing function
EP0992877B1 (en) * 1992-10-21 2003-02-26 Sharp Kabushiki Kaisha Information processing apparatus
CN101605176A (en) * 2009-07-10 2009-12-16 中兴通讯股份有限公司 The method of a kind of portable terminal and realization video text editing function thereof

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP0992877B1 (en) * 1992-10-21 2003-02-26 Sharp Kabushiki Kaisha Information processing apparatus
EP0607926B1 (en) * 1993-01-18 2000-04-26 Sharp Kabushiki Kaisha Information processing apparatus with a gesture editing function
CN1117170A (en) * 1994-08-17 1996-02-21 财团法人工业技术研究院 System of taking stroke character as edit instruction
CN101605176A (en) * 2009-07-10 2009-12-16 中兴通讯股份有限公司 The method of a kind of portable terminal and realization video text editing function thereof

Also Published As

Publication number Publication date
CN101605176A (en) 2009-12-16

Similar Documents

Publication Publication Date Title
CN102968206B (en) Input unit and method for the terminal device with touch modules
TWI564786B (en) Managing real-time handwriting recognition
CN104166474B (en) Information processor and character identifying method
US8487888B2 (en) Multi-modal interaction on multi-touch display
WO2017185575A1 (en) Touch screen track recognition method and apparatus
US9378573B2 (en) Information processing apparatus and control method thereof
TW201303788A (en) Image segmentation methods and image segmentation methods systems
JP6427559B6 (en) Permanent synchronization system for handwriting input
JP2845149B2 (en) Handwritten character input device and handwritten character input method
JP6147825B2 (en) Electronic apparatus and method
CN109614847A (en) Manage real-time handwriting recognition
TW201510775A (en) Real-time stroke-order and stroke-direction independent handwriting recognition
US20180121074A1 (en) Freehand table manipulation
US20140298223A1 (en) Systems and methods for drawing shapes and issuing gesture-based control commands on the same draw grid
JP2001005599A (en) Information processor and information processing method an d recording medium recording information processing program
WO2011003262A1 (en) Mobile terminal and method thereof for implementing image and text editing function
WO2019000681A1 (en) Information layout method, device, apparatus and computer storage medium
WO2014147722A1 (en) Electronic apparatus, method, and program
WO2014106380A1 (en) Camera-based control method and mobile terminal
TW201407420A (en) Improved video tracking
JP6054547B2 (en) Electronic device and method for processing handwritten document information
WO2014103388A1 (en) Electronic device, display method, and program
WO2016145827A1 (en) Terminal control method and device
CN106990900A (en) One kind writing implementation method and device
CN106502553A (en) Gesture interaction operational approach

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 09847013

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 09847013

Country of ref document: EP

Kind code of ref document: A1