Fix for bug whereby owner-drawn buttons didn't draw multiline labels correctly
Backported from head git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_4_BRANCH@20025 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -215,6 +215,7 @@ wxMSW:
|
|||||||
- use ES_DISABLENOSCROLL to work around the vertical scrollbar bug in
|
- use ES_DISABLENOSCROLL to work around the vertical scrollbar bug in
|
||||||
wxTE_RICH2 text control
|
wxTE_RICH2 text control
|
||||||
- fixes for wxLocale::Init and Borland C++
|
- fixes for wxLocale::Init and Borland C++
|
||||||
|
- Fix for bug whereby owner-drawn buttons didn't draw multiline labels correctly
|
||||||
|
|
||||||
wxMotif:
|
wxMotif:
|
||||||
|
|
||||||
|
@@ -415,8 +415,7 @@ static void DrawButtonText(HDC hdc,
|
|||||||
COLORREF colOld = SetTextColor(hdc, col);
|
COLORREF colOld = SetTextColor(hdc, col);
|
||||||
int modeOld = SetBkMode(hdc, TRANSPARENT);
|
int modeOld = SetBkMode(hdc, TRANSPARENT);
|
||||||
|
|
||||||
DrawText(hdc, text, text.length(), pRect,
|
::DrawText(hdc, text, text.length(), pRect, DT_CENTER | DT_VCENTER);
|
||||||
DT_CENTER | DT_VCENTER | DT_SINGLELINE);
|
|
||||||
|
|
||||||
SetBkMode(hdc, modeOld);
|
SetBkMode(hdc, modeOld);
|
||||||
SetTextColor(hdc, colOld);
|
SetTextColor(hdc, colOld);
|
||||||
|
Reference in New Issue
Block a user