aboutsummaryrefslogtreecommitdiff
path: root/engines/sword25/gfx/text.cpp
diff options
context:
space:
mode:
authorEugene Sandulenko2010-09-02 11:54:44 +0000
committerEugene Sandulenko2010-10-12 23:26:48 +0000
commit0cdb2ded85d17150cb108a5d63dd8957c29af2a5 (patch)
tree8d3d48b7ad1c0fd1888b90a8ad2e8b86de0393b5 /engines/sword25/gfx/text.cpp
parent56878b0e62d65aae1b0eba76a2ca2553fbaf1288 (diff)
downloadscummvm-rg350-0cdb2ded85d17150cb108a5d63dd8957c29af2a5.tar.gz
scummvm-rg350-0cdb2ded85d17150cb108a5d63dd8957c29af2a5.tar.bz2
scummvm-rg350-0cdb2ded85d17150cb108a5d63dd8957c29af2a5.zip
SWORD25: unsigned char -> byte
svn-id: r53308
Diffstat (limited to 'engines/sword25/gfx/text.cpp')
-rw-r--r--engines/sword25/gfx/text.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/engines/sword25/gfx/text.cpp b/engines/sword25/gfx/text.cpp
index bb24cba25b..dfbf723910 100644
--- a/engines/sword25/gfx/text.cpp
+++ b/engines/sword25/gfx/text.cpp
@@ -183,7 +183,7 @@ bool Text::DoRender() {
int CurX = m_AbsoluteX + (*Iter).BBox.left;
int CurY = m_AbsoluteY + (*Iter).BBox.top;
for (unsigned int i = 0; i < (*Iter).Text.size(); ++i) {
- Common::Rect CurRect = FontPtr->GetCharacterRect((unsigned char)(*Iter).Text[i]);
+ Common::Rect CurRect = FontPtr->GetCharacterRect((byte)(*Iter).Text[i]);
Common::Rect RenderRect(CurX, CurY, CurX + CurRect.width(), CurY + CurRect.height());
int RenderX = CurX + (RenderRect.left - RenderRect.left);
@@ -258,9 +258,9 @@ void Text::UpdateFormat() {
TempLineWidth = 0;
LastSpace = 0;
for (j = i; j < m_Text.size(); ++j) {
- if ((unsigned char)m_Text[j] == ' ') LastSpace = j;
+ if ((byte)m_Text[j] == ' ') LastSpace = j;
- const Common::Rect &CurCharRect = FontPtr->GetCharacterRect((unsigned char)m_Text[j]);
+ const Common::Rect &CurCharRect = FontPtr->GetCharacterRect((byte)m_Text[j]);
TempLineWidth += CurCharRect.width();
TempLineWidth += FontPtr->GetGapWidth();
@@ -275,7 +275,7 @@ void Text::UpdateFormat() {
for (j = i; j < LastSpace; ++j) {
m_Lines[CurLine].Text += m_Text[j];
- const Common::Rect &CurCharRect = FontPtr->GetCharacterRect((unsigned char)m_Text[j]);
+ const Common::Rect &CurCharRect = FontPtr->GetCharacterRect((byte)m_Text[j]);
CurLineWidth += CurCharRect.width();
CurLineWidth += FontPtr->GetGapWidth();
if ((unsigned int) CurCharRect.height() > CurLineHeight) CurLineHeight = CurCharRect.height();
@@ -322,7 +322,7 @@ void Text::UpdateMetrics(FontResource &FontResource) {
m_Height = 0;
for (unsigned int i = 0; i < m_Text.size(); ++i) {
- const Common::Rect &CurRect = FontResource.GetCharacterRect((unsigned char)m_Text[i]);
+ const Common::Rect &CurRect = FontResource.GetCharacterRect((byte)m_Text[i]);
m_Width += CurRect.width();
if (i != m_Text.size() - 1) m_Width += FontResource.GetGapWidth();
if (m_Height < CurRect.height()) m_Height = CurRect.height();