From 846173c976cc7c8576d88a9fd8b1d22b3c6ab153 Mon Sep 17 00:00:00 2001 From: Julian Smart Date: Sun, 6 Apr 2003 16:23:09 +0000 Subject: [PATCH] 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 --- docs/changes.txt | 1 + src/msw/button.cpp | 3 +-- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/changes.txt b/docs/changes.txt index b36de710f7..cad93ad705 100644 --- a/docs/changes.txt +++ b/docs/changes.txt @@ -215,6 +215,7 @@ wxMSW: - use ES_DISABLENOSCROLL to work around the vertical scrollbar bug in wxTE_RICH2 text control - fixes for wxLocale::Init and Borland C++ +- Fix for bug whereby owner-drawn buttons didn't draw multiline labels correctly wxMotif: diff --git a/src/msw/button.cpp b/src/msw/button.cpp index 81c588c5be..2e50a96213 100644 --- a/src/msw/button.cpp +++ b/src/msw/button.cpp @@ -415,8 +415,7 @@ static void DrawButtonText(HDC hdc, COLORREF colOld = SetTextColor(hdc, col); int modeOld = SetBkMode(hdc, TRANSPARENT); - DrawText(hdc, text, text.length(), pRect, - DT_CENTER | DT_VCENTER | DT_SINGLELINE); + ::DrawText(hdc, text, text.length(), pRect, DT_CENTER | DT_VCENTER); SetBkMode(hdc, modeOld); SetTextColor(hdc, colOld);