-
Notifications
You must be signed in to change notification settings - Fork 985
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Narrator focus is not moving in proper logical order when user is navigating by using caps + arrow keys (tab index is ignored) #2164
Comments
Workaround: to add the controls to the Form.Controls in order accordingly to Tab index. |
I have played around with this suggestion and I don't think its applicable in general. WinForms designer appears to place controls in reverse order in the Form.Controls, the most recent control being at the front of the collection. When I look more closely the display order also is like this, the first control is on top and the last control is on bottom. For some reason ControlsCollection is in reverse order, so you need your top left control last and the bottom right first, sorting after TabIndex will screw things up I think. Usually I place TabIndex in text-flow order (left to right, top to bottom for me) but if you order controls after TabIndex they'll display in reverse (right to left, bottom to top) which will cause problems when things overlap - e.g. when text doesn't fit my autosized labels to the left of my textboxes they are supposed to overlap under the textbox, not over it, which appears to be not possible anymore when sorting after TabIndex. I'm a bit confused why the ControlsCollection is in reverse, never had payed much attention to it, but I'm sure there's a good technical reason for it ... |
Thank you for your comment @weltkante! It seems to me that minimal impact can be achieved by implementing custom accessible navigation for the form inner controls accordingly to tab index without changing the actual control order in the ControlsCollection. |
Yup its probably best to keep those concerns separated, the workaround described above is just that - a workaround - not something that can be done in general. ControlCollection order is strictly linked to display order and not something one can change freely when things overlap. |
Z-order? |
Z-order is applicable to the case when in the hierarchy of Form's control we have something like this:
Do you mean this case? How the reversed order of Form controls [Control 3, Control 2, Control 1] can help with it? Sorry if I missed something. |
I think that was just a response to me wondering about the reverse ControlsCollection order |
Problem description:
Narrator focus is not moving in proper logical order when user is navigating by using caps + arrow keys: Narrator goes thru the controls in order which is the order of controls being added to the Controls collection of the form in design time (order of controls can be corrected by manual changing the order of adding the control to the collection of child controls.
Actual behavior:
Expected behavior:
Narrator caps + arrow navigation should take into account control tab index and accessible hierarchy should also take into account control tab index.
Minimal repro:
The text was updated successfully, but these errors were encountered: