Re: Clarification sought regarding aria-setsize and aria-posinset

Hey Joseph.

On 03/10/2014 12:08 PM, Joseph Scheuhammer wrote:
> If the spreadsheet is large enough, I presume, perhaps incorrectly, that
> oocalc does not load all of the cells into memory from the hard drive
> until the user scrolls to them.  If that is the case, what exists in
> ATK/AT-SPI for the subset of the cells that are loaded? Put another way,
> what does oocalc expose through ATK for the partial load, specifically,
> the number of cells and the position in the set?

In that particular instance, the number of cells is the child count; the
position in the set is the index in parent. This is contrary to what
ATK_STATE_MANAGES_DESCENDANTS suggests should (reliably) be the case,
mind you.

At the moment, ATs -- at least freedesktop ATs -- have to check the
following to answer the questions of set size and position in set:

1. Presence of ATK_STATE_MANAGES_DESCENDANTS. This suggests that
   looking at the child count and index in parent cannot be trusted and
   that you need to check the following -- unless you are in Calc, in
   which case go immediately to 5.

2. Presence of ATK_RELATION_NODE_PARENT_OF. This should give you the
   answers in the case of #1 above. But it might not depending on the
   implementation.

3. Presence of ATK_RELATION_NODE_CHILD_OF. It's older and less
   performant than #2, but if you cannot trust the child count, and
   there is no ATK_RELATION_NODE_PARENT_OF to be found, the answers
   might be here.

4. Object attributes -- that's if you're in ARIA. Or possibly Gecko,
   even if it's not ARIA. Desktop toolkits don't do this.

5. If all else fails, hope the child count and index in parent can
   be trusted.

I think what the improvements to ATK (and in turn AT-SPI2) may be is two
new methods:

a. get_set_size()
b. get_position_in_set()

Seems like that would be a more reliable -- and implementation-agnostic
-- way for ATs to get the needed information to pass along to end users.

Related aside: Are the ATs on other platforms having to play a similar
game of "go fish" when trying to present things like set size and
position in set?

--joanie

Received on Tuesday, 11 March 2014 01:41:19 UTC