summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorALONSO Laurent <laurent.alonso@inria.fr>2019-04-07 10:39:25 +0200
committerALONSO Laurent <laurent.alonso@inria.fr>2019-04-07 10:39:25 +0200
commit54fac59bb8017b5d9e568f07bac423a4cc5ecb40 (patch)
treece66ce757d5978111baac85074c12cc65a08ed5e
parent7ad7c4db5b22e8486b99f4b036963b1cf1d2f935 (diff)
pages[xml]: retrieve lines attached as page...
Change-Id: I477ae47b3bb1722411e2ed388f80aa78b4fff838
-rw-r--r--src/lib/IWORKCollector.cpp1
-rw-r--r--src/lib/PAG1Parser.cpp3
-rw-r--r--src/lib/PAGCollector.cpp9
3 files changed, 5 insertions, 8 deletions
diff --git a/src/lib/IWORKCollector.cpp b/src/lib/IWORKCollector.cpp
index 26b0089..da93e96 100644
--- a/src/lib/IWORKCollector.cpp
+++ b/src/lib/IWORKCollector.cpp
@@ -1071,6 +1071,7 @@ void IWORKCollector::drawLine(const IWORKLinePtr_t &line)
librevenge::RVNGPropertyList points;
points.insert("svg:points", vertices);
+ fillShapeProperties(points);
elements.addDrawPolyline(points);
}
diff --git a/src/lib/PAG1Parser.cpp b/src/lib/PAG1Parser.cpp
index abd0933..4c8baae 100644
--- a/src/lib/PAG1Parser.cpp
+++ b/src/lib/PAG1Parser.cpp
@@ -19,6 +19,7 @@
#include "IWORKGroupElement.h"
#include "IWORKHeaderFooterContext.h"
#include "IWORKImageElement.h"
+#include "IWORKLineElement.h"
#include "IWORKMediaElement.h"
#include "IWORKMetadataElement.h"
#include "IWORKNumberConverter.h"
@@ -679,6 +680,8 @@ IWORKXMLContextPtr_t PageGroupElement::element(const int name)
return std::make_shared<PAG1ShapeContext>(getState());
case IWORKToken::NS_URI_SF | IWORKToken::group :
return std::make_shared<GroupElement>(getState());
+ case IWORKToken::NS_URI_SF | IWORKToken::line :
+ return std::make_shared<IWORKLineElement>(getState());
case IWORKToken::NS_URI_SF | IWORKToken::image :
return std::make_shared<IWORKImageElement>(getState());
case IWORKToken::NS_URI_SF | IWORKToken::media :
diff --git a/src/lib/PAGCollector.cpp b/src/lib/PAGCollector.cpp
index 2cede83..5adc9c0 100644
--- a/src/lib/PAGCollector.cpp
+++ b/src/lib/PAGCollector.cpp
@@ -288,14 +288,7 @@ void PAGCollector::drawMedia(const double x, const double y, const librevenge::R
return;
}
RVNGPropertyList frameProps(data);
- if (m_inAttachments)
- {
- frameProps.insert("text:anchor-type", "as-char");
- frameProps.insert("style:vertical-pos", "bottom");
- frameProps.insert("style:vertical-rel", "text");
- }
- else
- fillShapeProperties(frameProps);
+ fillShapeProperties(frameProps);
if (m_inAttachments && m_attachmentPosition)
{
frameProps.insert("svg:x", pt2in(get(m_attachmentPosition).m_x));