From 4d4e95849a0f973f5827e65807bf643da3ac2d57 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Mon, 9 Jul 2018 20:50:22 +0200 Subject: [PATCH] Fix size of wxSearchCtrl in the widgets sample in high DPI Add missing FromDIP(), without it the control was too small. --- samples/widgets/searchctrl.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/samples/widgets/searchctrl.cpp b/samples/widgets/searchctrl.cpp index 623d2b92e3..a4607cafa7 100644 --- a/samples/widgets/searchctrl.cpp +++ b/samples/widgets/searchctrl.cpp @@ -178,7 +178,7 @@ void SearchCtrlWidgetsPage::CreateControl() long style = GetAttrs().m_defaultFlags; m_srchCtrl = new wxSearchCtrl(this, -1, wxEmptyString, wxDefaultPosition, - wxSize(150, -1), style); + FromDIP(wxSize(150, -1)), style); m_srchCtrl->Bind(wxEVT_SET_FOCUS, &SearchCtrlWidgetsPage::OnSetFocus, this); m_srchCtrl->Bind(wxEVT_KILL_FOCUS, &SearchCtrlWidgetsPage::OnKillFocus, this);