Main Page   Class Hierarchy   Compound List   File List   Compound Members   File Members  

TxqPlotTrol Class Reference

This class controls the creation, destruction and placement of 2d and 3d plot windows. More...

#include <TxqPlotTrol.h>

Inheritance diagram for TxqPlotTrol::

QObject List of all members.

Public Slots

void remove2dWindow (int index)
 Remove the entry from the Txq2dWindow lists associated with this index. More...

void remove3dWindow (int index)
 Remove the entry from the Txq3dWindow lists associated with this index. More...

void stopModel ()
 slot to stop the model. More...

void startModel ()
 slot to start the model. More...


Signals

void close2dSignal (int windex)
 public signal to set the close flag upon closing a 2d window. More...

void close3dSignal (int windex)
 public signal to set the close flag upon closing a 3d window. More...

void stopModelSignal ()
 signal to stop the model. More...

void startModelSignal ()
 signal to start the model. More...


Public Methods

 TxqPlotTrol (const QString &fileName=QString::null, const bool readFlag=false, int numWindows=0)
 The TxqPlotTrol constructor will construct an object to control the two and three dimensional windows. More...

virtual ~TxqPlotTrol ()
 TxqPlotTrol destructor clears all the vectors. More...

virtual void writeConfig ()
 Write the config file. More...

virtual void begin ()
 Begin the construction and placement of all the windows. More...

virtual void setFileName (const QString &name)
 Set the config filename filename. More...

virtual void setNumberWindows (int n)
 Set the number of windows in the list. More...

virtual void add2dWindow (int i)
 Add the entry to the Txq2dFrame lists. More...

virtual void add3dWindow (int i)
 Add the entry to the Txq3dFrame lists. More...

virtual void closeAll ()
 Close all the windows. More...

virtual void closeWindow (int index)
 Close the window at this index number. More...

virtual void move (int type, int index)
 Move the window. More...


Public Attributes

TXSTD::vector<Txq2dFrame *> plot2dWindows
 plot2dWindows contains the pointers to the created TxqP2dindow. More...

TXSTD::vector<int> plotType
 plotType contains the 2d or 3d plot type information. More...

TXSTD::vector<int> openFlag
 openFlag determines if the window is opened. More...

TXSTD::vector<int> plotIndex
 plotIndex is the index number into plot?dWindows must be used in conjunction with plotType. More...

TXSTD::map<int,int> plot2dIndexMap
 The plot2dIndexMap is a map of the index number with the plot2dIndexNumber such that plot2dIndexMap[plot2dIndexNumber] will equal the index number of the window in the plotIndex vector. More...

TXSTD::map<int,int> plot3dIndexMap
 The plot3dIndexMap is a map of the index number with the plot3dIndexNumber such that plot3dIndexMap[plot3dIndexNumber] will equal the index number of the window in the plotIndex vector. More...

TXSTD::vector<TXSTD::string> plotLabel
 plotLabel pointer is the diagnostic name of the plot. More...

TXSTD::vector<QPoint> plotPos
 plotPos is the plot's position within the desktop. More...

TXSTD::vector<int> plotWidth
 plotWidth is the list of window widths. More...

TXSTD::vector<int> plotHeight
 plotHeight is the list of window heights. More...


Protected Methods

virtual void remove2dWindow (int i, int wi)
 Remove the entry from the plot2dWindow lists. More...

virtual void remove3dWindow (int i, int wi)
 Remove the entry from the plot3dWindow lists. More...

virtual void readConfig ()
 Read the config file. More...

virtual void appendData (int index, int flag, TXSTD::string label, int type)
 Append the data to the lists. More...

virtual int getType (int index)=0
 Get the window type, 2 for 2d, 3 for 3d from auxillary data given an index number. More...

virtual TXSTD::string getLabel (int index)=0
 Get the window label for this index from auxillary data. More...

virtual int getOpenFlag (int index)=0
 Get the open flag for this index from auxillary data. More...

virtual int getModelState ()=0
 Get the model state from a model pointer that must be defined by derived class. More...

virtual void appendAuxData (int index)
 Append auxillary data. More...

virtual Txq2dFramecreate2dWindow (int index, int pltIndex)
 Create the 2d window. More...

virtual Txq3dFramecreate3dWindow (int index, int pltIndex)
 Create the 3d window. More...


Protected Attributes

int numberOfWindows
 The number of open windows. More...

QString inputFileName
 The input filename. More...


Private Methods

int getOption (const TxAttributeSet &config, TXSTD::string optionName)
 Get the option from the config set if the option is a string rather than an integer. More...

void appendNewData (int index, int flag, TXSTD::string label, int type)
 Append new data to the data vectors. More...

void updateGeometry ()
 Update the geometry vectors. More...


Private Attributes

int indexNumber
 The index number into theWindowArray list. More...

int plot2dIndexNumber
 The index number into the plot2dWindows list. More...

int plot3dIndexNumber
 The index number into the plot3dWindows list. More...

int numberOfOpenPlotWindows
 The number of open plot windows. More...

int sx
 The starting position for the windows. More...

int sy
 The starting position for the windows. More...

