Patent Document ID: 9377949
Application ID: 14334670
Patent Status: 1

Claim One:
1. A method for selecting a character from content displayed in a touch screen, comprising: detecting a touch point of a user gesture acting on the touch screen, wherein the touch point falls into a touch point node; searching a plurality of nodes of the contents to find a nearest text node to the touch point, when the touch point node is not a text node, wherein the plurality of nodes are organized as a node tree, wherein searching the plurality of nodes comprises determining whether the touch point node contains any text node; calculating the distance between the touch point and each text node contained in the touch point node when the touch point node contains at least one text node, wherein calculating the distance comprises determining the coordinates of the four vortex of the at least one text node; and calculating the distance between the touch point and each text node according to the coordinates of the touch point and the coordinates of the four vortex of the at least one text node, wherein the coordinates of the touch point are (m, n), the coordinates of the lower left vertex of a text node are (x 1 , y 1 ) the coordinates of the upper left vertex are (x 1 , y 2 ), the coordinates of the upper right vertex are (x 2 , y 2 ), and the coordinates of the lower right vertex are (x 2 , y 1 ), wherein if m<x 1 , and n<y 2 , the distance is √{square root over ((x 1 −m) 2 +(n−y 2 ) 2 )}; if m<x 1 , and y 2 <n<y 1 , the distance is |x 1 −m|; if m<x 1 , and n>y 1 , the distance is √{square root over ((x 1 −m) 2 +(n−y 1 ) 2 )}; if x 1 <m<x 2 , and n>y 1 , the distance is |y 1 −n|; if m>x 2 , and n>y 1 , the distance is √{square root over ((x 2 −m) 2 +(y 1 −n) 2 )}; if m>x 2 , and y 2 <n<y 1 , the distance is |m−x 2 |; if m>x 2 , and n<y 2 , the distance is √{square root over ((x 2 −m) 2 +(y 2 −n) 2 )}; and if x 1 <m<x 2 , and n<y 2 , the distance is |n−y 2 |; and selecting the text node of the smallest distance as the nearest text node to the touch point; and selecting a nearest character to the touch point within the nearest text node.