#include <molecularFileDialog.h>
Inheritance diagram for VIEW::MolecularFileDialog:
Public Slots | |
virtual void | readFiles () |
Open a molecular file. | |
virtual bool | writeFile () |
Write a molecular file. | |
Public Member Functions | |
MolecularFileDialog (QWidget *parent=0, const char *name="MolecularFileDialog") throw () | |
Default Constructor. | |
virtual | ~MolecularFileDialog () throw () |
Destructor. | |
virtual void | initializeWidget (MainControl &main_control) throw () |
Initializes the menu entries in File. | |
virtual bool | canHandle (const String &fileformat) const |
Test if this ModularWidget can handle a given file format. | |
virtual bool | openFile (const String &filename) |
Tell this ModularWidget to open a given file. | |
virtual System * | openMolecularFile (const String &file) throw () |
Open a given molecular file. | |
virtual System * | openMolecularFile (const String &filename, const String &filetype, const String &system_name) throw () |
Wrapper for the read methods. | |
System * | openPDBFile () |
System * | openHINFile () |
System * | openMOLFile () |
System * | openMOL2File () |
System * | openSDFile () |
System * | openXYZFile () |
System * | readPDBFile (String filename, String system_name) throw () |
Read a PDB file. | |
System * | readHINFile (String filename, String system_name) throw () |
Read a HIN file. | |
System * | readMOLFile (String filename, String system_name) throw () |
Read a MOL file. | |
System * | readMOL2File (String filename, String system_name) throw () |
Read a MOL2 file. | |
System * | readSDFile (String filename, String system_name) throw () |
Read a SD file. | |
System * | readXYZFile (String filename, String system_name) throw () |
Read a XYZ file. | |
bool | writePDBFile (String filename, const System &system) throw () |
Write a PDB file. | |
bool | writeHINFile (String filename, const System &system) throw () |
Write a HIN file. | |
bool | writeMOLFile (String filename, const System &system) throw () |
Write a MOL file. | |
bool | writeMOL2File (String filename, const System &system) throw () |
Write a MOL2 file. | |
bool | writeSDFile (String filename, const System &system) throw () |
Write a SD file. | |
bool | writeXYZFile (String filename, const System &system) throw () |
Write a XYZ file. | |
virtual void | checkMenu (MainControl &main_control) throw () |
Overloaded from ModularWidget. | |
virtual String | getSupportedFileFormats () const |
virtual String | getSupportedFileFormatsList () const |
Protected Types | |
enum | FileFormats { PDB_FILE = 0, HIN_FILE, MOL_FILE, MOL2_FILE, SD_FILE, XYZ_FILE } |
Protected Member Functions | |
virtual void | onNotify (Message *message) throw () |
Message handling method. | |
MolecularFileDialog (const MolecularFileDialog &mfd) throw () | |
virtual bool | finish_ (const String &filename, const String &system_name, System *system) throw () |
System * | openFile_ (String type) |
Protected Attributes | |
QAction * | save_id_ |
QAction * | open_id_ |
String | file_format_ |
This class is used to read or write Molecular files in one of several file formats. Currently supported file formats are:
|
Default Constructor. |
|
Test if this ModularWidget can handle a given file format. (Overloaded from ModularWidget)
Reimplemented from VIEW::ModularWidget. |
|
Initializes the menu entries in File. This method is called automatically immediately before the main application is started. This method will be called MainControl::show().
Reimplemented from VIEW::ModularWidget. |
|
Message handling method. This method handles messages sent to this connectionObject. If a certain message should be processed for this connectionObject this method must be overridden. With the help of the RTTI methods one can easily determine if an incoming message is relevant for this connectionObject. See Message for further information concerning messages.
Reimplemented from VIEW::ConnectionObject. |
|
Tell this ModularWidget to open a given file. (Overloaded from ModularWidget)
Reimplemented from VIEW::ModularWidget. |
|
Wrapper for the read methods. The filetype String is used to indentify the file type (HIN, PDP, MOL, MOL2). It is possible to give the system a designated name, otherwise it is named by the file. |
|
Open a given molecular file. The file type is identified by the filename extension. This method can be used to load molecular files, which were given as command line arguments. |
|
Open a molecular file. This method tries to open and read a molecular file, selected from a QFileDialog, and, if susccesfull, converts is into a System. Then it sends a CompositeMessage containing the System to the other ConnectionObject instances.
|
|
Write a molecular file. This method takes a System and saves it into a molecular file, selected from a QFileDialog. |