Seprated the parsing code and cleaned up the GUI a little bit