summaryrefslogtreecommitdiff
path: root/inputmethods/dasher/QtDasherScreen.cc
Unidiff
Diffstat (limited to 'inputmethods/dasher/QtDasherScreen.cc') (more/less context) (show whitespace changes)
-rw-r--r--inputmethods/dasher/QtDasherScreen.cc3
1 files changed, 0 insertions, 3 deletions
diff --git a/inputmethods/dasher/QtDasherScreen.cc b/inputmethods/dasher/QtDasherScreen.cc
index 7d77511..747b705 100644
--- a/inputmethods/dasher/QtDasherScreen.cc
+++ b/inputmethods/dasher/QtDasherScreen.cc
@@ -1,45 +1,42 @@
1// QtDasherScreen.cc 1// QtDasherScreen.cc
2// (c) 2003 Yann Dirson 2// (c) 2003 Yann Dirson
3// Derived from GtkDasherCanvas.cc 3// Derived from GtkDasherCanvas.cc
4// (c) 2002 Philip Cowans 4// (c) 2002 Philip Cowans
5 5
6#include <iostream> 6#include <iostream>
7#include <string> 7#include <string>
8 8
9#include <qpointarray.h> 9#include <qpointarray.h>
10#include <qpoint.h> 10#include <qpoint.h>
11 11
12#include "QtDasherScreen.h" 12#include "QtDasherScreen.h"
13#include "DasherScreen.h" 13#include "DasherScreen.h"
14#include "SettingsStore.h" 14#include "SettingsStore.h"
15 15
16#define MAXFONTSIZE 25 16#define MAXFONTSIZE 25
17#define MINFONTSIZE 8 17#define MINFONTSIZE 8
18 18
19#include <iconv.h>
20#include <iostream>
21
22QtDasherScreen::QtDasherScreen (int _width, int _height, 19QtDasherScreen::QtDasherScreen (int _width, int _height,
23 CDasherInterface *_interface, 20 CDasherInterface *_interface,
24 QWidget * _parent, Dasher::CDashEditbox *edit): 21 QWidget * _parent, Dasher::CDashEditbox *edit):
25 QWidget(_parent), interface( _interface ), 22 QWidget(_parent), interface( _interface ),
26 fontname( "fixed" ), fontsize(12), 23 fontname( "fixed" ), fontsize(12),
27 Dasher::CDasherScreen(_width, _height) 24 Dasher::CDasherScreen(_width, _height)
28{ 25{
29 font = QFont (fontname.c_str(), fontsize); 26 font = QFont (fontname.c_str(), fontsize);
30 painter = new QPainter (); 27 painter = new QPainter ();
31 28
32 pixmap = new QPixmap (_width, _height); 29 pixmap = new QPixmap (_width, _height);
33 pixmap->setOptimization(QPixmap::BestOptim); 30 pixmap->setOptimization(QPixmap::BestOptim);
34 interface->SetSettingsStore(new CSettingsStore); 31 interface->SetSettingsStore(new CSettingsStore);
35 32
36 interface->ChangeLanguageModel(0); 33 interface->ChangeLanguageModel(0);
37 interface->ChangeView(0); 34 interface->ChangeView(0);
38 interface->ChangeEdit(edit); 35 interface->ChangeEdit(edit);
39 36
40/* interface->GetFontSizes(&FontSizes); 37/* interface->GetFontSizes(&FontSizes);
41 38
42 for (int i=0; i<FontSizes.size(); i++) { 39 for (int i=0; i<FontSizes.size(); i++) {
43 if (FontSizes[i]>Fonts.size()) 40 if (FontSizes[i]>Fonts.size())
44 Fonts.resize((FontSizes[i])+1); 41 Fonts.resize((FontSizes[i])+1);
45 Fonts[FontSizes[i]]= QFont (fontname.c_str(), FontSizes[i]); 42 Fonts[FontSizes[i]]= QFont (fontname.c_str(), FontSizes[i]);