OpenStructure
gl_win.hh
Go to the documentation of this file.
1 //------------------------------------------------------------------------------
2 // This file is part of the OpenStructure project <www.openstructure.org>
3 //
4 // Copyright (C) 2008-2020 by the OpenStructure authors
5 //
6 // This library is free software; you can redistribute it and/or modify it under
7 // the terms of the GNU Lesser General Public License as published by the Free
8 // Software Foundation; either version 3.0 of the License, or (at your option)
9 // any later version.
10 // This library is distributed in the hope that it will be useful, but WITHOUT
11 // ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
12 // FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
13 // details.
14 //
15 // You should have received a copy of the GNU Lesser General Public License
16 // along with this library; if not, write to the Free Software Foundation, Inc.,
17 // 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
18 //------------------------------------------------------------------------------
19 #ifndef OST_GUI_GL_WIN_HH
20 #define OST_GUI_GL_WIN_HH
21 
22 
24 #include <ost/gui/module_config.hh>
25 #include <ost/gui/widget.hh>
26 
27 /*
28  Authors: Ansgar Philippsen, Marco Biasini
29  */
30 
31 namespace ost { namespace gui {
32 
33 
34 class GLCanvas;
35 class ToolBar;
36 class Tool;
37 class SceneMenu;
38 
40 {
41  Q_OBJECT;
42 public:
43  GLWin(QWidget* p, bool try_stereo=false);
44  ~GLWin();
45  void SetTestMode(bool f);
46 
47 public:
48  virtual bool Restore(const QString& prefix);
49  virtual bool Save(const QString& prefix);
50 
51 public slots:
52  void StatusMessage(const String& m);
54 
55 private slots:
56  virtual void RequestContextMenu(const QPoint& pos);
57 
58 private:
59  GLCanvas* gl_canvas_;
60  QWidget* gl_canvas_widget_;
61  ToolBar* toolbar_;
62  SceneMenu* scene_menu_;
63 };
64 
65 }} // ns
66 
67 #endif
68 
Interface for observing graphical objects.
void ActiveToolChanged(Tool *t)
virtual bool Save(const QString &prefix)
void SetTestMode(bool f)
void StatusMessage(const String &m)
virtual bool Restore(const QString &prefix)
GLWin(QWidget *p, bool try_stereo=false)
base class for tools
Definition: tool.hh:62
Base class for widgets.
Definition: widget.hh:40
#define DLLEXPORT_OST_GUI
std::string String
Definition: base.hh:54
Definition: base.dox:1