summaryrefslogtreecommitdiff
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--library/qpeapplication.cpp20
1 files changed, 18 insertions, 2 deletions
diff --git a/library/qpeapplication.cpp b/library/qpeapplication.cpp
index cf437da..f84bc0e 100644
--- a/library/qpeapplication.cpp
+++ b/library/qpeapplication.cpp
@@ -72,2 +72,4 @@
#include "fontmanager.h"
+#include "fontdatabase.h"
+
#include "power.h"
@@ -387,3 +389,3 @@ public:
QWSServer::sendKeyEvent( 0xffff, Qt::Key_F34, FALSE, TRUE, FALSE );
- return TRUE;
+ return TRUE;
}
@@ -506,3 +508,3 @@ QPEApplication::QPEApplication( int& argc, char **argv, Type t )
if ( dw < 200 ) {
- setFont( QFont( "helvetica", 8 ) );
+// setFont( QFont( "helvetica", 8 ) );
AppLnk::setSmallIconSize(10);
@@ -601,3 +603,17 @@ QPEApplication::QPEApplication( int& argc, char **argv, Type t )
}
+ else {
+ Config config( "qpe" );
+ config.setGroup( "Appearance" );
+ QString familyStr = config.readEntry( "FontFamily", "fixed" );
+ QString styleStr = config.readEntry( "FontStyle", "Regular" );
+ QString sizeStr = config.readEntry( "FontSize", "10" );
+ QString charSetStr = config.readEntry( "FontCharSet", "iso10646-1" );
+ bool ok;
+ int i_size = sizeStr.toInt( &ok, 10 );
+ FontDatabase fdb;
+ QFont selectedFont = fdb.font( familyStr, styleStr, i_size, charSetStr );
+ setFont( selectedFont );
+ }
}
+
#endif