added pane class, cleaned up mainwindow