Compare commits

..

5 Commits

Author SHA1 Message Date
9d10c4ddce Merge branch 'develop' of https://github.com/ONLYOFFICE/core into develop 2017-03-07 12:19:08 +03:00
d5026d014d . 2017-03-06 17:24:29 +03:00
ac0b7e4e22 fix bug 34019 2017-03-06 15:45:43 +03:00
623fe25415 fix 34229 2017-03-06 15:30:54 +03:00
c4c9d50aae fix bug 34222 2017-03-06 14:29:15 +03:00
6 changed files with 24 additions and 20 deletions

View File

@ -110,7 +110,7 @@ namespace utils {
{
if (!a_.empty())
{
return boost::lexical_cast<int>(a_.length())-1;
return boost::lexical_cast<int>(a_) - 1;
}
else
return 0;

View File

@ -1763,7 +1763,11 @@ void XlsxConverter::convert(OOX::Spreadsheet::CCellAnchor *oox_anchor)
else if (oox_anchor->m_oGroupShape.IsInit())
{
convert(oox_anchor->m_oGroupShape.GetPointer());
}
}
else if (oox_anchor->m_oGraphicFrame.IsInit())
{
OoxConverter::convert(oox_anchor->m_oGraphicFrame.GetPointer());
}
}
void XlsxConverter::convert(OOX::Spreadsheet::CDrawing *oox_drawing)

View File

@ -110,6 +110,8 @@ namespace PPTX
OOX::CPath FileContainer::CorrectPathRels(const OOX::CPath& path, OOX::Rels::CRelationShip* relation )
{
if (relation->IsExternal()) return relation->Target();
OOX::CPath filename = path / relation->Target();
if ( NSFile::CFileBinary::Exists(filename.GetPath()) == true ) return filename;

View File

@ -298,6 +298,15 @@ namespace PPTX
{
nvGraphicFramePr.toXmlWriter(pWriter);
if (xfrm.IsInit() && pWriter->m_lDocType != XMLWRITER_DOC_TYPE_DOCX)
{
std::wstring namespace_ = m_namespace;
if (pWriter->m_lDocType == XMLWRITER_DOC_TYPE_XLSX && pWriter->m_lGroupIndex >= 0) namespace_ = L"xdr";
xfrm->m_ns = namespace_;
xfrm->toXmlWriter(pWriter);
}
if (table.is_init())
{
pWriter->WriteString (L"<a:graphic><a:graphicData uri=\"http://schemas.openxmlformats.org/drawingml/2006/table\">");
@ -322,11 +331,6 @@ namespace PPTX
pWriter->EndAttributes();
if (xfrm.IsInit())
{
xfrm->m_ns = namespace_;
xfrm->toXmlWriter(pWriter);
}
toXmlWriter2(pWriter);
pWriter->EndNode(namespace_ + L":graphicFrame");
@ -535,6 +539,11 @@ namespace PPTX
std::wstring sXml;
sXml += nvGraphicFramePr.toXML();
if (xfrm.IsInit() && m_namespace != L"wp")
{
sXml += xfrm->toXML();
}
if (table.IsInit())
{
sXml += L"<a:graphic><a:graphicData uri=\"http://schemas.openxmlformats.org/drawingml/2006/table\">";
@ -555,17 +564,6 @@ namespace PPTX
sXml += L"<" + m_namespace + L":graphicFrame macro=\"\">";
if (xfrm.IsInit())
{
xfrm->m_ns = m_namespace;
sXml += xfrm->toXML();
}
else
{
sXml += L"<" + m_namespace + L":xfrm><a:off x=\"0\" y=\"0\"/><a:ext cx=\"0\" cy=\"0\"/>";
sXml += L"</" + m_namespace + L":xfrm>";
}
sXml += toXML2();
sXml += L"</" + m_namespace + L":graphicFrame>";

View File

@ -97,7 +97,7 @@ namespace PPTX
if (spcPct.is_init())
{
oValue.m_strValue = L"<a:spcPct val=\"" + std::to_wstring(*spcPct) + L"\">";
oValue.m_strValue = L"<a:spcPct val=\"" + std::to_wstring(*spcPct) + L"\"/>";
}
else
{

View File

@ -7,7 +7,7 @@
QT -= core
QT -= gui
VERSION = 2.0.3.445
VERSION = 2.0.3.446
DEFINES += INTVER=$$VERSION
TARGET = x2t