Link tree forming apparatus, link tree forming method, and link tree forming program6862598Abstract A link tree is able to be formed in a visually logical and natural form for a plurality of objects displayed on a screen. At the time of setting individually selectable links to form an overall object link tree for the plurality of objects displayed on the screen, first processing is carried out for setting a link between an m-th object and an n-th object when only the n-th object exists in a predetermined direction with reference to the m-th object, and second processing is alternatively carried out for setting a link based on a distance of each object existing in said predetermined direction from the m-th object when a plurality of objects exist in a predetermined direction with reference to the m-th object. Claims What is claimed is: Description BACKGROUND OF THE INVENTION
Condition 1: Left (A) < horizontal center (B) and
Condition 2: Lower (A) .gtoreq. upper (B) .gtoreq. upper (A) or
upper (A) > upper (B) and simultaneously vertical
center (A) .ltoreq. lower (B)
FIG. 4B shows an example of a case where the above described conditions are satisfied: that is, a case where "(B) is to the right of (A)". In comparisons within the above described conditions, values in the horizontal direction are progressively smaller toward the left, and values in the vertical direction are progressively smaller upward. As a concrete example, a case will be described in which "object" is (1). In this case, "item after object" is (2), and therefore it is determined whether (2) is to the right of (1). In FIG. 2, left (1)<horizontal center (2), and the condition lower (1).gtoreq.upper (2).gtoreq.upper (1) is satisfied, so (2) is determined to be to the right of (1). Therefore the result of S104 is YES, and the right link destination of object (1) is set as item after object (2) (S105). Next, "item after object" is assigned to "object" (S111). If "object" is (1), (2), which is "item after object", is assigned. Then, links are set from S103 in the same way as described above. As shown in FIG. 2, up to object (3) a right link is set in all cases for "item after object". Next, when the link destination from object (4) is determined, since "item after object" is (5), the right link conditions are not satisfied (S104, NO). It is then determined whether or not item after object (5) is below object (4) (S106). In this step, "below object" means a case where the following conditions are satisfied. Using the notation in FIG. 4A, sample conditions for (B) being below (A) are shown below.
Condition 1: Vertical center (A) < upper (B) and
Condition 2: Right (B) .gtoreq. left (A) .gtoreq. left (B) or
right (A) .gtoreq. left (B) .gtoreq. left (A)
FIG. 4C shows an example of a case where the above described conditions are satisfied: that is, a case where "(B) is below (A)." With regard to object (4) and item after object (5), vertical center (4)<upper (5), and the condition right (5).gtoreq.left (4).gtoreq.left (5) is satisfied, so (5) is determined to be below (4). Therefore, the result of S106 is YES, and the downward link destination of object (4) is set as item after object (5) (S107). Next, "item after object" is assigned to "object" (S111). If "object" is (4), (5), which is "item after object", is assigned. Then, links are set from S103 in the same way as described above. As shown in FIG. 2, a downward link is set for "item after object" for object (4), object (6), and object (8). Next, when the link destination from object (5) is determined, since "item after object" is (6), as can be seen from the drawing the right link and downward link conditions are not satisfied (S104, NO and S106, NO). And in the case of object (7), also, conditions are similarly not satisfied with respect to item after object (8). Therefore, a near item link search is performed (S108). In S108, to be specific, if "object" is (5), the item nearest item after object (6) from among the items from the top of the list to the object (from 1 to 5) is searched for. Details of the processing flow in S108 are shown in FIG. 5. The terms "horizontal distance" and "distance" used in the flowchart in FIG. 5 are defined as follows. Distance (A, B)={left (A)-left (B)}.sup.2 +{upper (A)-upper (B)}.sup.2 Horizontal distance (A, B)=absolute value of {right (A)-right (B)} Distance (A, B) should be expressed as the square root of the right side, but is defined here as described above since only a size comparison is necessary. Here, verification proceeds for each item, one by one, from the top of the list to the object, and therefore a new variable "object 2" is provided separately from "object". When contents item m is assigned to "object 2", it is expressed as object 2 (m). First, the top of the list is assigned to "object 2". In this embodiment, (1) is assigned. A candidate for a right link to "item after object" is designated "right link" and a candidate for a downward link to "item after object" is designated "downward link", and initially NULL is set for "right link" and "downward link" (S120). Next, it is determined whether or not the "object 2" right link destination is NULL and "item after object" is to the right of "object 2" (S121). If the result of S121 is YES, it is determined that "item after object" is to the right of "object 2", and then verification is performed as to whether or not "item after object" should be set as "right link" of "object 2" (S122). In S122, it is determined whether or not "right link" is NULL, or horizontal distance (object 2, item after object)<horizontal distance (right link, item after object). If either condition is satisfied (S122, YES), "object 2" is assigned to "right link" (S123). In this processing, if nothing has been set for "right link", or if a candidate (contents item) has already been assigned to "right link" and the result of comparing the horizontal distance from "item after object" to the already assigned candidate with the horizontal distance from "item after object" to "object 2" is that the horizontal distance from "item after object" to "object 2" is smaller, a right link is set for the time being from the contents item assigned to "object 2" to the contents item assigned to "item after object". As all items from the start of the links to the object are assigned and verified one by one for object 2, "right link" is not confirmed until verification is completed for all items. If the result of S121 is NO, verification is performed as to whether or not a downward link can be set. First, it is determined whether or not all the following conditions are satisfied: "right link" is NULL, and "object 2" downward link destination is NULL, and upper (object 2).ltoreq.lower (item after object) (S124). If all the conditions are satisfied here (S124, YES), "item after object" is determined to be in a downward direction from "object 2", and verification is then performed as to whether or not "item after object" should be set as "downward link" of "object 2" (S125). In S125, it is determined whether or not "downward link" is NULL, or distance (object 2, item after object)<distance (downward link, item after object). If either condition is satisfied (S125, YES), "object 2" is assigned to "downward link" (S126). In this processing, if nothing has been set for "downward link", or if a candidate has already been assigned to "downward link" and the result of comparing the distance from "item after object" to the already assigned candidate with the distance from "item after object" to "object 2" is that the distance from "item after object" to "object 2" is smaller, a downward link is set, for the time being, from the contents item assigned to "object 2" to the contents item assigned to "item after object". As with the above described right link, as all items from the start of the links to "object" are assigned and verified one by one for "object 2", "downward link" is not confirmed until verification is completed for all items. If the results of S122, S124, and S125 are all NO, or if "object 2" is assigned to "right link" or "object 2" is assigned to "downward link", the contents item after "object 2" is assigned to "object 2" (S127). Then, a check is performed as to whether or not "object 2" after assignment is "object" (S128), and if it is not "object" (S128, NO), link checking is performed again for the relevant "object 2" in the same way as described above. If "object 2" after assignment is "object" (S128, YES), verification is taken as having been completed for all items, and at this point the contents item assigned to "right link" or "downward link" is set as a link destination. If "right link" is not NULL (S129, NO), TRUE is returned (S131) as a right link is set for "item after object" from "right link" (S130). If "right link" is NULL (S129, YES) and "downward link" is not NULL (S132, NO), TRUE is returned (S131) as a downward link is set for "item after object" from "downward link" (S133). If "downward link" is NULL (S132, YES), this means that a nearest contents item to "item after object" was not found, and FALSE is returned (S134). If TRUE is obtained (S108, YES), in S109 in FIG. 3 the right (or downward) link destination of the contents item nearest "item after object" is set as "item after object". That is to say, either a right link is set for "item after object" from "right link", or a downward link is set for "item after object" from "downward link". Conversely, if FALSE is obtained (S108, NO), this means that an item near "item after object" was not found from the top of the list to "object", and an "object" downward link is forcibly set as "item after object" (S110). The above described flow will now be described for an actual example. Verification is first performed from (1) for item after object (6). As a right link of object 2 (1) has already been set in S104 in FIG. 3 and is not NULL, the result of S121 is NO. Next, in S124, since "right link" is NULL and a downward link of object 2 (1) has not yet been set, and moreover (6) is below object 2 (1), the result of S124 is YES. Then, since "downward link" is NULL in S125, the result of S125 is YES, and object 2 (1) is assigned to "downward link". Next, (2) is assigned to "object 2" and verification is carried out in the same way as described above. For (2), the flow up to S125 is the same as for (1), but since (1) has already been assigned to "downward link", it is determined whether or not object 2 (2) should be newly assigned to "downward link" by comparing the distances from (1) and (2) to item after object (6). As can be seen from FIG. 2, distance (2, 6)>distance (1, 6) (S125, NO), and therefore the downward link is left unchanged at (1). Next, (3) and (4) are assigned in order to "object 2" and verification is performed in the same way. Since, in the final analysis, distance (1, 6) is the smallest, "downward link" finally remains as (1), TRUE is returned in S131, and a setting is made in S109 in FIG. 3 so that the (1) downward link becomes item after object (6). When "item after object" is (8), also, verification is performed in the same way as described above, and the (5) downward link is set as item after object (8). As described above, a basic link tree is formed in the first step. FIG. 6 shows an example of the result of basic tree formation. The arrows shown in this drawing are the links set in this step. Next, a description will be given of link tree creation processing by means of a complete search for right and downward links (S200) in the second step. In this step, the optimum right link destination or downward link destination is determined from contents in the list for each contents item for which a right link or downward link has not yet been determined in the first step. FIG. 7 is a flowchart showing the detailed processing flow for complete creation of right and downward links, and the above described processing will be described below using this flowchart. First, the top of the list is assigned to "object" (S201). In this embodiment, (1) is assigned first. Next, it is determined whether or not "object" is NULL (S202). If "object" is NULL (S202, NO), it is determined that there is no contents item for which a link is to be set, and this processing is terminated. If "object" is not NULL in S202 (S202, YES), it is then determined whether or not the right link destination of "object" is NULL (S203). If the right link destination of "object" is NULL (S203, NO), it is determined that a right link has not yet been set, and an "object" right link destination search is performed (S204). In this embodiment, as shown in FIG. 6, a right link destination has not been set for (4) through (9), so S204 processing is executed. FIG. 8 is a flowchart showing the processing in S204 in detail. Right link destination search processing will be described below using this flowchart. For "right link 1" in the flowchart in FIG. 8 an item is assigned that satisfies the condition of being to the right of the object, and for "right link 2" an item is assigned that satisfies the condition of being in a 30.degree. sector area to the lower right of the object. As shown in FIG. 9, not only the "to the right of" condition (right link 1) but also the "within a 30.degree. sector area in the lower right direction" condition (right link 2) is used in right link search processing. If there are a plurality of contents items that satisfy the respective conditions, the distances from "object" to these are compared, and the item at the shortest distance is selected. If a contents item that satisfies the "right link 1" condition is found, "right link 2" search processing is suspended and the contents item satisfying the "right link 1" condition is preferentially determined to be the right link destination. As verification proceeds for each item, one by one, from the top of the list to "object", a variable called "object 2" is provided separately from "object". First, the top of the list (1) is assigned to "object 2". Also, NULL is assigned to "right link 1" and "right link 2" (S220). Next, it is determined whether or not "object 2" is NULL (S221). If "object 2" is not NULL (S221, YES), it is inferred that verification has not been completed for all contents items in the list, and right link search processing is continued. It is then determined whether or not "object 2" is "object" (S222). If "object 2" is "object" (S222, NO), since a right link is never set from "object" to "object" itself, the next contents item is assigned to "object 2" and search processing is continued (S228). If "object 2" is not "object" (S222, YES), it is next determined whether or not "object 2" is to the right of "object" (S223). In this embodiment, when the right link destination of object (6) is determined, since "object 2" is located above object (6) from (1) to (5), the result of S223 is NO, and S226 processing is executed. In S226, verification is performed as to whether or not conditions are satisfied for making a "right link 2" setting. "Object 2" is assigned to "right link 2" when the following conditions are satisfied.
Condition 1: "Right link 1" is NULL, and
Condition 2: "Object 2" is in a 30.degree. sector area to the lower
right of
"object", and
Condition 3: "Right link 2" is NULL or
distance (object, object 2) < distance (object, right
link 2)
When "object 2" is (1) to (5) or (7), condition 2 is not satisfied (S226, NO), and therefore no assignment is made to "right link 2" and in S228 the next contents item on the list is assigned to "object 2" (S228). In the case of "object 2" (6), the result of S222 is NO, and so similarly "right link 1" and "right link 2" do not change. When "object 2" is (8), it is in a 30.degree. sector area to the lower right of (6) and S226 conditions 1, 2, and 3 are all satisfied (S226, YES), and therefore (8) is assigned to "right link 2" (S227). When "object 2" is (9), as with (1) to (5) and (7), the S226 conditions are not satisfied and therefore "right link 2" does not change. In the distance-related condition of the above described three conditions, if there are a plurality of contents items in a 30.degree. sector area to the lower right of "object", the contents item nearest "object" is made "right link 2". When verification ends for (9), since "object 2" is NULL (S221, NO) as a result of S228 processing, S229 processing is executed. In S229, if "right link 1 " is not NULL (S229, YES), "right link 1" is given priority over "right link 2" and the contents item assigned to "right link 1" is set as the right link destination of "object" (S230). Also, if "right link 1" is NULL in S229 (S229, NO), the contents item assigned to "right link 2" is set as the right link destination of "object" (S231). As described above, when "object" is (6), the right link destination is (8) assigned to "right link 2". As another concrete example, the right link destination determination process will now be briefly described for the case where "object" is (7). When "object 2" is (1) to (6) or (8), the S226 conditions are not satisfied and therefore nothing is assigned to "right link 2". However, when "object 2" is (9), since it is to the right of (7) the result of S223 is YES, and since, of S224 conditions:
Conditions "Right link 1" is NULL, or
horizontal distance (object, object 2) < horizontal
distance (object, right link 1)
the condition "right link 1" is NULL is satisfied, after S228 "object 2" becomes NULL and (9) is assigned to "right link 1". As (9) is the last item on the list, S229 processing is executed, and also, since "right link 1" is not NULL in S229 (S229, YES), the right link destination of object (7) is set as (9) assigned to "right link 1" (S230). In the distance-related condition of the above described conditions, if there are a plurality of contents items to the right of "object", the contents item nearest "object" is made "right link 1". There are also cases where nothing is assigned to either "right link 1" or "right link 2" because the conditions are not satisfied at all. For example, the right link remains as NULL and nothing is set for (5), (8), and (9) in FIG. 6. When S204 processing in FIG. 7 ends, a check is then performed as to the presence/absence of a downward link for "object" in S205. S205 is also performed if the "object" right link destination is not NULL in S203 (S203, YES). Here, if the "object" downward link destination is NULL (S205, NO), it is determined that a downward link has not yet been set, and an "object" downward link destination search is performed (S206). FIG. 10 is a flowchart showing the processing in S206 in detail. Downward link destination search processing will be described below by using this flowchart. In the flowchart in FIG. 10, "downward link" indicates a candidate for the "object" downward link destination. In this processing, viewed from "object", the contents item that satisfies the condition of being lower than "object" in the list and has the shortest vertical distance to "object" is selected and made the downward link destination. If there are a plurality of contents items for which the vertical distance value is the same, a decision is made by comparing the distances (squares of absolute distances). To describe the above processing following the flowchart, the top of the list (1) is first assigned to "object 2". Also, NULL is assigned to "downward link" (S240). Next, it is determined whether or not "object 2" is NULL (S241). If "object 2" is not NULL (S241, YES), it is inferred that verification has not been completed for all contents items in the list, and downward link search processing is continued. It is then determined whether or not "object 2" is "object" and whether or not "object 2" is below "object" (S242). If "object 2" is "object" (S242, NO), since a downward link is never set from "object" to "object" itself, the next contents item after "object 2" is assigned to "object 2" (S249) and search processing is continued. If "object 2" is not "object" in S242 and upper (object)<upper (object 2) (S242, YES), it is then determined whether or not "downward link" is NULL (S243). If it is NULL (S243, YES), "object 2" is assigned to "downward link" (S244). If it is not NULL (S243, NO), it is inferred that there is a plurality of downward-linkable contents items, and verification in S245 to S247 is performed to set the contents item at the shortest distance from "object" from among these as the downward link. First, vertical distance (object, object 2) and vertical distance (object, downward link) are compared in S245. If the condition vertical distance (object, object 2).gtoreq.vertical distance (object, downward link) is not true (S245, NO), "object 2" is determined to be nearer "object" than the candidate assigned to "downward link", and "object 2" is assigned to "downward link" (S244). If vertical distance (object, object 2).gtoreq.vertical distance (object, downward link) (S245, YES), a check is then carried out as to whether or not vertical distance (object, object 2)=vertical distance (object, downward link). If the condition vertical distance (object, object 2)=vertical distance (object, downward link) is not true (S246, NO), the distance from the candidate assigned to "downward link" is determined to be smaller than that of "object 2", and the candidate assigned to "downward link" is kept unchanged. If vertical distance (object, object 2)=vertical distance (object, downward link) (S246, YES), distance, not vertical distance, is then verified. If distance (object, object 2).gtoreq.distance (object, downward link) (S247, YES), the candidate assigned to "downward link" is kept, but if the condition distance (object, object 2).gtoreq.distance (object, downward link) is not true (S247, NO), "object 2" is determined to be nearer "object" than the candidate assigned to "downward link", and "object 2" is assigned to "downward link" (S244). After S244, or if the result of S246 is NO or the result of S247 is YES, the next contents item after "object 2" is assigned to "object 2" (S249), and the downward link search is continued as described above. When "object 2" (9) verification ends, "object 2" becomes NULL (S241, NO), and therefore searching is terminated for all contents items and the candidate finally assigned to "downward link" is determined as the downward link destination of "object" (S248). As a concrete example, the case where the downward links of contents items (2) and (3) are set in FIG. 6 will now be described in detail, following the above described processing flow. When "object" is (2), (1) to (9) are assigned successively to "object 2", and verification as to whether or not a downward link is to be made is carried out. At the point at which "object 2" becomes (5), the S242 and S243 conditions are satisfied, and therefore (5) is assigned to "downward link" (S244). In this example, there are no items other than (5) for which upper (object)<upper (object 2), and therefore the candidate (5) assigned to "downward link" is determined as the downward link destination of object (2) (S248). When "object" is (3), also, (1) to (9) are assigned successively to "object 2" in the same way, and verification as to whether or not a downward link is to be made is carried out. As shown in FIG. 6, at the point at which "object 2" becomes (5), the S242 and S243 conditions are satisfied, and therefore (5) is assigned to "downward link" (S244). Then, when "object 2" becomes (8), the S242 conditions are satisfied but "downward link" is not NULL (S243, NO), so (5) and (8) are compared. In S245, vertical distance (2, 8).gtoreq.vertical distance (2, 5) (S245, YES) and the condition vertical distance (2, 8)=vertical distance (2, 5) is not true (S246, NO), and therefore "downward link" remains as (5). When "object 2" is (9), also, as with (8), vertical distance (2, 9).gtoreq.vertical distance (2, 5) (S245, YES) and the condition vertical distance (2,9)=vertical distance (2, 5) is not true (S246, NO), and therefore "downward link" is kept unchanged as (5). As a result, the downward link destination of (3) is (5). There are also cases where nothing is assigned to "downward link" because the conditions are not satisfied at all. For example, "downward link" remains as NULL and nothing is set for (7) and (9) in FIG. 6. When S206 processing in FIG. 7 ends, or if the object downward link is not NULL in S205 (S205, YES), "item after object" is assigned to "object" (S207), and the processing from S203 to S206 is repeated. As a result, right and downward link settings are completed for all contents items. FIG. 11 shows an example of the results of the second step. In the drawing, arrows shown as dotted lines are links set in the previous step, and arrows shown as solid lines are links set in this step. Next, left and upward link creation processing (S300) in the third step will be described. In this step, left and upward link destinations are determined using information on the right and downward link destinations determined in the first step and second step processing. If a right link (or downward link) has been set for a particular "object" from among a plurality of contents items, the one of these at the shortest distance from "object" is selected, and a left link (or upward link) is set from "object" to the selected contents item. FIG. 12 is a flowchart showing the processing flow for left and upward link creation, and the above described processing will be described below using this flowchart. First, the top of the list is assigned to "object" (S310). In this embodiment, (1) is assigned first. In this step, also, link destination searching is performed in order for all the contents items in the list (in this example, up to (9)). Next, it is determined whether or not "object" is NULL (S320). If "object" is NULL (S320, NO), it is determined that there is no contents item for which a link is to be set, or that links have been set for all contents items, and this processing is terminated. Next, a right reverse link (that is, a left link) is set from "object" (S330). Details of the processing in S330 are shown in the flowchart in FIG. 13A. `Right link destination of object` is expressed as "right of object" and `left link destination of "right of object"` as "left of right of object". First, it is determined whether or not "right of object" is NULL (S331). If it is NULL (S331, NO), since a reverse link (left link) is not set for an item for which a right link has not been set, left link setting is not performed. If "right of object" is not NULL (S331, YES), it is next determined whether or not the following S332 condition is satisfied: "left of right of object" is NULL, or distance (right of object, object)<distance (right of object, left of right of object) If the above described condition is satisfied (S332, YES), "object" is assigned to "left of right of object" (S333). If the above described condition is not satisfied, "left of right of object" does not change and S330 processing is terminated. In the distance-related condition of the above described conditions, if there are a plurality of contents items to the left of "right of object", the item nearest "object" is made the left link destination. Next, a downward reverse link (that is, upward link) from "object" is set (S340). Details of the processing in S340 are shown in the flowchart in FIG. 13B. `Downward link destination of object` is expressed as "downward of object" and `upward link destination of "downward link destination of object"` as "upward of downward of object". First, it is determined whether or not "downward of object" is NULL (S341). If it is NULL (S341, NO), since a reverse link (upward link) is not set for an item for which a downward link has not been set, upward link setting is not performed. If "downward of object" is not NULL (S341, YES), it is next determined whether or not the following S342 condition is satisfied: "upward of downward of object" is NULL, or "distance (downward of object, object)<distance (downward of object, upward of downward of object) If the above described condition is satisfied (S342, YES), "object" is assigned to "upward of downward of object" (S343). If the above described condition is not satisfied, "upward of downward of object" does not change and S340 processing is terminated. In the distance-related condition of the above described conditions, if there are a plurality of contents items upward of "downward of object", the item nearest "object" is made the upward link destination. After the S330 and S340 processing, the next contents item is assigned to "object" (S350). By repeating the processing from S320 to S350 in this way up to the end of the list (9), left and upward link destinations are determined. FIG. 14 shows an example of the results of the third step. In the drawing, arrows shown as dotted lines are links set in the first and second steps, and arrows shown as solid lines are links set in this step. Next, left and upward link complete search processing (S400) in the fourth step will be described. In this step, links are set for contents items for which a left link destination or upward link destination has not been determined in the third step processing. For each object, the optimum left link destination or upward link destination is determined from the contents items in the list. In this step, the processing is basically the same as that for right/downward link complete searching in the second step. Link destinations are determined in the left and upward directions instead of the right and downward directions. Also, as shown in FIG. 15, in left link search processing the condition "within a 30.degree. sector area to the upper left" is used, and the condition "to the left of" is not used. FIG. 16 and FIG. 17 are flowcharts showing the detailed processing flow for complete creation of a left and upward link tree, and the above described processing will be described below using these flowcharts. As upward link search processing is in principle the same as downward link search processing, a flowchart for this processing is omitted. First, in FIG. 16, the top of the list is assigned to "object" (S410). In this embodiment, (1) is assigned first. Next, it is determined whether or not "object" is NULL (S420). If "object" is NULL (S420, NO), it is determined that there is no contents item for which a link is to be set, or that links have been set for all contents items, and this processing is terminated. If "object" is not NULL in S420 (S420, YES), it is then determined whether or not the left link destination of "object" is NULL (S430). If the left link destination of "object" is NULL (S430, NO), it is determined that a left link has not yet been set, and an "object" left link destination search is performed (S440). In this embodiment, as shown in FIG. 14, a left link destination has not been set for (5), so S440 processing is executed when (5) is assigned to "object". FIG. 17 is a flowchart showing the processing in S440 in detail. Left link destination search processing will be described below by using this flowchart. In this processing, also, verification proceeds for each item, one by one, from the top of the list to the object, and therefore a variable called "object 2" is provided separately from "object". First, the top of the list (1) is assigned to "object 2". Also, NULL is assigned to "left link" (S441). Next, it is determined whether or not "object 2" is NULL (S442). If "object 2" is not NULL (S442, YES), it is inferred that verification has not been completed for all contents items in the list, and left link search processing is continued. In S443 it is determined whether or not the conditions for left link setting are satisfied (S443). If either of the conditions shown below is satisfied (S443, YES), "object 2" is assigned to "left link" (S444).
Condition A: "Left link" is NULL, and
"object 2" is in a 30.degree. sector area to the upper left
of
"object".
Condition B: Distance (object 2, object) < distance (left link,
object)
In condition B above, if there are a plurality of contents items in a 30.degree. sector area to the upper right of "object", the contents item nearest "object" is made the left link destination. When S444 processing ends, or if neither of the above described S443 conditions is satisfied (S443, NO), the next contents item is assigned to "object 2" (S445), and the above described processing is repeated. If "object 2" is NULL (S442, NO), it is determined that a left link search has been performed for all the contents items in the list for the relevant object, and the item finally assigned to "left link" is set as the left link destination of "object" (S446). In this embodiment, when "object" is (5) and "object 2" is (1), condition A above is satisfied and therefore (1) is assigned to "left link". When object 2 is (2) to (9), neither of the above conditions is satisfied, and therefore, finally, (1) is the left link destination of (5). After left link destination searching has been performed in S440, upward link destination searching is carried out. First, it is determined whether or not the upward link of "object" is NULL (S450). If it is NULL (S450, NO), an "object" upward link destination search is carried out in S460. The processing in S460 is similar to that in S206 ("object" downward link destination search) in FIG. 7, and so details will be omitted here. After S460 processing ends, or if the object upward link is not NULL (S450, YES), the next contents item is assigned to "object" (S470), and the processing from S430 to S460 is repeated. By this means, a left and upward and link search is finally carried out for all contents items, and link settings are completed. FIG. 18 shows an example of the results of the fourth step. In the drawing, arrows shown as dotted lines are links set in the first through third steps, and the arrow shown as a solid line is the link set in this step. At this point, the processing of all steps ends and the overall link tree is completed as shown in FIG. 19. As position information and distances are used in link setting, and link setting is carried out in steps, as described above, a visually natural link tree is created. In FIG. 19, for example, with the conventional method a downward link is made forcibly from (5) to (6), but according to the present invention, a downward link is set from (5) to (8), and focus movement that is visually natural and logical for the user is made possible. Embodiment 2 There is no problem if contents for which links are to be set are simple in form as shown in the first embodiment, but contents actually displayed on the Web have a variety of forms, and with Hyperlinks or the like, for example, there are cases where there is a plurality of lines produced by line feeds because of the length of the contents. FIG. 20 shows an example of such a case. In this drawing, reference numeral 500 denotes the state in which contents items (1) to (4) are displayed on the screen. As can be seen from the drawing, (3) is broken by line feeds so that the contents item is composed of a first element 3A, middle element 3B, and last element 3C, and is of such a form as to make it difficult to determine uniquely its position and distance relative to the other contents items. At this time, with the present invention, substitute position and size conversions are performed with the position, size, and observation direction of the first line and last line as parameters, and link setting is performed on the basis of the results of these conversions. Looking to the right from (3), the horizontal coordinate of (3C) and vertical coordinate of (3A) are used for the substitute position of (3), and the size of (3C) is used for the size (width). Similarly, when looking downward, also, the horizontal coordinate of (3C) and vertical coordinate of (3A) are used, and the size of (3C) is used for the size (width). Also, at the time of looking to the right to (3) from other contents, the position and size of the shaded part of the left frame are used, and at the time of looking downward to (3), the position and size of the shaded part of the upper frame are used. Concise notation for the substitute position and size for various observation directions using the above example in FIG. 20 can be given as follows. 1) Observation direction: When looking at (3) from 1 (upper) (501) Substitute position=Upper (3A), left (3C) Substitute size=Height (height of 3A), width (overall width) 2) Observation direction: When looking at 4 (lower) from (3) (502) Substitute position=Upper (3A), left (3C) Substitute size=Height (height of 3A), width (overall width) 3) Observation direction: When looking at (3) from 2 (right) (503) Substitute position=Upper (3A), left (3C) Substitute size=Height (overall height), width (width of 3A) 4) Observation direction: When looking at 4 (right) from (3) (504) Substitute position=Upper (3A), right (3C) Substitute size=Height (overall height), width (width of 3C) The results of such conversions may be stored beforehand in memory, etc., alternatively, such conversions may be made as required when setting links. Embodiment 3 By using the above-described first and second embodiments, it is possible to set links in a similar way for frames frequently used in Web pages, etc. A detailed description will be given below of link setting for contents within each frame and frames when there are a plurality of frames. It is assumed that the link tree formation method described in the first embodiment is provided independently for each frame. Therefore, within a frame, only the above described method can be applied. In this embodiment, inter-frame link setting is performed dynamically according to the frame display state (scroll state). To give a brief description of this dynamic link setting, at the time of setting a link from the object frame to another frame, if there are contents in that other frame, a link is set to the contents item at the shortest distance from the link origin among those contents. Also, in cases where there are contents in another frame but the contents are not displayed on the screen because of the scroll state of the frame, when a focus movement destination is input in the direction of that other frame, focusing alone is performed on that frame, and link setting to and focusing on the contents not displayed on the screen are not carried out. Also, if contents in the input movement direction are not visible even though they are present within the same frame, the frame only scrolls and focusing is not performed even if links have been set between the contents. Focusing can be carried out after the contents become visible. FIG. 21 is a flowchart showing the details of this kind of focus movement processing, and this flowchart is used in the following description. First, if there is an input for movement in direction X (S600), it is determined whether there is no selectable content in the frame currently being focused on, or whether the direction X link destination is NULL within the frame currently being focused on (S601). If the result of S601 is NO, it is determined that there is a selectable content, that is, a focus movement destination, within the frame currently being focused on. Then, it is determined whether or not the focus movement destination is in a position visible to the user (S602). That is to say, as there are cases where a link destination is not displayed on the screen due to the scroll state of the frame, judgment on this is performed in S602. If the link destination is being displayed (S602, YES), the focus is moved to the direction X link destination (S603). If the link destination is not being displayed (S602, NO), part of the screen is scrolled in direction X so that the link destination is displayed on the screen, and the focus is moved to that link destination (S605). Next, the processing when the result of S601 is YES will be described. In this case, it is determined that there is no selectable link destination in direction X within the frame currently being focused on, and it is then determined whether or not the current frame has been scrolled virtually to the limit in the direction of X (S604). If the result of S604 is NO, it is judged that there is room for scrolling of that frame in direction X, and part of the screen is scrolled in direction X (S605). If the result of S604 is YES, it is judged that there is no room for scrolling of that frame in direction X, and it is then determined whether or not there is another frame close to the frame currently being focused on in the X direction (S606). If there is another frame nearby (S606, NO), the focus is moved to that other nearby frame (S607). To give a detailed description of the operation in S607, the focus is moved as a link destination to the selectable contents item within the movement destination frame at the smallest distance from the selectable items currently being focused on. Also, if there are no selectable contents in the movement destination frame, the movement destination frame itself is focused on. Moreover, since the movement destination frame at this time will be the object of scrolling when there is the next input, information is held on it as the frame being focused on. If the result of S606 is YES, nothing is done and the processing ends. As a concrete example, focus movement in the case of contents containing four frames as shown in FIG. 22 will be described below. When the down-movement key is pressed while contents item (2) is being focused on: The focus is moved to contents item (3) (S603, intra-frame focus movement). When the down-movement key is pressed while contents item (3) is being focused on: The downward link destination of contents item (3) is NULL (S601, YES), frame 1 cannot be scrolled downward (S604, YES), and there is no nearby frame in the downward direction (S606, YES), so nothing is done. When the right-movement key is pressed while contents item (2) is being focused on: The right link destination of contents item (2) is NULL (S601, YES), frame 1 cannot be scrolled to the right (S604, YES), and there is an adjacent frame 2 in the right direction (S606, NO), so the focus is moved to frame 2 (S607). As contents item (5) is calculated as being at the shortest distance from contents item (2) according to the current position of frame 2, the focus is moved to contents item (5) (S607, inter-frame movement). When the down-movement key is pressed while contents item (6) is being focused on: As link destination contents item (7) cannot yet be seen on the screen (S602, NO), focus movement to contents item (7) is skipped, and frame 2 is scrolled one part at a time so that contents item (7) can be seen (S605, intra-frame scrolling). When the right-movement key is pressed while contents item (6) is being focused on: The right link destination of contents item (6) is NULL (S601, YES) and scrolling to the right is not possible (S604, YES), so the focus is moved to frame 4 nearby on the right (S607). However, as there are no selectable contents in frame 4, information on frame 4 is held, only, as a focus frame. Various embodiments of the present invention have been described above, but the present invention is not limited to the above described embodiments, and various changes or modifications are possible without departing from the object or spirit of the present invention. As described above, the present invention operates on the basis of both geometrical direction and distance for a plurality of objects displayed on a screen, and therefore makes it possible to form a link tree for focus movement by means of cross-shaped buttons or the like, for example, in a visually more logical and natural form than in the case of the conventional method whereby the order of a one-dimensional list is taken as an absolute condition. Consequently, when a browser that forms this kind of link tree is used, ease of use and excellent operability are provided to the user. Moreover, in link setting, at the time of setting a link from an m-th object to another object, if there are a plurality of linkable objects in the same direction, as viewed from the m-th object, the item for which the distance from the m-th object is the shortest is set as the link destination, thereby making possible link tree formation that achieves natural focus movement. Also, by setting links in steps, the present invention allows links to be set more flexibly according to the object layout, and as a result makes it possible to form a link tree desirable to the user. Therefore, even with devices such as portable terminals and WebTVs that do not use a mouse device, but have only an input device such as a remote controller with few buttons or cross-shaped buttons, the present invention provides an apparatus that allows contents displayed on the screen to be subjected to focus movement or selected easily without any sense of incongruity, and that is easy to use for the user. Moreover, the present invention can also be applied to frames frequently used in Home Pages or the like, and therefore enables link settings to be made easily to objects of other frames. In addition, the relevant link settings can be made dynamically according to the display state of contents that vary according to the scroll state of a frame, making it possible for link settings that include frames to be made in a visually natural fashion in the same way as described above. Also, by performing such link settings, natural on-screen frame movements and focus movements are ensured, further improving ease of use for the user.
|
Same subclass Same class Consider this |
||||||||||
