How can I force VoiceOver to read parentheses for math expressions like this:
Text("(2+3)×4") // VoiceOver: Two plus three, times four
I’m looking for a way to have VoiceOver announce parentheses (e.g. “left paren”, “right paren”) without relying on NumberFormatter.Style.spellOut
or .speechAlwaysIncludesPunctuation()
, as both have drawbacks.
Using .spellOut
breaks braille output and Rotor › Characters menu by turning numbers and symbols into words. And .speechAlwaysIncludesPunctuation()
makes VoiceOver overly verbose—for example, it reads “21” as “twenty hyphen one.”
Is there a better way to selectively announce specific punctuation like parentheses while keeping numbers and symbols intact for braille and Rotor use?
Hello,
There doesn't appear to be a way to do this with existing API.
.speechAlwaysIncludesPunctuation() comes close in intent with "You might use this for code or other text where the punctuation is relevant".
Please send us an enhancement request using the Feedback Assistant so that we can consider how to improve the API for your use cases.