diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2019-12-05 09:55:56 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2019-12-05 13:31:39 +0100 |
commit | 55e596956e56b175ab17b682e7c8ac7daeb9289a (patch) | |
tree | 3691e2f43d50019b5e0f0e0145714afb13bcc685 /vcl/win/gdi/winlayout.cxx | |
parent | 6a10149c5fef13721e3f83727a828556f8e1ec9a (diff) |
loplugin:external (clang-cl)
...plus loplugin:consttobool and loplugin:fakebool fallout
Change-Id: Ie3d8121815c080b13bea6d9deca1eb138ca56138
Reviewed-on: https://gerrit.libreoffice.org/84515
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'vcl/win/gdi/winlayout.cxx')
-rw-r--r-- | vcl/win/gdi/winlayout.cxx | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/vcl/win/gdi/winlayout.cxx b/vcl/win/gdi/winlayout.cxx index 7b8f5df30180..935aeb84d2a4 100644 --- a/vcl/win/gdi/winlayout.cxx +++ b/vcl/win/gdi/winlayout.cxx @@ -345,6 +345,8 @@ float WinFontInstance::getHScale() const return nWidth / nHeight; } +namespace { + struct BlobReference { hb_blob_t* mpBlob; @@ -359,7 +361,13 @@ struct BlobReference } ~BlobReference() { hb_blob_destroy(mpBlob); } }; + +} + using BlobCacheKey = std::pair<rtl::Reference<PhysicalFontFace>, hb_tag_t>; + +namespace { + struct BlobCacheKeyHash { std::size_t operator()(BlobCacheKey const& rKey) const @@ -371,6 +379,8 @@ struct BlobCacheKeyHash } }; +} + static hb_blob_t* getFontTable(hb_face_t* /*face*/, hb_tag_t nTableTag, void* pUserData) { static o3tl::lru_map<BlobCacheKey, BlobReference, BlobCacheKeyHash> gCache(50); |