CN108491145B - Handwriting canceling method and device for writing application, storage medium and terminal device - Google Patents

Handwriting canceling method and device for writing application, storage medium and terminal device Download PDF

Info

Publication number
CN108491145B
CN108491145B CN201810254400.3A CN201810254400A CN108491145B CN 108491145 B CN108491145 B CN 108491145B CN 201810254400 A CN201810254400 A CN 201810254400A CN 108491145 B CN108491145 B CN 108491145B
Authority
CN
China
Prior art keywords
drawing area
handwriting
temporary
area
current
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
CN201810254400.3A
Other languages
Chinese (zh)
Other versions
CN108491145A (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.)
Guangzhou Shiyuan Electronics Thecnology Co Ltd
Guangzhou Shirui Electronics Co Ltd
Original Assignee
Guangzhou Shiyuan Electronics Thecnology Co Ltd
Guangzhou Shirui Electronics 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 Guangzhou Shiyuan Electronics Thecnology Co Ltd, Guangzhou Shirui Electronics Co Ltd filed Critical Guangzhou Shiyuan Electronics Thecnology Co Ltd
Priority to CN201810254400.3A priority Critical patent/CN108491145B/en
Publication of CN108491145A publication Critical patent/CN108491145A/en
Application granted granted Critical
Publication of CN108491145B publication Critical patent/CN108491145B/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/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

Abstract

The embodiment of the invention discloses a method for canceling handwriting of writing application, which comprises the following steps: responding to a cancel operation instruction of any drawing area, and judging whether the current drawing area is a temporary drawing area; if the current drawing area is the temporary drawing area, judging whether handwriting exists in the current drawing area; if the current drawing area is the temporary drawing area and handwriting exists in the current drawing area, calculating a specific area corresponding to the cancelling operation instruction, and redrawing the handwriting in the specific area corresponding to the cancelling operation instruction in the current drawing area; and if the current drawing area is the temporary drawing area and no handwriting exists in the current drawing area, sending a cancel operation instruction to the next drawing area. The invention also discloses a device for canceling the handwriting, a storage medium and a terminal device. The handwriting canceling method for the writing application of the embodiment of the invention realizes the quick canceling of the handwriting by the scheme of arranging the plurality of temporary drawing areas which are sequentially arranged.

Description

