OpenMS  2.7.0
Signals | Public Member Functions | Static Public Member Functions | List of all members
QApplicationTOPP Class Reference

Extension to the QApplication for running TOPPs GUI tools. More...

#include <OpenMS/VISUAL/APPLICATIONS/MISC/QApplicationTOPP.h>

Inheritance diagram for QApplicationTOPP:
[legend]
Collaboration diagram for QApplicationTOPP:
[legend]

Signals

void fileOpen (QString file)
 

Public Member Functions

 QApplicationTOPP (int &argc, char **argv)
 Constructor (no NOT remove the "&" from argc, since Qt will segfault on some platforms otherwise!) More...
 
 ~QApplicationTOPP () override
 Destructor. More...
 
bool notify (QObject *rec, QEvent *ev) override
 : Catch exceptions in Qt GUI applications, preventing ungraceful exit More...
 
bool event (QEvent *) override
 

Static Public Member Functions

static void showAboutDialog (QWidget *parent, const QString &toolname)
 Show the About-Dialog with License and Citation for all GUI tools. More...
 

Detailed Description

Extension to the QApplication for running TOPPs GUI tools.

Basically re-implements notify of QApplication to prevent ungraceful exit.

Constructor & Destructor Documentation

◆ QApplicationTOPP()

QApplicationTOPP ( int &  argc,
char **  argv 
)

Constructor (no NOT remove the "&" from argc, since Qt will segfault on some platforms otherwise!)

References GUIProgressLoggerImpl::create(), File::find(), GUIProgressLoggerImpl::getProductName(), Factory< FactoryProduct >::registerProduct(), and String::toQString().

◆ ~QApplicationTOPP()

~QApplicationTOPP ( )
override

Destructor.

Member Function Documentation

◆ event()

bool event ( QEvent *  event)
override

Reimplemented from QApplication, to handle QEvent::FileOpen to enable handling of odoc event on MacOSX

References QApplicationTOPP::fileOpen().

◆ fileOpen

void fileOpen ( QString  file)
signal

Referenced by QApplicationTOPP::event(), and main().

◆ notify()

bool notify ( QObject rec,
QEvent *  ev 
)
override

: Catch exceptions in Qt GUI applications, preventing ungraceful exit

Re-implementing QApplication::notify() to catch exception thrown in event handlers (which is most likely OpenMS code).

References BaseException::getName(), OPENMS_LOG_ERROR, and String::toQString().

◆ showAboutDialog()

void showAboutDialog ( QWidget parent,
const QString &  toolname 
)
static

Show the About-Dialog with License and Citation for all GUI tools.

Parameters
parentParent widget (usually 'this')
toolnamename of the tool (used as heading)

References VersionInfo::getRevision(), and VersionInfo::getVersion().

Referenced by SwathWizardBase::showAboutDialog(), and TOPPASBase::showAboutDialog().