[Kde-accessibility] Review Request: Adding Accessibility Interfaces for Dolphin Views & Widgets

Frederik Gladhorn gladhorn at kde.org
Tue Aug 14 14:14:04 UTC 2012



> On Aug. 13, 2012, 2:50 p.m., Frank Reininghaus wrote:
> > dolphin/src/kitemviews/kitemlistviewaccessible.h, line 16
> > <http://git.reviewboard.kde.org/r/105972/diff/2/?file=77302#file77302line16>
> >
> >     On the other hand, I see lots of QModelIndex and friends here, which is something I don't particularly like. After all, the basic idea of the new view engine is to get rid of Qt's itemviews.
> >     
> >     Is there an easy way to do it without Qt's itemviews?
> 
> Frederik Gladhorn wrote:
>     This is a very good point. For Qt 4 there is no way to avoid QModelIndex since it's in the public API. I will look into this for Qt 5 since it's definitively something we don't want to rely on.
> 
> Frank Reininghaus wrote:
>     It would be nice if the Qt itemviews dependency could be dropped with Qt 5.
>     
>     Concerning the public API: the Qt docs don't seem to contain anything about QAccessibleTable2Interface and QAccessibleObjectEx, or am I missing something?

I just checked, Qt 5 doesn't have QModelIndex in the API any more, we actually cleaned that up.
Regarding documentation: We never officially committed to the IAccessible2 like interfaces for Qt 4, so they are marked as internal, you can find some documentation in src/gui/qaccessible2.cpp (a little in Qt 4 and some more up to date one in Qt 5). Currently our plan is to make it official in Qt 5.1. This implementation is actually very good to validate what is problematic with the APIs, thus I'm happy for the feedback.


> On Aug. 13, 2012, 2:50 p.m., Frank Reininghaus wrote:
> > dolphin/src/kitemviews/kitemlistviewaccessible.cpp, line 67
> > <http://git.reviewboard.kde.org/r/105972/diff/2/?file=77303#file77303line67>
> >
> >     I think this will fail when grouping is enabled.
> 
> Frederik Gladhorn wrote:
>     Frank, maybe you can give some guidance here. I didn't have time to carefully read the KItemListView etc code, but for me the row/column count/positions etc were a bit off. I wonder if there is a general problem in the code or maybe just an off-by-one somewhere.
> 
> Frank Reininghaus wrote:
>     You're right, the rowCount issue is more tricky than it looks at first sight, at least when grouping is enabled. Just leave it as it is at the moment, I will look into that.
>     
>     About the "row/column positions that are a bit off": the QAccessible::updateAccessibility() calls always add 1 to the current index, that looks strange and might be the cause of an off-by-one error. Or is there a reason why 1 has to be added?

Yes, the +1 is one of the really ugly sides in Qt 4 accessibility. It's required, because we index children 1-based (0 is the item itself, 1 the first child). In Qt 5 this has been removed and the API is a lot more intuitive. For the time being this will have to stay this way though. I will happily do the Qt 5 port in the near future.


- Frederik


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/105972/#review17313
-----------------------------------------------------------


On Aug. 13, 2012, 5:50 a.m., Amandeep Singh wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://git.reviewboard.kde.org/r/105972/
> -----------------------------------------------------------
> 
> (Updated Aug. 13, 2012, 5:50 a.m.)
> 
> 
> Review request for Dolphin, KDE Base Apps and KDE Accessibility.
> 
> 
> Description
> -------
> 
> Added Accessibility Interfaces for Dolphin Views & Widgets, to make it accessible.
> 2 New files added in dolphin/ src/ kitemviews/ kitemlistviewaccessible.* that contain the three new classes.
> 
> 
> Diffs
> -----
> 
>   dolphin/src/CMakeLists.txt 5c1a6da 
>   dolphin/src/kitemviews/kitemlistcontainer.cpp 5500851 
>   dolphin/src/kitemviews/kitemlistcontroller.cpp 88f5d9f 
>   dolphin/src/kitemviews/kitemlistselectionmanager.cpp 383914d 
>   dolphin/src/kitemviews/kitemlistview.h 5723b9a 
>   dolphin/src/kitemviews/kitemlistview.cpp 72b3fd8 
>   dolphin/src/kitemviews/kitemlistviewaccessible.h PRE-CREATION 
>   dolphin/src/kitemviews/kitemlistviewaccessible.cpp PRE-CREATION 
>   dolphin/src/kitemviews/private/kitemlistviewlayouter.h da5bd1d 
>   dolphin/src/tests/CMakeLists.txt 3f906d1 
> 
> Diff: http://git.reviewboard.kde.org/r/105972/diff/
> 
> 
> Testing
> -------
> 
> Focus-tracking tested with KMag / KWin. 
> 
> 
> Thanks,
> 
> Amandeep Singh
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-accessibility/attachments/20120814/558f743c/attachment.html>


More information about the kde-accessibility mailing list