Skip to content

Commit

Permalink
Merge pull request #9 from VODGroup/eng
Browse files Browse the repository at this point in the history
whitespaces added
  • Loading branch information
crescentheaded authored Jan 26, 2024
2 parents 45bae2c + f362a8a commit 9d314ab
Show file tree
Hide file tree
Showing 8 changed files with 26 additions and 26 deletions.
2 changes: 1 addition & 1 deletion Sources/AccessibilityDocumentation/Constants.swift
Original file line number Diff line number Diff line change
Expand Up @@ -331,7 +331,7 @@ extension Book {
//extension UIAccessibility.AssistiveTechnologyIdentifier {
//
// @available(iOS 8.0, *)
// public static let notificationSwitchControl: UIAccessibility.AssistiveTechnologyIdentifier
// public static let notificationSwitch Control: UIAccessibility.AssistiveTechnologyIdentifier
//
// @available(iOS 9.0, *)
// public static let notificationVoiceOver: UIAccessibility.AssistiveTechnologyIdentifier
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

Allows to connect external devices and link them to any command. As a result paralyzed people can control a phone by simple signals: finger movement, muscle stretches, etc. Also, a iPhone's camera can recognize facial expression or any sound like a command. In the end user moves focus on screen and pass command to focused element by submenu that is presented after selection.

![Switch control modes: focus groups on elements, cross selection and submenu](SwitchControlOverview)
![Switch control modes: focus groups on elements, cross selection and submenu](Switch ControlOverview)

## How to setup

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Voice Control

Adds additional commands over graphical UI to control a phone by voice commands. A user of VoiceControl can see, but can't touch their phone, as a result he can pronounce commands lite "select Pepperoni", "tap purchase" or "close screen". iPhone recognizes speech, convert it to text and links command to elements' description.
Adds additional commands over graphical UI to control a phone by voice commands. A user of Voice Control can see, but can't touch their phone, as a result he can pronounce commands lite "select Pepperoni", "tap purchase" or "close screen". iPhone recognizes speech, convert it to text and links command to elements' description.

@Metadata {
@PageImage(
Expand All @@ -12,7 +12,7 @@ Adds additional commands over graphical UI to control a phone by voice commands.

## Overview

![Voice Control modes: with labels, enumerated elements or grid](VoiceControlOverview)
![Voice Control modes: with labels, enumerated elements or grid](Voice ControlOverview)

[Video how to use Voice Control](https://www.youtube.com/watch?v=eg22JaZWAgs)

Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ To describe element we can use label, value and trait (like a type)

### Label vs Value

Important to understand differences between label and value. Label should be as short as possible: Voice Control will use it as HUD over UI to name things for feature voice commands, but not show value part, because we expect that it's already presented for user on screen. <doc:VoiceControl>
Important to understand differences between label and value. Label should be as short as possible: Voice Control will use it as HUD over UI to name things for feature voice commands, but not show value part, because we expect that it's already presented for user on screen. <doc:Voice Control>

Otherwise, adjustable elements allow to change only value part and after change only value part will be pronounced to user. <doc:AdjustableElements>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,21 +9,21 @@ Accessibility part of UIKit and SwiftUI frameworks helps developers to represent
There are three main assistance for blind or motion limited users:
@Links(visualStyle: compactGrid) {
- <doc:VoiceOver>
- <doc:VoiceControl>
- <doc:SwitchControl>
- <doc:Voice Control>
- <doc:Switch Control>
}

- **<doc:VoiceOver>** helps blind or low-visioned persons to use a phone by listening audio description of UI and command by different swipes and non-direct touches. Developer prepare text description of the element, iPhone will generate voice description from text.

![VoiceOver gestures](VoiceOverGestures)

- **<doc:VoiceControl>** adds additional commands over graphical UI to control a phone by voice commands. A user of VoiceControl can see, but can't touch their phone, as a result he can pronounce commands lite "select Pepperoni", "tap purchase" or "close screen". iPhone recognizes speach, convert it to text and links command to elements' description.
- **<doc:Voice Control>** adds additional commands over graphical UI to control a phone by voice commands. A user of Voice Control can see, but can't touch their phone, as a result he can pronounce commands lite "select Pepperoni", "tap purchase" or "close screen". iPhone recognizes speach, convert it to text and links command to elements' description.

![Voice Control modes: with labels, enumerated elements or grid](VoiceControlOverview)
![Voice Control modes: with labels, enumerated elements or grid](Voice ControlOverview)

- **<doc:SwitchControl>** allows to connect external devices and link them to any command. As a result paralyzed people can control a phone by simple signals: finger movement, muscle stretches, etc. Also, a iPhone's camera can recognize facial expression or any sound like a command. In the end user moves focus on screen and pass command to focused element by submenu that is presented after selection.
- **<doc:Switch Control>** allows to connect external devices and link them to any command. As a result paralyzed people can control a phone by simple signals: finger movement, muscle stretches, etc. Also, a iPhone's camera can recognize facial expression or any sound like a command. In the end user moves focus on screen and pass command to focused element by submenu that is presented after selection.

![Switch control modes: focus groups on elements, cross selection and submenu](SwitchControlOverview)
![Switch control modes: focus groups on elements, cross selection and submenu](Switch ControlOverview)

> Note: Watch [Apple's playlist about Accessibility ](https://www.youtube.com/playlist?list=PLIl2EzNYri0cLtSlZowttih25VnSvWITu) for inspiration
Expand All @@ -47,14 +47,14 @@ Step by step practice course.
@TabNavigator {
@Tab("Switch Control") {
Allows to connect external devices and link them to any command. As a result paralyzed people can control a phone by simple signals: finger movement, muscle stretches, etc. Also, a iPhone's camera can recognize facial expression or any sound like a command. In the end user moves focus on screen and pass command to focused element by submenu that is presented after selection.
![Switch control modes: focus groups on elements, cross selection and submenu](SwitchControlOverview)
![Switch control modes: focus groups on elements, cross selection and submenu](Switch ControlOverview)
}


@Tab("Voice Control") {
Adds additional commands over graphical UI to control a phone by voice commands. A user of VoiceControl can see, but can't touch their phone, as a result he can pronounce commands lite "select Pepperoni", "tap purchase" or "close screen". iPhone recognizes speach, convert it to text and links command to elements' description.
Adds additional commands over graphical UI to control a phone by voice commands. A user of Voice Control can see, but can't touch their phone, as a result he can pronounce commands lite "select Pepperoni", "tap purchase" or "close screen". iPhone recognizes speach, convert it to text and links command to elements' description.

![Voice Control modes: with labels, enumerated elements or grid](VoiceControlOverview)
![Voice Control modes: with labels, enumerated elements or grid](Voice ControlOverview)
}

@Tab("Voice Over") {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
@Tutorial(time: 10) {
@Intro(title: "Adopting Cell") {

To have assistive technology work as intented sometimes it is needed to **simplify complex cells** to such degree so there is no difference for accessibility features between *differentiated abstractions* that are stored in the cell. In other words, if there is a cell with pizza's description it is understandable to distinguish data by its nature: have an image as an illustration, a title, a list of ingridients and a price - but it complicates the work for VoiceOver, VoiceControl and SwitchControl. Such layout makes it adapt the cell's contents **wrong**. Let's take a look of what can be done to help our digital assistants navigate through the cognitive models we come up with,.
To have assistive technology work as intented sometimes it is needed to **simplify complex cells** to such degree so there is no difference for accessibility features between *differentiated abstractions* that are stored in the cell. In other words, if there is a cell with pizza's description it is understandable to distinguish data by its nature: have an image as an illustration, a title, a list of ingridients and a price - but it complicates the work for VoiceOver, Voice Control and Switch Control. Such layout makes it adapt the cell's contents **wrong**. Let's take a look of what can be done to help our digital assistants navigate through the cognitive models we come up with,.

}

Expand Down Expand Up @@ -208,7 +208,7 @@
```

@Justification(reaction: "Try again!") {
**VoiceOver *doesn't* distinguish such pieces of data**, but **VoiceControl *has to have* price as a part of the element's label** in order to use it correctly.
**VoiceOver *doesn't* distinguish such pieces of data**, but **Voice Control *has to have* price as a part of the element's label** in order to use it correctly.
}
}

Expand All @@ -221,7 +221,7 @@


@Justification(reaction: "That's right!") {
VoiceControl will have a simple label, VoiceOver reads the price before the ingredients (because it's more important). Good job!
Voice Control will have a simple label, VoiceOver reads the price before the ingredients (because it's more important). Good job!
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,20 +35,20 @@

@Section(title: "Backward Compatibility") {
@ContentAndMedia {
VoiceControl and SwitchControl work with separate *buttons* instead of *adjustable elements*.
Voice Control and Switch Control work with separate *buttons* instead of *adjustable elements*.
}

@Steps {
@Step {
> Important: Adjustable elements are only used for VoiceOver and will break the behaviour of VoiceControl and SwitchControl.
> Important: Adjustable elements are only used for VoiceOver and will break the behaviour of Voice Control and Switch Control.

Distinguish their behaviour in code by a dynamic getter:

@Code(name: "", file: "AdjustableTutorialStep_4.swift")
}

@Step {
SwitchControl requires grouping: firstly focus will be placed on the group itself, afterwards the selection will be moved between elements of this group. It simulates navigation by reducing the number of elements on each level.
Switch Control requires grouping: firstly focus will be placed on the group itself, afterwards the selection will be moved between elements of this group. It simulates navigation by reducing the number of elements on each level.

> Note: Watch video [How Grouping Simplifies Navigation](https://youtube.com/shorts/1l8H615EkV0?si=tKyhIGjBbR9XG9HP)

Expand All @@ -62,7 +62,7 @@
What assistive technologies use adjustable trait?

@Choice(isCorrect: false) {
SwitchControl
Switch Control


@Justification(reaction: "Try again!") {
Expand All @@ -84,7 +84,7 @@


@Justification(reaction: "Try again!") {
VoiceControl is mostly used by people who are able to see. In such case percieving elements as separate buttons is preferred.
Voice Control is mostly used by people who are able to see. In such case percieving elements as separate buttons is preferred.
}
}
}
Expand Down
8 changes: 4 additions & 4 deletions Sources/AccessibilityDocumentation/UIAccessibility_.swift
Original file line number Diff line number Diff line change
Expand Up @@ -636,15 +636,15 @@ public class Book {


/**
Use UIAccessibilityIsSwitchControlRunning() to determine if Switch Control is running.
Listen for UIAccessibilitySwitchControlStatusDidChangeNotification to know when Switch Control starts or stops.
Use UIAccessibilityIsSwitch ControlRunning() to determine if Switch Control is running.
Listen for UIAccessibilitySwitch ControlStatusDidChangeNotification to know when Switch Control starts or stops.
*/
@available(iOS 8.0, *)
public static var isSwitchControlRunning: Bool { false }
public static var isSwitch ControlRunning: Bool { false }


@available(iOS 8.0, *)
public static let switchControlStatusDidChangeNotification: NSNotification.Name = .init("")
public static let Switch ControlStatusDidChangeNotification: NSNotification.Name = .init("")


/// Returns whether the system preference for Speak Selection is enabled
Expand Down

0 comments on commit 9d314ab

Please sign in to comment.