4 #include <QtGui/QMainWindow>
5 #include <QtGui/QTextEdit>
6 #include <QtGui/QPushButton>
7 #include <QtGui/QVBoxLayout>
8 #include <QtGui/QLineEdit>
9 #include <QtGui/QScrollArea>
10 #include <QtGui/QLabel>
11 #include <QtGui/QTableWidget>
17 #include <verbiste/FrenchVerbDictionary.h>
18 #include "gui/conjugation.h"
19 using namespace verbiste;
33 // No destructor because this object does not own the two widgets.
40 class MainWindow : public QMainWindow
44 enum ScreenOrientation {
45 ScreenOrientationLockPortrait,
46 ScreenOrientationLockLandscape,
50 explicit MainWindow(QWidget *parent = 0);
51 virtual ~MainWindow();
53 // Setup UI by coding, not by QtDesigner
56 // Note that this will only have an effect on Symbian and Fremantle.
57 void setOrientation(ScreenOrientation orientation);
61 QVBoxLayout* makeResultCell(const VVS &tenseIterator,
62 const std::string &tenseName,
63 const std::string &inputWord,
64 FrenchVerbDictionary *verbDict);
71 QWidget *cent; // Central widget
72 QVBoxLayout *mlayout; // Main layout
73 QTabWidget *resultPages;
74 QHBoxLayout *btlayout; // Layout to pack the functional buttons
75 QPushButton *btnClear; // Clear button
76 QLineEdit *wordinput; // Word input
77 QPushButton *btnLookup; // Lookup button
79 FrenchVerbDictionary *freVerbDic;
81 ResultPage* addResultPage(const std::string &labelText);
89 #endif // MAINWINDOW_H