[DEV] add charactercode,add keyboard function to consolewidget,fix the
bug in consoleimage and make the consolewidget the mainwindow.