Initial refactor and tests of the text_box class (and derived classes)
First of a series of proposed commits to simplify, reduce duplication, and add testing to box classes
A few things to discuss here, I think.
Proposing to move many of the 'demo' functions to a demo class so that the code files can be pure implementation. Proposing to settle on Tk as the windowing tool, and strip out the UI intermediate layer - we are pretty settled on Tk...
If this looks good, I've got some (local) commits to do a similar refactor for other box classes.
The imports and usage of the methods should all be staying the same here: due to the way that we set the easygui.__init__.py __all__ we should still be able to import textbox, codebox, and exceptionbox in the same way as before.
I think that is the main refactor done. Most boxes now inherit from an AbstractBox which allows for a good amount of code re-use.
Things that I'd like to do pre-merge:
- go through each type of box and compare before-and-after screenshots (padding changes etc might be nasty)
- list the breaking changes (there are a handful of them ... which I think are worthwhile ... but should be clear and explicit(
- test out the demos to confirm that I've not broken any sensible use cases ... and then merge this to master.
Once the refactor lands, then I think that we can do some tidying up of the docs and finally make some headway on the open issues / bugs / feature requests that have been stacking up.