Image Class Reference

#include <image.h>

List of all members.

Public Member Functions

 Image (int w, int h)
 ~Image ()
void setPixel (int x, int y, uchar val)
uchar getPixel (int x, int y) const
void writeChar (int x, int y, char c, uchar fg)
void writeString (int x, int y, const char *s, uchar fg)
void drawHorzLine (int y, int xs, int xe, uchar colIndex, uint mask)
void drawHorzArrow (int y, int xs, int xe, uchar colIndex, uint mask)
void drawVertLine (int x, int ys, int ye, uchar colIndex, uint mask)
void drawVertArrow (int x, int ys, int ye, uchar colIndex, uint mask)
void drawRect (int x, int y, int width, int height, uchar colIndex, uint mask)
void fillRect (int x, int y, int width, int height, uchar colIndex, uint mask)
bool save (const char *fileName, int mode=0)
uint getWidth () const
uint getHeight () const
uchar * getData () const

Static Public Member Functions

static uint stringLength (const char *s)

Friends

uint stringLength (const char *s)


Detailed Description

Definition at line 23 of file image.h.


Constructor & Destructor Documentation

Image::Image ( int  w,
int  h 
)

Definition at line 176 of file image.cpp.

Image::~Image (  ) 

Definition at line 184 of file image.cpp.


Member Function Documentation

void Image::setPixel ( int  x,
int  y,
uchar  val 
)

Definition at line 189 of file image.cpp.

Referenced by drawHorzLine(), drawVertLine(), fillRect(), FormulaList::generateBitmaps(), and writeChar().

uchar Image::getPixel ( int  x,
int  y 
) const

Definition at line 195 of file image.cpp.

Referenced by writeChar().

void Image::writeChar ( int  x,
int  y,
char  c,
uchar  fg 
)

Definition at line 203 of file image.cpp.

References charHeight, charPos, charSetWidth, charWidth, fontRaw, getPixel(), and setPixel().

Referenced by writeString().

void Image::writeString ( int  x,
int  y,
const char *  s,
uchar  fg 
)

Definition at line 240 of file image.cpp.

References charWidth, and writeChar().

void Image::drawHorzLine ( int  y,
int  xs,
int  xe,
uchar  colIndex,
uint  mask 
)

Definition at line 264 of file image.cpp.

References setPixel().

Referenced by TreeDiagram::drawConnectors(), drawHorzArrow(), drawRect(), and drawVertArrow().

void Image::drawHorzArrow ( int  y,
int  xs,
int  xe,
uchar  colIndex,
uint  mask 
)

Definition at line 274 of file image.cpp.

References drawHorzLine(), and drawVertLine().

Referenced by TreeDiagram::drawConnectors().

void Image::drawVertLine ( int  x,
int  ys,
int  ye,
uchar  colIndex,
uint  mask 
)

Definition at line 285 of file image.cpp.

References setPixel().

Referenced by TreeDiagram::drawConnectors(), drawHorzArrow(), drawRect(), and drawVertArrow().

void Image::drawVertArrow ( int  x,
int  ys,
int  ye,
uchar  colIndex,
uint  mask 
)

Definition at line 294 of file image.cpp.

References drawHorzLine(), and drawVertLine().

Referenced by TreeDiagram::drawConnectors().

void Image::drawRect ( int  x,
int  y,
int  width,
int  height,
uchar  colIndex,
uint  mask 
)

Definition at line 305 of file image.cpp.

References drawHorzLine(), and drawVertLine().

void Image::fillRect ( int  x,
int  y,
int  width,
int  height,
uchar  colIndex,
uint  mask 
)

Definition at line 313 of file image.cpp.

References setPixel().

bool Image::save ( const char *  fileName,
int  mode = 0 
)

Definition at line 322 of file image.cpp.

References PngEncoder::write().

Referenced by FormulaList::generateBitmaps().

uint Image::getWidth (  )  const [inline]

Definition at line 41 of file image.h.

Referenced by FormulaList::generateBitmaps().

uint Image::getHeight (  )  const [inline]

Definition at line 42 of file image.h.

Referenced by TreeDiagram::drawBoxes(), TreeDiagram::drawConnectors(), and FormulaList::generateBitmaps().

uchar* Image::getData (  )  const [inline]

Definition at line 43 of file image.h.

static uint Image::stringLength ( const char *  s  )  [static]


Friends And Related Function Documentation

uint Image::stringLength ( const char *  s  )  [friend]

Definition at line 253 of file image.cpp.

Referenced by TreeDiagram::computeExtremes().


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



Generated on Mon Mar 31 10:59:00 2008 by  doxygen 1.5.1