Fixed Redo/Undo bugs. Changed the way menu is printed.