[Idle-dev] Making Python Speech-Friendly Under IDLE
David Scherer
dscherer@cmu.edu
Tue, 5 Dec 2000 12:46:23 -0500
> Is anyone interested in making Python's
> whitespace (tabs) more speech-friendly under IDLE?
How would this be done? I don't know anything about the conventions used
for such things.
if x<>y:
if x<3:
x = x + 1
x = x + y
Saying each tab character where it appears gives:
"if x not equal y colon; tab if x less than 3 colon; tab tab x equals x plus
1; tab x equals x plus y"
Saying the invisible DEDENT tokens gives:
"if x not equal y colon; if x less than 3 colon; x equals x plus 1; dedent;
x equals x plus y; dedent"
Or, equivalently you could invent an "end if":
"if x not equal y colon; if x less than 3 colon; x equals x plus 1; end if;
x equals x plus y; end if"
How about using pitch? My background in music theory is limited to having
played the piano when I was six, but something like:
(C3)"if x not equal y colon"
(E3)"if x less than 3 colon"
(G3)"x equals x plus 1"
(E3)"x equals x plus y"
Any other ideas? I don't think I will have time to work on this, but I can
kibitz ;)
Dave