From 611694b707eb43e4c0f20b781f6869016a3ba099 Mon Sep 17 00:00:00 2001 From: Khaled Hosny Date: Thu, 17 Aug 2023 17:39:29 +0300 Subject: [PATCH] =?UTF-8?q?vcl:=20Allow=20pushing/popping=20OutputDevice?= =?UTF-8?q?=E2=80=99s=20RTLEnabled=20state?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: Icafdc307c5c9df768f00c3ac0d128936607bf3e6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155794 Tested-by: Jenkins Reviewed-by: خالد حسني --- include/vcl/rendercontext/State.hxx | 4 +++- vcl/source/gdi/mtfxmldump.cxx | 2 ++ vcl/source/outdev/stack.cxx | 6 ++++++ 3 files changed, 11 insertions(+), 1 deletion(-) diff --git a/include/vcl/rendercontext/State.hxx b/include/vcl/rendercontext/State.hxx index a433dbd8fb05..042eb2deca7a 100644 --- a/include/vcl/rendercontext/State.hxx +++ b/include/vcl/rendercontext/State.hxx @@ -53,6 +53,7 @@ enum class PushFlags TEXTLAYOUTMODE = 0x0800, TEXTLANGUAGE = 0x1000, OVERLINECOLOR = 0x2000, + RTLENABLED = 0x4000, ALL = 0xFFFF }; } @@ -66,7 +67,7 @@ template <> struct typed_flags : is_typed_flagsPush(); } @@ -184,6 +187,9 @@ void OutputDevice::Pop() SetRefPoint(); } + if ( rState.mnFlags & vcl::PushFlags::RTLENABLED ) + EnableRTL( rState.mbRTLEnabled ); + maOutDevStateStack.pop_back(); mpMetaFile = pOldMetaFile;