Rev 2116 Rev 2222
1 #include <QApplication> 1 #include <QApplication>
2 #include <QPushButton> 2 #include <QPushButton>
3 #include <QVBoxLayout> 3 #include <QVBoxLayout>
4   4  
5 #include "scope.h" 5 #include "scope.h"
6   6  
7 class Window : public QWidget 7 class Window : public QWidget
8 { 8 {
9 public: 9 public:
10 Window(QWidget *parent = 0); 10 Window(QWidget *parent = 0);
11 }; 11 };
12   12  
13 Window::Window(QWidget *parent) 13 Window::Window(QWidget *parent)
14 : QWidget(parent) 14 : QWidget(parent)
15 { 15 {
16 Scope *scope = new Scope; 16 Scope *scope = new Scope;
17   17  
18 QVBoxLayout *layout = new QVBoxLayout; 18 QVBoxLayout *layout = new QVBoxLayout;
19 layout->addWidget(scope); 19 layout->addWidget(scope);
20 setLayout(layout); 20 setLayout(layout);
21 } 21 }
22   22  
23   23  
24 int main(int argc, char *argv[]) 24 int main(int argc, char *argv[])
25 { 25 {
26 QApplication app(argc, argv); 26 QApplication app(argc, argv);
27 Window window; 27 Window window;
28 window.setGeometry(1200, 200, 570, 390); 28 window.setGeometry(1200, 200, 570, 390);
29 window.show(); 29 window.show();
30 return app.exec(); 30 return app.exec();
31 } 31 }