Add alternative printf when in QT_GUI (fixed logging in QtCreator)