After the page is loaded and rendered (and even durring these processes), the focus can the guide the browsing inside every webpage, even those don't have "focusable elements embedded on it" though and TAB usage, right ?! I think one limitation of this approach is that this browsing between them must to occur according with a fixed and previously defined 'tabIndex' sequence.
I implementing a feature that enable this switching guided by the arrows in the keyboard, I mean moving the focus on a web page though "Up", "Down", "Left" and "Right" arrows, so the order of the focus selection will not be determined by the "tabIndex" HTML parameter on a web page .
To do this, I must to know at runtime the X and Y coordinates of each focusable element in the webpage to calculate the next to get the focus according with the direction clicked by the user. I have algorithms to provide this functionality that is IMHO, very useful. Some time ago I did an seemed implementation, but using another application (not a browser) using SVG and the Batik framework.
I wanna know from you how viable is this feature in a implementational point of view. Where can I found the data or what struct can provide me them !? Is it related with layout objects and DOM objects, and retrieve information from them about each focusable element !?
I hope this gives you insight!!! :)
This one of my doubts: does every thing shown on a page (focusable and non-focusable, text, html form, and so on) has a "corresponding" node in the dom tree related with it ?!
Yes, but the mapping is not one-to-one.
Hummm ... I got your point of view. This would be a special (and hard) case, but I think if exist two different focusable locations like in this case, aren't they treated as non-related "elements" !?
Depends on what you mean by "elements", I guess. We manage to keep the focus state separate, but only by keeping track of both the focused layout object _and_ the focused DOM node.
interesting :)
Cheers and thanks again .
___________________________ AntÃnio Gomes Nokia Technology Institute (INdT)
"... but my whole life I've been writing my own tools for my own use. I'll survive ..." (Torvalds, Linus)
_______________________________________________ mozilla-layout mailing list [email protected] http://mail.mozilla.org/listinfo/mozilla-layout
