hedgewars/uChat.pas
changeset 3407 dcc129c4352e
parent 3390 1d4926d10a9e
child 3539 c3d1fccbe0ed
equal deleted inserted replaced
3406:f4bdebced042 3407:dcc129c4352e
    83     color:= colors[str[1]];
    83     color:= colors[str[1]];
    84     delete(str, 1, 1)
    84     delete(str, 1, 1)
    85 end;
    85 end;
    86 
    86 
    87 font:= CheckCJKFont(str, fnt16);
    87 font:= CheckCJKFont(str, fnt16);
       
    88 w:= 0; h:= 0; // avoid compiler hints
    88 TTF_SizeUTF8(Fontz[font].Handle, Str2PChar(str), w, h);
    89 TTF_SizeUTF8(Fontz[font].Handle, Str2PChar(str), w, h);
    89 
    90 
    90 resSurface:= SDL_CreateRGBSurface(0, toPowerOf2(w), toPowerOf2(h), 32, RMask, GMask, BMask, AMask);
    91 resSurface:= SDL_CreateRGBSurface(0, toPowerOf2(w), toPowerOf2(h), 32, RMask, GMask, BMask, AMask);
    91 
    92 
    92 strSurface:= TTF_RenderUTF8_Solid(Fontz[font].Handle, Str2PChar(str), color);
    93 strSurface:= TTF_RenderUTF8_Solid(Fontz[font].Handle, Str2PChar(str), color);