class Document

(abstract) document class; generalization of diagram, tree, table, etc.

Inheritance:


Public Classes

enum MoveType

Public Methods

Document (Config *c, EditWindow *d, Viewer *v)
virtual ~Document ()
void New ()
opens new document called untitled.'suffix'.
virtual void Load ()
popup file selector dialog for loading a file.
virtual void Append ()
same as load but old document remains unchanged.
void Save ()
save document to file.
void SaveAs ()
popup file selector dialog for saving to a file.
void SaveSelectionAs ()
popup file selector dialog for saving selection to a file.
void Quit ()
closes document (asks confirmation) and quits application.
void ShowDocInfo ()
popup info dialog containing information about this document.
void ShowSource ()
popup text edit dialog with document source from file.
void SaveSource ()
save edited source back to file.
virtual void ShowSummary ()
popup info dialog containing summary of contents of this document.
virtual void CheckDocument ()
popup warning dialog containing soft constraint violations (syntactic)
virtual void ModelCheckDocument ()
popup dialog to model check the document (semantic check)
void Annotate ()
popup text edit dialog in which doc. annotation can be given.
void LoadSave (const string *file)
called from file selector dialog callbacks.
virtual void DoLoad (const string *file)
load document from file.
void DoSaveAs (const string *file)
void DoSaveSelectionAs (const string *file)
double GetLoadFormat () const
return format that was found in file that is read in.
virtual void Initialize ()
perform some document type specific initialization.
void NewFile (const string *file)
Checks if file is legal and opens new document with file as name.
virtual void RemoveAll ()
Delete contents of the document.
bool NewName (const string *newname)
Checks if newname is legal, and if so, changes name of document.
void SetName (const string *newname)
const string* GetName () const
const string* GetDocType () const
const string* GetSuffix () const
const string* GetToolName () const
const string* GetAuthor () const
const string* GetCreationTime () const
bool IsDefault ()
return whether doc.name is the default name.
void NewDir (const string *newdir)
Checks if newdir is legal, and if so, changes current directory.
void SetDir (const string *newdir)
const string* GetDir () const
void SetFSDir ()
Set dir from file selector.
void IncChanges ()
increases number of changes.
void DecChanges ()
decrease number of changes.
int GetChanges () const
virtual void SetInlineEdit (bool)
set inline edit (doc. type specific).
virtual void Move (MoveType)
move document in mainwindow.
bool IsModified () const
void SetModified (bool set)
bool IsLoaded () const
bool MayWrite (const string *path)
ask user to confirm that a file may be overwritten
void SetStatus (const char *msg)
set main window status message to msg.
void SetStatus (const string *msg)
void SetAnnotation (const string *s)
set document annotation text to s.
virtual void FindAll (const string *, bool, bool, bool)
find all strings.
virtual void FindNext (const string *, bool, bool, bool)
find next string.
virtual void ReplaceAll (const string *, const string *, bool, bool, bool)
replace all strings.
virtual void ReplaceNext (const string *, const string *, bool, bool, bool)
replace next string.
virtual void Find ()
issue a popup dialog for getting a search string.
virtual void Replace ()
issue a popup dialog for search and replace strings.
void UpdateWindow ()
update main window document text fields
EditWindow* GetMainWindow () const
Config* GetConfig () const
Viewer* GetViewer () const
InputFile* GetInputFile () const
OutputFile* GetOutputFile () const
TextEditDialog* GetSourceEditDialog () const
TextEditDialog* GetDocAnnotationDialog () const
TextEditDialog* GetEltAnnotationDialog () const
FileSelectionDialog* GetFileSelectionDialog () const
FindDialog* GetFindDialog () const
ReplaceDialog* GetReplaceDialog () const

Protected Fields

string chkbuf
message string filled by Check Document.

Protected Methods

virtual void LoadEntries ()
...
virtual void SaveEntries ()
...
bool IsAppending () const
bool IsSaveSelection () const
virtual void UpdateDirectory (const string *s)
Set directory in all dialogs.
void ShowDialog (MessageDialog::DialogType, const char *title, const char *text)
void ShowDialog (MessageDialog::DialogType, const char *title, const string *text)
void ReportCheck (int errors, const string *msg)
Give results of Check Document in popup dialog.
bool Save (const string *file)
function needed for saving to file.

Documentation