QString configFileName
 The config file name. More...

TxHierAttribSet* configSet
 The TxHierAttribSet containing the config file information. More...

bool haveConfig
 The bool to determine if the config set is valid. More...


Detailed Description

This class controls the creation, destruction and placement of 2d and 3d plot windows.

Copyright 2002 by Tech-X Corporation

Author:
Kelly G. Luetkemeyer

Version:
Id:
TxqPlotTrol.h,v 1.7 2002/01/17 21:02:57 kgl Exp

Definition at line 55 of file TxqPlotTrol.h.


Constructor & Destructor Documentation

TxqPlotTrol::TxqPlotTrol ( const QString & fileName = QString::null,
const bool readFlag = false,
int numWindows = 0 )
 

The TxqPlotTrol constructor will construct an object to control the two and three dimensional windows.

Parameters:
fileName   the configuration filename defaults to null This filename contains config information as a TxHierAttribSet with each individual window information contained as a TxAttributeSet. (See the default test.config file as an example)
readFlag   the bool readFlag determines whether to read a configuration file.
numWindows   the number of windows that can be opened/closed.

TxqPlotTrol::~TxqPlotTrol ( ) [virtual]
 

TxqPlotTrol destructor clears all the vectors.


Member Function Documentation

void TxqPlotTrol::add2dWindow ( int i ) [virtual]
 

Add the entry to the Txq2dFrame lists.

Parameters:
i   the index number for this entry.

void TxqPlotTrol::add3dWindow ( int i ) [virtual]
 

Add the entry to the Txq3dFrame lists.

Parameters:
i   the index number for this entry.

void TxqPlotTrol::appendAuxData ( int index ) [inline, protected, virtual]
 

Append auxillary data.

Parameters:
index   the index number to use for the auxillary data.

Definition at line 308 of file TxqPlotTrol.h.

void TxqPlotTrol::appendData ( int index,
int flag,
TXSTD::string label,
int type ) [protected, virtual]
 

Append the data to the lists.

Parameters:
index   the index number
flag   the open flag
label   the window label
type   the window type

void TxqPlotTrol::appendNewData ( int index,
int flag,
TXSTD::string label,
int type ) [private]
 

Append new data to the data vectors.

This will be invoked if a config set is not valid or not found. The data will be set to default values.

void TxqPlotTrol::begin ( ) [virtual]
 

Begin the construction and placement of all the windows.

void TxqPlotTrol::close2dSignal ( int windex ) [signal]
 

public signal to set the close flag upon closing a 2d window.

void TxqPlotTrol::close3dSignal ( int windex ) [signal]
 

public signal to set the close flag upon closing a 3d window.

void TxqPlotTrol::closeAll ( ) [virtual]
 

Close all the windows.

void TxqPlotTrol::closeWindow ( int index ) [virtual]
 

Close the window at this index number.

Parameters:
index   the index number associated with the window.

Txq2dFrame * TxqPlotTrol::create2dWindow ( int index,
int pltIndex ) [protected, virtual]
 

Create the 2d window.

Parameters:
index   the index number for the window
plotIndex   the plot index number

Txq3dFrame * TxqPlotTrol::create3dWindow ( int index,
int pltIndex ) [protected, virtual]
 

Create the 3d window.

Parameters:
index   the index number for the window
plotIndex   the plot index number

TXSTD::string TxqPlotTrol::getLabel ( int index ) [protected, pure virtual]
 

Get the window label for this index from auxillary data.

Parameters:
index   the associated index number for this label.

int TxqPlotTrol::getModelState ( ) [protected, pure virtual]
 

Get the model state from a model pointer that must be defined by derived class.

This is used to start/stop a model/application.

int TxqPlotTrol::getOpenFlag ( int index ) [protected, pure virtual]
 

Get the open flag for this index from auxillary data.

Parameters:
index   the associated index number for this flag.

int TxqPlotTrol::getOption ( const TxAttributeSet & config,
TXSTD::string optionName ) [private]
 

Get the option from the config set if the option is a string rather than an integer.

This method is needed because some compilers when reading the TxAttributeSet will not set the option parameters as strings.

Parameters:
config, the   config attribute set to get the data
optionName, the   option name key.

int TxqPlotTrol::getType ( int index ) [protected, pure virtual]
 

Get the window type, 2 for 2d, 3 for 3d from auxillary data given an index number.

This method must be defined by derived classes.

Parameters:
index   the index number to get the window type

void TxqPlotTrol::move ( int type,
int index ) [virtual]
 

Move the window.

Parameters:
type   the type of the window (2d or 3d)
index   the window index number

void TxqPlotTrol::readConfig ( ) [protected, virtual]
 

Read the config file.

void TxqPlotTrol::remove2dWindow ( int i,
int wi ) [protected, virtual]
 

Remove the entry from the plot2dWindow lists.

Parameters:
i   the index number associated with this window.
wi   the index number associated with this window.

void TxqPlotTrol::remove2dWindow ( int index ) [slot]
 

Remove the entry from the Txq2dWindow lists associated with this index.

Parameters:
index   the index number associated with this window.

void TxqPlotTrol::remove3dWindow ( int i,
int wi ) [protected, virtual]
 

