Summary of the invention
In view of this, it is an object of the invention to propose a kind of method and apparatus utilizing gesture quick alignment object simply, efficiently.
Based on above-mentioned purpose a kind of method utilizing gesture quick alignment object provided by the invention, it is applied to the electronic whiteboard software inputted by touch apparatus, comprises the following steps:
Detect the some touch control operation of 3 to five that user inputs continuously;
When all described some touch control operations are all within default interval and distance interval, and all fall within first can on edit object time, enter alignment pattern;
Under described alignment pattern, when detect act on second can after the drag operation of edit object, obtaining after described drag operation terminates described second can the moving direction information of edit object;
According to described moving direction information, mobile described second can edit object can the justified margin of edit object with described first by it.
Preferably, further comprise the steps of: when drop on described first can all somes touch control operations on edit object all terminate time, exit described alignment pattern.
Preferably, under described alignment pattern, ignore all follow-up drop on described first can touch control operation on edit object.
Preferably, when entering described alignment pattern, further comprise the steps of: reduction and enter all touch control operation effects triggered in described alignment pattern process.
Preferably, entering after described alignment pattern, further comprising the steps of: and can do described first prominent effect and show by edit object, until exiting described alignment pattern.
Optionally, described prominent effect shows and includes: flicker, edge are highlighted, assertive colours covers or eject instruction frame.
Preferably, obtaining described second can the step of moving direction information of edit object include: gentle vertical component of being fetched water respectively by the line of the starting point of described drag operation Yu end point, determines that described second can the moving direction of edit object with higher value therein.
Preferably, further comprise the steps of: obtain in real time described second can the moving direction information of edit object, and according to described moving direction information, prominent effect can be done in real time show described first in the corresponding edge of edit object.
Present invention also offers a kind of device utilizing gesture quick alignment object, including:
First detection module, for detecting the some touch control operation of 3 to five that user inputs continuously;
Opening module, for when all described some touch control operations are all within default interval and distance interval, and all fall within first can on edit object time, enter alignment pattern;
Second detection module, under described alignment pattern, when detect act on second can after the drag operation of edit object, obtaining after described drag operation terminates described second can the moving direction information of edit object;
Perform module, for according to described moving direction information, mobile described second can edit object can the justified margin of edit object with described first by it.
Preferably, also include terminating module, for when drop on described first can all somes touch control operations on edit object all terminate time, exit described alignment pattern.
Preferably, described first detection module is additionally operable under described alignment pattern, ignore all follow-up drop on described first can touch control operation on edit object.
Preferably, described opening module is additionally operable to when entering described alignment pattern, further comprises the steps of: reduction and enters all touch control operation effects triggered in described alignment pattern process.
Preferably, also including the first reminding module, for entering after described alignment pattern, prominent effect can be done showing described first by edit object, until exiting described alignment pattern.
Optionally, described prominent effect shows and includes: flicker, edge are highlighted, assertive colours covers or eject instruction frame.
Preferably, described second detection module is further used for fetching water the line of the starting point of described drag operation Yu end point respectively gentle vertical component, determines that described second can the moving direction of edit object with higher value therein.
Preferably, also include the second reminding module, for obtain in real time described second can the moving direction information of edit object, and according to described moving direction information, prominent effect can be done in real time show described first in the corresponding edge of edit object.
From the above it can be seen that the method and apparatus utilizing gesture quick alignment object provided by the invention, by detect user drop on first can the some touch control operation of on edit object 3 to five, trigger and enter alignment pattern;Under alignment pattern, detect for second can the drag operation of edit object, according to second can the moving direction information of edit object, can edit object corresponding edge quick alignment with first by it.Compared to prior art, the present invention greatly simplify the operating procedure of align objects, and whole processing procedure simply, quickly, easily realize, improves the work efficiency of user significantly.
Detailed description of the invention
For making the object, technical solutions and advantages of the present invention clearly understand, below in conjunction with specific embodiment, and with reference to accompanying drawing, the present invention is described in more detail.
The method and apparatus utilizing gesture quick alignment object of the embodiment of the present invention, is applied to the electronic whiteboard software inputted by touch apparatus.The main users of described electronic whiteboard software is teacher, teacher can carry out the broadcasting demonstration of courseware development and electronic courseware by electronic whiteboard software, the embodiment of the present invention is applied to above-mentioned courseware development process, teacher by electronic courseware edit page insert, edit various can edit object to generate electronic courseware.
Described electronic whiteboard software support touch apparatus input, is usually the touch screen of electronic whiteboard or handheld terminal;And support some conventional gesture input operations, as: some touch-control dragging object, the rotation of 2 touch-controls, scale objects, sliding trace shows etc..
With reference to Fig. 1, for the method flow diagram utilizing gesture quick alignment object of the embodiment of the present invention.
The method utilizing gesture quick alignment object of the present embodiment comprises the following steps:
Step 101: detect the some touch control operation of 3 to five that user inputs continuously;
Step 102: when all described some touch control operations are all within default interval and distance interval, and all fall within first can on edit object time, enter alignment pattern;
Step 103: under described alignment pattern, when detect act on second can after the drag operation of edit object, obtaining after described drag operation terminates described second can the moving direction information of edit object;
Step 104: according to described moving direction information, mobile described second can edit object can the justified margin of edit object with described first by it.
In step 101, the some touch control operation of detection user, testing conditions is: input and quantity are three to five continuously, three, four or five touch points dropping on touch screen that namely detection user inputs continuously.For some touch-control operation amount lower limit, the i.e. setting of three, it is that the rotation of 2 touch-controls, scale objects equiphase zone are separately, it is to avoid the conflict of detection, reduce the amount of calculation that detection processes in order to put touch-control dragging object described above with some conventional touch control operations.For some the touch-control operation amount upper limit, the i.e. setting of five, being based on the operating habit of human body, the touch control operation for same target is generally completed by one hand, it is to avoid bimanualness, simplifies operating process.
In step 102, point touch control operation for detect in step 101 3 to five does further judgement, judge whether the some touch control operation of above-mentioned three to five has fully fallen in electronic whiteboard software on edit page same can on edit object, namely first can edit object;And whether interval between any two continuous print point touch control operation and distance interval be all in default scope.For interval, in the present embodiment, the interval preset is 0-20 millisecond, and namely for any two continuous print point touch control operation, it drops on the time difference on touch screen less than 20 milliseconds;Considering that a touch-control operating gesture is by one man operation, has been tapped by fingers of single hand for user, be the coherent action of a comparison, multiple fingers pin same object, and several fingers can fully fall on touch screen in very short time.For distance interval, in the present embodiment, the distance preset is spaced apart 0-20 pixel, namely drops on the difference of distance between the point on touch screen less than 20 pixels for any two continuous print point touch control operation;Considering that a touch-control operating gesture is by one man operation, has been tapped by fingers of single hand for user, several fingers drop on the point on touch screen and can compare and concentrate within the scope of one.That namely all somes touch control operations are all within default interval and distance interval when two above-mentioned result of determination are, and all fall within first can on edit object time, then enter alignment pattern.
In step 103, under alignment pattern, first can be continued to choose by edit object, and it is fixed on selected position and will not be moved.Then so detect whether to act on second can the drag operation of edit object, described second can edit object be that in electronic whiteboard software, another on edit page can edit object.When detect act on second can after the drag operation of edit object, continue to monitor this drag operation, and obtain the moving direction of its initial position relative when it terminates, and namely determine through pulling, second can be moved to the upper and lower, left of initial position or right by edit object.
In step 104, according to step 103 obtains second can the moving direction information of edit object, mobile second can edit object, one edge can the respective edges of edit object be alignd with first.Such as, the drag operation in step 103 completes and can drag second to the left by edit object, then after drag operation terminates, continue to move to second can edit object, its left hand edge can the left hand edge of edit object be alignd with first.For can edit object edge, in electronic whiteboard software, can have the operation box of a regular shape by edit object, be usually rectangle, described can the four edges of edit object edge namely this rectangular operation frame.
Under alignment pattern, second after the alignment of edit object completes, can may proceed to the drag operation of detection user, when again detecting, will redefine second can edit object, and continue follow-up step, it is achieved multiple can the alignment procedure of edit object.
In the present embodiment, for 3 some touch control operations, the process of the whole operation of user is: touch touch screens by three fingers, and 3 fully fall in electronic whiteboard software on edit page first on edit object, can now enter alignment pattern.User continues through touch control operation and pulls second and can be moved to the left by edit object, after pulling end, continuation can be moved by edit object by second, and its left hand edge will automatically can the left hand edge of edit object align with first, first can edit object and second can edit object proper alignment in the way of flush left.
Visible, by the method for the present embodiment, alignment pattern is triggered by a touch control operation, it is similar to " choosing " destination object, and then continue to pull another object to a direction, according to drag direction, the respective edges of two objects is alignd, by above-mentioned simple operations, it is possible to quickly realize the proper alignment effect of multiple object.
With reference to Fig. 2, for the method flow diagram utilizing gesture quick alignment object of another embodiment of the present invention.
As another embodiment, the described method utilizing gesture quick alignment object, comprise the following steps:
Step 201: detect the some touch control operation of 3 to five that user inputs continuously.
Step 202: when all described some touch control operations are all within default interval and distance interval, and all fall within first can on edit object time, enter alignment pattern.
Step 203: reduction enters all touch control operation effects triggered in described alignment pattern process.
When entering alignment pattern, point touch control operation can successively drop on touch screen, simultaneously because finger falls the small movement that can occur on touch screen to be not easily easily noticed by the users, therefore in the process that multiple somes touch control operations successively fall, the several somes touch control operations first fallen are likely to be identified as other conventional gesture touch control operation.Such as, when first some touch control operation falls and minute movement occurs, sliding trace display gesture can be identified as, a bit of track can occur in edit object first;Second some touch control operation falls and during relative to first some touch control operation generation minute movement, can be identified as convergent-divergent gesture, first can edit object can be scaled.In order to avoid above-mentioned problem, in this step, all touch control operation effects reduction triggered in alignment pattern process can be entered, be about to mobile, zooming effect described above and all cancel.
Simultaneously, in order to further avoid in entering alignment pattern process, maloperation can be there is on edit object in user first, in the present embodiment, under alignment pattern, ignore all follow-up drop on described first can touch control operation on edit object, to ensure that first can be fixed on selected position and will not be moved and change by edit object.
Step 204: entering after described alignment pattern, can do described first prominent effect and shows by edit object, until exiting described alignment pattern.
Under alignment pattern, first can edit object selected for alignment target, its position and state will not be changed, therefore in this step, entering after alignment pattern, prominent effect can done showing first by edit object, in order to point out user currently to come into alignment pattern.Concrete, described prominent effect shows and includes: by first can edit object do that overall flicker, edge be highlighted, assertive colours cover or eject instruction frame point to first can edit object etc., make its with other can have obvious difference by edit object, with reach prompting effect.
Step 205: under described alignment pattern, when detect act on second can after the drag operation of edit object, obtaining after described drag operation terminates described second can the moving direction information of edit object.
In this step, obtain second can the process of moving direction information of edit object particularly as follows: will act on second and can the starting point of drag operation and the line of end point of edit object fetch water respectively gentle vertical component, determine that described second can the moving direction of edit object with higher value therein.User can the drag operation of edit object will not be generally strict be in horizontally and vertically on direction for second, therefore need further to judge that this drag operation is more likely to that direction, by doing upright projection in the horizontal and vertical directions, take corresponding component, and take the greater therein, namely can determine that the direction of this drag operation is inclined to.Such as, drag operation can pull second to upper left side by edit object, and more to the left, and the component in its horizontal direction will be greater than vertical component, then judge this drag operation pull second can the result of edit object as to the left.
Step 206: obtain in real time described second can the moving direction information of edit object, and according to described moving direction information, prominent effect can be done in real time show described first in the corresponding edge of edit object.
In this step, judge based on the moving direction information in step 205, obtaining second in real time can the moving direction information of edit object, and can the result of determination of moving direction of edit object according to second, prominent effect can be done show first in the corresponding edge of edit object in real time, if for pointing out user to terminate drag operation with current drag direction, second will can be aligned to first can which bar edge of edit object by edit object.
Such as, current drag operation drags second and can be moved to the left by edit object, now first can the left hand edge of edit object show with prominent effect, this drag operation and then turn to moves over, first can the top edge of edit object show with prominent effect so in real time, and left hand edge no longer shows with prominent effect.
Described in this step first the prominent effect at edit object edge can show can be that flicker, highlighted, assertive colours show or indicatrix etc., should be noted that, in the present embodiment, first can show also by prominent effect in order to point out user to be currently at alignment pattern by edit object, the prominent effect of above-mentioned two shows and should differ, to ensure to realize respective prompting effect.
Step 207: according to described moving direction information, mobile described second can edit object can the justified margin of edit object with described first by it.
Step 208: when drop on described first can all somes touch control operations on edit object all terminate time, exit described alignment pattern.
In this step, shake due to the shake of user's finger or touch-screen equipment, it is likely to cause a touch control operation to terminate, therefore in order to avoid above-mentioned maloperation, the decision condition exiting alignment pattern is set as: dropping on first in step 201 can all terminate by all somes touch control operations on edit object.When follow-up again having drop on first can some touch control operation on edit object time, ignored.
The embodiment of the present invention additionally provides a kind of device utilizing gesture quick alignment object, with reference to Fig. 3, for the apparatus structure schematic diagram utilizing gesture quick alignment object of the embodiment of the present invention.
The described device utilizing gesture quick alignment object includes:
First detection module 301, for detecting the some touch control operation of 3 to five that user inputs continuously;
Opening module 302, for when all described some touch control operations are all within default interval and distance interval, and all fall within first can on edit object time, enter alignment pattern;
Second detection module 303, for entering after described alignment pattern, when detect act on second can after the drag operation of edit object, obtaining after described drag operation terminates described second can the moving direction information of edit object;
Perform module 304, for according to described moving direction information, mobile described second can edit object can the justified margin of edit object with described first by it.
In the present embodiment, described device also includes: terminate module 305, for when drop on described first can all somes touch control operations on edit object all terminate time, exit described alignment pattern.
Wherein, described first detection module 301 is additionally operable under described alignment pattern, ignore all follow-up drop on described first can touch control operation on edit object.
Described opening module 302 is additionally operable to when entering described alignment pattern, and reduction enters all touch control operation effects triggered in described alignment pattern process.
Further, described device also includes: the first reminding module 306, for entering after described alignment pattern, can do described first prominent effect and show by edit object, until exiting described alignment pattern.Concrete, described prominent effect shows and includes: glimmer, edge is highlighted, assertive colours covers or ejects instruction frame.
In the present embodiment, described second detection module 303 is further used for fetching water the line of the starting point of described drag operation Yu end point respectively gentle vertical component, determines that described second can the moving direction of edit object with higher value therein.
Further, the device of the present embodiment also includes the second reminding module 307, for obtain in real time described second can the moving direction information of edit object, and according to described moving direction information, prominent effect can be done in real time show described first in the corresponding edge of edit object.
Those of ordinary skill in the field are it is understood that the foregoing is only specific embodiments of the invention; it is not limited to the present invention; all within the spirit and principles in the present invention, any amendment of making, equivalent replacement, improvement etc., should be included within protection scope of the present invention.