From cec2736cc98834341f25ee559af5805feb441066 Mon Sep 17 00:00:00 2001 From: Edouard DUPIN Date: Thu, 3 Dec 2015 22:10:30 +0100 Subject: [PATCH] [DEBUG] correct path end and not ending --- esvg/Path.cpp | 2 +- esvg/render/Path.cpp | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/esvg/Path.cpp b/esvg/Path.cpp index 4c42a37..541964b 100644 --- a/esvg/Path.cpp +++ b/esvg/Path.cpp @@ -75,7 +75,7 @@ bool esvg::Path::parseXML(const std::shared_ptr& _element, mat2& std::string elementXML1 = _element->getAttribute("d"); if (elementXML1.size() == 0) { - SVG_ERROR("(l "<<_element->getPos()<<") path: missing 'p' attribute"); + SVG_WARNING("(l "<<_element->getPos()<<") path: missing 'd' attribute or empty"); return false; } SVG_VERBOSE("Parse Path : \"" << elementXML1 << "\""); diff --git a/esvg/render/Path.cpp b/esvg/render/Path.cpp index 03a2589..ebc1133 100644 --- a/esvg/render/Path.cpp +++ b/esvg/render/Path.cpp @@ -349,8 +349,10 @@ esvg::render::PointList esvg::render::Path::generateListPoints(int32_t _level, i break; } } + // special case : No request end of path ==> open path: if (tmpListPoint.size() != 0) { - SVG_WARNING("TODO ... check this ..."); + SVG_VERBOSE("Auto-end PATH"); + tmpListPoint.back().setEndPath(); out.addList(tmpListPoint); tmpListPoint.clear(); }