Accessibility/RichContentKeyboardBehaviour: Difference between revisions

Jump to navigation Jump to search
m
Line 152: Line 152:
=== Navigation by words ===
=== Navigation by words ===


The following conditions are considered under assumption the user navigates by words (ctrl or alt (option) + left/right arrow key depending on platform).
The following conditions are considered under assumption the user navigates forward by words (ctrl or alt (option) + left/right arrow key depending on platform and text direction). The rules defined below are inverse if user moves backward.


If the caret position is somewhere in the middle of the rich text and the integral element is next on the way (i.e. its rich word is the next word) then the caret should be set before or after the rich element depending on the navigation direction. If the caret is before the integral element then the element should be skipped and the caret should be moved to the begin of the next word or in the case if there is no next word it should be moved to position after the element.
==== Integral element ====
 
If the caret position is somewhere in the middle of the rich text and the integral element is next on the way (i.e. its rich word is the next word) then the caret should be set before the rich element. If the caret is before the integral element then the element should be skipped and the caret should be set before the next word.


For example,
For example,
Line 160: Line 162:
Enter <input value="number"> in pixels.
Enter <input value="number"> in pixels.
</pre>
</pre>
If the initial caret position is before 'Enter' word then it should be moved before the input element, then before the 'in' word.
If the initial caret position is before 'Enter' word then the caret should be moved before the input element, then after the input element (before the space preceding the 'in' word) and then before the 'pixels' word.
 
If the caret is on the integral element and the rich word is empty (i.e. the caret is between its boundary characters) then the caret position should be set before the next word.
 
For example, if the HTML button is focused (which is treated the caret is on the element) then the caret should be set immediately after the button.


If the compound element is next on the way (i.e. the first word of its sentence is next word) then the caret should be set before the element (i.e. before the first word of the rich sentence). If the caret is before the rich element then the caret moved before the begin of the second word of the sentence. If the the sentence consist of one word then the caret should be moved before the word following the sentence.
==== Compound element ====
 
If the compound element is next on the way (i.e. the first word of its sentence is next word) then the caret should be set before the element. If the caret is before the element then it should be moved before the begin of the second word of the sentence. If the the sentence consist of one word then the caret should be moved before the word following the sentence.


For example,
For example,
Line 168: Line 176:
See <a>this report</a> for more details.
See <a>this report</a> for more details.
</pre>
</pre>
If the user moves by words and initial caret position is before the 'See' word then caret should be set before the empty character of the 'this' word, before 'report' word and the 'for' word.
If the initial caret position is before the 'See' word then caret should be set before the empty character of the 'this' word, before 'report' word and then before the 'for' word.
 
So that the compound element is processed as a normal text.


If the caret is in the middle of the rich sentence then the user should navigate the whole sentence by words.
If the caret is in the middle of the rich sentence then the user should navigate the whole sentence by words.


For example, if the caret is inside of the anchor then the caret should be moved by words of the anchor text.
For example, if the caret is inside of the anchor then the caret should be moved by words of the anchor text.
If the caret is on the integral element and the rich word is empty (i.e. the caret is between its boundary characters) then the caret position should be set before the next word.
For example, if the HTML button is focused (which is treated the caret is on the element) then the caret should be set immediately after the button.


If the caret is inside of (or on) focusable rich element and the caret goes out of the element then the area where the element is placed should be focused.
If the caret is inside of (or on) focusable rich element and the caret goes out of the element then the area where the element is placed should be focused.
Confirmed users
1,396

edits

Navigation menu