Remove the entry from the plot3dWindow lists.

Parameters:
i   the index number associated with this window.
wi   the index number associated with this window.

void TxqPlotTrol::remove3dWindow ( int index ) [slot]
 

Remove the entry from the Txq3dWindow lists associated with this index.

Parameters:
index   the index number associated with this window.

void TxqPlotTrol::setFileName ( const QString & name ) [virtual]
 

Set the config filename filename.

Parameters:
name   the name to be used for the configuration file.

void TxqPlotTrol::setNumberWindows ( int n ) [inline, virtual]
 

Set the number of windows in the list.

Parameters:
n   the number of windows.

Definition at line 102 of file TxqPlotTrol.h.

void TxqPlotTrol::startModel ( ) [slot]
 

slot to start the model.

void TxqPlotTrol::startModelSignal ( ) [signal]
 

signal to start the model.

void TxqPlotTrol::stopModel ( ) [slot]
 

slot to stop the model.

void TxqPlotTrol::stopModelSignal ( ) [signal]
 

signal to stop the model.

void TxqPlotTrol::updateGeometry ( ) [private]
 

Update the geometry vectors.

void TxqPlotTrol::writeConfig ( ) [virtual]
 

Write the config file.


Member Data Documentation

QString TxqPlotTrol::configFileName [private]
 

The config file name.

Definition at line 386 of file TxqPlotTrol.h.

TxHierAttribSet * TxqPlotTrol::configSet [private]
 

The TxHierAttribSet containing the config file information.

Definition at line 391 of file TxqPlotTrol.h.

bool TxqPlotTrol::haveConfig [private]
 

The bool to determine if the config set is valid.

Definition at line 396 of file TxqPlotTrol.h.

int TxqPlotTrol::indexNumber [private]
 

The index number into theWindowArray list.

Definition at line 361 of file TxqPlotTrol.h.

QString TxqPlotTrol::inputFileName [protected]
 

The input filename.

Definition at line 332 of file TxqPlotTrol.h.

int TxqPlotTrol::numberOfOpenPlotWindows [private]
 

The number of open plot windows.

Definition at line 376 of file TxqPlotTrol.h.

int TxqPlotTrol::numberOfWindows [protected]
 

The number of open windows.

Definition at line 327 of file TxqPlotTrol.h.

TXSTD::vector< int > TxqPlotTrol::openFlag
 

openFlag determines if the window is opened.

Definition at line 156 of file TxqPlotTrol.h.

TXSTD::map< int, int > TxqPlotTrol::plot2dIndexMap
 

The plot2dIndexMap is a map of the index number with the plot2dIndexNumber such that plot2dIndexMap[plot2dIndexNumber] will equal the index number of the window in the plotIndex vector.

Definition at line 169 of file TxqPlotTrol.h.

int TxqPlotTrol::plot2dIndexNumber [private]
 

The index number into the plot2dWindows list.

Definition at line 366 of file TxqPlotTrol.h.

TXSTD::vector< Txq2dFrame *> TxqPlotTrol::plot2dWindows
 

plot2dWindows contains the pointers to the created TxqP2dindow.

Definition at line 137 of file TxqPlotTrol.h.

TXSTD::map< int, int > TxqPlotTrol::plot3dIndexMap
 

The plot3dIndexMap is a map of the index number with the plot3dIndexNumber such that plot3dIndexMap[plot3dIndexNumber] will equal the index number of the window in the plotIndex vector.

Definition at line 176 of file TxqPlotTrol.h.

int TxqPlotTrol::plot3dIndexNumber [private]
 

The index number into the plot3dWindows list.

Definition at line 371 of file TxqPlotTrol.h.

TXSTD::vector< int > TxqPlotTrol::plotHeight
 

plotHeight is the list of window heights.

Definition at line 196 of file TxqPlotTrol.h.

TXSTD::vector< int > TxqPlotTrol::plotIndex
 

plotIndex is the index number into plot?dWindows must be used in conjunction with plotType.

Definition at line 162 of file TxqPlotTrol.h.

TXSTD::vector< TXSTD::string > TxqPlotTrol::plotLabel
 

plotLabel pointer is the diagnostic name of the plot.

Definition at line 181 of file TxqPlotTrol.h.

TXSTD::vector< QPoint > TxqPlotTrol::plotPos
 

plotPos is the plot's position within the desktop.

Definition at line 186 of file TxqPlotTrol.h.

TXSTD::vector< int > TxqPlotTrol::plotType
 

plotType contains the 2d or 3d plot type information.

Definition at line 151 of file TxqPlotTrol.h.

TXSTD::vector< int > TxqPlotTrol::plotWidth
 

plotWidth is the list of window widths.

Definition at line 191 of file TxqPlotTrol.h.

int TxqPlotTrol::sx [private]
 

The starting position for the windows.

Definition at line 381 of file TxqPlotTrol.h.

int TxqPlotTrol::sy [private]
 

The starting position for the windows.

Definition at line 381 of file TxqPlotTrol.h.


The documentation for this class was generated from the following file: Copyright Tech-X Corporation, all rights reserved.