|
AvogadroLibs
1.93.1
|
The InterfaceWidget class provides a user interface for running external scripts. More...
#include <interfacewidget.h>
Public Member Functions | |
| InterfaceWidget (const QString &scriptFilePath, QWidget *parent_=0) | |
| void | setInterfaceScript (const QString &scriptFilePath) |
| void | setMolecule (QtGui::Molecule *mol) |
| const QtGui::InterfaceScript & | interfaceScript () const |
| QJsonObject | collectOptions () const |
| void | applyOptions (const QJsonObject &opts) |
| bool | isEmpty () const |
<avogadro/qtgui/interfacewidget.h>
The InterfaceWidget creates a GUI to represent the options given by an script, turning JSON from the script into a form and passing the results back to the script via command-line
|
explicit |
Construct a widget that dynamically generates a GUI to configure the script specified by scriptFilePath.
| void setInterfaceScript | ( | const QString & | scriptFilePath | ) |
Use the script pointed to by scriptFilePath.
| scriptFilePath | Absolute path to script. |
| void setMolecule | ( | QtGui::Molecule * | mol | ) |
Set the molecule used in the simulation.
| const QtGui::InterfaceScript& interfaceScript | ( | ) | const |
Access to the underlying input generator object.
| QJsonObject collectOptions | ( | ) | const |
Collect all of the user-specified options into a JSON object, to be sent to the generator script.
| void applyOptions | ( | const QJsonObject & | opts | ) |
Apply the options in the passed QJsonObject to the GUI. Any widgets changed by this method will have their signals blocked while modifying their values.