refactoring GUIGenerator