2001-11-21 Laszlo Peter <laca@ireland.sun.com>
[platform/core/uifw/at-spi2-atk.git] / cspi / spi_hypertext.c
1 /**
2  * AccessibleHypertext_ref:
3  * @obj: a pointer to the #AccessibleHypertext object on which to operate.
4  *
5  * Increment the reference count for an #AccessibleHypertext object.
6  *       Since AccessibleHypertext is derived from AccessibleText,
7  *       this is the same as AccessibleText_unref().
8  *
9  * Returns: (no return code implemented yet).
10  *
11  **/
12 int
13 AccessibleHypertext_ref (AccessibleHypertext *obj)
14 {
15   Accessibility_Hypertext_ref (*obj, &ev);
16   return 0;
17 }
18
19
20 /**
21  * AccessibleHypertext_unref:
22  * @obj: a pointer to the #AccessibleHypertext object on which to operate.
23  *
24  * Decrement the reference count for an #AccessibleHypertext object.
25  *       Since AccessibleHypertext is derived from AccessibleText,
26  *       this is the same as AccessibleText_unref().
27  *
28  * Returns: (no return code implemented yet).
29  *
30  **/
31 int
32 AccessibleHypertext_unref (AccessibleHypertext *obj)
33 {
34   Accessibility_Hypertext_unref (*obj, &ev);
35   return 0;
36 }
37
38
39
40 /**
41  * AccessibleHypertext_getNLinks:
42  * @obj: a pointer to the #AccessibleHypertext implementor on which to operate.
43  *
44  * Get the total number of #AccessibleHyperlinks which an
45  *        #AccessibleHypertext implementor has.
46  *
47  * Returns: a #long indicating the number of #AccessibleHyperlinks
48  *        of the #AccessibleHypertext implementor, or -1 if
49  *        the number cannot be determined (for example, if the
50  *        #AccessibleHypertext object is so large that it is not
51  *        all currently in the memory cache).
52  *
53  **/
54 long
55 AccessibleHypertext_getNLinks (AccessibleHypertext *obj)
56 {
57   return (long)
58     Accessibility_Hypertext_getNLinks (*obj, &ev);
59 }
60
61
62 /**
63  * AccessibleHypertext_getLink:
64  * @obj: a pointer to the #AccessibleHypertext implementor on which to operate.
65  * @linkIndex: a (zero-index) long integer indicating which hyperlink to query.
66  *
67  * Get the #AccessibleHyperlink object at a specified index.
68  *
69  * Returns: the #AccessibleHyperlink object specified by #linkIndex.
70  *
71  **/
72 AccessibleHyperlink *
73 AccessibleHypertext_getLink (AccessibleHypertext *obj,
74                              long int linkIndex)
75 {
76   return (AccessibleHyperlink *)
77     Accessibility_Hypertext_getLink (*obj,
78                                      (CORBA_long) linkIndex, &ev);
79 }
80
81
82 /**
83  * AccessibleHypertext_getLinkIndex:
84  * @obj: a pointer to the #AccessibleHypertext implementor on which to operate.
85  * @characterOffset: an integer specifying the character offset to query.
86  *
87  * Get the index of the #AccessibleHyperlink object at a specified
88  *        character offset.
89  *
90  * Returns: the linkIndex of the #AccessibleHyperlink active at
91  *        character offset @characterOffset, or -1 if there is
92  *        no hyperlink at the specified character offset.
93  *
94  **/
95 long
96 AccessibleHypertext_getLinkIndex (AccessibleHypertext *obj,
97                                   long int characterOffset)
98 {
99   return (long)
100     Accessibility_Hypertext_getLinkIndex (*obj,
101                                           (CORBA_long) characterOffset, &ev);
102 }
103
104