Handwriting canceling method and device for writing application, storage medium and terminal device
Technical Field
The invention relates to the field of object editing, in particular to a method and a device for canceling handwriting of writing application, a storage medium and a terminal device.
Background
With the increasing development of information technology, editing objects such as pictures and characters becomes a basic function in the field of object editing, and undoing completed operations is a basic operation of object editing.
The revocation is used for discovering that one or some operations finished recently are not needed or not ideal after a user performs some operations on an object such as a file or file content, and wants to restore the object such as the file or file content, and therefore, the user needs to revoke the unnecessary or not ideal operations. For example, after the user deletes the handwriting in the specific area, it is found that the deletion operation is an erroneous operation and the handwriting in the specific area needs to be restored, and at this time, the user needs to restore the handwriting by undoing, and the system redraws all the deleted handwriting in the original specific area when executing the undo instruction. The traditional drawing method is carried out on the same canvas, the handwriting execution operation is carried out on the handwriting drawn on the canvas, the operation cancellation is also carried out on the handwriting drawn on the canvas, and when the operation cancellation is carried out, all the handwriting in a specific area corresponding to the last operation needs to be redrawn. Therefore, when there is much writing in the specific area, it takes a long time and the system performance is more consumed to redraw the writing.
Disclosure of Invention
The embodiment of the invention aims to provide a method and a device for canceling handwriting for writing application, which can effectively solve the problems of long time and system performance consumption in redrawing handwriting in the existing canceling operation, can quickly complete the canceling operation and improve the system performance.
In order to achieve the above object, an embodiment of the present invention provides a method for canceling handwriting for writing application, which is characterized in that the method is applicable to n sequentially set drawing areas, where the first n-1 drawing areas of the n sequentially set drawing areas are temporary drawing areas, the nth drawing area is a permanent drawing area, and n is greater than or equal to 2; in the n sequentially set drawing areas, a first temporary drawing area is used for receiving the latest handwriting; in the N sequentially set drawing areas, starting from the second temporary drawing area, each temporary drawing area is used for transferring N pieces of handwriting to the next temporary drawing area and redrawing the N pieces of handwriting of the previous temporary drawing area, wherein N is more than or equal to 1; the method comprises the following steps:
responding to a cancel operation instruction of any drawing area, and judging whether the current drawing area is a temporary drawing area;
if the current drawing area is a temporary drawing area, judging whether handwriting exists in the current drawing area;
if the current drawing area is a temporary drawing area and handwriting exists in the current drawing area, calculating a specific area corresponding to the cancel operation instruction, and redrawing the handwriting in the specific area;
and if the current drawing area is the temporary drawing area and no handwriting exists in the current drawing area, sending a cancel operation instruction to the next drawing area.
As an improvement of the above scheme, if the current drawing area is the temporary drawing area and no handwriting exists in the current drawing area, the step of sending a cancel operation instruction to the next drawing area specifically includes:
and if the current drawing area is any one temporary drawing area from 1 st to n-2 th of the n sequentially set drawing areas and no handwriting exists in the current drawing area, sending a cancel operation instruction to the next drawing area.
As an improvement of the above, the method further comprises the steps of:
responding to a drawing operation instruction of the first drawing area, and judging whether the handwriting number of the first drawing area is equal to a preset threshold value N;
when the number of the handwriting in the first drawing area is equal to the preset threshold value N, sending a drawing operation instruction to the next drawing area, transmitting the N handwriting in the first drawing area to the second drawing area, and simultaneously emptying the handwriting in the first drawing area;
starting from the second drawing area, responding to a drawing operation instruction of any drawing area except the first drawing area, and judging whether the current drawing area is a temporary drawing area;
if the current drawing area is a temporary drawing area, judging whether handwriting exists in the current drawing area;
if the current drawing area is the temporary drawing area and no handwriting exists in the current drawing area, redrawing the handwriting of the previous drawing area in the current drawing area;
if the current drawing area is a temporary drawing area and handwriting exists in the current drawing area, transferring the handwriting in the current drawing area to a next drawing area and emptying the current drawing area, redrawing the handwriting in the previous drawing area in the current drawing area, and sending a drawing operation instruction to the next drawing area;
and if the current drawing area is the permanent drawing area, adding the handwriting transferred by the previous temporary drawing area in the current drawing area.
As an improvement of the above scheme, when n is 3, the n sequentially set drawing areas include a first temporary drawing area, a second temporary drawing area, and a permanent drawing area, and the method specifically includes the steps of:
responding to a cancel operation instruction of a first temporary drawing area, when detecting that handwriting exists in the first temporary drawing area, calculating a specific area corresponding to the cancel operation instruction on the first temporary drawing area, and redrawing the handwriting in the specific area corresponding to the cancel operation instruction on the first temporary drawing area;
when detecting that no handwriting exists in the first temporary drawing area, sending a cancel operation instruction to the second temporary drawing area;
responding to a cancel operation instruction of a second temporary drawing area, and judging whether handwriting exists in the second temporary area;
and when judging that the handwriting exists in the second temporary drawing area, calculating a specific area corresponding to the cancelling operation instruction on the second temporary drawing area, and redrawing the handwriting in the specific area corresponding to the cancelling operation instruction on the second temporary drawing area.
As an improvement of the scheme, the writing application is electronic whiteboard software arranged on the interactive intelligent device.
The embodiment of the invention also provides a handwriting canceling device for writing application, which is characterized by being suitable for n sequentially set drawing areas, wherein the first n-1 drawing areas of the n sequentially set drawing areas are temporary drawing areas, the nth drawing area is a permanent drawing area, and n is more than or equal to 2; in the n sequentially set drawing areas, a first temporary drawing area is used for receiving the latest handwriting; in the N sequentially set drawing areas, starting from the second temporary drawing area, each temporary drawing area is used for transferring N pieces of handwriting to the next temporary drawing area and redrawing the N pieces of handwriting of the previous temporary drawing area, wherein N is more than or equal to 1; the device comprises:
the first revocation judgment module is used for responding to a revocation operation instruction of any drawing area and judging whether the current drawing area is a temporary drawing area;
the second revocation judging module is used for judging whether handwriting exists in the current drawing area if the current drawing area is the temporary drawing area;
the first revocation processing module is used for calculating a specific area corresponding to the revocation operation instruction and redrawing the handwriting in the specific area if the current drawing area is the temporary drawing area and the current drawing area has the handwriting;
and the second revocation processing module is used for sending a revocation operation instruction to the next drawing area if the current drawing area is the temporary drawing area and no handwriting exists in the current drawing area.
As an improvement of the above, the apparatus further comprises:
the first drawing judgment module is used for responding to the drawing operation instruction of the first drawing area and judging whether the handwriting number of the first drawing area is equal to a preset threshold value N or not;
the first drawing processing module is used for sending a drawing operation instruction to the next drawing area when the number of the handwriting in the first drawing area is equal to the preset threshold value N, transmitting the N handwriting in the first drawing area to the second drawing area, and simultaneously emptying the handwriting in the first drawing area;
the second drawing judgment module is used for responding to a drawing operation instruction of any drawing area except the first drawing area from the second drawing area and judging whether the current drawing area is a temporary drawing area;
the third drawing judgment module is used for judging whether handwriting exists in the current drawing area if the current drawing area is the temporary drawing area;
the second drawing processing module is used for redrawing the handwriting of the previous drawing area in the current drawing area if the current drawing area is the temporary drawing area and the current drawing area has no handwriting;
the third drawing processing module is used for transferring the handwriting on the current drawing area to the next drawing area and emptying the current drawing area if the current drawing area is a temporary drawing area and the current drawing area has the handwriting, redrawing the handwriting of the previous drawing area in the current drawing area and sending a drawing operation instruction to the next drawing area;
and the fourth drawing processing module is used for adding the handwriting transferred by the previous temporary handwriting drawing area in the current drawing area if the current drawing area is the permanent drawing area.
As an improvement of the above scheme, when n is 3, the n sequentially set rendering regions include a first temporary rendering region, a second temporary rendering region, and a permanent rendering region, and the apparatus specifically includes:
the first judging module is used for responding to a cancel operation instruction of a first temporary drawing area, when detecting that handwriting exists in the first temporary drawing area, calculating a specific area corresponding to the cancel operation instruction on the first temporary drawing area, and redrawing the handwriting in the specific area corresponding to the cancel operation instruction on the first temporary drawing area;
the second judgment module is used for sending a cancel operation instruction to the second temporary drawing area when detecting that no handwriting exists in the first temporary drawing area;
the third judging module is used for responding to a cancel operation instruction of the second temporary drawing area and judging whether handwriting exists in the second temporary drawing area;
and the first cancelling module is used for calculating a specific area corresponding to the cancelling operation instruction on the second temporary drawing area and redrawing the handwriting in the specific area corresponding to the cancelling operation instruction on the second temporary drawing area when the second temporary drawing area is judged to have the handwriting.
As an improvement of the scheme, the writing application is electronic whiteboard software arranged on the interactive intelligent device.
Compared with the prior art, the handwriting canceling method and the device for the writing application disclosed by the invention respond to the canceling operation instruction of any drawing area and judge whether the current drawing area is a temporary drawing area; if the current drawing area is a temporary drawing area, judging whether handwriting exists in the current drawing area; if the current drawing area is a temporary drawing area and handwriting exists in the current drawing area, calculating a specific area corresponding to the cancel operation instruction, and redrawing the handwriting in the specific area; if the current drawing area is the temporary drawing area and no handwriting exists in the current drawing area, the scheme of sending a cancel operation instruction to the next drawing area realizes the quick cancel of the handwriting.
The embodiment of the invention also provides a storage medium which comprises a stored program, wherein when the program runs, the device where the storage medium is located is controlled to execute the handwriting canceling method of the writing application.
The embodiment of the invention also provides terminal equipment, which comprises one or more processors; a memory; and
one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the one or more processors, the programs comprising an undo method for executing the writing application of any of the above.
Drawings
Fig. 1 is a schematic flowchart of a handwriting undoing method for a writing application according to embodiment 1 of the present invention.
Fig. 2 is a flowchart illustrating a handwriting undoing method for a writing application according to embodiment 2 of the present invention.
Fig. 3 is a flowchart illustrating a handwriting undoing method for a writing application according to embodiment 3 of the present invention.
Fig. 4 is a schematic structural diagram of a handwriting undo apparatus for writing application according to embodiment 4 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 only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Referring to fig. 1, which is a schematic flow chart of a method for canceling handwriting for writing application according to embodiment 1 of the present invention, the method is applicable to n sequentially set drawing areas, where the first n-1 drawing areas of the n sequentially set drawing areas are temporary drawing areas, the nth drawing area is a permanent drawing area, and n is greater than or equal to 2; in the n sequentially set drawing areas, a first temporary drawing area is used for receiving the latest handwriting; in the N sequentially set drawing areas, starting from the second temporary drawing area, each temporary drawing area is used for transferring N pieces of handwriting to the next temporary drawing area and redrawing the N pieces of handwriting of the previous temporary drawing area, wherein N is more than or equal to 1; the method comprises the following steps of S101 to S104:
s101, responding to a cancel operation instruction of any drawing area, and judging whether the current drawing area is a temporary drawing area;
s102, if the current drawing area is a temporary drawing area, judging whether handwriting exists in the current drawing area;
s103, if the current drawing area is a temporary drawing area and handwriting exists in the current drawing area, calculating a specific area corresponding to the cancel operation instruction, and redrawing the handwriting in the specific area;
it should be noted that, in the field of computer drawing, each operation may be performed based on one handwriting, or may be performed based on one area, for example, deleting a certain handwriting, or deleting a handwriting in a certain area, and for example, moving a certain handwriting, or moving a handwriting in a certain area. The undo operation is to undo operations such as deletion and movement performed last time, and redraws the handwriting corresponding to the last operation or multiple handwriting in a specific area. In the embodiment of the invention, redrawing is performed on a plurality of handwriting in a specific area during the undo operation. In step S103, the size and position of the specific region corresponding to the latch operation command, i.e., the specific region for which the last operation was performed, are calculated.
And S104, if the current drawing area is the temporary drawing area and no handwriting exists in the current drawing area, sending a cancel operation instruction to the next drawing area.
Specifically, the step S104 specifically includes:
and if the current drawing area is any one temporary drawing area from 1 st to n-2 th of the n sequentially set drawing areas and no handwriting exists in the current drawing area, sending a cancel operation instruction to the next drawing area.
Preferably, if the current drawing area is an (n-1) th temporary drawing area of the n sequentially set drawing areas and no handwriting exists in the current drawing area, the cancelling operation instruction is not sent to the next drawing area.
The method for canceling the handwriting provided by the embodiment of the invention responds to the canceling operation instruction of any drawing area and judges whether the current drawing area is a temporary drawing area; if the current drawing area is a temporary drawing area, judging whether handwriting exists in the current drawing area; if the current drawing area is a temporary drawing area and handwriting exists in the current drawing area, calculating a specific area corresponding to the cancel operation instruction, and redrawing the handwriting in the specific area; if the current drawing area is the temporary drawing area and no handwriting exists in the current drawing area, the scheme of sending the cancel operation instruction to the next drawing area can effectively and quickly complete the cancel operation, and the system performance is improved.
For example, in an exemplary application scenario of the present scheme, after a user performs a deletion operation on handwriting in a specific area, the deletion operation is found to be an incorrect operation, and the handwriting in the specific area needs to be restored, at this time, the user needs to restore the handwriting by revocation, and then the system redraws all the deleted handwriting in the original specific area when executing a revocation instruction. The traditional drawing method is carried out on the same canvas, the handwriting execution operation is carried out on the handwriting drawn on the canvas, the operation cancellation is also carried out on the handwriting drawn on the canvas, and when the operation cancellation is carried out, all the handwriting in a specific area corresponding to the last operation needs to be redrawn. Therefore, when there are more handwriting in the specific area, redrawing the handwriting consumes more system resources and takes longer time. For example, the last deletion operation deletes a plurality of scripts in a specific area, and when the deletion operation is cancelled, all the scripts in the specific area need to be redrawn, which not only causes resource loss, but also slows down the system, and has the risk of jamming and halting. The method for canceling the handwriting provided by the embodiment utilizes the scheme that the temporary drawing area is arranged and the temporary drawing area is set with at most N pieces of handwriting, and cancels the N pieces of handwriting at most in one-time canceling operation, so that a plurality of pieces of handwriting cancelled in one time in the traditional scheme can be shared to different temporary drawing areas, the handwriting can be cancelled quickly, the canceling operation can be completed quickly and effectively, and the system performance is improved.
Referring to fig. 2, a flow chart of a method for canceling handwriting for writing application according to embodiment 2 of the present invention is schematically shown, where on the basis of embodiment 1, the method further includes steps S105 to S111:
s105, responding to the drawing operation instruction of the first drawing area, and judging whether the handwriting number of the first drawing area is equal to a preset threshold value N or not;
s106, when the number of the handwriting in the first drawing area is equal to the preset threshold value N, sending a drawing operation instruction to the next drawing area, transmitting the N handwriting in the first drawing area to the second drawing area, and simultaneously emptying the handwriting in the first drawing area;
s107, starting from the second drawing area, responding to a drawing operation instruction of any drawing area except the first drawing area, and judging whether the current drawing area is a temporary drawing area;
s108, if the current drawing area is a temporary drawing area, judging whether handwriting exists in the current drawing area;
s109, if the current drawing area is a temporary drawing area and no handwriting exists in the current drawing area, redrawing the handwriting of the previous drawing area in the current drawing area;
s110, if the current drawing area is a temporary drawing area and handwriting exists in the current drawing area, transferring the handwriting in the current drawing area to a next drawing area and emptying the current drawing area, redrawing the handwriting in the previous drawing area in the current drawing area, and sending a drawing operation instruction to the next drawing area;
and S111, if the current drawing area is the permanent drawing area, adding the handwriting transferred by the previous temporary drawing area in the current drawing area.
Preferably, the handwriting on the drawing area is stored by using a bitmap format file.
In the method for canceling handwriting provided by this embodiment, the N sequentially set drawing areas sequentially transfer the handwriting drawn by the user in the first drawing area from the first temporary drawing area to the bottom, so that the canceling operation is sequentially completed according to the order of drawing by the user when the system executes the canceling operation, and the scheme that the temporary drawing area is set and at most N handwriting are set in the temporary drawing area is used to quickly cancel the handwriting, thereby reducing the system performance consumption.
Referring to fig. 3, a flowchart of a method for canceling handwriting for a writing application according to embodiment 3 of the present invention is shown. The method is suitable for when n is 3, the n sequentially set drawing areas include a first temporary drawing area, a second temporary drawing area and a permanent drawing area, and specifically includes steps S201 to S210:
s201, responding to a cancel operation instruction of a first temporary drawing area, when detecting that handwriting exists in the first temporary drawing area, calculating a specific area corresponding to the cancel operation instruction on the first temporary drawing area, and redrawing the handwriting in the specific area of the handwriting corresponding to the cancel operation instruction on the first temporary drawing area;
it should be noted that, in the field of computer drawing, each operation may be performed based on one handwriting, or may be performed based on one area, for example, deleting a certain handwriting, or deleting a handwriting in a certain area, and for example, moving a certain handwriting, or moving a handwriting in a certain area. The undo operation is to undo operations such as deletion and movement performed last time, and redraws the handwriting corresponding to the last operation or multiple handwriting in a specific area. In the embodiment of the invention, redrawing is performed on a plurality of handwriting in a specific area during the undo operation. In step S201, the size and position of the specific region corresponding to the latch operation command, i.e., the specific region for which the last operation was performed, are calculated.
S202, when detecting that no handwriting exists in the first temporary drawing area, sending an undo operation instruction to the second temporary drawing area;
s203, responding to a cancel operation instruction of a second temporary drawing area, and judging whether handwriting exists in the second temporary drawing area;
and S204, when the second temporary drawing area is judged to have handwriting, calculating a specific area corresponding to the cancelling operation instruction on the second temporary drawing area, and redrawing the handwriting in the specific area corresponding to the cancelling operation instruction on the second temporary drawing area.
Preferably, if no handwriting exists in the second temporary drawing area, a cancel operation instruction is not sent to the permanent drawing area; or when no handwriting exists in the second temporary drawing area, sending an operation canceling instruction to the permanent drawing area, but not responding to the operation canceling instruction to the permanent drawing area.
Preferably, the method further comprises the step of:
s205, responding to a drawing operation instruction of the first temporary drawing area, and judging whether the handwriting number of the first temporary drawing area is equal to a preset threshold value N or not;
s206, when the number of the handwriting in the first temporary drawing area reaches a preset threshold value N, sending a drawing operation instruction to the second temporary drawing area, transmitting the handwriting in the first temporary drawing area to the second temporary drawing area, and simultaneously emptying the handwriting in the first temporary drawing area;
s207, responding to a drawing operation instruction of the second temporary drawing area, and judging whether handwriting exists in the second temporary drawing area;
s208, if no handwriting exists in the second temporary drawing area, redrawing the handwriting in the first temporary drawing area in the second temporary drawing area;
s209, if the second temporary drawing area has handwriting, transmitting the handwriting of the second temporary drawing area to the permanent drawing area, sending a drawing operation instruction to the permanent drawing area, simultaneously emptying the handwriting of the second temporary drawing area, and redrawing the handwriting of the first temporary drawing area on the second temporary drawing area;
and S210, responding to a drawing operation instruction of the persistent drawing area, and adding the handwriting transferred by the second temporary drawing area on the persistent drawing area.
In this embodiment, n drawing areas in embodiments 1 and 2 are further defined as including 3 drawing areas, and the method for canceling handwriting of a writing application provided in this embodiment is configured to, in response to a cancel operation instruction for a first temporary drawing area, calculate a specific area on the first temporary drawing area corresponding to the cancel operation instruction when detecting that there is handwriting in the first temporary drawing area, and redraw the handwriting in the specific area on the first temporary drawing area corresponding to the cancel operation instruction; when detecting that no handwriting exists in the first temporary drawing area, sending a cancel operation instruction to the second temporary drawing area; responding to a cancel operation instruction of a second temporary drawing area, and judging whether handwriting exists in the second temporary area; and when the second temporary drawing area is judged to have the handwriting, calculating a specific area corresponding to the cancelling operation instruction on the second temporary drawing area, and redrawing the handwriting in the specific area corresponding to the cancelling operation instruction on the second temporary drawing area.
For example, 3 screen-sized bitmap file drawing areas, respectively A, B, C, are first created. Wherein A, B is used as a temporary drawing area and C is used as a permanent drawing area. A user directly draws handwriting on the temporary drawing area A, after N pieces of handwriting exist on the temporary drawing area A, if N pieces of handwriting also exist on the temporary drawing area B, all the handwriting on the temporary drawing area B are drawn on the permanent drawing area C, the temporary drawing area B is emptied, the temporary drawing area A is drawn on the temporary drawing area B, and the temporary drawing area A is emptied; when a user executes a cancel operation, when detecting that handwriting exists on a temporary drawing area A, firstly calculating a specific area corresponding to the cancel operation, and redrawing the handwriting in the specific area on the temporary drawing area A; when no handwriting is detected in the temporary drawing area A, firstly calculating a specific area corresponding to the undo operation in the temporary drawing area B, and redrawing the handwriting in the specific area in the temporary drawing area B; further, when detecting that no handwriting exists in the temporary drawing area B, stopping the undo operation, and not redrawing any handwriting corresponding to the last operation. By arranging the temporary drawing area A and the temporary drawing area B, the number of handwriting required by redrawing can be reduced, and the system performance consumption is reduced.
Furthermore, the writing application in the above embodiments is preferably electronic whiteboard software provided on the interactive smart device. The interactive intelligent equipment comprises an intelligent tablet computer, an all-in-one computer and the like, and a user can directly perform operations such as drawing, deleting, marking and the like on a white board.
Referring to fig. 4, which is a schematic structural diagram of a handwriting cancellation device for writing application provided in embodiment 4 of the present invention, the handwriting cancellation device 100 for writing application is applicable to n sequentially set drawing areas, where the first n-1 drawing areas of the n sequentially set drawing areas are temporary drawing areas, the nth drawing area is a permanent drawing area, and n is greater than or equal to 2; in the n sequentially set drawing areas, a first temporary drawing area is used for receiving the latest handwriting; in the N sequentially set drawing areas, starting from the second temporary drawing area, each temporary drawing area is used for transferring N pieces of handwriting to the next temporary drawing area and redrawing the N pieces of handwriting of the previous temporary drawing area, wherein N is more than or equal to 1; the apparatus 100 comprises:
a first cancellation judgment module 101, configured to respond to a cancellation operation instruction for any drawing area, and judge whether a current drawing area is a temporary drawing area;
the second revocation judging module 102 is configured to, if the current drawing area is a temporary drawing area, judge whether handwriting exists in the current drawing area;
the first undo processing module 103 is configured to calculate a specific area corresponding to the undo operation instruction and redraw the handwriting in the specific area if the current drawing area is the temporary drawing area and the current drawing area has the handwriting;
and the second revocation processing module 104 is configured to send a revocation operation instruction to a next drawing area if the current drawing area is the temporary drawing area and no handwriting exists in the current drawing area.
The handwriting cancellation device 100 for writing applications, provided by the embodiment of the present invention, responds to an operation instruction for a drawing area through the first cancellation judgment module 101, and judges whether a current drawing area is a temporary drawing area; when the current drawing area is a temporary drawing area, the second revocation judgment module 102 judges whether handwriting exists in the current drawing area; when the current drawing area is a temporary drawing area and handwriting exists in the current drawing area, the first undo processing module 103 calculates a specific area corresponding to the undo operation instruction and redraws the handwriting in the specific area; when the current drawing area is a temporary drawing area and no handwriting exists in the current drawing area, the second revocation processing module 104 sends a scheme of a revocation operation instruction to the next drawing area to implement a scheme of quickly revoking the handwriting, so that the revocation operation can be effectively and quickly completed, and the system performance is improved.
Preferably, the apparatus further comprises:
the first drawing judgment module is used for responding to the drawing operation instruction of the first drawing area and judging whether the handwriting number of the first drawing area is equal to a preset threshold value N or not;
the first drawing processing module is used for sending a drawing operation instruction to the next drawing area when the number of the handwriting in the first drawing area is equal to the preset threshold value N, transmitting the N handwriting in the first drawing area to the second drawing area, and simultaneously emptying the handwriting in the first drawing area;
the second drawing judgment module is used for responding to a drawing operation instruction of any drawing area except the first drawing area from the second drawing area and judging whether the current drawing area is a temporary drawing area;
the third drawing judgment module is used for judging whether handwriting exists in the current drawing area if the current drawing area is the temporary drawing area;
the second drawing processing module is used for redrawing the handwriting of the previous drawing area in the current drawing area if the current drawing area is the temporary drawing area and the current drawing area has no handwriting;
the third drawing processing module is used for transferring the handwriting on the current drawing area to the next drawing area and emptying the current drawing area if the current drawing area is a temporary drawing area and the current drawing area has the handwriting, redrawing the handwriting of the previous drawing area in the current drawing area and sending a drawing operation instruction to the next drawing area;
and the fourth drawing processing module is used for adding the handwriting transferred by the previous temporary handwriting drawing area in the current drawing area if the current drawing area is the permanent drawing area.
In another embodiment, the n drawing areas are further defined as including 3 drawing areas, and the apparatus for canceling handwriting of a writing application provided in this embodiment specifically includes:
the first judging module is used for responding to a cancel operation instruction of a first temporary drawing area, when detecting that handwriting exists in the first temporary drawing area, calculating a specific area corresponding to the cancel operation instruction on the first temporary drawing area, and redrawing the handwriting in the specific area corresponding to the cancel operation instruction on the first temporary drawing area;
the second judgment module is used for sending a cancel operation instruction to the second temporary drawing area when detecting that no handwriting exists in the first temporary drawing area;
the third judging module is used for responding to a cancel operation instruction of the second temporary drawing area and judging whether handwriting exists in the second temporary drawing area;
and the first cancelling module is used for calculating a specific area corresponding to the cancelling operation instruction on the second temporary drawing area and redrawing the handwriting in the specific area corresponding to the cancelling operation instruction on the second temporary drawing area when the second temporary drawing area is judged to have the handwriting.
Preferably, the handwriting cancellation device of the writing application further comprises:
the first temporary judgment module is used for responding to a drawing operation instruction of the first temporary drawing area and judging whether the number of the handwriting in the first temporary drawing area is equal to a preset threshold value N or not;
the first temporary drawing module is used for sending a drawing operation instruction to the second temporary drawing area when the number of the handwriting in the first temporary drawing area reaches a preset threshold value N, transmitting the handwriting in the first temporary drawing area to the second temporary drawing area, and emptying the handwriting in the first temporary drawing area;
the second temporary judgment module is used for responding to a drawing operation instruction of the second temporary drawing area and judging whether handwriting exists in the second temporary drawing area;
the second temporary drawing module is used for redrawing the handwriting of the first temporary drawing area in the second temporary drawing area if the second temporary drawing area does not have the handwriting;
the third temporary drawing module is used for transmitting the handwriting in the second temporary drawing area to the permanent drawing area if the second temporary drawing area has the handwriting, sending a drawing operation instruction to the permanent drawing area, emptying the handwriting in the second temporary drawing area, and redrawing the handwriting in the first temporary drawing area in the second temporary drawing area;
a persistent rendering module to respond to the persistent rendering region
And drawing an operation instruction, and adding the handwriting transferred by the second temporary drawing area on the permanent drawing area.
Furthermore, the writing application in the above embodiments is preferably electronic whiteboard software provided on the interactive smart device. The interactive intelligent equipment comprises an intelligent tablet computer, an all-in-one computer and the like, and a user can directly perform operations such as drawing, deleting, marking and the like on a white board.
The device for canceling the handwriting of the writing application responds to a command for canceling the operation of a first temporary drawing area through a first judging module, when the first temporary drawing area is detected to have the handwriting, a specific area corresponding to the command for canceling the operation on the first temporary drawing area is calculated, and the handwriting in the specific area corresponding to the command for canceling the operation on the first temporary drawing area is redrawn; when detecting that no handwriting exists in the first temporary drawing area, the second judging module sends a cancel operation instruction to the second temporary drawing area; the third judging module responds to a cancel operation instruction of the second temporary drawing area and judges whether handwriting exists in the second temporary drawing area; and when judging that the second temporary drawing area has the handwriting, the first cancelling module calculates a specific area corresponding to the cancelling operation instruction on the second temporary drawing area and redraws the handwriting in the specific area corresponding to the cancelling operation instruction on the second temporary drawing area, and reduces the number of the handwriting required by redrawing, reduces the system performance consumption, realizes the fast cancelling operation and improves the system performance by utilizing the first temporary drawing area and the second temporary drawing area.
The storage medium is characterized by comprising a stored program, wherein when the program runs, a device where the storage medium is located is controlled to execute any one of the handwriting withdrawing methods of the writing application.
The embodiment of the invention also provides terminal equipment, which comprises one or more processors; a memory; and
one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the one or more processors, the programs comprising an undo method for executing the writing application of any of the above.
While the foregoing is directed to the preferred embodiment of the present invention, it will be understood by those skilled in the art that various changes and modifications may be made without departing from the spirit and scope of the invention.

