summaryrefslogtreecommitdiff
path: root/vcl/source/gdi/WidgetDefinition.cxx
diff options
context:
space:
mode:
authorTomaž Vajngerl <tomaz.vajngerl@collabora.co.uk>2019-02-08 21:56:14 +0100
committerTomaž Vajngerl <quikee@gmail.com>2019-03-05 11:23:41 +0100
commit983566119c926d0e2478f74548f00a789de55c15 (patch)
tree082517f6aa3414cf6bd8c475f2c4eb956ddacb51 /vcl/source/gdi/WidgetDefinition.cxx
parent5723d303a44597cdb2ea242cf3fb0ac0e8c15b83 (diff)
Add support for <image> draw definition to draw a SVG image
Attribute "source" is used to get the relative path to the image. Path is relative to the definition file. Change-Id: I6ca0c113385e26ad74b928e1f56635b4b0cef995 Reviewed-on: https://gerrit.libreoffice.org/68712 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Diffstat (limited to 'vcl/source/gdi/WidgetDefinition.cxx')
-rw-r--r--vcl/source/gdi/WidgetDefinition.cxx7
1 files changed, 7 insertions, 0 deletions
diff --git a/vcl/source/gdi/WidgetDefinition.cxx b/vcl/source/gdi/WidgetDefinition.cxx
index 2cff3aedd36e..defcf0b84cd8 100644
--- a/vcl/source/gdi/WidgetDefinition.cxx
+++ b/vcl/source/gdi/WidgetDefinition.cxx
@@ -132,6 +132,13 @@ void WidgetDefinitionState::addDrawLine(Color aStrokeColor, sal_Int32 nStrokeWid
mpDrawCommands.push_back(std::move(pCommand));
}
+void WidgetDefinitionState::addDrawImage(OUString sSource)
+{
+ auto pCommand(std::make_shared<ImageDrawCommand>());
+ pCommand->msSource = sSource;
+ mpDrawCommands.push_back(std::move(pCommand));
+}
+
} // end vcl namespace
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */