Compare commits

..

15 Commits

Author SHA1 Message Date
31deb60343 Merge branch 'develop' of https://github.com/ONLYOFFICE/core into develop 2019-02-07 19:30:26 +03:00
7e83e168db PptFormat - fix bug #40114 2019-02-07 19:29:51 +03:00
a4c0fbe4ea Fix bug #40340
Add support of a GM_COMPATIBLE mode for a text. Also fixed the problem with clipping by the path with specified a world-transform
2019-02-07 19:05:00 +03:00
ae0f5867dd [ios][x2t] up formats 2019-02-07 18:44:52 +03:00
0dd4fc9c14 x2t - doc/ppt/xls format - small refactoring (rename namespaces) 2019-02-07 18:23:41 +03:00
3a92ef2395 Merge branch 'develop' of https://github.com/ONLYOFFICE/core into develop 2019-02-06 18:11:35 +03:00
23c9a65fcb PptFormat - fix bug #40482 2019-02-06 18:10:39 +03:00
ba55f1436d [ios][x2t] up formats 2019-02-06 18:02:00 +03:00
f1c1d62a4d [x2t] Fix writing corrupted pptx 2019-02-06 13:03:11 +03:00
c2bdec6bde Merge branch 'develop' of https://github.com/ONLYOFFICE/core into develop 2019-02-05 20:39:34 +03:00
93d0ebfa09 . 2019-02-05 20:39:24 +03:00
6f881e2066 XlsFormat - fix bugs #40461, #40459 2019-02-05 20:36:11 +03:00
8be0d7f2b3 [x2t] Add "created", "MODIFIED" environments to rev:8f332c3c09437f0d89b8d0a843655b6b02eb1329 2019-02-05 15:45:18 +03:00
cbbb4c19de . 2019-02-05 12:23:10 +03:00
f4e0ce53b4 [x2t] For linux build 8f332c3c09 2019-02-05 11:24:36 +03:00
428 changed files with 2820 additions and 2219 deletions

View File

