GlobalBase Class Reference

#include <globalbase.h>

List of all members.


Detailed Description

This class allows setup of the global calculation options.

It contains the implementation for the widget GlobalWidget.

Definition at line 35 of file globalbase.h.

Public Types

enum  Calculation { SinglePointEnergy, EnergyAndForces, GeometryOptimization, Frequencies }
enum  Buur { NoBuur, PC, SM }
enum  Run { Xbrabo, Script, Queue }

Public Slots

void reset ()
 Resets all widgets to their default values.

Public Member Functions

 GlobalBase (QWidget *parent=0, const char *name=0, bool modal=FALSE, WFlags fl=0)
 ~GlobalBase ()
 The default destructor.
void setDefaultName (const QString name)
 Sets the default calculation name.
unsigned int calculationType () const
 Returns the type of calculation.
unsigned int buurType () const
 Returns the type of crystal calculation.
bool extendedFormat () const
 Returns true if extended format is to be used.
QString description () const
 Returns the description for the calculation.
QString name () const
 Returns the name of the calculation.
QString directory () const
 Returns the directory in which the calculation will be run.
unsigned int runType () const
 Returns the type of run.
unsigned int queue () const
 Returns the queue to which the script file should be submitted.
void allowChanges (const bool status)
 Allows or prohibits changing every option.
void loadCML (const QDomElement *root)
 Reads the widget data from a QDomElement.
void saveCML (QDomElement *root)
 Saves the widget data to a QDomElement.

Protected Slots

void accept ()
 Overridden from GlobalWidget::accept().
void reject ()
 Overriden from GlobalWidget::reject().

Private Slots

void setChanged (const bool state=true)
 Sets the 'changed' property of the dialog.
void correctType (int index)
 Corrects the calculation type, because only Single Point Energy and Energy & Forces are implemented ATM.
void chooseDir ()
 Chooses a directory using a dialog.

Private Member Functions

void makeConnections ()
 Sets up the permanent connections. Called once from the constructor.
void init ()
 Initializes the dialog. Called once from the constructor.
void saveWidgets ()
 Saves the status of the widgets to a data struct.
void restoreWidgets ()
 Restores the status of the widgets from the data struct.

Private Attributes

WidgetData data
 Internal data structure.
QString defaultName
 Name() when reset is issued.
bool widgetChanged
 Holds the 'changed' property of the widget.

Classes

struct  WidgetData
 Struct local to the class GLobalBase containing the data pertaining to all widgets. More...


Member Enumeration Documentation

enum GlobalBase::Calculation
 

Enumerator:
SinglePointEnergy 
EnergyAndForces 
GeometryOptimization 
Frequencies 

Definition at line 44 of file globalbase.h.

enum GlobalBase::Buur
 

Enumerator:
NoBuur 
PC 
SM 

Definition at line 45 of file globalbase.h.

enum GlobalBase::Run
 

Enumerator:
Xbrabo 
Script 
Queue 

Definition at line 46 of file globalbase.h.


Constructor & Destructor Documentation

GlobalBase::GlobalBase QWidget *  parent = 0,
const char *  name = 0,
bool  modal = FALSE,
WFlags  fl = 0
 

Definition at line 58 of file globalbase.cpp.

GlobalBase::~GlobalBase  ) 
 

The default destructor.

Definition at line 71 of file globalbase.cpp.


Member Function Documentation

void GlobalBase::setDefaultName const QString  name  ) 
 

Sets the default calculation name.

Definition at line 78 of file globalbase.cpp.

unsigned int GlobalBase::calculationType  )  const
 

Returns the type of calculation.

Definition at line 86 of file globalbase.cpp.

unsigned int GlobalBase::buurType  )  const
 

Returns the type of crystal calculation.

Definition at line 97 of file globalbase.cpp.

bool GlobalBase::extendedFormat  )  const
 

Returns true if extended format is to be used.

Definition at line 110 of file globalbase.cpp.

QString GlobalBase::description  )  const
 

Returns the description for the calculation.

Definition at line 117 of file globalbase.cpp.

QString GlobalBase::name  )  const
 

Returns the name of the calculation.

Definition at line 124 of file globalbase.cpp.

QString GlobalBase::directory  )  const
 

Returns the directory in which the calculation will be run.

Definition at line 131 of file globalbase.cpp.

unsigned int GlobalBase::runType  )  const
 

Returns the type of run.

Definition at line 138 of file globalbase.cpp.

unsigned int GlobalBase::queue  )  const
 

Returns the queue to which the script file should be submitted.

Definition at line 148 of file globalbase.cpp.

void GlobalBase::allowChanges const bool  status  ) 
 

Allows or prohibits changing every option.

During a calculation most options may not be changed (type, format, queue, etc.).

Definition at line 155 of file globalbase.cpp.

void GlobalBase::loadCML const QDomElement *  root  ) 
 

Reads the widget data from a QDomElement.

Definition at line 166 of file globalbase.cpp.

void GlobalBase::saveCML QDomElement *  root  ) 
 

Saves the widget data to a QDomElement.

Definition at line 204 of file globalbase.cpp.

void GlobalBase::reset  )  [slot]
 

Resets all widgets to their default values.

Definition at line 230 of file globalbase.cpp.

void GlobalBase::accept  )  [protected, slot]
 

Overridden from GlobalWidget::accept().

Definition at line 258 of file globalbase.cpp.

void GlobalBase::reject  )  [protected, slot]
 

Overriden from GlobalWidget::reject().

Definition at line 276 of file globalbase.cpp.

void GlobalBase::setChanged const bool  state = true  )  [private, slot]
 

Sets the 'changed' property of the dialog.

Defaults to true if no argument is provided.

Definition at line 293 of file globalbase.cpp.

void GlobalBase::correctType int  index  )  [private, slot]
 

Corrects the calculation type, because only Single Point Energy and Energy & Forces are implemented ATM.

Definition at line 301 of file globalbase.cpp.

void GlobalBase::chooseDir  )  [private, slot]
 

Chooses a directory using a dialog.

Definition at line 310 of file globalbase.cpp.

void GlobalBase::makeConnections  )  [private]
 

Sets up the permanent connections. Called once from the constructor.

Definition at line 324 of file globalbase.cpp.

void GlobalBase::init  )  [private]
 

Initializes the dialog. Called once from the constructor.

Definition at line 350 of file globalbase.cpp.

void GlobalBase::saveWidgets  )  [private]
 

Saves the status of the widgets to a data struct.

Definition at line 362 of file globalbase.cpp.

void GlobalBase::restoreWidgets  )  [private]
 

Restores the status of the widgets from the data struct.

Definition at line 385 of file globalbase.cpp.


Member Data Documentation

WidgetData GlobalBase::data [private]
 

Internal data structure.

Definition at line 97 of file globalbase.h.

QString GlobalBase::defaultName [private]
 

Name() when reset is issued.

Definition at line 98 of file globalbase.h.

bool GlobalBase::widgetChanged [private]
 

Holds the 'changed' property of the widget.

Definition at line 99 of file globalbase.h.


Generated on Fri May 19 14:31:57 2006 for Brabosphere by  doxygen 1.4.6-NO