Isis Developer Reference
Isis::GuiEditFile Class Reference

Opens a window in Gui Application to be able to edit, save and create text files. More...

#include <GuiEditFile.h>

Inheritance diagram for Isis::GuiEditFile:
Inheritance graph
Collaboration diagram for Isis::GuiEditFile:
Collaboration graph

Public Slots

void open ()
 For action File->Open.
 
void OpenFile (QString)
 To display the contents of an opened file.
 
void setTextChanged ()
 Indicator that the text has changed.
 
void saveAs ()
 For action File->Save As.
 
void saveAsFile (QString)
 Save the contents of text editor to another file.
 
void saveFile ()
 For action File->Save.
 
void closeFile ()
 For action File->Close.
 
void closeWin ()
 For action Exit (close the window)
 

Public Member Functions

void showWindow (QString psFile="")
 If there is already an instance of this object, then display the window.
 
 ~GuiEditFile ()
 Destructor.
 
void clearFile ()
 Delete the contents of a file.
 

Static Public Member Functions

static void EditFile (UserInterface &pUI, QString psFile="")
 Creates a single instance of the GuiEditFile.
 

Detailed Description

Opens a window in Gui Application to be able to edit, save and create text files.

Creates a singleton window to edit files.

Example can be used to edit DefFiles in control net applications. Refer to cnetedit Application

Author
2011-05-21 Sharmila Prasad

Constructor & Destructor Documentation

◆ ~GuiEditFile()

Isis::GuiEditFile::~GuiEditFile ( )

Destructor.

Author
Sharmila Prasad (5/20/2011)

Member Function Documentation

◆ clearFile()

void Isis::GuiEditFile::clearFile ( )

Delete the contents of a file.

Delete the contents of the current file - especially if changes are made and they are not to be saved.

Author
Sharmila Prasad (5/23/2011)

Referenced by saveFile().

◆ closeFile

void Isis::GuiEditFile::closeFile ( )
slot

For action File->Close.

Action File->close, close the opened file.

Author
Sharmila Prasad (5/20/2011)

References saveFile().

◆ closeWin

void Isis::GuiEditFile::closeWin ( )
slot

For action Exit (close the window)

Action Exit - Close window and clear text editor.

Author
Sharmila Prasad (5/23/2011)

◆ EditFile()

void Isis::GuiEditFile::EditFile ( UserInterface & pUI,
QString psFile = "" )
static

Creates a single instance of the GuiEditFile.

If already an instance, display the object

Author
Sharmila Prasad (5/20/2011)
Parameters
pUI- User Interface of parent app
psFile- File to edit

◆ open

void Isis::GuiEditFile::open ( )
slot

For action File->Open.

Action File->Open.

Author
Sharmila Prasad (5/20/2011)

References OpenFile(), and saveFile().

◆ OpenFile

void Isis::GuiEditFile::OpenFile ( QString psOutFile)
slot

To display the contents of an opened file.

Display the selected file.

Author
Sharmila Prasad (5/20/2011)
Parameters
psOutFile

Referenced by open(), and showWindow().

◆ saveAs

void Isis::GuiEditFile::saveAs ( )
slot

For action File->Save As.

Action File->Save As.

Author
Sharmila Prasad (5/23/2011)

References saveAsFile().

◆ saveAsFile

void Isis::GuiEditFile::saveAsFile ( QString psNewFile)
slot

Save the contents of text editor to another file.

Copy the current file into user selected file.

Author
Sharmila Prasad (5/23/2011)
Parameters
psNewFile

References saveFile().

Referenced by saveAs().

◆ saveFile

void Isis::GuiEditFile::saveFile ( )
slot

For action File->Save.

Action File->Save.

Author
Sharmila Prasad (5/20/2011)

References clearFile().

Referenced by closeFile(), open(), and saveAsFile().

◆ setTextChanged

void Isis::GuiEditFile::setTextChanged ( )
slot

Indicator that the text has changed.

Flag to indicate text has changed.

Author
Sharmila Prasad (5/20/2011)

◆ showWindow()

void Isis::GuiEditFile::showWindow ( QString psFile = "")

If there is already an instance of this object, then display the window.

Display the window if there is already an instance of this object.

Author
Sharmila Prasad (5/23/2011)
Parameters
psFile- File to edit

References OpenFile().


The documentation for this class was generated from the following files: