2009-04-21 Mark Doffman <mark.doffman@codethink.co.uk>
[platform/core/uifw/at-spi2-atk.git] / xml / org.freedesktop.atspi.EditableText.xml
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.EditableText">
4   <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
5     <p>Derived from interface Text, EditableText provides methods for
6       modifying textual content of components which support editing.
7       EditableText also interacts with the system clipboard via copyText,
8       cutText, and pasteText.  </p>
9
10     <p>Read-only instances of EditableText are possible; 
11       These may be instances of a general-purpose component type which are
12       sometimes, but not always, user-editable, or may be
13       components which are temporarily or circumstantially
14       in a non-editable state. </p>
15   </tp:docstring>
16   <method name="setTextContents">
17     <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
18       <p>Replace the text contents with a new string, discarding the old contents.    </p>
19     </tp:docstring>
20     <arg direction="in" name="newContents" type="s">
21     <tp:docstring>
22       A UTF-8 string with which the text object's contents will be replaced.
23     </tp:docstring>
24     </arg>
25     <arg direction="out" type="b" tp:type="boolean">
26     <tp:docstring>
27             <code>True</code> if the text content was successfully changed, <code>False</code> otherwise.
28     </tp:docstring>
29     </arg>
30   </method>
31   <method name="insertText">
32     <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
33       <p>Insert new text contents into an existing text object at a given location, while retaining
34         the old contents.
35       </p>
36     </tp:docstring>
37     <arg direction="in" name="position" type="i">
38             <tp:docstring>
39         The character offset into the Text implementor's content at which the
40         new content will be inserted.
41             </tp:docstring>
42     </arg>
43     <arg direction="in" name="text" type="s">
44             <tp:docstring>
45                     A UTF-8 string of which <code>length</code> characters will be inserted into the text 
46         object's text buffer.
47             </tp:docstring>
48     </arg>
49     <arg direction="in" name="length" type="i">
50             <tp:docstring>
51                     The number of characters of <code>text</code> to insert.  If the character count
52                     of <code>text</code> is less than or equal to <code>length</code>, the entire contents
53                     of <code>text</code> will be inserted.    
54             </tp:docstring>
55     </arg>
56     <arg direction="out" type="b" tp:type="boolean">
57     <tp:docstring>
58             <code>True</code> if the text content was successfully inserted, <code>False</code> otherwise.
59     </tp:docstring>
60     </arg>
61   </method>
62   <method name="copyText">
63     <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
64       <p>Copy a range of text into the system clipboard.
65       </p>
66     </tp:docstring>
67     <arg direction="in" name="startPos" type="i">
68             <tp:docstring>
69         The character offset of the first character in the range of text being
70         copied.
71             </tp:docstring>
72     </arg>
73     <arg direction="in" name="endPos" type="i">
74             <tp:docstring>
75         The offset of the first character past the end of the range of text
76         being copied.
77             </tp:docstring>
78     </arg>
79   </method>
80   <method name="cutText">
81     <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
82       <p>Excise a range of text from a Text object, copying it into the system clipboard.  </p>
83     </tp:docstring>
84     <arg direction="in" name="startPos" type="i">
85     <tp:docstring>
86         The character offset of the first character in the range of text being
87         cut.
88     </tp:docstring>
89     </arg>
90     <arg direction="in" name="endPos" type="i">
91     <tp:docstring>
92         The offset of the first character past the end of the range of text
93         being cut.
94     </tp:docstring>
95     </arg>
96     <arg direction="out" type="b" tp:type="boolean">
97     <tp:docstring>
98       <code>True</code> if the text was successfully cut, <code>False</code> otherwise.
99     </tp:docstring>
100     </arg>
101   </method>
102   <method name="deleteText">
103     <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
104       <p>Excise a range of text from a Text object without copying it into the system clipboard.  </p>
105     </tp:docstring>
106     <arg direction="in" name="startPos" type="i">
107     <tp:docstring>
108         The character offset of the first character in the range of text being
109         deleted.
110     </tp:docstring>
111     </arg>
112     <arg direction="in" name="endPos" type="i">
113     <tp:docstring>
114         The offset of the first character past the end of the range of text
115         being deleted.
116     </tp:docstring>
117     </arg>
118     <arg direction="out" type="b" tp:type="boolean">
119     <tp:docstring>
120       <code>True</code> if the text was successfully deleted, <code>False</code> otherwise.
121     </tp:docstring>
122     </arg>
123   </method>
124   <method name="pasteText">
125     <tp:docstring xmlns="http://www.w3.org/1999/xhtml">
126       <p>Copy the text contents of the system clipboard, if any, into a Text object, 
127         inserting it at a particular character offset.    </p>
128     </tp:docstring>
129     <arg direction="in" name="position" type="i">
130             <tp:docstring>
131                 <p>The character offset before which the text will be inserted.</p>
132             </tp:docstring>
133     </arg>
134     <arg direction="out" type="b" tp:type="boolean">
135     <tp:docstring>
136       <code>True</code> if the text was successfully pasted into the Text object, <code>False</code> otherwise.
137     </tp:docstring>
138     </arg>
139   </method>
140 </interface>
141 </node>