open_iA  2020.01
A tool for the visual analysis and processing of volumetric datasets, with a focus on industrial computed tomography.
Public Slots | Signals | Public Member Functions | Static Public Member Functions | Protected Member Functions | List of all members
MainWindow Class Reference

Application main window, provides access to all global graphical user interface elements. More...

#include <mainwindow.h>

Inheritance diagram for MainWindow:
Collaboration diagram for MainWindow:

Public Slots

void loadLayout ()
 

Signals

void fullScreenToggled ()
 
void styleChanged ()
 

Public Member Functions

template<typename T >
T * activeChild ()
 Get the active child window of type T. More...
 
MdiChildactiveMdiChild ()
 Provides access to the currently active mdi child, if such is available. More...
 
QMdiSubWindow * addSubWindow (QWidget *child)
 
template<typename T >
QList< T * > childList (QMdiArea::WindowOrder order=QMdiArea::CreationOrder)
 Get the list of current child windows of type T. More...
 
void closeAllSubWindows ()
 
void closeMdiChild (MdiChild *child)
 
MdiChildcreateMdiChild (bool unsavedChanges)
 
const QString & currentFile ()
 deprecated. Use a specific mdichilds, or even better, an mdichilds dlg_modalities methods instead! More...
 
QMenu * fileMenu ()
 Get the File menu (can be used by modules to append entries to it). More...
 
QMenu * filtersMenu ()
 Get the Filters menu (can be used by modules to append entries to it). More...
 
const iAPreferencesgetDefaultPreferences () const
 
iAModuleDispatchergetModuleDispatcher () const
 
QMenu * helpMenu ()
 Get the Help menu (can be used by modules to append entries to it). More...
 
void loadArguments (int argc, char **argv)
 
bool loadCamera (iAXmlSettings &xml)
 
void loadFile (QString const &fileName)
 
void loadFile (QString fileName, bool isStack)
 
void loadFiles (QStringList fileNames)
 
void loadPreferences (QDomNode preferencesNode)
 
void loadRenderSettings (QDomNode renderSettingsNode)
 
void loadSlicerSettings (QDomNode slicerSettingsNode)
 
void loadSliceViews (QDomNode sliceViewsNode)
 
 MainWindow (QString const &appName, QString const &version, QString const &splashImage)
 
QList< MdiChild * > mdiChildList (QMdiArea::WindowOrder order=QMdiArea::CreationOrder)
 Get the list of current MdiChild windows. More...
 
QList< QString > mdiWindowTitles ()
 Get list of the titles of currently open MdiChild windows. More...
 
const QString & path ()
 
void saveCamera (iAXmlSettings &xml)
 
void savePreferences (iAXmlSettings &xml)
 
void saveRenderSettings (iAXmlSettings &xml)
 
void saveSlicerSettings (iAXmlSettings &xml)
 
void saveSliceView (QDomDocument &doc, QDomNode &sliceViewsNode, vtkCamera *ren, QString const &elemStr)
 
void saveSliceViews (iAXmlSettings &xml)
 
void saveTransferFunction (QDomDocument &doc, iAChartTransferFunction *transferFunction)
 
MdiChildsecondNonActiveChild ()
 Provides access to a second loaded mdi child, if such is available. More...
 
void setCurrentFile (const QString &fileName)
 
void setPath (QString const &p)
 
QMenu * toolsMenu ()
 Get the Tools menu (can be used by modules to append entries to it). More...
 
 ~MainWindow ()
 
MdiChildresultChild (QString const &title)
 
MdiChildresultChild (int childInd, QString const &title)
 
MdiChildresultChild (MdiChild *oldChild, QString const &title)
 

Static Public Member Functions

static void initResources ()
 
static int runGUI (int argc, char *argv[], QString const &appName, QString const &version, QString const &splashPath, QString const &iconPath)
 

Protected Member Functions

void closeEvent (QCloseEvent *event) override
 
void dragEnterEvent (QDragEnterEvent *e) override
 
void dropEvent (QDropEvent *e) override
 

Detailed Description

Application main window, provides access to all global graphical user interface elements.

Constructor & Destructor Documentation

◆ MainWindow()

MainWindow::MainWindow ( QString const &  appName,
QString const &  version,
QString const &  splashImage 
)

◆ ~MainWindow()

MainWindow::~MainWindow ( )

Member Function Documentation

◆ activeChild()

template<typename T >
T * MainWindow::activeChild ( )

Get the active child window of type T.

◆ activeMdiChild()

MdiChild * MainWindow::activeMdiChild ( )

Provides access to the currently active mdi child, if such is available.

Returns
pointer to the currently active mdi child, or nullptr if no child is currently open

◆ addSubWindow()

QMdiSubWindow * MainWindow::addSubWindow ( QWidget *  child)

◆ childList()

template<typename T >
QList< T * > MainWindow::childList ( QMdiArea::WindowOrder  order = QMdiArea::CreationOrder)

Get the list of current child windows of type T.

◆ closeAllSubWindows()

void MainWindow::closeAllSubWindows ( )

◆ closeEvent()

