From: Ketmar Dark Date: Mon, 28 Aug 2017 11:21:06 +0000 (+0300) Subject: Holmes UI window title fix X-Git-Url: http://deadsoftware.ru/gitweb?a=commitdiff_plain;h=b7279c74ac3d4b1e272d1b6f8d3263ec83f83467;p=d2df-sdl.git Holmes UI window title fix --- diff --git a/src/game/g_holmes.pas b/src/game/g_holmes.pas index 598e0ee..f97952b 100644 --- a/src/game/g_holmes.pas +++ b/src/game/g_holmes.pas @@ -297,7 +297,7 @@ begin llb.appendItem('acid2', @g_rlayer_acid2); llb.appendItem('water', @g_rlayer_water); llb.appendItem('foreground', @g_rlayer_fore); - winLayers := THTopWindow.Create('visible', 10, 10); + winLayers := THTopWindow.Create('layers', 10, 10); winLayers.escClose := true; winLayers.appendChild(llb); winLayers.closeCB := winLayersClosed; diff --git a/src/game/g_holmes_ui.inc b/src/game/g_holmes_ui.inc index f9cbf3c..a6daf4f 100644 --- a/src/game/g_holmes_ui.inc +++ b/src/game/g_holmes_ui.inc @@ -885,7 +885,7 @@ begin if (Length(mTitle) > 0) then begin setScissor(mFrameWidth+3*8, 0, mWidth-mFrameWidth*2-3*8, 8); - tx := mX+(mWidth-Length(mTitle)*8) div 2; + tx := (mX+3*8)+((mWidth-3*8)-Length(mTitle)*8) div 2; fillRect(tx-3, mY, Length(mTitle)*8+3+2, 8, 0, 0, 128); drawText8(tx, mY, mTitle, r, g, b); end;