- Main Page
- Classes
- Files
- Related Pages
- Examples

- Class List
- Class Hierarchy
- Class Members

# IAEX::CellApplication Class Reference

Implements the application interface. This class is the main controller of the program. More...

Inheritance diagram for IAEX::CellApplication:

List of all members.

## Public Member Functions
virtual | ~CellApplication ()
| Class destructor.
virtual CommandCenter * | commandCenter ()
virtual void | setCommandCenter (CommandCenter *c)
virtual void | addToPasteboard (Cell *c)
virtual void | clearPasteboard ()
vector< Cell * > | pasteboard ()
int | exec ()
void | add (Document *doc)
void | add (DocumentView *view)
void | open (const QString filename, int readmode=READMODE_NORMAL)
| Open an file, and display the content of hte file.
void | removeTempFiles (QString filename)
| Add filename to a list of temporary files that should be deleted when the applicaiton quits.
vector< DocumentView * > | documentViewList ()
| returns list of all current doucment views
void | removeDocumentView (DocumentView *view)
| remove document view from internal list, also remove document

## Detailed Description

Implements the application interface. This class is the main controller of the program.

Author:
  Ingemar Axelsson and Anders Fernström

Date:
  2006-04-10 (update)

This class has the responsibility to open new windows, open new documents and handle commands. Commands are sent to a commandCenter object where they are executed and stored (they should be stored).

2005-10-25 AF, Added a check to see if OMC is running, if not - try to start OMC. 2005-12-16 AF, Added code that create an instance of CommandCompletion, so all commands are loaded from the beginning. 2005-12-17 AF, Added code that create instance of stylesheet, so the styles are loaded from the beginning. 2006-01-09 AF, added a new highlight thread with the 'openmodelicahighlighter' as the highlighter that should be used. 2006-02-09 AF, code for starting omc have been moved to the omc interactive environment. 2006-02-13 AF, create temp dir 2006-02-27 AF, use environment variable to find DrModelica 2006-03-24 AF, first look for DrModelica.onb, and then for DrModelica.nb 2006-04-10 AF, use environment variable to find xml files 2006-04-10 AF, Open file that is sent to main

## Constructor & Destructor Documentation

IAEX::CellApplication::~CellApplication | ( |  | ) | `[virtual]`

| Class destructor. Author: Anders Fernström and Ingemar Axelsson Date: 2006-05-03 (update) 2005-11-24 AF, Added code that quited OMC, if it was still running. 2005-12-19 AF, Added code that stopped the highlighter thread, if it is running 2006-01-16 AF, Go Through remove list and remove all temporary files. 2006-02-09 AF, moved code for quiting omc to notebook windows closeEvent handler 2006-02-13 AF, remove temp dir 2006-05-03 AF, delete notebook socket

## Member Function Documentation

void IAEX::CellApplication::add | ( | DocumentView * | d | ) |

| Author: Ingemar Axelsson

void IAEX::CellApplication::add | ( | Document * | d | ) |

| Author: Ingemar Axelsson

void IAEX::CellApplication::addToPasteboard | ( | Cell * | c | ) | `[virtual]`

| Author: Anders Fernström and Ingemar Axelsson Date: 2006-01-12 (update) 2006-01-12 AF, added so any images in the cell are copied. 2006-02-13 AF, removed code for copy image Todo: Create a pasteboard class as a Singleton that should be used instead of having a singleton inside the application class. Other things to do is to use the systemwide pasteboard instead. (Ingemar Axelsson) Implements IAEX::Application.

void IAEX::CellApplication::clearPasteboard | ( |  | ) | `[virtual]`

| Author: Ingemar Axelsson This is used to clear the pasteboard. This is an ugly solution. Implements IAEX::Application.

CommandCenter * IAEX::CellApplication::commandCenter | ( |  | ) | `[virtual]`

| Author: Ingemar Axelsson Implements IAEX::Application.

vector< DocumentView * > IAEX::CellApplication::documentViewList | ( |  | ) | `[virtual]`

| returns list of all current doucment views Author: Anders Fernström Date: 2006-01-27 Implements IAEX::Application.

int IAEX::CellApplication::exec | ( |  | ) |

| Author: Ingemar Axelsson

void IAEX::CellApplication::open | ( | const QString | filename,
|  | int | readmode = `READMODE_NORMAL`
| ) | `[virtual]`

| Open an file, and display the content of hte file. Author: Ingemar Axelsson and Anders Fernström Date: 2006-05-03 (update) 2005-09-22 AF, added the filename to the NotebookWindow() call 2005-10-11 AF, Porting, added resize call, so all cells get the correct size. Ugly way! 2005-11-30 AF, added code to launch the visitor that applies hide() and show() to groupcells. 2005-12-01 AF, added a try-catch statment around the function 2006-01-17 AF, added code that set the change variable in a document to false. 2006-01-31 AF, open windows minimized, then show normal when all operations are done on the window. 2006-05-03 AF, during open, stop highlighter Implements IAEX::Application.

vector< Cell * > IAEX::CellApplication::pasteboard | ( |  | ) | `[virtual]`

| Author: Ingemar Axelsson returns a vector with all content of the pasteboard. Implements IAEX::Application.

void IAEX::CellApplication::removeDocumentView | ( | DocumentView * | view | ) | `[virtual]`

| remove document view from internal list, also remove document Author: Anders Fernström Date: 2006-01-27 Implements IAEX::Application.

void IAEX::CellApplication::removeTempFiles | ( | QString | filename | ) | `[virtual]`

| Add filename to a list of temporary files that should be deleted when the applicaiton quits. Author: Anders Fernström Date: 2006-01-16 Implements IAEX::Application.

void IAEX::CellApplication::setCommandCenter | ( | CommandCenter * | c | ) | `[virtual]`

| Author: Ingemar Axelsson Implements IAEX::Application.

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

- C:/OpenModelica/OMNotebookQT4 v2/OMNotebookQT4/cellapplication.h
- C:/OpenModelica/OMNotebookQT4 v2/OMNotebookQT4/cellapplication.cpp