HOG2
|
#include <TextOverlay.h>
Public Member Functions | |
TextOverlay (int maxLines=34) | |
~TextOverlay () | |
void | SetBold (bool useBold) |
void | AddLine (const char *) |
void | DeleteChar () |
void | AppendToLine (const char *) |
const char * | GetLastLine () |
void | Clear () |
void | OpenGLDraw (int window) |
void | Draw (Graphics::Display &display) const |
Private Member Functions | |
int | DrawString (std::string, int start=0) |
Private Attributes | |
std::vector< std::string > | text |
int | index |
int | maxNumLines |
bool | bold |
Definition at line 16 of file TextOverlay.h.
TextOverlay::TextOverlay | ( | int | maxLines = 34 | ) |
Definition at line 16 of file TextOverlay.cpp.
References bold, index, and maxNumLines.
TextOverlay::~TextOverlay | ( | ) |
Definition at line 23 of file TextOverlay.cpp.
References text.
void TextOverlay::AddLine | ( | const char * | line | ) |
Definition at line 37 of file TextOverlay.cpp.
References index, maxNumLines, and text.
void TextOverlay::AppendToLine | ( | const char * | line | ) |
Definition at line 60 of file TextOverlay.cpp.
References text.
void TextOverlay::Clear | ( | ) |
Definition at line 69 of file TextOverlay.cpp.
void TextOverlay::DeleteChar | ( | ) |
Definition at line 54 of file TextOverlay.cpp.
References text.
void TextOverlay::Draw | ( | Graphics::Display & | display | ) | const |
Definition at line 149 of file TextOverlay.cpp.
References Colors::darkgray, Graphics::Display::DrawText(), Graphics::Display::FillRect(), Graphics::Display::FrameRect(), index, maxNumLines, text, Graphics::textAlignLeft, Graphics::textBaselineBottom, and Colors::white.
|
private |
Definition at line 166 of file TextOverlay.cpp.
Referenced by OpenGLDraw().
const char * TextOverlay::GetLastLine | ( | ) |
Definition at line 47 of file TextOverlay.cpp.
References text.
void TextOverlay::OpenGLDraw | ( | int | window | ) |
Definition at line 75 of file TextOverlay.cpp.
References bold, DrawString(), index, maxNumLines, and text.
void TextOverlay::SetBold | ( | bool | useBold | ) |
Definition at line 32 of file TextOverlay.cpp.
References bold.
|
private |
Definition at line 33 of file TextOverlay.h.
Referenced by OpenGLDraw(), SetBold(), and TextOverlay().
|
private |
Definition at line 31 of file TextOverlay.h.
Referenced by AddLine(), Clear(), Draw(), OpenGLDraw(), and TextOverlay().
|
private |
Definition at line 32 of file TextOverlay.h.
Referenced by AddLine(), Draw(), OpenGLDraw(), and TextOverlay().
|
private |
Definition at line 30 of file TextOverlay.h.
Referenced by AddLine(), AppendToLine(), Clear(), DeleteChar(), Draw(), GetLastLine(), OpenGLDraw(), and ~TextOverlay().