Claims (11)

1. A handwriting canceling method for writing application is characterized by being applicable to n sequentially set drawing areas, wherein the first n-1 drawing areas of the n sequentially set drawing areas are temporary drawing areas, the nth drawing area is a permanent drawing area, and n is more than or equal to 2; in the n sequentially set drawing areas, a first temporary drawing area is used for receiving the latest handwriting; in the N sequentially set drawing areas, starting from the second temporary drawing area, each temporary drawing area is used for transferring N pieces of handwriting to the next temporary drawing area and redrawing the N pieces of handwriting of the previous temporary drawing area, wherein N is more than or equal to 1; the method comprises the following steps:
responding to a cancel operation instruction of any drawing area, and judging whether the current drawing area is a temporary drawing area;
if the current drawing area is a temporary drawing area, judging whether handwriting exists in the current drawing area;
if the current drawing area is a temporary drawing area and handwriting exists in the current drawing area, calculating a specific area corresponding to the cancel operation instruction, and redrawing the handwriting in the specific area;
and if the current drawing area is the temporary drawing area and no handwriting exists in the current drawing area, sending a cancel operation instruction to the next drawing area.
2. The method for canceling handwriting for writing application according to claim 1, wherein if the current drawing area is the temporary drawing area and no handwriting exists in the current drawing area, the issuing of the canceling operation instruction to the next drawing area specifically comprises:
and if the current drawing area is any one temporary drawing area from 1 st to n-2 th of the n sequentially set drawing areas and no handwriting exists in the current drawing area, sending a cancel operation instruction to the next drawing area.
3. A method of undoing handwriting for a writing application as recited in claim 1, said method further comprising the steps of:
responding to a drawing operation instruction of the first drawing area, and judging whether the handwriting number of the first drawing area is equal to a preset threshold value N;
when the number of the handwriting in the first drawing area is equal to the preset threshold value N, sending a drawing operation instruction to the next drawing area, transmitting the N handwriting in the first drawing area to the second drawing area, and simultaneously emptying the handwriting in the first drawing area;
starting from the second drawing area, responding to a drawing operation instruction of any drawing area except the first drawing area, and judging whether the current drawing area is a temporary drawing area;
if the current drawing area is a temporary drawing area, judging whether handwriting exists in the current drawing area;
if the current drawing area is the temporary drawing area and no handwriting exists in the current drawing area, redrawing the handwriting of the previous drawing area in the current drawing area;
if the current drawing area is a temporary drawing area and handwriting exists in the current drawing area, transferring the handwriting in the current drawing area to a next drawing area and emptying the current drawing area, redrawing the handwriting in the previous drawing area in the current drawing area, and sending a drawing operation instruction to the next drawing area;
and if the current drawing area is the permanent drawing area, adding the handwriting transferred by the previous temporary drawing area in the current drawing area.
4. The method for canceling handwriting for writing applications according to claim 1, wherein when n is 3, the n sequentially set drawing areas include a first temporary drawing area, a second temporary drawing area and a permanent drawing area, and the method specifically comprises the steps of:
responding to a cancel operation instruction of a first temporary drawing area, when detecting that handwriting exists in the first temporary drawing area, calculating a specific area corresponding to the cancel operation instruction on the first temporary drawing area, and redrawing the handwriting in the specific area corresponding to the cancel operation instruction on the first temporary drawing area;
when detecting that no handwriting exists in the first temporary drawing area, sending a cancel operation instruction to the second temporary drawing area;
responding to a cancel operation instruction of a second temporary drawing area, and judging whether handwriting exists in the second temporary area;
and when judging that the handwriting exists in the second temporary drawing area, calculating a specific area corresponding to the cancelling operation instruction on the second temporary drawing area, and redrawing the handwriting in the specific area corresponding to the cancelling operation instruction on the second temporary drawing area.
5. The method for canceling handwriting according to writing application of claim 1, wherein the writing application is electronic whiteboard software disposed on an interactive intelligent device.
6. A handwriting canceling device for writing application is characterized by being suitable for n sequentially set drawing areas, wherein the first n-1 drawing areas of the n sequentially set drawing areas are temporary drawing areas, the nth drawing area is a permanent drawing area, and n is more than or equal to 2; in the n sequentially set drawing areas, a first temporary drawing area is used for receiving the latest handwriting; in the N sequentially set drawing areas, starting from the second temporary drawing area, each temporary drawing area is used for transferring N pieces of handwriting to the next temporary drawing area and redrawing the N pieces of handwriting of the previous temporary drawing area, wherein N is more than or equal to 1; the device comprises:
the first revocation judgment module is used for responding to a revocation operation instruction of any drawing area and judging whether the current drawing area is a temporary drawing area;
the second revocation judging module is used for judging whether handwriting exists in the current drawing area if the current drawing area is the temporary drawing area;
the first revocation processing module is used for calculating a specific area corresponding to the revocation operation instruction and redrawing the handwriting in the specific area if the current drawing area is the temporary drawing area and the current drawing area has the handwriting;
and the second revocation processing module is used for sending a revocation operation instruction to the next drawing area if the current drawing area is the temporary drawing area and no handwriting exists in the current drawing area.
7. Apparatus for handwriting cancellation for writing applications according to claim 6, said apparatus further comprising:
the first drawing judgment module is used for responding to the drawing operation instruction of the first drawing area and judging whether the handwriting number of the first drawing area is equal to a preset threshold value N or not;
the first drawing processing module is used for sending a drawing operation instruction to the next drawing area when the number of the handwriting in the first drawing area is equal to the preset threshold value N, transmitting the N handwriting in the first drawing area to the second drawing area, and simultaneously emptying the handwriting in the first drawing area;
the second drawing judgment module is used for responding to a drawing operation instruction of any drawing area except the first drawing area from the second drawing area and judging whether the current drawing area is a temporary drawing area;
the third drawing judgment module is used for judging whether handwriting exists in the current drawing area if the current drawing area is the temporary drawing area;
the second drawing processing module is used for redrawing the handwriting of the previous drawing area in the current drawing area if the current drawing area is the temporary drawing area and the current drawing area has no handwriting;
the third drawing processing module is used for transferring the handwriting on the current drawing area to the next drawing area and emptying the current drawing area if the current drawing area is a temporary drawing area and the current drawing area has the handwriting, redrawing the handwriting of the previous drawing area in the current drawing area and sending a drawing operation instruction to the next drawing area;
and the fourth drawing processing module is used for adding the handwriting of the previous temporary handwriting drawing area in the current drawing area if the current drawing area is the permanent drawing area.
8. The apparatus for canceling handwriting according to claim 6, wherein when n is 3, said n sequentially set drawing areas include a first temporary drawing area, a second temporary drawing area and a permanent drawing area, said apparatus specifically comprising:
the first judging module is used for responding to a cancel operation instruction of a first temporary drawing area, when detecting that handwriting exists in the first temporary drawing area, calculating a specific area corresponding to the cancel operation instruction on the first temporary drawing area, and redrawing the handwriting in the specific area corresponding to the cancel operation instruction on the first temporary drawing area;
the second judgment module is used for sending a cancel operation instruction to the second temporary drawing area when detecting that no handwriting exists in the first temporary drawing area;
the third judging module is used for responding to a cancel operation instruction of the second temporary drawing area and judging whether handwriting exists in the second temporary drawing area;
and the first cancelling module is used for calculating a specific area corresponding to the cancelling operation instruction on the second temporary drawing area and redrawing the handwriting in the specific area corresponding to the cancelling operation instruction on the second temporary drawing area when the second temporary drawing area is judged to have the handwriting.
9. The apparatus for handwriting cancellation for a writing application according to claim 6, wherein said writing application is electronic whiteboard software disposed on an interactive smart device.
10. A storage medium comprising a stored program, wherein the program, when executed, controls a device on which the storage medium is located to perform a method of undoing handwriting for a writing application according to any of claims 1-5.
11. A terminal device comprising one or more processors; a memory; and
one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the one or more processors, the programs comprising an undo method for executing the writing application of any of claims 1-5.
CN201810254400.3A 2018-03-26 2018-03-26 Handwriting canceling method and device for writing application, storage medium and terminal device Active CN108491145B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810254400.3A CN108491145B (en) 2018-03-26 2018-03-26 Handwriting canceling method and device for writing application, storage medium and terminal device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810254400.3A CN108491145B (en) 2018-03-26 2018-03-26 Handwriting canceling method and device for writing application, storage medium and terminal device

