about summary refs log tree commit diff
path: root/src/engine/client/text.cpp
diff options
context:
space:
mode:
authoroy <Tom_Adams@web.de>2010-08-16 02:21:18 +0200
committeroy <Tom_Adams@web.de>2010-08-16 02:21:18 +0200
commitabc84ac0b0ff77b3b30a20252f86332c699e4466 (patch)
tree4ed487066f87aaac06b28ffd749f94126b169cd9 /src/engine/client/text.cpp
parent4c2dcc4f2b5f061a1d75aa2aa0b316c4b86bc1d8 (diff)
downloadzcatch-abc84ac0b0ff77b3b30a20252f86332c699e4466.tar.gz
zcatch-abc84ac0b0ff77b3b30a20252f86332c699e4466.zip
added fixes for compiler errors and warnings by sworddragon
Diffstat (limited to 'src/engine/client/text.cpp')
-rw-r--r--src/engine/client/text.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/engine/client/text.cpp b/src/engine/client/text.cpp
index 672fde60..ef741c12 100644
--- a/src/engine/client/text.cpp
+++ b/src/engine/client/text.cpp
@@ -509,7 +509,7 @@ public:
 		return Cursor.m_X;
 	}
 	
-	virtual float TextLineCount(void *pFontSetV, float Size, const char *pText, int LineWidth)
+	virtual int TextLineCount(void *pFontSetV, float Size, const char *pText, float LineWidth)
 	{
 		CTextCursor Cursor;
 		SetCursor(&Cursor, 0, 0, Size, 0);
@@ -551,14 +551,14 @@ public:
 		
 		FakeToScreenX = (Graphics()->ScreenWidth()/(ScreenX1-ScreenX0));
 		FakeToScreenY = (Graphics()->ScreenHeight()/(ScreenY1-ScreenY0));
-		ActualX = pCursor->m_X * FakeToScreenX;
-		ActualY = pCursor->m_Y * FakeToScreenY;
+		ActualX = (int)(pCursor->m_X * FakeToScreenX);
+		ActualY = (int)(pCursor->m_Y * FakeToScreenY);
 
 		CursorX = ActualX / FakeToScreenX;
 		CursorY = ActualY / FakeToScreenY;
 
 		// same with size
-		ActualSize = Size * FakeToScreenY;
+		ActualSize = (int)(Size * FakeToScreenY);
 		Size = ActualSize / FakeToScreenY;
 
 		// fetch pFont data