Refactoring of UI and Shapes