Publications (2)

Publication Number Publication Date
CN108491145A CN108491145A (en) 2018-09-04
CN108491145B true CN108491145B (en) 2020-09-08

Family

ID=63337869

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810254400.3A Active CN108491145B (en) 2018-03-26 2018-03-26 Handwriting canceling method and device for writing application, storage medium and terminal device

Country Status (1)

Country Link
CN (1) CN108491145B (en)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109165626A (en) * 2018-09-11 2019-01-08 广州视源电子科技股份有限公司 Stroke writing processing method, device, equipment and the storage medium of electronic whiteboard
CN111046638B (en) * 2018-10-12 2022-06-28 北京金山办公软件股份有限公司 Ink mark removing method and device, electronic equipment and storage medium
CN111045580B (en) * 2018-10-15 2021-11-02 鸿合科技股份有限公司 Handwriting processing method and device and electronic equipment
CN110347318B (en) * 2019-06-27 2022-08-16 广州视睿电子科技有限公司 Handwriting drawing method, device, equipment and storage medium
CN111552410B (en) * 2020-05-13 2023-09-12 广州视源电子科技股份有限公司 Method, device, equipment and computer readable storage medium for processing writing trace
CN113093969A (en) * 2021-06-09 2021-07-09 北京易真学思教育科技有限公司 Hand-drawn track rendering method, device, electronic equipment, medium and program product

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2014071928A (en) * 2012-09-28 2014-04-21 Taiyo Yuden Co Ltd Optical recording device, optical recording method, and multilayer optical disk
CN104102465A (en) * 2014-07-09 2014-10-15 宁波摩视光电科技有限公司 Fast image displaying method based on high-precision large format scanner system
CN105630939A (en) * 2015-12-23 2016-06-01 深圳宸睿科技有限公司 General canvas input interface design method and device
CN106775429A (en) * 2017-03-08 2017-05-31 青岛海信电器股份有限公司 A kind of method and apparatus based on setting-out storage on touch-screen
CN106991711A (en) * 2017-03-15 2017-07-28 广州视源电子科技股份有限公司 Person's handwriting edit methods and system
CN107329689A (en) * 2017-06-27 2017-11-07 维沃移动通信有限公司 The backing method and mobile terminal of a kind of hand-writing input method

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2014071928A (en) * 2012-09-28 2014-04-21 Taiyo Yuden Co Ltd Optical recording device, optical recording method, and multilayer optical disk
CN104102465A (en) * 2014-07-09 2014-10-15 宁波摩视光电科技有限公司 Fast image displaying method based on high-precision large format scanner system
CN105630939A (en) * 2015-12-23 2016-06-01 深圳宸睿科技有限公司 General canvas input interface design method and device
CN106775429A (en) * 2017-03-08 2017-05-31 青岛海信电器股份有限公司 A kind of method and apparatus based on setting-out storage on touch-screen
CN106991711A (en) * 2017-03-15 2017-07-28 广州视源电子科技股份有限公司 Person's handwriting edit methods and system
CN107329689A (en) * 2017-06-27 2017-11-07 维沃移动通信有限公司 The backing method and mobile terminal of a kind of hand-writing input method

