CN103809954B - Method and device for realizing interface element selection - Google Patents
Method and device for realizing interface element selection Download PDFInfo
- Publication number
- CN103809954B CN103809954B CN201210457676.4A CN201210457676A CN103809954B CN 103809954 B CN103809954 B CN 103809954B CN 201210457676 A CN201210457676 A CN 201210457676A CN 103809954 B CN103809954 B CN 103809954B
- Authority
- CN
- China
- Prior art keywords
- line segment
- interface element
- motion track
- terminal
- segment
- 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
Links
Landscapes
- User Interface Of Digital Computer (AREA)
- Position Input By Displaying (AREA)
Abstract
The invention provides a method and a device for realizing interface element selection. The method comprises the steps of obtaining moving operation in an interface, and recording the moving locus corresponding to the moving operation; judging whether the region determined by the moving locus is a closed region, and if so, selecting interface elements in the closed region. The system comprises a moving processing module and an availability judgment module, wherein the moving processing module is used for obtaining the moving operation in the interface and recording the locus corresponding to the moving operation; the availability judgment module is used for judging whether the region determined by the moving locus is the closed region, if so, a closed region processing module is informed; the closed region processing module is used for selecting the interface elements in the closed region. According to the method and the device for realizing the interface element selection, the operation is simplified.
Description
Technical field
The present invention relates to computer interaction technique, more particularly to a kind of method and apparatus for realizing that interface element is selected.
Background technology
Terminal unit is generally provided with several interface elements to the interactive interface that user shows, the interface element is generally
By clicking on to interface element or growing by operation, the form of multiselect frame or icon, user realize that interface element is selected, make
Obtain corresponding interface element and be in selected state.
For example, in interactive interface of the interface element for multiselect frame, user is realized by clicking the content in multiselect frame
Interface element select.But, the selected mode of this interface element is only applicable to the less situation of option, if desired selects
A large amount of interface elements, user have to click on multiselect frame one by one, need to be selected when there is dozens or even hundreds of multiselect frame
Regularly, the single-click operation quantity of required input will be very huge, operate very loaded down with trivial details.
The content of the invention
Based on this, it is necessary to carry out selecting the very loaded down with trivial details problem of operation for a large amount of interface elements, there is provided a kind of energy letter
Change the method for realizing that interface element is selected of operation.
Additionally, there is a need to providing a kind of device for realizing that interface element is selected that can simplify operation.
A kind of method for realizing that interface element is selected, comprises the steps:
The moving operation in interface is obtained, and records the corresponding motion track of the moving operation;
Judge whether region determined by the motion track is enclosed region, if so, then
Interface element in enclosed region is chosen.
A kind of device for realizing that interface element is selected, it is characterised in that include:
Mobile processing module, for obtaining the moving operation in interface, and records the corresponding track of the moving operation;
Availability deciding module, for judging whether region determined by the motion track is enclosed region, if so, then
Notify enclosed region processing module;
The enclosed region processing module is for the interface element in enclosed region is chosen.
The above-mentioned method and apparatus for realizing that interface element is selected, obtains the moving operation that user is input in interface, according to
Enclosed region determined by moving operation obtains the interface element in positioned at enclosed region, these interface elements is chosen, at this
During the selecting of one interface element, user only needs on interface arbitrarily input moving operation and is capable of achieving a large amount of interface elements
Select, significantly simplify operation, improve carries out selected speed to interface element.
Description of the drawings
Flow charts of the Fig. 1 for realizing the selected method of interface element in one embodiment;
Fig. 2 is for obtaining the moving operation in interface in one embodiment, and records the corresponding motion track of moving operation
Method flow diagram;
Fig. 3 is to obtain the moving operation in interface in another embodiment, and records the corresponding motion track of moving operation
Method flow diagram;
Fig. 4 be one embodiment in the interface element in enclosed region is chosen;
Fig. 5 is to choose the interface element in enclosed region in another embodiment;
Fig. 6 selected for realizing interface element in one embodiment application schematic diagram;
Fig. 7 is to realize application schematic diagram that interface element is selected in another embodiment;
Fig. 8 be one embodiment in realize interface element select device structural representation;
Fig. 9 is the structural representation of availability deciding module in one embodiment;
Figure 10 is the structural representation of availability deciding module in another embodiment;
Figure 11 is the structural representation of enclosed region processing module in one embodiment;
Figure 12 is the structural representation of enclosed region processing module in another embodiment;
Figure 13 is the structural representation of enclosed region processing module in another embodiment;
Figure 14 is the structural representation of enclosed region processing module in another embodiment.
Specific embodiment
As shown in figure 1, in one embodiment, a kind of method for realizing that interface element is selected, comprises the steps:
Step S110, obtains the moving operation in interface, and records the corresponding motion track of moving operation.
In the present embodiment, the operation interface that interface is provided a user with for terminal unit wherein, includes several on interface
Interface element, the interface element are the graphic element in operation interface.Moving operation in interface is that user passes through touch screen, Mus
Mark or the input of the input equipment such as touch pad, the pressing in interface, mobile and lift this series of actions and formed by user.
For example, moving operation is that user arbitrarily draws next lines in interface.
After moving operation is triggered in interface, the track of record user's moving operation is obtained into motion track, and is led to
Cross the form record of coordinate.Specifically, in the coordinate system that interface is located, as the moving operation triggered in interface is with the shape of coordinate
Formula is recorded, and the coordinate of multiple records defines the corresponding motion track of moving operation.For example, the coordinate of record is interface institute
Coordinate system in x and y-axis coordinate, n represents at n-th point,(X1, y1)...,(Xn, yn)Constitute motion track.
During the track of record moving operation, also the track corresponding to moving operation will be shown in interface, with
To the moving operation of user feedback input.
Step S130, judges whether region determined by motion track is enclosed region, if so, then enters step S150,
If it is not, then terminating.
In the present embodiment, motion track can be the track, or semi-open track of closure, to facilitate user to grasp
Make.Enclosed region be with the motion track of user as boundary line in interface determined by region, be can by motion track come
Determine its concrete scope, the enclosed region formed in interface can be one or more, and multiple enclosed regions are users
Obtained by carrying out multiple moving operation.If it is enclosed region to determine region determined by motion track, illustrate that user is led to
Cross moving operation to interface element it is selected be it is effective, if determine motion track determination region be open, illustrate
The moving operation of user is invalid operation.
As shown in Fig. 2 in one embodiment, the detailed process of above-mentioned steps S130 is:
Step S131, arranges any one line segment in the line segment of composition motion track for initial segment, and with start line
Terminal of the arbitrary end points in section as initial segment.
In the present embodiment, the motion track corresponding to moving operation is made up of some line segments, in composition moving rail
Using any one line segment as initial segment in the line segment of mark, and any one end points work is chosen from two end points of initial segment
For the terminal of initial segment, accordingly, the starting point then for initial segment of another end points in initial segment.
Step S133, with terminal as starting in the line segment of motion track, judge the line segment that do not intersect with terminal whether with
Initial segment intersects, and if so, then enters step S150, if it is not, then terminating.
In the present embodiment, in several line segments of composition motion track, the terminal with initial segment is judged not as starting
Whether the line segment intersected with terminal is intersected in starting point with initial segment, if so, then illustrates region determined by motion track
It is enclosed region, if it is not, region determined by then illustrating motion track is open.The line segment not intersected with terminal is moving rail
Other line segments in addition to the adjacent segments being connected with initial segment except initial segment and by terminal in the line segment of mark.This
It is corresponding with initial segment termination line segment in motion track not intersect the line segment for but intersecting with initial segment with terminal.
As shown in figure 3, in another embodiment, above-mentioned steps S130 also include:
Step S135, when determining the line segment and non-intersect initial segment that do not intersect with terminal, rising according to initial segment
Beginning direction obtains the corresponding terminal of line segment not intersected with terminal, and between calculated terminal and the starting point of initial segment
Distance.
In the present embodiment, prime direction is the starting point direction to terminal in motion track by initial segment, along rising
Beginning direction can obtain the terminal corresponding to the line segment that do not intersect with terminal, so according to Pythagorean theorem be calculated not with terminal
The distance between starting point of terminal and initial segment corresponding to intersecting line segment.
Step S 136, judges that the distance, whether less than threshold value, if so, then enters step S137, if it is not, then terminating.
In the present embodiment, motion track can be semi-open track, if it is in threshold to determine calculated distance
Within the scope of value, then illustrate that the moving operation of user is effectively operation, motion track can determine enclosed region, if determining
Calculated distance is that outside threshold range, then the curve two ends corresponding to explanation motion track is distant,
The enclosed region of a determination cannot be formed, therefore, the moving operation is input into by user is invalid operation.
Whether motion track is near to be judged to the initial segment in motion track and the corresponding line segment that terminates by given threshold
Like closure, and then cause the moving operation of the motion track for forming approximate closure also be judged as effective operation, improve use
The ease for use and convenience of family operation so that user need not carry out precise manipulation and be capable of achieving selecting for interface element.
Step S137, is obtained determined by motion track by the line between the terminal that obtains and the starting point of initial segment
Enclosed region.
In the present embodiment, in semi-open motion track, by the terminal corresponding to the line segment that do not intersect with terminal and
Line between the starting point of initial segment can determine enclosed region.Wherein, the terminal corresponding to line segment not intersected with terminal
The line and starting point of initial segment between can be the terminal and initial segment that the line segment not intersected with terminal is located
Starting point is joined directly together extended line and the initial segment place at resulting line segment, or the line segment place do not intersected with terminal
Extended line be connected the line segment for obtaining.
Step S150, the interface element in enclosed region is chosen.
In the present embodiment, the region for being judged as enclosed region in interface makes a look up and obtains in enclosed region
Interface element, searches the interface element that obtains for one or more, the boundary that will be transformed to choose by unchecked interface element
Surface element.
As shown in figure 4, in one embodiment, the detailed process of above-mentioned steps S150 is:
Step S151, carries out extending the ray for obtaining interface element with interface element as starting point one by one.
In the present embodiment, several interface elements in interface, are contained, each interface element in interface enters line position
Judgement is put, during knowing that whether the interface element is located in enclosed region, will be starting point to certain orientation with interface element one by one
Extend to obtain corresponding ray.In a preferred embodiment, the bearing of trend for interface x-axis in a coordinate system losing side
To.
Step S153, obtains the intersection point sum between the line segment of the ray and composition motion track, and judges intersection point sum
Whether it is odd number, if so, then enters step S155, if it is not, then terminating.
In the present embodiment, if interface element is located in enclosed region determined by motion track, the interface element institute is right
Number of intersections that the line segment of the ray answered and motion track is formed necessarily odd number, if interface element is located at motion track institute
It is determined that enclosed region outside, then the number of intersections formed by the line segment of the ray corresponding to the interface element and motion track must
It is so even number.
Accordingly, after the intersection point sum between the line segment of the ray and composition motion track that get interface element,
If it is odd number to determine intersection point sum, illustrate that interface element is, in enclosed region determined by motion track, to be
The interface element that user selectes, therefore, it is marked as selected state.If it is even number to determine intersection point sum, this is illustrated
Interface element is that, outside enclosed region determined by motion track, therefore the interface element is not the boundary that user selectes
Surface element, it is not necessary to do any process to which.
Step S155, ray corresponding interface element is chosen.
In the present embodiment, the number of intersections between the line segment for determining ray and composition motion track is odd number, then say
Bright this interface element is the enclosed region in interface, and interface element is transformed to choose by unselected.
In another embodiment, the above-mentioned method for realizing that interface element is selected also includes:By the interface element for obtaining
After choosing, the step of selected interface element is labeled as selected state.
In the present embodiment, the interface element to choosing is marked, in order to receive and respond the further of user input
Operation.
As shown in figure 5, in another embodiment, also include before above-mentioned steps S153:
Step S201, judges whether the line segment for constituting motion track is parallel with ray, if so, then enters step S203, if
It is no, then into step S153.
In the present embodiment, by the line segment quantitative determination of the ray of the interface element and composition motion track interface element
When whether being the interface element that user selectes, some specific scenes are also there are, therefore, pay the utmost attention to the special scenes for existing
Can quickly judge interface element or remove interference factor that whether interface element is selected as user, so improve treatment effeciency and
Accuracy.
Specifically, special scenes are that the corresponding ray of interface element is in parallel shape with the line segment of composition motion track
State, now, if the ray and between the line segment that the ray is parallel to each other be it is Chong Die, the ray and with the ray phase
Mutually the number of intersections between parallel line segment would is that countless;If the ray and between the coequal line segment of the ray
It is nonoverlapping, then no intersection point, therefore, antinode quantity is will be unable under this special scenes determines specific numerical value, because
This, it is necessary to ignore the line segment parallel with the ray, be to calculate the number of intersections between this line segment parallel with the ray and ray,
The accuracy selected to ensure interface element.
Step S203, ignores the line segment parallel with the ray.
In another embodiment, also include before above-mentioned steps S153:
Judge whether interface element region has common factor with the line segment for constituting motion track, if so, then enter step
S155, if it is not, then enter step S153.
In the present embodiment, special scenes are that interface element is located on motion track.If a certain interface element is located at composition and moves
On a certain line segment of dynamic rail mark, then directly judge that the interface element is within enclosed region determined by motion track
, now the interface element is the interface element that user selectes.
If interface element is not located at constituting on a certain line segment of motion track, need to obtain the interface element pair
Intersection point sum between the ray answered and the line segment of composition motion track, and then continue to judge whether the interface element is located at movement
In enclosed region determined by track.
Specifically, judgment formula can be passed through(y1-y0)*(x2-x0)-(y2-y0)*(x1-x0)Whether sentence into Rob Roy==0
Delimit whether surface element is located on motion track, that what is set up when above-mentioned formula is determined then determines whether whether x0 and y0 is equal
Between x1 and x2 and y1 and y2, a certain line segment of interface element region and composition motion track is if so, then judged
There is common factor, wherein,(Xi, y1)With(X2, y2)The coordinate of end points P1 and end points P2 in the line segment of motion track is constituted respectively,
(X0, y0)The coordinate of interface element p, the coordinate of interface element can be set as the seat corresponding to the center of interface element
Mark.
In another embodiment, also include before above-mentioned steps S153:
Judge whether the ray passes through the end points of line segment, if so, then ignore arbitrary line segment at end points place, if it is not, then entering
Enter step S153.
In the present embodiment, special scenes are situation of the ray through some end of line segment.Specifically, it is being connected with each other
Between two lines section be by end points connect, therefore the ray of interface element pass through line segment end points when, the ray will be with two
There is intersection point in line segment, but in practice for being only one of which intersection point for whole motion track, therefore, should ignore wherein
One line segment, to ensure the accuracy of number of intersections.
The above-mentioned method for realizing that interface element is selected is elaborated with reference to a specific embodiment.The embodiment
In, as shown in fig. 6, nine interface elements such as interface element A to interface element I in interface element, are provided with, by user to appointing
One interface element it is selected triggering corresponding function.Moving operation by user in interface defines what is shown in interface
Curve 601, the motion track that the curve 601 is as recorded.Judge to obtain determined by the curve 601 after curve 601 is obtained
Region is an enclosed region, now, lookup is obtained interface element A, interface element B and interface element C positioned at enclosed region
In, therefore, these three interface elements are the selected interface element of user, by interface element A, interface element B and Interface Element
Plain C flag is selected state.
Furthermore it is also possible to realize selecting for interface element by the multiple moving operation of user.Specifically, such as Fig. 7 institutes
Show, user in addition to the curve 601 obtained by moving operation first also have input moving operation twice and obtain 701 He of curve
Curve 703, and then determine multiple enclosed regions, now search still according to said method and obtain the interface in enclosed region
Elements A, interface element B, interface element C, interface element D and interface element E, and then the interface element labelling that lookup is obtained
For selected state.
In the above-mentioned method for realizing that interface element is selected, in interface of the interface element for icon, pass through keyboard with user
In button and single-click operation be implemented in combination with icon select or by press mouse and drag realize icon select
Both traditional approachs compare, and realize that by moving operation the selected of interface element is easier to apply with touch screen as defeated
Enter in the terminal unit of equipment, it is not necessary to which external connection keyboard or mouse can easily carry out interface element and select.
Additionally, during for carrying out one by one selecting to interface element by keyboard or mouse, often occur due to
Some maloperation and cause the selected situation about being abandoned of multiple elements, and pass through the interface element choosing realized by moving operation
It is fixed to efficiently avoid the generation of this case.
As shown in figure 8, in one embodiment, a kind of device for realizing that interface element is selected, including mobile processing module
110th, availability deciding module 130 and enclosed region processing module 150.
Mobile processing module 110, for obtaining the moving operation in interface, and records the corresponding track of moving operation.
In the present embodiment, the operation interface that interface is provided a user with for terminal unit wherein, includes several on interface
Interface element, the interface element are the graphic element in operation interface.Moving operation in interface is that user passes through touch screen, Mus
Mark or the input of the input equipment such as touch pad, the pressing in interface, mobile and lift this series of actions and formed by user.
For example, moving operation is that user arbitrarily draws next lines in interface.
After moving operation is triggered in interface, the track for recording user's moving operation is obtained by mobile processing module 110
To motion track, and recorded by the form of coordinate.Specifically, in the coordinate system that interface is located, mobile processing module 110 with
The moving operation triggered in interface is recorded in the form of coordinate, and the coordinate of multiple records defines the corresponding shifting of moving operation
Dynamic rail mark.For example, the coordinate of x and y-axis in the coordinate system that the coordinate of record is located for interface, n represent at n-th point,(X1,
y1)...,(Xn, yn)Constitute motion track.
During the track of record moving operation, mobile processing module 110 will also show moving operation in interface
Corresponding track, with the moving operation being input into user feedback.
Availability deciding module 130, for judging whether region determined by motion track is enclosed region, if so, then
Enclosed region processing module 150 is notified, if it is not, then stopping performing.
In the present embodiment, motion track can be the track, or semi-open track of closure, to facilitate user to grasp
Make.Enclosed region be with the motion track of user as boundary line in interface determined by region, be can by motion track come
Determine its concrete scope, the enclosed region formed in interface can be one or more, and multiple enclosed regions are users
Obtained by carrying out multiple moving operation.If the region that availability deciding module 130 determines motion track determination is closed area
Domain, then illustrate user by moving operation to interface element it is selected be it is effective, if determine motion track determination region
It is open, then illustrates that the moving operation of user is invalid operation.
As shown in figure 9, in one embodiment, above-mentioned availability deciding module 130 includes setting unit 131 and intersects
Judging unit 133.
Setting unit 131, is initial segment for any one line segment of equipment in the line segment of composition motion track, and with
Terminal of the arbitrary end points in initial segment as initial segment.
In the present embodiment, the motion track corresponding to moving operation is made up of some line segments, in composition moving rail
Using any one line segment as initial segment in the line segment of mark, and any one end points work is chosen from two end points of initial segment
For the terminal of initial segment, accordingly, the starting point then for initial segment of another end points in initial segment.
Intersecting judging unit 133, judges what is do not intersected with terminal in the line segment of motion track with terminal as starting
Whether line segment is intersected with initial segment, if so, then notifies closure processing module 150, if it is not, then stopping performing.
In the present embodiment, in several line segments of composition motion track, the terminal with initial segment is as starting, intersecting to sentence
Disconnected unit 133 judges whether the line segment not intersected with terminal is intersected in starting point with initial segment, if so, then illustrates moving rail
Region determined by mark is enclosed region, if it is not, region determined by then illustrating motion track is open.Do not intersect with terminal
Line segment be motion track line segment in addition to the adjacent segments that are connected with initial segment except initial segment and by terminal
Other line segments.It is corresponding with initial segment in motion track that this does not intersect the line segment for but intersecting with initial segment with terminal
Termination line segment.
As shown in Figure 10, in another embodiment, above-mentioned availability deciding module 130 also includes metrics calculation unit
135 and Distance Judgment unit 137.
Metrics calculation unit 135, for determine the line segment not intersected with terminal and initial segment it is non-intersect when, according to rising
The prime direction of initial line section obtains the corresponding terminal of line segment not intersected with terminal, and calculated terminal and initial segment
Starting distance between starting point.
In the present embodiment, prime direction is the starting point direction to terminal in motion track by initial segment, distance meter
The terminal that unit 135 can obtain corresponding to the line segment that do not intersect with terminal along prime direction is calculated, and then according to Pythagorean theorem
The distance between the terminal being calculated corresponding to the line segment not intersected with terminal and the starting point of initial segment.
Whether Distance Judgment unit 137, be less than threshold value for judging distance, if so, then passes through terminal and the starting for obtaining
Line between the starting point of line segment obtains enclosed region determined by motion track, if it is not, then terminating.
In the present embodiment, motion track can be semi-open track, if Distance Judgment unit 137 is determined being calculated
Distance be then to illustrate that the moving operation of user is effectively operation within threshold range, motion track can determine
Region be enclosed region, if it is, outside threshold range, to illustrate motion track institute to determine calculated distance
Corresponding curve two ends it is distant, it is impossible to formed one determination enclosed region, therefore, the moving operation is input into by user
It is invalid operation.
Distance Judgment unit 137 is judged to the initial segment in motion track and the corresponding line segment that terminates by given threshold
Whether motion track approximately closes, and then the moving operation of the motion track for forming approximate closure will be also judged as effectively
Operation, improves the ease for use and convenience of user operation so that user need not carry out precise manipulation and be capable of achieving Interface Element
Plain selectes.
In semi-open motion track, by rising for the terminal corresponding to the line segment that do not intersect with terminal and initial segment
Line between point can determine enclosed region.Wherein, the terminal corresponding to line segment that do not intersect with terminal and initial segment
Line between starting point can be that the starting point of the terminal and initial segment that the line segment not intersected with terminal is located is joined directly together
The extended line that the extended line and initial segment that resulting line segment, or the line segment not intersected with terminal are located is located is connected
The line segment that knot is obtained.
Enclosed region processing module 150, for the interface element in enclosed region is chosen.
In the present embodiment, enclosed region processing module 150 is judged as the region of enclosed region in interface and makes a look up
The interface element in enclosed region is obtained, it is one or more to search the interface element for obtaining, will be by unchecked boundary
Surface element is transformed to the interface element chosen.
As shown in figure 11, in one embodiment, above-mentioned enclosed region processing module 150 includes extension apparatus 151, intersection point
Judging unit 153 and indexing unit 155.
Extension apparatus 151, for carrying out extending the ray for obtaining interface element with interface element as starting point one by one.
In the present embodiment, several interface elements in interface, are contained, each interface element in interface enters line position
Judgement is put, during knowing whether the interface element is located in enclosed region, extension apparatus 151 will one by one with interface element as starting point
Extend to obtain corresponding ray to certain orientation.In a preferred embodiment, the bearing of trend is interface institute x in a coordinate system
The negative direction of axle.
Intersection point judging unit 153, for obtaining the sum of the intersection point between ray and the line segment of composition motion track, and judges
Whether intersection point sum is odd number, if so, then notification indicia unit 155, if it is not, then stopping performing.
In the present embodiment, if interface element is located in enclosed region determined by motion track, the interface element institute is right
Number of intersections that the line segment of the ray answered and motion track is formed necessarily odd number, if interface element is located at motion track institute
It is determined that enclosed region outside, then the number of intersections formed by the line segment of the ray corresponding to the interface element and motion track must
It is so even number.
Accordingly, intersection point judging unit 153 is between the line segment of the ray and composition motion track that get interface element
Intersection point sum after, if it is odd number to determine intersection point sum, illustrate that interface element is in determined by motion track
In enclosed region, it is interface element that user selectes, therefore, notification indicia unit 155 is marked as selected state.If sentencing
It is even number to break to intersection point sum, then illustrate the interface element be outside enclosed region determined by motion track, because
This interface element is not the interface element that user selectes, it is not necessary to do any process to which.
Indexing unit 155, for ray corresponding interface element is chosen.
In the present embodiment, the number of intersections between the line segment for determining ray and composition motion track is odd number, then say
Bright this interface element is the enclosed region in interface, and interface element is transformed to choose by indexing unit 155 by unselected.
In another embodiment, above-mentioned enclosed region processing module 150 is additionally operable to choosing the interface element for obtaining
Afterwards, selected interface element is labeled as into selected state.
In the present embodiment, 150 pairs of interface elements chosen of enclosed region processing module are marked, in order to receiving and ringing
Answer the further operation of user input.
As shown in figure 12, in one embodiment, above-mentioned enclosed region processing module 150 also includes parallel judging unit
156。
Parallel judging unit 156, it is whether parallel with ray for judging the line segment for constituting motion track, if so, then ignore
The line segment parallel with the ray, it is no, then notify intersection point judging unit 153.
In the present embodiment, by the line segment quantitative determination of the ray of the interface element and composition motion track interface element
When whether being the interface element that user selectes, some specific scenes are also there are, therefore, pay the utmost attention to the special scenes for existing
Can quickly judge interface element or remove interference factor that whether interface element is selected as user, so improve treatment effeciency and
Accuracy.
Specifically, special scenes are that the corresponding ray of interface element is in parallel shape with the line segment of composition motion track
State, now, if the ray and between the line segment that the ray is parallel to each other be it is Chong Die, the ray and with the ray phase
Mutually the number of intersections between parallel line segment would is that countless;If the ray and between the coequal line segment of the ray
It is nonoverlapping, then no intersection point, therefore, antinode quantity is will be unable under this special scenes determines specific numerical value, because
This, it is necessary to ignore the line segment parallel with the ray, be to calculate the number of intersections between this line segment parallel with the ray and ray,
The accuracy selected to ensure interface element.
As shown in figure 13, in one embodiment, above-mentioned enclosed region processing module 150 also includes position judgment unit
157。
Position judgment unit 157, for judging that whether interface element region has friendship with the line segment of composition motion track
Collection, if so, then notification indicia unit 155, if it is not, then notify intersection point judging unit 153.
In the present embodiment, special scenes are that interface element is located on motion track.If a certain interface element is located at composition and moves
On a certain line segment of dynamic rail mark, then position judgment unit 157 directly judges that the interface element is determined in motion track
Enclosed region within, now the interface element is the interface element selected of user.
If interface element is not located at constituting on a certain line segment of motion track, need to obtain the interface element pair
Intersection point sum between the ray answered and the line segment of composition motion track, and then continue to judge whether the interface element is located at movement
In enclosed region determined by track.
Specifically, position judgment unit 157 can pass through judgment formula(y1-y0)*(x2-x0)-(y2-y0)*(x1-x0)
Into Rob Roy, whether==0 judges whether interface element is located on motion track, that what is set up when above-mentioned formula is determined is then further
Judge whether x0 and y0 is respectively positioned between x1 and x2 and y1 and y2, if so, then judge that interface element region is moved with composition
Dynamic rail mark has common factor, wherein,(Xi, y1)With(X2, y2)End points P1 and end points P2 respectively in the line segment of composition motion track
Coordinate,(X0, y0)The coordinate of interface element p, the coordinate of interface element are can be set as corresponding to the center of interface element
Coordinate.
As shown in figure 14, in one embodiment, above-mentioned enclosed region processing module 150 also includes end points judging unit
158。
End points judging unit 158, for judging whether the ray passes through the end points of line segment, if so, then ignores end points place
Arbitrary line segment, if it is not, then notifying intersection point judging unit 153.
In the present embodiment, special scenes are situation of the ray through some end of line segment.Specifically, it is being connected with each other
Between two lines section be by end points connect, therefore the ray of interface element pass through line segment end points when, the ray will be with two
There is intersection point in line segment, but in practice for being only one of which intersection point for whole motion track, therefore, should ignore wherein
One line segment, to ensure the accuracy of number of intersections.
In the above-mentioned device for realizing that interface element is selected, parallel judging unit 156, position can be set according to actual needs and sentenced
Any one unit in disconnected unit 157 and end points judging unit 158, it is also possible to which these three units are all arranged at into above-mentioned realization
In the device that interface element is selected.
The above-mentioned method and apparatus for realizing that interface element is selected, obtains the moving operation that user is input in interface, according to
Enclosed region determined by moving operation obtains the interface element in positioned at enclosed region, these interface elements is chosen, at this
During the selecting of one interface element, user only needs on interface arbitrarily input moving operation and is capable of achieving a large amount of interface elements
Select, significantly simplify operation, improve carries out selected speed to interface element.
One of ordinary skill in the art will appreciate that all or part of flow process in realizing above-described embodiment method, can be
Instruct related hardware to complete by computer program, described program can be stored in a computer read/write memory medium
In, the program is upon execution, it may include such as the flow process of the embodiment of above-mentioned each method.Wherein, described storage medium can be magnetic
Dish, CD, read-only memory(Read-Only Memory, ROM)Or random access memory(Random Access
Memory, RAM)Deng.
Embodiment described above only expresses the several embodiments of the present invention, and its description is more concrete and detailed, but and
Therefore the restriction to the scope of the claims of the present invention can not be interpreted as.It should be pointed out that for one of ordinary skill in the art
For, without departing from the inventive concept of the premise, some deformations and improvement can also be made, these belong to the guarantor of the present invention
Shield scope.Therefore, the protection domain of patent of the present invention should be defined by claims.
Claims (12)
1. a kind of method for realizing that interface element is selected, comprises the steps:
The moving operation in interface is obtained, and records the corresponding motion track of the moving operation;
Judge whether region determined by the motion track is enclosed region, the enclosed region formed in interface includes many
It is individual, multiple enclosed regions be obtained by user carries out multiple moving operation judge the motion track determined by region be
It is no for enclosed region the step of be:Any one line segment is set in the line segment of composition motion track for initial segment, and with institute
The arbitrary end points in initial segment is stated as the terminal of the initial segment, the motion track corresponding to the moving operation be by
Some line segment compositions, with the terminal as starting in the line segment of the motion track, judgement is not intersected with the terminal
Line segment whether intersect with the initial segment, the line segment that do not intersect with terminal be motion track line segment in except starting
Other line segments outside line segment and the adjacent segments that are connected with initial segment by terminal, are determined and are not intersected with the terminal
Line segment it is non-intersect with the initial segment when, according to the prime direction of the initial segment is obtained not with the terminal phase
The distance between the corresponding terminal of line segment of friendship, and the terminal that obtains described in calculating and the starting point of the initial segment, judge institute
Distance is stated whether less than threshold value, is if so, then obtained by the line between the terminal for obtaining and the starting point of the initial segment
To enclosed region determined by the motion track, the terminal corresponding to line segment not intersected with terminal and the starting point of initial segment
Between line include that the extended line that the line segment that do not intersected with terminal is located and the extended line that initial segment is located are connected and obtain
Line segment;
If so, then the interface element in enclosed region is chosen.
2. it is according to claim 1 realize interface element select method, it is characterised in that it is described by enclosed region
The step of interface element is chosen be:
Carry out extending the ray for obtaining the interface element with interface element as starting point one by one;
The intersection point sum between the line segment of the ray and composition motion track is obtained, and judges whether the intersection point sum is strange
Number, if so, then
The ray corresponding interface element is chosen.
3. the method for realizing that interface element is selected according to claim 2, it is characterised in that the acquisition ray with
Also include before the step of the intersection point sum between the line segment of composition motion track:
Judge whether the line segment of the composition motion track is parallel with ray, if so, then ignores the line segment parallel with the ray,
If it is not, then entering the step of the intersection point sum obtained between the ray and the line segment of composition motion track.
4. the method for realizing that interface element is selected according to claim 2, it is characterised in that the acquisition ray with
Also include before the step of the intersection point sum between the line segment of composition motion track:
Judge whether the interface element region has common factor with the line segment for constituting motion track, if so, then enter institute
The step of ray corresponding interface element is chosen is stated, if it is not, then entering the acquisition ray and composition moving rail
The step of the intersection point sum between the line segment of mark.
5. the method for realizing that interface element is selected according to claim 2, it is characterised in that the acquisition ray with
Also include before the step of the intersection point sum between the line segment of composition motion track:
Judge whether the ray passes through the end points of line segment, if so, then ignore arbitrary line segment that the end points is located.
6. according to any one of claim 1-5 realizing interface element select method, it is characterised in that will it is described must
To interface element choose after, selected interface element is labeled as into selected state.
7. it is a kind of realize interface element select device, it is characterised in that include:
Mobile processing module, for obtaining the moving operation in interface, and records the corresponding track of the moving operation;
Availability deciding module, for judging whether region determined by the motion track is enclosed region, if so, then notifies
Enclosed region processing module, the enclosed region formed in interface includes multiple, and multiple enclosed regions are that user is carried out repeatedly
Obtained by moving operation;
The enclosed region processing module is for the interface element labelling in enclosed region is chosen;
The availability deciding module includes:
Setting unit, for arranging any one line segment for initial segment, and with described in the line segment of composition motion track
Terminal of the arbitrary end points in initial line section as the initial segment, the motion track corresponding to the moving operation is by some
Bar line segment composition;
Intersecting judging unit, in the line segment of the motion track with the terminal as starting, judge not with the terminal
Whether intersecting line segment is intersected with the initial segment, the line segment that do not intersect with terminal be motion track line segment in except
Other line segments outside initial segment and the adjacent segments that are connected with initial segment by terminal, if so, then notify described in close
Close regional processing module;
Metrics calculation unit, for determine the line segment that do not intersect with the terminal it is non-intersect with the initial segment when, according to
The prime direction of the initial segment obtains the corresponding terminal of line segment not intersected with the terminal, and obtains described in calculating
The distance between terminal and the starting point of the initial segment;
Distance Judgment unit, for judging the distance whether less than threshold value, if so, then passes through the terminal for obtaining and described
Line between the starting point of initial segment obtains enclosed region determined by the motion track, the line segment institute do not intersected with terminal
Line between corresponding terminal and the starting point of initial segment includes the extended line at the line segment place do not intersected with terminal and starting
The extended line that line segment is located is connected the line segment for obtaining.
8. the device for realizing that interface element is selected according to claim 7, it is characterised in that the enclosed region processes mould
Block includes:
Extension apparatus, for carrying out extending the ray for obtaining the interface element with interface element as starting point one by one;
Intersection point judging unit, for obtaining the sum of the intersection point between the ray and the line segment of composition motion track, and judges institute
State whether intersection point sum is odd number, if so, then notification indicia unit;
The indexing unit is for the ray corresponding interface element is chosen.
9. the device for realizing that interface element is selected according to claim 8, it is characterised in that the enclosed region processes mould
Block also includes:
Whether parallel judging unit, the line segment for judging the composition motion track are parallel with ray, if so, then ignore and institute
The parallel line segment of ray is stated, if it is not, then notifying the intersection point judging unit.
10. the device for realizing that interface element is selected according to claim 8, it is characterised in that the enclosed region is processed
Module also includes:
Position judgment unit, for judging that whether the interface element region has friendship with the line segment of the composition motion track
Collection, if so, then notifies the indexing unit, if it is not, then notifying the intersection point judging unit.
11. devices for realizing that interface element is selected according to claim 8, it is characterised in that the enclosed region is processed
Module also includes:
End points judging unit, for judging whether the ray passes through the end points of line segment, if so, then ignores what the end points was located
Arbitrary line segment.
12. devices that interface element is selected of realizing according to any one of claim 7-11, it is characterised in that the closure
Regional processing module is additionally operable to after the interface element for obtaining is chosen, and selected interface element is labeled as choosing shape
State.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201210457676.4A CN103809954B (en) | 2012-11-14 | 2012-11-14 | Method and device for realizing interface element selection |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201210457676.4A CN103809954B (en) | 2012-11-14 | 2012-11-14 | Method and device for realizing interface element selection |
Publications (2)
Publication Number | Publication Date |
---|---|
CN103809954A CN103809954A (en) | 2014-05-21 |
CN103809954B true CN103809954B (en) | 2017-03-22 |
Family
ID=50706790
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201210457676.4A Active CN103809954B (en) | 2012-11-14 | 2012-11-14 | Method and device for realizing interface element selection |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN103809954B (en) |
Families Citing this family (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104133595A (en) * | 2014-06-06 | 2014-11-05 | 蓝信工场(北京)科技有限公司 | Method and device for selecting multiple objects on touch screen of electronic equipment |
CN105989344B (en) * | 2015-02-26 | 2019-09-17 | 阿里巴巴集团控股有限公司 | Bar code recognition and device |
CN106775210B (en) * | 2016-11-29 | 2020-09-04 | 北京小米移动软件有限公司 | Wallpaper changing method and device |
EP3913518A4 (en) * | 2019-02-15 | 2022-09-14 | Siemens Ltd., China | Graphical programming method, system and apparatus, medium, processor and terminal |
CN110751706B (en) * | 2019-10-29 | 2024-03-22 | 网易(杭州)网络有限公司 | Method, device, equipment and storage medium for processing graphics in game |
CN113625924A (en) * | 2020-05-09 | 2021-11-09 | 北京奇虎科技有限公司 | Element selection method, equipment, storage medium and device based on mobile operation |
CN113010067A (en) * | 2020-12-25 | 2021-06-22 | 北京小米移动软件有限公司 | Image processing method and device, electronic equipment and storage medium |
Family Cites Families (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US8643605B2 (en) * | 2005-11-21 | 2014-02-04 | Core Wireless Licensing S.A.R.L | Gesture based document editor |
JP4605279B2 (en) * | 2008-09-12 | 2011-01-05 | ソニー株式会社 | Information processing apparatus, information processing method, and program |
CN102656869B (en) * | 2009-12-22 | 2015-11-25 | 摩托罗拉移动公司 | For the method and apparatus of n-back test in the electronic device |
CN102760029B (en) * | 2011-04-29 | 2016-04-20 | 汉王科技股份有限公司 | The method and apparatus of operating list on display interface |
-
2012
- 2012-11-14 CN CN201210457676.4A patent/CN103809954B/en active Active
Also Published As
Publication number | Publication date |
---|---|
CN103809954A (en) | 2014-05-21 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN103809954B (en) | Method and device for realizing interface element selection | |
US9218683B2 (en) | Collection rearrangement animation | |
EP2635954B1 (en) | Notification group touch gesture dismissal techniques | |
CN104166553B (en) | A kind of display methods and electronic equipment | |
CN104063128B (en) | A kind of information processing method and electronic equipment | |
CN101887344B (en) | Information processing apparatus and information processing method | |
US11720230B2 (en) | Interactive data visualization user interface with hierarchical filtering based on gesture location on a chart | |
DE212015000213U1 (en) | Multidimensional object reorganization | |
CN102937844B (en) | Control method of medical diagnostic device with touch screen | |
US20140176555A1 (en) | Use of dynamic numeric axis to indicate and highlight data ranges | |
CN104238887B (en) | The icon lookup method and device of conventional application program | |
CN104714737A (en) | Method and apparatus for switching an interface mode using an input gesture | |
CN108596955A (en) | A kind of image detecting method, image detection device and mobile terminal | |
CN107608668A (en) | Method, apparatus, terminal device and the storage medium of the compatible display of H5 page animations | |
CN106527915A (en) | Information processing method and electronic equipment | |
CN107219983A (en) | List display method and device | |
CN105094669A (en) | Method and device for switching multiple tab pages of browser | |
CN103645937B (en) | The method and electronic equipment of a kind of data processing | |
CN108509241A (en) | A kind of full screen display process of image, full screen display device and mobile terminal | |
CN104239606B (en) | The UML modeling methods and device of touch screen are supported under Web environment | |
CN104254875A (en) | Information processing device, information processing method, and information processing computer program product | |
CN108052677A (en) | Page processing method, device and readable storage medium storing program for executing | |
CN107239212A (en) | Segmentation selection view rendering method, device and user terminal | |
CN102141909B (en) | Primitive creation method and system | |
CN102609206A (en) | Interaction method of function option in software |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
C14 | Grant of patent or utility model | ||
GR01 | Patent grant |