Commit 8aefacd4 authored by ElenaSubbotina's avatar ElenaSubbotina

new chart witout office_drawing(faster...)

parent 6cd5fbca
......@@ -147,6 +147,8 @@ namespace PPTX
virtual std::wstring toXML() const
{
if (m_namespace.empty()) m_namespace = L"a";
XmlUtils::CAttribute oAttr;
oAttr.Write(_T("rot"), rot);
oAttr.Write(_T("spcFirstLastPara"), spcFirstLastPara);
......@@ -186,6 +188,8 @@ namespace PPTX
virtual void toXmlWriter(NSBinPptxRW::CXmlWriter* pWriter) const
{
if (m_namespace.empty()) m_namespace = L"a";
pWriter->StartNode(m_namespace + _T(":bodyPr"));
pWriter->StartAttributes();
......
......@@ -127,7 +127,7 @@ namespace PPTX
int nParentDepth = oReader.GetDepth();
while( oReader.ReadNextSiblingNode( nParentDepth ) )
{
std::wstring strName = oReader.GetName();
std::wstring strName = XmlUtils::GetNameNoNS(oReader.GetName());
WritingElement *pItem = NULL;
if (_T("pPr") == strName)
......
......@@ -104,6 +104,9 @@ namespace PPTX
}
virtual std::wstring toXML() const
{
if (m_name.empty())
m_name = L"a:lstStyle";
XmlUtils::CNodeValue oValue;
oValue.WriteNullable(/*defPPr*/ levels[9]);
oValue.WriteNullable(/*lvl1pPr*/ levels[0]);
......
......@@ -251,10 +251,14 @@ namespace XmlUtils
AVSINLINE std::wstring CreateNode(const std::wstring& strName, const CAttribute& oAttr)
{
if (strName.empty()) return L"";
return L"<" + strName + (oAttr.m_strValue.empty() ? L"" : L" " + oAttr.m_strValue) + L"/>";
}
AVSINLINE std::wstring CreateNode(const std::wstring& strName, const CNodeValue& oNode)
{
if (strName.empty()) return L"";
if (oNode.m_strValue.empty())
return L"<" + strName + L"/>";
......@@ -262,6 +266,8 @@ namespace XmlUtils
}
AVSINLINE std::wstring CreateNode(const std::wstring& strName, const CAttribute& oAttr, const CNodeValue& oNode)
{
if (strName.empty()) return L"";
if ( oNode.m_strValue.empty())
return CreateNode(strName, oAttr);
......@@ -269,6 +275,8 @@ namespace XmlUtils
}
AVSINLINE std::wstring CreateNode(const std::wstring& strName, const CAttribute& oAttr, const std::wstring& strXml)
{
if (strName.empty()) return L"";
if (!strXml.empty())
return L"<" + strName + (oAttr.m_strValue.empty() ? L"" : L" " + oAttr.m_strValue) + L">" + strXml + L"</" + strName + L">";
......@@ -276,6 +284,8 @@ namespace XmlUtils
}
AVSINLINE std::wstring CreateNode(const std::wstring& strName, const std::wstring& strXml)
{
if (strName.empty()) return L"";
return L"<" + strName + L">" + strXml + L"</" + strName + L">";
}
......
......@@ -666,6 +666,14 @@
<File
RelativePath="..\..\..\ASCOfficeDocxFile2\BinWriter\BinWriters.cpp"
>
<FileConfiguration
Name="Debug|Win32"
>
<Tool
Name="VCCLCompilerTool"
AdditionalOptions="/bigobj"
/>
</FileConfiguration>
</File>
<File
RelativePath="..\..\..\ASCOfficeDocxFile2\BinWriter\BinWriters.h"
......
......@@ -1874,8 +1874,10 @@ namespace BinXlsxRW
CT_Tx* poVal = static_cast<CT_Tx*>(poResult);
if(c_oserct_txRICH == type)
{
BYTE typeRec1 = m_oBufferedStream.GetUChar();
poVal->m_oRich = new PPTX::Logic::TxBody;
res = Read1(length, &BinaryChartReader::ReadCT_TxPr, this, poVal->m_oRich.GetPointer());
poVal->m_oRich->fromPPTY(&m_oBufferedStream);
poVal->m_oRich->m_name = L"c:rich";
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment