diff options
Diffstat (limited to 'vcl/headless/svpgdi.cxx')
-rw-r--r-- | vcl/headless/svpgdi.cxx | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/vcl/headless/svpgdi.cxx b/vcl/headless/svpgdi.cxx index b1f622904b5f..e42eb3ed3eaa 100644 --- a/vcl/headless/svpgdi.cxx +++ b/vcl/headless/svpgdi.cxx @@ -1056,6 +1056,8 @@ public: cairo_path_t* getCairoPath() { return mpCairoPath; } bool getNoJoin() const { return mbNoJoin; } bool getAntiAliasB2DDraw() const { return mbAntiAliasB2DDraw; } + + virtual sal_Int64 estimateUsageInBytes() const override; }; SystemDependentData_CairoPath::SystemDependentData_CairoPath( @@ -1079,6 +1081,22 @@ SystemDependentData_CairoPath::~SystemDependentData_CairoPath() } } +sal_Int64 SystemDependentData_CairoPath::estimateUsageInBytes() const +{ + sal_Int64 nRetval(0); + + if(nullptr != mpCairoPath) + { + // per node + // - num_data incarnations of + // - sizeof(cairo_path_data_t) which is a union of defines and point data + // thus may 2 x sizeof(double) + nRetval = mpCairoPath->num_data * sizeof(cairo_path_data_t); + } + + return nRetval; +} + bool SvpSalGraphics::drawPolyLine( const basegfx::B2DHomMatrix& rObjectToDevice, const basegfx::B2DPolygon& rPolyLine, |