From ecf352701411fe178b51841b5714e27bef500206 Mon Sep 17 00:00:00 2001 From: Khaled Hosny Date: Wed, 19 Jul 2023 08:19:06 +0300 Subject: vcl: Use GetTextArray() when drawing mnemonics MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Instead of using a different function to get the character width, use the same function used for getting the character widths elsewhere. Change-Id: I21428f34bb0f3a60fa17f5e8ecc3420545356337 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154609 Tested-by: Jenkins Reviewed-by: خالد حسني --- include/drawinglayer/primitive2d/textlayoutdevice.hxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'include/drawinglayer') diff --git a/include/drawinglayer/primitive2d/textlayoutdevice.hxx b/include/drawinglayer/primitive2d/textlayoutdevice.hxx index 6348de0ddd25..dfb5ba6c5c37 100644 --- a/include/drawinglayer/primitive2d/textlayoutdevice.hxx +++ b/include/drawinglayer/primitive2d/textlayoutdevice.hxx @@ -96,8 +96,8 @@ public: void addTextRectActions(const tools::Rectangle& rRectangle, const OUString& rText, DrawTextFlags nStyle, GDIMetaFile& rGDIMetaFile) const; - ::std::vector getTextArray(const OUString& rText, sal_uInt32 nIndex, - sal_uInt32 nLength) const; + ::std::vector getTextArray(const OUString& rText, sal_uInt32 nIndex, sal_uInt32 nLength, + bool bCaret = false) const; ::std::vector getCaretPositions(const OUString& rText, sal_uInt32 nIndex, sal_uInt32 nLength) const; -- cgit