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

TxqImageFrame Class Reference

The TxqImageFrame displays an image from a file onto this frame. More...

#include <TxqImageFrame.h>

Inheritance diagram for TxqImageFrame::

TxqFrame QFrame List of all members.

Public Slots

void print ()
 slot to print the canvas. More...


Signals

void closeSignal (int indx)
 signal emitted when the window is closing. More...

void clearMemory ()
 signal emitted when needing to clear the pixmap map memory. More...


Public Methods

 TxqImageFrame (QString fileName, TxqMasterIoFrame *parent, const char *nm=0, WFlags f=WType_TopLevel)
 The constructor requires the image file and can also add the QWidget parent. More...

virtual ~TxqImageFrame ()
 The destructor. More...

void setPixmap (QPixmap *pm)
 Set the pixmap to write the image onto. More...

void setPixmapMemory (bool memory)
 Set the memory flag. More...

void setFileName (const QString fileName)
 Set the filename. More...

void advance (const QString fileName, int frameNumber)
 Advance the movie. More...

void setIndex (int indx)
 Set the window index. More...

bool getPixmapMemory ()
 Get the pixmap memory flag. More...

void clearMapElements (unsigned int n)
 clear N elements from the pixmap. More...

void clearPixMaps ()
 Clear the pixmaps pointers from the pixmap map. More...


Protected Slots

bool close (bool forceKill=FALSE)
 Close and quit the window. More...


Protected Methods

void readImage (const QString fileName)
 read the image file and convert to a pixmap. More...

virtual void addMenuBarItems ()
 Add the default menu bar items. More...

virtual void addSubMenuBarItems ()
 Add the sub menu bar items The sub menubar items are any menus in the menubar that may need items inserted into it. More...

void addWidgets ()
 Add the widgets. More...

void paintEvent (QPaintEvent *)
 The paint event will paint the image onto the widget. More...


Private Methods

 TxqImageFrame ()
 The default constructor is private in order to not be used. More...


Private Attributes

QPixmap* pixmap
 The private pixmap. More...

TXSTD::map<QString, QPixmap*> pixMaps
 The pixmap maps. More...

QWidgetpaintWidget
 The background paint widget. More...

int windowIndex
 The window index. More...

bool memory
 bool to determine if using memory pixmaps. More...

bool memoryExhausted
 bool to determine if memory is exhausted. More...

TxqLogtxcout
 The output logger. More...

TxqLogtxcerr
 The error output logger. More...

bool isPainted
 The paint flag. More...

unsigned int clearElements
 The number of elements to clear from the pixmap map when the memory is exhausted. More...

int frameNumber
 The current frame number. More...

QString imageFileName
 The class image file name. More...


Detailed Description

The TxqImageFrame displays an image from a file onto this frame.

Copyright 2000 by Tech-X Corporation

Author:
Kelly G. Luetkemeyer

Version:
Id:
TxqImageFrame.h,v 1.9 2001/10/12 20:08:08 kgl Exp

Definition at line 42 of file TxqImageFrame.h.


Constructor & Destructor Documentation

TxqImageFrame::TxqImageFrame ( QString fileName,
TxqMasterIoFrame * parent,
const char * nm = 0,
WFlags f = WType_TopLevel )
 

The constructor requires the image file and can also add the QWidget parent.

Parameters:
fileName   the image file name to either read or use as a key.
parent   the parent widget which must be supplied.
nm   the name of the widget which defaults to null.
f   the window flags which default to WType_TopLevel.

TxqImageFrame::~TxqImageFrame ( ) [virtual]
 

The destructor.

TxqImageFrame::TxqImageFrame ( ) [private]
 

The default constructor is private in order to not be used.


Member Function Documentation

void TxqImageFrame::addMenuBarItems ( ) [protected, virtual]
 

Add the default menu bar items.

Reimplemented from TxqFrame.

void TxqImageFrame::addSubMenuBarItems ( ) [protected, virtual]
 

Add the sub menu bar items The sub menubar items are any menus in the menubar that may need items inserted into it.

Reimplemented from TxqFrame.

void TxqImageFrame::addWidgets ( ) [protected, virtual]
 

Add the widgets.

