changeset 47:5629105aa178

21.01.13(DrawText)
author Ritor1
date Mon, 21 Jan 2013 14:37:14 +0600
parents 9b4f8fe32a6e
children ca142e247b73 5a08b193507f 8af333180755
files GUIFont.cpp
diffstat 1 files changed, 9 insertions(+), 9 deletions(-) [+]
line wrap: on
line diff
--- a/GUIFont.cpp	Mon Jan 21 14:36:40 2013 +0600
+++ b/GUIFont.cpp	Mon Jan 21 14:37:14 2013 +0600
@@ -97,7 +97,7 @@
 void GUIFont::DrawTextLine(unsigned int uDefaultColor, signed int uX, signed int uY, const char *Str, int a6)
 {
   size_t v6; // ebx@1
-  GUIFont *v7; // esi@1
+  GUIFont *pFont; // esi@1
   signed int v8; // edi@3
   unsigned __int8 v9; // cl@4
   int v10; // eax@5
@@ -116,7 +116,7 @@
 
   v6 = 0;
   v21 = uDefaultColor;
-  v7 = this;
+  pFont = this;
   if ( Str )
   {
     v21 = ui_current_text_color;
@@ -126,7 +126,7 @@
       v8 = uX;
       do
       {
-        if ( v7->IsCharValid(v9 = Str[v6]) )
+        if ( pFont->IsCharValid(v9 = Str[v6]) )
         {
           v10 = v9;
           v11 = v9 - 9;
@@ -141,20 +141,20 @@
               if ( v13 != 1 )
               {
                 v14 = 3 * v10 + 9;
-                v15 = *((int *)&v7->cFirstChar + v14);
-                uXa = *((int *)&v7->cFirstChar + v14);
+                v15 = *((int *)&pFont->cFirstChar + v14);
+                uXa = *((int *)&pFont->cFirstChar + v14);
                 if ( v15 )
                 {
                   if ( (signed int)v6 > 0 )
-                    v8 += v7->pMetrics[v10].uLeftSpacing;
+                    v8 += pFont->pMetrics[v10].uLeftSpacing;
                   v16 = v21;
-                  v17 = (unsigned __int8 *)((char *)&v7[1] + v7->field_C20[v10]);
+                  v17 = (unsigned __int8 *)((char *)&pFont[1] + pFont->field_C20[v10]);
                   if ( !v21 )
                     v16 = -1;
-                  pRenderer->DrawText(v8, uY, v17, v15, LOBYTE(v7->uFontHeight), v7->pFontPalettes[0], v16, 0);
+                  pRenderer->DrawText(v8, uY, v17, v15, pFont->uFontHeight, pFont->pFontPalettes[0], v16, 0);
                   v8 += uXa;
                   if ( (signed int)v6 < (signed int)v20 )
-                    v8 += v7->pMetrics[(unsigned __int8)Str[v6]].uRightSpacing;
+                    v8 += pFont->pMetrics[(unsigned __int8)Str[v6]].uRightSpacing;
                 }
               }
             }