void MainWindow::closeEvent ( QCloseEvent *  event)
overrideprotected

◆ closeMdiChild()

void MainWindow::closeMdiChild ( MdiChild child)

◆ createMdiChild()

MdiChild * MainWindow::createMdiChild ( bool  unsavedChanges)

◆ currentFile()

const QString & MainWindow::currentFile ( )

deprecated. Use a specific mdichilds, or even better, an mdichilds dlg_modalities methods instead!

◆ dragEnterEvent()

void MainWindow::dragEnterEvent ( QDragEnterEvent *  e)
overrideprotected

◆ dropEvent()

void MainWindow::dropEvent ( QDropEvent *  e)
overrideprotected

◆ fileMenu()

QMenu * MainWindow::fileMenu ( )

Get the File menu (can be used by modules to append entries to it).

◆ filtersMenu()

QMenu * MainWindow::filtersMenu ( )

Get the Filters menu (can be used by modules to append entries to it).

◆ fullScreenToggled

void MainWindow::fullScreenToggled ( )
signal

◆ getDefaultPreferences()

const iAPreferences & MainWindow::getDefaultPreferences ( ) const

◆ getModuleDispatcher()

iAModuleDispatcher & MainWindow::getModuleDispatcher ( ) const

◆ helpMenu()

QMenu * MainWindow::helpMenu ( )

Get the Help menu (can be used by modules to append entries to it).

◆ initResources()

void MainWindow::initResources ( )
static

◆ loadArguments()

void MainWindow::loadArguments ( int  argc,
char **  argv 
)

◆ loadCamera()

bool MainWindow::loadCamera ( iAXmlSettings xml)

◆ loadFile() [1/2]

void MainWindow::loadFile ( QString const &  fileName)

◆ loadFile() [2/2]

void MainWindow::loadFile ( QString  fileName,
bool  isStack 
)

◆ loadFiles()

void MainWindow::loadFiles ( QStringList  fileNames)

◆ loadLayout

void MainWindow::loadLayout ( )
slot

◆ loadPreferences()

void MainWindow::loadPreferences ( QDomNode  preferencesNode)

◆ loadRenderSettings()

void MainWindow::loadRenderSettings ( QDomNode  renderSettingsNode)

◆ loadSlicerSettings()

void MainWindow::loadSlicerSettings ( QDomNode  slicerSettingsNode)

◆ loadSliceViews()

void MainWindow::loadSliceViews ( QDomNode  sliceViewsNode)

◆ mdiChildList()

QList< MdiChild * > MainWindow::mdiChildList ( QMdiArea::WindowOrder  order = QMdiArea::CreationOrder)

Get the list of current MdiChild windows.

◆ mdiWindowTitles()

QList< QString > MainWindow::mdiWindowTitles ( )

Get list of the titles of currently open MdiChild windows.

◆ path()

const QString & MainWindow::path ( )

◆ resultChild() [1/3]

MdiChild * MainWindow::resultChild ( int  childInd,
QString const &  title 
)

◆ resultChild() [2/3]

MdiChild * MainWindow::resultChild ( MdiChild oldChild,
QString const &  title 
)

◆ resultChild() [3/3]

MdiChild * MainWindow::resultChild ( QString const &  title)

Get access to result child with the given title. (depending on preferences, this will either open a new mdi child window, or reuse the currently active one)

◆ runGUI()

int MainWindow::runGUI ( int  argc,
char *  argv[],
QString const &  appName,
QString const &  version,
QString const &  splashPath,
QString const &  iconPath 
)
static

◆ saveCamera()

void MainWindow::saveCamera ( iAXmlSettings xml)

◆ savePreferences()

void MainWindow::savePreferences ( iAXmlSettings xml)

◆ saveRenderSettings()

void MainWindow::saveRenderSettings ( iAXmlSettings xml)

◆ saveSlicerSettings()

void MainWindow::saveSlicerSettings ( iAXmlSettings xml)

◆ saveSliceView()

void MainWindow::saveSliceView ( QDomDocument &  doc,
QDomNode &  sliceViewsNode,
vtkCamera *  ren,
QString const &  elemStr 
)

◆ saveSliceViews()

void MainWindow::saveSliceViews ( iAXmlSettings xml)

◆ saveTransferFunction()

void MainWindow::saveTransferFunction ( QDomDocument &  doc,
iAChartTransferFunction transferFunction 
)

◆ secondNonActiveChild()

MdiChild * MainWindow::secondNonActiveChild ( )

Provides access to a second loaded mdi child, if such is available.

Will throw an error if none is available or more than two are loaded.

Deprecated:
instead of this method, in filters, use the facilities provided in iAFilter (via the requiredInputs parameter to the constructor) to specify multiple inputs

◆ setCurrentFile()

void MainWindow::setCurrentFile ( const QString &  fileName)

◆ setPath()

void MainWindow::setPath ( QString const &  p)

◆ styleChanged

void MainWindow::styleChanged ( )
signal

◆ toolsMenu()

QMenu * MainWindow::toolsMenu ( )

Get the Tools menu (can be used by modules to append entries to it).


The documentation for this class was generated from the following files: