Commit d3a0b5e9 authored by Elen.Subbotina's avatar Elen.Subbotina Committed by Alexander Trofimov

поправлен ASCOfficePPTFile.dll до состояния собираемости с учетом изменений в библиотеках на trunk

git-svn-id: svn://fileserver/activex/AVS/Sources/TeamlabOffice/trunk/ServerComponents@60230 954022d7-b5bf-4e40-9824-e11837661b57
parent ed2022c1
<?xml version="1.0" encoding="windows-1251"?>
<VisualStudioProject
ProjectType="Visual C++"
Version="8.00"
Version="8,00"
Name="ASCHTMLRenderer"
ProjectGUID="{DC24710E-8DF2-4A7A-B7C3-2313E294143C}"
RootNamespace="ASCHTMLRenderer"
......@@ -21,7 +21,7 @@
IntermediateDirectory="Debug"
ConfigurationType="4"
UseOfMFC="0"
UseOfATL="1"
UseOfATL="0"
ATLMinimizesCRunTimeLibraryUsage="false"
CharacterSet="1"
>
......@@ -56,7 +56,7 @@
PreprocessorDefinitions="WIN32;_WINDOWS;_DEBUG;_USRDLL;_ATL_ATTRIBUTES;DESKTOP_EDITOR_GRAPHICS"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="3"
RuntimeLibrary="1"
UsePrecompiledHeader="0"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
......
This diff is collapsed.
......@@ -52,8 +52,8 @@
<Tool
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories=".;..\..\..\ASCOfficeStudio\Common\OfficeDrawing\Shapes;..\..\..\ASCOfficeStudio\Common\OfficeDrawing"
PreprocessorDefinitions="WIN32;_WINDOWS;_DEBUG;_USRDLL;_ATL_ATTRIBUTES"
AdditionalIncludeDirectories=".;..\..\..\ASCOfficeStudio\Common\OfficeDrawing\Shapes;..\..\..\ASCOfficeStudio\Common\OfficeDrawing;&quot;..\..\..\..\DesktopEditor\freetype-2.5.2\include&quot;;&quot;..\..\DesktopEditor\freetype-2.5.2\include&quot;"
PreprocessorDefinitions="WIN32;_WINDOWS;_DEBUG;_USRDLL;_ATL_ATTRIBUTES;_USE_MATH_DEFINES;PPT_DEF"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="1"
......@@ -79,6 +79,8 @@
RegisterOutput="true"
IgnoreImportLibrary="true"
LinkIncremental="2"
AdditionalLibraryDirectories=""
IgnoreDefaultLibraryNames=""
MergedIDLBaseFileName="_ASCOfficePPTFile.idl"
GenerateDebugInformation="true"
SubSystem="2"
......@@ -149,8 +151,8 @@
<Tool
Name="VCCLCompilerTool"
Optimization="2"
AdditionalIncludeDirectories=".;..\..\ASCOfficeStudio\Common\OfficeDrawing\Shapes;..\..\ASCOfficeStudio\Common\OfficeDrawing"
PreprocessorDefinitions="WIN32;_WINDOWS;NDEBUG;_USRDLL;_ATL_ATTRIBUTES"
AdditionalIncludeDirectories=".;..\..\..\ASCOfficeStudio\Common\OfficeDrawing\Shapes;..\..\..\ASCOfficeStudio\Common\OfficeDrawing;&quot;..\..\..\..\DesktopEditor\freetype-2.5.2\include&quot;;&quot;..\..\DesktopEditor\freetype-2.5.2\include&quot;"
PreprocessorDefinitions="WIN32;_WINDOWS;NDEBUG;_USRDLL;_ATL_ATTRIBUTES;_USE_MATH_DEFINES;PPT_DEF"
StringPooling="true"
RuntimeLibrary="2"
UsePrecompiledHeader="2"
......@@ -176,6 +178,7 @@
IgnoreImportLibrary="true"
OutputFile="..\..\..\redist\$(ProjectName).dll"
LinkIncremental="1"
AdditionalLibraryDirectories=""
MergedIDLBaseFileName="_ASCOfficePPTFile.idl"
GenerateDebugInformation="true"
ProgramDatabaseFile="$(OutDir)/$(TargetName).pdb"
......@@ -253,6 +256,26 @@
/>
</FileConfiguration>
</File>
<File
RelativePath="..\..\Common\DocxFormat\Source\XML\stringcommon.cpp"
>
<FileConfiguration
Name="Debug|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="0"
/>
</FileConfiguration>
<FileConfiguration
Name="Release|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="0"
/>
</FileConfiguration>
</File>
</Filter>
<Filter
Name="Resource Files"
......@@ -292,30 +315,142 @@
<File
RelativePath="..\..\ASCPresentationEditor\OfficeDrawing\Shapes\BaseShape\BaseShape.cpp"
>
<FileConfiguration
Name="Debug|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="0"
/>
</FileConfiguration>
<FileConfiguration
Name="Release|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="0"
/>
</FileConfiguration>
</File>
<File
RelativePath="..\..\ASCPresentationEditor\OfficeDrawing\Elements.cpp"
>
<FileConfiguration
Name="Debug|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="0"
/>
</FileConfiguration>
<FileConfiguration
Name="Release|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="0"
/>
</FileConfiguration>
</File>
<File
RelativePath="..\..\ASCPresentationEditor\OfficeDrawing\Shapes\BaseShape\PPTShape\Formula.cpp"
>
<FileConfiguration
Name="Debug|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="0"
/>
</FileConfiguration>
<FileConfiguration
Name="Release|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="0"
/>
</FileConfiguration>
</File>
<File
RelativePath="..\..\ASCPresentationEditor\OfficeDrawing\Layout.cpp"
>
<FileConfiguration
Name="Debug|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="0"
/>
</FileConfiguration>
<FileConfiguration
Name="Release|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="0"
/>
</FileConfiguration>
</File>
<File
RelativePath="..\..\ASCPresentationEditor\OfficeDrawing\Shapes\BaseShape\PPTShape\PPTShape.cpp"
>
<FileConfiguration
Name="Debug|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="0"
/>
</FileConfiguration>
<FileConfiguration
Name="Release|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="0"
/>
</FileConfiguration>
</File>
<File
RelativePath="..\..\ASCPresentationEditor\OfficeDrawing\TextAttributesEx.cpp"
>
<FileConfiguration
Name="Debug|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="0"
/>
</FileConfiguration>
<FileConfiguration
Name="Release|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="0"
/>
</FileConfiguration>
</File>
<File
RelativePath="..\..\ASCPresentationEditor\OfficeDrawing\Theme.cpp"
>
<FileConfiguration
Name="Debug|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="0"
/>
</FileConfiguration>
<FileConfiguration
Name="Release|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="0"
/>
</FileConfiguration>
</File>
</Filter>
<Filter
......@@ -333,6 +468,10 @@
RelativePath="..\ASCPresentationEditor\OfficeDrawing\Document.h"
>
</File>
<File
RelativePath="..\..\ASCPresentationEditor\OfficeDrawing\Document.h"
>
</File>
<File
RelativePath=".\Reader\PPTDocumentInfo.h"
>
......
......@@ -4,8 +4,6 @@
#include "zlib.h"
#pragma comment(lib, "zlib.lib")
namespace NSZLib
{
static BOOL Decompress(const BYTE* pSrcBuffer, const ULONG& lSrcBufferLen,
......
......@@ -193,7 +193,7 @@ BOOL CPPTUserInfo::ReadFromStream(CRecordUserEditAtom* pUser, IStream* pStream,
oInfo.m_strFilePath = m_oExMedia.m_strPresentationDirectory;
oInfo.m_dwID = 0xFFFFFFFF;
m_oExMedia.m_arImages.Add(oInfo);
m_oExMedia.m_arImages.push_back(oInfo);
//
CSimpleArray<CRecordExObjListContainer*> oArrayExObjects;
......@@ -255,7 +255,7 @@ BOOL CPPTUserInfo::ReadFromStream(CRecordUserEditAtom* pUser, IStream* pStream,
void CPPTUserInfo::FromDocument()
{
UpdateXMLInfo();
m_arSlides.RemoveAll();
m_arSlides.clear();
//
// , ...
......@@ -293,7 +293,8 @@ void CPPTUserInfo::FromDocument()
{
DurationSlide = PPT_DEFAULT_SLIDE_DURATION;
m_arSlides.Add();
CSlide elm;
m_arSlides.push_back(elm);
// ...
//
......@@ -392,7 +393,7 @@ void CPPTUserInfo::LoadSlide(int nIndex)
return;
size_t lCountSlides = m_arSlides.GetCount();
size_t lCountSlides = m_arSlides.size();
CSlide* pSlide = &m_arSlides[lCountSlides - 1];
pSlide->m_bUseLayoutColorScheme = true;
......@@ -425,7 +426,7 @@ void CPPTUserInfo::LoadSlide(int nIndex)
CTheme* pTheme = &m_arThemes[pSlide->m_lThemeID];
CLayout* pLayout = &pTheme->m_arLayouts[pSlide->m_lLayoutID];
CAtlArray<NSPresentationEditor::CColor>* pArrayColorScheme = &pTheme->m_arColorScheme;
std::vector<NSPresentationEditor::CColor>* pArrayColorScheme = &pTheme->m_arColorScheme;
if (!pLayout->m_bUseThemeColorScheme)
pArrayColorScheme = &pLayout->m_arColorScheme;
......@@ -445,13 +446,13 @@ void CPPTUserInfo::LoadSlide(int nIndex)
CorrectColorScheme(pSlide->m_arColorScheme);
//
size_t nCountC = pSlide->m_arColorScheme.GetCount();
size_t nCountC = pSlide->m_arColorScheme.size();
size_t nIndexC = 0;
if (nCountC == pArrayColorScheme->GetCount())
if (nCountC == pArrayColorScheme->size())
{
for (; nIndexC < nCountC; ++nIndexC)
{
if (pSlide->m_arColorScheme[i].IsEqual(pArrayColorScheme->GetAt(i)))
if (pSlide->m_arColorScheme[i].IsEqual(pArrayColorScheme->at(i)))
break;
}
}
......@@ -459,7 +460,7 @@ void CPPTUserInfo::LoadSlide(int nIndex)
if (nIndexC == nCountC)
{
pSlide->m_bUseLayoutColorScheme = true;
pSlide->m_arColorScheme.RemoveAll();
pSlide->m_arColorScheme.clear();
}
break;
......@@ -502,7 +503,7 @@ void CPPTUserInfo::LoadSlide(int nIndex)
continue;
}
pSlide->m_arElements.Add(pElem);
pSlide->m_arElements.push_back(pElem);
}
}
}
......@@ -554,14 +555,16 @@ void CPPTUserInfo::LoadMainMaster(int nIndexMaster, const LONG& lOriginWidth, co
return;
}
LONG lIndexTheme = (LONG)m_arThemes.GetCount();
LONG lIndexTheme = (LONG)m_arThemes.size();
m_mapMasterToTheme.SetAt(dwKey, lIndexTheme);
m_mapMasterToLayout.SetAt(dwKey, 0);
m_arThemes.Add();
CTheme elm;
m_arThemes.push_back(elm);
CTheme* pTheme = &m_arThemes[lIndexTheme];
pTheme->m_arLayouts.Add();
CLayout elm1;
pTheme->m_arLayouts.push_back(elm1);
CLayout* pLayout = &pTheme->m_arLayouts[0];
m_arMasterWrapper.Add();
......@@ -571,7 +574,7 @@ void CPPTUserInfo::LoadMainMaster(int nIndexMaster, const LONG& lOriginWidth, co
int nCountFonts = m_arrFonts.GetSize();
for (int i = 0; i < nCountFonts; ++i)
{
pTheme->m_arFonts.Add(m_arrFonts[i]);
pTheme->m_arFonts.push_back(m_arrFonts[i]);
}
// ---------------------------------------------------------------------------------
......@@ -677,9 +680,9 @@ void CPPTUserInfo::LoadMainMaster(int nIndexMaster, const LONG& lOriginWidth, co
}
if (-1 == pElem->m_lPlaceholderType)
pTheme->m_arElements.Add(pElem);
pTheme->m_arElements.push_back(pElem);
else
pLayout->m_arElements.Add(pElem);
pLayout->m_arElements.push_back(pElem);
}
}
}
......@@ -745,12 +748,13 @@ void CPPTUserInfo::LoadNoMainMaster(int nIndex, const LONG& lOriginWidth, const
return;
CTheme* pTheme = &m_arThemes[pPair->m_value];
LONG lIndexLayout = (LONG)pTheme->m_arLayouts.GetCount();
LONG lIndexLayout = (LONG)pTheme->m_arLayouts.size();
m_mapMasterToTheme.SetAt(dwCurID, pPair->m_value);
m_mapMasterToLayout.SetAt(dwCurID, lIndexLayout);
pTheme->m_arLayouts.Add();
CLayout elm;
pTheme->m_arLayouts.push_back(elm);
CLayout* pLayout = &pTheme->m_arLayouts[lIndexLayout];
m_arMasterWrapper.Add();
......@@ -765,14 +769,14 @@ void CPPTUserInfo::LoadNoMainMaster(int nIndex, const LONG& lOriginWidth, const
pLayout->m_bShowMasterShapes = (bMasterObjects == TRUE) ? true : false;
pLayout->m_strLayoutType = ConvertLayoutType(oArraySlideAtoms[0]->m_oLayout.m_nGeom, oArraySlideAtoms[0]->m_oLayout.m_pPlaceHolderID);
CAtlArray<NSPresentationEditor::CColor>* pArrayColorScheme = &pTheme->m_arColorScheme;
std::vector<NSPresentationEditor::CColor>* pArrayColorScheme = &pTheme->m_arColorScheme;
// -----------------------------------------------------------
if (!bMasterColorScheme)
{
CSimpleArray<CRecordColorSchemeAtom*> oArrayColors;
pCurMaster->GetRecordsByType(&oArrayColors, false);
pLayout->m_arColorScheme.RemoveAll();
pLayout->m_arColorScheme.clear();
for (int i = 0; i < oArrayColors.GetSize(); ++i)
{
if (0x01 == oArrayColors[i]->m_oHeader.RecInstance)
......@@ -782,13 +786,13 @@ void CPPTUserInfo::LoadNoMainMaster(int nIndex, const LONG& lOriginWidth, const
CorrectColorScheme(pLayout->m_arColorScheme);
//
size_t nCountC = pLayout->m_arColorScheme.GetCount();
size_t nCountC = pLayout->m_arColorScheme.size();
size_t nIndexC = 0;
if (nCountC == pArrayColorScheme->GetCount())
if (nCountC == pArrayColorScheme->size())
{
for (; nIndexC < nCountC; ++nIndexC)
{
if (pLayout->m_arColorScheme[i].IsEqual(pArrayColorScheme->GetAt(i)))
if (pLayout->m_arColorScheme[i].IsEqual(pArrayColorScheme->at(i)))
break;
}
}
......@@ -796,7 +800,7 @@ void CPPTUserInfo::LoadNoMainMaster(int nIndex, const LONG& lOriginWidth, const
if (nIndexC == nCountC)
{
pLayout->m_bUseThemeColorScheme = true;
pLayout->m_arColorScheme.RemoveAll();
pLayout->m_arColorScheme.clear();
}
break;
......@@ -844,7 +848,7 @@ void CPPTUserInfo::LoadNoMainMaster(int nIndex, const LONG& lOriginWidth, const
continue;
}
pLayout->m_arElements.Add(pElem);
pLayout->m_arElements.push_back(pElem);
}
}
}
......@@ -1021,7 +1025,7 @@ void CPPTUserInfo::LoadExternal(CRecordExObjListContainer* pExObjects)
oArrayData[0]->SaveToFile(oInfo.m_strFilePath);
m_oExMedia.m_arAudioCollection.Add(oInfo);
m_oExMedia.m_arAudioCollection.push_back(oInfo);
}
}
}
......@@ -1079,7 +1083,7 @@ void CPPTUserInfo::LoadExternal(CRecordExObjListContainer* pExObjects)
oAudio.m_strFilePath = pInfo->m_strFilePath;
oAudio.m_bLoop = oArrayAudioEmbedded[nIndex]->m_oMedia.m_bLoop;
m_oExMedia.m_arAudios.Add(oAudio);
m_oExMedia.m_arAudios.push_back(oAudio);
}
}
for (int nIndex = 0; nIndex < nSize1; ++nIndex)
......@@ -1120,7 +1124,7 @@ void CPPTUserInfo::LoadExVideo(CRecordsContainer* pExObject)
oInfo.m_bLoop = oArrayExMedia[0]->m_bLoop;
m_oExMedia.m_arVideos.Add(oInfo);
m_oExMedia.m_arVideos.push_back(oInfo);
}
oArrayExMedia.RemoveAll();
......@@ -1143,7 +1147,7 @@ void CPPTUserInfo::LoadExAudio(CRecordsContainer* pExObject)
oInfo.m_bLoop = oArrayExMedia[0]->m_bLoop;
m_oExMedia.m_arAudios.Add(oInfo);
m_oExMedia.m_arAudios.push_back(oInfo);
}
oArrayExMedia.RemoveAll();
......@@ -1172,7 +1176,7 @@ void CPPTUserInfo::AddAnimation ( int SlideIndex, double Width, double Height, I
}
else if (2 == oEffect.m_nSchemeColor) // Index From Table
{
if ((int)oAnimation.m_nColorTo >= (int)m_oSchemeColors.GetCount())
if ((int)oAnimation.m_nColorTo >= (int)m_oSchemeColors.size())
continue;
oAnimation.m_nColorTo = m_oSchemeColors[oEffect.m_nColorTo].GetLONG();
......@@ -1181,7 +1185,7 @@ void CPPTUserInfo::AddAnimation ( int SlideIndex, double Width, double Height, I
pElement->m_oAnimations.m_dSlideWidth = Width;
pElement->m_oAnimations.m_dSlideHeight = Height;
pElement->m_oAnimations.m_arAnimations.Add ( oAnimation );
pElement->m_oAnimations.m_arAnimations.push_back( oAnimation );
}
}
}
......
......@@ -60,7 +60,7 @@ public:
// DEBUG information
CString m_strXmlInfo;
CAtlArray<CColor> m_oSchemeColors;
std::vector<CColor> m_oSchemeColors;
public:
......@@ -127,28 +127,28 @@ public:
}
}
void CorrectColorScheme(CAtlArray<CColor>& oScheme)
void CorrectColorScheme(std::vector<CColor>& oScheme)
{
CAtlArray<CColor> oArrayMem;
oArrayMem.Add(CColor());
oArrayMem.Add(oScheme[1]);
oArrayMem.Add(oScheme[2]);
oArrayMem.Add(oScheme[3]);
oArrayMem.Add(oScheme[0]);
oArrayMem.Add(oScheme[4]);
oArrayMem.Add(oScheme[5]);
oArrayMem.Add(oScheme[5]);//
oArrayMem.Add(oScheme[5]);//
oArrayMem.Add(oScheme[5]);//
oArrayMem.Add(oScheme[5]);//
oArrayMem.Add(oScheme[6]);
oArrayMem.Add(oScheme[7]);
oArrayMem.Add(oScheme[1]);
oArrayMem.Add(oScheme[2]);
oArrayMem.Add(oScheme[3]);
oArrayMem.Add(oScheme[0]);
oScheme.Copy(oArrayMem);
std::vector<CColor> oArrayMem;
oArrayMem.push_back(CColor());
oArrayMem.push_back(oScheme[1]);
oArrayMem.push_back(oScheme[2]);
oArrayMem.push_back(oScheme[3]);
oArrayMem.push_back(oScheme[0]);
oArrayMem.push_back(oScheme[4]);
oArrayMem.push_back(oScheme[5]);
oArrayMem.push_back(oScheme[5]);//
oArrayMem.push_back(oScheme[5]);//
oArrayMem.push_back(oScheme[5]);//
oArrayMem.push_back(oScheme[5]);//
oArrayMem.push_back(oScheme[6]);
oArrayMem.push_back(oScheme[7]);
oArrayMem.push_back(oScheme[1]);
oArrayMem.push_back(oScheme[2]);
oArrayMem.push_back(oScheme[3]);
oArrayMem.push_back(oScheme[0]);
oScheme = oArrayMem;
}
CString ConvertLayoutType(INT nGeom, BYTE* pPlaceholders)
......
......@@ -395,11 +395,11 @@ namespace NSStreamReader
if (bTabStops_)
{
WORD tabStopsCount = StreamUtils::ReadWORD(pStream);
oRun.tabsStops.RemoveAll();
oRun.tabsStops.clear();
for (int i = 0; i < (int)tabStopsCount; ++i)
{
oRun.tabsStops.Add(StreamUtils::ReadDWORD(pStream));
oRun.tabsStops.push_back(StreamUtils::ReadDWORD(pStream));
}
}
......@@ -568,17 +568,17 @@ public:
if (tabStops_)
{
WORD tabStopsCount = StreamUtils::ReadWORD(pStream);
m_oRun.tabStops.RemoveAll();
m_oRun.tabStops.clear();
if (tabStopsCount > 10)
tabStopsCount = 10;
for (int i = 0; i < (int)tabStopsCount; ++i)
{
m_oRun.tabStops.Add(StreamUtils::ReadDWORD(pStream));
m_oRun.tabStops.push_back(StreamUtils::ReadDWORD(pStream));
}
if (0 < m_oRun.tabStops.GetCount())
if (0 < m_oRun.tabStops.size())
m_oRun.defaultTabSize = m_oRun.tabStops[0];
}
......@@ -727,7 +727,7 @@ namespace NSPresentationEditor
int nCountPFs = (int)oArrayPF.GetCount();
int nCountCFs = (int)oArrayCF.GetCount();
oAttributes.m_arParagraphs.RemoveAll();
oAttributes.m_arParagraphs.clear();
int nCurrentPF = 0;
int nCurrentCF = 0;
int nOffsetCF = 0;
......@@ -736,7 +736,7 @@ namespace NSPresentationEditor
int nIndexText = 0;
for (int nIndexPF = 0; nIndexPF < nCountPFs; ++nIndexPF)
{
oAttributes.m_arParagraphs.Add();
oAttributes.m_arParagraphs.push_back(CParagraph());
NSPresentationEditor::CParagraph* pPar = &oAttributes.m_arParagraphs[nIndexPF];
pPar->m_oPFRun = oArrayPF[nIndexPF].m_oRun;
......@@ -759,7 +759,7 @@ namespace NSPresentationEditor
oSpan.m_oRun = oArrayCF[nCurrentCF].m_oRun;
oSpan.m_strText = strText.Mid(nIndexText, nCountInPF);
pPar->m_arSpans.Add(oSpan);
pPar->m_arSpans.push_back(oSpan);
nIndexText += nCountInPF;
break;
......@@ -772,7 +772,7 @@ namespace NSPresentationEditor
oSpan.m_oRun = oArrayCF[nCurrentCF].m_oRun;
oSpan.m_strText = strText.Mid(nIndexText, nCountAdd);
pPar->m_arSpans.Add(oSpan);
pPar->m_arSpans.push_back(oSpan);
nIndexText += nCountAdd;
++nCurrentCF;
......@@ -786,7 +786,7 @@ namespace NSPresentationEditor
oSpan.m_oRun = oArrayCF[nCurrentCF].m_oRun;
oSpan.m_strText = strText.Mid(nIndexText, nCountAdd);
pPar->m_arSpans.Add(oSpan);
pPar->m_arSpans.push_back(oSpan);
nIndexText += nCountAdd;
nCountInPF -= nCountAdd;
......
......@@ -60,48 +60,48 @@ public:
return oWriter.GetXmlString();
}
void ToArray(CSimpleArray<SColorAtom>* pArray)
void ToArray(std::vector<SColorAtom>* pArray)
{
if (NULL != pArray)
{
pArray->Add(m_oBackgroundColor);
pArray->Add(m_oTextAndLinesColor);
pArray->Add(m_oShadowsColor);
pArray->Add(m_oTitleTextColor);
pArray->Add(m_oFillsColor);
pArray->Add(m_oAccentColor);
pArray->Add(m_oAccentAndHyperlinkColor);
pArray->Add(m_oAccentAndFollowingHyperlinkColor);
pArray->push_back(m_oBackgroundColor);
pArray->push_back(m_oTextAndLinesColor);
pArray->push_back(m_oShadowsColor);
pArray->push_back(m_oTitleTextColor);
pArray->push_back(m_oFillsColor);
pArray->push_back(m_oAccentColor);
pArray->push_back(m_oAccentAndHyperlinkColor);
pArray->push_back(m_oAccentAndFollowingHyperlinkColor);
}
}
void ToArray(CAtlArray<CColor>* pArray)
void ToArray(std::vector<CColor>* pArray)
{
CColor oColor;
if (NULL != pArray)
{
m_oBackgroundColor.ToColor(&oColor);
pArray->Add(oColor);
pArray->push_back(oColor);
m_oTextAndLinesColor.ToColor(&oColor);
pArray->Add(oColor);
pArray->push_back(oColor);
m_oShadowsColor.ToColor(&oColor);
pArray->Add(oColor);
pArray->push_back(oColor);
m_oTitleTextColor.ToColor(&oColor);
pArray->Add(oColor);
pArray->push_back(oColor);
m_oFillsColor.ToColor(&oColor);
pArray->Add(oColor);
pArray->push_back(oColor);
m_oAccentColor.ToColor(&oColor);
pArray->Add(oColor);
pArray->push_back(oColor);
m_oAccentAndHyperlinkColor.ToColor(&oColor);
pArray->Add(oColor);
pArray->push_back(oColor);
m_oAccentAndFollowingHyperlinkColor.ToColor(&oColor);
pArray->Add(oColor);
pArray->push_back(oColor);
}
}
};
\ No newline at end of file
......@@ -307,7 +307,7 @@ public:
case NSOfficeDrawing::adjust10Value:
{
LONG lIndexAdj = pProperty->m_ePID - NSOfficeDrawing::adjustValue;
if (lIndexAdj >= 0 && lIndexAdj < pShape->m_arAdjustments.GetSize())
if (lIndexAdj >= 0 && lIndexAdj < pShape->m_arAdjustments.size())
{
//SetAdjustment(lIndexAdj, (LONG)pProperty->m_lValue);
pShape->m_oCustomVML.LoadAdjusts(lIndexAdj, (LONG)pProperty->m_lValue);
......@@ -949,7 +949,7 @@ public:
{
lMasterID = oArrayOptions[0]->m_oProperties.m_arProperties[i].m_lValue;
size_t nIndexMem = pLayout->m_arElements.GetCount();
size_t nIndexMem = pLayout->m_arElements.size();
for (size_t nIndex = 0; nIndex < nIndexMem; ++nIndex)
{
if (lMasterID == pLayout->m_arElements[nIndex]->m_lID && (elType == pLayout->m_arElements[nIndex]->m_etType))
......@@ -960,7 +960,7 @@ public:
{
CShapeElement* pShape = dynamic_cast<CShapeElement*>(*ppElement);
if (NULL != pShape)
pShape->m_oShape.m_oText.m_arParagraphs.RemoveAll();
pShape->m_oShape.m_oText.m_arParagraphs.clear();
}
break;
......@@ -1035,10 +1035,10 @@ public:
pAudioElem->m_dStartTime = pSlide->m_dStartTime;
pAudioElem->m_dEndTime = pSlide->m_dEndTime;
pSlide->m_arElements.Add(pAudioElem);
pSlide->m_arElements.push_back(pAudioElem);
}
else
pLayout->m_arElements.Add(pAudioElem);
pLayout->m_arElements.push_back(pAudioElem);
CImageElement* pImageElem = new CImageElement();
pImageElem->m_strFileName = strPathPicture;
......@@ -1260,7 +1260,7 @@ public:
oRange.m_lStart = oArrayTextInteractive[i]->m_lStart;
oRange.m_lEnd = oArrayTextInteractive[i]->m_lEnd;
pShapeElem->m_oActions.m_arRanges.Add(oRange);
pShapeElem->m_oActions.m_arRanges.push_back(oRange);
}
}
......@@ -1428,7 +1428,7 @@ protected:
pTextSettings->m_lPlaceholderType = ph_type;
size_t lElemsCount = pLayout->m_arElements.GetCount();
size_t lElemsCount = pLayout->m_arElements.size();
for (size_t i = 0; i < lElemsCount; ++i)
{
IElement* pPh = pLayout->m_arElements[i];
......@@ -1463,10 +1463,10 @@ protected:
eTypePersist = (NSOfficePPT::TextType)pSettings->m_nTextType;
strText = pSettings->ApplyProperties(pTextSettings);
if ((0 != pSettings->m_arRanges.GetCount()) && (0 == pShape->m_oActions.m_arRanges.GetCount()))
if ((0 != pSettings->m_arRanges.size()) && (0 == pShape->m_oActions.m_arRanges.size()))
{
pShape->m_oActions.m_bPresent = true;
pShape->m_oActions.m_arRanges.Copy(pSettings->m_arRanges);
pShape->m_oActions.m_arRanges = pSettings->m_arRanges;
}
bIsPersistPresentSettings = ((NULL != pSettings->m_pTextStyleProp) && (0 < pSettings->m_pTextStyleProp->m_lCount));
......@@ -1702,7 +1702,7 @@ protected:
}
}
if ((_T("") != strText) && 0 == pTextSettings->m_arParagraphs.GetCount())
if ((_T("") != strText) && 0 == pTextSettings->m_arParagraphs.size())
{
// .
CAtlArray<CTextPFRun_ppt> oArrayPF;
......@@ -1783,7 +1783,7 @@ protected:
case sptTextCanUp:
case sptTextCanDown:
{
pShape->m_oShape.m_oText.m_arParagraphs.RemoveAll();
pShape->m_oShape.m_oText.m_arParagraphs.clear();
pShape->m_oShape.m_oText.m_oAttributes.m_oTextBrush = pShape->m_oShape.m_oBrush;
......@@ -1801,15 +1801,15 @@ protected:
void ApplyHyperlink(CShapeElement* pShape, CColor& oColor)
{
CAtlArray<CTextRange>* pRanges = &pShape->m_oActions.m_arRanges;
std::vector<CTextRange>* pRanges = &pShape->m_oActions.m_arRanges;
CTextAttributesEx* pTextAttributes = &pShape->m_oShape.m_oText;
LONG lCountHyper = (LONG)pRanges->GetCount();
LONG lCountHyper = (LONG)pRanges->size();
if (0 == lCountHyper)
return;
size_t nCountPars = pTextAttributes->m_arParagraphs.GetCount();
size_t nCountPars = pTextAttributes->m_arParagraphs.size();
for (LONG nIndexRange = 0; nIndexRange < lCountHyper; ++nIndexRange)
{
LONG lStart = (*pRanges)[nIndexRange].m_lStart;
......@@ -1820,7 +1820,7 @@ protected:
{
CParagraph* pParagraph = &pTextAttributes->m_arParagraphs[nIndexPar];
for (size_t nIndexSpan = 0; nIndexSpan < pParagraph->m_arSpans.GetCount(); ++nIndexSpan)
for (size_t nIndexSpan = 0; nIndexSpan < pParagraph->m_arSpans.size(); ++nIndexSpan)
{
LONG lCurrentEnd = lCurrentStart + pParagraph->m_arSpans[nIndexSpan].m_strText.GetLength() - 1;
......@@ -1838,7 +1838,7 @@ protected:
CString strText = pParagraph->m_arSpans[nIndexSpan].m_strText;
if (lStart_ > lCurrentStart)
{
pParagraph->m_arSpans.InsertAt(nIndexSpan, oRunProp);
pParagraph->m_arSpans.insert(pParagraph->m_arSpans.begin() + nIndexSpan, oRunProp);
pParagraph->m_arSpans[nIndexSpan].m_strText = strText.Mid(0, lStart_ - lCurrentStart);
++nIndexSpan;
......@@ -1848,7 +1848,7 @@ protected:
pParagraph->m_arSpans[nIndexSpan].m_strText = strText.Mid(lStart_ - lCurrentStart, lEnd_ - lStart_ + 1);
if (lEnd_ < lCurrentEnd)
{
pParagraph->m_arSpans.InsertAt(nIndexSpan + 1, oRunProp);
pParagraph->m_arSpans.insert(pParagraph->m_arSpans.begin() + nIndexSpan + 1, oRunProp);
++nIndexSpan;
pParagraph->m_arSpans[nIndexSpan].m_strText = strText.Mid(lEnd_ - lCurrentStart + 1, lCurrentEnd - lEnd_);
......
......@@ -124,7 +124,7 @@ public:
NSPresentationEditor::CTextRange oRange;
oRange.m_lStart = pTxRanges->m_lStart;
oRange.m_lEnd = pTxRanges->m_lEnd;
m_arTextPlaceHolders[nCurrentSlide][nCurrentTextHeader].m_arRanges.Add(oRange);
m_arTextPlaceHolders[nCurrentSlide][nCurrentTextHeader].m_arRanges.push_back(oRange);
}
}
......
......@@ -15,7 +15,7 @@ public:
CRecordTextSpecInfoAtom* m_pTextSpecInfo;
CRecordTextRulerAtom* m_pTextRuler;
CAtlArray<NSPresentationEditor::CTextRange> m_arRanges;
std::vector<NSPresentationEditor::CTextRange> m_arRanges;
CStringW m_strText;
DWORD m_nTextType;
......@@ -42,7 +42,7 @@ public:
m_nTextType = oSrc.m_nTextType;
m_strText = oSrc.m_strText;
m_arRanges.Copy(oSrc.m_arRanges);
m_arRanges = oSrc.m_arRanges;
return (*this);
}
~CTextFullSettings()
......
......@@ -44,13 +44,11 @@
#include <atlctl.h>
#include <atlhost.h>
#include <atlcoll.h>
#define _USE_MATH_DEFINES
#include <math.h>
#include <gdiplus.h>
//#include <gdiplus.h>
using namespace ATL;
using namespace Gdiplus;
#pragma comment(lib, "gdiplus.lib")
//#pragma comment(lib, "gdiplus.lib")
//
#pragma warning(disable: 4244)
......
......@@ -2,6 +2,6 @@
//1
//0
//0
//67
#define INTVER 1,0,0,67
#define STRVER "1,0,0,67\0"
//73
#define INTVER 1,0,0,73
#define STRVER "1,0,0,73\0"
......@@ -265,19 +265,19 @@ public:
INT bFlipX = (0 != (c_nParamFlipX & lFlags));
INT bFlipY = (0 != (c_nParamFlipY & lFlags));
REAL m11 = bFlipX ? -1.0f : 1.0f;
REAL m22 = bFlipY ? -1.0f : 1.0f;
float m11 = bFlipX ? -1.0f : 1.0f;
float m22 = bFlipY ? -1.0f : 1.0f;
Aggplus::CMatrix oMatrix(1, 0, 0, 1, 0, 0);
if ((0 != dAngle) || (0 != lFlags))
{
REAL dCentreX = (REAL)(dLeft + dWidth / 2.0);
REAL dCentreY = (REAL)(dTop + dHeight / 2.0);
double dCentreX = (double)(dLeft + dWidth / 2.0);
double dCentreY = (double)(dTop + dHeight / 2.0);
oMatrix.Translate(-dCentreX, -dCentreY , Aggplus::MatrixOrderAppend);
oMatrix.Rotate((REAL)dAngle , Aggplus::MatrixOrderAppend);
oMatrix.Rotate(dAngle , Aggplus::MatrixOrderAppend);
oMatrix.Scale(m11, m22 , Aggplus::MatrixOrderAppend);
oMatrix.Translate(dCentreX, dCentreY , Aggplus::MatrixOrderAppend);
......
......@@ -35,7 +35,7 @@ public:
double OffsetX() const;
double OffsetY() const;
Status GetElements(REAL* m) const;
Status GetElements(float* m) const;
Status GetElements(double* m) const;
void Reset();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment