1 <?xml version="1.0" encoding="UTF-8"?>
2 <node xmlns:tp="http://telepathy.freedesktop.org/wiki/DbusSpec#extensions-v0" name="/node">
3 <interface name="org.freedesktop.atspi.Selection">
4 <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
5 <p>An interface which indicates that an object exposes a 'selection' model,
6 allowing the selection of one or more of its children. Read-only Selection
7 instances are possible, in which case the interface is used to programmatically
8 determine the selected-ness of its children. A selected child has State.STATE_SELECTED,
9 and a child which may hypothetically be selected (though possibly not programmatically
10 selectable) has State.STATE_SELECTABLE.</p>
11 <p>Events emitted by implementors of Selection include:
12 <code>object:selection-changed</code> An instance of Selection has undergone a change in the
13 'selected-ness' of its children, i.e. had a selection added,
14 removed, and/or modified. Usually accompanied by
15 corresponding <code>object:state-changed:selected</code> events
16 from the corresponding children, unless the children are
17 previously un-queried via AT-SPI and the Selection instance
18 has State.STATE_MANAGES_DESCENDANTS.</p>
20 <tp:property name="nSelectedChildren" type="i" access="read">
21 <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
22 <p>The number of children of a Selection implementor which are
23 currently selected.</p>
26 <method name="GetSelectedChild">
27 <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
28 <p>Get the i-th selected Accessible child of a Selection.</p>
29 <p><code>selectedChildIndex</code> refers to the index in the list of
30 'selected' children as opposed to the more general 'child index'
31 of an object; as such it generally differs from that used in
32 Accessible.GetChildAtIndex() or returned by
33 Accessible.GetIndexInParent().
34 <code>selectedChildIndex</code> must lie between 0
35 and Selection.nSelectedChildren-1, inclusive.</p>
37 <arg direction="in" name="selectedChildIndex" type="i">
39 A long integer indicating which of the selected children of an object is being requested.
42 <arg direction="out" type="o" tp:type="Accessible">
44 A pointer to a selected Accessible child object,specified by <code>selectedChildIndex</code>.
48 <method name="SelectChild">
49 <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
50 <p>Add a child to the selected children list of a Selection.</p>
51 <p>For Selection implementors that only allow
52 single selections, this call may result in the
53 replacement of the (single) current
54 selection. The call may return <code>False</code> if
55 the child is not selectable (i.e. does not have State.STATE_SELECTABLE),
56 if the user does not have permission to change the selection,
57 or if the Selection instance does not have State.STATE_SENSITIVE. </p>
59 <arg direction="in" name="childIndex" type="i">
61 A long integer indicating which child of theSelection is to be selected.
64 <arg direction="out" type="b" tp:type="boolean">
66 <code>True</code> if the child was successfully selected, <code>False</code> otherwise.
70 <method name="DeselectSelectedChild">
71 <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
72 <p>Remove a child to the selected children list of a Selection.</p>
73 <p><code>childIndex</code> is the index in the selected-children list,
74 not the index in the parent container. <code>selectedChildIndex</code> in this
75 method, and <code>childIndex</code> in Selection.SelectChild
78 <arg direction="in" name="selectedChildIndex" type="i">
80 A long integer indicating which of the selected children of the Selection is to be deselected. The indexis a zero-offset index into the 'selected child list', nota zero-offset index into the list of all children of the Selection.
83 <arg direction="out" type="b" tp:type="boolean">
85 <code>True</code> if the child was successfully deselected, <code>False</code> otherwise, see deSelectChild
89 <method name="IsChildSelected">
90 <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
91 <p>Determine whether a particular child of an Selection implementor
92 is currently selected. Note that <code>childIndex</code> is the zero-offset
93 index into the standard Accessible container's list of children. </p>
95 <arg direction="in" name="childIndex" type="i">
97 An index into the Selection's list of children.
100 <arg direction="out" type="b" tp:type="boolean">
102 <code>True</code> if the specified child is currently selected,<code>False</code> otherwise.
106 <method name="SelectAll">
107 <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
108 <p>Attempt to select all of the children of a Selection implementor.
109 Not all Selection implementors support this operation (for instance,
110 implementations which support only "single selection" do not support this operation).</p>
112 <arg direction="out" type="b" tp:type="boolean">
114 <code>True</code> if successful, <code>False</code> otherwise.
118 <method name="ClearSelection">
119 <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
120 <p>Attempt to clear all selections (i.e. deselect all children) of a Selection.
121 Not all Selection implementations allow the removal of all selections. </p>
123 <p>This operation may fail if the object must have at least one selected child,
124 if the user does not have permission to change the selection, or if the Selection
125 does not have State.STATE_SENSITIVE. </p>
127 <arg direction="out" type="b" tp:type="boolean">
129 <code>True</code> if the selections were successfully cleared, <code>False</code> otherwise.
133 <method name="deSelectChild">
134 <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
135 <p>Remove a child from the selected children list of a Selection,
136 if the child is currently selected. </p>
138 <p>Unlike DeselectSelectedChild, <code>childIndex</code> is the zero-offset
139 index into the Accessible instance's list of children,
140 not the index into the 'selected child list'. </p>
142 <arg direction="in" name="childIndex" type="i">
144 a long integer (the zero offset index into the Accessibleobject's list of children) indicating which child of theSelection is to be selected.
147 <arg direction="out" type="b" tp:type="boolean">
149 <code>True</code> if the child was successfully selected, <code>False</code> otherwise, see DeselectSelectedChild.