summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--glcdgraphics/bitmap.c2
-rw-r--r--glcdgraphics/font.c8
2 files changed, 4 insertions, 6 deletions
diff --git a/glcdgraphics/bitmap.c b/glcdgraphics/bitmap.c
index 9080ec4..46bcdb1 100644
--- a/glcdgraphics/bitmap.c
+++ b/glcdgraphics/bitmap.c
@@ -596,8 +596,6 @@ int cBitmap::DrawText(int x, int y, int xmax, const std::string & text, const cF
start = text.length();
else
{
- unsigned int tmp = start;
- cFont::EncodedCharAdjustCounter(font->IsUTF8(), text, c, tmp);
while (skipPixels > font->SpaceBetween() + font->Width(text.substr(start), 1 /*text[start]*/))
{
cFont::EncodedCharAdjustCounter(font->IsUTF8(), text, c, start);
diff --git a/glcdgraphics/font.c b/glcdgraphics/font.c
index 8b80186..b670262 100644
--- a/glcdgraphics/font.c
+++ b/glcdgraphics/font.c
@@ -397,7 +397,7 @@ void cFont::EncodedCharAdjustCounter(const bool isutf8, const std::string & str,
if ( (c1 & 0xC0) == 0x80 ) {
c = ( (c0 & 0x1F) << 6 ) | ( (c1 & 0x3F) );
} else {
- syslog(LOG_INFO, "GraphLCD: illegal 2-byte UTF-8 sequence found: 0x%02x 0x%02x\n", c0, c1);
+ //syslog(LOG_INFO, "GraphLCD: illegal 2-byte UTF-8 sequence found: 0x%02x 0x%02x\n", c0, c1);
c = UTF8_ERRCODE;
}
i += 1;
@@ -406,7 +406,7 @@ void cFont::EncodedCharAdjustCounter(const bool isutf8, const std::string & str,
if ( ((c1 & 0xC0) == 0x80) && ((c2 & 0xC0) == 0x80) ) {
c = ( (c0 & 0x0F) << 12 ) | ( (c1 & 0x3F) << 6 ) | ( c2 & 0x3F );
} else {
- syslog(LOG_INFO, "GraphLCD: illegal 3-byte UTF-8 sequence found: 0x%02x 0x%02x 0x%02x\n", c0, c1, c2);
+ //syslog(LOG_INFO, "GraphLCD: illegal 3-byte UTF-8 sequence found: 0x%02x 0x%02x 0x%02x\n", c0, c1, c2);
c = UTF8_ERRCODE;
}
i += 2;
@@ -415,13 +415,13 @@ void cFont::EncodedCharAdjustCounter(const bool isutf8, const std::string & str,
if ( ((c1 & 0xC0) == 0x80) && ((c2 & 0xC0) == 0x80) && ((c3 & 0xC0) == 0x80) ) {
c = ( (c0 & 0x07) << 18 ) | ( (c1 & 0x3F) << 12 ) | ( (c2 & 0x3F) << 6 ) | (c3 & 0x3F);
} else {
- syslog(LOG_INFO, "GraphLCD: illegal 4-byte UTF-8 sequence found: 0x%02x 0x%02x 0x%02x 0x%02x\n", c0, c1, c2, c3);
+ //syslog(LOG_INFO, "GraphLCD: illegal 4-byte UTF-8 sequence found: 0x%02x 0x%02x 0x%02x 0x%02x\n", c0, c1, c2, c3);
c = UTF8_ERRCODE;
}
i += 3;
} else {
// 1xxxxxxx is invalid!
- syslog(LOG_INFO, "GraphLCD: illegal 1-byte UTF-8 char found: 0x%02x\n", c0);
+ //syslog(LOG_INFO, "GraphLCD: illegal 1-byte UTF-8 char found: 0x%02x\n", c0);
c = UTF8_ERRCODE;
}
} else {