moved resize functions to its own place
started refactoring to make first basic test pass
made test pass

- updated references to spacer
- fixed some initialisation stuff
added more tests, fixed buttons initialisation

- major cleanup of involved functions
- fixed mode access when initialising buttons
- fixed access to button constructors without global accessor
- added new tests for drawButton