When drawing wxPG items (with double buffering) use the same layout direction as the window uses.

Memory DC used for double buffering purposes should inherit layout direction from the window DC to ensure that texts are rendered correctly.

This is the backport of r76931.
See #15797.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_3_0_BRANCH@78509 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Artur Wieczorek
2015-02-16 20:50:07 +00:00
parent 63e678d978
commit a3735c8cc1

View File

@@ -1971,6 +1971,9 @@ void wxPropertyGrid::DrawItems( wxDC& dc,
else
{
bufferDC = new wxMemoryDC();
// Use the same layout direction as the window DC uses
// to ensure that the text is rendered correctly.
bufferDC->SetLayoutDirection(dc.GetLayoutDirection());
// If nothing was changed, then just copy from double-buffer
bufferDC->SelectObject( *m_doubleBuffer );