VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
DtQtDeMainWindow.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 2025 MAK Technologies, Inc.
3 ** All rights reserved.
4 ******************************************************************************/
5 
9 
10 #pragma once
11 
12 #include <vrvCoreQt/vrvCoreQt.h>
13 
14 #if !defined(Q_MOC_RUN)
15 #include <vrvCore/DtDeMainWindow.h>
18 
20 
22 #endif
23 
24 #include <QtCore/QRect>
25 
26 class QAction;
27 
28 namespace makVrv
29 {
30 
31  class DtDe;
32  class DtQtKeyAdapter;
33  class DtDriverManager;
34  class DtInputDriver;
35  class DtDriver;
36  class DtStartupDialog;
37  class DtHelpDialog;
38  class DtDeSplashScreen;
39 
45  public DtDeMainWindow
46  {
47  Q_OBJECT
48  public:
49 
50  static const char* ContainerPlaceHolderString;
51 
53 
55  virtual ~DtQtDeMainWindow();
56 
58  virtual void setApplicationTitle(const std::string& appName);
59 
61  virtual std::string applicationTitle() const;
62 
64  virtual void setApplicationIcon(const std::string& iconName);
65 
67  virtual QDockWidget* dockComponent(QWidget* component,
68  Qt::DockWidgetArea area = Qt::LeftDockWidgetArea);
69 
71  virtual QToolBar* dockComponent(QWidget* component,
72  Qt::ToolBarArea area = Qt::LeftToolBarArea);
73 
75  virtual void setMainWidget(QWidget* widget, DtQtKeyAdapter* keyAdapter = 0);
76 
78  virtual void removeMainWidget();
79 
80  virtual QWidget* mainWidget();
81 
83  virtual void destroyWindow();
84 
86  virtual void quit();
87 
89  virtual bool isToggledAsFullScreen();
90 
95  virtual void setStatusBarVisible(bool visible);
96 
100  virtual bool isStatusBarVisible() const;
101 
105  virtual void toggleFullScreen();
106 
108  virtual void slot_onDisplayEngineConfigurationRealized(
109  const std::string& igName, const std::string& displayName);
110 
112  virtual int screenNumber() const;
113 
115  virtual void showStartupDialog();
116 
118  virtual void hideStartupDialog();
119 
121  virtual void showHelpDialog();
122 
124  virtual void hideHelpDialog();
125 
126  signals:
127 
130  void signal_fullScreenToggled();
131 
133  void signal_statusBarVisibilityChanged();
134 
135  public slots:
136 
137  virtual void remaximization();
138 
139  protected:
140 
142  DtQtDeMainWindow(DtDe& de, QWidget* parent = 0, Qt::WindowFlags flags = 0);
143 
144  virtual bool event(QEvent* event) override;
145 
146  virtual void keyPressEvent( QKeyEvent* event ) override;
147  virtual void keyReleaseEvent( QKeyEvent* event ) override;
148 
151  virtual void closeEvent(QCloseEvent *event) override;
152 
154  void onMainEmbeddedWindowPixelRatioChanged();
155 
159  void slot_onWindowToBeDestroyed();
160 
163  void displayLabelInCentralWidget();
164 
168  void slot_onWindowCreated();
169 
171  virtual void setSplashScreen(DtDeSplashScreen* splashScreen);
172 
175  virtual void showBasedOnSettings();
176 
178  void hideAllVisibleDockableWidgets();
179 
182  void showAllVisibleDockableWidgets();
183 
185  void configureTabbedDockComponents();
186 
188  virtual void dragEnterEvent(QDragEnterEvent* event) override;
189 
191  virtual void dropEvent(QDropEvent* event) override;
192 
193  protected:
194 
196 
200  QPoint myRestorePos;
204 
205  //this are used for cache the window state before go to fullscreen for restore purpose
211 
213  Qt::WindowStates myLastWindowState;
214 
215  // int because we get ints from Qt (unless we are using qml for everything)
217 
222  };
223 
228  {
229 
230  public:
231 
234 
236  virtual ~DtQtDeMainWindowProvider();
237 
240  //static DtQtDeMainWindowProvider& instance(DtDe& de);
241 
242  protected:
243 
246  virtual DtDeMainWindow* createMainWindow(DtDe& de);
247 
248  };
249 }
Qt::WindowStates myLastWindowState
Definition: DtQtDeMainWindow.h:213
DtDeSplashScreen * mySplashScreen
Definition: DtQtDeMainWindow.h:195
DtStartupDialog provides a dialog to be displayed on VR-Vantage startup to allow the user to choose w...
Definition: DtStartupDialog.h:37
QRect myRestoreRect
Definition: DtQtDeMainWindow.h:199
int myOldDevicePixelRatio
Definition: DtQtDeMainWindow.h:216
Contains makVrv::DtSubjectObserver class.
bool myFullScreen
Definition: DtQtDeMainWindow.h:198
DtStartupDialog * myStartupDialog
Definition: DtQtDeMainWindow.h:202
int myWindowXBeforeFullscreen
Definition: DtQtDeMainWindow.h:207
int myWindowHeightBeforeFullscreen
Definition: DtQtDeMainWindow.h:210
DtQtKeyAdapter * myKeyAdapter
Definition: DtQtDeMainWindow.h:197
int myWindowWidthBeforeFullscreen
Definition: DtQtDeMainWindow.h:209
The abstract main window provider.
Definition: DtDeMainWindow.h:84
DtHelpDialog * myHelpDialog
Definition: DtQtDeMainWindow.h:203
#define DT_DLL_VRVCOREQT
Definition: vrvCoreQt.h:20
Contains DLL export macros.
A styled QMainWindow that maintains color mappings for icons. This styled main window support mapping...
Definition: DtStyledQMainWindow.h:39
Contains makVrv::DtDeMainWindow class.
Abstract class to get Qt key events into OpenSceneGraph. Typically owned by DtDeMainWindowEmbeddedOsg...
Definition: DtQtKeyAdapter.h:20
int myWindowStateBeforeFullscreen
Definition: DtQtDeMainWindow.h:206
Contains makVrv::DtObserverObject class declaration.
DtQtDeMainWindowProvider lazily creates and provides access to the DtQtDeMainWindow.
Definition: DtQtDeMainWindow.h:227
QPoint myRestorePos
Definition: DtQtDeMainWindow.h:200
QObjectList myVisibleButHiddenDockableWidgets
Definition: DtQtDeMainWindow.h:201
Class to manage disconnection of boost connections on deletion.
Definition: DtSignalConnectionManager.h:20
The abstract main window class.
Definition: DtDeMainWindow.h:24
static const char * ContainerPlaceHolderString
Definition: DtQtDeMainWindow.h:50
Base class to provide boost signal/slot management.
int myWindowYBeforeFullscreen
Definition: DtQtDeMainWindow.h:208
The VR-Vantage Splash Screen Interface.
Definition: DtDeSplashScreen.h:34
The DtDe is the core component of any VR-Vantage application. It owns a DtRenderer, DtDeCommunicator, as well as a DtDisplay and other things.
Definition: DtDe.h:76
Contains makVrv::DtStyledQMainWindow class.
QDockWidget * myBgStatusDock
Non-owning pointer to the background status bar dock widget.
Definition: DtQtDeMainWindow.h:221
The help dialog class loads information about VR-Vantage and presents them to the user using a Qt dia...
Definition: DtHelpDialog.h:25
The Qt main window. There will be only one of these per DtDe instance. Note, this window will be dest...
Definition: DtQtDeMainWindow.h:44
DtSignalConnectionManager myConnections
Definition: DtQtDeMainWindow.h:212

Document ID: Generated on Thu Oct 15 21:27:02 EDT 2026 from SVN revision 296421
Copyright © 2005-2026 MAK Technologies. All Rights Reserved (www.mak.com)