More work on the gui system.