Re: [orca-list] eclipse and status line



Hi Will,

After apply the suggested defense I got the following error:

Traceback (most recent call last):
File "/usr/local/lib/python2.5/site-packages/orca/input_event.py", line 186, in processInputEvent
    consumed = self.function(script, inputEvent)
File "/usr/local/lib/python2.5/site-packages/orca/default.py", line 2540, in getStatusBar
    return self.whereAmI.speakStatusBar(orca_state.locusOfFocus)
File "/usr/local/lib/python2.5/site-packages/orca/where_am_I.py", line 1796, in speakStatusBar
    self._speakDefaultButton(window)
File "/usr/local/lib/python2.5/site-packages/orca/where_am_I.py", line 1901, in _speakDefaultButton
    defaultButton = self._getDefaultButton(obj)
File "/usr/local/lib/python2.5/site-packages/orca/where_am_I.py", line 1887, in _getDefaultButton
    defaultButton = self._getDefaultButton(child)
File "/usr/local/lib/python2.5/site-packages/orca/where_am_I.py", line 1887, in _getDefaultButton
    defaultButton = self._getDefaultButton(child)
File "/usr/local/lib/python2.5/site-packages/orca/where_am_I.py", line 1887, in _getDefaultButton
    defaultButton = self._getDefaultButton(child)
File "/usr/local/lib/python2.5/site-packages/orca/where_am_I.py", line 1887, in _getDefaultButton
    defaultButton = self._getDefaultButton(child)
File "/usr/local/lib/python2.5/site-packages/orca/where_am_I.py", line 1887, in _getDefaultButton
    defaultButton = self._getDefaultButton(child)
File "/usr/local/lib/python2.5/site-packages/orca/where_am_I.py", line 1887, in _getDefaultButton
    defaultButton = self._getDefaultButton(child)
File "/usr/local/lib/python2.5/site-packages/orca/where_am_I.py", line 1887, in _getDefaultButton
    defaultButton = self._getDefaultButton(child)
File "/usr/local/lib/python2.5/site-packages/orca/where_am_I.py", line 1887, in _getDefaultButton
    defaultButton = self._getDefaultButton(child)
File "/usr/local/lib/python2.5/site-packages/orca/where_am_I.py", line 1882, in _getDefaultButton
    state = child.getState()
AttributeError: 'NoneType' object has no attribute 'getState'

After I got this error I included the same suggested code before line 1882.

            if not child:
                continue
            state = child.getState()

No more erros. However I can not get the content of the status line.

It seems that eclipse doesn't provide a status bar. I remember that when I was a jaws user, I could access something like a status bar. In this component I could read information about line and collumn position, and error messages.

Thanks.

On 14-03-2009 20:57, Willie Walker wrote:
Bummer - looks like it might be some sort of unfortunate garbage in eclipse's accessibility hierarchy. The relevant code around line 1840 in where_am_I.py looks like this -- 'child' should never be None:

        for child in obj:
            # debug.println(self._debugLevel,
            #               "_findStatusBar: child=%s, %s" % \
# (child.getRole(), self.getObjLabelAndName(child)))
            if child.getRole() == pyatspi.ROLE_STATUS_BAR:

If you want to try experimenting, you might try adding something defensive code like this before the check for "if child.getRole()....":

            if not child:
                continue

Let me know if this works,

Will

Jose Vilmar Estacio de Souza wrote:
Hi all,

While debugging orca in a try to identify the problem reported in my previous message, I found the following, error which I believe is related to the problem reported.

Traceback (most recent call last):
File "/usr/local/lib/python2.5/site-packages/orca/input_event.py", line 186, in processInputEvent
    consumed = self.function(script, inputEvent)
File "/usr/local/lib/python2.5/site-packages/orca/default.py", line 2540, in getStatusBar
    return self.whereAmI.speakStatusBar(orca_state.locusOfFocus)
File "/usr/local/lib/python2.5/site-packages/orca/where_am_I.py", line 1791, in speakStatusBar
    self._getStatusBar(results[0])
File "/usr/local/lib/python2.5/site-packages/orca/where_am_I.py", line 1845, in _getStatusBar
    self._getStatusBar(child)
File "/usr/local/lib/python2.5/site-packages/orca/where_am_I.py", line 1845, in _getStatusBar
    self._getStatusBar(child)
File "/usr/local/lib/python2.5/site-packages/orca/where_am_I.py", line 1845, in _getStatusBar
    self._getStatusBar(child)
File "/usr/local/lib/python2.5/site-packages/orca/where_am_I.py", line 1845, in _getStatusBar
    self._getStatusBar(child)
File "/usr/local/lib/python2.5/site-packages/orca/where_am_I.py", line 1845, in _getStatusBar
    self._getStatusBar(child)
File "/usr/local/lib/python2.5/site-packages/orca/where_am_I.py", line 1845, in _getStatusBar
    self._getStatusBar(child)
File "/usr/local/lib/python2.5/site-packages/orca/where_am_I.py", line 1845, in _getStatusBar
    self._getStatusBar(child)
File "/usr/local/lib/python2.5/site-packages/orca/where_am_I.py", line 1845, in _getStatusBar
    self._getStatusBar(child)
File "/usr/local/lib/python2.5/site-packages/orca/where_am_I.py", line 1840, in _getStatusBar
    if child.getRole() == pyatspi.ROLE_STATUS_BAR:
AttributeError: 'NoneType' object has no attribute 'getRole'

Actualy I am running latest orca from trunk and eclipse build I20090313-0100.

To reproduce try the following steps:

1) Run orca and redirect the stder output to a file
orca 2>orca2.txt

2) Launch eclips.

3) After eclipse is loaded press the sequence key to read the status bar. In my case it is mapped to orca_key+pageDown. No output from orca.

4) List the file orca2.txt created in the step 1 and the erro must be present.

Thanks.

On 14-03-2009 11:13, Jose Vilmar Estacio de Souza wrote:
Hi all,
Using eclipse and orca I can not access the status line of eclipse.
Any ideas?
Thanks.




--
José Vilmar Estácio de Souza
Informal Informatica
msn: vilmar informal com br
aim: zevilmar
gmail: jvilmar gmail com
fone: +55 21-2555-2650
cel: +55 21-8868-0859





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]