Quantum GIS API Documentation
1.8
|
Provides a context based help browser for a dialog. More...
#include <qgscontexthelp.h>
Static Public Member Functions | |
static void | run (QString context) |
Private Slots | |
void | readPort () |
void | processExited () |
Private Member Functions | |
QgsContextHelp (QString context) | |
Constructor. | |
~QgsContextHelp () | |
Destructor. | |
QProcess * | start (QString context) |
void | showContext (QString context) |
Private Attributes | |
QProcess * | mProcess |
QProcess * | mNextProcess |
Static Private Attributes | |
static QgsContextHelp * | gContextHelp = NULL |
Provides a context based help browser for a dialog.
The help text is stored in SQLite and accessed by a context identifier unique to each dialog. This is a singleton class which invokes the help viewer using QProcess and ensures that only one viewer is open. The viewer will be terminated if open when the main application quits.
If the compile-time flag QGSCONTEXTHELP_REUSE is defined, the help viewer will be reused if it is still open. If this flag is not set, the viewer process will be terminated if open and restarted; this makes it the top window for window managers such as Linux/GNOME which will make a window active but not bring it to the top if raised programatically.
Definition at line 43 of file qgscontexthelp.h.
QgsContextHelp::QgsContextHelp | ( | QString | context | ) | [private] |
Constructor.
Definition at line 48 of file qgscontexthelp.cpp.
References mNextProcess, mProcess, readPort(), and start().
Referenced by run().
QgsContextHelp::~QgsContextHelp | ( | ) | [private] |
Destructor.
Definition at line 61 of file qgscontexthelp.cpp.
References mNextProcess, and mProcess.
void QgsContextHelp::processExited | ( | ) | [private, slot] |
Definition at line 120 of file qgscontexthelp.cpp.
References gContextHelp, mNextProcess, and mProcess.
Referenced by start().
void QgsContextHelp::readPort | ( | ) | [private, slot] |
Definition at line 90 of file qgscontexthelp.cpp.
References mProcess.
Referenced by QgsContextHelp().
void QgsContextHelp::run | ( | QString | context | ) | [static] |
Definition at line 35 of file qgscontexthelp.cpp.
References gContextHelp, QgsContextHelp(), and showContext().
Referenced by QgsNewHttpConnection::on_buttonBox_helpRequested(), QgsNewVectorLayerDialog::on_buttonBox_helpRequested(), QgsQueryBuilder::on_buttonBox_helpRequested(), and QgsSearchQueryBuilder::on_buttonBox_helpRequested().
void QgsContextHelp::showContext | ( | QString | context | ) | [private] |
Definition at line 101 of file qgscontexthelp.cpp.
References mNextProcess, mProcess, QgsDebugMsg, and start().
Referenced by run().
QProcess * QgsContextHelp::start | ( | QString | context | ) | [private] |
Definition at line 72 of file qgscontexthelp.cpp.
References QgsApplication::helpAppPath(), processExited(), and QgsDebugMsg.
Referenced by QgsContextHelp(), and showContext().
QgsContextHelp * QgsContextHelp::gContextHelp = NULL [static, private] |
Definition at line 62 of file qgscontexthelp.h.
Referenced by processExited(), and run().
QProcess* QgsContextHelp::mNextProcess [private] |
Definition at line 69 of file qgscontexthelp.h.
Referenced by processExited(), QgsContextHelp(), showContext(), and ~QgsContextHelp().
QProcess* QgsContextHelp::mProcess [private] |
Definition at line 63 of file qgscontexthelp.h.
Referenced by processExited(), QgsContextHelp(), readPort(), showContext(), and ~QgsContextHelp().