Isis Developer Reference
ViewportMainWindow.h
Go to the documentation of this file.
1 #ifndef ViewportMainWindow_h
2 #define ViewportMainWindow_h
3 
4 #include <map>
5 #include <QToolBar>
6 #include <QMenu>
7 #include "FileName.h"
8 #include "MainWindow.h"
9 
10 namespace Isis {
11  class Preference;
12  class ToolPad;
13  class TrackTool;
14  class Workspace;
15 
43  class ViewportMainWindow : public MainWindow {
44  Q_OBJECT
45 
46  signals:
47  void closeWindow(QCloseEvent *event = NULL);
48 
49  public slots:
50  void displayWarning(std::string &pStr, const std::string &pExStr);
51  void resetWarning(void);
52 
53  public:
54  ViewportMainWindow(QString title, QWidget *parent = 0);
55  virtual ~ViewportMainWindow();
56 
59  return p_workspace;
60  };
61 
64  return p_permToolbar;
65  };
66 
69  return p_activeToolbar;
70  };
71 
74  return p_toolpad;
75  };
76 
77  QMenu *getMenu(const QString &name);
79  return mTrackTool;
80  };
81 
82  protected:
83  virtual void closeEvent(QCloseEvent *event);
84 
85  private:
86  Workspace *p_workspace;
87  QToolBar *p_permToolbar;
88  QToolBar *p_activeToolbar;
89  ToolPad *p_toolpad;
90  std::map<QString, QMenu *> p_menus;
91  std::string p_appName;
92  TrackTool *mTrackTool;
93  };
94 };
95 
96 #endif
FileName.h
QWidget
Isis::ViewportMainWindow::closeWindow
void closeWindow(QCloseEvent *event=NULL)
Signal called when the window receives a close event.
Isis::ViewportMainWindow::getMenu
QMenu * getMenu(const QString &name)
Returns the menu with menu name = name.
Definition: ViewportMainWindow.cpp:87
Isis::TrackTool::displayWarning
void displayWarning(std::string &pStr, const std::string &pExStr)
Display the Warning icon in case of an exception, sent from the tool where the exception occured.
Definition: TrackTool.cpp:97
ViewportMainWindow.h
Isis::ViewportMainWindow::getTrackTool
TrackTool * getTrackTool()
Definition: ViewportMainWindow.h:78
MainWindow.h
QMenu
Isis::ViewportMainWindow::~ViewportMainWindow
virtual ~ViewportMainWindow()
Definition: ViewportMainWindow.cpp:55
Isis::ViewportMainWindow::workspace
Workspace * workspace()
Returns the current workspace.
Definition: ViewportMainWindow.h:58
ToolPad.h
Isis::ViewportMainWindow::resetWarning
void resetWarning(void)
Slot which receives the message to reset warning status.
Definition: ViewportMainWindow.cpp:74
QToolBar
Isis::ViewportMainWindow::activeToolBar
QToolBar * activeToolBar()
Returns the active toolbar.
Definition: ViewportMainWindow.h:68
Isis::Workspace::confirmClose
bool confirmClose()
Confirms that the user wishes toc lose the Workspace.
Definition: Workspace.cpp:267
Isis::MainWindow::closeEvent
virtual void closeEvent(QCloseEvent *event)
This method is overridden so that we can be sure to write the current settings of the Main window.
Definition: MainWindow.cpp:37
Isis::ViewportMainWindow
This was called the Qisis MainWindow.
Definition: ViewportMainWindow.h:43
Isis::ViewportMainWindow::toolPad
ToolPad * toolPad()
Returns the toolpad.
Definition: ViewportMainWindow.h:73
Isis::ViewportMainWindow::closeEvent
virtual void closeEvent(QCloseEvent *event)
This class is called when a close event occurs, it emits a signal and ignores the close event.
Definition: ViewportMainWindow.cpp:115
Isis::Tool::addTo
void addTo(ViewportMainWindow *mw)
Adds the tool to the application.
Definition: Tool.cpp:78
Workspace.h
Isis::ViewportMainWindow::permanentToolBar
QToolBar * permanentToolBar()
Returns the permanent toolbar.
Definition: ViewportMainWindow.h:63
Isis::MainWindow::readSettings
virtual void readSettings(QSize defaultSize=QSize())
This method ensure that the settings get written even if the Main window was only hidden,...
Definition: MainWindow.cpp:80
Isis::ToolPad
Definition: ToolPad.h:14
Isis::TrackTool::resetStatusWarning
void resetStatusWarning(void)
Resets the warning status on the status bar to default.
Definition: TrackTool.cpp:104
Isis::Workspace
Definition: Workspace.h:78
Isis::MainWindow
Base class for the Qisis main windows.
Definition: MainWindow.h:24
TrackTool.h
Isis::TrackTool
This tool is part of the Qisis namespace and displays the statusbar of the window.
Definition: TrackTool.h:42
Isis
This is free and unencumbered software released into the public domain.
Definition: Apollo.h:16
Isis::ViewportMainWindow::ViewportMainWindow
ViewportMainWindow(QString title, QWidget *parent=0)
Constructs a ViewportMainWindow object with windowTitle = title.
Definition: ViewportMainWindow.cpp:18
Isis::ViewportMainWindow::displayWarning
void displayWarning(std::string &pStr, const std::string &pExStr)
Slot which receives the warning signal.
Definition: ViewportMainWindow.cpp:65