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>
20 #include <verbiste/FrenchVerbDictionary.h>
21 #include "gui/conjugation.h"
25 #include <QtCore/QDebug>
26 #include <QtCore/QElapsedTimer>
29 using namespace verbiste;
43 // No destructor because this object does not own the two widgets.
50 class MainWindow : public QMainWindow
54 enum ScreenOrientation {
55 ScreenOrientationLockPortrait,
56 ScreenOrientationLockLandscape,
60 explicit MainWindow(QWidget *parent = 0);
61 virtual ~MainWindow();
63 // Setup UI by coding, not by QtDesigner
66 // Note that this will only have an effect on Symbian and Fremantle.
67 void setOrientation(ScreenOrientation orientation);
71 QVBoxLayout* makeResultCell(const VVS &tenseIterator,
72 const std::string &tenseName,
73 const std::string &inputWord,
74 FrenchVerbDictionary *verbDict);
82 QWidget *cent; // Central widget
83 QVBoxLayout *mlayout; // Main layout
84 QTabWidget *resultPages;
85 QHBoxLayout *btlayout; // Layout to pack the functional buttons
86 QPushButton *btnClear; // Clear button
88 QLineEdit *wordinput; // Word input
89 QPushButton *btnLookup; // Lookup button
94 FrenchVerbDictionary *freVerbDic;
95 AboutDialog *aboutDialog;
97 ResultPage* addResultPage(const std::string &labelText);
108 #endif // MAINWINDOW_H