Yes. The question might be rephrased as “Does spaces indentation prohibit visually-impaired coding?”
Yes, as I think through this situation, several factors come to mind:
- spaced indentation can be detected programmatically by an editor.
- as a sequence of spaces starting at column 0, for example.
- other consecutive spaces are usually before comments.
- other instances of consecutive spaces are rare (or is this not the case?)
print(index) #TEMPORARY DEBUG CODE
- An editor can detect indentation and morph it into something more visually accessible.
- Example: In the case where a very large type size is used, the four spaces can be converted to a single Unicode 160 (a ‘space’ character) and converted back to four spaces at Save.
- Since a mix is not desirable, the questions becomes “Which to use if we have ONLY ONE indent type?”
- spaces are the elemental option, and are therefore the most flexible. Consider: We can make tabs from spaces but can’t make spaces from tabs. The K.I.S.S. principle applies.
Rephrasing the statement above: “This discussion has taken place fully and, as far as we can tell, the reasoning hasn’t changed. If there’s something new to bring to the discussion, then we can re-open this discussion. Otherwise this is a resolved question.”
The bullet points above show that tabs are not the only solution, and are not a universal solution.
(This thread doesn’t belong in the PEPs category)
It might be associated with the PEPs category if the reasoning and conclusions about spaced indentation has not been documented yet; in that case, maybe a PEP should be drafted. HOWEVER, the path to PEP is to start a discussion in Ideas or (better) what used to be Users. [@staff, are we going to create the Discussion category now that we’ve made the two category name changes?] I recommend that this be moved to Discussion if/when the category becomes available.
[EDIT: ] From the cybre.space quote:
Even between blind people there’s [disagreement] about this. The advantage of a tab is that it can be represented by a single character (a ctrl-i) on the display, so it only eats up one cell.
The disadvantage is that any sort of alignment (for example putting the params at the same column as the (from a function) becomes impossible to tell, whereas we can with spaces.
[EDIT: ] Another quote from the cybre.space discussion:
the most important thing is consistency.
My conclusion: This is more of an a11y industry situation than anything else. Hardware can be made more configurable/intelligent and extensions can be created for editors. On the other hand, any changes at the language level are clearly only going to affect a fraction of the overall situation and may make other areas worse, such as braille readers that are expecting spaced indentation. In the case of standards, one has to consider how much established work will be broken by a change. We can do our part better by being consistent and avoiding breaking changes, as the writer of the original Reddit post realized.