diff --git a/src/common/animatecmn.cpp b/src/common/animatecmn.cpp index 9a80ce3add..282fc2e9da 100644 --- a/src/common/animatecmn.cpp +++ b/src/common/animatecmn.cpp @@ -173,7 +173,7 @@ void wxAnimationCtrlBase::UpdateStaticImage() m_bmpStaticReal.GetLogicalHeight() != sz.GetHeight()) { // need to (re)create m_bmpStaticReal - if (!m_bmpStaticReal.CreateWithDIPSize(sz, + if (!m_bmpStaticReal.CreateWithLogicalSize(sz, bmpCurrent.GetScaleFactor(), bmpCurrent.GetDepth())) { diff --git a/src/common/dcbufcmn.cpp b/src/common/dcbufcmn.cpp index db0e001fba..ba31002c1d 100644 --- a/src/common/dcbufcmn.cpp +++ b/src/common/dcbufcmn.cpp @@ -84,7 +84,7 @@ private: // we must always return a valid bitmap but creating a bitmap of // size 0 would fail, so create a 1*1 bitmap in this case - buffer->CreateWithDIPSize(wxMax(w, 1), wxMax(h, 1), scale); + buffer->CreateWithLogicalSize(wxMax(w, 1), wxMax(h, 1), scale); return buffer; } diff --git a/src/generic/wizard.cpp b/src/generic/wizard.cpp index bb0978936b..a346e0be14 100644 --- a/src/generic/wizard.cpp +++ b/src/generic/wizard.cpp @@ -999,7 +999,7 @@ bool wxWizard::ResizeBitmap(wxBitmap& bmp) if (!m_statbmp->GetBitmap().IsOk() || m_statbmp->GetBitmap().GetLogicalHeight() != bitmapHeight) { wxBitmap bitmap; - bitmap.CreateWithDIPSize(bitmapWidth, bitmapHeight, bmp.GetScaleFactor(), bmp.GetDepth()); + bitmap.CreateWithLogicalSize(bitmapWidth, bitmapHeight, bmp.GetScaleFactor(), bmp.GetDepth()); { wxMemoryDC dc; dc.SelectObject(bitmap); diff --git a/src/msw/overlay.cpp b/src/msw/overlay.cpp index 030df35636..7df05aca45 100644 --- a/src/msw/overlay.cpp +++ b/src/msw/overlay.cpp @@ -103,7 +103,7 @@ void wxOverlayImpl::Init(wxDC* dc, int , int , int , int ) m_rect.SetSize(m_window->GetClientSize()); m_rect.SetPosition(m_window->GetScreenPosition()); - m_bitmap.CreateWithDIPSize(m_rect.GetSize(), m_window->GetDPIScaleFactor()); + m_bitmap.CreateWithLogicalSize(m_rect.GetSize(), m_window->GetDPIScaleFactor()); m_overlayWindow = wxCreateOverlayWindow(m_rect); } diff --git a/src/propgrid/propgrid.cpp b/src/propgrid/propgrid.cpp index 5f902410b7..7112061fca 100644 --- a/src/propgrid/propgrid.cpp +++ b/src/propgrid/propgrid.cpp @@ -4607,10 +4607,10 @@ void wxPropertyGrid::OnResize( wxSizeEvent& event ) if ( !m_doubleBuffer ) { // Create double buffer bitmap to draw on, if none - int w = wxMax(width, 250); - int h = wxMax(height + dblh, 400); + int w = wxMax(width, FromDIP(250)); + int h = wxMax(height + dblh, FromDIP(400)); m_doubleBuffer = new wxBitmap; - m_doubleBuffer->CreateWithDIPSize( w, h, scaleFactor ); + m_doubleBuffer->CreateWithLogicalSize( w, h, scaleFactor ); } else { @@ -4624,7 +4624,7 @@ void wxPropertyGrid::OnResize( wxSizeEvent& event ) if ( h < (height+dblh) ) h = height + dblh; delete m_doubleBuffer; m_doubleBuffer = new wxBitmap; - m_doubleBuffer->CreateWithDIPSize( w, h, scaleFactor ); + m_doubleBuffer->CreateWithLogicalSize( w, h, scaleFactor ); } } } diff --git a/src/richtext/richtextctrl.cpp b/src/richtext/richtextctrl.cpp index 953a6f2e85..3f87011627 100644 --- a/src/richtext/richtextctrl.cpp +++ b/src/richtext/richtextctrl.cpp @@ -3029,7 +3029,7 @@ bool wxRichTextCtrl::RecreateBuffer(const wxSize& size) #if defined(__WXMSW__) depth = 24; #endif - m_bufferBitmap.CreateWithDIPSize(sz, GetDPIScaleFactor(), depth); + m_bufferBitmap.CreateWithLogicalSize(sz, GetDPIScaleFactor(), depth); } return m_bufferBitmap.IsOk(); }