- Translation updates
- JGE: DrawString now allows std::string objects
This commit is contained in:
wagic.the.homebrew@gmail.com
2009-11-01 02:52:41 +00:00
parent efbfc0a1b9
commit 5b92639cca
31 changed files with 7705 additions and 7399 deletions

View File

@@ -16,7 +16,7 @@
#define MAX_CHAR 256
#include "JRenderer.h"
#include <string>
//////////////////////////////////////////////////////////////////////////
/// Bitmap font class for LMNOpc's Bitmap Font Builder:
@@ -54,6 +54,7 @@ public:
///
//////////////////////////////////////////////////////////////////////////
void DrawString(const char *string, float x, float y, int align=JGETEXT_LEFT, float leftOffset = 0, float width = 0);
void DrawString(std::string s, float x, float y, int align=JGETEXT_LEFT, float leftOffset = 0, float width = 0);
//////////////////////////////////////////////////////////////////////////
/// Rendering text to screen with syntax similar to printf of C/C++.

Binary file not shown.

View File

@@ -99,6 +99,11 @@ JLBFont::~JLBFont()
}
void JLBFont::DrawString(std::string s, float x, float y, int align, float leftOffset, float displayWidth)
{
return DrawString(s.c_str(), x, y, align, leftOffset, displayWidth);
}
void JLBFont::DrawString(const char *string, float x, float y, int align, float leftOffset, float displayWidth)
{
char *p = (char*)string;