Re: AT-SPI standard's management of text objects



Hello,

Ksamak, on Mon 21 Nov 2016 16:00:05 +0100, wrote:
            if text and (text.caretOffset >= 0):
                offset = text.caretOffset
                if offset == text.characterCount:
                    offset -= 1

So if the string is empty, offset becomes -1, and thus atk duly reports
this as bogus. I have added this after:

                if offset == 0:
                    offset = 0

                [x, y, width, height] = text.getCharacterExtents(offset, 0)

And now it gets correct results in various gtk2/3, qt5 apps.  It however
still reproduces in firefox, I'm having a look.

Samuel


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