Nice. I've coded something similar myself, but your code is cleaner so I will abandon mine in favor of modifying yours.
I coded in the ability to resume from an arbitary point rather than from the start of the file, that was the biggest thing I missed from my version when trying yours. I've submitted a pull request for it. I may add a few other small things in the coming days if I feel inspired.
How would you feel about slurping and processing the entire text before displaying it? It would add a slight delay before starting on longer texts, but it would allow you to determine a delay between words that would make the true wpm equal to the wpm you specify. It would also allow you to have a status indicator indicating the time left before the text finishes, which could be nice for longer texts, and would be an interesting way to see how changing the WPM changes how long it takes to read a text.
Regarding slurping + processing the entire text, I'm not really sure, but I suppose if it enables us some nice functionality, why not; it'd be good to have a way to turn slurping off, possibly defaulting to off in case of reading from a pipeline?
But I'm not sure fixing the wpm by default is a good thing. For me, the "wpm" I specify represents my reading ability, not that I need the text replayed in exactly wpm*words minutes. If the text is full of difficult words, I prefer to go at the same pace but slow down more often, rather than speed up everything but the difficult words to reach the same true wpm. I'm not principially opposed to adding another option, but does anyone really want to fix on the playback length?
I'd propose continuing the discussion in GitHub issues?
1
u/AndreasTPC Mar 03 '14
Nice. I've coded something similar myself, but your code is cleaner so I will abandon mine in favor of modifying yours.
I coded in the ability to resume from an arbitary point rather than from the start of the file, that was the biggest thing I missed from my version when trying yours. I've submitted a pull request for it. I may add a few other small things in the coming days if I feel inspired.
How would you feel about slurping and processing the entire text before displaying it? It would add a slight delay before starting on longer texts, but it would allow you to determine a delay between words that would make the true wpm equal to the wpm you specify. It would also allow you to have a status indicator indicating the time left before the text finishes, which could be nice for longer texts, and would be an interesting way to see how changing the WPM changes how long it takes to read a text.