Fix broken rendering of wxGTK wxDataViewCtrl renderers

Fix wrong checks for RTL mode added in 07c1da23e2 (wxGTK: Fix
wxDataViewCustomRenderer in RTL layout, 2025-10-20).

See #25426.

Closes #25944.
This commit is contained in:
Vadim Zeitlin
2025-11-01 17:38:50 +01:00
parent 556943e74f
commit 2d5f490ef3
+3 -2
View File
@@ -1657,7 +1657,7 @@ gtk_wx_cell_renderer_render (GtkCellRenderer *renderer,
wxDataViewCustomRenderer::GTKRenderParams renderParams;
wxRect rect(wxRectFromGDKRect(cell_area));
#ifdef __WXGTK3__
const bool isRTL = wxWindow::GTKGetLayout(widget);
const bool isRTL = wxWindow::GTKGetLayout(widget) == wxLayout_RightToLeft;
if (isRTL)
{
cairo_scale(cr, -1, 1);
@@ -2834,7 +2834,8 @@ void wxDataViewCustomRenderer::RenderText( const wxString &text,
cell_area.width -= xoffset;
#ifdef __WXGTK3__
const bool isRTL = wxWindow::GTKGetLayout(m_renderParams->widget);
const bool isRTL =
wxWindow::GTKGetLayout(m_renderParams->widget) == wxLayout_RightToLeft;
if (isRTL)
{
cairo_save(m_renderParams->cr);