change getRenderWidth() default to UTF8

Origin commit data
------------------
Branch: ni/coolstream
Commit: 8b91cda918
Author: vanhofen <vanhofen@gmx.de>
Date: 2014-06-11 (Wed, 11 Jun 2014)

Origin message was:
------------------
- change getRenderWidth() default to UTF8

------------------
No further description and justification available within origin commit message!

------------------
This commit was generated by Migit
This commit is contained in:
vanhofen
2014-06-11 11:48:59 +02:00
parent 68b7a1e86c
commit 108a1c1b93
35 changed files with 127 additions and 128 deletions

View File

@@ -186,13 +186,13 @@ void EpgPlus::TimeLine::paint (time_t startTime, int pduration)
std::string timeStr = EpgPlus::getTimeString (tickTime, "%H");
int textWidth = this->fontTime->getRenderWidth (timeStr, true);
int textWidth = this->fontTime->getRenderWidth (timeStr);
this->fontTime->RenderString (xPos - textWidth - 4, this->y + this->fontTime->getHeight()
, textWidth, timeStr, toggleColor ? COL_MENUCONTENT_P1 : COL_MENUCONTENT_P2, 0, true); // UTF-8
timeStr = EpgPlus::getTimeString (tickTime, "%M");
textWidth = this->fontTime->getRenderWidth (timeStr, true);
textWidth = this->fontTime->getRenderWidth (timeStr);
this->fontTime->RenderString (xPos + 4, this->y + this->fontTime->getHeight()
, textWidth, timeStr, toggleColor ? COL_MENUCONTENT_P1 : COL_MENUCONTENT_P2, 0, true); // UTF-8
@@ -223,14 +223,14 @@ void EpgPlus::TimeLine::paintMark (time_t startTime, int pduration, int px, int
// display start time before mark
std::string timeStr = EpgPlus::getTimeString (startTime, "%H:%M");
int textWidth = this->fontTime->getRenderWidth (timeStr, true);
int textWidth = this->fontTime->getRenderWidth (timeStr);
this->fontTime->RenderString (px - textWidth, this->y + this->fontTime->getHeight() + this->fontTime->getHeight()
, textWidth, timeStr, COL_MENUCONTENT_TEXT, 0, true); // UTF-8
// display end time after mark
timeStr = EpgPlus::getTimeString (startTime + pduration, "%H:%M");
textWidth = fontTime->getRenderWidth (timeStr, true);
textWidth = fontTime->getRenderWidth (timeStr);
if (px + pwidth + textWidth < this->x + this->width) {
this->fontTime->RenderString (px + pwidth, this->y + this->fontTime->getHeight() + this->fontTime->getHeight()