GNOME Bugzilla – Bug 359635
gnome-about doesn't return correct values for text.getRangeExtents()
Last modified: 2009-10-02 09:40:41 UTC
See Orca bug #355524 for more background. I will be attaching two files to this bug: 1/ bug_355524.py - a standalone Python script that replicates the problem. 2/ bug_355524.out - the results of running bug_355524.py. Steps to reproduce: 1. Run gnome-about 2. Run gnome-terminal 3. Run the attached standalone python application in an xterm 4. Click on the gnome-terminal window. Press F11. 5. Click on the gnome-about window. Press F11. Actual Results: Step 4: You will see what a well-behaved application should do. Step 5: You will see output like the following with the following values: (start=0, end=51, x=0, y=0, width=0, height=0) Expected Results: getRangeExtents should produce values that are real
Created attachment 74011 [details] Python script for replicating the problem.
Created attachment 74012 [details] Output from running bug_355524.py F11 output for gnome-terminal starts at line 35. F11 output for gnome-about starts at line 165.
The problem is that atk_get_range_extents is not working for GailCanvasText. The reason is that the function gail_canvas_text_get_character_extents exists but does nothing.
Move to libgnomecanvas since A11Y support of libgnomecanvas has been moved here. BTW, does anyone know how to get the coordinate of a given char_offset for GnomeCanvasText?
(In reply to comment #4) > Move to libgnomecanvas since A11Y support of libgnomecanvas has been moved > here. > > BTW, does anyone know how to get the coordinate of a given char_offset for > GnomeCanvasText? You can query it using the PangoLayout* of the GnomeCanvasText, adjust it by the ink-rect (or logical rect) that is also stored in the text item and everything should work like a charm.
Methinks someone fixed something somewhere. Orca is now doing the right thing, Rich's script is now giving valid numbers. I'll leave it to someone else to close this out since I didn't fix it. ;-)
Closing this based on the last comment.