After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 498687 - No getText method
No getText method
Status: RESOLVED NOTABUG
Product: dogtail
Classification: Deprecated
Component: Framework
unspecified
Other opensolaris
: Normal normal
: ---
Assigned To: Dogtail Maintainers
Dogtail Maintainers
Depends on:
Blocks:
 
 
Reported: 2007-11-21 06:47 UTC by Patrick
Modified: 2007-11-26 16:25 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Patrick 2007-11-21 06:47:06 UTC
Try to use Application in script with pyatspi branch:

class EogApp(Application):
    def __init__(self):
        Application.not__init__(self, root.application("eog"))
        ...

Error output:
  • File "/usr/lib/python2.4/vendor-packages/dogtail/tree.py", line 198 in not__init__
    self.__text = self.__accessible.getText()
AttributeError: 'Application' object has no attribute 'getText'


There is not getText method, only have _getText.

Also not getEditableText() and getEditableText()
Comment 1 Michal Babej 2007-11-23 19:31:55 UTC
Zack prepended all methods which are not supposed to be used anymore with "not" So methods like not__init__, not__getattr__ and not_setattr__ are deprecated and should not be used. 

If you wonder if __init__ is missing, please see the end of tree.py:

Accessibility.Accessible.__bases__ = (Node,) + Accessibility.Accessible.__bases__
...

this line inserts Node into Accessible's base classes, so every Accessible automagically becomes a Node, and Accessible's __init__ is used.

The two __?etattr__ methods were replaced by properties.
Comment 2 Zack Cerza 2007-11-26 16:25:56 UTC
Yes, the not_* methods are only still in svn to remind me of which functionality has yet to be ported over in the branch.