implementing a GUI