@ -324,7 +324,7 @@ namespace DocFileFormat
{
case wzEquationXML:
{
ODRAW::xmlString *pXml = dynamic_cast<ODRAW::xmlString*>(iter.get());
ODRAW::XmlString *pXml = dynamic_cast<ODRAW::XmlString*>(iter.get());
if (pXml)
{
m_isEquation = true;
@ -340,7 +340,7 @@ namespace DocFileFormat
}break;
case metroBlob:
{//встроенная неведомая хуйня
ODRAW::metroBlob* blob = dynamic_cast<ODRAW::metroBlob*>(iter.get());
ODRAW::MetroBlob* blob = dynamic_cast<ODRAW::MetroBlob*>(iter.get());
if (blob)
{
m_isBlob = true;

View File

@ -568,7 +568,7 @@ namespace DocFileFormat
}break;
case fillBlipName:
{
ODRAW::anyString* str = dynamic_cast<ODRAW::anyString*>(iter.get());
ODRAW::AnyString* str = dynamic_cast<ODRAW::AnyString*>(iter.get());
if ((str) && (!str->string_.empty()))
{
appendValueAttribute(&m_fill, L"o:title", FormatUtils::XmlEncode(str->string_));
@ -650,7 +650,7 @@ namespace DocFileFormat
}break;
case pibName:
{
ODRAW::anyString* str = dynamic_cast<ODRAW::anyString*>(iter.get());
ODRAW::AnyString* str = dynamic_cast<ODRAW::AnyString*>(iter.get());
if ((str) && (!str->string_.empty()))
{
appendValueAttribute(&m_imagedata, L"o:title", FormatUtils::XmlEncode(str->string_));
@ -762,7 +762,7 @@ namespace DocFileFormat
// Word Art
case gtextUNICODE:
{
ODRAW::anyString* str = dynamic_cast<ODRAW::anyString*>(iter.get());
ODRAW::AnyString* str = dynamic_cast<ODRAW::AnyString*>(iter.get());
if ((str) && (!str->string_.empty()))
{
std::wstring text = FormatUtils::XmlEncode(str->string_);
@ -776,7 +776,7 @@ namespace DocFileFormat
}break;
case gtextFont:
{
ODRAW::anyString* str = dynamic_cast<ODRAW::anyString*>(iter.get());
ODRAW::AnyString* str = dynamic_cast<ODRAW::AnyString*>(iter.get());
if ((str) && (!str->string_.empty()))
{
std::wstring font = str->string_;
@ -1261,7 +1261,7 @@ namespace DocFileFormat
/// Build the VML wrapcoords string for a given pWrapPolygonVertices
std::wstring VMLShapeMapping::GetWrapCoords(const ODRAW::OfficeArtFOPTEPtr& pOpt) const
{
ODRAW::pWrapPolygonVertices* pWrapPolygonVertices = dynamic_cast<ODRAW::pWrapPolygonVertices*>(pOpt.get());
ODRAW::PWrapPolygonVertices* pWrapPolygonVertices = dynamic_cast<ODRAW::PWrapPolygonVertices*>(pOpt.get());
if (!pWrapPolygonVertices) return L"";
std::wstring coords;
@ -1842,7 +1842,7 @@ namespace DocFileFormat
std::wstring VMLShapeMapping::getFillColorString(const ODRAW::OfficeArtFOPTEPtr& pOpt) const
{
ODRAW::fillShadeColors* pColors = dynamic_cast<ODRAW::fillShadeColors*>(pOpt.get());
ODRAW::FillShadeColors* pColors = dynamic_cast<ODRAW::FillShadeColors*>(pOpt.get());
if (!pColors) return L"";
std::wstring result;
@ -1923,7 +1923,7 @@ namespace DocFileFormat
}
std::wstring VMLShapeMapping::GetConnectAngles(const ODRAW::OfficeArtFOPTEPtr& pOpt) const
{
ODRAW::pConnectionSitesDir* pAngles = dynamic_cast<ODRAW::pConnectionSitesDir*>(pOpt.get());
ODRAW::PConnectionSitesDir* pAngles = dynamic_cast<ODRAW::PConnectionSitesDir*>(pOpt.get());
if (!pAngles) return L"";
std::wstring angles;
@ -1951,7 +1951,7 @@ namespace DocFileFormat
}
void VMLShapeMapping::GetGuides( const ODRAW::OfficeArtFOPTEPtr& pOpt )
{
ODRAW::pGuides* pGuides = dynamic_cast<ODRAW::pGuides*>(pOpt.get());
ODRAW::PGuides* pGuides = dynamic_cast<ODRAW::PGuides*>(pOpt.get());
if (!pGuides) return;
m_arrGuides = pGuides->complex.data;
@ -1975,7 +1975,7 @@ namespace DocFileFormat
std::wstring VMLShapeMapping::GetConnectLocs( const ODRAW::OfficeArtFOPTEPtr& pOpt ) const
{
ODRAW::pConnectionSites* pConnection = dynamic_cast<ODRAW::pConnectionSites*>(pOpt.get());
ODRAW::PConnectionSites* pConnection = dynamic_cast<ODRAW::PConnectionSites*>(pOpt.get());
if (!pConnection) return L"";
std::wstring locs;
@ -1996,7 +1996,7 @@ namespace DocFileFormat
{
std::vector<std::wstring> rectangles;
ODRAW::pInscribe* pInscribe = dynamic_cast<ODRAW::pInscribe*>(pOpt.get());
ODRAW::PInscribe* pInscribe = dynamic_cast<ODRAW::PInscribe*>(pOpt.get());
if (!pInscribe) return rectangles;
for (size_t i = 0; i < pInscribe->complex.data.size(); ++i)

View File

@ -8806,7 +8806,6 @@ public:
case c_oSerTableTypes::App:
{
PPTX::App oApp(NULL);
m_oBufferedStream.Skip(1); // type
oApp.fromPPTY(&m_oBufferedStream);
OOX::CApp* pApp = new OOX::CApp(NULL);
pApp->FromPptxApp(&oApp);
@ -8817,7 +8816,6 @@ public:
case c_oSerTableTypes::Core:
{
PPTX::Core oCore(NULL);
m_oBufferedStream.Skip(1); // type
oCore.fromPPTY(&m_oBufferedStream);
OOX::CCore* pCore = new OOX::CCore(NULL);
pCore->FromPptxCore(&oCore);

View File

@ -377,8 +377,7 @@ void _oox_drawing::serialize_bodyPr(std::wostream & strm, const std::wstring & n
}
else if ((bFitToSize) && (*bFitToSize))
{
CP_XML_NODE(L"a:noAutofit");
//CP_XML_NODE(L"a:spAutoFit")
CP_XML_NODE(L"a:normAutofit");
//{
// CP_XML_ATTR(L"lnSpcReduction", 10000);
//}

View File

@ -55,6 +55,7 @@ void graphic_format_properties::add_attributes( const xml::attributes_wc_ptr & A
CP_APPLY_ATTR(L"draw:auto-grow-width", draw_auto_grow_width_);
CP_APPLY_ATTR(L"draw:fit-to-size", draw_fit_to_size_);
CP_APPLY_ATTR(L"draw:fit-to-contour", draw_fit_to_contour_);
CP_APPLY_ATTR(L"style:shrink-to-fit", style_shrink_to_fit_);
CP_APPLY_ATTR(L"draw:stroke", draw_stroke_);
CP_APPLY_ATTR(L"draw:stroke-dash", draw_stroke_dash_);
@ -134,8 +135,10 @@ void graphic_format_properties::apply_to(std::vector<_property> & properties)
if (draw_auto_grow_height_) properties.push_back(_property(L"auto-grow-height", *draw_auto_grow_height_));
if (draw_auto_grow_width_) properties.push_back(_property(L"auto-grow-width", *draw_auto_grow_width_));
if (draw_fit_to_size_) properties.push_back(_property(L"fit-to-size", *draw_fit_to_size_));
if (draw_fit_to_contour_) properties.push_back(_property(L"fit-to-contour", *draw_fit_to_contour_));
if (style_shrink_to_fit_) properties.push_back(_property(L"fit-to-size", true));
else if (draw_fit_to_size_) properties.push_back(_property(L"fit-to-size", *draw_fit_to_size_));
if (common_draw_fill_attlist_.draw_color_mode_)
{
@ -183,6 +186,7 @@ void graphic_format_properties::apply_from(const graphic_format_properties * Oth
_CP_APPLY_PROP3(draw_auto_grow_width_);
_CP_APPLY_PROP3(draw_fit_to_size_);
_CP_APPLY_PROP3(draw_fit_to_contour_);
_CP_APPLY_PROP3(style_shrink_to_fit_);
_CP_APPLY_PROP3(svg_stroke_color_);
_CP_APPLY_PROP3(svg_stroke_width_);

View File

@ -94,7 +94,8 @@ public:
_CP_OPT(bool) draw_auto_grow_height_;
_CP_OPT(bool) draw_auto_grow_width_;
_CP_OPT(bool) draw_fit_to_size_;
_CP_OPT(bool) style_shrink_to_fit_;
_CP_OPT(bool) draw_fit_to_size_; // draw:fit-to-size="shrink-to-fit" style:shrink-to-fit="true" - cebre_1.odp
_CP_OPT(bool) draw_fit_to_contour_;
_CP_OPT(std::wstring) draw_wrap_influence_on_position_;

View File

@ -119,7 +119,7 @@ _UINT32 COfficePPTFile::LoadFromFile(std::wstring sSrcFileName, std::wstring sDs
}
if (!((CPPTFileReader*)m_pReader)->m_oDocumentInfo.m_arUsers.empty())
{
NSPresentationEditor::CPPTXWriter oPPTXWriter;
PPT_FORMAT::CPPTXWriter oPPTXWriter;
oPPTXWriter.m_strTempDirectory = sDstPath;

View File

@ -48,7 +48,7 @@
#include "Converter.h"
namespace NSPresentationEditor
namespace PPT_FORMAT
{
namespace NSPPTXWriterConst
{
@ -68,7 +68,7 @@ namespace NSPresentationEditor
}
NSPresentationEditor::CPPTXWriter::CPPTXWriter()
PPT_FORMAT::CPPTXWriter::CPPTXWriter()
{
m_strTempDirectory = NSDirectory::GetTempPath() + FILE_SEPARATOR_STR + _T("TempPPTX");
m_strDstFileName = NSDirectory::GetTempPath() + FILE_SEPARATOR_STR + _T("Test.pptx");
@ -79,12 +79,12 @@ NSPresentationEditor::CPPTXWriter::CPPTXWriter()
m_pShapeWriter = new CShapeWriter();
}
NSPresentationEditor::CPPTXWriter::~CPPTXWriter()
PPT_FORMAT::CPPTXWriter::~CPPTXWriter()
{
RELEASEOBJECT(m_pShapeWriter);
}
void NSPresentationEditor::CPPTXWriter::CreateFile(CPPTUserInfo* pUserInfo )
void PPT_FORMAT::CPPTXWriter::CreateFile(CPPTUserInfo* pUserInfo )
{
m_pUserInfo = pUserInfo;
@ -131,7 +131,7 @@ void NSPresentationEditor::CPPTXWriter::CreateFile(CPPTUserInfo* pUserInfo )
WriteAll();
}
void NSPresentationEditor::CPPTXWriter::CreateFile(CDocument* pDocument)
void PPT_FORMAT::CPPTXWriter::CreateFile(CDocument* pDocument)
{
m_pDocument = pDocument;
m_oManager.Clear();
@ -175,13 +175,13 @@ void NSPresentationEditor::CPPTXWriter::CreateFile(CDocument* pDocument)
WriteAll();
}
void NSPresentationEditor::CPPTXWriter::CloseFile()
void PPT_FORMAT::CPPTXWriter::CloseFile()
{
m_oManager.Clear();
}
void NSPresentationEditor::CPPTXWriter::WriteContentTypes()
void PPT_FORMAT::CPPTXWriter::WriteContentTypes()
{
std::wstring strContentTypes = L"<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"yes\" ?>\
<Types xmlns=\"http://schemas.openxmlformats.org/package/2006/content-types\">\
@ -273,7 +273,7 @@ void NSPresentationEditor::CPPTXWriter::WriteContentTypes()
}
void NSPresentationEditor::CPPTXWriter::WriteApp(CFile& oFile)
void PPT_FORMAT::CPPTXWriter::WriteApp(CFile& oFile)
{
std::wstringstream strm;
@ -413,7 +413,7 @@ void NSPresentationEditor::CPPTXWriter::WriteApp(CFile& oFile)
oFile.WriteStringUTF8(strm.str());
}
void NSPresentationEditor::CPPTXWriter::WritePresInfo()
void PPT_FORMAT::CPPTXWriter::WritePresInfo()
{
CFile oFile;
@ -551,7 +551,7 @@ void NSPresentationEditor::CPPTXWriter::WritePresInfo()
oFile.CloseFile();
}
void NSPresentationEditor::CPPTXWriter::WriteAll()
void PPT_FORMAT::CPPTXWriter::WriteAll()
{
std::wstring strPptDirectory = m_strTempDirectory + FILE_SEPARATOR_STR + _T("ppt") + FILE_SEPARATOR_STR ;
@ -585,7 +585,7 @@ void NSPresentationEditor::CPPTXWriter::WriteAll()
WriteNotes();
}
void NSPresentationEditor::CPPTXWriter::WriteThemes()
void PPT_FORMAT::CPPTXWriter::WriteThemes()
{
int nStartLayout = 0, nIndexTheme = 0;
@ -600,7 +600,7 @@ void NSPresentationEditor::CPPTXWriter::WriteThemes()
WriteTheme(m_pDocument->m_pHandoutMaster, nIndexTheme, nStartLayout);
}
void NSPresentationEditor::CPPTXWriter::WriteTheme(CThemePtr pTheme, int & nIndexTheme, int & nStartLayout)
void PPT_FORMAT::CPPTXWriter::WriteTheme(CThemePtr pTheme, int & nIndexTheme, int & nStartLayout)
{
if (!pTheme) return;
@ -612,7 +612,7 @@ void NSPresentationEditor::CPPTXWriter::WriteTheme(CThemePtr pTheme, int & nInde
CFile oFile;
oFile.CreateFile(strThemeFile);
NSPresentationEditor::CStringWriter oStringWriter;
PPT_FORMAT::CStringWriter oStringWriter;
oStringWriter.WriteString(std::wstring(L"<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"yes\" ?><a:theme xmlns:a=\"http://schemas.openxmlformats.org/drawingml/2006/main\" name=\""));
oStringWriter.WriteStringXML(pTheme->m_sThemeName);
@ -854,7 +854,7 @@ void NSPresentationEditor::CPPTXWriter::WriteTheme(CThemePtr pTheme, int & nInde
nIndexTheme++;
}
void NSPresentationEditor::CPPTXWriter::WriteColorScheme(CStringWriter& oStringWriter, const std::wstring & name, const std::vector<CColor> & colors, bool extra)
void PPT_FORMAT::CPPTXWriter::WriteColorScheme(CStringWriter& oStringWriter, const std::wstring & name, const std::vector<CColor> & colors, bool extra)
{
if (colors.size() < 1)
{
@ -908,7 +908,7 @@ accent2=\"accent2\" accent3=\"accent3\" accent4=\"accent4\" accent5=\"accent5\"
}
}
void NSPresentationEditor::CPPTXWriter::WriteBackground(CStringWriter& oWriter, CRelsGenerator& oRels, CBrush& oBackground)
void PPT_FORMAT::CPPTXWriter::WriteBackground(CStringWriter& oWriter, CRelsGenerator& oRels, CBrush& oBackground)
{
oWriter.WriteString(std::wstring(L"<p:bg><p:bgPr>"));
@ -918,7 +918,7 @@ void NSPresentationEditor::CPPTXWriter::WriteBackground(CStringWriter& oWriter,
}
oWriter.WriteString(std::wstring(L"</p:bgPr></p:bg>"));
}
void NSPresentationEditor::CPPTXWriter::WriteGroup(CStringWriter& oWriter, CRelsGenerator& oRels, CElementPtr pElement, CLayout* pLayout)
void PPT_FORMAT::CPPTXWriter::WriteGroup(CStringWriter& oWriter, CRelsGenerator& oRels, CElementPtr pElement, CLayout* pLayout)
{
CGroupElement *pGroupElement = dynamic_cast<CGroupElement*>(pElement.get());
@ -931,7 +931,7 @@ void NSPresentationEditor::CPPTXWriter::WriteGroup(CStringWriter& oWriter, CRels
}
oWriter.WriteString(L"</p:grpSp>");
}
void NSPresentationEditor::CPPTXWriter::WriteElement(CStringWriter& oWriter, CRelsGenerator& oRels, CElementPtr pElement, CLayout* pLayout)
void PPT_FORMAT::CPPTXWriter::WriteElement(CStringWriter& oWriter, CRelsGenerator& oRels, CElementPtr pElement, CLayout* pLayout)
{
if (!pElement) return;
@ -986,7 +986,7 @@ void NSPresentationEditor::CPPTXWriter::WriteElement(CStringWriter& oWriter, CRe
}
}
void NSPresentationEditor::CPPTXWriter::WriteLayout(CLayoutPtr pLayout, int nIndexLayout, int nStartLayout, int nIndexTheme)
void PPT_FORMAT::CPPTXWriter::WriteLayout(CLayoutPtr pLayout, int nIndexLayout, int nStartLayout, int nIndexTheme)
{
if (!pLayout) return;
@ -1055,7 +1055,7 @@ void NSPresentationEditor::CPPTXWriter::WriteLayout(CLayoutPtr pLayout, int nInd
strFile = L"slideLayout" + std::to_wstring(nIndexLayout + nStartLayout + 1) + L".xml.rels";
oRels.SaveRels(strFileLayoutPath + _T("_rels") + FILE_SEPARATOR_STR + strFile);
}
void NSPresentationEditor::CPPTXWriter::WriteSlide(int nIndexSlide)
void PPT_FORMAT::CPPTXWriter::WriteSlide(int nIndexSlide)
{
CStringWriter oWriter;
CRelsGenerator oRels(&m_oManager);
@ -1140,7 +1140,7 @@ void NSPresentationEditor::CPPTXWriter::WriteSlide(int nIndexSlide)
oRels.SaveRels(strFileSlidePath + _T("_rels") + FILE_SEPARATOR_STR + strFile);
}
void NSPresentationEditor::CPPTXWriter::WriteTransition(CStringWriter& oWriter, CTransition& transition)
void PPT_FORMAT::CPPTXWriter::WriteTransition(CStringWriter& oWriter, CTransition& transition)
{
if (transition.m_nEffectType == 0xFF) return;
@ -1327,7 +1327,7 @@ void NSPresentationEditor::CPPTXWriter::WriteTransition(CStringWriter& oWriter,
oWriter.WriteString(std::wstring(L"</p:transition>"));
}
void NSPresentationEditor::CPPTXWriter::WriteNotes(int nIndexNotes)
void PPT_FORMAT::CPPTXWriter::WriteNotes(int nIndexNotes)
{
CStringWriter oWriter;
CRelsGenerator oRels(&m_oManager);
@ -1391,14 +1391,14 @@ void NSPresentationEditor::CPPTXWriter::WriteNotes(int nIndexNotes)
oRels.SaveRels(strFileSlidePath + _T("_rels") + FILE_SEPARATOR_STR + strFile);
}
void NSPresentationEditor::CPPTXWriter::WriteSlides()
void PPT_FORMAT::CPPTXWriter::WriteSlides()
{
for (size_t nIndexS = 0; nIndexS < m_pDocument->m_arSlides.size(); ++nIndexS)
{
WriteSlide((int)nIndexS);
}
}
void NSPresentationEditor::CPPTXWriter::WriteNotes()
void PPT_FORMAT::CPPTXWriter::WriteNotes()
{
for (size_t nIndexS = 0; nIndexS < m_pDocument->m_arNotes.size(); ++nIndexS)
{

View File

@ -37,7 +37,7 @@
class CStylesWriter;
class CPPTUserInfo;
namespace NSPresentationEditor
namespace PPT_FORMAT
{
class CDocument;
class CShapeWriter;

View File

@ -35,7 +35,7 @@
#include "../../../Common/FileDownloader/FileDownloader.h"
#endif
namespace NSPresentationEditor
namespace PPT_FORMAT
{
class CMediaManager
{
@ -170,7 +170,7 @@ namespace NSPresentationEditor
class CRelsGenerator
{
private:
NSPresentationEditor::CStringWriter m_oWriter;
PPT_FORMAT::CStringWriter m_oWriter;
int m_lNextRelsID;
std::map<std::wstring, int> m_mapMediaRelsID;
CMediaManager* m_pManager;

File diff suppressed because it is too large Load Diff

View File

@ -35,7 +35,7 @@
#include "ImageManager.h"
namespace NSPresentationEditor
namespace PPT_FORMAT
{
static inline LONG GetPPTXPlaceHolderType(const int & lType)
{
@ -64,7 +64,6 @@ namespace NSPresentationEditor
return 13; // subtitle
case PT_Object:
case PT_VerticalObject:
return 9; // object
case PT_MasterNotesSlideImage:
@ -86,9 +85,6 @@ namespace NSPresentationEditor
case PT_Media:
return 8; // media
case PT_Picture:
return 10; // picture
case PT_MasterDate:
return 5; // date
@ -138,15 +134,15 @@ namespace NSPresentationEditor
class CShapeWriter
{
private:
NSPresentationEditor::CStringWriter m_oWriterPath;
NSPresentationEditor::CStringWriter m_oWriterVML;
NSPresentationEditor::CStringWriter m_oWriter;
PPT_FORMAT::CStringWriter m_oWriterPath;
PPT_FORMAT::CStringWriter m_oWriterVML;
PPT_FORMAT::CStringWriter m_oWriter;
NSPresentationEditor::CElementPtr m_pElement;
PPT_FORMAT::CElementPtr m_pElement;
NSPresentationEditor::CRelsGenerator* m_pRels;
PPT_FORMAT::CRelsGenerator* m_pRels;
NSPresentationEditor::CTheme* m_pTheme;
PPT_FORMAT::CTheme* m_pTheme;
LONG m_lNextShapeID;

View File

@ -31,19 +31,19 @@
*/
#pragma once
namespace NSPresentationEditor
namespace PPT_FORMAT
{
class CTheme;
}
class CStylesWriter
{
public:
CStylesWriter(NSPresentationEditor::CTheme* m_pTheme);
CStylesWriter(PPT_FORMAT::CTheme* m_pTheme);
CStylesWriter();
NSPresentationEditor::CTheme* m_pTheme;
PPT_FORMAT::CTheme* m_pTheme;
void ConvertStyles(NSPresentationEditor::CTextStyles& oStyles, NSPresentationEditor::CStringWriter& oWriter, int nCount = 10)
void ConvertStyles(PPT_FORMAT::CTextStyles& oStyles, PPT_FORMAT::CStringWriter& oWriter, int nCount = 10)
{
for (int i = 0; i < nCount; ++i)
{
@ -51,19 +51,19 @@ public:
ConvertStyleLevel(oStyles.m_pLevels[i].get(), oWriter, i);
}
}
std::wstring ConvertStyleLevel(NSPresentationEditor::CTextStyleLevel& oLevel, const int& nLevel)
std::wstring ConvertStyleLevel(PPT_FORMAT::CTextStyleLevel& oLevel, const int& nLevel)
{
NSPresentationEditor::CStringWriter oWriter;
PPT_FORMAT::CStringWriter oWriter;
ConvertStyleLevel(oLevel, oWriter, nLevel);
return oWriter.GetData();
}
void ConvertStyleLevel(NSPresentationEditor::CTextStyleLevel& oLevel,
NSPresentationEditor::CStringWriter& oWriter, const int& nLevel);
void ConvertStyleLevel(PPT_FORMAT::CTextStyleLevel& oLevel,
PPT_FORMAT::CStringWriter& oWriter, const int& nLevel);
std::wstring ConvertStyles(NSPresentationEditor::CTextStyles& oStyles, int nCount = 10)
std::wstring ConvertStyles(PPT_FORMAT::CTextStyles& oStyles, int nCount = 10)
{
NSPresentationEditor::CStringWriter oWriter;
PPT_FORMAT::CStringWriter oWriter;
ConvertStyles(oStyles, oWriter, nCount);
return oWriter.GetData();
}

View File

@ -33,7 +33,7 @@
#include "../Records/CurrentUserAtom.h"
using namespace NSOfficePPT;
//using namespace NSOfficePPT;
class CUserEdit
{

View File

@ -42,6 +42,7 @@
#include "../Records/SoundCollectionContainer.h"
#include "../Records/SoundContainer.h"
CPPTUserInfo::CPPTUserInfo() : CDocument(),
m_oUser(),
m_mapOffsetInPIDs(),
@ -446,7 +447,7 @@ void CPPTUserInfo::ReadExtenalObjects(std::wstring strFolderMem)
// так... теперь берем всю инфу о ExObject -----------------------------
m_oExMedia.m_strPresentationDirectory = strFolderMem;
NSPresentationEditor::CExFilesInfo oInfo;
PPT_FORMAT::CExFilesInfo oInfo;
oInfo.m_strFilePath = m_oExMedia.m_strPresentationDirectory;
oInfo.m_dwID = 0xFFFFFFFF;
@ -475,10 +476,10 @@ void CPPTUserInfo::ReadExtenalObjects(std::wstring strFolderMem)
for (size_t nIndex = 0; nIndex < oArrayFonts.size(); ++nIndex)
{
CFont oFont;
CFontProperty oFont;
oFont.Name = oArrayFonts[nIndex]->m_strFaceName;
oFont.Charset = oArrayFonts[nIndex]->m_lfCharSet;
oFont.PitchFamily = oArrayFonts[nIndex]->m_lfPitchAndFamily;
m_arrFonts.push_back(oFont);
@ -510,7 +511,7 @@ void CPPTUserInfo::FromDocument()
oArrayInfo[0]->GetRecordsByType(&oStyles, false, false);
if (0 != oStyles.size())
m_oDefaultTextStyle.SetStyles((NSPresentationEditor::CTextStyles*)oStyles[0]);
m_oDefaultTextStyle.SetStyles((PPT_FORMAT::CTextStyles*)oStyles[0]);
std::vector<CRecordTextSIExceptionAtom*> oSI;
oArrayInfo[0]->GetRecordsByType(&oSI, false, false);
@ -674,7 +675,7 @@ void CPPTUserInfo::LoadNotes(_UINT32 dwNoteID, CSlide* pNotes)
CLayout* pLayout = NULL;
//-----------------------------------------------------
std::vector<NSPresentationEditor::CColor>* pArrayColorScheme = pTheme ? &pTheme->m_arColorScheme : NULL;
std::vector<ODRAW::CColor>* pArrayColorScheme = pTheme ? &pTheme->m_arColorScheme : NULL;
// читаем цветовую схему -----------------------------------------------------------
pNotes->m_bUseLayoutColorScheme = true;
@ -800,7 +801,7 @@ void CPPTUserInfo::LoadSlide(_UINT32 dwSlideID, CSlide* pSlide)
pTransition->m_bAudioPresent = pAtom->m_bSound;
NSPresentationEditor::CExFilesInfo* pInfo = m_oExMedia.LockAudioFromCollection(pAtom->m_nSoundRef);
PPT_FORMAT::CExFilesInfo* pInfo = m_oExMedia.LockAudioFromCollection(pAtom->m_nSoundRef);
if (NULL != pInfo)
{
pTransition->m_oAudio.m_strAudioFileName = pInfo->m_strFilePath;
@ -818,7 +819,7 @@ void CPPTUserInfo::LoadSlide(_UINT32 dwSlideID, CSlide* pSlide)
CSlideShowSlideInfoAtom* pAtom = &pRecordSlide->m_oSlideShowSlideInfoAtom;
if (pAtom->m_bSound)
{
NSPresentationEditor::CExFilesInfo* pInfo = m_oExMedia.LockAudioFromCollection(pAtom->m_nSoundRef);
PPT_FORMAT::CExFilesInfo* pInfo = m_oExMedia.LockAudioFromCollection(pAtom->m_nSoundRef);
if (NULL != pInfo)
AddAudioTransition (dwSlideID, pTransition, pInfo->m_strFilePath);
}
@ -897,7 +898,7 @@ void CPPTUserInfo::LoadSlide(_UINT32 dwSlideID, CSlide* pSlide)
}
}
std::vector<NSPresentationEditor::CColor>* pArrayColorScheme = &pTheme->m_arColorScheme;
std::vector<ODRAW::CColor>* pArrayColorScheme = &pTheme->m_arColorScheme;
if (!pLayout->m_bUseThemeColorScheme)
pArrayColorScheme = &pLayout->m_arColorScheme;
@ -1024,16 +1025,16 @@ void CPPTUserInfo::LoadSlide(_UINT32 dwSlideID, CSlide* pSlide)
}
std::multimap<int, int>::iterator it;
if (bHasSlideNumber) AddLayoutSlidePlaceholder(pSlide, MasterSlideNumber, pLayout, true);
if (bHasSlideNumber) AddLayoutSlidePlaceholder(pSlide, PT_MasterSlideNumber, pLayout, true);
if (bHasDate)
{
CElementPtr pElement = AddLayoutSlidePlaceholder(pSlide, MasterDate, pLayout, true);
CElementPtr pElement = AddLayoutSlidePlaceholder(pSlide, PT_MasterDate, pLayout, true);
if (pElement) pElement->m_nFormatDate = nFormatDate;
}
if (bHasFooter) AddLayoutSlidePlaceholder(pSlide, MasterFooter, pLayout, true);
if (bHasFooter) AddLayoutSlidePlaceholder(pSlide, PT_MasterFooter, pLayout, true);
}
void CPPTUserInfo::LoadGroupShapeContainer(CRecordGroupShapeContainer* pGroupContainer, std::vector<CElementPtr>* pParentElements, CTheme* pTheme, CLayout* pLayout,
@ -1101,9 +1102,9 @@ void CPPTUserInfo::LoadGroupShapeContainer(CRecordGroupShapeContainer* pGroupCon
{
if (pElement->m_lPlaceholderID >= 0)
{
if (pElement->m_lPlaceholderType == MasterSlideNumber) pLayout->m_bHasSlideNumber = true;
if (pElement->m_lPlaceholderType == MasterDate) pLayout->m_bHasDate = true;
if (pElement->m_lPlaceholderType == MasterFooter) pLayout->m_bHasFooter = true;
if (pElement->m_lPlaceholderType == PT_MasterSlideNumber) pLayout->m_bHasSlideNumber = true;
if (pElement->m_lPlaceholderType == PT_MasterDate) pLayout->m_bHasDate = true;
if (pElement->m_lPlaceholderType == PT_MasterFooter) pLayout->m_bHasFooter = true;
}
pLayout->m_mapPlaceholders.insert(std::make_pair(pElement->m_lPlaceholderType, pElement));
}
@ -1230,7 +1231,7 @@ int CPPTUserInfo::AddNewLayout(CTheme* pTheme, CRecordSlide* pRecordSlide, bool
int ind = pTheme->m_arLayouts.size();
pTheme->m_arLayouts.push_back(boost::make_shared<NSPresentationEditor::CLayout>());
pTheme->m_arLayouts.push_back(boost::make_shared<PPT_FORMAT::CLayout>());
CLayout *pLayout = pTheme->m_arLayouts.back().get();
pLayout->m_bUseThemeColorScheme = true;
@ -1270,16 +1271,16 @@ int CPPTUserInfo::AddNewLayout(CTheme* pTheme, CRecordSlide* pRecordSlide, bool
switch(layoutRecord.m_pPlaceHolderID[i])
{
case NSOfficePPT::MasterTitle :
case NSOfficePPT::MasterBody :
case NSOfficePPT::MasterCenteredTitle :
case NSOfficePPT::MasterSubtitle :
case NSOfficePPT::MasterNotesSlideImage :
case NSOfficePPT::MasterNotesBody:
case NSOfficePPT::MasterSlideNumber:
case NSOfficePPT::MasterDate:
case NSOfficePPT::MasterHeader:
case NSOfficePPT::MasterFooter:
case PT_MasterTitle:
case PT_MasterBody:
case PT_MasterCenterTitle:
case PT_MasterSubTitle:
case PT_MasterNotesSlideImage:
case PT_MasterNotesBody:
case PT_MasterDate:
case PT_MasterSlideNumber:
case PT_MasterFooter:
case PT_MasterHeader:
{
int usualType = layoutRecord.m_pPlaceHolderID[i];
CorrectPlaceholderType(usualType);
@ -1331,9 +1332,9 @@ int CPPTUserInfo::AddNewLayout(CTheme* pTheme, CRecordSlide* pRecordSlide, bool
for (int i = 0; i < 3; i++) pLayout->m_PlaceholdersReplaceString[i] = pTheme->m_PlaceholdersReplaceString[i];
if (pLayout->m_bHasSlideNumber) AddThemeLayoutPlaceholder(pLayout, MasterSlideNumber, pTheme, true);
if (pLayout->m_bHasDate) AddThemeLayoutPlaceholder(pLayout, MasterDate, pTheme, true);
if (pLayout->m_bHasFooter) AddThemeLayoutPlaceholder(pLayout, MasterFooter, pTheme, true);
if (pLayout->m_bHasSlideNumber) AddThemeLayoutPlaceholder(pLayout, PT_MasterSlideNumber, pTheme, true);
if (pLayout->m_bHasDate) AddThemeLayoutPlaceholder(pLayout, PT_MasterDate, pTheme, true);
if (pLayout->m_bHasFooter) AddThemeLayoutPlaceholder(pLayout, PT_MasterFooter, pTheme, true);
return ind;
}
@ -1387,7 +1388,7 @@ void CPPTUserInfo::LoadMainMaster(_UINT32 dwMasterID)
if (0 == oArraySlideAtoms.size())
return;
_UINT32 dwID = (_UINT32)oArraySlideAtoms[0]->m_nMasterIDRef;
_UINT32 dwID = (_UINT32)oArraySlideAtoms[0]->m_nMasterIDRef;
if (0 != dwID)
{
// этот мастер - не main!!!
@ -1419,7 +1420,7 @@ void CPPTUserInfo::LoadMainMaster(_UINT32 dwMasterID)
m_mapMasterToTheme.insert(std::pair<_UINT32, LONG>(dwMasterID, lIndexTheme));
m_arThemes.push_back(boost::make_shared<NSPresentationEditor::CTheme>());
m_arThemes.push_back(boost::make_shared<PPT_FORMAT::CTheme>());
CTheme* pTheme = m_arThemes[lIndexTheme].get();
std::vector<CRecordHeadersFootersContainer*> oArrayHeadersFootersInfo;
@ -1531,8 +1532,8 @@ void CPPTUserInfo::LoadMainMaster(_UINT32 dwMasterID)
if ((0 > lType) || (lType > 8))
continue;
pMasterWrapper->m_pStyles[lType] = new NSPresentationEditor::CTextStyles();
pMasterWrapper->m_pStyles[lType]->SetStyles((NSPresentationEditor::CTextStyles*)oArrayTextMasters[i]);
pMasterWrapper->m_pStyles[lType] = new PPT_FORMAT::CTextStyles();
pMasterWrapper->m_pStyles[lType]->SetStyles((PPT_FORMAT::CTextStyles*)oArrayTextMasters[i]);
CTheme::CalculateStyle(pTheme, pMasterWrapper->m_pStyles[lType].get());
}
@ -1671,7 +1672,7 @@ void CPPTUserInfo::LoadMaster(_typeMaster type, CRecordSlide* pMaster, CSlideInf
}
}
pTheme = boost::make_shared<NSPresentationEditor::CTheme>(type);
pTheme = boost::make_shared<PPT_FORMAT::CTheme>(type);
std::vector<CRecordHeadersFootersContainer*> oArrayHeadersFootersInfo;
pMaster->GetRecordsByType(&oArrayHeadersFootersInfo, true, false);
@ -1891,7 +1892,7 @@ void CPPTUserInfo::LoadNoMainMaster(_UINT32 dwMasterID)
pTheme->m_mapTitleLayout[dwMasterID] = lLayoutID;
std::vector<NSPresentationEditor::CColor>* pArrayColorScheme = &pTheme->m_arColorScheme;
std::vector<ODRAW::CColor>* pArrayColorScheme = &pTheme->m_arColorScheme;
// читаем цветовую схему -----------------------------------------------------------
if (!bMasterColorScheme)
{
@ -2006,23 +2007,23 @@ void CPPTUserInfo::LoadNoMainMaster(_UINT32 dwMasterID)
if (pLayout->m_bHasSlideNumber)
{
if (pLayout->m_mapPlaceholders.find(MasterSlideNumber) == pLayout->m_mapPlaceholders.end())
if (pLayout->m_mapPlaceholders.find(PT_MasterSlideNumber) == pLayout->m_mapPlaceholders.end())
{
AddNewLayoutPlaceholder(pLayout, MasterSlideNumber, 2);
AddNewLayoutPlaceholder(pLayout, PT_MasterSlideNumber, 2);
}
}
if (pLayout->m_bHasDate && pLayout->m_nFormatDate == 1)
{
if (pLayout->m_mapPlaceholders.find(MasterDate) == pLayout->m_mapPlaceholders.end())
if (pLayout->m_mapPlaceholders.find(PT_MasterDate) == pLayout->m_mapPlaceholders.end())
{
AddNewLayoutPlaceholder(pLayout, MasterDate, 2);
AddNewLayoutPlaceholder(pLayout, PT_MasterDate, 2);
}
}
if (pLayout->m_bHasFooter)
{
if (pLayout->m_mapPlaceholders.find(MasterFooter) == pLayout->m_mapPlaceholders.end())
if (pLayout->m_mapPlaceholders.find(PT_MasterFooter) == pLayout->m_mapPlaceholders.end())
{
AddNewLayoutPlaceholder(pLayout, MasterFooter, 1);
AddNewLayoutPlaceholder(pLayout, PT_MasterFooter, 1);
}
}
@ -2249,7 +2250,7 @@ void CPPTUserInfo::LoadExternal(CRecordExObjListContainer* pExObjects)
if ((3 <= oArrayStrings.size()) && (1 == oArrayData.size()))
{
NSPresentationEditor::CExFilesInfo oInfo;
PPT_FORMAT::CExFilesInfo oInfo;
oInfo.m_strFilePath = m_oExMedia.m_strPresentationDirectory + FILE_SEPARATOR_STR + oArrayStrings[0]->m_strText + _T(".audio");
oInfo.m_dwID = (_UINT32)XmlUtils::GetInteger(oArrayStrings[2]->m_strText.c_str());
@ -2300,10 +2301,10 @@ void CPPTUserInfo::LoadExternal(CRecordExObjListContainer* pExObjects)
_UINT32 dwKeySound = oArrayAudioEmbedded[nIndex]->m_nSoundID;
_UINT32 dwKeyObj = oArrayAudioEmbedded[nIndex]->m_oMedia.m_nExObjID;
NSPresentationEditor::CExFilesInfo* pInfo = m_oExMedia.LockAudioFromCollection(dwKeySound);
PPT_FORMAT::CExFilesInfo* pInfo = m_oExMedia.LockAudioFromCollection(dwKeySound);
if (NULL != pInfo)
{
NSPresentationEditor::CExFilesInfo oAudio;
PPT_FORMAT::CExFilesInfo oAudio;
oAudio.m_dwID = dwKeyObj;
oAudio.m_strFilePath = pInfo->m_strFilePath;
@ -2316,7 +2317,7 @@ void CPPTUserInfo::LoadExternal(CRecordExObjListContainer* pExObjects)
{
_UINT32 dwKeyObj = oArrayAudioCD[nIndex]->m_oMedia.m_nExObjID;
NSPresentationEditor::CExFilesInfo* pInfo = m_oExMedia.LockAudio(dwKeyObj);
PPT_FORMAT::CExFilesInfo* pInfo = m_oExMedia.LockAudio(dwKeyObj);
if (NULL != pInfo)
{
@ -2342,7 +2343,7 @@ void CPPTUserInfo::LoadExternal(CRecordExObjListContainer* pExObjects)
if (oArrayCString.size() > 0 && oArrayHyperlink.size() > 0)
{
NSPresentationEditor::CExFilesInfo oInfo;
PPT_FORMAT::CExFilesInfo oInfo;
oInfo.m_dwID = oArrayHyperlink[0]->m_nHyperlinkID;
for (size_t i = 0 ; i < oArrayCString.size(); i++)
@ -2365,7 +2366,7 @@ void CPPTUserInfo::LoadExVideo(CRecordsContainer* pExObject)
if ((1 == oArrayExMedia.size()) && (1 == oArrayCString.size()))
{
NSPresentationEditor::CExFilesInfo oInfo;
PPT_FORMAT::CExFilesInfo oInfo;
oInfo.m_dwID = oArrayExMedia[0]->m_nExObjID;
oInfo.m_strFilePath = oArrayCString[0]->m_strText;
@ -2388,7 +2389,7 @@ void CPPTUserInfo::LoadExAudio(CRecordsContainer* pExObject)
if ((1 == oArrayExMedia.size()) && (1 == oArrayCString.size()))
{
NSPresentationEditor::CExFilesInfo oInfo;
PPT_FORMAT::CExFilesInfo oInfo;
oInfo.m_dwID = oArrayExMedia[0]->m_nExObjID;
oInfo.m_strFilePath = oArrayCString[0]->m_strText;
@ -2459,22 +2460,21 @@ void CPPTUserInfo::AddAudioTransition (_UINT32 dwSlideID, CTransition* pTransiti
delete pAudio;
}
void CPPTUserInfo::CreateDefaultStyle(NSPresentationEditor::CTextStyles& pStyle, NSPresentationEditor::CTheme* pTheme)
void CPPTUserInfo::CreateDefaultStyle(PPT_FORMAT::CTextStyles& pStyle, PPT_FORMAT::CTheme* pTheme)
{
for (int i = 0; i < 10; ++i)
{
if (!pStyle.m_pLevels[i].is_init())
pStyle.m_pLevels[i] = new NSPresentationEditor::CTextStyleLevel();
pStyle.m_pLevels[i] = new PPT_FORMAT::CTextStyleLevel();
NSPresentationEditor::CTextPFRun* pPF = &pStyle.m_pLevels[i]->m_oPFRun;
NSPresentationEditor::CTextCFRun* pCF = &pStyle.m_pLevels[i]->m_oCFRun;
PPT_FORMAT::CTextPFRun* pPF = &pStyle.m_pLevels[i]->m_oPFRun;
PPT_FORMAT::CTextCFRun* pCF = &pStyle.m_pLevels[i]->m_oCFRun;
pCF->Language = m_wLanguage;
pCF->Size = 18;
pCF->FontProperties = new NSPresentationEditor::CFontProperties();
pCF->FontProperties->SetFont(pTheme->m_arFonts[0]);
pCF->font.font = new PPT_FORMAT::CFontProperty(pTheme->m_arFonts[0]);
}
}

View File

@ -39,13 +39,13 @@
#include "SlideInfo.h"
class CPPTDocumentInfo;
using namespace NSPresentationEditor;
using namespace PPT_FORMAT;
class CPPTUserInfo : public CDocument
{
public:
CUserEdit m_oUser;
std::map<_UINT32, _UINT32> m_mapOffsetInPIDs;
std::map<_UINT32, _UINT32> m_mapOffsetInPIDs;
CRecordDocument m_oDocument;
CEncryptionHeader m_oEncryptionHeader;
@ -55,16 +55,16 @@ public:
POLE::Storage* m_pStorageDecrypt;
std::vector<CFStreamPtr> m_arStreamDecrypt; // на каждый Persist свой ... оО
std::map<_UINT32, CRecordSlide*> m_mapSlides;
std::map<_UINT32, CRecordSlide*> m_mapMasters;
std::map<_UINT32, CRecordSlide*> m_mapNotes;
std::map<_UINT32, CRecordSlide*> m_mapSlides;
std::map<_UINT32, CRecordSlide*> m_mapMasters;
std::map<_UINT32, CRecordSlide*> m_mapNotes;
std::map<_UINT32, CRecordSlide*> m_mapNotesMasters;
std::map<_UINT32, CRecordSlide*> m_mapHandoutMasters;
std::map<_UINT32, CRecordSlide*> m_mapNotesMasters;
std::map<_UINT32, CRecordSlide*> m_mapHandoutMasters;
std::vector<_UINT32> m_arrSlidesOrder;
std::vector<_UINT32> m_arrMastersOrder;
std::vector<_UINT32> m_arrNotesOrder;
std::vector<_UINT32> m_arrSlidesOrder;
std::vector<_UINT32> m_arrMastersOrder;
std::vector<_UINT32> m_arrNotesOrder;
// перевод id мастера в индекс темы/шаблона
std::map<_UINT32, LONG> m_mapMasterToTheme;
@ -83,8 +83,8 @@ public:
// эти параметры - одни на весь документ.
// чтобы поддержать нашу схему (пптх) - копируем их в темы
std::vector<CRecordBlipStoreContainer*> m_arrBlipStore;
std::vector<CFont> m_arrFonts;
NSPresentationEditor::CTextStyles m_oDefaultTextStyle;
std::vector<CFontProperty> m_arrFonts;
PPT_FORMAT::CTextStyles m_oDefaultTextStyle;
vector_string m_PlaceholdersReplaceString[3]; //0-dates, 1 - headers, 2 - footers
@ -161,7 +161,7 @@ public:
void LoadExVideo(CRecordsContainer* pExObject);
void LoadExAudio(CRecordsContainer* pExObject);
void CreateDefaultStyle(NSPresentationEditor::CTextStyles& pStyle, NSPresentationEditor::CTheme* pTheme);
void CreateDefaultStyle(PPT_FORMAT::CTextStyles& pStyle, PPT_FORMAT::CTheme* pTheme);
void CorrectColorScheme(std::vector<CColor>& oScheme)
{
if (oScheme.size() < 1) return;
@ -174,10 +174,10 @@ public:
oArrayMem.push_back(oScheme[0]);//4
oArrayMem.push_back(oScheme[4]);//5 //accent1
oArrayMem.push_back(oScheme[5]);//6 //accent2
oArrayMem.push_back(oScheme[0]);//7 //accent3
oArrayMem.push_back(oScheme[5]);//8 //accent4
oArrayMem.push_back(oScheme[4]);//9 //accent5
oArrayMem.push_back(oScheme[7]);//10 //accent6
oArrayMem.push_back(CColor(0xAAAAAA));//(oScheme[0]);//7 //accent3
oArrayMem.push_back(CColor(0xDCDCDC));//(oScheme[5]);//8 //accent4
oArrayMem.push_back(CColor(0xDBF1FA));//(oScheme[4]);//9 //accent5
oArrayMem.push_back(CColor(0x4B9DCA));//(oScheme[7]);//10 //accent6
oArrayMem.push_back(oScheme[6]);//11 //hlink
oArrayMem.push_back(oScheme[7]);//12 //folHlink
oArrayMem.push_back(oScheme[0]);//13 //lt1
@ -201,122 +201,109 @@ public:
{
switch (nGeom)
{
case 0x00: //SL_TitleSlide
case 0x02: //SL_MasterTitle
return _T("title");
case 0x01: // SL_TitleBody
case SL_TitleSlide:
case SL_MasterTitle: return L"title";
case SL_TitleBody:
{
int ind = 0;
if (pPlaceholders[0] == 13 && pPlaceholders[1] != 0) ind++;
NSOfficePPT::PlaceholderEnum phbody = (NSOfficePPT::PlaceholderEnum)pPlaceholders[ind];
ePlaceholderType phbody = (ePlaceholderType)pPlaceholders[ind];
switch (phbody)
{
case NSOfficePPT::MasterTitle:
return _T("title");
case NSOfficePPT::Table:
return _T("tbl");
case NSOfficePPT::OrganizationChart:
return _T("dgm");
case NSOfficePPT::Graph:
return _T("chart");
case PT_MasterTitle: return L"title";
case PT_Table: return L"tbl";
case PT_OrgChart: return L"dgm";
case PT_Graph: return L"chart";
default:
break;
}
return _T("obj");
return L"obj";
}
case 0x07: //SL_TitleOnly
return _T("titleOnly");
case 0x08: //SL_TwoColumns
case SL_TitleOnly: return L"titleOnly";
case SL_TwoColumns:
{
NSOfficePPT::PlaceholderEnum leftType = (NSOfficePPT::PlaceholderEnum)pPlaceholders[1];
NSOfficePPT::PlaceholderEnum rightType = (NSOfficePPT::PlaceholderEnum)pPlaceholders[2];
ePlaceholderType leftType = (ePlaceholderType)pPlaceholders[1];
ePlaceholderType rightType = (ePlaceholderType)pPlaceholders[2];
if (leftType == NSOfficePPT::Body && rightType == NSOfficePPT::Object)
if (leftType == PT_Body && rightType == PT_Object)
{
return _T("txAndObj");
return L"txAndObj";
}
else if (leftType == NSOfficePPT::Object && rightType == NSOfficePPT::Body)
else if (leftType == PT_Object && rightType == PT_Body)
{
return _T("objAndTx");
return L"objAndTx";
}
else if (leftType == NSOfficePPT::Body && rightType == NSOfficePPT::ClipArt)
else if (leftType == PT_Body && rightType == PT_ClipArt)
{
return _T("txAndClipArt");
return L"txAndClipArt";
}
else if (leftType == NSOfficePPT::ClipArt && rightType == NSOfficePPT::Body)
else if (leftType == PT_ClipArt && rightType == PT_Body)
{
return _T("clipArtAndTx");
return L"clipArtAndTx";
}
else if (leftType == NSOfficePPT::Body && rightType == NSOfficePPT::Graph)
else if (leftType == PT_Body && rightType == PT_Graph)
{
return _T("txAndChart");
return L"txAndChart";
}
else if (leftType == NSOfficePPT::Graph && rightType == NSOfficePPT::Body)
else if (leftType == PT_Graph && rightType == PT_Body)
{
return _T("chartAndTx");
return L"chartAndTx";
}
else if (leftType == NSOfficePPT::Body && rightType == NSOfficePPT::MediaClip)
else if (leftType == PT_Body && rightType == PT_Media)
{
return _T("txAndMedia");
return L"txAndMedia";
}
else if (leftType == NSOfficePPT::MediaClip && rightType == NSOfficePPT::Body)
else if (leftType == PT_Media && rightType == PT_Body)
{
return _T("mediaAndTx");
return L"mediaAndTx";
}
return _T("twoObj");
return L"twoObj";
}
case 0x09: //SL_TwoRows
case SL_TwoRows:
{
NSOfficePPT::PlaceholderEnum topType = (NSOfficePPT::PlaceholderEnum)pPlaceholders[1];
NSOfficePPT::PlaceholderEnum bottomType = (NSOfficePPT::PlaceholderEnum)pPlaceholders[2];
ePlaceholderType topType = (ePlaceholderType)pPlaceholders[1];
ePlaceholderType bottomType = (ePlaceholderType)pPlaceholders[2];
if (topType == NSOfficePPT::Body && bottomType == NSOfficePPT::Object)
if (topType == PT_Body && bottomType == PT_Object)
{
return _T("txOverObj");
return L"txOverObj";
}
return _T("objOverTx");
return L"objOverTx";
}
case 0x0A: //SL_ColumnTwoRows
case SL_ColumnTwoRows:
{
NSOfficePPT::PlaceholderEnum leftType = (NSOfficePPT::PlaceholderEnum)pPlaceholders[1];
ePlaceholderType leftType = (ePlaceholderType)pPlaceholders[1];
if (leftType == NSOfficePPT::Object)
if (leftType == PT_Object)
{
return _T("objAndTwoObj");
return L"objAndTwoObj";
}
return _T("txAndTwoObj");
return L"txAndTwoObj";
}
case 0x0B: //SL_TwoRowsColumn
case SL_TwoRowsColumn:
{
NSOfficePPT::PlaceholderEnum rightType = (NSOfficePPT::PlaceholderEnum)pPlaceholders[2];
ePlaceholderType rightType = (ePlaceholderType)pPlaceholders[2];
if (rightType == NSOfficePPT::Object)
if (rightType == PT_Object)
{
return _T("twoObjAndObj");
return L"twoObjAndObj";
}
return _T("twoObjAndTx");
return L"twoObjAndTx";
}
case 0x0D: //SL_TwoColumnsRow
return _T("twoObjOverTx");
case 0x0E://SL_FourObjects
return _T("fourObj");
case 0x0F: //SL_BigObject
//return _T("tx");
return _T("objOnly");
case 0x10: //SL_Blank
return _T("blank");
case 0x11: //SL_VerticalTitleBody
return _T("vertTitleAndTx");
case 0x12: //SL_VerticalTwoRows
return _T("vertTx");
case SL_TwoColumnsRow: return L"twoObjOverTx";
case SL_FourObjects: return L"fourObj";
case SL_BigObject: return L"objOnly";
case SL_Blank: return L"blank";
case SL_VerticalTitleBody: return L"vertTitleAndTx";
case SL_VerticalTwoRows: return L"vertTx";
}
return _T("blank");
return L"blank";
}
void AddAnimation (_UINT32 dwSlideID, double Width, double Height, CElementPtr pElement);
void AddAudioTransition (_UINT32 dwSlideID, CTransition* pTransition, const std::wstring& strFilePath);
int AddNewLayout(NSPresentationEditor::CTheme* pTheme, CRecordSlide* pRecordSlide, bool addShapes, bool bMasterObjects);
int AddNewLayout(PPT_FORMAT::CTheme* pTheme, CRecordSlide* pRecordSlide, bool addShapes, bool bMasterObjects);
CElementPtr AddNewLayoutPlaceholder (CLayout *pLayout, int placeholderType, int placeholderSizePreset = -1);

View File

@ -79,6 +79,7 @@ typedef BYTE BOOL1;
#define RECORD_TYPE_NAMEDSHOW 1041
#define RECORD_TYPE_NAMEDSHOW_SLIDES 1042
#define RECORD_TYPE_SHEET_PROPERTIES 1044
#define RECORD_TYPE_NORMALVIEW_SETINFO9 1045
#define RECORD_TYPE_ORIGINALMAINMASTERID 1052
#define RECORD_TYPE_COMPOSITEMASTERID 1053
@ -95,6 +96,7 @@ typedef BYTE BOOL1;
#define RECORD_TYPE_LIST 2000
#define RECORD_TYPE_FONTCOLLECTION 2005
#define RECORD_TYPE_FONTCOLLECTION10 2006
#define RECORD_TYPE_BOOKMARKCOLLECTION 2019
#define RECORD_TYPE_SOUNDCOLLECTION 2020
#define RECORD_TYPE_SOUNDCOLL_ATOM 2021
@ -381,6 +383,7 @@ static std::string GetRecordName(_UINT32 dwType)
case RECORD_TYPE_PERSISTPTRINCREMENTALBLOCK : { strName = ("PersistPtrIncrementalBlock"); break; }
case RECORD_TYPE_GSCALING_ATOM2 : { strName = ("GScalingAtom2"); break; }
case RECORD_TYPE_GRCOLOR_ATOM2 : { strName = ("GRColorAtom2"); break; }
case RECORD_TYPE_NORMALVIEW_SETINFO9 : { strName = ("NormalViewSetInfoAtom"); break; }
// Records ~12000 seem to be related to the Comments used in PPT 2000/XP
// (Comments in PPT97 are normal Escher text boxes)

View File

@ -36,9 +36,7 @@
#include "../../../ASCOfficeDocFile/DocDocxConverter/MemoryStream.h"
#include "../../../OfficeCryptReader/source/CryptTransform.h"
using namespace NSPresentationEditor;
namespace NSPresentationEditor
namespace PPT_FORMAT
{
static CColor GetStandartPaletteColor(int index)
{
@ -108,7 +106,7 @@ namespace NSPresentationEditor
namespace NSStreamReader
{
void Read(POLE::Stream* pStream, NSPresentationEditor::CTextSIRun& oRun, bool bIsIndentation)
void Read(POLE::Stream* pStream, PPT_FORMAT::CTextSIRun& oRun, bool bIsIndentation)
{
if (bIsIndentation)
{
@ -170,7 +168,7 @@ namespace NSStreamReader
}*/
}
void Read(POLE::Stream* pStream, NSPresentationEditor::CTextRuler& oRun)
void Read(POLE::Stream* pStream, PPT_FORMAT::CTextRuler& oRun)
{
double dScaleX = 625 * 2.54 ;
//1/576 inch = 72/576 pt = 360000 *72 * 2.54 /(72*576) emu
@ -237,7 +235,7 @@ namespace NSStreamReader
}
void CTextPFRun_ppt::LoadFromStream(POLE::Stream* pStream, bool bIsIndentation)
void CTextPFRunRecord::LoadFromStream(POLE::Stream* pStream, bool bIsIndentation)
{
double dScaleX = 625 * 2.54 ;
//1/576 inch = 72/576 pt = 360000 *72 * 2.54 /(72*576) emu
@ -345,7 +343,7 @@ void CTextPFRun_ppt::LoadFromStream(POLE::Stream* pStream, bool bIsIndentation)
SColorAtom oColorAtom;
NSStreamReader::Read(pStream, oColorAtom);
NSPresentationEditor::CColor oColor;
ODRAW::CColor oColor;
oColor.R = oColorAtom.R;
oColor.G = oColorAtom.G;
@ -356,7 +354,7 @@ void CTextPFRun_ppt::LoadFromStream(POLE::Stream* pStream, bool bIsIndentation)
if (oColorAtom.bSchemeIndex)
{
oColor.m_lSchemeIndex = oColorAtom.Index;
NSPresentationEditor::CorrectColorPPT(oColor.m_lSchemeIndex);
ODRAW::CorrectColorPPT(oColor.m_lSchemeIndex);
}
if (oColorAtom.bSchemeIndex || oColorAtom.bPaletteRGB)
@ -413,7 +411,7 @@ void CTextPFRun_ppt::LoadFromStream(POLE::Stream* pStream, bool bIsIndentation)
}
void CTextCFRun_ppt::LoadFromStream(POLE::Stream* pStream, bool bIsIndentation)
void CTextCFRunRecord::LoadFromStream(POLE::Stream* pStream, bool bIsIndentation)
{
if (bIsIndentation)
{
@ -474,13 +472,13 @@ void CTextCFRun_ppt::LoadFromStream(POLE::Stream* pStream, bool bIsIndentation)
m_oRun.fontRef = StreamUtils::ReadWORD(pStream);
if (EAFontRef_)
m_oRun.EAFontRef = StreamUtils::ReadWORD(pStream);
m_oRun.eaFontRef = StreamUtils::ReadWORD(pStream);
if (AnsiFontRef_)
m_oRun.AnsiFontRef = StreamUtils::ReadWORD(pStream);
m_oRun.ansiFontRef = StreamUtils::ReadWORD(pStream);
if (SymbolFontRef_)
m_oRun.SymbolFontRef = StreamUtils::ReadWORD(pStream);
m_oRun.symbolFontRef = StreamUtils::ReadWORD(pStream);
if (size_)
m_oRun.Size = StreamUtils::ReadWORD(pStream);
@ -490,7 +488,7 @@ void CTextCFRun_ppt::LoadFromStream(POLE::Stream* pStream, bool bIsIndentation)
SColorAtom oColorAtom;
NSStreamReader::Read(pStream, oColorAtom);
NSPresentationEditor::CColor oColor;
ODRAW::CColor oColor;
oColor.R = oColorAtom.R;
oColor.G = oColorAtom.G;
@ -501,7 +499,7 @@ void CTextCFRun_ppt::LoadFromStream(POLE::Stream* pStream, bool bIsIndentation)
if (oColorAtom.Index < 8 && oColorAtom.bSchemeIndex)
{
oColor.m_lSchemeIndex = oColorAtom.Index;
NSPresentationEditor::CorrectColorPPT(oColor.m_lSchemeIndex);
ODRAW::CorrectColorPPT(oColor.m_lSchemeIndex);
}
if (oColorAtom.bSchemeIndex || oColorAtom.bPaletteRGB)
{
@ -516,10 +514,10 @@ void CTextCFRun_ppt::LoadFromStream(POLE::Stream* pStream, bool bIsIndentation)
}
namespace NSPresentationEditor
namespace PPT_FORMAT
{
void ConvertPPTTextToEditorStructure(std::vector<CTextPFRun_ppt>& oArrayPF, std::vector<CTextCFRun_ppt>& oArrayCF,
std::wstring& strText, NSPresentationEditor::CTextAttributesEx& oAttributes)
void ConvertPPTTextToEditorStructure(std::vector<CTextPFRunRecord>& oArrayPF, std::vector<CTextCFRunRecord>& oArrayCF,
std::wstring& strText, PPT_FORMAT::CTextAttributesEx& oAttributes)
{
int nCountPFs = (int)oArrayPF.size();
int nCountCFs = (int)oArrayCF.size();
@ -536,7 +534,7 @@ namespace NSPresentationEditor
{
CParagraph elm;
oAttributes.m_arParagraphs.push_back(elm);
NSPresentationEditor::CParagraph* pPar = &oAttributes.m_arParagraphs[nIndexPF];
PPT_FORMAT::CParagraph* pPar = &oAttributes.m_arParagraphs[nIndexPF];
pPar->m_lTextLevel = oArrayPF[nIndexPF].m_lLevel;
pPar->m_oPFRun = oArrayPF[nIndexPF].m_oRun;
@ -564,7 +562,7 @@ namespace NSPresentationEditor
{
nOffsetCF += nCountInPF;
NSPresentationEditor::CSpan oSpan;
PPT_FORMAT::CSpan oSpan;
oSpan.m_oRun = oArrayCF[nCurrentCF].m_oRun;
nCountAddTrue = nCountInPF;
@ -586,7 +584,7 @@ namespace NSPresentationEditor
{
nOffsetCF = 0;
NSPresentationEditor::CSpan oSpan;
PPT_FORMAT::CSpan oSpan;
oSpan.m_oRun = oArrayCF[nCurrentCF].m_oRun;
if (nCountAddTrue > 0)
@ -602,7 +600,7 @@ namespace NSPresentationEditor
{
nOffsetCF = 0;
NSPresentationEditor::CSpan oSpan;
PPT_FORMAT::CSpan oSpan;
oSpan.m_oRun = oArrayCF[nCurrentCF].m_oRun;
if (nCountAddTrue > 0)

View File

@ -36,7 +36,7 @@
#include "../../../OfficeUtils/src/OfficeUtils.h"
using namespace NSPresentationEditor;
using namespace PPT_FORMAT;
namespace CRYPT
{
@ -285,27 +285,27 @@ namespace NSStreamReader
}
}
void Read(POLE::Stream* pStream, NSPresentationEditor::CTextSIRun& oRun, bool bIsIndentation = true);
void Read(POLE::Stream* pStream, NSPresentationEditor::CTextRuler& oRun);
void Read(POLE::Stream* pStream, PPT_FORMAT::CTextSIRun& oRun, bool bIsIndentation = true);
void Read(POLE::Stream* pStream, PPT_FORMAT::CTextRuler& oRun);
}
class CTextPFRun_ppt
class CTextPFRunRecord
{
public:
NSPresentationEditor::CTextPFRun m_oRun;
LONG m_lLevel;
LONG m_lCount;
PPT_FORMAT::CTextPFRun m_oRun;
LONG m_lLevel;
LONG m_lCount;
CTextPFRun_ppt() : m_oRun()
CTextPFRunRecord() : m_oRun()
{
m_lLevel = -1;
m_lCount = 0;
}
CTextPFRun_ppt(const CTextPFRun_ppt& oSrc)
CTextPFRunRecord(const CTextPFRunRecord& oSrc)
{
*this = oSrc;
}
CTextPFRun_ppt& operator=(const CTextPFRun_ppt& oSrc)
CTextPFRunRecord& operator=(const CTextPFRunRecord& oSrc)
{
m_oRun = oSrc.m_oRun;
m_lLevel = oSrc.m_lLevel;
@ -316,21 +316,21 @@ public:
void LoadFromStream(POLE::Stream* pStream, bool bIsIndentation = true);
};
class CTextCFRun_ppt
class CTextCFRunRecord
{
public:
NSPresentationEditor::CTextCFRun m_oRun;
LONG m_lCount;
PPT_FORMAT::CTextCFRun m_oRun;
LONG m_lCount;
CTextCFRun_ppt() : m_oRun()
CTextCFRunRecord() : m_oRun()
{
m_lCount = 0;
}
CTextCFRun_ppt(const CTextCFRun_ppt& oSrc)
CTextCFRunRecord(const CTextCFRunRecord& oSrc)
{
*this = oSrc;
}
CTextCFRun_ppt& operator=(const CTextCFRun_ppt& oSrc)
CTextCFRunRecord& operator=(const CTextCFRunRecord& oSrc)
{
m_oRun = oSrc.m_oRun;
m_lCount = oSrc.m_lCount;
@ -340,8 +340,8 @@ public:
void LoadFromStream(POLE::Stream* pStream, bool bIsIndentation = true);
};
namespace NSPresentationEditor
namespace PPT_FORMAT
{
void ConvertPPTTextToEditorStructure(std::vector<CTextPFRun_ppt>& oArrayPF, std::vector<CTextCFRun_ppt>& oArrayCF,
std::wstring& strText, NSPresentationEditor::CTextAttributesEx& oAttributes);
void ConvertPPTTextToEditorStructure(std::vector<CTextPFRunRecord>& oArrayPF, std::vector<CTextCFRunRecord>& oArrayCF,
std::wstring& strText, PPT_FORMAT::CTextAttributesEx& oAttributes);
}

View File

@ -167,12 +167,14 @@ IRecord* CreateByType(SRecordHeader oHeader)
{
CREATE_BY_TYPE(RECORD_TYPE_SLIDELISTWITHTEXT , CRecordSlideListWithText)
CREATE_BY_TYPE(RECORD_TYPE_DOCUMENT_ATOM , CRecordDocumentAtom)
//CREATE_BY_TYPE(RECORD_TYPE_ENDDOCUMENT , CRecordEndDocument)
CREATE_BY_TYPE(RECORD_TYPE_ENDDOCUMENT , CRecordEndDocument)
//CREATE_BY_TYPE(RECORD_TYPE_SSLIDE_LAYOUT_ATOM , CRecordSSlideLayoutAtom)
CREATE_BY_TYPE(RECORD_TYPE_SLIDE_ATOM , CRecordSlideAtom)
CREATE_BY_TYPE(RECORD_TYPE_NOTES_ATOM , CRecordNotesAtom)
CREATE_BY_TYPE(RECORD_TYPE_SLIDE_PERSIST_ATOM , CRecordSlidePersistAtom)
CREATE_BY_TYPE(RECORD_TYPE_ENVIRONMENT , CRecordDocumentTextInfo)
CREATE_BY_TYPE(RECORD_TYPE_FONTCOLLECTION , CRecordFontCollection)
CREATE_BY_TYPE(RECORD_TYPE_FONTCOLLECTION10 , CRecordFontCollection)
//CREATE_BY_TYPE(RECORD_TYPE_UNKNOWN , CRecordMasterPersistAtom)
//CREATE_BY_TYPE(RECORD_TYPE_UNKNOWN , CRecordNotesPersistAtom)
CREATE_BY_TYPE(RECORD_TYPE_SSSLIDE_INFO_ATOM , CSlideShowSlideInfoAtom)
@ -182,7 +184,7 @@ IRecord* CreateByType(SRecordHeader oHeader)
CREATE_BY_TYPE(RECORD_TYPE_VIEWINFO_ATOM , CRecordViewInfoAtom)
CREATE_BY_TYPE(RECORD_TYPE_SLIDE_VIEWINFO_ATOM , CRecordSlideViewInfoAtom)
CREATE_BY_TYPE(RECORD_TYPE_VBAINFO_ATOM , CRecordVBAInfoAtom)
//CREATE_BY_TYPE(RECORD_TYPE_SSDOCINFO_ATOM , CRecordSSDocInfoAtom)
CREATE_BY_TYPE(RECORD_TYPE_SSDOCINFO_ATOM , CRecordSSDocInfoAtom)
//CREATE_BY_TYPE(RECORD_TYPE_DOC_ROUTING_SLIP , CRecordDocRoutingSlipAtom)
CREATE_BY_TYPE(RECORD_TYPE_EXOBJLIST_ATOM , CRecordExObjListAtom)
//CREATE_BY_TYPE(RECORD_TYPE_UNKNOWN , CRecordGridSpacing10Atom)
@ -204,11 +206,9 @@ IRecord* CreateByType(SRecordHeader oHeader)
CREATE_BY_TYPE(RECORD_TYPE_ROUNDTRIPNOTESMASTERTEXTSTYLES12 , CRecordRoundTripNotesMasterTextStyles12Atom)
//CREATE_BY_TYPE(RECORD_TYPE_ROUNDTRIPDOCFLAGS12 , CRecordRoundTripDocFlags12Atom)
//CREATE_BY_TYPE(RECORD_TYPE_ROUNDTRIPSHAPECHECKSUMFORCUSTOMLAYOUTS12 , CRecordRoundTripShapeCheckSumForCustomLayouts12Atom)
//CREATE_BY_TYPE(RECORD_TYPE_ROUNDTRIPCUSTOMTABLESTYLES12 , CRecordRoundTripCustomTableStyles12Atom)
CREATE_BY_TYPE(RECORD_TYPE_ROUNDTRIPCUSTOMTABLESTYLES12 , CRecordRoundTripCustomTableStyles12Atom)
//CREATE_BY_TYPE(RECORD_TYPE_BOOKMARK_SEED_ATOM , CRecordBookmarkSeedAtom)
//CREATE_BY_TYPE(RECORD_TYPE_COLOR_SCHEME_ATOM , CRecordSlideColorSchemeAtom)
//CREATE_BY_TYPE(RECORD_TYPE_UNKNOWN, CRecordSchemeListElementColorSchemeAtom)
//CREATE_BY_TYPE(RECORD_TYPE_UNKNOWN, CRecordBlipEntityAtom)
//CREATE_BY_TYPE(RECORD_TYPE_UNKNOWN, CRecordExObjRefAtom)
CREATE_BY_TYPE(RECORD_TYPE_OEPLACEHOLDER_ATOM , CRecordPlaceHolderAtom)
@ -236,7 +236,7 @@ IRecord* CreateByType(SRecordHeader oHeader)
CREATE_BY_TYPE(RECORD_TYPE_GUIDE_ATOM , CRecordGuideAtom)
CREATE_BY_TYPE(RECORD_TYPE_FONTENTITY_ATOM , CRecordFontEntityAtom)
//CREATE_BY_TYPE(RECORD_TYPE_FONT_EMBEDDEDDATA , CRecordFontEmbedDataBlob)
CREATE_BY_TYPE(RECORD_TYPE_FONT_EMBEDDEDDATA , CRecordFontEmbedDataBlob)
//CREATE_BY_TYPE(RECORD_TYPE_METAFILE , CRecordMetafileBlob)
CREATE_BY_TYPE(RECORD_TYPE_CSTRING , CRecordCString)
CREATE_BY_TYPE(RECORD_TYPE_SOUNDCOLL_ATOM , CRecordSoundCollAtom)
@ -245,7 +245,7 @@ IRecord* CreateByType(SRecordHeader oHeader)
//CREATE_BY_TYPE(RECORD_TYPE_BOOKMARK_ENTITY_ATOM , CRecordBookmarkEntityAtom)
//CREATE_BY_TYPE(RECORD_TYPE_EXLINK_ATOM , CRecordExOleLinkAtom)
//CREATE_BY_TYPE(RECORD_TYPE_SRKINSOKU_ATOM , CRecordKinsokuAtom)
CREATE_BY_TYPE(RECORD_TYPE_SRKINSOKU_ATOM , CRecordKinsokuAtom)
CREATE_BY_TYPE(RECORD_TYPE_EXHYPERLINK , CRecordExHyperlinkContainer)
CREATE_BY_TYPE(RECORD_TYPE_EXHYPERLINK_ATOM , CRecordExHyperlinkAtom)
@ -283,7 +283,9 @@ IRecord* CreateByType(SRecordHeader oHeader)
CREATE_BY_TYPE(RECORD_TYPE_ESCHER_SECONDARY_OPT , CRecordShapeProperties)
CREATE_BY_TYPE(RECORD_TYPE_ESCHER_TETRIARY_OPT , CRecordShapeProperties)
CREATE_BY_TYPE(RECORD_TYPE_ESCHER_REGROUPITEMS , CRecordRegGroupItems)
CREATE_BY_TYPE(RECORD_TYPE_ESCHER_SPLITMENUCOLORS , CRecordSplitMenuColorRecord)
CREATE_BY_TYPE(RECORD_TYPE_ESCHER_COLORMRU , CRecordMostRecentlyUserColors)
CREATE_BY_TYPE(RECORD_TYPE_EX_CDAUDIO , CRecordExCDAudioContainer)
CREATE_BY_TYPE(RECORD_TYPE_EX_WAVAUDIOLINK , CRecordWAVAudioLinkContainer)
CREATE_BY_TYPE(RECORD_TYPE_EX_WAVAUDIOEMBEDDED , CRecordWAVAudioEmbeddedContainer)
@ -318,7 +320,7 @@ IRecord* CreateByType(SRecordHeader oHeader)
pRecord = new CUnknownRecord();
#ifdef _DEBUG
char str[1024]={};
sprintf(str, "Unknown record type: %xd\t" , oHeader.RecType);
sprintf(str, "Unknown record type: %x\t" , oHeader.RecType);
std::cout << str << GetRecordName((_UINT32)oHeader.RecType) << "\n";
#endif
}

View File

@ -38,7 +38,9 @@
#include "../../../Common/3dParty/pole/pole.h"
#include "../../../OfficeCryptReader/source/CryptTransform.h"
using namespace NSPresentationEditor;
#include <boost/smart_ptr/shared_array.hpp>
using namespace PPT_FORMAT;
using namespace XLS;
class SRecordHeader
@ -249,7 +251,6 @@ public:
/*
class CRecordDocument : public CRecordsContainer {};
class CRecordEnvironment : public CRecordsContainer {};
class CRecordExAviMovie : public CRecordsContainer {};
class CRecordExCDAudio : public CRecordsContainer {};
class CRecordExControl : public CRecordsContainer {};
@ -265,7 +266,6 @@ class CRecordExQuickTimeMovie : public CRecordsContainer {};
class CRecordExVideo : public CRecordsContainer {};
class CRecordExWAVAudioEmbedded : public CRecordsContainer {};
class CRecordExWAVAudioLink : public CRecordsContainer {};
class CRecordFontCollection : public CRecordsContainer {};
class CRecordFontCollection10 : public CRecordsContainer {};
class CRecordHandout : public CRecordsContainer {};
class CRecordHeadersFooters : public CRecordsContainer {};

View File

@ -83,7 +83,7 @@ public:
std::map<LONG, CElementInfo> m_mapElements;
std::vector<int>* m_parEmptyPictures;
std::map<int, std::wstring>* m_mapFilePictures;
nullable_base<NSPresentationEditor::CTextStyles> m_pStyles[9];
nullable_base<PPT_FORMAT::CTextStyles> m_pStyles[9];
CSlideInfo()
{

View File

@ -34,8 +34,6 @@
class CRecordAnimationInfoAtom : public CUnknownRecord
{
// поля...
public:
CRecordAnimationInfoAtom()

View File

@ -2878,7 +2878,7 @@ namespace Animations
namespace Animations
{
typedef NSPresentationEditor::CAnimationSimple Effect;
typedef PPT_FORMAT::CAnimationSimple Effect;
typedef std::vector <Effect> Effects;
typedef std::map<_UINT32,Effects*> EffectsMap;
typedef std::vector <double> TimeArray;

View File

@ -34,10 +34,9 @@
class CRecordBlipEntityAtom : public CUnknownRecord
{
BYTE m_nWinBlipType;
BYTE* m_pImage;
public:
BYTE m_nWinBlipType;
std::pair<boost::shared_array<unsigned char>, _INT32> data;
CRecordBlipEntityAtom()
{

View File

@ -34,10 +34,9 @@
class CRecordBookmarkEntityAtom : public CUnknownRecord
{
public:
UINT m_nID;
std::wstring m_strName;
public:
CRecordBookmarkEntityAtom()
{

View File

@ -34,9 +34,8 @@
class CRecordBookmarkSeedAtom : public CUnknownRecord
{
INT m_nBookmarkID;
public:
INT m_nBookmarkID;
CRecordBookmarkSeedAtom()
{

View File

@ -34,6 +34,7 @@
class CRecordDocRoutingSlipAtom : public CUnknownRecord
{
public:
struct SDocRoutingSlipAtom
{
USHORT m_nType;
@ -50,8 +51,6 @@ class CRecordDocRoutingSlipAtom : public CUnknownRecord
SDocRoutingSlipAtom m_oRgRecipientRoutingSlipStrings;
SDocRoutingSlipAtom m_oSubjectString;
SDocRoutingSlipAtom m_oMessageString;
public:
CRecordDocRoutingSlipAtom()
{

View File

@ -43,8 +43,8 @@ public:
UINT m_nNotesMasterPersistIDRef;
UINT m_nHandoutMasterPersistIDRef;
USHORT m_nFirstSlideNum;
NSOfficePPT::SlideSizeType m_nSlideSizeType;
USHORT m_nFirstSlideNum;
USHORT m_nSlideSizeType;
BOOL1 m_bSaveWithFonts;
BOOL1 m_bOmitTitlePlace;
@ -78,12 +78,12 @@ public:
m_nHandoutMasterPersistIDRef = (UINT)StreamUtils::ReadDWORD(pStream);
m_nFirstSlideNum = StreamUtils::ReadWORD(pStream);
m_nSlideSizeType = (NSOfficePPT::SlideSizeType)StreamUtils::ReadWORD(pStream);
m_nSlideSizeType = StreamUtils::ReadWORD(pStream);
m_bSaveWithFonts = StreamUtils::ReadBYTE(pStream);
m_bOmitTitlePlace = StreamUtils::ReadBYTE(pStream);
m_bRightToLeft = StreamUtils::ReadBYTE(pStream);
m_bShowComments = StreamUtils::ReadBYTE(pStream);
m_bSaveWithFonts = StreamUtils::ReadBYTE(pStream);
m_bOmitTitlePlace = StreamUtils::ReadBYTE(pStream);
m_bRightToLeft = StreamUtils::ReadBYTE(pStream);
m_bShowComments = StreamUtils::ReadBYTE(pStream);
}
};

View File

@ -49,4 +49,23 @@ public:
CRecordsContainer::ReadFromStream(oHeader, pStream);
}
};
};
class CRecordFontCollection : public CRecordsContainer
{
public:
CRecordFontCollection()
{
}
~CRecordFontCollection()
{
}
virtual void ReadFromStream(SRecordHeader & oHeader, POLE::Stream* pStream)
{
CRecordsContainer::ReadFromStream(oHeader, pStream);
}
};

View File

@ -59,12 +59,11 @@ public:
class CRecordBitmapBlip : public CUnknownRecord
{
public:
BYTE m_pRgbUid[16];
BYTE m_nTag;
BYTE* m_pScan0;
public:
//BYTE* m_pScan0;
CRecordBitmapBlip()
{

View File

@ -35,8 +35,8 @@
class CRecordBlipStoreEntry : public CUnknownRecord
{
public:
NSOfficeDrawing::BlipType m_btWin32;
NSOfficeDrawing::BlipType m_btMacOS;
ODRAW::eBlipType m_btWin32;
ODRAW::eBlipType m_btMacOS;
BYTE m_pRgbUid[16];
unsigned short m_nTag;
@ -44,7 +44,7 @@ public:
_UINT32 m_nCountRef;
_UINT32 m_nFoDelay;
NSOfficeDrawing::BlipUsage m_eUsage;
ODRAW::eBlipUsage m_eUsage;
BYTE m_nLenName;
BYTE m_nUnused2;
@ -62,8 +62,8 @@ public:
{
m_oHeader = oHeader;
m_btWin32 = (NSOfficeDrawing::BlipType)StreamUtils::ReadBYTE(pStream);
m_btMacOS = (NSOfficeDrawing::BlipType)StreamUtils::ReadBYTE(pStream);
m_btWin32 = (ODRAW::eBlipType)StreamUtils::ReadBYTE(pStream);
m_btMacOS = (ODRAW::eBlipType)StreamUtils::ReadBYTE(pStream);
pStream->read(m_pRgbUid, 16);
@ -73,7 +73,7 @@ public:
m_nCountRef = StreamUtils::ReadDWORD(pStream);
m_nFoDelay = StreamUtils::ReadDWORD(pStream);
m_eUsage = (NSOfficeDrawing::BlipUsage)StreamUtils::ReadBYTE(pStream);
m_eUsage = (ODRAW::eBlipUsage)StreamUtils::ReadBYTE(pStream);
m_nLenName = StreamUtils::ReadBYTE(pStream);

View File

@ -48,4 +48,5 @@ public:
{
CRecordsContainer::ReadFromStream(oHeader, pStream);
}
};
};

View File

@ -43,9 +43,6 @@
#define FIXED_POINT_unsigned(val) (double)((WORD)(val >> 16) + ((WORD)(val) / 65536.0))
using namespace NSOfficeDrawing;
using namespace NSPresentationEditor;
bool CPPTElement::ChangeBlack2ColorImage(std::wstring image_path, int rgbColor1, int rgbColor2)
{
CBgraFrame bgraFrame;
@ -205,7 +202,7 @@ void CPPTElement::SetUpProperties(CElementPtr pElement, CTheme* pTheme, CSlideIn
long lCount = pProperties->m_lCount;
switch (pElement->m_etType)
{
case NSPresentationEditor::etVideo:
case PPT_FORMAT::etVideo:
{
pElement->m_bLine = false;
for (long i = 0; i < lCount; ++i)
@ -214,7 +211,7 @@ void CPPTElement::SetUpProperties(CElementPtr pElement, CTheme* pTheme, CSlideIn
}
break;
}
case NSPresentationEditor::etPicture:
case PPT_FORMAT::etPicture:
{
pElement->m_oBrush.Type = c_BrushTypeTexture;
pElement->m_bLine = false;
@ -224,7 +221,7 @@ void CPPTElement::SetUpProperties(CElementPtr pElement, CTheme* pTheme, CSlideIn
}
break;
}
case NSPresentationEditor::etAudio:
case PPT_FORMAT::etAudio:
{
pElement->m_bLine = false;
for (long i = 0; i < lCount; ++i)
@ -233,7 +230,7 @@ void CPPTElement::SetUpProperties(CElementPtr pElement, CTheme* pTheme, CSlideIn
}
break;
}
case NSPresentationEditor::etGroup:
case PPT_FORMAT::etGroup:
{
pElement->m_bLine = false;
pElement->m_bIsFilled = false;
@ -242,7 +239,7 @@ void CPPTElement::SetUpProperties(CElementPtr pElement, CTheme* pTheme, CSlideIn
SetUpProperty(pElement, pTheme, pWrapper, pSlide, &pProperties->m_arProperties[i]);
}
}break;
case NSPresentationEditor::etShape:
case PPT_FORMAT::etShape:
{
CShapeElement* pShapeElem = dynamic_cast<CShapeElement*>(pElement.get());
CPPTShape* pPPTShape = dynamic_cast<CPPTShape*>(pShapeElem->m_pShape->getBaseShape().get());
@ -321,29 +318,29 @@ void CPPTElement::SetUpProperty(CElementPtr pElement, CTheme* pTheme, CSlideInfo
_UINT32 dwType = pProperty->m_lValue;
switch(dwType)
{
case NSOfficeDrawing::fillPattern:
case ODRAW::fillPattern:
{
pElement->m_oBrush.Type = c_BrushTypePattern;
//texture + change black to color2, white to color1
}break;
case NSOfficeDrawing::fillTexture :
case NSOfficeDrawing::fillPicture :
case ODRAW::fillTexture :
case ODRAW::fillPicture :
{
pElement->m_oBrush.Type = c_BrushTypeTexture;
pElement->m_oBrush.TextureMode = (NSOfficeDrawing::fillPicture == dwType) ? c_BrushTextureModeStretch : c_BrushTextureModeTile;
pElement->m_oBrush.TextureMode = (ODRAW::fillPicture == dwType) ? c_BrushTextureModeStretch : c_BrushTextureModeTile;
}break;
case NSOfficeDrawing::fillShadeCenter://1 color
case NSOfficeDrawing::fillShadeShape:
case ODRAW::fillShadeCenter://1 color
case ODRAW::fillShadeShape:
{
pElement->m_oBrush.Type = c_BrushTypeCenter;
}break;//
case NSOfficeDrawing::fillShadeTitle://2 colors and more
case NSOfficeDrawing::fillShade :
case NSOfficeDrawing::fillShadeScale:
case ODRAW::fillShadeTitle://2 colors and more
case ODRAW::fillShade :
case ODRAW::fillShadeScale:
{
pElement->m_oBrush.Type = c_BrushTypePathGradient1;
}break;
case NSOfficeDrawing::fillBackground:
case ODRAW::fillBackground:
{
pElement->m_oBrush.Type = c_BrushTypeNoFill;
}break;
@ -532,7 +529,7 @@ void CPPTElement::SetUpProperty(CElementPtr pElement, CTheme* pTheme, CSlideInfo
break;
}
case NSOfficeDrawing::geoBoolean:
case ODRAW::geoBoolean:
{
BYTE flag1 = (BYTE)(pProperty->m_lValue);
BYTE flag2 = (BYTE)(pProperty->m_lValue >> 8);
@ -821,7 +818,7 @@ void CPPTElement::SetUpPropertyImage(CElementPtr pElement, CTheme* pTheme, CSlid
switch(pProperty->m_ePID)
{
case Pib:
case pib:
{
int dwOffset = pInfo->GetIndexPicture(pProperty->m_lValue);
if (dwOffset >=0)
@ -881,7 +878,7 @@ void CPPTElement::SetUpPropertyShape(CElementPtr pElement, CTheme* pTheme, CSlid
switch (pProperty->m_ePID)
{
case NSOfficeDrawing::metroBlob:
case ODRAW::metroBlob:
{
NSFile::CFileBinary file;
@ -911,22 +908,22 @@ void CPPTElement::SetUpPropertyShape(CElementPtr pElement, CTheme* pTheme, CSlid
}
NSFile::CFileBinary::Remove(tempFileName);
}break;
case NSOfficeDrawing::geoRight:
case ODRAW::geoRight:
{
if (0 < pProperty->m_lValue)
pParentShape->m_dWidthLogic = (double)(pProperty->m_lValue);
}break;
case NSOfficeDrawing::geoBottom:
case ODRAW::geoBottom:
{
if (0 < pProperty->m_lValue)
pParentShape->m_dHeightLogic = (double)(pProperty->m_lValue);
}break;
case NSOfficeDrawing::shapePath:
case ODRAW::shapePath:
{
pShape->m_oCustomVML.SetPath((RulesType)pProperty->m_lValue);
pShape->m_bCustomShape = true;
}break;
case NSOfficeDrawing::pSegmentInfo:
case ODRAW::pSegmentInfo:
{
if (pProperty->m_bComplex)
{
@ -934,7 +931,7 @@ void CPPTElement::SetUpPropertyShape(CElementPtr pElement, CTheme* pTheme, CSlid
pShape->m_bCustomShape = true;
}
}break;
case NSOfficeDrawing::pVertices:
case ODRAW::pVertices:
{
if (pProperty->m_bComplex)
{
@ -942,53 +939,53 @@ void CPPTElement::SetUpPropertyShape(CElementPtr pElement, CTheme* pTheme, CSlid
pShape->m_bCustomShape = true;
}
}break;
case NSOfficeDrawing::pConnectionSites:
case ODRAW::pConnectionSites:
{
if (pProperty->m_bComplex)
{
pShape->m_oCustomVML.LoadConnectionSites(pProperty);
}
}break;
case NSOfficeDrawing::pConnectionSitesDir:
case ODRAW::pConnectionSitesDir:
{
if (pProperty->m_bComplex)
{
pShape->m_oCustomVML.LoadConnectionSitesDir(pProperty);
}
}break;
case NSOfficeDrawing::pGuides:
case ODRAW::pGuides:
{
if (pProperty->m_bComplex/* && pShape->m_eType != sptNotchedCircularArrow*/)
{//Тікбұрышты үшбұрыштарды.ppt - slide 25
pShape->m_oCustomVML.LoadGuides(pProperty);
}
}break;
case NSOfficeDrawing::pInscribe:
case ODRAW::pInscribe:
{
if (pProperty->m_bComplex)
{
pShape->m_oCustomVML.LoadInscribe(pProperty);
}
}break;
case NSOfficeDrawing::pAdjustHandles:
case ODRAW::pAdjustHandles:
{
if (pProperty->m_bComplex)
{
pShape->m_oCustomVML.LoadAHs(pProperty);
}
}break;
case NSOfficeDrawing::adjustValue:
case NSOfficeDrawing::adjust2Value:
case NSOfficeDrawing::adjust3Value:
case NSOfficeDrawing::adjust4Value:
case NSOfficeDrawing::adjust5Value:
case NSOfficeDrawing::adjust6Value:
case NSOfficeDrawing::adjust7Value:
case NSOfficeDrawing::adjust8Value:
case NSOfficeDrawing::adjust9Value:
case NSOfficeDrawing::adjust10Value:
case ODRAW::adjustValue:
case ODRAW::adjust2Value:
case ODRAW::adjust3Value:
case ODRAW::adjust4Value:
case ODRAW::adjust5Value:
case ODRAW::adjust6Value:
case ODRAW::adjust7Value:
case ODRAW::adjust8Value:
case ODRAW::adjust9Value:
case ODRAW::adjust10Value:
{
LONG lIndexAdj = pProperty->m_ePID - NSOfficeDrawing::adjustValue;
LONG lIndexAdj = pProperty->m_ePID - ODRAW::adjustValue;
if (lIndexAdj >= 0 && lIndexAdj < (LONG)pShape->m_arAdjustments.size())
{
pShape->m_oCustomVML.LoadAdjusts(lIndexAdj, (LONG)pProperty->m_lValue);
@ -1002,27 +999,27 @@ void CPPTElement::SetUpPropertyShape(CElementPtr pElement, CTheme* pTheme, CSlid
case lTxid:
{
}break;
case NSOfficeDrawing::dxTextLeft:
case ODRAW::dxTextLeft:
{
pParentShape->m_dTextMarginX = pProperty->m_lValue;
}break;
case NSOfficeDrawing::dxTextRight:
case ODRAW::dxTextRight:
{
pParentShape->m_dTextMarginRight = pProperty->m_lValue;
}break;
case NSOfficeDrawing::dyTextTop:
case ODRAW::dyTextTop:
{
pParentShape->m_dTextMarginY = pProperty->m_lValue;
}break;
case NSOfficeDrawing::dyTextBottom:
case ODRAW::dyTextBottom:
{
pParentShape->m_dTextMarginBottom = pProperty->m_lValue;
}break;
case NSOfficeDrawing::WrapText:
case ODRAW::WrapText:
{
pParentShape->m_oText.m_lWrapMode = (LONG)pProperty->m_lValue;
}break;
case NSOfficeDrawing::gtextUNICODE://word art text
case ODRAW::gtextUNICODE://word art text
{
if (pProperty->m_bComplex && 0 < pProperty->m_lValue)
{
@ -1037,15 +1034,15 @@ void CPPTElement::SetUpPropertyShape(CElementPtr pElement, CTheme* pTheme, CSlid
if (str.at(i) > 13 ) break;
length--;
}
NSPresentationEditor::CParagraph p;
NSPresentationEditor::CSpan s;
PPT_FORMAT::CParagraph p;
PPT_FORMAT::CSpan s;
s.m_strText = str.substr(0,length);
p.m_arSpans.push_back(s);
pParentShape->m_oText.m_arParagraphs.push_back(p);
}
}
}break;
case NSOfficeDrawing::gtextFont:
case ODRAW::gtextFont:
{
if (pProperty->m_bComplex && 0 < pProperty->m_lValue)
{
@ -1053,48 +1050,48 @@ void CPPTElement::SetUpPropertyShape(CElementPtr pElement, CTheme* pTheme, CSlid
pParentShape->m_oText.m_oAttributes.m_oFont.Name = str;
}
}break;
case NSOfficeDrawing::gtextSize:
case ODRAW::gtextSize:
{
pParentShape->m_oText.m_oAttributes.m_oFont.Size = (INT)((pProperty->m_lValue >> 16) & 0x0000FFFF);
break;
}
case NSOfficeDrawing::anchorText:
case ODRAW::anchorText:
{
switch (pProperty->m_lValue)
{
case NSOfficeDrawing::anchorTop:
case NSOfficeDrawing::anchorTopBaseline:
case ODRAW::anchorTop:
case ODRAW::anchorTopBaseline:
{
pParentShape->m_oText.m_oAttributes.m_nTextAlignVertical = 0;
break;
}
case NSOfficeDrawing::anchorMiddle:
case ODRAW::anchorMiddle:
{
pParentShape->m_oText.m_oAttributes.m_nTextAlignVertical = 1;
break;
}
case NSOfficeDrawing::anchorBottom:
case NSOfficeDrawing::anchorBottomBaseline:
case ODRAW::anchorBottom:
case ODRAW::anchorBottomBaseline:
{
pParentShape->m_oText.m_oAttributes.m_nTextAlignHorizontal = 0;
pParentShape->m_oText.m_oAttributes.m_nTextAlignVertical = 2;
break;
}
case NSOfficeDrawing::anchorTopCentered:
case NSOfficeDrawing::anchorTopCenteredBaseline:
case ODRAW::anchorTopCentered:
case ODRAW::anchorTopCenteredBaseline:
{
pParentShape->m_oText.m_oAttributes.m_nTextAlignHorizontal = 1;
pParentShape->m_oText.m_oAttributes.m_nTextAlignVertical = 0;
break;
}
case NSOfficeDrawing::anchorMiddleCentered:
case ODRAW::anchorMiddleCentered:
{
pParentShape->m_oText.m_oAttributes.m_nTextAlignHorizontal = 1;
pParentShape->m_oText.m_oAttributes.m_nTextAlignVertical = 1;
break;
}
case NSOfficeDrawing::anchorBottomCentered:
case NSOfficeDrawing::anchorBottomCenteredBaseline:
case ODRAW::anchorBottomCentered:
case ODRAW::anchorBottomCenteredBaseline:
{
pParentShape->m_oText.m_oAttributes.m_nTextAlignHorizontal = 1;
pParentShape->m_oText.m_oAttributes.m_nTextAlignVertical = 2;
@ -1109,19 +1106,19 @@ void CPPTElement::SetUpPropertyShape(CElementPtr pElement, CTheme* pTheme, CSlid
};
break;
}
case NSOfficeDrawing::gtextAlign:
case ODRAW::gtextAlign:
{
switch (pProperty->m_lValue)
{
case NSOfficeDrawing::alignTextLeft:
case ODRAW::alignTextLeft:
{
pParentShape->m_oText.m_oAttributes.m_nTextAlignHorizontal = 0;
}break;
case NSOfficeDrawing::alignTextCenter:
case ODRAW::alignTextCenter:
{
pParentShape->m_oText.m_oAttributes.m_nTextAlignHorizontal = 1;
}break;
case NSOfficeDrawing::alignTextRight:
case ODRAW::alignTextRight:
{
pParentShape->m_oText.m_oAttributes.m_nTextAlignHorizontal = 2;
}break;
@ -1132,7 +1129,7 @@ void CPPTElement::SetUpPropertyShape(CElementPtr pElement, CTheme* pTheme, CSlid
};
break;
}
case NSOfficeDrawing::gtextBoolean:
case ODRAW::gtextBoolean:
{
// вот здесь - нужно единицы перевести в пикселы
BYTE flag1 = (BYTE)(pProperty->m_lValue);
@ -1182,7 +1179,7 @@ void CPPTElement::SetUpPropertyShape(CElementPtr pElement, CTheme* pTheme, CSlid
pParentShape->m_oText.m_bVertical = (true == bVertical) ? true : false;
}
}break;
case NSOfficeDrawing::cdirFont:
case ODRAW::cdirFont:
{
switch (pProperty->m_lValue)
{
@ -1198,11 +1195,11 @@ void CPPTElement::SetUpPropertyShape(CElementPtr pElement, CTheme* pTheme, CSlid
break;
}
}break;
case NSOfficeDrawing::txflTextFlow:
case ODRAW::txflTextFlow:
{
pParentShape->m_oText.m_nTextFlow = pProperty->m_lValue;
}break;
case NSOfficeDrawing::textBoolean:
case ODRAW::textBoolean:
{
BYTE flag1 = (BYTE)(pProperty->m_lValue);
BYTE flag2 = (BYTE)(pProperty->m_lValue >> 8);
@ -1231,35 +1228,35 @@ void CPPTElement::SetUpPropertyShape(CElementPtr pElement, CTheme* pTheme, CSlid
pParentShape->m_oText.m_bAutoFit = bFitShapeToText;
}break;
case NSOfficeDrawing::c3DSpecularAmt:
case ODRAW::c3DSpecularAmt:
{
pShape->m_o3dOptions.dSpecularAmt = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DDiffuseAmt:
case ODRAW::c3DDiffuseAmt:
{
pShape->m_o3dOptions.dDiffuseAmt = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DShininess:
case ODRAW::c3DShininess:
{
pShape->m_o3dOptions.dShininess = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DEdgeThickness:
case ODRAW::c3DEdgeThickness:
{
pShape->m_o3dOptions.nEdgeThickness = pProperty->m_lValue;
}break;
case NSOfficeDrawing::C3DExtrudeForward:
case ODRAW::C3DExtrudeForward:
{
pShape->m_o3dOptions.nExtrudeForward = pProperty->m_lValue;
}break;
case NSOfficeDrawing::c3DExtrudeBackward:
case ODRAW::c3DExtrudeBackward:
{
pShape->m_o3dOptions.nExtrudeBackward = pProperty->m_lValue;
}break;
case NSOfficeDrawing::c3DExtrudePlane:
case ODRAW::c3DExtrudePlane:
{
//ExtrudePlane = 0;
}break;
case NSOfficeDrawing::c3DExtrusionColor:
case ODRAW::c3DExtrusionColor:
{
SColorAtom oAtom;
oAtom.FromValue(pProperty->m_lValue);
@ -1270,7 +1267,7 @@ void CPPTElement::SetUpPropertyShape(CElementPtr pElement, CTheme* pTheme, CSlid
pShape->m_o3dOptions.oExtrusionColor = tmp;
}break;
case NSOfficeDrawing::c3DCrMod:
case ODRAW::c3DCrMod:
{
SColorAtom oAtom;
oAtom.FromValue(pProperty->m_lValue);
@ -1281,7 +1278,7 @@ void CPPTElement::SetUpPropertyShape(CElementPtr pElement, CTheme* pTheme, CSlid
pShape->m_o3dOptions.oCrMod = tmp;
}break;
case NSOfficeDrawing::c3DExtrusionColorExt:
case ODRAW::c3DExtrusionColorExt:
{
SColorAtom oAtom;
oAtom.FromValue(pProperty->m_lValue);
@ -1291,35 +1288,35 @@ void CPPTElement::SetUpPropertyShape(CElementPtr pElement, CTheme* pTheme, CSlid
else oAtom.ToColor(&tmp);
pShape->m_o3dOptions.oExtrusionColorExt = tmp;
}break;
case NSOfficeDrawing::c3DExtrusionColorExtMod:
case ODRAW::c3DExtrusionColorExtMod:
{
pShape->m_o3dOptions.nTypeExtrusionColorExt = (pProperty->m_lValue & 0x00000300) >> 8;
}break;
case NSOfficeDrawing::c3DBottomBevelWidth:
case ODRAW::c3DBottomBevelWidth:
{
pShape->m_o3dOptions.dBottomBevelWidth = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DBottomBevelHeight:
case ODRAW::c3DBottomBevelHeight:
{
pShape->m_o3dOptions.dBottomBevelHeight = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DBottomBevelType:
case ODRAW::c3DBottomBevelType:
{
pShape->m_o3dOptions.nBottomBevelType = pProperty->m_lValue;
}break;
case NSOfficeDrawing::c3DTopBevelWidth:
case ODRAW::c3DTopBevelWidth:
{
pShape->m_o3dOptions.dTopBevelWidth = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DTopBevelHeight:
case ODRAW::c3DTopBevelHeight:
{
pShape->m_o3dOptions.dTopBevelHeight = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DTopBevelType:
case ODRAW::c3DTopBevelType:
{
pShape->m_o3dOptions.nTopBevelType = pProperty->m_lValue;
}break;
case NSOfficeDrawing::c3DBoolean:
case ODRAW::c3DBoolean:
{
bool fUsef3D = GETBIT(pProperty->m_lValue, 19);
bool fUsefc3DMetallic = GETBIT(pProperty->m_lValue, 18);
@ -1332,121 +1329,121 @@ void CPPTElement::SetUpPropertyShape(CElementPtr pElement, CTheme* pTheme, CSlid
pShape->m_o3dOptions.bLightFace = fUsefc3DLightFace ? GETBIT(pProperty->m_lValue, 0) : true;
}break;
case NSOfficeDrawing::c3DYRotationAngle:
case ODRAW::c3DYRotationAngle:
{
double val = FixedPointToDouble(pProperty->m_lValue);
if (val < 0) val += 360;
pShape->m_o3dOptions.dYRotationAngle = val;
}break;
case NSOfficeDrawing::c3DXRotationAngle:
case ODRAW::c3DXRotationAngle:
{
double val = FixedPointToDouble(pProperty->m_lValue);
if (val < 0) val += 360;
pShape->m_o3dOptions.dXRotationAngle = val;
}break;
case NSOfficeDrawing::c3DRotationAxisX:
case ODRAW::c3DRotationAxisX:
{
pShape->m_o3dOptions.dRotationAxisX = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DRotationAxisY:
case ODRAW::c3DRotationAxisY:
{
pShape->m_o3dOptions.dRotationAxisY = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DRotationAxisZ:
case ODRAW::c3DRotationAxisZ:
{
pShape->m_o3dOptions.dRotationAxisZ = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DRotationAngle:
case ODRAW::c3DRotationAngle:
{
pShape->m_o3dOptions.dRotationAngle = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DRotationCenterX:
case ODRAW::c3DRotationCenterX:
{
pShape->m_o3dOptions.dRotationCenterX = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DRotationCenterY:
case ODRAW::c3DRotationCenterY:
{
pShape->m_o3dOptions.dRotationCenterY = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DRotationCenterZ:
case ODRAW::c3DRotationCenterZ:
{
pShape->m_o3dOptions.dRotationCenterZ = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DRenderMode:
case ODRAW::c3DRenderMode:
{
pShape->m_o3dOptions.nRenderMode = pProperty->m_lValue;
}break;
case NSOfficeDrawing::c3DTolerance:
case ODRAW::c3DTolerance:
{
pShape->m_o3dOptions.dTolerance = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DXViewpoint:
case ODRAW::c3DXViewpoint:
{
pShape->m_o3dOptions.dXViewpoint = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DYViewpoint:
case ODRAW::c3DYViewpoint:
{
pShape->m_o3dOptions.dYViewpoint = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DZViewpoint:
case ODRAW::c3DZViewpoint:
{
pShape->m_o3dOptions.dZViewpoint = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DOriginX:
case ODRAW::c3DOriginX:
{
pShape->m_o3dOptions.dOriginX = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DOriginY:
case ODRAW::c3DOriginY:
{
pShape->m_o3dOptions.dOriginY = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DSkewAngle:
case ODRAW::c3DSkewAngle:
{
double val = FixedPointToDouble(pProperty->m_lValue);
if (val <= 0) val += 360;
pShape->m_o3dOptions.dSkewAngle = val;
}break;
case NSOfficeDrawing::c3DSkewAmount:
case ODRAW::c3DSkewAmount:
{
pShape->m_o3dOptions.nSkewAmount = pProperty->m_lValue;
}break;
case NSOfficeDrawing::c3DAmbientIntensity:
case ODRAW::c3DAmbientIntensity:
{
pShape->m_o3dOptions.dAmbientIntensity = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DKeyX:
case ODRAW::c3DKeyX:
{
pShape->m_o3dOptions.dKeyX = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DKeyY:
case ODRAW::c3DKeyY:
{
pShape->m_o3dOptions.dKeyY = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DKeyZ:
case ODRAW::c3DKeyZ:
{
pShape->m_o3dOptions.dKeyZ = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DKeyIntensity:
case ODRAW::c3DKeyIntensity:
{
pShape->m_o3dOptions.dKeyIntensity = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DFillX:
case ODRAW::c3DFillX:
{
pShape->m_o3dOptions.dFillX = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DFillY:
case ODRAW::c3DFillY:
{
pShape->m_o3dOptions.dFillY = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DFillZ:
case ODRAW::c3DFillZ:
{
pShape->m_o3dOptions.dFillZ = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DFillIntensity:
case ODRAW::c3DFillIntensity:
{
pShape->m_o3dOptions.dFillIntensity = FixedPointToDouble(pProperty->m_lValue);
}break;
case NSOfficeDrawing::c3DStyleBoolean:
case ODRAW::c3DStyleBoolean:
{
bool fUsefc3DConstrainRotation = GETBIT(pProperty->m_lValue, 20);
bool fUsefc3DRotationCenterAuto = GETBIT(pProperty->m_lValue, 19);
@ -1488,7 +1485,7 @@ CElementPtr CRecordShapeContainer::GetElement (bool inGroup, CExMedia* pMapIDs,
GetRecordsByType(&oArrayOptions, true, /*true*/false/*secondary & tetriary*/);
PPTShapes::ShapeType eType = (PPTShapes::ShapeType)oArrayShape[0]->m_oHeader.RecInstance;
ElementType elType = GetTypeElem((NSOfficeDrawing::SPT)oArrayShape[0]->m_oHeader.RecInstance);
ElementType elType = GetTypeElem((ODRAW::eSPT)oArrayShape[0]->m_oHeader.RecInstance);
int lMasterID = -1;
@ -1813,9 +1810,9 @@ CElementPtr CRecordShapeContainer::GetElement (bool inGroup, CExMedia* pMapIDs,
}
else
{
pShapeElem->m_pShape->m_oText.m_lTextType = NSOfficePPT::NoPresent;
pShapeElem->m_pShape->m_oText.m_lTextMasterType = NSOfficePPT::NoPresent;
oElementInfo.m_lMasterTextType = NSOfficePPT::NoPresent;
pShapeElem->m_pShape->m_oText.m_lTextType = NoPresent;
pShapeElem->m_pShape->m_oText.m_lTextMasterType = NoPresent;
oElementInfo.m_lMasterTextType = NoPresent;
}
// проверка на ссылку в персист
@ -2060,9 +2057,9 @@ void CRecordShapeContainer::SetUpTextStyle(std::wstring& strText, CTheme* pTheme
bool bIsPersistPresentSettings = false;
bool bIsOwnPresentSettings = false;
NSOfficePPT::TextType eTypeMaster = NSOfficePPT::NoPresent;
NSOfficePPT::TextType eTypePersist = NSOfficePPT::NoPresent;
NSOfficePPT::TextType eTypeOwn = (NSOfficePPT::TextType)pTextSettings->m_lTextType;
eTextType eTypeMaster = NoPresent;
eTextType eTypePersist = NoPresent;
eTextType eTypeOwn = (eTextType)pTextSettings->m_lTextType;
CShapeElement* pElementLayoutPH = NULL;
@ -2084,7 +2081,7 @@ void CRecordShapeContainer::SetUpTextStyle(std::wstring& strText, CTheme* pTheme
if ((etShape == pPh->m_etType) && (ph_type == pPh->m_lPlaceholderType) && (/*ph_pos == pPh->m_lPlaceholderID*/true))
{
pElementLayoutPH = dynamic_cast<CShapeElement*>(pPh.get());
eTypeMaster = (NSOfficePPT::TextType)pElementLayoutPH->m_pShape->m_oText.m_lTextMasterType;
eTypeMaster = (eTextType)pElementLayoutPH->m_pShape->m_oText.m_lTextMasterType;
break;
}
}
@ -2092,7 +2089,7 @@ void CRecordShapeContainer::SetUpTextStyle(std::wstring& strText, CTheme* pTheme
}
else
{
eTypeMaster = (NSOfficePPT::TextType)pTextSettings->m_lTextMasterType;
eTypeMaster = (eTextType)pTextSettings->m_lTextMasterType;
}
// ------------------------------------------------------------------------------
@ -2110,7 +2107,7 @@ void CRecordShapeContainer::SetUpTextStyle(std::wstring& strText, CTheme* pTheme
{
CTextFullSettings* pSettings = &pArrayPlaceHolders->at(lPersistIndex);
eTypePersist = (NSOfficePPT::TextType)pSettings->m_nTextType;
eTypePersist = (eTextType)pSettings->m_nTextType;
strText = pSettings->ApplyProperties(pTextSettings);
if ((0 != pSettings->m_arRanges.size()) && (0 == pShape->m_oTextActions.m_arRanges.size()))
@ -2141,7 +2138,7 @@ void CRecordShapeContainer::SetUpTextStyle(std::wstring& strText, CTheme* pTheme
pStyle->ReadFromStream(oHeader, oElemInfo.m_pStream);
NSPresentationEditor::ConvertPPTTextToEditorStructure(pStyle->m_arrPFs, pStyle->m_arrCFs, strText, pShape->m_pShape->m_oText);
PPT_FORMAT::ConvertPPTTextToEditorStructure(pStyle->m_arrPFs, pStyle->m_arrCFs, strText, pShape->m_pShape->m_oText);
bIsOwnPresentSettings = (0 < pStyle->m_lCount);
@ -2160,13 +2157,13 @@ void CRecordShapeContainer::SetUpTextStyle(std::wstring& strText, CTheme* pTheme
{
switch (oElemInfo.m_lMasterPlaceholderType)
{
case NSOfficePPT::Title:
case NSOfficePPT::MasterTitle:
case NSOfficePPT::VerticalTextTitle:
case PT_Title:
case PT_MasterTitle:
case PT_VerticalTitle:
{
pTextSettings->m_lStyleThemeIndex = 1;
if (NSOfficePPT::_Title != eTypeMaster)
if (Tx_TYPE_TITLE != eTypeMaster)
{
if (0 <= nTextMasterType && nTextMasterType < 9)
{
@ -2176,12 +2173,12 @@ void CRecordShapeContainer::SetUpTextStyle(std::wstring& strText, CTheme* pTheme
}
break;
}
case NSOfficePPT::CenteredTitle:
case NSOfficePPT::MasterCenteredTitle:
case PT_CenterTitle:
case PT_MasterCenterTitle:
{
pTextSettings->m_lStyleThemeIndex = 1;
if (NSOfficePPT::_Title != eTypeMaster)
if (Tx_TYPE_TITLE != eTypeMaster)
{
if (0 <= nTextMasterType && nTextMasterType < 9)
{
@ -2191,17 +2188,17 @@ void CRecordShapeContainer::SetUpTextStyle(std::wstring& strText, CTheme* pTheme
}
break;
}
case NSOfficePPT::Body:
case NSOfficePPT::MasterBody:
case NSOfficePPT::NotesBody:
case NSOfficePPT::MasterNotesBody:
case NSOfficePPT::VerticalTextBody:
case NSOfficePPT::MasterSubtitle:
case NSOfficePPT::Subtitle:
case PT_Body:
case PT_MasterBody:
case PT_NotesBody:
case PT_MasterNotesBody:
case PT_VerticalBody:
case PT_MasterSubTitle:
case PT_SubTitle:
{
pTextSettings->m_lStyleThemeIndex = 2;
if ((NSOfficePPT::_Body != eTypeMaster) || !pLayout)
if ((Tx_TYPE_BODY != eTypeMaster) || !pLayout)
{
if (0 <= nTextMasterType && nTextMasterType < 9)
{
@ -2215,7 +2212,7 @@ void CRecordShapeContainer::SetUpTextStyle(std::wstring& strText, CTheme* pTheme
{
pTextSettings->m_lStyleThemeIndex = 3;
if ((NSOfficePPT::Other != eTypeMaster) || !pLayout)
if ((Tx_TYPE_OTHER != eTypeMaster) || !pLayout)
{
if (0 <= nTextMasterType && nTextMasterType < 9)
{
@ -2233,7 +2230,7 @@ void CRecordShapeContainer::SetUpTextStyle(std::wstring& strText, CTheme* pTheme
{
//pTextSettings->m_lTextType = 0;
//if (NSOfficePPT::Other != eTypeMaster)
//if (Other != eTypeMaster)
//{
// if (0 <= nTextMasterType && nTextMasterType < 9)
// {
@ -2244,7 +2241,7 @@ void CRecordShapeContainer::SetUpTextStyle(std::wstring& strText, CTheme* pTheme
}
// теперь смотрим все остальные стили (persist и own) - просто применяем их к m_oStyles
if (eTypePersist != NSOfficePPT::NoPresent && eTypePersist != eTypeMaster)
if (eTypePersist != NoPresent && eTypePersist != eTypeMaster)
{
int nIndexType = (int)eTypePersist;
if (0 <= nIndexType && nIndexType < 9)
@ -2253,7 +2250,7 @@ void CRecordShapeContainer::SetUpTextStyle(std::wstring& strText, CTheme* pTheme
pTextSettings->m_oStyles.ApplyAfter(pThemeWrapper->m_pStyles[nIndexType].get());
}
}
if (eTypeOwn != NSOfficePPT::NoPresent && eTypeOwn != eTypePersist && eTypeOwn != eTypeMaster)
if (eTypeOwn != NoPresent && eTypeOwn != eTypePersist && eTypeOwn != eTypeMaster)
{
int nIndexType = (int)eTypeOwn;
if (0 <= nIndexType && nIndexType < 9)
@ -2277,24 +2274,24 @@ void CRecordShapeContainer::SetUpTextStyle(std::wstring& strText, CTheme* pTheme
{
switch (oElemInfo.m_lMasterPlaceholderType)
{
case NSOfficePPT::Title:
case NSOfficePPT::MasterTitle:
case NSOfficePPT::VerticalTextTitle:
case PT_Title:
case PT_MasterTitle:
case PT_VerticalTitle:
{
pTextSettings->m_lStyleThemeIndex = 1;
break;
}
case NSOfficePPT::CenteredTitle:
case NSOfficePPT::MasterCenteredTitle:
case PT_CenterTitle:
case PT_MasterCenterTitle:
{
pTextSettings->m_lStyleThemeIndex = 1;
break;
}
case NSOfficePPT::Body:
case NSOfficePPT::MasterBody:
case NSOfficePPT::NotesBody:
case NSOfficePPT::MasterNotesBody:
case NSOfficePPT::VerticalTextBody:
case PT_Body:
case PT_MasterBody:
case PT_NotesBody:
case PT_MasterNotesBody:
case PT_VerticalBody:
{
pTextSettings->m_lStyleThemeIndex = 2;
break;
@ -2313,7 +2310,7 @@ void CRecordShapeContainer::SetUpTextStyle(std::wstring& strText, CTheme* pTheme
}
// теперь смотрим все остальные стили (persist и own) - просто применяем их к m_oStyles
if (eTypePersist != NSOfficePPT::NoPresent && eTypePersist != eTypeMaster)
if (eTypePersist != NoPresent && eTypePersist != eTypeMaster)
{
int nIndexType = (int)eTypePersist;
if (0 <= nIndexType && nIndexType < 9)
@ -2322,13 +2319,13 @@ void CRecordShapeContainer::SetUpTextStyle(std::wstring& strText, CTheme* pTheme
pTextSettings->m_oStyles.ApplyAfter(pThemeWrapper->m_pStyles[nIndexType].get());
}
}
if (eTypeOwn != NSOfficePPT::NoPresent/* && eTypeOwn != NSOfficePPT::Other*/ && eTypeOwn != eTypePersist && eTypeOwn != eTypeMaster)
if (eTypeOwn != NoPresent/* && eTypeOwn != Other*/ && eTypeOwn != eTypePersist && eTypeOwn != eTypeMaster)
{
int nIndexType = (int)eTypeOwn;
if (0 <= nIndexType && nIndexType < 9 && pLayout)
{
if (eTypeOwn == NSOfficePPT::HalfBody || eTypeOwn == NSOfficePPT::QuarterBody)
if (eTypeOwn == Tx_TYPE_HALFBODY || eTypeOwn == Tx_TYPE_QUARTERBODY)
{
if (pThemeWrapper->m_pStyles[1].IsInit())//body -> (560).ppt
{
@ -2346,23 +2343,23 @@ void CRecordShapeContainer::SetUpTextStyle(std::wstring& strText, CTheme* pTheme
if ((_T("") != strText) && 0 == pTextSettings->m_arParagraphs.size())
{
// значит никаких своих настроек нету. Значит просто пустые свои настройки
std::vector<CTextPFRun_ppt> oArrayPF;
std::vector<CTextPFRunRecord> oArrayPF;
CTextPFRun_ppt elm;
CTextPFRunRecord elm;
elm.m_lCount = strText.length();
elm.m_lLevel = 0;
oArrayPF.push_back(elm);
std::vector<CTextCFRun_ppt> oArrayCF;
std::vector<CTextCFRunRecord> oArrayCF;
CTextCFRun_ppt elm1;
CTextCFRunRecord elm1;
elm1.m_lCount = elm.m_lCount;
oArrayCF.push_back(elm1);
NSPresentationEditor::ConvertPPTTextToEditorStructure(oArrayPF, oArrayCF, strText, *pTextSettings);
PPT_FORMAT::ConvertPPTTextToEditorStructure(oArrayPF, oArrayCF, strText, *pTextSettings);
}
if (NULL != oElemInfo.m_pStream && -1 != oElemInfo.m_lOffsetTextProp)
@ -2394,7 +2391,7 @@ void CRecordShapeContainer::SetUpTextStyle(std::wstring& strText, CTheme* pTheme
if (pShape->m_oTextActions.m_bPresent)
{
//todooo разобраться нужно ли менять цвет на гиперлинк - 1-(34).ppt
NSPresentationEditor::CColor oColor;
ODRAW::CColor oColor;
if ((NULL != pSlide) && !pSlide->m_bUseLayoutColorScheme) oColor = pSlide->GetColor(11);
else if ((NULL != pLayout) && (!pLayout->m_bUseThemeColorScheme)) oColor = pLayout->GetColor(11);
else if (NULL != pTheme) oColor = pTheme->GetColor(11);

View File

@ -57,8 +57,8 @@
#define FIXED_POINT_unsigned(val) (double)((WORD)(val >> 16) + ((WORD)(val) / 65536.0))
using namespace NSOfficeDrawing;
using namespace NSPresentationEditor;
using namespace ODRAW;
using namespace PPT_FORMAT;
class CPPTElement
{
@ -107,7 +107,7 @@ public:
CTheme* pTheme, CLayout* pLayout,
CSlideInfo* pThemeWrapper, CSlideInfo* pSlideWrapper, CSlide* pSlide = NULL);
NSPresentationEditor::ElementType GetTypeElem(SPT eType)
PPT_FORMAT::ElementType GetTypeElem(eSPT eType)
{
switch (eType)
{

View File

@ -34,8 +34,6 @@
class CRecordTextBox : public CUnknownRecord
{
BYTE* m_pData;
public:
CRecordTextBox()

View File

@ -34,12 +34,11 @@
class CRecordExOleEmbedAtom : public CUnknownRecord
{
public:
UINT m_nColorFollow;
BOOL1 m_nCantLockServer;
BOOL1 m_nNoSizeToServer;
BOOL1 m_nIsTable;
public:
CRecordExOleEmbedAtom()
{

View File

@ -34,10 +34,9 @@
class CRecordExOleLinkAtom : public CUnknownRecord
{
public:
UINT m_nSlideID;
UINT m_nOleUpdateMode;
public:
CRecordExOleLinkAtom()
{

View File

@ -47,15 +47,9 @@ public:
BYTE m_lfPitchAndFamily;
public:
CRecordFontEntityAtom()
{
}
CRecordFontEntityAtom(){}
~CRecordFontEntityAtom()
{
}
~CRecordFontEntityAtom(){}
virtual void ReadFromStream(SRecordHeader & oHeader, POLE::Stream* pStream)
{
@ -109,3 +103,22 @@ public:
m_lfPitchAndFamily = StreamUtils::ReadBYTE(pStream);
}
};
class CRecordFontEmbedDataBlob : public CUnknownRecord
{
public:
std::pair<boost::shared_array<unsigned char>, _INT32> data;
//font data of an embedded font
CRecordFontEmbedDataBlob(){}
~CRecordFontEmbedDataBlob(){}
virtual void ReadFromStream(SRecordHeader & oHeader, POLE::Stream* pStream)
{
m_oHeader = oHeader;
data = std::make_pair(boost::shared_array<unsigned char>(new unsigned char[m_oHeader.RecLen]), m_oHeader.RecLen);
pStream->read(data.first.get(), data.second);
}
};

View File

@ -34,10 +34,9 @@
class CRecordGridSpacing10Atom : public CUnknownRecord
{
public:
INT m_nX;
INT m_nY;
public:
CRecordGridSpacing10Atom()
{

View File

@ -34,9 +34,8 @@
class CRecordKinsokuAtom : public CUnknownRecord
{
UINT m_nLevel;
public:
_UINT32 m_nLevel;
CRecordKinsokuAtom()
{
@ -48,7 +47,9 @@ public:
virtual void ReadFromStream(SRecordHeader & oHeader, POLE::Stream* pStream)
{
return CUnknownRecord::ReadFromStream(oHeader, pStream);
m_oHeader = oHeader;
m_nLevel = StreamUtils::ReadDWORD(pStream);
}
};

View File

@ -34,10 +34,9 @@
class CRecordMasterPersistAtom : public CUnknownRecord
{
public:
UINT m_nPsrRef;
INT m_nMasterID;
public:
CRecordMasterPersistAtom()
{

View File

@ -34,12 +34,11 @@
class CRecordMetafileBlob : public CUnknownRecord
{
public:
SHORT m_nMM;
SHORT m_nExtX;
SHORT m_nExtY;
BYTE* m_pData;
public:
CRecordMetafileBlob()
{

View File

@ -34,9 +34,8 @@
class CRecordMouseTextInteractiveInfoAtom : public CUnknownRecord
{
STextRange m_oRange;
public:
STextRange m_oRange;
CRecordMouseTextInteractiveInfoAtom()
{

View File

@ -34,9 +34,8 @@
class CRecordNamedShowSlidesAtom : public CUnknownRecord
{
std::vector<UINT> m_arRgSlideIdRef;
public:
std::vector<UINT> m_arRgSlideIdRef;
CRecordNamedShowSlidesAtom()
{

View File

@ -34,12 +34,11 @@
class CRecordNoZoomViewInfoAtom : public CUnknownRecord
{
public:
SScalingAtom m_oCurScale;
SPointAtom m_nOrigin;
BOOL1 m_bDraftMode;
public:
CRecordNoZoomViewInfoAtom()
{

View File

@ -34,10 +34,9 @@
class CRecordNotesPersistAtom : public CUnknownRecord
{
public:
UINT m_nPsrRef;
INT m_nNotesID;
public:
CRecordNotesPersistAtom()
{

View File

@ -35,7 +35,7 @@
class CRecordRoundTripColorMappingAtom : public CUnknownRecord
{
public:
std::string m_strData;
std::pair<boost::shared_array<unsigned char>, _INT32> data;
CRecordRoundTripColorMappingAtom()
{
@ -48,6 +48,8 @@ public:
virtual void ReadFromStream(SRecordHeader & oHeader, POLE::Stream* pStream)
{
m_oHeader = oHeader;
m_strData = StreamUtils::ReadStringA(pStream, (long)m_oHeader.RecLen);
data = std::make_pair(boost::shared_array<unsigned char>(new unsigned char[m_oHeader.RecLen]), m_oHeader.RecLen);
pStream->read(data.first.get(), data.second);
}
};

View File

@ -34,9 +34,8 @@
class CRecordRoundTripNewPlaceholderId12Atom : public CUnknownRecord
{
BYTE m_nFlags;
public:
BYTE m_nFlags;
CRecordRoundTripNewPlaceholderId12Atom()
{

View File

@ -35,7 +35,7 @@
class CRecordRoundTripNotesMasterTextStyles12Atom : public CUnknownRecord
{
public:
std::string m_strData;
std::pair<boost::shared_array<unsigned char>, _INT32> data;
CRecordRoundTripNotesMasterTextStyles12Atom()
{
@ -48,6 +48,30 @@ public:
virtual void ReadFromStream(SRecordHeader & oHeader, POLE::Stream* pStream)
{
m_oHeader = oHeader;
m_strData = StreamUtils::ReadStringA(pStream, (long)m_oHeader.RecLen);
data = std::make_pair(boost::shared_array<unsigned char>(new unsigned char[m_oHeader.RecLen]), m_oHeader.RecLen);
pStream->read(data.first.get(), data.second);
}
};
class CRecordRoundTripCustomTableStyles12Atom : public CUnknownRecord
{
public:
std::pair<boost::shared_array<unsigned char>, _INT32> data;
CRecordRoundTripCustomTableStyles12Atom()
{
}
~CRecordRoundTripCustomTableStyles12Atom()
{
}
virtual void ReadFromStream(SRecordHeader & oHeader, POLE::Stream* pStream)
{
m_oHeader = oHeader;
data = std::make_pair(boost::shared_array<unsigned char>(new unsigned char[m_oHeader.RecLen]), m_oHeader.RecLen);
pStream->read(data.first.get(), data.second);
}
};

View File

@ -35,19 +35,16 @@
class CRecordRoundTripThemeAtom : public CUnknownRecord
{
public:
std::string m_strData;
std::pair<boost::shared_array<unsigned char>, _INT32> data;
CRecordRoundTripThemeAtom()
{
}
~CRecordRoundTripThemeAtom()
{
}
CRecordRoundTripThemeAtom(){}
~CRecordRoundTripThemeAtom(){}
virtual void ReadFromStream(SRecordHeader & oHeader, POLE::Stream* pStream)
{
m_oHeader = oHeader;
m_strData = StreamUtils::ReadStringA(pStream, (long)m_oHeader.RecLen);
data = std::make_pair(boost::shared_array<unsigned char>(new unsigned char[m_oHeader.RecLen]), m_oHeader.RecLen);
pStream->read(data.first.get(), data.second);
}
};

View File

@ -34,16 +34,23 @@
class CRecordSSDocInfoAtom : public CUnknownRecord
{
SColorAtom m_oColor;
INT m_nRestartTime;
SHORT m_nStartSlide;
SHORT m_nEndSlide;
USHORT m_pName[32];
USHORT m_nFlags;
public:
SColorAtom m_oPenColor;
_INT32 m_nRestartTime;
short m_nStartSlide;
short m_nEndSlide;
std::wstring m_pName;
bool fAutoAdvance;
bool fWillSkipBuilds;
bool fUseSlideRange;
bool fDocUseNamedShow;
bool fBrowseMode;
bool fKioskMode;
bool fWillSkipNarration;
bool fLoopContinuously;
bool fHideScrollBar;
CRecordSSDocInfoAtom()
{
}
@ -54,7 +61,32 @@ public:
virtual void ReadFromStream(SRecordHeader & oHeader, POLE::Stream* pStream)
{
return CUnknownRecord::ReadFromStream(oHeader, pStream);
m_oHeader = oHeader;
unsigned short flags;
unsigned char nm[64];
NSStreamReader::Read(pStream, m_oPenColor);
m_nRestartTime = StreamUtils::ReadLONG(pStream);
m_nStartSlide = StreamUtils::ReadSHORT(pStream);
m_nEndSlide = StreamUtils::ReadSHORT(pStream);
pStream->read(nm, 64);
m_pName = NSFile::CUtf8Converter::GetWStringFromUTF16((unsigned short*)nm, 32);
flags = StreamUtils::ReadWORD(pStream);
fAutoAdvance = GETBIT(flags, 15);
fWillSkipBuilds = GETBIT(flags, 14);
fUseSlideRange = GETBIT(flags, 13);
fDocUseNamedShow = GETBIT(flags, 12);
fBrowseMode = GETBIT(flags, 11);
fKioskMode = GETBIT(flags, 10);
fWillSkipNarration = GETBIT(flags, 9);
fLoopContinuously = GETBIT(flags, 8);
fHideScrollBar = GETBIT(flags, 7);
unsigned short unused = StreamUtils::ReadWORD(pStream);
}
};

View File

@ -34,10 +34,9 @@
class CRecordSSlideLayoutAtom : public CUnknownRecord
{
public:
INT m_nGeom;
BYTE m_pPlaceHolderID[8];
public:
CRecordSSlideLayoutAtom()
{

View File

@ -34,9 +34,8 @@
class CRecordShapeFlags10Atom : public CUnknownRecord
{
BYTE m_nFlags;
public:
BYTE m_nFlags;
CRecordShapeFlags10Atom()
{

View File

@ -34,9 +34,8 @@
class CRecordShapeFlagsAtom : public CUnknownRecord
{
BYTE m_nFlags;
public:
BYTE m_nFlags;
CRecordShapeFlagsAtom()
{

View File

@ -32,23 +32,56 @@
#pragma once
#include "../Reader/Records.h"
class CRecordSlideColorSchemeAtom : public CUnknownRecord
class CRecordSplitMenuColorRecord: public CUnknownRecord
{
public:
SColorAtom m_arColors[8];
SColorAtom m_oFillColor;
SColorAtom m_oLineColor;
SColorAtom m_oShadowColor;
SColorAtom m_o3DColor;
CRecordSlideColorSchemeAtom()
CRecordSplitMenuColorRecord()
{
}
~CRecordSlideColorSchemeAtom()
~CRecordSplitMenuColorRecord()
{
}
virtual void ReadFromStream(SRecordHeader & oHeader, POLE::Stream* pStream)
{
return CUnknownRecord::ReadFromStream(oHeader, pStream);
m_oHeader = oHeader;
NSStreamReader::Read(pStream, m_oFillColor);
NSStreamReader::Read(pStream, m_oLineColor);
NSStreamReader::Read(pStream, m_oShadowColor);
NSStreamReader::Read(pStream, m_o3DColor);
}
};
typedef CRecordSlideColorSchemeAtom CRecordSchemeListElementColorSchemeAtom;
class CRecordMostRecentlyUserColors : public CUnknownRecord
{
public:
std::vector<SColorAtom> m_oColors;
CRecordMostRecentlyUserColors()
{
}
~CRecordMostRecentlyUserColors()
{
}
virtual void ReadFromStream(SRecordHeader & oHeader, POLE::Stream* pStream)
{
m_oHeader = oHeader;
for (int i = 0; i < m_oHeader.RecLen / 4; i++)
{
SColorAtom color;
NSStreamReader::Read(pStream, color);
m_oColors.push_back(color);
}
}
};

View File

@ -154,7 +154,7 @@ public:
if (RECORD_TYPE_TXINTERACTIVEINFO_ATOM == oRec.RecType)
{
CRecordTextInteractiveInfoAtom* pTxRanges = dynamic_cast<CRecordTextInteractiveInfoAtom*>(pRecord);
NSPresentationEditor::CTextRange oRange;
PPT_FORMAT::CTextRange oRange;
oRange.m_lStart = pTxRanges->m_lStart;
oRange.m_lEnd = pTxRanges->m_lEnd;
m_arTextPlaceHolders[nCurrentSlide][nCurrentTextHeader].m_arRanges.push_back(oRange);

View File

@ -43,8 +43,8 @@ public:
// Text.Bytes/Chars.Atom
_UINT32 m_lCount;
std::vector<CTextPFRun_ppt> m_arrPFs;
std::vector<CTextCFRun_ppt> m_arrCFs;
std::vector<CTextPFRunRecord> m_arrPFs;
std::vector<CTextCFRunRecord> m_arrCFs;
CRecordStyleTextPropAtom()
{
@ -73,7 +73,7 @@ public:
while (lMemCount < m_lCount + 1)
{
CTextPFRun_ppt elm;
CTextPFRunRecord elm;
m_arrPFs.push_back(elm);
m_arrPFs[lCountItems].LoadFromStream(pStream);
lMemCount += m_arrPFs[lCountItems].m_lCount;
@ -85,7 +85,7 @@ public:
lCountItems = 0;
while (lMemCount < m_lCount + 1)
{
CTextCFRun_ppt elm;
CTextCFRunRecord elm;
m_arrCFs.push_back(elm);
m_arrCFs[lCountItems].LoadFromStream(pStream);

View File

@ -35,7 +35,7 @@
class CRecordTextCFExceptionAtom : public CUnknownRecord
{
public:
CTextCFRun_ppt m_oCFRun;
CTextCFRunRecord m_oCFRun;
CRecordTextCFExceptionAtom()
{

View File

@ -47,7 +47,7 @@ public:
CRecordTextSpecInfoAtom* m_pTextSpecInfo;
CRecordTextRulerAtom* m_pTextRuler;
std::vector<NSPresentationEditor::CTextRange> m_arRanges;
std::vector<PPT_FORMAT::CTextRange> m_arRanges;
std::wstring m_strText;
_UINT32 m_nTextType;
@ -97,7 +97,7 @@ public:
pTextAttributes->m_lStyleThemeIndex = m_lStyleThemeIndex;
if (NULL != m_pTextStyleProp)
NSPresentationEditor::ConvertPPTTextToEditorStructure(m_pTextStyleProp->m_arrPFs, m_pTextStyleProp->m_arrCFs, m_strText, *pTextAttributes);
PPT_FORMAT::ConvertPPTTextToEditorStructure(m_pTextStyleProp->m_arrPFs, m_pTextStyleProp->m_arrCFs, m_strText, *pTextAttributes);
if (NULL != m_pTextRuler)
pTextAttributes->m_oRuler = m_pTextRuler->m_oTextRuler;

View File

@ -32,14 +32,14 @@
#pragma once
#include "../Reader/Records.h"
class CRecordTextMasterStyleAtom : public CUnknownRecord, public NSPresentationEditor::CTextStyles
class CRecordTextMasterStyleAtom : public CUnknownRecord, public PPT_FORMAT::CTextStyles
{
public:
LONG m_nTextType;
CRecordTextMasterStyleAtom() : NSPresentationEditor::CTextStyles()
CRecordTextMasterStyleAtom() : PPT_FORMAT::CTextStyles()
{
m_nTextType = 0;
m_nTextType = -1;
}
~CRecordTextMasterStyleAtom()
@ -111,12 +111,12 @@ protected:
if (bIsLevelPresent)
lLevel = StreamUtils::ReadSHORT(pStream);
CTextPFRun_ppt oPF;
CTextCFRun_ppt oCF;
CTextPFRunRecord oPF;
CTextCFRunRecord oCF;
oPF.LoadFromStream(pStream, false);
oCF.LoadFromStream(pStream, false);
m_pLevels[lLevelOld] = new NSPresentationEditor::CTextStyleLevel();
m_pLevels[lLevelOld] = new PPT_FORMAT::CTextStyleLevel();
m_pLevels[lLevelOld]->m_oPFRun = oPF.m_oRun;
m_pLevels[lLevelOld]->m_oCFRun = oCF.m_oRun;
}

View File

@ -35,7 +35,7 @@
class CRecordTextPFExceptionAtom : public CUnknownRecord
{
public:
CTextPFRun_ppt m_oPFRun;
CTextPFRunRecord m_oPFRun;
CRecordTextPFExceptionAtom()
{

View File

@ -35,7 +35,7 @@
class CRecordTextRulerAtom : public CUnknownRecord
{
public:
NSPresentationEditor::CTextRuler m_oTextRuler;
PPT_FORMAT::CTextRuler m_oTextRuler;
public:

View File

@ -40,7 +40,7 @@ public:
LONG m_lOffsetInStream;
_UINT32 m_lCount;
std::vector<NSPresentationEditor::CTextSIRun> m_arrSIs;
std::vector<PPT_FORMAT::CTextSIRun> m_arrSIs;
CRecordTextSpecInfoAtom()
@ -62,7 +62,7 @@ public:
_UINT32 lMemCount = 0;
while (true)
{
NSPresentationEditor::CTextSIRun elm;
PPT_FORMAT::CTextSIRun elm;
m_arrSIs.push_back(elm);
NSStreamReader::Read(pStream, m_arrSIs.back());

View File

@ -34,13 +34,12 @@
class CRecordZoomViewInfoAtom : public CUnknownRecord
{
public:
SScalingAtom m_oCurScale;
SPointAtom m_nOrigin;
BOOL1 m_bUseVarScale;
BOOL1 m_bDraftMode;
public:
CRecordZoomViewInfoAtom()
{

View File

@ -279,9 +279,9 @@ namespace NS_DWC_Common
// 0x00FFFFFF, 0x00000000, 0x00000000, 0x00000000,
// 0x00000000, 0x00000000, 0x00FFFFFF, 0x00FFFFFF
//};
NSPresentationEditor::CColor getColorFromString(const std::wstring& colorStr)
ODRAW::CColor getColorFromString(const std::wstring& colorStr)
{
NSPresentationEditor::CColor color;
ODRAW::CColor color;
bool bSet = false;
if (colorStr.find(L"#") != std::wstring::npos)
{
@ -1780,7 +1780,7 @@ void CDrawingConverter::doc_LoadShape(PPTX::Logic::SpTreeElem *elem, XmlUtils::C
std::wstring strStyleAdvenced = L"";
NSPresentationEditor::CShapeElement oShapeElem;
PPT_FORMAT::CShapeElement oShapeElem;
CPPTShape* pPPTShape = NULL;
bool bSetShape = false;
@ -2144,7 +2144,7 @@ void CDrawingConverter::doc_LoadShape(PPTX::Logic::SpTreeElem *elem, XmlUtils::C
{
eFillType = etSolidFill;
NSPresentationEditor::CColor color = NS_DWC_Common::getColorFromString(*sFillColor);
ODRAW::CColor color = NS_DWC_Common::getColorFromString(*sFillColor);
PPTX::Logic::SolidFill* pSolid = new PPTX::Logic::SolidFill();
pSolid->m_namespace = L"a";
@ -2302,7 +2302,7 @@ void CDrawingConverter::doc_LoadShape(PPTX::Logic::SpTreeElem *elem, XmlUtils::C
}
if (sColor.is_init())
{
NSPresentationEditor::CColor color;
ODRAW::CColor color;
if (sColor->find(L"fill") != -1)
{
std::wstring sColorEffect = *sColor;
@ -2341,7 +2341,7 @@ void CDrawingConverter::doc_LoadShape(PPTX::Logic::SpTreeElem *elem, XmlUtils::C
}
if (sColor2.is_init())
{
NSPresentationEditor::CColor color;
ODRAW::CColor color;
if (sColor2->find(L"fill") != -1)
{
std::wstring sColorEffect = *sColor2;
@ -2407,7 +2407,7 @@ void CDrawingConverter::doc_LoadShape(PPTX::Logic::SpTreeElem *elem, XmlUtils::C
double pos = strPos.empty() ? 0 : _wtof(strPos.c_str());
NSPresentationEditor::CColor color = NS_DWC_Common::getColorFromString(strColor);
ODRAW::CColor color = NS_DWC_Common::getColorFromString(strColor);
PPTX::Logic::UniColor *oColor = new PPTX::Logic::UniColor();
oColor->Color = new PPTX::Logic::SrgbClr();
oColor->Color->SetRGB(color.R, color.G, color.B);
@ -2628,7 +2628,7 @@ void CDrawingConverter::doc_LoadShape(PPTX::Logic::SpTreeElem *elem, XmlUtils::C
smart_ptr<PPTX::Logic::SolidFill> pSolid = new PPTX::Logic::SolidFill();
pSolid->m_namespace = L"a";
pSolid->Color.Color = new PPTX::Logic::SrgbClr();
NSPresentationEditor::CColor color;
ODRAW::CColor color;
if (sStroked.is_init())
{
@ -4167,7 +4167,7 @@ void CDrawingConverter::CheckBrushShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils
XmlMacroReadAttributeBase(oNode, L"fillcolor", sFillColor);
if (sFillColor.is_init() && !pPPTShape->IsWordArt())
{
NSPresentationEditor::CColor color = NS_DWC_Common::getColorFromString(*sFillColor);
ODRAW::CColor color = NS_DWC_Common::getColorFromString(*sFillColor);
PPTX::Logic::SolidFill* pSolid = new PPTX::Logic::SolidFill();
pSolid->m_namespace = L"a";
@ -4240,7 +4240,7 @@ void CDrawingConverter::CheckBrushShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils
XmlMacroReadAttributeBase(oNodeFill, L"color", sColor);
if (sColor.is_init())
{
NSPresentationEditor::CColor color = NS_DWC_Common::getColorFromString(*sColor);
ODRAW::CColor color = NS_DWC_Common::getColorFromString(*sColor);
PPTX::Logic::SolidFill* pSolid = new PPTX::Logic::SolidFill();
pSolid->m_namespace = L"a";
@ -4303,7 +4303,7 @@ void CDrawingConverter::CheckBrushShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils
if (sColor.is_init())
{
NSPresentationEditor::CColor color = NS_DWC_Common::getColorFromString(*sColor);
ODRAW::CColor color = NS_DWC_Common::getColorFromString(*sColor);
PPTX::Logic::Gs Gs_;
Gs_.color.Color = new PPTX::Logic::SrgbClr();
@ -4333,7 +4333,7 @@ void CDrawingConverter::CheckBrushShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils
}
else
{
NSPresentationEditor::CColor color = NS_DWC_Common::getColorFromString(*sColor2);
ODRAW::CColor color = NS_DWC_Common::getColorFromString(*sColor2);
Gs_.color.Color->SetRGB(color.R, color.G, color.B);
}
@ -4543,7 +4543,7 @@ void CDrawingConverter::CheckPenShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils::
XmlMacroReadAttributeBase(oNode, L"strokecolor", sStrokeColor);
if (sStrokeColor.is_init())
{
NSPresentationEditor::CColor color = NS_DWC_Common::getColorFromString(*sStrokeColor);
ODRAW::CColor color = NS_DWC_Common::getColorFromString(*sStrokeColor);
if (!pSpPr->ln.is_init())
pSpPr->ln = new PPTX::Logic::Ln();
@ -4616,7 +4616,7 @@ void CDrawingConverter::CheckPenShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils::
XmlMacroReadAttributeBase(oNodeStroke, L"strokecolor", sStrokeColor);
if (sStrokeColor.is_init())
{
NSPresentationEditor::CColor color = NS_DWC_Common::getColorFromString(*sStrokeColor);
ODRAW::CColor color = NS_DWC_Common::getColorFromString(*sStrokeColor);
if (!pSpPr->ln.is_init())
pSpPr->ln = new PPTX::Logic::Ln();

View File

@ -32,7 +32,7 @@
#pragma once
#include "Attributes.h"
namespace NSPresentationEditor
namespace PPT_FORMAT
{
enum PointPathType
{
@ -346,24 +346,24 @@ namespace NSPresentationEditor
// m_oQuery.clear ();
// m_oQuery.push_back ( _T(" id = '") + NSPresentationEditor::ToString (pEffect->m_nEffectID) + _T("' "));
// m_oQuery.push_back ( _T(" type = '") + NSPresentationEditor::ToString (pEffect->m_nEffectType) + _T("' "));
// m_oQuery.push_back ( _T(" dir = '") + NSPresentationEditor::ToString (pEffect->m_nEffectDir) + _T("' "));
// m_oQuery.push_back ( _T(" id = '") + PPT_FORMAT::ToString (pEffect->m_nEffectID) + _T("' "));
// m_oQuery.push_back ( _T(" type = '") + PPT_FORMAT::ToString (pEffect->m_nEffectType) + _T("' "));
// m_oQuery.push_back ( _T(" dir = '") + PPT_FORMAT::ToString (pEffect->m_nEffectDir) + _T("' "));
// m_oQuery.push_back ( _T(" begin = '") + NSPresentationEditor::ToString (dEffectBegin) + _T("' "));
// m_oQuery.push_back ( _T(" dur = '") + NSPresentationEditor::ToString (pEffect->m_nDuration) + _T("' "));
// m_oQuery.push_back ( _T(" accel = '") + NSPresentationEditor::ToString (pEffect->m_dTimeAccel) + _T("' "));
// m_oQuery.push_back ( _T(" decel = '") + NSPresentationEditor::ToString (pEffect->m_dTimeDecel) + _T("' "));
// m_oQuery.push_back ( _T(" begin = '") + PPT_FORMAT::ToString (dEffectBegin) + _T("' "));
// m_oQuery.push_back ( _T(" dur = '") + PPT_FORMAT::ToString (pEffect->m_nDuration) + _T("' "));
// m_oQuery.push_back ( _T(" accel = '") + PPT_FORMAT::ToString (pEffect->m_dTimeAccel) + _T("' "));
// m_oQuery.push_back ( _T(" decel = '") + PPT_FORMAT::ToString (pEffect->m_dTimeDecel) + _T("' "));
// m_oQuery.push_back ( _T(" sx = '") + NSPresentationEditor::ToString (pEffect->m_dSX) + _T("' "));
// m_oQuery.push_back ( _T(" sy = '") + NSPresentationEditor::ToString (pEffect->m_dSY) + _T("' "));
// m_oQuery.push_back ( _T(" alpha = '") + NSPresentationEditor::ToString (pEffect->m_dTransparency) + _T("' "));
// m_oQuery.push_back ( _T(" sx = '") + PPT_FORMAT::ToString (pEffect->m_dSX) + _T("' "));
// m_oQuery.push_back ( _T(" sy = '") + PPT_FORMAT::ToString (pEffect->m_dSY) + _T("' "));
// m_oQuery.push_back ( _T(" alpha = '") + PPT_FORMAT::ToString (pEffect->m_dTransparency) + _T("' "));
// m_oQuery.push_back ( _T(" angle = '") + NSPresentationEditor::ToString (pEffect->m_dRotateAngle) + _T("' "));
// m_oQuery.push_back ( _T(" color = '") + NSPresentationEditor::ToString (pEffect->m_nColorTo) + _T("' "));
// m_oQuery.push_back ( _T(" angle = '") + PPT_FORMAT::ToString (pEffect->m_dRotateAngle) + _T("' "));
// m_oQuery.push_back ( _T(" color = '") + PPT_FORMAT::ToString (pEffect->m_nColorTo) + _T("' "));
// m_oQuery.push_back ( _T(" block = '") + NSPresentationEditor::ToString (pEffect->m_nTextSequence) + _T("' "));
// m_oQuery.push_back ( _T(" removeemptyblocks = '") + NSPresentationEditor::ToString (pEffect->m_bRemoveEmptyBlocks) + _T("' "));
// m_oQuery.push_back ( _T(" block = '") + PPT_FORMAT::ToString (pEffect->m_nTextSequence) + _T("' "));
// m_oQuery.push_back ( _T(" removeemptyblocks = '") + PPT_FORMAT::ToString (pEffect->m_bRemoveEmptyBlocks) + _T("' "));
// std::wstring Effect;

View File

@ -43,18 +43,34 @@
#include "../../../DesktopEditor/graphics/structures.h"
#include "../../../Common/DocxFormat/Source/XML/Utils.h"
namespace NSPresentationEditor
static void ReplaceAll(std::wstring & str, const std::wstring& from, const std::wstring& to)
{
static void ReplaceAll(std::wstring & str, const std::wstring& from, const std::wstring& to)
size_t start_pos = 0;
while((start_pos = str.find(from, start_pos)) != std::wstring::npos)
{
size_t start_pos = 0;
while((start_pos = str.find(from, start_pos)) != std::wstring::npos)
{
str.replace(start_pos, from.length(), to);
start_pos += to.length();
}
str.replace(start_pos, from.length(), to);
start_pos += to.length();
}
}
static void CorrectXmlString2(std::wstring & strText)
{
ReplaceAll(strText, L"&apos;", L"'");
ReplaceAll(strText, L"&lt;", L"<");
ReplaceAll(strText, L"&gt;", L">");
ReplaceAll(strText, L"&quot;", L"\"");
ReplaceAll(strText, L"&amp;", L"&");
}
static void CorrectXmlString(std::wstring & strText)
{
strText = XmlUtils::EncodeXmlString(strText);
}
static inline std::wstring BoolToString(bool bValue)
{
return bValue ? L"1" : L"0";
}
namespace PPT_FORMAT
{
class CExFilesInfo
{
public:
@ -239,42 +255,9 @@ namespace NSPresentationEditor
}
};
static void CorrectXmlString2(std::wstring & strText)
{
ReplaceAll(strText, L"&apos;", L"'");
ReplaceAll(strText, L"&lt;", L"<");
ReplaceAll(strText, L"&gt;", L">");
ReplaceAll(strText, L"&quot;", L"\"");
ReplaceAll(strText, L"&amp;", L"&");
}
static void CorrectXmlString(std::wstring & strText)
{
strText = XmlUtils::EncodeXmlString(strText);
}
static inline std::wstring BoolToString(bool bValue)
{
if (bValue)
return _T("1");
return _T("0");
}
static inline std::wstring ToString(int val)
{
return std::to_wstring(val);
}
static inline std::wstring ToString(_UINT32 val)
{
return std::to_wstring(val);
}
static inline std::wstring ToString(long val)
{
return std::to_wstring(val);
}
static inline std::wstring ToString(double val)
{
return std::to_wstring(val);
}
}
namespace ODRAW
{
class CColor
{
public:
@ -296,7 +279,7 @@ namespace NSPresentationEditor
}
CColor(_UINT32 rgb)
{
CreateColor(rgb);
(*this) = CreateColor(rgb);
}
CColor& operator =(const CColor& oSrc)
{
@ -397,7 +380,7 @@ namespace NSPresentationEditor
dwColor |= R;
dwColor |= (G << 8);
dwColor |= (B << 16);
return NSPresentationEditor::ToString((int)dwColor);
return std::to_wstring((int)dwColor);
}
void FromString(std::wstring str)

View File

@ -32,7 +32,7 @@
#pragma once
#include "Elements.h"
namespace NSPresentationEditor
namespace PPT_FORMAT
{
class CAudioPart
{

View File

@ -34,7 +34,7 @@
#include "AudioOverlay.h"
#include "Slide.h"
namespace NSPresentationEditor
namespace PPT_FORMAT
{
class CDocument
{
@ -157,11 +157,11 @@ namespace NSPresentationEditor
if (NULL == pShape) return;
if (pElement->m_lPlaceholderType == NSOfficePPT::MasterSlideNumber) pShape->SetUpTextPlaceholder(L"<#>");
if (pElement->m_lPlaceholderType == PT_MasterSlideNumber) pShape->SetUpTextPlaceholder(L"<#>");
int ind = -1;
if (pElement->m_lPlaceholderType == NSOfficePPT::MasterDate) ind = 0;
if (pElement->m_lPlaceholderType == NSOfficePPT::MasterFooter) ind = 2;
if (pElement->m_lPlaceholderType == PT_MasterDate) ind = 0;
if (pElement->m_lPlaceholderType == PT_MasterFooter) ind = 2;
if (pElement->m_lPlaceholderUserStr >= 0 && ind >= 0)
{
@ -171,7 +171,7 @@ namespace NSPresentationEditor
}
else
{
if (pElement->m_lPlaceholderType == NSOfficePPT::MasterDate && pElement->m_nFormatDate == 1)
if (pElement->m_lPlaceholderType == PT_MasterDate && pElement->m_nFormatDate == 1)
{
std::wstring current_date = L"11.11.2015";
pShape->SetUpTextPlaceholder(current_date);

View File

@ -34,7 +34,7 @@
#include <vector>
#include <string>
namespace NSPresentationEditor
namespace PPT_FORMAT
{
class CEffect
{

View File

@ -34,7 +34,9 @@
#include "Interactive.h"
#include "Animations.h"
namespace NSPresentationEditor
using namespace ODRAW;
namespace PPT_FORMAT
{
enum ElementType
{
@ -46,81 +48,6 @@ namespace NSPresentationEditor
etText = 5
};
enum enumPlaceholderType
{
PT_None = 0,
PT_MasterTitle,
PT_MasterBody,
PT_MasterCenterTitle,
PT_MasterSubTitle,
PT_MasterNotesSlideImage,
PT_MasterNotesBody,
PT_MasterDate,
PT_MasterSlideNumber,
PT_MasterFooter,
PT_MasterHeader,
PT_NotesSlideImage,
PT_NotesBody,
PT_Title,
PT_Body,
PT_CenterTitle,
PT_SubTitle,
PT_VerticalTitle,
PT_VerticalBody,
PT_Object,
PT_Graph,
PT_Table,
PT_ClipArt,
PT_OrgChart,
PT_Media,
PT_VerticalObject,
PT_Picture
};
static void CorrectPlaceholderType(int & type)
{
switch (type)
{
case PT_MasterTitle: type = PT_Title; break;
case PT_MasterBody: type = PT_Body; break;
case PT_MasterCenterTitle: type = PT_CenterTitle; break;
case PT_MasterSubTitle: type = PT_SubTitle; break;
case PT_MasterNotesSlideImage: type = PT_NotesSlideImage; break;
case PT_MasterNotesBody: type = PT_NotesBody; break;
}
}
static bool isTitlePlaceholder(int type)
{
switch (type)
{
case PT_MasterTitle:
case PT_MasterCenterTitle:
case PT_Title:
case PT_CenterTitle:
case PT_VerticalTitle:
return true;
default:
return false;
}
}
static bool isBodyPlaceholder(int type)
{
switch (type)
{
case PT_MasterBody:
case PT_Body:
case PT_VerticalBody:
return true;
default:
return false;
}
}
class CTheme;
class CLayout;
class CSlide;

View File

@ -32,7 +32,7 @@
#include "Slide.h"
void NSPresentationEditor::CShapeElement::CalculateColor(CColor& oColor, CSlide* pSlide, CTheme* pTheme, CLayout* pLayout)
void PPT_FORMAT::CShapeElement::CalculateColor(CColor& oColor, CSlide* pSlide, CTheme* pTheme, CLayout* pLayout)
{
LONG lOldIndex = oColor.m_lSchemeIndex;
if (-1 == oColor.m_lSchemeIndex)
@ -61,9 +61,9 @@ void NSPresentationEditor::CShapeElement::CalculateColor(CColor& oColor, CSlide*
oColor.m_lSchemeIndex = lOldIndex;
}
void NSPresentationEditor::CShapeElement::SetupTextProperties(CSlide* pSlide, CTheme* pTheme, CLayout* pLayout)
void PPT_FORMAT::CShapeElement::SetupTextProperties(CSlide* pSlide, CTheme* pTheme, CLayout* pLayout)
{
NSPresentationEditor::CTextAttributesEx* pAttributes = &m_pShape->m_oText;
PPT_FORMAT::CTextAttributesEx* pAttributes = &m_pShape->m_oText;
int nCountColors = 0;
if (NULL != pTheme)
nCountColors = (int)pTheme->m_arColorScheme.size();
@ -99,31 +99,32 @@ void NSPresentationEditor::CShapeElement::SetupTextProperties(CSlide* pSlide, CT
{
if ((pRun->fontRef.is_init()) && (pRun->fontRef.get() < pTheme->m_arFonts.size()))
{
pRun->FontProperties = new CFontProperties();
pRun->FontProperties->SetFont(pTheme->m_arFonts[pRun->fontRef.get()]);
pRun->font.font = new CFontProperty(pTheme->m_arFonts[pRun->fontRef.get()]);
if (1 < pRun->fontRef.get())
pRun->fontRef.reset();
//if (1 < pRun->fontRef.get())
// pRun->fontRef.reset();
}
if ((pRun->EAFontRef.is_init()) && (pRun->EAFontRef.get() < pTheme->m_arFonts.size()))
if ((pRun->ansiFontRef.is_init()) && (pRun->ansiFontRef.get() < pTheme->m_arFonts.size()))
{
pRun->FontPropertiesEA = new CFontProperties();
pRun->FontPropertiesEA->SetFont(pTheme->m_arFonts[pRun->EAFontRef.get()]);
pRun->font.ansi = new CFontProperty(pTheme->m_arFonts[pRun->ansiFontRef.get()]);
}
if ((pRun->SymbolFontRef.is_init()) && (pRun->SymbolFontRef.get() < pTheme->m_arFonts.size()))
if ((pRun->eaFontRef.is_init()) && (pRun->eaFontRef.get() < pTheme->m_arFonts.size()))
{
pRun->FontPropertiesSym = new CFontProperties();
pRun->FontPropertiesSym->SetFont(pTheme->m_arFonts[pRun->SymbolFontRef.get()]);
pRun->font.ea = new CFontProperty(pTheme->m_arFonts[pRun->eaFontRef.get()]);
}
if ((pRun->symbolFontRef.is_init()) && (pRun->symbolFontRef.get() < pTheme->m_arFonts.size()))
{
pRun->font.sym = new CFontProperty(pTheme->m_arFonts[pRun->symbolFontRef.get()]);
}
}
}
}
}
bool NSPresentationEditor::CShapeElement::SetUpTextPlaceholder(std::wstring newText)
bool PPT_FORMAT::CShapeElement::SetUpTextPlaceholder(std::wstring newText)
{
bool result = false;
NSPresentationEditor::CTextAttributesEx* pText = &m_pShape->m_oText;
PPT_FORMAT::CTextAttributesEx* pText = &m_pShape->m_oText;
for (size_t p = 0 ; p < pText->m_arParagraphs.size(); p++) //тут по всем -> 1-(33).ppt
{

View File

@ -282,7 +282,7 @@ namespace PPTX2EditorAdvanced
}
namespace NSPresentationEditor
namespace PPT_FORMAT
{
class CImageElement : public CElement
{

View File

@ -34,7 +34,7 @@
#include "../../../DesktopEditor/common/ASCVariant.h"
namespace NSPresentationEditor
namespace PPT_FORMAT
{
class CTextRange
{

View File

@ -32,8 +32,126 @@
#pragma once
#include "Element.h"
namespace NSPresentationEditor
namespace PPT_FORMAT
{
enum eSlideSize
{
SS_Screen = 0,
SS_LetterPaper = 1,
SS_A4Paper = 2,
SS_35mm = 3,
SS_Overhead = 4,
SS_Banner = 5,
SS_Custom = 6
};
enum ePlaceholderType
{
PT_None = 0,
PT_MasterTitle = 1,
PT_MasterBody = 2,
PT_MasterCenterTitle = 3,
PT_MasterSubTitle = 4,
PT_MasterNotesSlideImage = 5,
PT_MasterNotesBody = 6,
PT_MasterDate = 7,
PT_MasterSlideNumber = 8,
PT_MasterFooter = 9,
PT_MasterHeader = 10,
PT_NotesSlideImage = 11,
PT_NotesBody = 12,
PT_Title = 13,
PT_Body = 14,
PT_CenterTitle = 15,
PT_SubTitle = 16,
PT_VerticalTitle = 17,
PT_VerticalBody = 18,
PT_Object = 19,
PT_Graph = 20,
PT_Table = 21,
PT_ClipArt = 22,
PT_OrgChart = 23,
PT_Media = 24
};
enum Instances
{
CollectionOfSlides = 0,
CollectionOfMasterSlides = 1,
CollectionOfNotesSlides = 2
};
enum eSlideLayoutType
{
SL_TitleSlide = 0,
SL_TitleBody = 1,
SL_MasterTitle = 2,
SL_TitleOnly = 7,
SL_TwoColumns = 8,
SL_TwoRows = 9,
SL_ColumnTwoRows = 10,
SL_TwoRowsColumn = 11,
SL_TwoColumnsRow = 13,
SL_FourObjects = 14,
SL_BigObject = 15,
SL_Blank = 16,
SL_VerticalTitleBody = 17,
SL_VerticalTwoRows = 18
};
enum eTextType
{
Tx_TYPE_TITLE = 0,
Tx_TYPE_BODY = 1,
Tx_TYPE_NOTES = 2,
Tx_TYPE_OTHER = 4,
Tx_TYPE_CENTERBODY = 5,
Tx_TYPE_CENTERTITLE = 6,
Tx_TYPE_HALFBODY = 7,
Tx_TYPE_QUARTERBODY = 8,
NoPresent = 0xFF
};
static void CorrectPlaceholderType(int & type)
{
switch (type)
{
case PT_MasterTitle: type = PT_Title; break;
case PT_MasterBody: type = PT_Body; break;
case PT_MasterCenterTitle: type = PT_CenterTitle; break;
case PT_MasterSubTitle: type = PT_SubTitle; break;
case PT_MasterNotesSlideImage: type = PT_NotesSlideImage; break;
case PT_MasterNotesBody: type = PT_NotesBody; break;
}
}
static bool isTitlePlaceholder(int type)
{
switch (type)
{
case PT_MasterTitle:
case PT_MasterCenterTitle:
case PT_Title:
case PT_CenterTitle:
case PT_VerticalTitle:
return true;
default:
return false;
}
}
static bool isBodyPlaceholder(int type)
{
switch (type)
{
case PT_MasterBody:
case PT_Body:
case PT_VerticalBody:
return true;
default:
return false;
}
}
class CLayout
{
public:
@ -129,13 +247,13 @@ namespace NSPresentationEditor
return lFound;
}
NSPresentationEditor::CColor GetColor(const LONG& lIndexScheme)
ODRAW::CColor GetColor(const LONG& lIndexScheme)
{
if (lIndexScheme < (LONG)m_arColorScheme.size())
{
return m_arColorScheme[lIndexScheme];
}
return NSPresentationEditor::CColor();
return ODRAW::CColor();
}
static void CheckPlaceholderStyle(std::wstring strStyleName, LONG& lType, LONG& lLevel, LONG& lTypeStyle)

View File

@ -35,7 +35,7 @@
#include <math.h>
namespace NSPresentationEditor
namespace ODRAW
{
class CDoubleRect
{

View File

@ -36,7 +36,7 @@
#include "PPTXShape/PptxShape.h"
#include "PPTShape/PptShape.h"
using namespace NSPresentationEditor;
using namespace ODRAW;
CBaseShapePtr CBaseShape::CreateByType(NSBaseShape::ClassType ClassType, int ShapeType)
{

View File

@ -36,7 +36,7 @@
#include <boost/shared_ptr.hpp>
namespace NSPresentationEditor
namespace ODRAW
{
using namespace NSBaseShape;
class CHandle_
@ -49,7 +49,6 @@ namespace NSPresentationEditor
std::wstring polar;
std::wstring radiusrange;
public:
CHandle_()
{
}

View File

@ -45,14 +45,14 @@
#include <math.h>//M_PI
#include <vector>
namespace NSPresentationEditor
namespace ODRAW
{
class CDoublePoint
{
public:
double dX;
double dY;
public:
CDoublePoint()
{
dX = 0;
@ -75,7 +75,7 @@ namespace NSPresentationEditor
namespace NSBaseShape
{
enum ClassType {unknown, pptx, ppt, odp};// Перечисление можно расширять
enum ClassType {unknown, pptx, ppt, odp};// Перечисление можно расширять
}
enum RulesType
@ -169,14 +169,10 @@ namespace NSPresentationEditor
m_dAngle = 0;
m_lFlags = 0;
}
public:
CGraphicPath()
{
InternalClear();
}
virtual void Draw(IRenderer* pRenderer)
{
if (NULL == pRenderer)
@ -241,15 +237,12 @@ namespace NSPresentationEditor
pRenderer->EndCommand(c_nPathType);
}
public:
class CPart
{
public:
RulesType m_eType;
std::vector<CDoublePoint> m_arPoints;
public:
CPart() : m_eType(rtMoveTo), m_arPoints()
{
}
@ -903,8 +896,6 @@ namespace NSPresentationEditor
m_arParts.clear();
}
public:
std::vector<CPart> m_arParts;
int Metric;
bool m_bFill;

View File

@ -32,7 +32,7 @@
#pragma once
#include "../../../../../../Common/DocxFormat/Source/Base/Types_32.h"
namespace NSOfficeDrawing
namespace ODRAW
{
#define BINARY_READER_CHECK_OUT_RANGE(index, count) \
if (index > count) \
@ -63,7 +63,6 @@ namespace NSOfficeDrawing
m_lCount = 0;
}
public:
LONG ReadLONG() // int32 подразумевается
{
DWORD lOldOrigin = m_lOrigin;

View File

@ -38,7 +38,7 @@
namespace NSCustomVML
{
using namespace NSPresentationEditor;
using namespace PPT_FORMAT;
using namespace NSGuidesVML;
class CSegment
@ -215,7 +215,7 @@ namespace NSCustomVML
m_nCount = (mem >> 5) & 0x00FF;
}
void Read(NSOfficeDrawing::CBinaryReader& oReader)//from binary ms segments
void Read(ODRAW::CBinaryReader& oReader)//from binary ms segments
{
WORD mem = oReader.ReadWORD();
@ -411,7 +411,7 @@ namespace NSCustomVML
m_param_value2 = StreamUtils::ReadWORD(pStream);
m_param_value3 = StreamUtils::ReadWORD(pStream);
}
void Read(NSOfficeDrawing::CBinaryReader& oReader)
void Read(ODRAW::CBinaryReader& oReader)
{
WORD ftType = oReader.ReadWORD();
@ -584,7 +584,7 @@ namespace NSCustomVML
}
void LoadConnectionSitesDir(CProperty* pProperty)
{
NSOfficeDrawing::CBinaryReader oReader(pProperty->m_pOptions, pProperty->m_lValue);
ODRAW::CBinaryReader oReader(pProperty->m_pOptions, pProperty->m_lValue);
m_arConnectionSitesDir.clear();
WORD lCount = (WORD)(pProperty->m_lValue / 4);
@ -598,7 +598,7 @@ namespace NSCustomVML
}
void LoadConnectionSites(CProperty* pProperty)
{
NSOfficeDrawing::CBinaryReader oReader(pProperty->m_pOptions, pProperty->m_lValue);
ODRAW::CBinaryReader oReader(pProperty->m_pOptions, pProperty->m_lValue);
m_arConnectionSites.clear();
WORD lCount = (WORD)(pProperty->m_lValue / 8);
@ -641,7 +641,7 @@ namespace NSCustomVML
}
void LoadVertices(CProperty* pProperty)
{
NSOfficeDrawing::CBinaryReader oReader(pProperty->m_pOptions, pProperty->m_lValue);
ODRAW::CBinaryReader oReader(pProperty->m_pOptions, pProperty->m_lValue);
m_arVertices.clear();
@ -720,7 +720,7 @@ namespace NSCustomVML
}
void LoadSegments(CProperty* pProperty)
{
NSOfficeDrawing::CBinaryReader oReader(pProperty->m_pOptions, pProperty->m_lValue);
ODRAW::CBinaryReader oReader(pProperty->m_pOptions, pProperty->m_lValue);
m_arSegments.clear();
WORD lCount = (WORD)(pProperty->m_lValue / 2);
@ -755,7 +755,7 @@ namespace NSCustomVML
}
void LoadGuides(CProperty* pProperty)
{
NSOfficeDrawing::CBinaryReader oReader(pProperty->m_pOptions, pProperty->m_lValue);
ODRAW::CBinaryReader oReader(pProperty->m_pOptions, pProperty->m_lValue);
WORD lCount = (WORD)(pProperty->m_lValue / 4);
for (WORD lIndex = 0; lIndex < lCount; ++lIndex)
@ -767,7 +767,7 @@ namespace NSCustomVML
}
void LoadInscribe(CProperty* pProperty)
{
NSOfficeDrawing::CBinaryReader oReader(pProperty->m_pOptions, pProperty->m_lValue);
ODRAW::CBinaryReader oReader(pProperty->m_pOptions, pProperty->m_lValue);
m_arInscribe.clear();
WORD lCount = (WORD)(pProperty->m_lValue / 16);

View File

@ -42,7 +42,7 @@
class CProperty
{
public:
NSOfficeDrawing::PropertyId m_ePID;
ODRAW::ePropertyId m_ePID;
bool m_bIsBlip;
bool m_bComplex;
_UINT32 m_lValue;
@ -52,7 +52,7 @@ public:
CProperty()
{
m_ePID = NSOfficeDrawing::left;
m_ePID = ODRAW::left;
m_bIsBlip = false;
m_bComplex = false;
m_lValue = 0;
@ -70,7 +70,7 @@ public:
// только пока без учета bComplex
// т.к. Complex - учитывается в контейнере, хранящем все проперти
USHORT lMem = StreamUtils::ReadWORD(pStream);
m_ePID = (NSOfficeDrawing::PropertyId)(lMem & 0x3FFF);
m_ePID = (ODRAW::ePropertyId)(lMem & 0x3FFF);
m_bIsBlip = ((lMem & 0x4000) == 0x4000);
m_bComplex = ((lMem & 0x8000) == 0x8000);
@ -82,23 +82,23 @@ public:
{
if (m_bComplex && m_lValue > 0)
{
if (NSOfficeDrawing::dgmConstrainBounds == m_ePID ||
NSOfficeDrawing::fillShadeColors == m_ePID ||
NSOfficeDrawing::lineDashStyle == m_ePID ||
NSOfficeDrawing::pAdjustHandles == m_ePID ||
NSOfficeDrawing::pConnectionSites == m_ePID ||
NSOfficeDrawing::pConnectionSitesDir == m_ePID ||
NSOfficeDrawing::pInscribe == m_ePID ||
NSOfficeDrawing::pSegmentInfo == m_ePID ||
NSOfficeDrawing::pVertices == m_ePID ||
NSOfficeDrawing::pGuides == m_ePID ||
NSOfficeDrawing::pWrapPolygonVertices == m_ePID ||
NSOfficeDrawing::pRelationTbl == m_ePID ||
NSOfficeDrawing::tableRowProperties == m_ePID ||
NSOfficeDrawing::lineLeftDashStyle == m_ePID ||
NSOfficeDrawing::lineTopDashStyle == m_ePID ||
NSOfficeDrawing::lineRightDashStyle == m_ePID ||
NSOfficeDrawing::lineBottomDashStyle == m_ePID)
if (ODRAW::dgmConstrainBounds == m_ePID ||
ODRAW::fillShadeColors == m_ePID ||
ODRAW::lineDashStyle == m_ePID ||
ODRAW::pAdjustHandles == m_ePID ||
ODRAW::pConnectionSites == m_ePID ||
ODRAW::pConnectionSitesDir == m_ePID ||
ODRAW::pInscribe == m_ePID ||
ODRAW::pSegmentInfo == m_ePID ||
ODRAW::pVertices == m_ePID ||
ODRAW::pGuides == m_ePID ||
ODRAW::pWrapPolygonVertices == m_ePID ||
ODRAW::pRelationTbl == m_ePID ||
ODRAW::tableRowProperties == m_ePID ||
ODRAW::lineLeftDashStyle == m_ePID ||
ODRAW::lineTopDashStyle == m_ePID ||
ODRAW::lineRightDashStyle == m_ePID ||
ODRAW::lineBottomDashStyle == m_ePID)
{
WORD nElems = StreamUtils::ReadWORD(pStream);
WORD nElemsAlloc = StreamUtils::ReadWORD(pStream);
@ -122,7 +122,7 @@ public:
switch( m_ePID )
{
case NSOfficeDrawing::fillBlip:
case ODRAW::fillBlip:
{
SRecordHeader oHeader;
if (oHeader.ReadFromStream(pStream) == false )

View File

@ -31,187 +31,9 @@
*/
#pragma once
namespace NSOfficePPT
namespace ODRAW
{
enum SlideSizeType
{
OnScreen = 0,
LetterSizedPaper = 1,
A4Paper = 2,
Size35mm = 3,
Overhead = 4,
Banner = 5,
Custom = 6
};
enum StyleMask
{
None = 0,
IsBold = 1 << 0,
IsItalic = 1 << 1,
IsUnderlined = 1 << 2,
HasShadow = 1 << 4,
HasAsianSmartQuotes = 1 << 5,
HasHorizonNumRendering = 1 << 7,
IsEmbossed = 1 << 9,
ExtensionNibble = 0xF << 10
};
enum CharacterMask
{
_None = 0,
StyleFlagsFieldPresent = 0xFFFF,
TypefacePresent = 1 << 16,
SizePresent = 1 << 17,
ColorPresent = 1 << 18,
PositionPresent = 1 << 19,
FEOldTypefacePresent = 1 << 21,
ANSITypefacePresent = 1 << 22,
SymbolTypefacePresent = 1 << 23
};
enum PlaceholderEnum
{
__None = 0,
MasterTitle = 1,
MasterBody = 2,
MasterCenteredTitle = 3,
MasterSubtitle = 4,
MasterNotesSlideImage = 5,
MasterNotesBody = 6,
MasterDate = 7,
MasterSlideNumber = 8,
MasterFooter = 9,
MasterHeader = 10,
NotesSlideImage = 11,
NotesBody = 12,
Title = 13,
Body = 14,
CenteredTitle = 15,
Subtitle = 16,
VerticalTextTitle = 17,
VerticalTextBody = 18,
Object = 19,
Graph = 20,
Table = 21,
ClipArt = 22,
OrganizationChart = 23,
MediaClip = 24
};
enum ParagraphMask
{
___None = 0,
HasBullet = 1 << 0,
BulletHasFont = 1 << 1,
BulletHasColor = 1 << 2,
BulletHasSize = 1 << 3,
BulletFlagsFieldExists = HasBullet | BulletHasFont | BulletHasColor | BulletHasSize,
BulletFont = 1 << 4,
BulletColor = 1 << 5,
BulletSize = 1 << 6,
BulletChar = 1 << 7,
LeftMargin = 1 << 8,
Indent = 1 << 10,
Align = 1 << 11,
LineSpacing = 1 << 12,
SpaceBefore = 1 << 13,
SpaceAfter = 1 << 14,
DefaultTabSize = 1 << 15,
FontAlign = 1 << 16,
CharWrap = 1 << 17,
WordWrap = 1 << 18,
Overflow = 1 << 19,
WrapFlagsFieldExists = CharWrap | WordWrap | Overflow,
TabStops = 1 << 20,
TextDirection = 1 << 21,
BulletBlip = 1 << 23,
BulletScheme = 1 << 24,
BulletHasScheme = 1 << 25
};
enum Instances
{
CollectionOfSlides = 0,
CollectionOfMasterSlides = 1,
CollectionOfNotesSlides = 2
};
enum SlideLayoutType
{
TitleSlide = 0,
TitleAndBody = 1,
TitleMaster = 2,
MasterNotes = 4,
NotesTitleAndBody = 5,
Handout = 6,
TitleOnly = 7,
TwoColumnsAndTitle = 8,
TwoRowsAndTitle = 9,
TwoColumnsRightTwoRows = 10,
TwoColumnsLeftTwoRows = 11,
TwoRowsBottomTwoColumns = 12,
TwoRowsTopTwoColumns = 13,
FourObjects = 14,
BigObject = 15,
Blank = 16,
VerticalTitleRightBodyLeft = 17,
VerticalTitleRightBodyLeftTwoRows= 18
};
enum TextType
{
_Title = 0,
_Body = 1,
Notes = 2,
Outline = 3,
Other = 4,
CenterBody = 5,
CenterTitle = 6,
HalfBody = 7,
QuarterBody = 8,
NoPresent = 0xFF
};
enum ActionTable
{
NoAction = 0,
MacroAction = 1,
RunProgramAction = 2,
JumpAction = 3,
HyperlinkAction = 4,
OLEAction = 5,
MediaAction = 6,
CustomShowAction = 7
};
enum JumpTable
{
NoJump = 0,
NextSlide = 1,
PreviousSlide = 2,
FirstSlide = 3,
LastSlide = 4,
LastSlideViewed = 5,
EndShow = 6,
SlideId = 7
};
}
namespace NSOfficeDrawing
{
enum ShapePath
enum eShapePath
{
shapeLines, // A line of straight segments
shapeLinesClosed, // A closed polygonal object
@ -220,7 +42,7 @@ namespace NSOfficeDrawing
shapeComplex // pSegmentInfo must be non-empty
};
enum WrapMode
enum eWrapMode
{
wrapSquare,
wrapByPoints,
@ -229,7 +51,7 @@ namespace NSOfficeDrawing
wrapThrough
};
enum BwMode
enum eBwMode
{
bwColor, // only used for predefined shades
bwAutomatic, // depends on object type
@ -245,7 +67,7 @@ namespace NSOfficeDrawing
bwNumModes // number of Black and white modes
};
enum AnchorMode
enum eAnchorMode
{
anchorTop,
anchorMiddle,
@ -259,7 +81,7 @@ namespace NSOfficeDrawing
anchorBottomCenteredBaseline
};
enum CdirMode
enum eCdirMode
{
cdir0, // Right
cdir90, // Down
@ -267,7 +89,7 @@ namespace NSOfficeDrawing
cdir270 // Up
};
enum CxStyle
enum eCxStyle
{
cxstyleStraight = 0,
cxstyleBent,
@ -275,7 +97,7 @@ namespace NSOfficeDrawing
cxstyleNone
};
enum CXKMode
enum eCXKMode
{
cxkNone = 0, // No connection sites
cxkSegments = 1, // Connection sites at the segments
@ -283,7 +105,7 @@ namespace NSOfficeDrawing
cxkRect = 3 // Use the connection sites for a rectangle
};
enum TxflMode
enum eTxflMode
{
txflHorzN, //Horizontal non-@
txflTtoBA, //Top to Bottom @-font
@ -293,14 +115,14 @@ namespace NSOfficeDrawing
txflVertN //Vertical, non-@
};
enum TxDirMode
enum eTxDirMode
{
txdirLTR, // left-to-right text direction
txdirRTL, // right-to-left text direction
txdirContext // context text direction
};
enum SpcotMode
enum eSpcotMode
{
spcotRightAngle = 1,
spcotOneSegment = 2,
@ -308,7 +130,7 @@ namespace NSOfficeDrawing
spcotThreeSegment = 4
};
enum SpcoaMode
enum eSpcoaMode
{
spcoaAny,
spcoa30,
@ -318,7 +140,7 @@ namespace NSOfficeDrawing
spcoa0
};
enum SpcodMode
enum eSpcodMode
{
spcodTop,
spcodCenter,
@ -326,7 +148,7 @@ namespace NSOfficeDrawing
spcodSpecified
};
enum GeoTextAlign
enum eGeoTextAlign
{
alignTextStretch, /* Stretch each line of text to fit width. */
alignTextCenter, /* Center text on width. */
@ -337,7 +159,7 @@ namespace NSOfficeDrawing
alignTextInvalid /* Invalid */
};
enum BlipFlags
enum eBlipFlags
{
blipflagDefault = 0,
blipflagComment = 0, // Blip name is a comment
@ -361,14 +183,14 @@ namespace NSOfficeDrawing
BoundingCube // Generate a bounding cube
};
enum XFormType
enum eXFormType
{
xformAbsolute, // Apply transform in absolute space centered on shape
xformShape, // Apply transform to shape geometry
xformDrawing // Apply transform in drawing space
};
enum ShadowType
enum eShadowType
{
shadowOffset, // N pixel offset shadow
shadowDouble, // Use second offset too
@ -378,7 +200,7 @@ namespace NSOfficeDrawing
shadowEmbossOrEngrave
};
enum DzType
enum eDzType
{
dztypeMin = 0,
dztypeDefault = 0, // Default size, ignore the values
@ -396,7 +218,7 @@ namespace NSOfficeDrawing
dztypeMax = 11
};
enum FillType
enum eFillType
{
fillSolid, // Fill with a solid color
fillPattern, // Fill with a pattern (bitmap)
@ -413,7 +235,7 @@ namespace NSOfficeDrawing
fillBackground // Use the background fill color/pattern
};
enum ShadeType
enum eShadeType
{
shadeNone = 0, // Interpolate without correction between RGBs
shadeGamma = 1, // Apply gamma correction to colors
@ -433,7 +255,7 @@ namespace NSOfficeDrawing
shadeDefault = (shadeGamma | shadeSigma | (16384 << shadeParameterShift))
};
enum LinesStyle
enum eLinesStyle
{
lineSimple, // Single line (of width lineWidth)
lineDouble, // Double lines of equal width
@ -442,7 +264,7 @@ namespace NSOfficeDrawing
lineTriple // Three lines, thin, thick, thin
};
enum LineType
enum eLineType
{
lineSolidType, // Fill with a solid color
linePattern, // Fill with a pattern (bitmap)
@ -450,7 +272,7 @@ namespace NSOfficeDrawing
linePicture // Center a picture in the shape
};
enum LineDashing
enum eLineDashing
{
lineSolid, // Solid (continuous) pen
lineDashSys, // PS_DASH system dash style
@ -465,7 +287,7 @@ namespace NSOfficeDrawing
lineLongDashDotDotGEL // long dash short dash short dash
};
enum LineEnd
enum eLineEnd
{
lineNoEnd,
lineArrowEnd,
@ -475,35 +297,35 @@ namespace NSOfficeDrawing
lineArrowOpenEnd
};
enum LineEndWidth
enum eLineEndWidth
{
lineNarrowArrow,
lineMediumWidthArrow,
lineWideArrow
};
enum LineEndLength
enum eLineEndLength
{
lineShortArrow,
lineMediumLenArrow,
lineLongArrow
};
enum _LineJoin
enum eLineJoin
{
lineJoinBevel, // Join edges by a straight line
lineJoinMiter, // Extend edges until they join
lineJoinRound // Draw an arc between the two edges
};
enum _LineCap
enum eLineCap
{
lineEndCapRound, // Rounded ends - the default
lineEndCapSquare, // Square protrudes by half line width
lineEndCapFlat // Line ends at end point
};
enum SGF
enum eSGF
{
// Arithmetic
sgfSum, // guide := value + parameter1 - parameter2
@ -529,7 +351,7 @@ namespace NSOfficeDrawing
sgfTan // guide := value * tan(param1) [param2 ignored]
};
enum SGVT
enum eSGVT
{
sgvtV = 0x2000, // Value is adjust value or guide
sgvtP1 = 0x4000, // Parameter1 is adjust value or guide
@ -584,14 +406,14 @@ namespace NSOfficeDrawing
// <- а нужно ли...?
////////////////////////////////////////////////////////////
enum BlipUsage
enum eBlipUsage
{
blipUsageDefault, // All non-texture fill blips get this.
blipUsageTexture,
blipUsageMax = 255 // Since this is stored in a byte
};
enum BlipType
enum eBlipType
{
// GEL provided types...
blipERROR = 0, // An error occured during loading
@ -608,7 +430,7 @@ namespace NSOfficeDrawing
blipLastClient = 255 // Last client defined blip type
};
enum BlipSignature
enum eBlipSignature
{
biUNKNOWN = 0,
biWMF = 0x216, // Metafile header then compressed WMF
@ -623,14 +445,14 @@ namespace NSOfficeDrawing
biClient = 0x800, // Clients should set this bit
};
enum BlipFilter
enum eBlipFilter
{
filterAdaptive = 0,
filterNone = 254,
filterTest = 255
};
enum DGMNK
enum eDGMNK
{
dgmnkMin = 0,
dgmnkNode = dgmnkMin,
@ -645,7 +467,7 @@ namespace NSOfficeDrawing
dgmnkNil = 0xFFFF
};
enum DGMLO
enum eDGMLO
{
dgmloFirst = 0,
dgmloMin = dgmloFirst,
@ -689,7 +511,7 @@ namespace NSOfficeDrawing
dgmloNil = 0xFF
};
enum ODGMT
enum eODGMT
{
dgmtMin = 0,
dgmtCanvas = dgmtMin,
@ -704,7 +526,7 @@ namespace NSOfficeDrawing
dgmtNil = 0x0FFF
};
enum DGMST
enum eDGMST
{
/***WARNING: This is written out to the file format! ***/
/***NOTE: If you add a new style enum, you need to update vrgdgmstdesc ***/
@ -815,7 +637,7 @@ namespace NSOfficeDrawing
dgmstNil = 0xFFFF
};
enum SPT
enum eSPT
{
sptMin = 0,
sptNotPrimitive = sptMin,
@ -1025,7 +847,7 @@ namespace NSOfficeDrawing
sptNil = 0x0FFF
};
enum PropertyId
enum ePropertyId
{
//Transform
left=0,
@ -1083,7 +905,7 @@ namespace NSOfficeDrawing
cropFromBottom=257,
cropFromLeft=258,
cropFromRight=259,
Pib=260,
pib=260,
pibName=261,
pibFlags=262,
pictureTransparent=263,
@ -1441,7 +1263,7 @@ namespace NSOfficeDrawing
namespace NSAnimation
{
enum ConditionType
enum eConditionType
{
_NA, // obsolete identifier; not used
ctBegin,
@ -1452,7 +1274,7 @@ namespace NSOfficeDrawing
ConditionType_MaxEnumIDs
};
enum TLTimeNodeType
enum eTLTimeNodeType
{
TLTimeNodeTypeParallel = 0,
TLTimeNodeTypeSequential,
@ -1462,7 +1284,7 @@ namespace NSOfficeDrawing
TLTimeNodeType_MaxEnumIDs
};
enum TLTimeNodeRestartType
enum eTLTimeNodeRestartType
{
TLR_NoRestartType = 0,
TLR_AlwaysRestart = 1,
@ -1471,7 +1293,7 @@ namespace NSOfficeDrawing
TLTimeNodeRestartType_MaxEnumIDs = 4
};
enum TLTimeNodeFillType
enum eTLTimeNodeFillType
{
TLF_NoFillType = 0,
TLF_FillRemove = 1,
@ -1481,7 +1303,7 @@ namespace NSOfficeDrawing
TLTimeNodeFillType_MaxEnumIDs = 5
};
enum TLTimeNodeSyncType
enum eTLTimeNodeSyncType
{
TLS_NoSyncType = 0,
TLS_CanSlipSyncType = 1,
@ -1496,7 +1318,7 @@ namespace NSOfficeDrawing
const int groupingTypeProperty = (1 << 3);
const int durationProperty = (1 << 4);
enum TotEventType
enum eTotEventType
{
totNone,
totVisualElement,
@ -1505,7 +1327,7 @@ namespace NSOfficeDrawing
TriggerObjectType_MaxEnumIDs
};
enum TriggerEventType
enum eTriggerEventType
{
tetNone = 0,
tetOnBegin,
@ -1522,7 +1344,7 @@ namespace NSOfficeDrawing
TriggerEventType_MaxEnumIDs
};
enum RuntimeNodeReferenceType
enum eRuntimeNodeReferenceType
{
rnrtWithFirstChild,
rnrtWithLastChild,
@ -1530,7 +1352,7 @@ namespace NSOfficeDrawing
RuntimeNodeReferenceType_MaxEnumIDs
};
enum Type
enum eType
{
RepeatCount = 0, // The number of times to repeat
RepeatDur, // Duration of repeats
@ -1545,7 +1367,7 @@ namespace NSOfficeDrawing
Type_MaxEnumIDs
};
enum PropertyUsedFlag
enum ePropertyUsedFlag
{
PUF_NONE = 0,
PUF_Additive = 1 << 0,
@ -1557,7 +1379,7 @@ namespace NSOfficeDrawing
PUF_ByFormula = 1 << 6
};
enum Additive
enum eAdditive
{
BaseAdditive,
SumAdditive,
@ -1567,21 +1389,21 @@ namespace NSOfficeDrawing
Additive_MaxEnumIDs
};
enum Accumulate
enum eAccumulate
{
NoAccumulate,
AlwaysAccumulate,
Accumulate_MaxEnumIDs
};
enum TransformType
enum eTransformType
{
PropertyTransformType,
ImageTransformType,
TransformType_MaxEnumIDs
};
enum CalcMode
enum eCalcMode
{
DiscreteMode,
LinearMode,
@ -1589,7 +1411,7 @@ namespace NSOfficeDrawing
CalcMode_MaxEnumIDs
};
enum AnimatePropertyUsedFlag
enum eAnimatePropertyUsedFlag
{
APUF_NONE = 0,
APUF_By = 1 << 0,
@ -1600,7 +1422,7 @@ namespace NSOfficeDrawing
APUF_ValueType = 1 << 5
};
enum ValueType
enum eValueType
{
StringType,
NumberType,
@ -1608,7 +1430,7 @@ namespace NSOfficeDrawing
ValueType_MaxEnumIDs
};
enum AnimateColorPropertyUsedFlag
enum eAnimateColorPropertyUsedFlag
{
ACPUF_NONE = 0,
ACPUF_By = 1 << 0,
@ -1618,7 +1440,7 @@ namespace NSOfficeDrawing
ACPUF_Direction = 1 << 4
};
enum ColorModel
enum eColorModel
{
RGBColorModel = 0,
HSLColorModel = 1,
@ -1626,7 +1448,7 @@ namespace NSOfficeDrawing
ColorModel_MaxEnumIDs
};
enum AnimateEffectPropertyUsedFlag
enum eAnimateEffectPropertyUsedFlag
{
AEPUF_NONE = 0,
AEPUF_Transition = 1 << 0,
@ -1635,7 +1457,7 @@ namespace NSOfficeDrawing
AEPUF_RuntimeContext_Obsolete = 1 << 3 // Keep this for backward binary persistence
};
enum Transition
enum eTransition
{
TransitionIn,
TransitionOut,
@ -1643,7 +1465,7 @@ namespace NSOfficeDrawing
Transition_MaxEnumIDs
};
enum AnimateMotionPropertyUsedFlag
enum eAnimateMotionPropertyUsedFlag
{
AMPUF_NONE = 0,
AMPUF_By = 1 << 0,
@ -1656,7 +1478,7 @@ namespace NSOfficeDrawing
AMPUF_PointsTypes = 1 << 7
};
enum Origin
enum eOrigin
{
DefaultOrigin,
ParentOrigin,
@ -1664,7 +1486,7 @@ namespace NSOfficeDrawing
Origin_MaxEnumIDs
};
enum AnimateRotationPropertyUsedFlag
enum eAnimateRotationPropertyUsedFlag
{
ARPUF_NONE = 0,
ARPUF_By = 1 << 0,
@ -1673,14 +1495,14 @@ namespace NSOfficeDrawing
ARPUF_Direction = 1 << 3
};
enum Direction
enum eAnimateDirection
{
Clockwise,
CounterClockwise,
Direction_MaxEnumIDs
};
enum AnimateScalePropertyUsedFlag
enum eAnimateScalePropertyUsedFlag
{
ASPUF_NONE = 0,
ASPUF_By = 1 << 0,
@ -1689,21 +1511,21 @@ namespace NSOfficeDrawing
ASPUF_ZoomContents = 1 << 3
};
enum SetPropertyUsedFlag
enum eSetPropertyUsedFlag
{
SPUF_NONE = 0,
SPUF_To = 1 << 0,
SPUF_ValueType = 1 << 1
};
enum CommandPropertyUsedFlag
enum eCommandPropertyUsedFlag
{
CPUF_NONE = 0,
CPUF_Type = 1 << 0,
CPUF_Command = 1 << 1
};
enum CommandType
enum eCommandType
{
EventType,
CallType,
@ -1711,7 +1533,7 @@ namespace NSOfficeDrawing
CommandType_MaxEnumIDs
};
enum TLTimePropertyID
enum eTLTimePropertyID
{
tpidUnknown = 0,
tpidID = 1, // string
@ -1743,7 +1565,7 @@ namespace NSOfficeDrawing
tpidDVDEndTime = 30
};
enum IterationType
enum eIterationType
{
AllAtOnce,
ByWord,
@ -1751,21 +1573,21 @@ namespace NSOfficeDrawing
IterationType_MaxEnumIDs
};
enum IntervalType
enum eIntervalType
{
Seconds,
Percentage,
IntervalType_MaxEnumIDs
};
enum _Direction
enum eDirection
{
Backwards,
Forwards,
_Direction_MaxEnumIDs
};
enum PropertyUsed
enum ePropertyUsed
{
DirectionProperty = 1 << 0,
IterationTypeProperty = 1 << 1,
@ -1773,28 +1595,28 @@ namespace NSOfficeDrawing
IntervalTypeProperty = 1 << 3,
};
enum ConcurrencyType
enum eConcurrencyType
{
Disabled,
Enabled,
ConcurrencyType_MaxEnumIDs
};
enum NextActionType
enum eNextActionType
{
NoNextActionType,
Seek,
NextActionType_MaxEnumIDs
};
enum PreviousActionType
enum ePreviousActionType
{
NoPreviousActionType,
SkipTimed,
PreviousActionType_MaxEnumIDs
};
enum EnableNextType
enum eEnableNextType
{
End,
Begin,
@ -1807,7 +1629,7 @@ namespace NSOfficeDrawing
const int SF_PreviousAction = (1 << 2);
const int SF_EnableNext = (1 << 3);
enum _Type
enum eAnimateValueType
{
None = -1,
Bool = 0,

View File

@ -40,7 +40,7 @@ public:
{
m_bConcentricFill = true;
m_eJoin = NSOfficeDrawing::lineJoinMiter;
m_eJoin = ODRAW::lineJoinMiter;
//Encaps: Flat
m_strPath = _T("m@0@1l@2@3@4@5nfem@4,l@4,21600nfem,l21600,r,21600l,21600xe");

View File

@ -39,7 +39,7 @@ public:
CAccentCallout1Type()
{
m_bConcentricFill = true;
m_eJoin = NSOfficeDrawing::lineJoinMiter;
m_eJoin = ODRAW::lineJoinMiter;
//Encaps: Flat
m_strPath = _T("m@0@1l@2@3nfem@2,l@2,21600nfem,l21600,r,21600l,21600nsxe");

View File

@ -39,7 +39,7 @@ public:
CAccentCallout2Type()
{
m_bConcentricFill = true;
m_eJoin = NSOfficeDrawing::lineJoinMiter;
m_eJoin = ODRAW::lineJoinMiter;
//Encaps: Flat
m_strPath = _T("m@0@1l@2@3@4@5nfem@4,l@4,21600nfem,l21600,r,21600l,21600nsxe");

View File

@ -40,7 +40,7 @@ public:
{
m_bConcentricFill = true;
m_eJoin = NSOfficeDrawing::lineJoinMiter;
m_eJoin = ODRAW::lineJoinMiter;
//Encaps: Flat
m_strPath = _T("m@0@1l@2@3@4@5@6@7nfem@6,l@6,21600nfem,l21600,r,21600l,21600nsxe");

View File

@ -40,7 +40,7 @@ public:
{
m_bConcentricFill = true;
m_eJoin = NSOfficeDrawing::lineJoinMiter;
m_eJoin = ODRAW::lineJoinMiter;
//Encaps: Flat
m_strPath = _T("m@0@1l@2@3nfem,l21600,r,21600l,21600nsxe");

View File

@ -40,7 +40,7 @@ public:
{
m_bConcentricFill = true;
m_eJoin = NSOfficeDrawing::lineJoinMiter;
m_eJoin = ODRAW::lineJoinMiter;
m_strPath = _T("m,l,21600r21600,l21600,xem@0@0nfl@0@2@1@2@1@0xem,nfl@0@0em,21600nfl@0@2em21600,21600nfl@1@2em21600,nfl@1@0em@12@9nfl@11@4@12@10xe");

View File

@ -40,7 +40,7 @@ public:
{
m_bConcentricFill = true;
m_eJoin = NSOfficeDrawing::lineJoinMiter;
m_eJoin = ODRAW::lineJoinMiter;
m_strPath = _T("m,l,21600r21600,l21600,xem@0@0nfl@0@2@1@2@1@0xem,nfl@0@0em,21600nfl@0@2em21600,21600nfl@1@2em21600,nfl@1@0em@12@9l@17@4@12@10xem@11@9l@16@9@16@10@11@10xe");

View File

@ -40,7 +40,7 @@ public:
{
m_bConcentricFill = true;
m_eJoin = NSOfficeDrawing::lineJoinMiter;
m_eJoin = ODRAW::lineJoinMiter;
m_strPath = _T("m,l,21600r21600,l21600,xem@0@0nfl@0@2@1@2@1@0xem,nfl@0@0em,21600nfl@0@2em21600,21600nfl@1@2em21600,nfl@1@0e");

View File

@ -40,7 +40,7 @@ public:
{
m_bConcentricFill = true;
m_eJoin = NSOfficeDrawing::lineJoinMiter;
m_eJoin = ODRAW::lineJoinMiter;
m_strPath = _T("m,l,21600r21600,l21600,xem@0@0nfl@0@2@1@2@1@0xem,nfl@0@0em,21600nfl@0@2em21600,21600nfl@1@2em21600,nfl@1@0em@12@9nfl@12@10@13@10@13@14@15@9xem@15@9nfl@15@14@13@14e");

View File

@ -40,7 +40,7 @@ public:
{
m_bConcentricFill = true;
m_eJoin = NSOfficeDrawing::lineJoinMiter;
m_eJoin = ODRAW::lineJoinMiter;
m_strPath = _T("m,l,21600r21600,l21600,xem@0@0nfl@0@2@1@2@1@0xem,nfl@0@0em,21600nfl@0@2em21600,21600nfl@1@2em21600,nfl@1@0em@11@9l@16@4@11@10xem@17@9l@12@9@12@10@17@10xe");

View File

@ -40,7 +40,7 @@ public:
{
m_bConcentricFill = true;
m_eJoin = NSOfficeDrawing::lineJoinMiter;
m_eJoin = ODRAW::lineJoinMiter;
m_strPath = _T("m,l,21600r21600,l21600,xem@0@0nfl@0@2@1@2@1@0xem,nfl@0@0em,21600nfl@0@2em21600,21600nfl@1@2em21600,nfl@1@0em@33@27nfqy@3@9@40@27@39@4@37@29l@37@30@36@30@36@29qy@37@28@39@27@3@26@34@27xem@3@31nfqx@35@32@3@10@38@32@3@31xe");

View File

@ -40,7 +40,7 @@ public:
{
m_bConcentricFill = true;
m_eJoin = NSOfficeDrawing::lineJoinMiter;
m_eJoin = ODRAW::lineJoinMiter;
m_strPath = _T("m,l,21600r21600,l21600,xem@0@0nfl@0@2@1@2@1@0xem,nfl@0@0em,21600nfl@0@2em21600,21600nfl@1@2em21600,nfl@1@0em@3@9nfl@11@4@28@4@28@10@33@10@33@4@12@4@32@26@32@24@31@24@31@25xem@31@25nfl@32@26em@28@4nfl@33@4em@29@10nfl@29@27@30@27@30@10e");

View File

@ -40,7 +40,7 @@ public:
{
m_bConcentricFill = true;
m_eJoin = NSOfficeDrawing::lineJoinMiter;
m_eJoin = ODRAW::lineJoinMiter;
m_strPath = _T("m,l,21600r21600,l21600,xem@0@0nfl@0@2@1@2@1@0xem,nfl@0@0em,21600nfl@0@2em21600,21600nfl@1@2em21600,nfl@1@0em@3@9nfqx@11@4@3@10@12@4@3@9xem@3@25nfqx@33@26@3@27@36@26@3@25xem@32@28nfl@32@29@34@29@34@30@32@30@32@31@37@31@37@30@35@30@35@28xe");

View File

@ -40,7 +40,7 @@ public:
{
m_bConcentricFill = true;
m_eJoin = NSOfficeDrawing::lineJoinMiter;
m_eJoin = ODRAW::lineJoinMiter;
m_strPath = _T("m,l,21600r21600,l21600,xem@0@0nfl@0@2@1@2@1@0xem,nfl@0@0em,21600nfl@0@2em21600,21600nfl@1@2em21600,nfl@1@0em@11@39nfl@11@44@31@44@32@43@33@43@33@47@35@47@35@45@36@45@38@46@12@46@12@41@38@41@37@42@35@42@35@41@34@40@32@40@31@39xe");

View File

@ -40,7 +40,7 @@ public:
{
m_bConcentricFill = true;
m_eJoin = NSOfficeDrawing::lineJoinMiter;
m_eJoin = ODRAW::lineJoinMiter;
m_strPath = _T("m,l,21600r21600,l21600,xem@0@0nfl@0@2@1@2@1@0xem,nfl@0@0em,21600nfl@0@2em21600,21600nfl@1@2em21600,nfl@1@0em@11@9nfl@12@4@11@10xe");

View File

@ -40,7 +40,7 @@ public:
{
m_bConcentricFill = true;
m_eJoin = NSOfficeDrawing::lineJoinMiter;
m_eJoin = ODRAW::lineJoinMiter;
m_strPath = _T("m,l,21600r21600,l21600,xem@0@0nfl@0@2@1@2@1@0xem,nfl@0@0em,21600nfl@0@2em21600,21600nfl@1@2em21600,nfl@1@0em@12@21nfl@23@9@3@21@24@21@24@20qy@3@19l@25@19qx@26@20l@26@21@11@21@11@20qy@25@10l@3@10qx@22@20l@22@21xe");

Some files were not shown because too many files have changed in this diff Show More