Reimplemented from TxqFrame.

void TxqImageFrame::advance ( const QString fileName,
int frameNumber )
 

Advance the movie.

Parameters:
filename   the fileName to either read or obtain the pixmap from the memory map.
frameNumber   the frameNumber for this image.

void TxqImageFrame::clearMapElements ( unsigned int n )
 

clear N elements from the pixmap.

Parameters:
n   the number of elements to clear from memory. This method is used when the system memory is getting full.

void TxqImageFrame::clearMemory ( ) [signal]
 

signal emitted when needing to clear the pixmap map memory.

void TxqImageFrame::clearPixMaps ( )
 

Clear the pixmaps pointers from the pixmap map.

bool TxqImageFrame::close ( bool forceKill = FALSE ) [protected, virtual, slot]
 

Close and quit the window.

Parameters:
forceKill   the forceKill bool is set to false as a default.

Reimplemented from TxqFrame.

void TxqImageFrame::closeSignal ( int indx ) [signal]
 

signal emitted when the window is closing.

Parameters:
indx   the index number of this frame.

bool TxqImageFrame::getPixmapMemory ( ) [inline]
 

Get the pixmap memory flag.

Returns:
the bool for determining if reading from memory the pixmaps.

Definition at line 102 of file TxqImageFrame.h.

void TxqImageFrame::paintEvent ( QPaintEvent * ) [protected]
 

The paint event will paint the image onto the widget.

Parameters:
e   the QPaintEvent

void TxqImageFrame::print ( ) [virtual, slot]
 

slot to print the canvas.

Reimplemented from TxqFrame.

void TxqImageFrame::readImage ( const QString fileName ) [protected]
 

read the image file and convert to a pixmap.

Parameters:
fileName   the filename to read and convert to a pixmap.

void TxqImageFrame::setFileName ( const QString fileName )
 

Set the filename.

Parameters:
fileName   the filename to read the image data. If using memory, then this filename is a key in the map.

void TxqImageFrame::setIndex ( int indx ) [virtual]
 

Set the window index.

Parameters:
indx   the window index number.

Reimplemented from TxqFrame.

void TxqImageFrame::setPixmap ( QPixmap * pm )
 

Set the pixmap to write the image onto.

Parameters:
pm   the QPixmap pointer.

void TxqImageFrame::setPixmapMemory ( bool memory )
 

Set the memory flag.

Parameters:
memory   the memory flag if true, the pixmaps will be painted from memory


Member Data Documentation

unsigned int TxqImageFrame::clearElements [private]
 

The number of elements to clear from the pixmap map when the memory is exhausted.

Definition at line 233 of file TxqImageFrame.h.

int TxqImageFrame::frameNumber [private]
 

The current frame number.

Definition at line 238 of file TxqImageFrame.h.

QString TxqImageFrame::imageFileName [private]
 

The class image file name.

Definition at line 243 of file TxqImageFrame.h.

bool TxqImageFrame::isPainted [private]
 

The paint flag.

Definition at line 227 of file TxqImageFrame.h.

bool TxqImageFrame::memory [private]
 

bool to determine if using memory pixmaps.

Definition at line 207 of file TxqImageFrame.h.

bool TxqImageFrame::memoryExhausted [private]
 

bool to determine if memory is exhausted.

Definition at line 212 of file TxqImageFrame.h.

QWidget * TxqImageFrame::paintWidget [private]
 

The background paint widget.

Definition at line 197 of file TxqImageFrame.h.

TXSTD::map< QString, QPixmap *> TxqImageFrame::pixMaps [private]
 

The pixmap maps.

Definition at line 192 of file TxqImageFrame.h.

QPixmap * TxqImageFrame::pixmap [private]
 

The private pixmap.

Definition at line 187 of file TxqImageFrame.h.

TxqLog * TxqImageFrame::txcerr [private]
 

The error output logger.

Definition at line 222 of file TxqImageFrame.h.

TxqLog * TxqImageFrame::txcout [private]
 

The output logger.

Definition at line 217 of file TxqImageFrame.h.

int TxqImageFrame::windowIndex [private]
 

The window index.

Definition at line 202 of file TxqImageFrame.h.


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