Added Text as a subclass of Drawable. Fixed syntax error in font.cpp
svn-id: r41981
This commit is contained in:
parent
49e1a07f27
commit
78d5b96f51
3 changed files with 40 additions and 3 deletions
|
@ -27,6 +27,7 @@
|
|||
#define DRACI_SPRITE_H
|
||||
|
||||
#include "draci/surface.h"
|
||||
#include "draci/font.h"
|
||||
|
||||
namespace Draci {
|
||||
|
||||
|
@ -70,7 +71,21 @@ public:
|
|||
byte *_data; //!< Pointer to a buffer containing raw sprite data (row-wise)
|
||||
};
|
||||
|
||||
class Text : public Drawable {
|
||||
|
||||
public:
|
||||
Text(const Common::String &str, Font *font, byte fontColour, uint spacing = 0);
|
||||
~Text();
|
||||
|
||||
void draw(Surface *surface) const;
|
||||
|
||||
byte *_text;
|
||||
uint _length;
|
||||
uint8 _colour;
|
||||
uint _spacing;
|
||||
Font *_font;
|
||||
};
|
||||
|
||||
} // End of namespace Draci
|
||||
|
||||
#endif // DRACI_SPRITE_H
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue