started to rewrite the gui again