Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

EmulationWidget Class Reference

#include </home/clem/local/src/opie/noncore/apps/opie-console/emulation_widget.h>

List of all members.

Public Member Functions

 EmulationWidget (const Profile &config, QWidget *parent=0, const char *name=0)
 ~EmulationWidget ()
virtual void setImage (QArray< Character > const newimg, int columns, int lines)
virtual void reloadConfig (const Profile &config)
virtual void setScroll (int cursor, int slines)
virtual void scroll (int value)
virtual QSize calcSize (int cols, int lins) const

Protected Types

enum  ScrollLocation { SCRNONE, SCRLEFT, SCRIGHT }

Protected Member Functions

virtual void calcGeometry ()
void paintEvent (QPaintEvent *event)
void setColorTable (const ColorEntry table[])
void drawAttrString (QString &string, QPainter &painter, QRect rect, Character attr, bool pm, bool clear)

Protected Attributes

int f_height
int f_width
int f_ascent
int m_blX
int m_blY
int m_brX
int m_bY
int m_bX
QScrollBar * m_scrollbar
ScrollLocation scrollLoc
bool blinking


Detailed Description

EmulationWidget simple implementation of EmulationLayer (doesn't support scrollbar, history, etc, yet)

Definition at line 20 of file emulation_widget.h.


Member Enumeration Documentation

enum EmulationWidget::ScrollLocation [protected]
 

Enumeration values:
SCRNONE 
SCRLEFT 
SCRIGHT 

Definition at line 93 of file emulation_widget.h.


Constructor & Destructor Documentation

EmulationWidget::EmulationWidget const Profile config,
QWidget *  parent = 0,
const char *  name = 0
 

constructor

Parameters:
const Profile& config, the configuration
QWidget* parent, parent widget
const char* name, the name of the widget

Definition at line 25 of file emulation_widget.cpp.

References calcGeometry(), f_ascent, f_height, f_width, m_scrollbar, and reloadConfig().

EmulationWidget::~EmulationWidget  ) 
 

destructor

Definition at line 54 of file emulation_widget.cpp.


Member Function Documentation

void EmulationWidget::calcGeometry  )  [protected, virtual]
 

calculates current image bounds

Definition at line 223 of file emulation_widget.cpp.

References f_height, f_width, height, m_blX, m_brX, m_bY, m_scrollbar, rimX, rimY, SCRIGHT, SCRLEFT, SCRNONE, scrollLoc, and width.

Referenced by EmulationWidget().

QSize EmulationWidget::calcSize int  cols,
int  lins
const [virtual]
 

Definition at line 99 of file emulation_widget.cpp.

References f_height, f_width, height, m_scrollbar, rimX, rimY, SCRNONE, scrollLoc, and width.

void EmulationWidget::drawAttrString QString string,
QPainter &  painter,
QRect  rect,
Character  attr,
bool  pm,
bool  clear
[protected]
 

draws a String

Parameters:
QString& string, string to be drawn
QPainter& painter, painter, that should draw
QRect rect, rect to be drawn into
Character attr, attributes of Characters
bool usePixmap, if to use the background pixmap (currently not supported)
bool clear, if rect should be cleared

Definition at line 255 of file emulation_widget.cpp.

References Character::b, blinking, Character::f, and f_ascent.

Referenced by paintEvent(), and setImage().

void EmulationWidget::paintEvent QPaintEvent *  event  )  [protected]
 

Definition at line 178 of file emulation_widget.cpp.

References drawAttrString(), f, f_height, f_width, l, len, loc, m_blX, m_bY, vt100extended(), Opie::MM::x, and Opie::MM::y.

void EmulationWidget::reloadConfig const Profile config  )  [virtual]
 

reloads configuration

Parameters:
const Profile& config, configuration

Definition at line 48 of file emulation_widget.cpp.

Referenced by EmulationWidget().

void EmulationWidget::scroll int  value  )  [virtual]
 

scrolls (not yet implemented)

Parameters:
int value, scroll by this value

Definition at line 286 of file emulation_widget.cpp.

void EmulationWidget::setColorTable const ColorEntry  table[]  )  [protected]
 

Parameters:
const ColorEntry* table, the new color table

void EmulationWidget::setImage QArray< Character > const   newimg,
int  columns,
int  lines
[virtual]
 

sets the image

Parameters:
QArray<Character> const newimg, the new image
int lines, lines of the new image
int columns, columns of the new image

Definition at line 108 of file emulation_widget.cpp.

References Character::b, drawAttrString(), Character::f, f, f_height, f_width, len, m_blX, m_bY, NULL, Character::r, vt100extended(), Opie::MM::x, and Opie::MM::y.

void EmulationWidget::setScroll int  cursor,
int  slines
[virtual]
 

sets the scrollbar (not yet implemented)

Definition at line 290 of file emulation_widget.cpp.


Member Data Documentation

bool EmulationWidget::blinking [protected]
 

Definition at line 115 of file emulation_widget.h.

Referenced by drawAttrString().

int EmulationWidget::f_ascent [protected]
 

Definition at line 102 of file emulation_widget.h.

Referenced by drawAttrString(), and EmulationWidget().

int EmulationWidget::f_height [protected]
 

Definition at line 100 of file emulation_widget.h.

Referenced by calcGeometry(), calcSize(), EmulationWidget(), paintEvent(), and setImage().

int EmulationWidget::f_width [protected]
 

Definition at line 101 of file emulation_widget.h.

Referenced by calcGeometry(), calcSize(), EmulationWidget(), paintEvent(), and setImage().

int EmulationWidget::m_blX [protected]
 

Definition at line 103 of file emulation_widget.h.

Referenced by calcGeometry(), paintEvent(), and setImage().

int EmulationWidget::m_blY [protected]
 

Definition at line 104 of file emulation_widget.h.

int EmulationWidget::m_brX [protected]
 

Definition at line 105 of file emulation_widget.h.

Referenced by calcGeometry().

int EmulationWidget::m_bX [protected]
 

Definition at line 108 of file emulation_widget.h.

int EmulationWidget::m_bY [protected]
 

Definition at line 107 of file emulation_widget.h.

Referenced by calcGeometry(), paintEvent(), and setImage().

QScrollBar* EmulationWidget::m_scrollbar [protected]
 

Definition at line 109 of file emulation_widget.h.

Referenced by calcGeometry(), calcSize(), and EmulationWidget().

ScrollLocation EmulationWidget::scrollLoc [protected]
 

Definition at line 111 of file emulation_widget.h.

Referenced by calcGeometry(), and calcSize().


The documentation for this class was generated from the following files:
Generated on Sat Nov 5 17:32:02 2005 for OPIE by  doxygen 1.4.2