4 #include <QtGui/QMainWindow>
5 #include <QtGui/QTextEdit>
6 #include <QtGui/QPushButton>
7 #include <QtGui/QCheckBox>
8 #include <QtGui/QVBoxLayout>
9 #include <QtGui/QLineEdit>
10 #include <QtGui/QScrollArea>
11 #include <QtGui/QLabel>
12 #include <QtGui/QTableWidget>
13 #include <QtGui/QMessageBox>
14 #include <QtGui/QActionGroup>
16 #if defined(Q_WS_MAEMO_5)
24 #include <verbiste/FrenchVerbDictionary.h>
25 #include "gui/conjugation.h"
29 #include <QtCore/QDebug>
30 #include <QtCore/QElapsedTimer>
33 using namespace verbiste;
47 // No destructor because this object does not own the two widgets.
54 class MainWindow : public QMainWindow
58 enum ScreenOrientation {
59 ScreenOrientationLockPortrait,
60 ScreenOrientationLockLandscape,
64 explicit MainWindow(QWidget *parent = 0);
65 virtual ~MainWindow();
67 // Setup UI by coding, not by QtDesigner
70 // Note that this will only have an effect on Symbian and Fremantle.
71 void setOrientation(ScreenOrientation orientation);
75 QVBoxLayout* makeResultCell(const VVS &tenseIterator,
76 const std::string &tenseName,
77 const std::string &inputWord,
78 FrenchVerbDictionary *verbDict);
86 QWidget *cent; // Central widget
87 QVBoxLayout *mlayout; // Main layout
88 QTabWidget *resultPages;
89 QHBoxLayout *btlayout; // Layout to pack the functional buttons
90 QPushButton *btnClear; // Clear button
92 QLineEdit *wordinput; // Word input
93 QPushButton *btnLookup; // Lookup button
98 FrenchVerbDictionary *freVerbDic;
99 AboutDialog *aboutDialog;
101 ResultPage* addResultPage(const std::string &labelText);
112 #endif // MAINWINDOW_H