begin of GUI implementation