-rw-r--r-- | noncore/apps/opie-console/emulation_widget.cpp | 3 | ||||
-rw-r--r-- | noncore/apps/opie-console/widget_layer.h | 2 |
2 files changed, 5 insertions, 0 deletions
diff --git a/noncore/apps/opie-console/emulation_widget.cpp b/noncore/apps/opie-console/emulation_widget.cpp index 5c3b2d2..318d7bb 100644 --- a/noncore/apps/opie-console/emulation_widget.cpp +++ b/noncore/apps/opie-console/emulation_widget.cpp @@ -17,24 +17,27 @@ #define SCRWIDTH 16 // width of scrollbar EmulationWidget::EmulationWidget( const Profile& config, QWidget *parent, const char* name ) : WidgetLayer( config, parent, name ) { // initialize font attributes QFontMetrics fm( font() ); f_height = fm.height(); f_width = fm.maxWidth(); f_ascent = fm.ascent(); + // give reasonable defaults to m_columns, m_lines + calcGeometry(); + // initialize scrollbar related vars m_scrollbar = new QScrollBar( this ); m_scrollbar->setCursor( arrowCursor ); // load config reloadConfig( config ); m_resizing = false; } void EmulationWidget::reloadConfig( const Profile& config ) { diff --git a/noncore/apps/opie-console/widget_layer.h b/noncore/apps/opie-console/widget_layer.h index bc8fe36..067f3da 100644 --- a/noncore/apps/opie-console/widget_layer.h +++ b/noncore/apps/opie-console/widget_layer.h @@ -17,24 +17,26 @@ #include <qapplication.h> #include <qframe.h> #include <qarray.h> #include <qtimer.h> #include <qkeycode.h> #include <qclipboard.h> // opie-console includes #include "session.h" #include "common.h" #include "profile.h" + + /* * given a pseudo location ( column, line ), * returns the actual index, in the QArray<Character> */ #define loc(X,Y) ((Y)*m_columns+(X)) extern unsigned short vt100_graphics[32]; class WidgetLayer : public QFrame { Q_OBJECT |