vcl/headless/svpinst.cxx | 28 +++++++++++++++++++++++----- vcl/inc/headless/svpinst.hxx | 2 ++ 2 files changed, 25 insertions(+), 5 deletions(-)
New commits: commit e8be3ec4d27d11e9583f39fa06e6ad785bea102c Author: Michael Meeks <michael.me...@collabora.com> AuthorDate: Mon Aug 17 19:57:58 2020 +0100 Commit: Michael Meeks <michael.me...@collabora.com> CommitDate: Wed Aug 19 14:23:38 2020 +0200 headless: don't allow the system to set subpixel rendering eg. Change-Id: Id62c03938c88d70dabda6111b8a7cca3b175e31f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100875 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoff...@gmail.com> Reviewed-by: Miklos Vajna <vmik...@collabora.com> (cherry picked from commit 985922fe1a5dfd9ce02f7d24c4083d9d69544951) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100805 Tested-by: Jenkins Reviewed-by: Michael Meeks <michael.me...@collabora.com> diff --git a/vcl/headless/svpinst.cxx b/vcl/headless/svpinst.cxx index 0e16d832659d..4893b8ddd44b 100644 --- a/vcl/headless/svpinst.cxx +++ b/vcl/headless/svpinst.cxx @@ -44,11 +44,12 @@ #include <headless/svpdummies.hxx> #include <headless/svpvd.hxx> #ifdef IOS -#include <quartz/salbmp.h> -#include <quartz/salgdi.h> -#include <quartz/salvd.h> +# include <quartz/salbmp.h> +# include <quartz/salgdi.h> +# include <quartz/salvd.h> #else -#include <headless/svpgdi.hxx> +# include <cairo.h> +# include <headless/svpgdi.hxx> #endif #include <headless/svpbmp.hxx> @@ -267,6 +268,24 @@ cairo_surface_t* get_underlying_cairo_surface(const VirtualDevice& rDevice) return static_cast<SvpSalVirtualDevice*>(rDevice.mpVirDev.get())->GetSurface(); } +const cairo_font_options_t* SvpSalInstance::GetCairoFontOptions() +{ + static cairo_font_options_t *gOptions = nullptr; + if (!gOptions) + { + gOptions = cairo_font_options_create(); + cairo_font_options_set_antialias(gOptions, CAIRO_ANTIALIAS_GRAY); + } + return gOptions; +} + +#else // IOS + +const cairo_font_options_t* SvpSalInstance::GetCairoFontOptions() +{ + return nullptr; +} + #endif SalTimer* SvpSalInstance::CreateSalTimer() @@ -610,7 +629,6 @@ OpenGLContext* SvpSalInstance::CreateOpenGLContext() return nullptr; } - #endif SvpSalTimer::~SvpSalTimer() diff --git a/vcl/inc/headless/svpinst.hxx b/vcl/inc/headless/svpinst.hxx index ef20f0cab1b1..ae1290729b4c 100644 --- a/vcl/inc/headless/svpinst.hxx +++ b/vcl/inc/headless/svpinst.hxx @@ -176,6 +176,8 @@ public: virtual void AddToRecentDocumentList(const OUString& rFileUrl, const OUString& rMimeType, const OUString& rDocumentService) override; virtual std::unique_ptr<GenPspGraphics> CreatePrintGraphics() override; + + virtual const cairo_font_options_t* GetCairoFontOptions() override; }; inline void SvpSalInstance::registerFrame( SalFrame* pFrame ) _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits