diff options
author | Miklos Vajna <vmiklos@collabora.co.uk> | 2018-09-06 14:55:13 +0200 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2018-09-06 16:18:47 +0200 |
commit | bcb9be395cd7e382777b041fc90869883f726850 (patch) | |
tree | d47b73dfed123ff067fd56735d836533270aeb52 /include | |
parent | e75c8384c4663b0603a30f66d0d8e390d03a3bf6 (diff) |
svtools: less text layout calls in Ruler
Number of GenericSalLayout::LayoutText() calls during Writer startup: 2603 ->
1616 (18 -> 1 layouts / included number).
Change-Id: I9a1a1131707bb6bc31683bbf609319f4bc22de92
Reviewed-on: https://gerrit.libreoffice.org/60087
Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
Tested-by: Jenkins
Diffstat (limited to 'include')
-rw-r--r-- | include/svtools/ruler.hxx | 3 | ||||
-rw-r--r-- | include/vcl/outdev.hxx | 3 |
2 files changed, 5 insertions, 1 deletions
diff --git a/include/svtools/ruler.hxx b/include/svtools/ruler.hxx index bcf4bc27acb3..c89550e3f6a2 100644 --- a/include/svtools/ruler.hxx +++ b/include/svtools/ruler.hxx @@ -28,6 +28,7 @@ #include <vcl/window.hxx> #include <vcl/virdev.hxx> #include <vcl/field.hxx> +#include <vcl/vcllayout.hxx> #include <svtools/accessibleruler.hxx> @@ -661,6 +662,8 @@ private: rtl::Reference<SvtRulerAccessible> mxAccContext; + std::map<OUString, SalLayoutGlyphs> maTextGlyphs; + SVT_DLLPRIVATE void ImplVDrawLine(vcl::RenderContext& rRenderContext, long nX1, long nY1, long nX2, long nY2 ); SVT_DLLPRIVATE void ImplVDrawRect(vcl::RenderContext& rRenderContext, long nX1, long nY1, long nX2, long nY2 ); SVT_DLLPRIVATE void ImplVDrawText(vcl::RenderContext& rRenderContext, long nX, long nY, const OUString& rText, diff --git a/include/vcl/outdev.hxx b/include/vcl/outdev.hxx index ba15a974f78d..1aa842b46cd5 100644 --- a/include/vcl/outdev.hxx +++ b/include/vcl/outdev.hxx @@ -1071,7 +1071,8 @@ public: */ bool GetTextBoundRect( tools::Rectangle& rRect, const OUString& rStr, sal_Int32 nBase = 0, sal_Int32 nIndex = 0, sal_Int32 nLen = -1, - sal_uLong nLayoutWidth = 0, const long* pDXArray = nullptr ) const; + sal_uLong nLayoutWidth = 0, const long* pDXArray = nullptr, + const SalLayoutGlyphs* pGlyphs = nullptr ) const; tools::Rectangle ImplGetTextBoundRect( const SalLayout& ); |