(abstract) document class; generalization of diagram, tree, table, etc.
Document(Config *c, EditWindow *d, Viewer *v)

virtual ~Document()

void New()
opens new document called untitled.'suffix'.

virtual void Load()
popup file selector dialog for loading a file.

virtual void Append()
same as load but old document remains unchanged.

void Save()
save document to file.

void SaveAs()
popup file selector dialog for saving to a file.

void SaveSelectionAs()
popup file selector dialog for saving selection to a file.

void Quit()
closes document (asks confirmation) and quits application.

void ShowDocInfo()
popup info dialog containing information about this document.

void ShowSource()
popup text edit dialog with document source from file.

void SaveSource()
save edited source back to file.

virtual void ShowSummary()
popup info dialog containing summary of contents of this document.

virtual void CheckDocument()
popup warning dialog containing soft constraint violations (syntactic)

virtual void ModelCheckDocument()
popup dialog to model check the document (semantic check)

void Annotate()
popup text edit dialog in which doc. annotation can be given.

void LoadSave(const string *file)
called from file selector dialog callbacks.

virtual void DoLoad(const string *file)
load document from file.

void DoSaveAs(const string *file)

void DoSaveSelectionAs(const string *file)

double GetLoadFormat() const
return format that was found in file that is read in.

virtual void Initialize()
perform some document type specific initialization.

void NewFile(const string *file)
Checks if file is legal and opens new document with file as name.

virtual void RemoveAll()
Delete contents of the document.

bool NewName(const string *newname)
Checks if newname is legal, and if so, changes name of document.

void SetName(const string *newname)

const string* GetName() const

const string* GetDocType() const

const string* GetSuffix() const

const string* GetToolName() const

const string* GetAuthor() const

const string* GetCreationTime() const

bool IsDefault()
return whether doc.name is the default name.

void NewDir(const string *newdir)
Checks if newdir is legal, and if so, changes current directory.

void SetDir(const string *newdir)

const string* GetDir() const

void SetFSDir()
Set dir from file selector.

void IncChanges()
increases number of changes.

void DecChanges()
decrease number of changes.

int GetChanges() const

virtual void SetInlineEdit(bool)
set inline edit (doc. type specific).

enum MoveType

virtual void Move(MoveType)
move document in mainwindow.

bool IsModified() const

void SetModified(bool set)

bool IsLoaded() const

bool MayWrite(const string *path)
ask user to confirm that a file may be overwritten

void SetStatus(const char *msg)
set main window status message to msg.

void SetStatus(const string *msg)

void SetAnnotation(const string *s)
set document annotation text to s.

virtual void FindAll(const string *, bool, bool, bool)
find all strings.

virtual void FindNext(const string *, bool, bool, bool)
find next string.

virtual void ReplaceAll(const string *, const string *, bool, bool, bool)
replace all strings.

virtual void ReplaceNext(const string *, const string *, bool, bool, bool)
replace next string.

virtual void Find()
issue a popup dialog for getting a search string.

virtual void Replace()
issue a popup dialog for search and replace strings.

void UpdateWindow()
update main window document text fields

EditWindow* GetMainWindow() const

Config* GetConfig() const

Viewer* GetViewer() const

InputFile* GetInputFile() const

OutputFile* GetOutputFile() const

TextEditDialog* GetSourceEditDialog() const

TextEditDialog* GetDocAnnotationDialog() const

TextEditDialog* GetEltAnnotationDialog() const

FileSelectionDialog* GetFileSelectionDialog() const

FindDialog* GetFindDialog() const

ReplaceDialog* GetReplaceDialog() const

virtual void LoadEntries()
...

virtual void SaveEntries()
...

bool IsAppending() const

bool IsSaveSelection() const

virtual void UpdateDirectory(const string *s)
Set directory in all dialogs.

void ShowDialog(MessageDialog::DialogType, const char *title, const char *text)

void ShowDialog(MessageDialog::DialogType, const char *title, const string *text)

void ReportCheck(int errors, const string *msg)
Give results of Check Document in popup dialog.

string chkbuf
message string filled by Check Document.

bool Save(const string *file)
function needed for saving to file.


Direct child classes:
Table
Diagram

alphabetic index hierarchy of classes


this page has been generated automatically by doc++

(c)opyright by Malte Zöckler, Roland Wunderling
contact: doc++@zib.de