Entity component framework refactor part 1

Began refactoring code into an entity component system. Wrote the
beginning of a simple gui library. Wrote the beginning of an editor.