2008-08-18 Mark Doffman <mark.doffman@codethink.co.uk>
[platform/core/uifw/at-spi2-atk.git] / pyatspi / other.py
1 #Copyright (C) 2008 Codethink Ltd
2
3 #This library is free software; you can redistribute it and/or
4 #modify it under the terms of the GNU Lesser General Public
5 #License version 2 as published by the Free Software Foundation.
6
7 #This program is distributed in the hope that it will be useful,
8 #but WITHOUT ANY WARRANTY; without even the implied warranty of
9 #MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
10 #GNU General Public License for more details.
11 #You should have received a copy of the GNU Lesser General Public License
12 #along with this program; if not, write to the Free Software
13 #Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
14
15 from base import _BaseProxy, _Enum
16 from base import Accessible as _Accessible
17
18 import constants
19
20 from factory import add_accessible_class
21
22 class Action(_BaseProxy):
23     """
24     An interface through which a user-actionable user interface component
25     can be manipulated. Components which react to mouse or keyboard
26     input from the user, (with the exception of pure text entry fields
27     with no other function), should implement this interface. Typical
28     actions include "click", "press", "release" (for instance for
29     buttons), "menu" (for objects which have context menus invokable
30     from mouse or keyboard), "open" for icons representing files
31     folders, and others.
32     """
33     
34     
35     def doAction(self, *args, **kwargs):
36         """
37         doAction: 
38         @param : index
39         the 0-based index of the action to perform.
40         Causes the object to perform the specified action.
41         @return : a boolean indicating success or failure.
42         """
43         func = self.get_dbus_method("doAction")
44         return func(*args, **kwargs)
45     
46     def getDescription(self, *args, **kwargs):
47         """
48         getDescription: 
49         @param : index
50         the index of the action for which a description is desired.
51         Get the description of the specified action. The description
52         of an action may provide information about the result of action
53         invocation, unlike the action name. 
54         @return : a string containing the description of the specified
55         action.
56         """
57         func = self.get_dbus_method("getDescription")
58         return func(*args, **kwargs)
59     
60     def getKeyBinding(self, *args, **kwargs):
61         """
62         getKeyBinding: 
63         @param : index
64         the 0-based index of the action for which a key binding is requested.
65         Get the key binding associated with a specific action.
66         @return : a string containing the key binding for the specified
67         action, or an empty string ("") if none exists.
68         """
69         func = self.get_dbus_method("getKeyBinding")
70         return func(*args, **kwargs)
71     
72     def getName(self, *args, **kwargs):
73         """
74         getName: 
75         @param : index
76         the index of the action whose name is requested.
77         Get the name of the specified action. Action names generally
78         describe the user action, i.e. "click" or "press", rather then
79         the result of invoking the action.
80         @return : a string containing the name of the specified action.
81         """
82         func = self.get_dbus_method("getName")
83         return func(*args, **kwargs)
84     
85     def get_nActions(self):
86         self._pgetter(self._dbus_interface, "nActions")
87     def set_nActions(self, value):
88         self._psetter(self._dbus_interface, "nActions", value)
89     _nActionsDoc = \
90         """
91         nActions: a long containing the number of actions this object
92         supports.
93         """
94     nActions = property(fget=get_nActions, fset=set_nActions, doc=_nActionsDoc)
95
96
97 #------------------------------------------------------------------------------
98
99 class BoundingBox(list):
100     def __new__(cls, x, y, width, height):
101         list.__new__(cls, (x, y, width, height))
102     def __init__(self, x, y, width, height):
103         list.__init__(self, (x, y, width, height))
104     
105     def _get_x(self):
106         return self[0]
107     def _set_x(self, val):
108         self[0] = val
109     x = property(fget=_get_x, fset=_set_x)
110     def _get_y(self):
111         return self[1]
112     def _set_y(self, val):
113         self[1] = val
114     y = property(fget=_get_y, fset=_set_y)
115     def _get_width(self):
116         return self[2]
117     def _set_width(self, val):
118         self[2] = val
119     width = property(fget=_get_width, fset=_set_width)
120     def _get_height(self):
121         return self[3]
122     def _set_height(self, val):
123         self[3] = val
124     height = property(fget=_get_height, fset=_set_height)
125
126
127 class Collection(_BaseProxy):
128     
129     def createMatchRule(self, *args, **kwargs):
130         func = self.get_dbus_method("createMatchRule")
131         return func(*args, **kwargs)
132     
133     def freeMatchRule(self, *args, **kwargs):
134         func = self.get_dbus_method("freeMatchRule")
135         return func(*args, **kwargs)
136     
137     def getActiveDescendant(self, *args, **kwargs):
138         func = self.get_dbus_method("getActiveDescendant")
139         return func(*args, **kwargs)
140     
141     def getMatches(self, *args, **kwargs):
142         func = self.get_dbus_method("getMatches")
143         return func(*args, **kwargs)
144     
145     def getMatchesFrom(self, *args, **kwargs):
146         func = self.get_dbus_method("getMatchesFrom")
147         return func(*args, **kwargs)
148     
149     def getMatchesTo(self, *args, **kwargs):
150         func = self.get_dbus_method("getMatchesTo")
151         return func(*args, **kwargs)
152     
153     def isAncestorOf(self, *args, **kwargs):
154         func = self.get_dbus_method("isAncestorOf")
155         return func(*args, **kwargs)
156     
157     def unImplemented(self, *args, **kwargs):
158         func = self.get_dbus_method("unImplemented")
159         return func(*args, **kwargs)
160     
161     def unImplemented2(self, *args, **kwargs):
162         func = self.get_dbus_method("unImplemented2")
163         return func(*args, **kwargs)
164     
165     def unImplemented3(self, *args, **kwargs):
166         func = self.get_dbus_method("unImplemented3")
167         return func(*args, **kwargs)
168     
169     def unImplemented4(self, *args, **kwargs):
170         func = self.get_dbus_method("unImplemented4")
171         return func(*args, **kwargs)
172
173     class MatchType(_Enum):
174         _enum_lookup = {
175             0:'MATCH_INVALID',
176             1:'MATCH_ALL',
177             2:'MATCH_ANY',
178             3:'MATCH_NONE',
179             4:'MATCH_EMPTY',
180             5:'MATCH_LAST_DEFINED',
181         }
182     
183     MATCH_ALL = MatchType(1)
184     
185     MATCH_ANY = MatchType(2)
186     
187     MATCH_EMPTY = MatchType(4)
188     
189     MATCH_INVALID = MatchType(0)
190     
191     MATCH_LAST_DEFINED = MatchType(5)
192     
193     MATCH_NONE = MatchType(3)
194
195     class SortOrder(_Enum):
196         _enum_lookup = {
197             0:'SORT_ORDER_INVALID',
198             1:'SORT_ORDER_CANONICAL',
199             2:'SORT_ORDER_FLOW',
200             3:'SORT_ORDER_TAB',
201             4:'SORT_ORDER_REVERSE_CANONICAL',
202             5:'SORT_ORDER_REVERSE_FLOW',
203             6:'SORT_ORDER_REVERSE_TAB',
204             7:'SORT_ORDER_LAST_DEFINED',
205         }
206     
207     SORT_ORDER_CANONICAL = SortOrder(1)
208     
209     SORT_ORDER_FLOW = SortOrder(2)
210     
211     SORT_ORDER_INVALID = SortOrder(0)
212     
213     SORT_ORDER_LAST_DEFINED = SortOrder(7)
214     
215     SORT_ORDER_REVERSE_CANONICAL = SortOrder(4)
216     
217     SORT_ORDER_REVERSE_FLOW = SortOrder(5)
218     
219     SORT_ORDER_REVERSE_TAB = SortOrder(6)
220     
221     SORT_ORDER_TAB = SortOrder(3)
222
223     class TreeTraversalType(_Enum):
224         _enum_lookup = {
225             0:'TREE_RESTRICT_CHILDREN',
226             1:'TREE_RESTRICT_SIBLING',
227             2:'TREE_INORDER',
228             3:'TREE_LAST_DEFINED',
229         }
230     
231     TREE_INORDER = TreeTraversalType(2)
232     
233     TREE_LAST_DEFINED = TreeTraversalType(3)
234     
235     TREE_RESTRICT_CHILDREN = TreeTraversalType(0)
236     
237     TREE_RESTRICT_SIBLING = TreeTraversalType(1)
238
239 class Command(list):
240     def __new__(cls, name, id):
241         list.__new__(cls, (name, id))
242     def __init__(self, name, id):
243         list.__init__(self, (name, id))
244     
245     def _get_name(self):
246         return self[0]
247     def _set_name(self, val):
248         self[0] = val
249     name = property(fget=_get_name, fset=_set_name)
250     def _get_id(self):
251         return self[1]
252     def _set_id(self, val):
253         self[1] = val
254     id = property(fget=_get_id, fset=_set_id)
255
256 class CommandListener(_BaseProxy):
257     """
258     An interface which should be implemented by assistive technologies
259     or other clients of the Selector interface, over which notifications
260     to the list of available commands is made. The notifyCommands()
261     method of the client is then called by the Selector instance.
262     """
263     
264     
265     def notifyCommands(self, *args, **kwargs):
266         """
267         Notify the CommandListener instance of changes to the currently
268         available commands, by sending the current CommandList.
269         @param : commands
270         The newly-available list of Command objects which may be invoked
271         by the listener.
272         """
273         func = self.get_dbus_method("notifyCommands")
274         return func(*args, **kwargs)
275
276
277 class Component(_BaseProxy):
278     
279     
280     """
281     The Component interface is implemented by objects which occupy
282     on-screen space, e.g. objects which have onscreen visual representations.
283     The methods in Component allow clients to identify where the
284     objects lie in the onscreen coordinate system, their relative
285     size, stacking order, and position. It also provides a mechanism
286     whereby keyboard focus may be transferred to specific user interface
287     elements programmatically. This is a 2D API, coordinates of 3D
288     objects are projected into the 2-dimensional screen view for
289     purposes of this interface.
290     """
291     
292     
293     def contains(self, *args, **kwargs):
294         """
295         @return True if the specified point lies within the Component's
296         bounding box, False otherwise.
297         """
298         func = self.get_dbus_method("contains")
299         return func(*args, **kwargs)
300     
301     def deregisterFocusHandler(self, *args, **kwargs):
302         """
303         Request that an EventListener registered via registerFocusHandler
304         no longer be notified when this object receives keyboard focus.
305         """
306         func = self.get_dbus_method("deregisterFocusHandler")
307         return func(*args, **kwargs)
308     
309     def getAccessibleAtPoint(self, *args, **kwargs):
310         """
311         @return the Accessible child whose bounding box contains the
312         specified point.
313         """
314         func = self.get_dbus_method("getAccessibleAtPoint")
315         return func(*args, **kwargs)
316     
317     def getAlpha(self, *args, **kwargs):
318         """
319         Obtain the alpha value of the component. An alpha value of 1.0
320         or greater indicates that the object is fully opaque, and an
321         alpha value of 0.0 indicates that the object is fully transparent.
322         Negative alpha values have no defined meaning at this time.
323         """
324         func = self.get_dbus_method("getAlpha")
325         return func(*args, **kwargs)
326     
327     def getExtents(self, *args, **kwargs):
328         """
329         Obtain the Component's bounding box, in pixels, relative to the
330         specified coordinate system. 
331         @return a BoundingBox which entirely contains the object's onscreen
332         visual representation.
333         """
334         func = self.get_dbus_method("getExtents")
335         return func(*args, **kwargs)
336     
337     def getLayer(self, *args, **kwargs):
338         """
339         @return the ComponentLayer in which this object resides.
340         """
341         func = self.get_dbus_method("getLayer")
342         return func(*args, **kwargs)
343     
344     def getMDIZOrder(self, *args, **kwargs):
345         """
346         Obtain the relative stacking order (i.e. 'Z' order) of an object.
347         Larger values indicate that an object is on "top" of the stack,
348         therefore objects with smaller MDIZOrder may be obscured by objects
349         with a larger MDIZOrder, but not vice-versa. 
350         @return an integer indicating the object's place in the stacking
351         order.
352         """
353         func = self.get_dbus_method("getMDIZOrder")
354         return func(*args, **kwargs)
355     
356     def getPosition(self, *args, **kwargs):
357         """
358         Obtain the position of the current component in the coordinate
359         system specified by coord_type. 
360         @param : coord_type
361         @param : x
362         an out parameter which will be back-filled with the returned
363         x coordinate. 
364         @param : y
365         an out parameter which will be back-filled with the returned
366         y coordinate.
367         """
368         func = self.get_dbus_method("getPosition")
369         return func(*args, **kwargs)
370     
371     def getSize(self, *args, **kwargs):
372         """
373         Obtain the size, in the coordinate system specified by coord_type,
374         of the rectangular area which fully contains the object's visual
375         representation, without accounting for viewport clipping. 
376         @param : width
377         the object's horizontal extents in the specified coordinate system.
378         @param : height
379         the object's vertical extents in the specified coordinate system.
380         """
381         func = self.get_dbus_method("getSize")
382         return func(*args, **kwargs)
383     
384     def grabFocus(self, *args, **kwargs):
385         """
386         Request that the object obtain keyboard focus.
387         @return True if keyboard focus was successfully transferred to
388         the Component.
389         """
390         func = self.get_dbus_method("grabFocus")
391         return func(*args, **kwargs)
392     
393     def registerFocusHandler(self, *args, **kwargs):
394         """
395         Register an EventListener for notification when this object receives
396         keyboard focus.
397         """
398         func = self.get_dbus_method("registerFocusHandler")
399         return func(*args, **kwargs)
400     
401     def unImplemented(self, *args, **kwargs):
402         func = self.get_dbus_method("unImplemented")
403         return func(*args, **kwargs)
404     
405     def unImplemented2(self, *args, **kwargs):
406         func = self.get_dbus_method("unImplemented2")
407         return func(*args, **kwargs)
408     
409     def unImplemented3(self, *args, **kwargs):
410         func = self.get_dbus_method("unImplemented3")
411         return func(*args, **kwargs)
412
413
414 class ComponentLayer(_Enum):
415     _enum_lookup = {
416         0:'LAYER_INVALID',
417         1:'LAYER_BACKGROUND',
418         2:'LAYER_CANVAS',
419         3:'LAYER_WIDGET',
420         4:'LAYER_MDI',
421         5:'LAYER_POPUP',
422         6:'LAYER_OVERLAY',
423         7:'LAYER_WINDOW',
424         8:'LAYER_LAST_DEFINED',
425     }
426
427
428 class ContentStream(_BaseProxy):
429     """
430     An interface by which the requested data from a StreamableContent
431     object may be read by the client.
432     """
433     
434     def close(self, *args, **kwargs):
435         """
436         close the stream and release associated resources. A client should
437         not perform further operations on a StreamableContent::Stream
438         object after closing it.
439         """
440         func = self.get_dbus_method("close")
441         return func(*args, **kwargs)
442     
443     def read(self, *args, **kwargs):
444         """
445         Request/read a specified amount of data from a Stream. 
446         @return the number of bytes actually read into the client buffer.
447         """
448         func = self.get_dbus_method("read")
449         return func(*args, **kwargs)
450     
451     def seek(self, *args, **kwargs):
452         """
453         Seek to a specified position in the Stream. 
454         @param : offset
455         an offset specifying the requested position in the stream, relative
456         to the SeekType specified in whence. 
457         @param : whence
458         a SeekType specifying the reference point from which the seek
459         offset is calculated. Some forms of seek are not supported by
460         certain implementations of Stream, in which case a NotSupported
461         exception will be raised. 
462         @return the actual resulting offset, if no exception was raised.
463         """
464         func = self.get_dbus_method("seek")
465         return func(*args, **kwargs)
466     
467     def unimplemented(self, *args, **kwargs):
468         """
469         /cond
470         """
471         func = self.get_dbus_method("unimplemented")
472         return func(*args, **kwargs)
473     
474     def unimplemented2(self, *args, **kwargs):
475         func = self.get_dbus_method("unimplemented2")
476         return func(*args, **kwargs)
477     
478     class IOError(Exception):
479         pass
480     
481     class NoPermission(Exception):
482         pass
483     
484     class NotSupported(Exception):
485         pass
486
487     class SeekType(_Enum):
488         """
489         Specifies the meaning of a seek 'offset'. Not all SeekTypes are
490         supported by all StreamableContent data sources, for instance
491         some streams may not support seeking from the beginning or other
492         types of 'backwards' seeks.
493         """
494         _enum_lookup = {
495             0:'SEEK_SET',
496             1:'SEEK_CURRENT',
497             2:'SEEK_END',
498         }
499     
500     SEEK_CURRENT = SeekType(1)
501     
502     SEEK_END = SeekType(2)
503     
504     SEEK_SET = SeekType(0)
505
506 class DeviceEvent(list):
507     def __new__(cls, type, id, hw_code, modifiers, timestamp, event_string, is_text):
508         list.__new__(cls, (type, id, hw_code, modifiers, timestamp, event_string, is_text))
509     def __init__(self, type, id, hw_code, modifiers, timestamp, event_string, is_text):
510         list.__init__(self, (type, id, hw_code, modifiers, timestamp, event_string, is_text))
511     
512     def _get_type(self):
513         return self[0]
514     def _set_type(self, val):
515         self[0] = val
516     type = property(fget=_get_type, fset=_set_type)
517     def _get_id(self):
518         return self[1]
519     def _set_id(self, val):
520         self[1] = val
521     id = property(fget=_get_id, fset=_set_id)
522     def _get_hw_code(self):
523         return self[2]
524     def _set_hw_code(self, val):
525         self[2] = val
526     hw_code = property(fget=_get_hw_code, fset=_set_hw_code)
527     def _get_modifiers(self):
528         return self[3]
529     def _set_modifiers(self, val):
530         self[3] = val
531     modifiers = property(fget=_get_modifiers, fset=_set_modifiers)
532     def _get_timestamp(self):
533         return self[4]
534     def _set_timestamp(self, val):
535         self[4] = val
536     timestamp = property(fget=_get_timestamp, fset=_set_timestamp)
537     def _get_event_string(self):
538         return self[5]
539     def _set_event_string(self, val):
540         self[5] = val
541     event_string = property(fget=_get_event_string, fset=_set_event_string)
542     def _get_is_text(self):
543         return self[6]
544     def _set_is_text(self, val):
545         self[6] = val
546     is_text = property(fget=_get_is_text, fset=_set_is_text)
547
548 class DeviceEventController(_BaseProxy):
549     """
550     The interface via which clients request notification of device
551     events, and through which device events may be simulated.
552     """
553
554     def deregisterDeviceEventListener(self, *args, **kwargs):
555         """
556         De-register a previously registered keyboard eventlistener. 
557         @param : listener
558         a DeviceEventListener which will intercept events. 
559         @param : typeseq
560         an EventTypeSeq indicating which event types to stop listening
561         for.
562         """
563         func = self.get_dbus_method("deregisterDeviceEventListener")
564         return func(*args, **kwargs)
565     
566     def deregisterKeystrokeListener(self, *args, **kwargs):
567         """
568         De-register a previously registered keyboard eventlistener. 
569         @param : listener
570         a DeviceEventListener which will intercept key events. 
571         @param : keys
572         a KeySet indicating which keys to intercept, or KEYSET_ALL_KEYS.
573         @param : mask
574         a ControllerEventMask filtering the intercepted key events. 
575         @param : type
576         an EventType mask that may created by ORing event types together.
577         """
578         func = self.get_dbus_method("deregisterKeystrokeListener")
579         return func(*args, **kwargs)
580     
581     def generateKeyboardEvent(self, *args, **kwargs):
582         """
583         Synthesize a keyboard event. 
584         @param : keycode
585         a long integer indicating the keycode of the keypress to be synthesized.
586         @param : keystring
587         an optional UTF-8 string indicating a complex keyboard input
588         event. 
589         @param : type
590         a KeySynthType indicating the type of event(s) to be synthesized:
591         a key press, release, press-release pair, or a complex input
592         string (for instance from an internationalized or complex text
593         input method, or a composed character).
594         """
595         func = self.get_dbus_method("generateKeyboardEvent")
596         return func(*args, **kwargs)
597     
598     def generateMouseEvent(self, *args, **kwargs):
599         """
600         Synthesize a mouse event. 
601         @param : x
602         a long integer indicating the screen x coord for the mouse event.
603         @param : y
604         a long integer indicating the screen y coord for the mouse event.
605         @param : eventName
606         a string indicating the type of mouse event, e.g. "button1up"
607         """
608         func = self.get_dbus_method("generateMouseEvent")
609         return func(*args, **kwargs)
610     
611     def notifyListenersAsync(self, *args, **kwargs):
612         """
613         Notify the Registry instance that a device event has taken place
614         in an asynchronous manner. This is the method used by accessibility
615         bridges to forward "toolkit dependent" device events to the Registry
616         from the application's process space. If the event in question
617         is potentially pre-emptible. notifyListenersSync should be used
618         instead.
619         """
620         func = self.get_dbus_method("notifyListenersAsync")
621         return func(*args, **kwargs)
622     
623     def notifyListenersSync(self, *args, **kwargs):
624         """
625         Notify the Registry instance that a device event has taken place,
626         and allow pre-emptive listeners the opportunity to 'consume'
627         the event and thus prevent its further issuance/forwarding. This
628         is the method used by accessibility bridges to forward "toolkit
629         dependent" device events to the Registry from the application's
630         process space.
631         @return True if the event was consumed by a (pre-emptive) listener,
632         False if not (in which case the device event will be forwarded
633         as normal to any application which would normally receive it,
634         e.g. the currently active application in the case of mouse or
635         keyboard events).
636         """
637         func = self.get_dbus_method("notifyListenersSync")
638         return func(*args, **kwargs)
639     
640     def registerDeviceEventListener(self, *args, **kwargs):
641         """
642         Register to intercept events, and either pass them on or consume
643         them. To listen to keyboard events use registerKeystrokeListener
644         instead. 
645         @param : listener
646         a DeviceEventListener which will intercept events. 
647         @param : typeseq
648         an EventTypeSeq indicating which event types to listen for. 
649         @return True if successful, False if not
650         """
651         func = self.get_dbus_method("registerDeviceEventListener")
652         return func(*args, **kwargs)
653     
654     def registerKeystrokeListener(self, *args, **kwargs):
655         """
656         Register to intercept keyboard events, and either pass them on
657         or consume them.
658         @param : listener
659         a DeviceEventListener which will intercept key events. 
660         @param : keys
661         a KeySet indicating which keys to intercept, or KEYSET_ALL_KEYS.
662         @param : mask
663         a ControllerEventMask filtering the intercepted key events. 
664         @param : type
665         a KeyEventTypeSeq that may created by ORing event types together.
666         @param : mode
667         an EventListenerMode indicating whether the listener should receive
668         the events synchronously, potentially consuming them, or just
669         be notified asynchronously of those events that have been generated.
670         @return True if the DeviceEventListener was successfully registered
671         for the requested KeySet, ControllerEventMask, event types, and
672         EventListenerMode; otherwise returns False.
673         """
674         func = self.get_dbus_method("registerKeystrokeListener")
675         return func(*args, **kwargs)
676     
677 class DeviceEventListener(_BaseProxy):
678     """
679     This interface should be implemented by AT-SPI clients who wish
680     to make use of the DeviceEventController to receive device event
681     notifications. DeviceEvents include keyboard events and mouse
682     button/motion events.
683     """
684     
685     def notifyEvent(self, *args, **kwargs):
686         """
687         Notify an interested DeviceEventListener that a DeviceEvent has
688         occurred. 
689         @return True if the recipient/consumer wishes to consume the
690         event, i.e. prevent it from being delivered to the desktop, False
691         if the event should continue to be delivered as normal.
692         """
693         func = self.get_dbus_method("notifyEvent")
694         return func(*args, **kwargs)
695     
696 class Document(_BaseProxy):
697     """
698     Primarily a 'tagging' interface which indicates the start of
699     document content in the Accessibility hierarchy. Accessible objects
700     below the node implementing Document are normally assumed to
701     be part of the document content. Attributes of Document are those
702     attributes associated with the document as a whole. Objects that
703     implement Document are normally expected to implement Collection
704     as well.
705     """
706     
707     def getAttributeValue(self, *args, **kwargs):
708         """
709         Gets the value of a single attribute, if specified for the document
710         as a whole.
711         @param : attributename
712         a string indicating the name of a specific attribute (name-value
713         pair) being queried.
714         @return a string corresponding to the value of the specified
715         attribute, or an empty string if the attribute is unspecified
716         for the object.
717         """
718         func = self.get_dbus_method("getAttributeValue")
719         return func(*args, **kwargs)
720     
721     def getAttributes(self, *args, **kwargs):
722         """
723         Gets all attributes specified for a document as a whole. For
724         attributes which change within the document content, see Accessibility::Text::getAttributes
725         instead.
726         @return an AttributeSet containing the attributes of the document,
727         as name-value pairs.
728         """
729         func = self.get_dbus_method("getAttributes")
730         return func(*args, **kwargs)
731     
732     def getLocale(self, *args, **kwargs):
733         """
734         Gets the locale associated with the document's content. e.g.
735         the locale for LOCALE_TYPE_MESSAGES.
736         @return a string compliant with the POSIX standard for locale
737         description.
738         """
739         func = self.get_dbus_method("getLocale")
740         return func(*args, **kwargs)
741     
742     def unImplemented2_(self, *args, **kwargs):
743         func = self.get_dbus_method("unImplemented2_")
744         return func(*args, **kwargs)
745     
746     def unImplemented3_(self, *args, **kwargs):
747         func = self.get_dbus_method("unImplemented3_")
748         return func(*args, **kwargs)
749     
750     def unImplemented4_(self, *args, **kwargs):
751         func = self.get_dbus_method("unImplemented4_")
752         return func(*args, **kwargs)
753     
754     def unImplemented_(self, *args, **kwargs):
755         func = self.get_dbus_method("unImplemented_")
756         return func(*args, **kwargs)
757
758 class Text(_BaseProxy):
759     """
760     The text interface should be implemented by objects which place
761     textual information onscreen as character strings or glyphs.
762     The text interface allows access to textual content, including
763     display attributes and semantic hints associated with runs of
764     text, and access to bounding box information for glyphs and substrings.
765     It also allows portions of textual content to be selected, if
766     the object's StateSet includes STATE_SELECTABLE_TEXT.
767     In some cases a Text object may have, as its content, an empty
768     string. In particular this can occur in the case of Hypertext
769     objects which do not display explicitly textual information onscreen,
770     as Hypertext is derived from the Text interface. 
771     Typographic and semantic attributes of onscreen textual content,
772     for instance typeface, weight, language, and such qualities as
773     'emphasis' or 'blockquote', are represented as text attributes.
774     Contiguous sequences of characters over which these attributes
775     are unchanged are referred to as "attribute runs", and are available
776     via Text::getAttributeRun. Where possible, implementing clients
777     will report textual attributes which are the same over the entire
778     text object, for instance those inherited from a default or document-scope
779     style, via getDefaultAttributes instead of reporting them explicitly
780     for each character. Therefore, for any span of text, the attributes
781     in effect are the union of the set returned by Text::getDefaultAttributes,
782     and the set returned at a particular character offset via Text::getAttributeRun.
783     """
784     
785     
786     def addSelection(self, *args, **kwargs):
787         """
788         The result of calling addSelection on objects which already have
789         one selection present, and which do not include STATE_MULTISELECTABLE,
790         is undefined, other than the return value. 
791         @return True of the selection was successfully added, False otherwise.
792         Selection may fail if the object does not support selection of
793         text (see STATE_SELECTABLE_TEXT), if the object does not support
794         multiple selections and a selection is already defined, or for
795         other reasons (for instance if the user does not have permission
796         to copy the text into the relevant selection buffer).
797         """
798         func = self.get_dbus_method("addSelection")
799         return func(*args, **kwargs)
800     
801     def getAttributeRun(self, *args, **kwargs):
802         """
803         Query a particular text object for the text attributes defined
804         at a given offset, obtaining the start and end of the "attribute
805         run" over which these attributes are currently invariant. Text
806         attributes are those presentational, typographic, or semantic
807         attributes or qualitites which apply to a range of text specifyable
808         by starting and ending offsets. Attributes relevant to localization
809         should be provided in accordance with the w3c "Internationalization
810         and Localization Markup Requirements", http://www.w3.org/TR/2005/WD-itsreq-20051122/
811         Other text attributes should choose their names and value semantics
812         in accordance with relevant standards such as CSS level 2 (http://www.w3.org/TR/1998/REC-CSS2-19980512),
813         XHTML 1.0 (http://www.w3.org/TR/2002/REC-xhtml1-20020801), and
814         WICD (http://www.w3.org/TR/2005/WD-WICD-20051121/). Those attributes
815         from the aforementioned specifications and recommendations which
816         do not concern typographic, presentational, or semantic aspects
817         of text should be exposed via the more general Accessible::getAttributes()
818         API (if at all).
819         For example, CSS attributes which should be exposed on text (either
820         as default attributes, or as explicitly-set attributes when non-default
821         values are specified in the content view) include the Font attributes
822         (i.e. "css2:font-weight", "css2:font-style"), the "css2:color"
823         and "css2:background-color" attributes, and "css2:text-decoration"
824         attribute.
825         If includeDefaults is TRUE, then this AttributeSet should include
826         the default attributes as well as those which are explicitly
827         assigned to the attribute run in question. startOffset and endOffset
828         will be back-filled to indicate the start and end of the attribute
829         run which contains 'offset' - an attribute run is a contiguous
830         section of text whose attributes are homogeneous. 
831         @param : offset
832         the offset of the character whose attributes will be reported.
833         @param : startOffset
834         backfilled with the starting offset of the character range over
835         which all text attributes match those of offset, i.e. the start
836         of the homogeneous attribute run including offset. 
837         @param : endOffset
838         backfilled with the offset of the first character past the character
839         range over which all text attributes match those of offset, i.e.
840         the character immediately after the homogeneous attribute run
841         including offset. 
842         @param : includeDefaults
843         if False, the call should only return those attributes which
844         are explicitly set on the current attribute run, omitting any
845         attributes which are inherited from the default values. See also
846         Text::getDefaultAttributes.
847         @return the AttributeSet defined at offset, optionally including
848         the 'default' attributes.
849         """
850         func = self.get_dbus_method("getAttributeRun")
851         return func(*args, **kwargs)
852     
853     def getAttributeValue(self, *args, **kwargs):
854         """
855         Get the string value of a named attribute at a given offset,
856         if defined. 
857         @param : offset
858         the offset of the character for which the attribute run is to
859         be obtained. 
860         @param : attributeName
861         the name of the attribute for which the value is to be returned,
862         if defined. 
863         @param : startOffset
864         back-filled with the offset of the first character in the attribute
865         run containing the character at offset. 
866         @param : endOffset
867         back-filled with the offset of the first character past the end
868         of the attribute run containing the character at offset. 
869         @param : defined
870         back-filled with True if the attributeName has a defined value
871         at offset, False otherwise. 
872         @return the value of attribute (name-value pair) corresponding
873         to "name", if defined.
874         """
875         func = self.get_dbus_method("getAttributeValue")
876         return func(*args, **kwargs)
877     
878     def getAttributes(self, *args, **kwargs):
879         """
880         getAttributes is deprecated in favor of getAttributeRun. 
881         @return the attributes at offset, as a semicolon-delimited set
882         of colon-delimited name-value pairs.
883         """
884         func = self.get_dbus_method("getAttributes")
885         return func(*args, **kwargs)
886     
887     def getBoundedRanges(self, *args, **kwargs):
888         """
889         Return the text content within a bounding box, as a list of Range
890         structures. Depending on the TEXT_CLIP_TYPE parameters, glyphs
891         which are clipped by the bounding box (i.e. which lie partially
892         inside and partially outside it) may or may not be included in
893         the ranges returned. 
894         @param : x
895         the minimum x ( i.e. leftmost) coordinate of the bounding box.
896         @param : y
897         the minimum y coordinate of the bounding box. 
898         @param : width
899         the horizontal size of the bounding box. The rightmost bound
900         of the bounding box is (x + width); 
901         @param : height
902         the vertical size of the bounding box. The maximum y value of
903         the bounding box is (y + height); 
904         @param : coordType
905         If 0, the above coordinates are interpreted as pixels relative
906         to corner of the screen; if 1, the coordinates are interpreted
907         as pixels relative to the corner of the containing toplevel window.
908         @param : xClipType
909         determines whether text which intersects the bounding box in
910         the x direction is included. 
911         @param : yClipType
912         determines whether text which intersects the bounding box in
913         the y direction is included.
914         """
915         func = self.get_dbus_method("getBoundedRanges")
916         return func(*args, **kwargs)
917     
918     def getCharacterAtOffset(self, *args, **kwargs):
919         """
920         @return an unsigned long integer whose value corresponds to the
921         UCS-4 representation of the character at the specified text offset,
922         or 0 if offset is out of range.
923         """
924         func = self.get_dbus_method("getCharacterAtOffset")
925         return func(*args, **kwargs)
926     
927     def getCharacterExtents(self, *args, **kwargs):
928         """
929         Obtain a the bounding box, as x, y, width, and height, of the
930         character or glyph at a particular character offset in this object's
931         text content. The coordinate system in which the results are
932         reported is specified by coordType. If an onscreen glyph corresponds
933         to multiple character offsets, for instance if the glyph is a
934         ligature, the bounding box reported will include the entire glyph
935         and therefore may apply to more than one character offset. 
936         @param : offset
937         the character offset of the character or glyph being queried.
938         @param : x
939         the minimum horizontal coordinate of the bounding box of the
940         glyph representing the character at offset. 
941         @param : y
942         the minimum vertical coordinate of the bounding box of the glyph
943         representing the character at offset. 
944         @param : width
945         the horizontal extent of the bounding box of the glyph representing
946         the character at offset. 
947         @param : height
948         the vertical extent of the bounding box of the glyph representing
949         the character at offset. 
950         @param : coordType
951         If 0, the results will be reported in screen coordinates, i.e.
952         in pixels relative to the upper-left corner of the screen, with
953         the x axis pointing right and the y axis pointing down. If 1,
954         the results will be reported relative to the containing toplevel
955         window, with the x axis pointing right and the y axis pointing
956         down.
957         """
958         func = self.get_dbus_method("getCharacterExtents")
959         return func(*args, **kwargs)
960     
961     def getDefaultAttributeSet(self, *args, **kwargs):
962         """
963         Return an AttributeSet containing the text attributes which apply
964         to all text in the object by virtue of the default settings of
965         the document, view, or user agent; e.g. those attributes which
966         are implied rather than explicitly applied to the text object.
967         For instance, an object whose entire text content has been explicitly
968         marked as 'bold' will report the 'bold' attribute via getAttributeRun(),
969         whereas an object whose text weight is inspecified may report
970         the default or implied text weight in the default AttributeSet.
971         """
972         func = self.get_dbus_method("getDefaultAttributeSet")
973         return func(*args, **kwargs)
974     
975     def getDefaultAttributes(self, *args, **kwargs):
976         """
977         Deprecated in favor of getDefaultAttributeSet. 
978         @return the attributes which apply to the entire text content,
979         but which were not explicitly specified by the content creator.
980         """
981         func = self.get_dbus_method("getDefaultAttributes")
982         return func(*args, **kwargs)
983     
984     def getNSelections(self, *args, **kwargs):
985         """
986         Obtain the number of separate, contiguous selections in the current
987         Text object. Text objects which do not implement selection of
988         discontiguous text regions will always return '0' or '1'. Note
989         that "contiguous" is defined by continuity of the offsets, i.e.
990         a text 'selection' is defined by a start/end offset pair. In
991         the case of bidirectional text, this means that a continguous
992         selection may appear visually discontiguous, and vice-versa.
993         @return the number of contiguous selections in the current Text
994         object.
995         """
996         func = self.get_dbus_method("getNSelections")
997         return func(*args, **kwargs)
998     
999     def getOffsetAtPoint(self, *args, **kwargs):
1000         """
1001         Get the offset of the character at a given onscreen coordinate.
1002         The coordinate system used to interpret x and y is determined
1003         by parameter coordType. 
1004         @param : x
1005         @param : y
1006         @param : coordType
1007         if 0, the input coordinates are interpreted relative to the entire
1008         screen, if 1, they are relative to the toplevel window containing
1009         this Text object. 
1010         @return the text offset (as an offset into the character array)
1011         of the glyph whose onscreen bounds contain the point x,y, or
1012         -1 if the point is outside the bounds of any glyph.
1013         """
1014         func = self.get_dbus_method("getOffsetAtPoint")
1015         return func(*args, **kwargs)
1016     
1017     def getRangeExtents(self, *args, **kwargs):
1018         """
1019         Obtain the bounding box which entirely contains a given text
1020         range. Negative values may be returned for the bounding box parameters
1021         in the event that all or part of the text range is offscreen
1022         or not mapped to the screen. 
1023         @param : startOffset
1024         the offset of the first character in the specified range. 
1025         @param : endOffset
1026         the offset of the character immediately after the last character
1027         in the specified range. 
1028         @param : x
1029         an integer parameter which is back-filled with the minimum horizontal
1030         coordinate of the resulting bounding box. 
1031         @param : y
1032         an integer parameter which is back-filled with the minimum vertical
1033         coordinate of the resulting bounding box. 
1034         @param : width
1035         an integer parameter which is back-filled with the horizontal
1036         extent of the bounding box. 
1037         @param : height
1038         an integer parameter which is back-filled with the vertical extent
1039         of the bounding box. 
1040         @param : coordType
1041         If 0, the above coordinates are reported in pixels relative to
1042         corner of the screen; if 1, the coordinates are reported relative
1043         to the corner of the containing toplevel window.
1044         """
1045         func = self.get_dbus_method("getRangeExtents")
1046         return func(*args, **kwargs)
1047     
1048     def getSelection(self, *args, **kwargs):
1049         """
1050         The result of calling getSelection with an out-of-range selectionNum
1051         (i.e. for a selection which does not exist) is not strictly defined,
1052         but should set endOffset equal to startOffset.
1053         """
1054         func = self.get_dbus_method("getSelection")
1055         return func(*args, **kwargs)
1056     
1057     def getText(self, *args, **kwargs):
1058         """
1059         Obtain all or part of the onscreen textual content of a Text
1060         object. If endOffset is specified as "-1", then this method will
1061         return the entire onscreen textual contents of the Text object.
1062         @return the textual content of the current Text object beginning
1063         startOffset (inclusive) up to but not including the character
1064         at endOffset.
1065         """
1066         func = self.get_dbus_method("getText")
1067         return func(*args, **kwargs)
1068     
1069     def getTextAfterOffset(self, *args, **kwargs):
1070         """
1071         Obtain a subset of the text content of an object which entirely
1072         follows offset, delimited by character, word, line, or sentence
1073         boundaries as specified by type. The starting and ending offsets
1074         of the resulting substring are returned in startOffset and endOffset.
1075         By definition, if such a substring exists, startOffset must be
1076         greater than offset. 
1077         @param : offset
1078         the offset from which the substring search begins, and which
1079         must lie before the returned substring. 
1080         @param : type
1081         the text-boundary delimiter which determines whether the returned
1082         text constitures a character, word, line, or sentence (and possibly
1083         attendant whitespace), and whether the start or ending of such
1084         a substring forms the boundary condition. 
1085         @param : startOffset
1086         back-filled with the starting offset of the resulting substring,
1087         if one exists. 
1088         @param : endOffset
1089         back-filled with the offset of the character immediately following
1090         the resulting substring, if one exists. 
1091         @return a string which is a substring of the text content of
1092         the object, delimited by the specified boundary condition.
1093         """
1094         func = self.get_dbus_method("getTextAfterOffset")
1095         return func(*args, **kwargs)
1096     
1097     def getTextAtOffset(self, *args, **kwargs):
1098         """
1099         Obtain a subset of the text content of an object which includes
1100         the specified offset, delimited by character, word, line, or
1101         sentence boundaries as specified by type. The starting and ending
1102         offsets of the resulting substring are returned in startOffset
1103         and endOffset. 
1104         @param : offset
1105         the offset from which the substring search begins, and which
1106         must lie within the returned substring. 
1107         @param : type
1108         the text-boundary delimiter which determines whether the returned
1109         text constitures a character, word, line, or sentence (and possibly
1110         attendant whitespace), and whether the start or ending of such
1111         a substring forms the boundary condition. 
1112         @param : startOffset
1113         back-filled with the starting offset of the resulting substring,
1114         if one exists. 
1115         @param : endOffset
1116         back-filled with the offset of the character immediately following
1117         the resulting substring, if one exists. 
1118         @return a string which is a substring of the text content of
1119         the object, delimited by the specified boundary condition.
1120         """
1121         func = self.get_dbus_method("getTextAtOffset")
1122         return func(*args, **kwargs)
1123     
1124     def getTextBeforeOffset(self, *args, **kwargs):
1125         """
1126         Obtain a subset of the text content of an object which entirely
1127         precedes offset, delimited by character, word, line, or sentence
1128         boundaries as specified by type. The starting and ending offsets
1129         of the resulting substring are returned in startOffset and endOffset.
1130         By definition, if such a substring exists, endOffset is less
1131         than or equal to offset. 
1132         @param : offset
1133         the offset from which the substring search begins. 
1134         @param : type
1135         the text-boundary delimiter which determines whether the returned
1136         text constitures a character, word, line, or sentence (and possibly
1137         attendant whitespace), and whether the start or ending of such
1138         a substring forms the boundary condition. 
1139         @param : startOffset
1140         back-filled with the starting offset of the resulting substring,
1141         if one exists. 
1142         @param : endOffset
1143         back-filled with the offset of the character immediately following
1144         the resulting substring, if one exists. 
1145         @return a string which is a substring of the text content of
1146         the object, delimited by the specified boundary condition.
1147         """
1148         func = self.get_dbus_method("getTextBeforeOffset")
1149         return func(*args, **kwargs)
1150     
1151     def removeSelection(self, *args, **kwargs):
1152         """
1153         Deselect the text contained in the specified selectionNum, if
1154         such a selection exists, otherwise do nothing. Removal of a non-existant
1155         selectionNum has no effect. 
1156         @return True if the selection was successfully removed, False
1157         otherwise.
1158         """
1159         func = self.get_dbus_method("removeSelection")
1160         return func(*args, **kwargs)
1161     
1162     def setCaretOffset(self, *args, **kwargs):
1163         """
1164         Programmatically move the text caret (visible or virtual, as
1165         above) to a given position. 
1166         @param : offset
1167         a long int indicating the desired character offset. Not all implementations
1168         of Text will honor setCaretOffset requests, so the return value
1169         below should be checked by the client. 
1170         @return TRUE if the request was carried out, or FALSE if the
1171         caret could not be moved to the requested position.
1172         """
1173         func = self.get_dbus_method("setCaretOffset")
1174         return func(*args, **kwargs)
1175     
1176     def setSelection(self, *args, **kwargs):
1177         """
1178         Modify an existing selection's start or ending offset.
1179         Calling setSelection for a selectionNum that is not already defined
1180         has no effect. The result of calling setSelection with a selectionNum
1181         greater than 0 for objects that do not include STATE_MULTISELECTABLE
1182         is undefined. 
1183         @param : selectionNum
1184         indicates which of a set of non-contiguous selections to modify.
1185         @param : startOffset
1186         the new starting offset for the selection 
1187         @param : endOffset
1188         the new ending offset for the selection 
1189         @return True if the selection corresponding to selectionNum is
1190         successfully modified, False otherwise.
1191         """
1192         func = self.get_dbus_method("setSelection")
1193         return func(*args, **kwargs)
1194
1195     def get_caretOffset(self):
1196         self._pgetter(self._dbus_interface, "caretOffset")
1197     def set_caretOffset(self, value):
1198         self._psetter(self._dbus_interface, "caretOffset", value)
1199     _caretOffsetDoc = \
1200         """
1201         The current offset of the text caret in the Text object. This
1202         caret may be virtual, e.g. non-visual and notional-only, but
1203         if an onscreen representation of the caret position is visible,
1204         it will correspond to this offset. The caret offset is given
1205         as a character offset, as opposed to a byte offset into a text
1206         buffer or a column offset.
1207         """
1208     caretOffset = property(fget=get_caretOffset, fset=set_caretOffset, doc=_caretOffsetDoc)
1209     
1210     def get_characterCount(self):
1211         self._pgetter(self._dbus_interface, "characterCount")
1212     def set_characterCount(self, value):
1213         self._psetter(self._dbus_interface, "characterCount", value)
1214     _characterCountDoc = \
1215         """
1216         The total current number of characters in the Text object, including
1217         whitespace and non-spacing characters.
1218         """
1219     characterCount = property(fget=get_characterCount, fset=set_characterCount, doc=_characterCountDoc)
1220     
1221     class Range(list):
1222         def __new__(cls, startOffset, endOffset, content, data):
1223             list.__new__(cls, (startOffset, endOffset, content, data))
1224         def __init__(self, startOffset, endOffset, content, data):
1225             list.__init__(self, (startOffset, endOffset, content, data))
1226         
1227         def _get_startOffset(self):
1228             return self[0]
1229         def _set_startOffset(self, val):
1230             self[0] = val
1231         startOffset = property(fget=_get_startOffset, fset=_set_startOffset)
1232         def _get_endOffset(self):
1233             return self[1]
1234         def _set_endOffset(self, val):
1235             self[1] = val
1236         endOffset = property(fget=_get_endOffset, fset=_set_endOffset)
1237         def _get_content(self):
1238             return self[2]
1239         def _set_content(self, val):
1240             self[2] = val
1241         content = property(fget=_get_content, fset=_set_content)
1242         def _get_data(self):
1243             return self[3]
1244         def _set_data(self, val):
1245             self[3] = val
1246         data = property(fget=_get_data, fset=_set_data)
1247
1248
1249 class EditableText(Text):
1250     """
1251     Derived from interface Text, EditableText provides methods for
1252     modifying textual content of components which support editing.
1253     EditableText also interacts with the system clipboard via copyText,
1254     cutText, and pasteText.
1255     """
1256     
1257     def copyText(self, *args, **kwargs):
1258         """
1259         Copy a range of text into the system clipboard. 
1260         @param : startPos
1261         the character offset of the first character in the range of text
1262         being copied. 
1263         @param : endPos
1264         the offset of the first character past the end of the range of
1265         text being copied.
1266         """
1267         func = self.get_dbus_method("copyText")
1268         return func(*args, **kwargs)
1269     
1270     def cutText(self, *args, **kwargs):
1271         """
1272         Excise a range of text from a Text object, copying it into the
1273         system clipboard. 
1274         @param : startPos
1275         the character offset of the first character in the range of text
1276         being cut. 
1277         @param : endPos
1278         the offset of the first character past the end of the range of
1279         text being cut. 
1280         @return True if the text was successfully cut, False otherwise.
1281         """
1282         func = self.get_dbus_method("cutText")
1283         return func(*args, **kwargs)
1284     
1285     def deleteText(self, *args, **kwargs):
1286         """
1287         Excise a range of text from a Text object without copying it
1288         into the system clipboard. 
1289         @param : startPos
1290         the character offset of the first character in the range of text
1291         being deleted. 
1292         @param : endPos
1293         the offset of the first character past the end of the range of
1294         text being deleted. 
1295         @return True if the text was successfully deleted, False otherwise.
1296         """
1297         func = self.get_dbus_method("deleteText")
1298         return func(*args, **kwargs)
1299     
1300     def insertText(self, *args, **kwargs):
1301         """
1302         Insert new text contents into an existing text object at a given
1303         location, while retaining the old contents. 
1304         @param : position
1305         the character offset into the Text implementor's content at which
1306         the new content will be inserted. 
1307         @param : text
1308         a UTF-8 string of which length characters will be inserted into
1309         the text object's text buffer. 
1310         @param : length
1311         the number of characters of text to insert. If the character
1312         count of text is less than or equal to length, the entire contents
1313         of text will be inserted.
1314         @return True if the text content was successfully inserted, False
1315         otherwise.
1316         """
1317         func = self.get_dbus_method("insertText")
1318         return func(*args, **kwargs)
1319     
1320     def pasteText(self, *args, **kwargs):
1321         """
1322         Copy the text contents of the system clipboard, if any, into
1323         a Text object, inserting it at a particular character offset.
1324         @param : position
1325         the character offset before which the text will be inserted.
1326         @return True if the text was successfully pasted into the Text
1327         object, False otherwise.
1328         """
1329         func = self.get_dbus_method("pasteText")
1330         return func(*args, **kwargs)
1331     
1332     def setAttributes(self, *args, **kwargs):
1333         """
1334         Apply a particular set of attributes to a range of text.
1335         @return True if the text attributes were successfully modified,
1336         False otherwise.
1337         """
1338         func = self.get_dbus_method("setAttributes")
1339         return func(*args, **kwargs)
1340     
1341     def setTextContents(self, *args, **kwargs):
1342         """
1343         Replace the text contents with a new string, discarding the old
1344         contents.
1345         @param : newContents
1346         a UTF-8 string with which the text object's contents will be
1347         replaced. 
1348         @return True if the text content was successfully changed, False
1349         otherwise.
1350         """
1351         func = self.get_dbus_method("setTextContents")
1352         return func(*args, **kwargs)
1353     
1354     def unImplemented10(self, *args, **kwargs):
1355         func = self.get_dbus_method("unImplemented10")
1356         return func(*args, **kwargs)
1357     
1358     def unImplemented11(self, *args, **kwargs):
1359         func = self.get_dbus_method("unImplemented11")
1360         return func(*args, **kwargs)
1361     
1362     def unImplemented12(self, *args, **kwargs):
1363         func = self.get_dbus_method("unImplemented12")
1364         return func(*args, **kwargs)
1365     
1366     def unImplemented5(self, *args, **kwargs):
1367         """
1368         unImplemented:
1369         placeholders for future expansion. Note that these are named
1370         'unimplemented5 and unimplemented6' to avoid conflict with placeholders
1371         from Accessibility::Text.
1372         """
1373         func = self.get_dbus_method("unImplemented5")
1374         return func(*args, **kwargs)
1375     
1376     def unImplemented6(self, *args, **kwargs):
1377         func = self.get_dbus_method("unImplemented6")
1378         return func(*args, **kwargs)
1379     
1380     def unImplemented9(self, *args, **kwargs):
1381         func = self.get_dbus_method("unImplemented9")
1382         return func(*args, **kwargs)
1383
1384 class Event(list):
1385     def __new__(cls, type, source, detail1, detail2, any_data):
1386         list.__new__(cls, (type, source, detail1, detail2, any_data))
1387     def __init__(self, type, source, detail1, detail2, any_data):
1388         list.__init__(self, (type, source, detail1, detail2, any_data))
1389     
1390     def _get_type(self):
1391         return self[0]
1392     def _set_type(self, val):
1393         self[0] = val
1394     type = property(fget=_get_type, fset=_set_type)
1395     def _get_source(self):
1396         return self[1]
1397     def _set_source(self, val):
1398         self[1] = val
1399     source = property(fget=_get_source, fset=_set_source)
1400     def _get_detail1(self):
1401         return self[2]
1402     def _set_detail1(self, val):
1403         self[2] = val
1404     detail1 = property(fget=_get_detail1, fset=_set_detail1)
1405     def _get_detail2(self):
1406         return self[3]
1407     def _set_detail2(self, val):
1408         self[3] = val
1409     detail2 = property(fget=_get_detail2, fset=_set_detail2)
1410     def _get_any_data(self):
1411         return self[4]
1412     def _set_any_data(self, val):
1413         self[4] = val
1414     any_data = property(fget=_get_any_data, fset=_set_any_data)
1415
1416
1417 class EventDetails(list):
1418     def __new__(cls, host_application, source_role, source_name, any_data):
1419         list.__new__(cls, (host_application, source_role, source_name, any_data))
1420     def __init__(self, host_application, source_role, source_name, any_data):
1421         list.__init__(self, (host_application, source_role, source_name, any_data))
1422     
1423     def _get_host_application(self):
1424         return self[0]
1425     def _set_host_application(self, val):
1426         self[0] = val
1427     host_application = property(fget=_get_host_application, fset=_set_host_application)
1428     def _get_source_role(self):
1429         return self[1]
1430     def _set_source_role(self, val):
1431         self[1] = val
1432     source_role = property(fget=_get_source_role, fset=_set_source_role)
1433     def _get_source_name(self):
1434         return self[2]
1435     def _set_source_name(self, val):
1436         self[2] = val
1437     source_name = property(fget=_get_source_name, fset=_set_source_name)
1438     def _get_any_data(self):
1439         return self[3]
1440     def _set_any_data(self, val):
1441         self[3] = val
1442     any_data = property(fget=_get_any_data, fset=_set_any_data)
1443
1444 class EventListener(_BaseProxy):
1445     """
1446     A generic interface implemented by objects for the receipt of
1447     event notifications. EventListener is the interface from which
1448     Accessibility::Registry is derived, and via which clients of
1449     the Registry receive notification of changes to an application's
1450     user interface and content.
1451     """
1452     
1453     def notifyEvent(self, *args, **kwargs):
1454         """
1455         Synchronously notify an EventListener that an event has occurred,
1456         by passing it an Event struct. 
1457         @param : e
1458         The Event about which the listener is being notified.
1459         """
1460         func = self.get_dbus_method("notifyEvent")
1461         return func(*args, **kwargs)
1462     
1463     def unImplemented2_(self, *args, **kwargs):
1464         func = self.get_dbus_method("unImplemented2_")
1465         return func(*args, **kwargs)
1466     
1467     def unImplemented3_(self, *args, **kwargs):
1468         func = self.get_dbus_method("unImplemented3_")
1469         return func(*args, **kwargs)
1470     
1471     def unImplemented4_(self, *args, **kwargs):
1472         func = self.get_dbus_method("unImplemented4_")
1473         return func(*args, **kwargs)
1474     
1475     def unImplemented_(self, *args, **kwargs):
1476         func = self.get_dbus_method("unImplemented_")
1477         return func(*args, **kwargs)
1478
1479
1480 class EventListenerMode(list):
1481     def __new__(cls, synchronous, preemptive, global_):
1482         list.__new__(cls, (synchronous, preemptive, global_))
1483     def __init__(self, synchronous, preemptive, global_):
1484         list.__init__(self, (synchronous, preemptive, global_))
1485     
1486     def _get_synchronous(self):
1487         return self[0]
1488     def _set_synchronous(self, val):
1489         self[0] = val
1490     synchronous = property(fget=_get_synchronous, fset=_set_synchronous)
1491     def _get_preemptive(self):
1492         return self[1]
1493     def _set_preemptive(self, val):
1494         self[1] = val
1495     preemptive = property(fget=_get_preemptive, fset=_set_preemptive)
1496     def _get_global_(self):
1497         return self[2]
1498     def _set_global_(self, val):
1499         self[2] = val
1500     global_ = property(fget=_get_global_, fset=_set_global_)
1501
1502
1503 class EventType(_Enum):
1504     _enum_lookup = {
1505         0:'KEY_PRESSED_EVENT',
1506         1:'KEY_RELEASED_EVENT',
1507         2:'BUTTON_PRESSED_EVENT',
1508         3:'BUTTON_RELEASED_EVENT',
1509     }
1510
1511 class Hyperlink(_BaseProxy):
1512     """
1513     Instances of Hyperlink are returned by Hypertext objects, and
1514     are the means by which end users and clients interact with linked,
1515     and in some cases embedded, content. Hyperlinks may have multiple
1516     "anchors", where an anchor corresponds to a reference to a particular
1517     resource with a corresponding resource identified (URI). Hyperlinks
1518     may be queried for their URIs, or queried for the objects corresponding
1519     to their anchors. The objects thus obtained are instances of
1520     Accessible, and may be queried, and manipulated via the Action
1521     interface.
1522     """
1523     
1524     def getObject(self, *args, **kwargs):
1525         """
1526         Gets the i'th object, (where i is an integer between 0 and Hyperlink::numAnchors
1527         - 1, inclusive) associated with a Hyperlink. The objects returned
1528         are usually actionable (i.e. they should implement Accessibility::Action),
1529         and the available actions often include "open", "bookmark", "save
1530         link as", etc. They may also implement Accessibility::StreamableContent,
1531         although clients can normally use getURI to obtain a resource
1532         locator via which the object's data may be accessed.
1533         @return an Accessible object instance representing the Hyperlink's
1534         ith anchor, or through which the content associated with the
1535         ith anchor can be accessed.
1536         """
1537         func = self.get_dbus_method("getObject")
1538         return func(*args, **kwargs)
1539     
1540     def getURI(self, *args, **kwargs):
1541         """
1542         Obtain a resource locator ('URI') which can be used to access
1543         the content to which this link "points" or is connected. 
1544         @return a string corresponding to the URI of the Hyperlink's
1545         'ith' anchor, if one exists, or a NIL string otherwise.
1546         """
1547         func = self.get_dbus_method("getURI")
1548         return func(*args, **kwargs)
1549     
1550     def isValid(self, *args, **kwargs):
1551         """
1552         Check the hyperlink to see if a connection to its backing content
1553         can be established, or if its URI is valid. 
1554         @return True if the object's content is available, or False if
1555         the hyperlink's URI is invalid, or a connection to the resource
1556         can not be established.
1557         """
1558         func = self.get_dbus_method("isValid")
1559         return func(*args, **kwargs)
1560     
1561     def unImplemented(self, *args, **kwargs):
1562         func = self.get_dbus_method("unImplemented")
1563         return func(*args, **kwargs)
1564     
1565     def unImplemented2(self, *args, **kwargs):
1566         func = self.get_dbus_method("unImplemented2")
1567         return func(*args, **kwargs)
1568     
1569     def unImplemented3(self, *args, **kwargs):
1570         func = self.get_dbus_method("unImplemented3")
1571         return func(*args, **kwargs)
1572     
1573     def unImplemented4(self, *args, **kwargs):
1574         func = self.get_dbus_method("unImplemented4")
1575         return func(*args, **kwargs)
1576     
1577     def get_endIndex(self):
1578         self._pgetter(self._dbus_interface, "endIndex")
1579     def set_endIndex(self, value):
1580         self._psetter(self._dbus_interface, "endIndex", value)
1581     _endIndexDoc = \
1582         """
1583         the ending offset within the containing Hypertext content with
1584         which this Hyperlink is associated; that is, the offset of the
1585         first element past the range within the Hypertext associated
1586         with this Hyperlink.
1587         """
1588     endIndex = property(fget=get_endIndex, fset=set_endIndex, doc=_endIndexDoc)
1589     
1590     def get_nAnchors(self):
1591         self._pgetter(self._dbus_interface, "nAnchors")
1592     def set_nAnchors(self, value):
1593         self._psetter(self._dbus_interface, "nAnchors", value)
1594     _nAnchorsDoc = \
1595         """
1596         the number of separate anchors associated with this Hyperlink
1597         """
1598     nAnchors = property(fget=get_nAnchors, fset=set_nAnchors, doc=_nAnchorsDoc)
1599     
1600     def get_startIndex(self):
1601         self._pgetter(self._dbus_interface, "startIndex")
1602     def set_startIndex(self, value):
1603         self._psetter(self._dbus_interface, "startIndex", value)
1604     _startIndexDoc = \
1605         """
1606         the starting offset within the containing Hypertext content with
1607         which this Hyperlink is associated
1608         """
1609     startIndex = property(fget=get_startIndex, fset=set_startIndex, doc=_startIndexDoc)
1610
1611
1612 class Hypertext(_BaseProxy):
1613     """
1614     An interface used for objects which implement linking between
1615     multiple resource or content locations, or multiple 'markers'
1616     within a single document. A Hypertext instance is associated
1617     with one or more Hyperlinks, which are associated with particular
1618     offsets within the Hypertext's included content.
1619     """
1620     
1621     def getLink(self, *args, **kwargs):
1622         """
1623         Get one of the Hyperlinks associated with this Hypertext object,
1624         by index.
1625         @param : linkIndex
1626         an integer from 0 to getNLinks() - 1. 
1627         @return the Hyperlink in this Hypertext object.
1628         """
1629         func = self.get_dbus_method("getLink")
1630         return func(*args, **kwargs)
1631     
1632     def getLinkIndex(self, *args, **kwargs):
1633         """
1634         Get the hyperlink index, if any, associated with a particular
1635         character offset in the Hypertext object. For Hypertext implementors
1636         without textual content, all hyperlinks are associated with character
1637         offset '0'.
1638         @return the index of the Hyperlink associated with character
1639         offset characterIndex, or -1 if no Hyperlink is associated with
1640         that character offset.
1641         """
1642         func = self.get_dbus_method("getLinkIndex")
1643         return func(*args, **kwargs)
1644     
1645     def getNLinks(self, *args, **kwargs):
1646         """
1647         Query the hypertext object for the number of Hyperlinks it contains.
1648         @return the number of Hyperlinks associated with this Hypertext
1649         object, as a long integer.
1650         """
1651         func = self.get_dbus_method("getNLinks")
1652         return func(*args, **kwargs)
1653     
1654 class Image(_BaseProxy):
1655     """
1656     An interface implemented by objects which render image data or
1657     pictorial information to the screen. When onscreen components
1658     include graphical information that is not purely intended to
1659     enhance "3d effect" or visual layout, but which conveys some
1660     semantic or informational content to the sighted user, they should
1661     implement Image, and that semantic content should be conveyed
1662     textually to the extent possible via the image description, as
1663     well as the Accessible::name and Accessible::description properties.
1664     """
1665     
1666     def getImageExtents(self, *args, **kwargs):
1667         """
1668         Obtain a bounding box which entirely contains the image contents,
1669         as displayed on screen. The bounds returned do not account for
1670         any viewport clipping or the fact that the image may be partially
1671         or wholly obscured by other onscreen content. 
1672         @param : coordType
1673         If 0, the returned bounding box position is returned relative
1674         to the screen; if 1, the bounding box position is returned relative
1675         to the containing window. 
1676         @return a BoundingBox enclosing the image's onscreen representation.
1677         """
1678         func = self.get_dbus_method("getImageExtents")
1679         return func(*args, **kwargs)
1680     
1681     def getImagePosition(self, *args, **kwargs):
1682         """
1683         Get the coordinates of the current image position on screen.
1684         @param : x
1685         Back-filled with the x coordinate of the onscreen image (i.e.
1686         the minimum x coordinate) 
1687         @param : y
1688         Back-filled with the y coordinate of the onscreen image (i.e.
1689         the minimum y coordinate) 
1690         @param : coordType
1691         If 0, the returned x and y coordinates are returned relative
1692         to the screen; if 1, they are returned relative to the containing
1693         window.
1694         """
1695         func = self.get_dbus_method("getImagePosition")
1696         return func(*args, **kwargs)
1697     
1698     def getImageSize(self, *args, **kwargs):
1699         """
1700         Obtain the width and height of the current onscreen view of the
1701         image. The extents returned do not account for any viewport clipping
1702         or the fact that the image may be partially or wholly obscured
1703         by other onscreen content. 
1704         @param : width
1705         Back-filled with the x extents of the onscreen image (i.e. the
1706         image width in pixels) 
1707         @param : height
1708         Back-filled with the y extents of the onscreen image (i.e. the
1709         image height in pixels)
1710         """
1711         func = self.get_dbus_method("getImageSize")
1712         return func(*args, **kwargs)
1713
1714     def get_imageDescription(self):
1715         self._pgetter(self._dbus_interface, "imageDescription")
1716     def set_imageDescription(self, value):
1717         self._psetter(self._dbus_interface, "imageDescription", value)
1718     _imageDescriptionDoc = \
1719         """
1720         A UTF-8 string providing a textual description of what is visually
1721         depicted in the image.
1722         """
1723     imageDescription = property(fget=get_imageDescription, fset=set_imageDescription, doc=_imageDescriptionDoc)
1724     
1725     def get_imageLocale(self):
1726         self._pgetter(self._dbus_interface, "imageLocale")
1727     def set_imageLocale(self, value):
1728         self._psetter(self._dbus_interface, "imageLocale", value)
1729     _imageLocaleDoc = \
1730         """
1731         A string corresponding to the POSIX LC_MESSAGES locale used by
1732         the imageDescription.
1733         """
1734     imageLocale = property(fget=get_imageLocale, fset=set_imageLocale, doc=_imageLocaleDoc)
1735
1736
1737 class KeyDefinition(list):
1738     def __new__(cls, keycode, keysym, keystring, unused):
1739         list.__new__(cls, (keycode, keysym, keystring, unused))
1740     def __init__(self, keycode, keysym, keystring, unused):
1741         list.__init__(self, (keycode, keysym, keystring, unused))
1742     
1743     def _get_keycode(self):
1744         return self[0]
1745     def _set_keycode(self, val):
1746         self[0] = val
1747     keycode = property(fget=_get_keycode, fset=_set_keycode)
1748     def _get_keysym(self):
1749         return self[1]
1750     def _set_keysym(self, val):
1751         self[1] = val
1752     keysym = property(fget=_get_keysym, fset=_set_keysym)
1753     def _get_keystring(self):
1754         return self[2]
1755     def _set_keystring(self, val):
1756         self[2] = val
1757     keystring = property(fget=_get_keystring, fset=_set_keystring)
1758     def _get_unused(self):
1759         return self[3]
1760     def _set_unused(self, val):
1761         self[3] = val
1762     unused = property(fget=_get_unused, fset=_set_unused)
1763
1764 class KeyEventType(_Enum):
1765     _enum_lookup = {
1766         0:'KEY_PRESSED',
1767         1:'KEY_RELEASED',
1768     }
1769
1770 class KeySynthType(_Enum):
1771     _enum_lookup = {
1772         0:'KEY_PRESS',
1773         1:'KEY_RELEASE',
1774         2:'KEY_PRESSRELEASE',
1775         3:'KEY_SYM',
1776         4:'KEY_STRING',
1777     }
1778
1779 class LOCALE_TYPE(_Enum):
1780     _enum_lookup = {
1781         0:'LOCALE_TYPE_MESSAGES',
1782         1:'LOCALE_TYPE_COLLATE',
1783         2:'LOCALE_TYPE_CTYPE',
1784         3:'LOCALE_TYPE_MONETARY',
1785         4:'LOCALE_TYPE_NUMERIC',
1786         5:'LOCALE_TYPE_TIME',
1787     }
1788
1789 class LoginHelper(_BaseProxy):
1790     """
1791     An interface for use by assistive technologies by which they
1792     can access system information and services on a 'need to know'
1793     basis while the screen is locked, during user authentication,
1794     or during other sensitive operations.     
1795     This interface is intended for use by assistive technologies
1796     and related user-enabling services, and by applications and utilities
1797     which may wish to restrict access to certain system devices and
1798     services during security-sensitive states, e.g. when the screen
1799     is locked or during authentication into some secure service.
1800     Such 'applications' (for instance, screen lock dialogs and security-enabled
1801     web browsers) use the LoginHelper client interfaces, and the
1802     bonobo-activation query service, to query for assistive technologies
1803     which advertise the LoginHelper service. The client then queries
1804     these assistive technologies for their device I/O requirements,
1805     via the getDeviceReqs call. The client may then issue the advisory
1806     request setSafe (TRUE), which requests that the LoginHelper -implementing
1807     service make a best-effort attempt to make itself more secure
1808     (for instance, an onscreen keyboard might turn off word prediction,
1809     and a screenreader may turn off keyboard echo via speech). The
1810     return value of setSafe is an advisory indication of whether
1811     this attempt was successful (no specific guarantees are implied).
1812     Once the 'security sensitive' state is exited, the client should
1813     call setSafe (FALSE).
1814     The return values from getDeviceReqs inform the client of which
1815     services the LoginHelper service (e. g. assistive technology)
1816     needs in order to do its job. The client may use this information
1817     to loosen any restrictions on access which it may currently have
1818     in place (for instance, keyboard grabs, etc.). If it does not
1819     do so, the likely outcome is that the end-user will experience
1820     loss of access to the system.
1821     """
1822     
1823     def getDeviceReqs(self, *args, **kwargs):
1824         """
1825         getDeviceReqs:
1826         Query a LoginHelper for the types of device I/O it requires,
1827         in order to do its job. For instance, a LoginHelper which needs
1828         to receive keyboard events will include Accessibility_LoginHelper_CORE_KEYBOARD
1829         in this list.
1830         @return : A sequence of LoginHelper_DeviceReq indicating the
1831         device I/O required in order to facilitate end-user access to
1832         the system.
1833         """
1834         func = self.get_dbus_method("getDeviceReqs")
1835         return func(*args, **kwargs)
1836     
1837     def getRaiseWindows(self, *args, **kwargs):
1838         """
1839         getRaiseWindows:
1840         Get a list of window IDs that need raising on login.
1841         @return : a sequence containing window IDS for toplevels which
1842         need to be raised/made visible during user authentication, in
1843         order for the LoginHelper to facilitate end-user access to the
1844         system.
1845         """
1846         func = self.get_dbus_method("getRaiseWindows")
1847         return func(*args, **kwargs)
1848     
1849     def setSafe(self, *args, **kwargs):
1850         """
1851         setSafe: 
1852         @param : safe_mode
1853         TRUE if the client is requesting that 'safe mode' be initiated,
1854         FALSE if the client is advising that 'safe mode' may be exited,
1855         i.e. normal operation may be resumed.
1856         Request a LoginHelper to enter "safe" mode, or inform LoginHelper
1857         that "safe" mode may be exited. If safe_mode is TRUE, but the
1858         return value is FALSE, the requesting client may wish to deny
1859         services to the LoginHelper, for instance avoid raising its toplevels.
1860         The return value is purely advisory, and no guarantees are intended
1861         about what the implementing LoginHelper will do to improve security
1862         when in "safe" mode.
1863         @return : whether the LoginHelper is now "safe" or not.
1864         """
1865         func = self.get_dbus_method("setSafe")
1866         return func(*args, **kwargs)
1867     
1868     class DeviceReq(_Enum):
1869         _enum_lookup = {
1870             0:'GUI_EVENTS',
1871             1:'CORE_KEYBOARD',
1872             2:'CORE_POINTER',
1873             3:'EXT_INPUT',
1874             4:'POST_WINDOWS',
1875             5:'AUDIO_OUT',
1876             6:'AUDIO_IN',
1877             7:'NETWORK',
1878             8:'LOCALHOST',
1879             9:'SERIAL_OUT',
1880             10:'SERIAL_IN',
1881         }
1882     
1883     AUDIO_IN = DeviceReq(6)
1884     
1885     AUDIO_OUT = DeviceReq(5)
1886     
1887     CORE_KEYBOARD = DeviceReq(1)
1888     
1889     CORE_POINTER = DeviceReq(2)
1890     
1891     EXT_INPUT = DeviceReq(3)
1892     
1893     GUI_EVENTS = DeviceReq(0)
1894     
1895     LOCALHOST = DeviceReq(8)
1896     
1897     NETWORK = DeviceReq(7)
1898     
1899     POST_WINDOWS = DeviceReq(4)
1900     
1901     SERIAL_IN = DeviceReq(10)
1902     
1903     SERIAL_OUT = DeviceReq(9)
1904     
1905     class WindowInfo(list):
1906         def __new__(cls, winID):
1907             list.__new__(cls, (winID))
1908         def __init__(self, winID):
1909             list.__init__(self, (winID))
1910         
1911         def _get_winID(self):
1912             return self[0]
1913         def _set_winID(self, val):
1914             self[0] = val
1915         winID = property(fget=_get_winID, fset=_set_winID)
1916
1917 class ModifierType(_Enum):
1918     _enum_lookup = {
1919         0:'MODIFIER_SHIFT',
1920         1:'MODIFIER_SHIFTLOCK',
1921         2:'MODIFIER_CONTROL',
1922         3:'MODIFIER_ALT',
1923         4:'MODIFIER_META',
1924         5:'MODIFIER_META2',
1925         6:'MODIFIER_META3',
1926         7:'MODIFIER_NUMLOCK',
1927     }
1928
1929 class Registry(EventListener):
1930     """
1931     The Registry is a service through which applications providing
1932     accessibility services (servers) can rendezvous with consumers
1933     of those services (Assistive Technologies). The Registry is the
1934     first "port of call" for accessible applications and for assistive
1935     technologies wishing to query and interact with those applications.
1936     The Registry service provides four basic functions to Assistive
1937     Technology (AT) clients: 
1938     it provides a list of the applications who have registered with
1939     the AT-SPI framework, thereby announcing their participation
1940     in the AT-SPI framework; 
1941     it allows AT clients to register for notification of changes
1942     in application state (at-spi Events); 
1943     it dispatches/relays said events from participating applications
1944     to the registered listeners; 
1945     it gives access to system device events via the associated DeviceEventController
1946     interface.
1947     From the point of view of accessible applications (i.e. AT-SPI
1948     service producers), the Registry is primarily a registration
1949     and event delivery service. Applications normally only call the
1950     registerApplication and deregisterApplication Registry methods,
1951     and its inherited EventListener::notifyEvent method.
1952     The Registry normally lives in its own process space; communication
1953     via Registry and both application services and AT clients takes
1954     place via IPC. A process space diagram illustrating the relationship
1955     between applications, Registry, and AT is shown below.
1956     """
1957     
1958     def deregisterApplication(self, *args, **kwargs):
1959         """
1960         De-register an application previously registered with the broker.
1961         deregisterApplication: 
1962         @param : app
1963         a reference to the Application to be deregistered.
1964         """
1965         func = self.get_dbus_method("deregisterApplication")
1966         return func(*args, **kwargs)
1967     
1968     def deregisterGlobalEventListener(self, *args, **kwargs):
1969         """
1970         deregisterGlobalEventListener: 
1971         @param : listener
1972         the requesting EventListener 
1973         @param : eventName
1974         a string indicating the type of events
1975         Request that a previously registered client stop receiving global
1976         notifications for events of a certain type.
1977         """
1978         func = self.get_dbus_method("deregisterGlobalEventListener")
1979         return func(*args, **kwargs)
1980     
1981     def deregisterGlobalEventListenerAll(self, *args, **kwargs):
1982         """
1983         deregisterGlobalEventListenerAll: 
1984         @param : listener
1985         the requesting EventListener
1986         Request that a previously registered client stop receiving global
1987         notifications for all events for which it was registered.
1988         """
1989         func = self.get_dbus_method("deregisterGlobalEventListenerAll")
1990         return func(*args, **kwargs)
1991     
1992     def getDesktop(self, *args, **kwargs):
1993         """
1994         getDesktop: 
1995         : the index of the requested Desktop.
1996         Get the nth accessible desktop.
1997         @return a reference to the requested Desktop.
1998         """
1999         func = self.get_dbus_method("getDesktop")
2000         return func(*args, **kwargs)
2001     
2002     def getDesktopCount(self, *args, **kwargs):
2003         """
2004         event types: "Window" "Desktop" "Window:Create" "Window:Destroy"
2005         "Window:Iconify" "Window:Restore" "Window:Fullscreen" "Window:Resize"
2006         "Desktop:Create" "Desktop:Destroy" "Desktop:Focus" "Desktop:Defocus"
2007         "Desktop:Reorder" "Focus" "GtkWidget:show" "GObject:notify:<propertyname>"
2008         ( not sure we should allow these last 2 forms, since they are
2009         toolkit-specific, but they're powerful ) getDesktopCount:
2010         Get the current number of desktops. 
2011         @return a short integer indicating the current number of Desktops.
2012         """
2013         func = self.get_dbus_method("getDesktopCount")
2014         return func(*args, **kwargs)
2015     
2016     def getDesktopList(self, *args, **kwargs):
2017         """
2018         Get a list of accessible desktops.
2019         @return : a sequence containing references to the Desktops.
2020         """
2021         func = self.get_dbus_method("getDesktopList")
2022         return func(*args, **kwargs)
2023     
2024     def getDeviceEventController(self, *args, **kwargs):
2025         """
2026         Obtain an object which can be used to request device event notifications.
2027         @return : an object implementing DeviceEventController
2028         """
2029         func = self.get_dbus_method("getDeviceEventController")
2030         return func(*args, **kwargs)
2031     
2032     def registerApplication(self, *args, **kwargs):
2033         """
2034         Register a new application with the accessibility broker. 
2035         @param : app
2036         a reference to the requesting Application
2037         """
2038         func = self.get_dbus_method("registerApplication")
2039         return func(*args, **kwargs)
2040     
2041     def registerGlobalEventListener(self, *args, **kwargs):
2042         """
2043         Register a client's interest in (all) application events of a
2044         certain type. 
2045         @param : listener
2046         a reference to the requesting EventListener. 
2047         @param : eventName
2048         a string which indicates the type of events about which the client
2049         desires notification.
2050         """
2051         func = self.get_dbus_method("registerGlobalEventListener")
2052         return func(*args, **kwargs)
2053
2054     
2055
2056 class Role(_Enum):
2057     _enum_lookup = {
2058         0:'ROLE_INVALID',
2059         1:'ROLE_ACCELERATOR_LABEL',
2060         2:'ROLE_ALERT',
2061         3:'ROLE_ANIMATION',
2062         4:'ROLE_ARROW',
2063         5:'ROLE_CALENDAR',
2064         6:'ROLE_CANVAS',
2065         7:'ROLE_CHECK_BOX',
2066         8:'ROLE_CHECK_MENU_ITEM',
2067         9:'ROLE_COLOR_CHOOSER',
2068         10:'ROLE_COLUMN_HEADER',
2069         11:'ROLE_COMBO_BOX',
2070         12:'ROLE_DATE_EDITOR',
2071         13:'ROLE_DESKTOP_ICON',
2072         14:'ROLE_DESKTOP_FRAME',
2073         15:'ROLE_DIAL',
2074         16:'ROLE_DIALOG',
2075         17:'ROLE_DIRECTORY_PANE',
2076         18:'ROLE_DRAWING_AREA',
2077         19:'ROLE_FILE_CHOOSER',
2078         20:'ROLE_FILLER',
2079         21:'ROLE_FOCUS_TRAVERSABLE',
2080         22:'ROLE_FONT_CHOOSER',
2081         23:'ROLE_FRAME',
2082         24:'ROLE_GLASS_PANE',
2083         25:'ROLE_HTML_CONTAINER',
2084         26:'ROLE_ICON',
2085         27:'ROLE_IMAGE',
2086         28:'ROLE_INTERNAL_FRAME',
2087         29:'ROLE_LABEL',
2088         30:'ROLE_LAYERED_PANE',
2089         31:'ROLE_LIST',
2090         32:'ROLE_LIST_ITEM',
2091         33:'ROLE_MENU',
2092         34:'ROLE_MENU_BAR',
2093         35:'ROLE_MENU_ITEM',
2094         36:'ROLE_OPTION_PANE',
2095         37:'ROLE_PAGE_TAB',
2096         38:'ROLE_PAGE_TAB_LIST',
2097         39:'ROLE_PANEL',
2098         40:'ROLE_PASSWORD_TEXT',
2099         41:'ROLE_POPUP_MENU',
2100         42:'ROLE_PROGRESS_BAR',
2101         43:'ROLE_PUSH_BUTTON',
2102         44:'ROLE_RADIO_BUTTON',
2103         45:'ROLE_RADIO_MENU_ITEM',
2104         46:'ROLE_ROOT_PANE',
2105         47:'ROLE_ROW_HEADER',
2106         48:'ROLE_SCROLL_BAR',
2107         49:'ROLE_SCROLL_PANE',
2108         50:'ROLE_SEPARATOR',
2109         51:'ROLE_SLIDER',
2110         52:'ROLE_SPIN_BUTTON',
2111         53:'ROLE_SPLIT_PANE',
2112         54:'ROLE_STATUS_BAR',
2113         55:'ROLE_TABLE',
2114         56:'ROLE_TABLE_CELL',
2115         57:'ROLE_TABLE_COLUMN_HEADER',
2116         58:'ROLE_TABLE_ROW_HEADER',
2117         59:'ROLE_TEAROFF_MENU_ITEM',
2118         60:'ROLE_TERMINAL',
2119         61:'ROLE_TEXT',
2120         62:'ROLE_TOGGLE_BUTTON',
2121         63:'ROLE_TOOL_BAR',
2122         64:'ROLE_TOOL_TIP',
2123         65:'ROLE_TREE',
2124         66:'ROLE_TREE_TABLE',
2125         67:'ROLE_UNKNOWN',
2126         68:'ROLE_VIEWPORT',
2127         69:'ROLE_WINDOW',
2128         70:'ROLE_EXTENDED',
2129         71:'ROLE_HEADER',
2130         72:'ROLE_FOOTER',
2131         73:'ROLE_PARAGRAPH',
2132         74:'ROLE_RULER',
2133         75:'ROLE_APPLICATION',
2134         76:'ROLE_AUTOCOMPLETE',
2135         77:'ROLE_EDITBAR',
2136         78:'ROLE_EMBEDDED',
2137         79:'ROLE_ENTRY',
2138         80:'ROLE_CHART',
2139         81:'ROLE_CAPTION',
2140         82:'ROLE_DOCUMENT_FRAME',
2141         83:'ROLE_HEADING',
2142         84:'ROLE_PAGE',
2143         85:'ROLE_SECTION',
2144         86:'ROLE_REDUNDANT_OBJECT',
2145         87:'ROLE_FORM',
2146         88:'ROLE_LINK',
2147         89:'ROLE_INPUT_METHOD_WINDOW',
2148         90:'ROLE_LAST_DEFINED',
2149     }
2150
2151 class Selection(_BaseProxy):
2152     """
2153     An interface which indicates that an object exposes a 'selection'
2154     model, allowing the selection of one or more of its children.
2155     Read-only Selection instances are possible, in which case the
2156     interface is used to programmatically determine the selected-ness
2157     of its children. A selected child has State::STATE_SELECTED,
2158     and a child which may hypothetically be selected (though possibly
2159     not programmatically selectable) has State::STATE_SELECTABLE.
2160     """
2161     
2162     def clearSelection(self, *args, **kwargs):
2163         """
2164         Attempt to clear all selections (i.e. deselect all children)
2165         of a Selection. Not all Selection implementations allow the removal
2166         of all selections.
2167         @return True if the selections were successfully cleared, False
2168         otherwise.
2169         """
2170         func = self.get_dbus_method("clearSelection")
2171         return func(*args, **kwargs)
2172     
2173     def deselectChild(self, *args, **kwargs):
2174         """
2175         Remove a child from the selected children list of a Selection,
2176         if the child is currently selected.
2177         @param : childIndex
2178         a long integer (the zero offset index into the Accessible object's
2179         list of children) indicating which child of the Selection is
2180         to be selected.
2181         @return True if the child was successfully selected, False otherwise.
2182         """
2183         func = self.get_dbus_method("deselectChild")
2184         return func(*args, **kwargs)
2185     
2186     def deselectSelectedChild(self, *args, **kwargs):
2187         """
2188         Remove a child to the selected children list of a Selection.
2189         @param : selectedChildIndex
2190         a long integer indicating which of the selected children of the
2191         Selection is to be deselected. The index is a zero-offset index
2192         into the 'selected child list', not a zero-offset index into
2193         the list of all children of the Selection.
2194         @return True if the child was successfully deselected, False
2195         otherwise.
2196         """
2197         func = self.get_dbus_method("deselectSelectedChild")
2198         return func(*args, **kwargs)
2199     
2200     def getSelectedChild(self, *args, **kwargs):
2201         """
2202         Get the i-th selected Accessible child of a Selection. 
2203         @param : selectedChildIndex
2204         a long integer indicating which of the selected children of an
2205         object is being requested. 
2206         @return a pointer to a selected Accessible child object, specified
2207         by selectedChildIndex.
2208         """
2209         func = self.get_dbus_method("getSelectedChild")
2210         return func(*args, **kwargs)
2211     
2212     def isChildSelected(self, *args, **kwargs):
2213         """
2214         Determine whether a particular child of an Selection implementor
2215         is currently selected. Note that childIndex is the zero-offset
2216         index into the standard Accessible container's list of children.
2217         @param : childIndex
2218         an index into the Selection's list of children.
2219         @return True if the specified child is currently selected, False
2220         otherwise.
2221         """
2222         func = self.get_dbus_method("isChildSelected")
2223         return func(*args, **kwargs)
2224     
2225     def selectAll(self, *args, **kwargs):
2226         """
2227         Attempt to select all of the children of a Selection implementor.
2228         Not all Selection implementors support this operation (for instance,
2229         implementations which support only "single selection" do not
2230         support this operation).
2231         @return True if successful, False otherwise.
2232         """
2233         func = self.get_dbus_method("selectAll")
2234         return func(*args, **kwargs)
2235     
2236     def selectChild(self, *args, **kwargs):
2237         """
2238         Add a child to the selected children list of a Selection. 
2239         @param : childIndex
2240         a long integer indicating which child of the Selection is to
2241         be selected.
2242         @return True if the child was successfully selected, False otherwise.
2243         """
2244         func = self.get_dbus_method("selectChild")
2245         return func(*args, **kwargs)
2246     
2247     def unImplemented(self, *args, **kwargs):
2248         """
2249         unImplemented:
2250         placeholders for future expansion.
2251         """
2252         func = self.get_dbus_method("unImplemented")
2253         return func(*args, **kwargs)
2254     
2255     def unImplemented2(self, *args, **kwargs):
2256         func = self.get_dbus_method("unImplemented2")
2257         return func(*args, **kwargs)
2258     
2259     def unImplemented3(self, *args, **kwargs):
2260         func = self.get_dbus_method("unImplemented3")
2261         return func(*args, **kwargs)
2262     
2263     def get_nSelectedChildren(self):
2264         self._pgetter(self._dbus_interface, "nSelectedChildren")
2265     def set_nSelectedChildren(self, value):
2266         self._psetter(self._dbus_interface, "nSelectedChildren", value)
2267     _nSelectedChildrenDoc = \
2268         """
2269         The number of children of a Selection implementor which are currently
2270         selected.
2271         """
2272     nSelectedChildren = property(fget=get_nSelectedChildren, fset=set_nSelectedChildren, doc=_nSelectedChildrenDoc)
2273
2274
2275 class Selector(_BaseProxy):
2276     """
2277     This interface is intended for use by assistive technologies
2278     and related user-agents. Via this interface, an assistive technology
2279     or user agent may expose a series of choices or selections in
2280     textual form, which can be activated on demand by a client of
2281     the Selector interface.
2282     Examples of the use of this interface include voice-command and
2283     remote-control applications, in which the user interaction is
2284     wholly or partly delegated by the implementor to an external
2285     agent.
2286     """
2287     
2288     def activateCommand(self, *args, **kwargs):
2289         """
2290         Request that the Selector invoke the specified Command. 
2291         @param : cmd
2292         the Command to activate/invoke. 
2293         @return a CommandResult indicating whether the request was honored,
2294         and the reason for failure if the Command could not be activated
2295         or invoked.
2296         """
2297         func = self.get_dbus_method("activateCommand")
2298         return func(*args, **kwargs)
2299     
2300     def deregisterChangeListener(self, *args, **kwargs):
2301         """
2302         Tell the Selector instance to cease notifying the specified CommandListener
2303         of changes to the command list. 
2304         @param : listener
2305         the CommandListener to remove from the notification list.
2306         """
2307         func = self.get_dbus_method("deregisterChangeListener")
2308         return func(*args, **kwargs)
2309     
2310     def getCommands(self, *args, **kwargs):
2311         """
2312         Query the Selector for the current CommandList.
2313         @return the currently available CommandList
2314         """
2315         func = self.get_dbus_method("getCommands")
2316         return func(*args, **kwargs)
2317     
2318     def refreshCommands(self, *args, **kwargs):
2319         """
2320         Ask the Selector to re-calculate its CommandList. 
2321         @return TRUE if the CommandList changed.
2322         """
2323         func = self.get_dbus_method("refreshCommands")
2324         return func(*args, **kwargs)
2325     
2326     def registerChangeListener(self, *args, **kwargs):
2327         """
2328         Register a :CommandListener instance for notification of changes
2329         to the command set. 
2330         @param : listener
2331         the CommandListener to be notified of changes.
2332         """
2333         func = self.get_dbus_method("registerChangeListener")
2334         return func(*args, **kwargs)
2335     
2336     def replaceCommands(self, *args, **kwargs):
2337         """
2338         @return TRUE if the replacement request was successful, FALSE
2339         if the request could not be honored.
2340         """
2341         func = self.get_dbus_method("replaceCommands")
2342         return func(*args, **kwargs)
2343     
2344     def get_supportsReplace(self):
2345         self._pgetter(self._dbus_interface, "supportsReplace")
2346     def set_supportsReplace(self, value):
2347         self._psetter(self._dbus_interface, "supportsReplace", value)
2348     _supportsReplaceDoc = \
2349         """
2350         This attribute is TRUE if this Selector allows its CommandList
2351         to be specified by the client
2352         """
2353     supportsReplace = property(fget=get_supportsReplace, fset=set_supportsReplace, doc=_supportsReplaceDoc)
2354
2355     class CommandResult(_Enum):
2356         """
2357         A code returned by a call to activateCommand, indicating the
2358         result of the activation request.
2359         """
2360         _enum_lookup = {
2361             0:'COMMAND_RESULT_INVALID',
2362             1:'COMMAND_RESULT_SUCCESS',
2363             2:'COMMAND_RESULT_FAILED',
2364             3:'COMMAND_RESULT_OBSOLETE',
2365             4:'COMMAND_RESULT_LAST_DEFINED',
2366         }
2367     
2368     COMMAND_RESULT_FAILED = CommandResult(2)
2369     
2370     COMMAND_RESULT_INVALID = CommandResult(0)
2371     
2372     COMMAND_RESULT_LAST_DEFINED = CommandResult(4)
2373     
2374     COMMAND_RESULT_OBSOLETE = CommandResult(3)
2375     
2376     COMMAND_RESULT_SUCCESS = CommandResult(1)
2377
2378 class StreamableContent(_BaseProxy):
2379     """
2380     An interface whereby an object allows its backing content to
2381     be streamed to clients. Negotiation of content type is allowed.
2382     Clients may examine the backing data and transform, convert,
2383     or parse the content in order to present it in an alternate form
2384     to end-users.
2385     """
2386     
2387     def getContent(self, *args, **kwargs):
2388         """
2389         DEPRECATED, use getStream instead. getContent: Retrieve this
2390         object's content, in a format appropriate to a requested mimetype.
2391                 long Bonobo::Stream:seek (in long offset, in SeekType
2392         whence)
2393                         raises (NoPermission, IOError)
2394                 void Bonobo::Stream:read (in long count, out iobuf buffer)
2395                         raises (NoPermission, IOError)
2396                
2397         @return a Bonobo::Stream whose mimetype matches contentType,
2398         if available, or NIL.
2399         """
2400         func = self.get_dbus_method("getContent")
2401         return func(*args, **kwargs)
2402     
2403     def getContentTypes(self, *args, **kwargs):
2404         """
2405         getContentTypes: 
2406         @return the list of available mimetypes for this object's content.
2407         """
2408         func = self.get_dbus_method("getContentTypes")
2409         return func(*args, **kwargs)
2410     
2411     def getStream(self, *args, **kwargs):
2412         """
2413         Retrieve this object's content, in a format appropriate to a
2414         requested mimetype, as a ContentStream instance.
2415         @param : contentType
2416         a string specifying the desired mimetype for the content stream.
2417         @return a Stream whose mimetype matches contentType, if available,
2418         or NIL.
2419         """
2420         func = self.get_dbus_method("getStream")
2421         return func(*args, **kwargs)
2422     
2423     def getURI(self, *args, **kwargs):
2424         """
2425         Get a URI pointing to the content of the specified type, if such
2426         a URI can be obtained. Not all streamable content providers have
2427         URI representations.
2428         @param : contentType
2429         a string specifying the desired mimetype for the content stream.
2430         If NULL, then a URI for the default content type will be returned,
2431         if available.
2432         @return a string which constitutes a URI for a stream of the
2433         specified content type, or NULL if no such URI can be obtained.
2434         """
2435         func = self.get_dbus_method("getURI")
2436         return func(*args, **kwargs)
2437     
2438     def unImplemented(self, *args, **kwargs):
2439         func = self.get_dbus_method("unImplemented")
2440         return func(*args, **kwargs)
2441     
2442     def unImplemented2(self, *args, **kwargs):
2443         func = self.get_dbus_method("unImplemented2")
2444         return func(*args, **kwargs)
2445
2446
2447 class TEXT_BOUNDARY_TYPE(_Enum):
2448     _enum_lookup = {
2449         0:'TEXT_BOUNDARY_CHAR',
2450         1:'TEXT_BOUNDARY_WORD_START',
2451         2:'TEXT_BOUNDARY_WORD_END',
2452         3:'TEXT_BOUNDARY_SENTENCE_START',
2453         4:'TEXT_BOUNDARY_SENTENCE_END',
2454         5:'TEXT_BOUNDARY_LINE_START',
2455         6:'TEXT_BOUNDARY_LINE_END',
2456     }
2457
2458 class TEXT_CLIP_TYPE(_Enum):
2459     _enum_lookup = {
2460         0:'TEXT_CLIP_NONE',
2461         1:'TEXT_CLIP_MIN',
2462         2:'TEXT_CLIP_MAX',
2463         3:'TEXT_CLIP_BOTH',
2464     }
2465
2466 class Table(_BaseProxy):
2467     """
2468     An interface used by containers whose contained data is arranged
2469     in a "tabular" (i.e. row-column) fashion. Tables may resemble
2470     a two-dimensional grid, as in a spreadsheet, or may feature objects
2471     which span multiple rows and/or columns, but whose bounds are
2472     aligned on a row/column matrix. Thus, the Table interface may
2473     be used to represent "spreadsheets" as well as "frames".
2474     Objects within tables are children of the Table instance, and
2475     they may be referenced either via a child index or via a row/column
2476     pair. Their role may be ROLE_TABLE_CELL, but table 'cells' may
2477     have other roles as well. These 'cells' may implement other interfaces,
2478     such as Text, Action, Image, and Component, and should do so
2479     as appropriate to their onscreen representation and/or behavior.
2480     """
2481     
2482     def addColumnSelection(self, *args, **kwargs):
2483         """
2484         Select the specified column, adding it to the current column
2485         selection, if the table's selection model permits it.
2486         @param : column
2487         @return True if the specified column was successfully selected,
2488         False if not.
2489         """
2490         func = self.get_dbus_method("addColumnSelection")
2491         return func(*args, **kwargs)
2492     
2493     def addRowSelection(self, *args, **kwargs):
2494         """
2495         Select the specified row, adding it to the current row selection,
2496         if the table's selection model permits it.
2497         @param : row
2498         @return True if the specified row was successfully selected,
2499         False if not.
2500         """
2501         func = self.get_dbus_method("addRowSelection")
2502         return func(*args, **kwargs)
2503     
2504     def getAccessibleAt(self, *args, **kwargs):
2505         """
2506         Get the table cell at the specified row and column indices. 
2507         @param : row
2508         the specified table row, zero-indexed. 
2509         @param : column
2510         the specified table column, zero-indexed.
2511         @return an Accessible object representing the specified table
2512         cell.
2513         """
2514         func = self.get_dbus_method("getAccessibleAt")
2515         return func(*args, **kwargs)
2516     
2517     def getColumnAtIndex(self, *args, **kwargs):
2518         """
2519         Get the table column index occupied by the child at a particular
2520         1-D child index.
2521         @param : index
2522         the specified child index, zero-indexed.
2523         @return a long integer indicating the first column spanned by
2524         the child of a table, at the specified 1-D (zero-offset) index.
2525         """
2526         func = self.get_dbus_method("getColumnAtIndex")
2527         return func(*args, **kwargs)
2528     
2529     def getColumnDescription(self, *args, **kwargs):
2530         """
2531         Get a text description of a particular table column. This differs
2532         from AccessibleTable_getColumnHeader, which returns an Accessible.
2533         @param : column
2534         the specified table column, zero-indexed.
2535         @return a UTF-8 string describing the specified table column,
2536         if available.
2537         """
2538         func = self.get_dbus_method("getColumnDescription")
2539         return func(*args, **kwargs)
2540     
2541     def getColumnExtentAt(self, *args, **kwargs):
2542         """
2543         Get the number of columns spanned by the table cell at the specific
2544         row and column. (some tables can have cells which span multiple
2545         rows and/or columns).
2546         @param : row
2547         the specified table row, zero-indexed. 
2548         @param : column
2549         the specified table column, zero-indexed.
2550         @return a long integer indicating the number of columns spanned
2551         by the specified cell.
2552         """
2553         func = self.get_dbus_method("getColumnExtentAt")
2554         return func(*args, **kwargs)
2555     
2556     def getColumnHeader(self, *args, **kwargs):
2557         """
2558         Get the header associated with a table column, if available,
2559         as an instance of Accessible. This differs from getColumnDescription,
2560         which returns a string.
2561         @param : column
2562         the specified table column, zero-indexed.
2563         @return an Accessible representatin of the specified table column,
2564         if available.
2565         """
2566         func = self.get_dbus_method("getColumnHeader")
2567         return func(*args, **kwargs)
2568     
2569     def getIndexAt(self, *args, **kwargs):
2570         """
2571         Get the 1-D child index corresponding to the specified 2-D row
2572         and column indices. 
2573         @param : row
2574         the specified table row, zero-indexed. 
2575         @param : column
2576         the specified table column, zero-indexed.
2577         @return a long integer which serves as the index of a specified
2578         cell in the table, in a form usable by Accessible::getChildAtIndex.
2579         """
2580         func = self.get_dbus_method("getIndexAt")
2581         return func(*args, **kwargs)
2582     
2583     def getRowAtIndex(self, *args, **kwargs):
2584         """
2585         Get the table row index occupied by the child at a particular
2586         1-D child index.
2587         @param : index
2588         the specified child index, zero-indexed.
2589         @return a long integer indicating the first row spanned by the
2590         child of a table, at the specified 1-D (zero-offset) index.
2591         """
2592         func = self.get_dbus_method("getRowAtIndex")
2593         return func(*args, **kwargs)
2594     
2595     def getRowColumnExtentsAtIndex(self, *args, **kwargs):
2596         """
2597         Given a child index, determine the row and column indices and
2598         extents, and whether the cell is currently selected. If the child
2599         at index is not a cell (for instance, if it is a summary, caption,
2600         etc.), False is returned.
2601         @param : index
2602         the index of the Table child whose row/column extents are requested.
2603         @param : row
2604         back-filled with the first table row associated with the cell
2605         with child index index. 
2606         @param : col
2607         back-filled with the first table column associated with the cell
2608         with child index index. 
2609         @param : row_extents
2610         back-filled with the number of table rows across which child
2611         i extends. 
2612         @param : col_extents
2613         back-filled with the number of table columns across which child
2614         i extends. 
2615         @param : is_selected
2616         a boolean which is back-filled with True if the child at index
2617         i corresponds to a selected table cell, False otherwise.
2618         Example: If the Table child at index '6' extends across columns
2619         5 and 6 of row 2 of a Table instance, and is currently selected,
2620         then retval=table::getRowColumnExtentsAtIndex(6,row,col,
2621         row_extents,
2622         col_extents,
2623         is_selected);
2624          will return True, and after the call row, col, row_extents,
2625         col_extents, and is_selected will contain 2, 5, 1, 2, and True,
2626         respectively.
2627         @return True if the index is associated with a valid table cell,
2628         False if the index does not correspond to a cell. If False is
2629         returned, the values of the out parameters are undefined.
2630         """
2631         func = self.get_dbus_method("getRowColumnExtentsAtIndex")
2632         return func(*args, **kwargs)
2633     
2634     def getRowDescription(self, *args, **kwargs):
2635         """
2636         Get a text description of a particular table row. This differs
2637         from AccessibleTable_getRowHeader, which returns an Accessible.
2638         @param : row
2639         the specified table row, zero-indexed.
2640         @return a UTF-8 string describing the specified table row, if
2641         available.
2642         """
2643         func = self.get_dbus_method("getRowDescription")
2644         return func(*args, **kwargs)
2645     
2646     def getRowExtentAt(self, *args, **kwargs):
2647         """
2648         Get the number of rows spanned by the table cell at the specific
2649         row and column. (some tables can have cells which span multiple
2650         rows and/or columns).
2651         @param : row
2652         the specified table row, zero-indexed. 
2653         @param : column
2654         the specified table column, zero-indexed.
2655         @return a long integer indicating the number of rows spanned
2656         by the specified cell.
2657         """
2658         func = self.get_dbus_method("getRowExtentAt")
2659         return func(*args, **kwargs)
2660     
2661     def getRowHeader(self, *args, **kwargs):
2662         """
2663         Get the header associated with a table row, if available. This
2664         differs from getRowDescription, which returns a string.
2665         @param : row
2666         the specified table row, zero-indexed.
2667         @return an Accessible representatin of the specified table row,
2668         if available.
2669         """
2670         func = self.get_dbus_method("getRowHeader")
2671         return func(*args, **kwargs)
2672     
2673     def getSelectedColumns(self, *args, **kwargs):
2674         """
2675         Obtain the indices of all columns which are currently selected.
2676         @return a sequence of integers comprising the indices of columns
2677         currently selected.
2678         """
2679         func = self.get_dbus_method("getSelectedColumns")
2680         return func(*args, **kwargs)
2681     
2682     def getSelectedRows(self, *args, **kwargs):
2683         """
2684         Obtain the indices of all rows which are currently selected.
2685         @return a sequence of integers comprising the indices of rows
2686         currently selected.
2687         """
2688         func = self.get_dbus_method("getSelectedRows")
2689         return func(*args, **kwargs)
2690     
2691     def isColumnSelected(self, *args, **kwargs):
2692         """
2693         Determine whether a table column is selected. 
2694         @param : column
2695         the column being queried.
2696         @return True if the specified column is currently selected, False
2697         if not.
2698         """
2699         func = self.get_dbus_method("isColumnSelected")
2700         return func(*args, **kwargs)
2701     
2702     def isRowSelected(self, *args, **kwargs):
2703         """
2704         Determine whether a table row is selected. 
2705         @param : row
2706         the row being queried.
2707         @return True if the specified row is currently selected, False
2708         if not.
2709         """
2710         func = self.get_dbus_method("isRowSelected")
2711         return func(*args, **kwargs)
2712     
2713     def isSelected(self, *args, **kwargs):
2714         """
2715         Determine whether the cell at a specific row and column is selected.
2716         @param : row
2717         a row occupied by the cell whose state is being queried. 
2718         @param : column
2719         a column occupied by the cell whose state is being queried.
2720         @return True if the specified cell is currently selected, False
2721         if not.
2722         """
2723         func = self.get_dbus_method("isSelected")
2724         return func(*args, **kwargs)
2725     
2726     def removeColumnSelection(self, *args, **kwargs):
2727         """
2728         Remove the specified column from current column selection, if
2729         the table's selection model permits it.
2730         @param : column
2731         @return True if the specified column was successfully de-selected,
2732         False if not.
2733         """
2734         func = self.get_dbus_method("removeColumnSelection")
2735         return func(*args, **kwargs)
2736     
2737     def removeRowSelection(self, *args, **kwargs):
2738         """
2739         Remove the specified row from current row selection, if the table's
2740         selection model permits it.
2741         @param : row
2742         @return True if the specified row was successfully de-selected,
2743         False if not.
2744         """
2745         func = self.get_dbus_method("removeRowSelection")
2746         return func(*args, **kwargs)
2747     
2748     def unImplemented(self, *args, **kwargs):
2749         func = self.get_dbus_method("unImplemented")
2750         return func(*args, **kwargs)
2751     
2752     def unImplemented2(self, *args, **kwargs):
2753         func = self.get_dbus_method("unImplemented2")
2754         return func(*args, **kwargs)
2755     
2756     def unImplemented3(self, *args, **kwargs):
2757         func = self.get_dbus_method("unImplemented3")
2758         return func(*args, **kwargs)
2759     
2760     def unImplemented4(self, *args, **kwargs):
2761         func = self.get_dbus_method("unImplemented4")
2762         return func(*args, **kwargs)
2763     
2764     def unImplemented5(self, *args, **kwargs):
2765         func = self.get_dbus_method("unImplemented5")
2766         return func(*args, **kwargs)
2767     
2768     def unImplemented6(self, *args, **kwargs):
2769         func = self.get_dbus_method("unImplemented6")
2770         return func(*args, **kwargs)
2771     
2772     def unImplemented7(self, *args, **kwargs):
2773         func = self.get_dbus_method("unImplemented7")
2774         return func(*args, **kwargs)
2775     
2776     def get_caption(self):
2777         self._pgetter(self._dbus_interface, "caption")
2778     def set_caption(self, value):
2779         self._psetter(self._dbus_interface, "caption", value)
2780     _captionDoc = \
2781         """
2782         An Accessible which represents of a caption for a Table.
2783         """
2784     caption = property(fget=get_caption, fset=set_caption, doc=_captionDoc)
2785     
2786     def get_nColumns(self):
2787         self._pgetter(self._dbus_interface, "nColumns")
2788     def set_nColumns(self, value):
2789         self._psetter(self._dbus_interface, "nColumns", value)
2790     _nColumnsDoc = \
2791         """
2792         The total number of columns in this table (including empty columns),
2793         exclusive of columns which are programmatically hidden. Columns
2794         which are scrolled out of view or clipped by the current viewport
2795         are included.
2796         """
2797     nColumns = property(fget=get_nColumns, fset=set_nColumns, doc=_nColumnsDoc)
2798     
2799     def get_nRows(self):
2800         self._pgetter(self._dbus_interface, "nRows")
2801     def set_nRows(self, value):
2802         self._psetter(self._dbus_interface, "nRows", value)
2803     _nRowsDoc = \
2804         """
2805         The total number of rows in this table (including empty rows),
2806         exclusive of any rows which are programmatically hidden. Rows
2807         which are merely scrolled out of view are included.
2808         """
2809     nRows = property(fget=get_nRows, fset=set_nRows, doc=_nRowsDoc)
2810     
2811     def get_nSelectedColumns(self):
2812         self._pgetter(self._dbus_interface, "nSelectedColumns")
2813     def set_nSelectedColumns(self, value):
2814         self._psetter(self._dbus_interface, "nSelectedColumns", value)
2815     _nSelectedColumnsDoc = \
2816         """
2817         The number of columns currently selected. A selected column is
2818         one in which all included cells are selected.
2819         """
2820     nSelectedColumns = property(fget=get_nSelectedColumns, fset=set_nSelectedColumns, doc=_nSelectedColumnsDoc)
2821     
2822     def get_nSelectedRows(self):
2823         self._pgetter(self._dbus_interface, "nSelectedRows")
2824     def set_nSelectedRows(self, value):
2825         self._psetter(self._dbus_interface, "nSelectedRows", value)
2826     _nSelectedRowsDoc = \
2827         """
2828         The number of rows currently selected. A selected row is one
2829         in which all included cells are selected.
2830         """
2831     nSelectedRows = property(fget=get_nSelectedRows, fset=set_nSelectedRows, doc=_nSelectedRowsDoc)
2832     
2833     def get_summary(self):
2834         self._pgetter(self._dbus_interface, "summary")
2835     def set_summary(self, value):
2836         self._psetter(self._dbus_interface, "summary", value)
2837     _summaryDoc = \
2838         """
2839         An accessible object which summarizes the contents of a Table.
2840         This object is frequently itself a Table instance, albeit a simplified
2841         one.
2842         """
2843     summary = property(fget=get_summary, fset=set_summary, doc=_summaryDoc)
2844
2845
2846
2847 class Value(_BaseProxy):
2848     """
2849     An interface supporting controls which allow a one-dimensional,
2850     scalar quantity to be modified or which reflect a scalar quantity.
2851     (If STATE_EDITABLE is not present, the valuator is treated as
2852     "read only".
2853     """
2854     
2855     def unImplemented(self, *args, **kwargs):
2856         func = self.get_dbus_method("unImplemented")
2857         return func(*args, **kwargs)
2858     
2859     def unImplemented2(self, *args, **kwargs):
2860         func = self.get_dbus_method("unImplemented2")
2861         return func(*args, **kwargs)
2862     
2863     def unImplemented3(self, *args, **kwargs):
2864         func = self.get_dbus_method("unImplemented3")
2865         return func(*args, **kwargs)
2866     
2867     def unImplemented4(self, *args, **kwargs):
2868         func = self.get_dbus_method("unImplemented4")
2869         return func(*args, **kwargs)
2870     
2871     def get_currentValue(self):
2872         self._pgetter(self._dbus_interface, "currentValue")
2873     def set_currentValue(self, value):
2874         self._psetter(self._dbus_interface, "currentValue", value)
2875     _currentValueDoc = \
2876         """
2877         The current value of the valuator.
2878         """
2879     currentValue = property(fget=get_currentValue, fset=set_currentValue, doc=_currentValueDoc)
2880     
2881     def get_maximumValue(self):
2882         self._pgetter(self._dbus_interface, "maximumValue")
2883     def set_maximumValue(self, value):
2884         self._psetter(self._dbus_interface, "maximumValue", value)
2885     _maximumValueDoc = \
2886         """
2887         The maximum value allowed by this valuator.
2888         """
2889     maximumValue = property(fget=get_maximumValue, fset=set_maximumValue, doc=_maximumValueDoc)
2890     
2891     def get_minimumIncrement(self):
2892         self._pgetter(self._dbus_interface, "minimumIncrement")
2893     def set_minimumIncrement(self, value):
2894         self._psetter(self._dbus_interface, "minimumIncrement", value)
2895     _minimumIncrementDoc = \
2896         """
2897         The smallest incremental change which this valuator allows. If
2898         0, the incremental changes to the valuator are limited only by
2899         the precision of a double precision value on the platform.
2900         """
2901     minimumIncrement = property(fget=get_minimumIncrement, fset=set_minimumIncrement, doc=_minimumIncrementDoc)
2902     
2903     def get_minimumValue(self):
2904         self._pgetter(self._dbus_interface, "minimumValue")
2905     def set_minimumValue(self, value):
2906         self._psetter(self._dbus_interface, "minimumValue", value)
2907     _minimumValueDoc = \
2908         """
2909         The minimum value allowed by this valuator.
2910         """
2911     minimumValue = property(fget=get_minimumValue, fset=set_minimumValue, doc=_minimumValueDoc)
2912
2913 BUTTON_PRESSED_EVENT = EventType(2)
2914
2915 BUTTON_RELEASED_EVENT = EventType(3)
2916
2917 KEY_PRESS = KeySynthType(0)
2918
2919 KEY_PRESSED = KeyEventType(0)
2920
2921 KEY_PRESSED_EVENT = EventType(0)
2922
2923 KEY_PRESSRELEASE = KeySynthType(2)
2924
2925 KEY_RELEASE = KeySynthType(1)
2926
2927 KEY_RELEASED = KeyEventType(1)
2928
2929 KEY_RELEASED_EVENT = EventType(1)
2930
2931 KEY_STRING = KeySynthType(4)
2932
2933 KEY_SYM = KeySynthType(3)
2934
2935 LAYER_BACKGROUND = ComponentLayer(1)
2936
2937 LAYER_CANVAS = ComponentLayer(2)
2938
2939 LAYER_INVALID = ComponentLayer(0)
2940
2941 LAYER_LAST_DEFINED = ComponentLayer(8)
2942
2943 LAYER_MDI = ComponentLayer(4)
2944
2945 LAYER_OVERLAY = ComponentLayer(6)
2946
2947 LAYER_POPUP = ComponentLayer(5)
2948
2949 LAYER_WIDGET = ComponentLayer(3)
2950
2951 LAYER_WINDOW = ComponentLayer(7)
2952
2953 LOCALE_TYPE_COLLATE = LOCALE_TYPE(1)
2954
2955 LOCALE_TYPE_CTYPE = LOCALE_TYPE(2)
2956
2957 LOCALE_TYPE_MESSAGES = LOCALE_TYPE(0)
2958
2959 LOCALE_TYPE_MONETARY = LOCALE_TYPE(3)
2960
2961 LOCALE_TYPE_NUMERIC = LOCALE_TYPE(4)
2962
2963 LOCALE_TYPE_TIME = LOCALE_TYPE(5)
2964
2965 MODIFIER_ALT = ModifierType(3)
2966
2967 MODIFIER_CONTROL = ModifierType(2)
2968
2969 MODIFIER_META = ModifierType(4)
2970
2971 MODIFIER_META2 = ModifierType(5)
2972
2973 MODIFIER_META3 = ModifierType(6)
2974
2975 MODIFIER_NUMLOCK = ModifierType(7)
2976
2977 MODIFIER_SHIFT = ModifierType(0)
2978
2979 MODIFIER_SHIFTLOCK = ModifierType(1)
2980
2981
2982 ROLE_ACCELERATOR_LABEL = Role(1)
2983
2984 ROLE_ALERT = Role(2)
2985
2986 ROLE_ANIMATION = Role(3)
2987
2988 ROLE_APPLICATION = Role(75)
2989
2990 ROLE_ARROW = Role(4)
2991
2992 ROLE_AUTOCOMPLETE = Role(76)
2993
2994 ROLE_CALENDAR = Role(5)
2995
2996 ROLE_CANVAS = Role(6)
2997
2998 ROLE_CAPTION = Role(81)
2999
3000 ROLE_CHART = Role(80)
3001
3002 ROLE_CHECK_BOX = Role(7)
3003
3004 ROLE_CHECK_MENU_ITEM = Role(8)
3005
3006 ROLE_COLOR_CHOOSER = Role(9)
3007
3008 ROLE_COLUMN_HEADER = Role(10)
3009
3010 ROLE_COMBO_BOX = Role(11)
3011
3012 ROLE_DATE_EDITOR = Role(12)
3013
3014 ROLE_DESKTOP_FRAME = Role(14)
3015
3016 ROLE_DESKTOP_ICON = Role(13)
3017
3018 ROLE_DIAL = Role(15)
3019
3020 ROLE_DIALOG = Role(16)
3021
3022 ROLE_DIRECTORY_PANE = Role(17)
3023
3024 ROLE_DOCUMENT_FRAME = Role(82)
3025
3026 ROLE_DRAWING_AREA = Role(18)
3027
3028 ROLE_EDITBAR = Role(77)
3029
3030 ROLE_EMBEDDED = Role(78)
3031
3032 ROLE_ENTRY = Role(79)
3033
3034 ROLE_EXTENDED = Role(70)
3035
3036 ROLE_FILE_CHOOSER = Role(19)
3037
3038 ROLE_FILLER = Role(20)
3039
3040 ROLE_FOCUS_TRAVERSABLE = Role(21)
3041
3042 ROLE_FONT_CHOOSER = Role(22)
3043
3044 ROLE_FOOTER = Role(72)
3045
3046 ROLE_FORM = Role(87)
3047
3048 ROLE_FRAME = Role(23)
3049
3050 ROLE_GLASS_PANE = Role(24)
3051
3052 ROLE_HEADER = Role(71)
3053
3054 ROLE_HEADING = Role(83)
3055
3056 ROLE_HTML_CONTAINER = Role(25)
3057
3058 ROLE_ICON = Role(26)
3059
3060 ROLE_IMAGE = Role(27)
3061
3062 ROLE_INPUT_METHOD_WINDOW = Role(89)
3063
3064 ROLE_INTERNAL_FRAME = Role(28)
3065
3066 ROLE_INVALID = Role(0)
3067
3068 ROLE_LABEL = Role(29)
3069
3070 ROLE_LAST_DEFINED = Role(90)
3071
3072 ROLE_LAYERED_PANE = Role(30)
3073
3074 ROLE_LINK = Role(88)
3075
3076 ROLE_LIST = Role(31)
3077
3078 ROLE_LIST_ITEM = Role(32)
3079
3080 ROLE_MENU = Role(33)
3081
3082 ROLE_MENU_BAR = Role(34)
3083
3084 ROLE_MENU_ITEM = Role(35)
3085
3086 ROLE_OPTION_PANE = Role(36)
3087
3088 ROLE_PAGE = Role(84)
3089
3090 ROLE_PAGE_TAB = Role(37)
3091
3092 ROLE_PAGE_TAB_LIST = Role(38)
3093
3094 ROLE_PANEL = Role(39)
3095
3096 ROLE_PARAGRAPH = Role(73)
3097
3098 ROLE_PASSWORD_TEXT = Role(40)
3099
3100 ROLE_POPUP_MENU = Role(41)
3101
3102 ROLE_PROGRESS_BAR = Role(42)
3103
3104 ROLE_PUSH_BUTTON = Role(43)
3105
3106 ROLE_RADIO_BUTTON = Role(44)
3107
3108 ROLE_RADIO_MENU_ITEM = Role(45)
3109
3110 ROLE_REDUNDANT_OBJECT = Role(86)
3111
3112 ROLE_ROOT_PANE = Role(46)
3113
3114 ROLE_ROW_HEADER = Role(47)
3115
3116 ROLE_RULER = Role(74)
3117
3118 ROLE_SCROLL_BAR = Role(48)
3119
3120 ROLE_SCROLL_PANE = Role(49)
3121
3122 ROLE_SECTION = Role(85)
3123
3124 ROLE_SEPARATOR = Role(50)
3125
3126 ROLE_SLIDER = Role(51)
3127
3128 ROLE_SPIN_BUTTON = Role(52)
3129
3130 ROLE_SPLIT_PANE = Role(53)
3131
3132 ROLE_STATUS_BAR = Role(54)
3133
3134 ROLE_TABLE = Role(55)
3135
3136 ROLE_TABLE_CELL = Role(56)
3137
3138 ROLE_TABLE_COLUMN_HEADER = Role(57)
3139
3140 ROLE_TABLE_ROW_HEADER = Role(58)
3141
3142 ROLE_TEAROFF_MENU_ITEM = Role(59)
3143
3144 ROLE_TERMINAL = Role(60)
3145
3146 ROLE_TEXT = Role(61)
3147
3148 ROLE_TOGGLE_BUTTON = Role(62)
3149
3150 ROLE_TOOL_BAR = Role(63)
3151
3152 ROLE_TOOL_TIP = Role(64)
3153
3154 ROLE_TREE = Role(65)
3155
3156 ROLE_TREE_TABLE = Role(66)
3157
3158 ROLE_UNKNOWN = Role(67)
3159
3160 ROLE_VIEWPORT = Role(68)
3161
3162 ROLE_WINDOW = Role(69)
3163
3164 TEXT_BOUNDARY_CHAR = TEXT_BOUNDARY_TYPE(0)
3165
3166 TEXT_BOUNDARY_LINE_END = TEXT_BOUNDARY_TYPE(6)
3167
3168 TEXT_BOUNDARY_LINE_START = TEXT_BOUNDARY_TYPE(5)
3169
3170 TEXT_BOUNDARY_SENTENCE_END = TEXT_BOUNDARY_TYPE(4)
3171
3172 TEXT_BOUNDARY_SENTENCE_START = TEXT_BOUNDARY_TYPE(3)
3173
3174 TEXT_BOUNDARY_WORD_END = TEXT_BOUNDARY_TYPE(2)
3175
3176 TEXT_BOUNDARY_WORD_START = TEXT_BOUNDARY_TYPE(1)
3177
3178 TEXT_CLIP_BOTH = TEXT_CLIP_TYPE(3)
3179
3180 TEXT_CLIP_MAX = TEXT_CLIP_TYPE(2)
3181
3182 TEXT_CLIP_MIN = TEXT_CLIP_TYPE(1)
3183
3184 TEXT_CLIP_NONE = TEXT_CLIP_TYPE(0)