Also Published As

Publication number Publication date
CN108491145A (en) 2018-09-04

Similar Documents

Publication Publication Date Title
CN108491145B (en) Handwriting canceling method and device for writing application, storage medium and terminal device
EP3575962B1 (en) Method and device for preloading application, storage medium and intelligent terminal
US20200371656A1 (en) Icon Control Method and Terminal
CN109753179B (en) User operation instruction processing method and handwriting reading equipment
CN103777947B (en) The management method at the main interface of a kind of mobile terminal and device
CN103092604A (en) Application program classification method and device
CN100530111C (en) Multi-thread access indirect register scheduling method
CN111831182B (en) Application icon control method and device and electronic equipment
CN104536643A (en) Icon dragging method and terminal
CN104426944A (en) Method and device for information feedback, and terminal
CN106598926B (en) Operation revocation method and device
CN102799348A (en) Method and device for icon edition on terminal adopting touch screen
CN104063125A (en) Managing method and managing device for desktop icons
CN108153454B (en) Multi-touch switching method and device, storage medium and terminal equipment
CN112947829A (en) Misoperation processing method and device, electronic equipment and readable storage medium
WO2016173307A1 (en) Message copying method and device, and smart terminal
CN111580905A (en) Negative one-screen card management method, terminal and computer readable storage medium
CN105700827A (en) Android APP migration method and system
CN112416201B (en) Application cache cleaning method and device, electronic equipment and medium
CN108737655A (en) Image processing method and relevant apparatus
CN105389116A (en) Terminal application processing method and system for terminal device, and terminal device
CN101394405A (en) Method and apparatus for data request processing
CN108984024B (en) Touch operation method and device, storage medium and electronic equipment
CN110908552A (en) Multi-window operation control method, device, equipment and storage medium
CN103809794A (en) Information processing method and electronic device

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