This patch adds preliminary support for speed-typing with code samples, should the user chooses so.
The changes can be summarized as follows:
Introducing "extensibility points" in the speed-type code which use gb-specific functions.
Added some defcustom to allow the user to choose if the text used to practice would be extracted from english texts, or from a list of github urls. There's now a defgroup "speed-type" and two defcustoms (for choosing among english or code, and to customize which urls to take code samples from).
Some preliminary functions to properly display Java code snippets for practicing.
I've tried not to mess the original code up too much. The "extensibility points" are just switch-case blocks to choose alternatives according to the user setting. Not very elegant, but easy to understand. However, for supporting additional types of content it'd probably need a cleaner approach than the suggested here.
This patch adds preliminary support for speed-typing with code samples, should the user chooses so.
The changes can be summarized as follows:
I've tried not to mess the original code up too much. The "extensibility points" are just switch-case blocks to choose alternatives according to the user setting. Not very elegant, but easy to understand. However, for supporting additional types of content it'd probably need a cleaner approach than the suggested here.