Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members   Related Pages  

XFuRLESpritePrinter.h

Go to the documentation of this file.
00001 /*! \file 
00002  * X-Forge Util <br>
00003  * Copyright 2000-2003 Fathammer Ltd
00004  * 
00005  * \brief Printer variant that uses RLE-sprites instead of normal ones.
00006  * 
00007  * $Id: XFuRLESpritePrinter.h,v 1.13 2003/08/12 13:33:52 lars Exp $
00008  * $Date: 2003/08/12 13:33:52 $
00009  * $Revision: 1.13 $
00010  */
00011 
00012 #ifndef XFURLESPRITEPRINTER_H_INCLUDED
00013 #define XFURLESPRITEPRINTER_H_INCLUDED
00014 
00015 #include <xfutil/XFuPrinter.h>
00016 
00017 
00018 //! XFuPrinter variant that uses RLE sprites instead of normal ones.
00019 /*! 
00020  * \sa XFuPrinter
00021  */
00022 class XFuRLESpritePrinter : public XFuPrinter
00023 {
00024 public:
00025     
00026     //! Creates XFuRLESpritePrinter from an image file.
00027     static XFuRLESpritePrinter * create(const CHAR *aFname);
00028     //! Creates XFuRLESpritePrinter from an image file.
00029     static XFuRLESpritePrinter * create(const CHAR *aFname, UINT32 aBaseMask, UINT32 aBaseColor);
00030     //! Creates XFuRLESpritePrinter from an image file using a scale.
00031     static XFuRLESpritePrinter * create(const CHAR *aFname, UINT32 aBaseMask, UINT32 aBaseColor,
00032                                         REAL aXScale, REAL aYScale);
00033     //! Prints a character string with the printer's font.
00034     /*! String is printed to a target surface with optional blending and clipping rectangle.
00035      */
00036     virtual void print(XFcGLSurface * aTarget, INT32 aX, INT32 aY, const CHAR *aText,
00037                        INT32 aBlendType = 0, INT32 aBlendValue = 0x7f, XFcRectangle *aClipRect = NULL);
00038     //! Calculates how big an area a string would take if printed.
00039     virtual void stringMetrics(const CHAR *aText, INT32 &aWidth, INT32 &aHeight);
00040     //! Returns the width of a single character.
00041     virtual INT32 getCharWidth(CHAR aChar);
00042     virtual ~XFuRLESpritePrinter();
00043 
00044 protected:
00045     
00046     XFuRLESpritePrinter();
00047     
00048     XFcRLESprite **mLetterSprite;  
00049 };
00050 
00051 
00052 #endif // !XFURLESPRITEPRINTER_H_INCLUDED
00053 

   
X-Forge Documentation
Confidential
Copyright © 2002-2003 Fathammer
   
Documentation generated
with doxygen
by Dimitri van Heesch