Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
onlyoffice_core
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boris Kocherov
onlyoffice_core
Commits
7d188b22
Commit
7d188b22
authored
May 10, 2017
by
ElenaSubbotina
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
PptFormatReader - presentation slide notes
parent
79ead484
Changes
24
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
24 changed files
with
390 additions
and
175 deletions
+390
-175
ASCOfficePPTFile/PPTFormatLib/PPTXWriter/Converter.cpp
ASCOfficePPTFile/PPTFormatLib/PPTXWriter/Converter.cpp
+73
-17
ASCOfficePPTFile/PPTFormatLib/PPTXWriter/Converter.h
ASCOfficePPTFile/PPTFormatLib/PPTXWriter/Converter.h
+2
-2
ASCOfficePPTFile/PPTFormatLib/PPTXWriter/ImageManager.h
ASCOfficePPTFile/PPTFormatLib/PPTXWriter/ImageManager.h
+19
-44
ASCOfficePPTFile/PPTFormatLib/Reader/PPTDocumentInfoOneUser.cpp
...icePPTFile/PPTFormatLib/Reader/PPTDocumentInfoOneUser.cpp
+211
-29
ASCOfficePPTFile/PPTFormatLib/Reader/PPTDocumentInfoOneUser.h
...fficePPTFile/PPTFormatLib/Reader/PPTDocumentInfoOneUser.h
+4
-4
ASCOfficePPTFile/PPTFormatLib/Reader/PPTFileDefines.h
ASCOfficePPTFile/PPTFormatLib/Reader/PPTFileDefines.h
+16
-13
ASCOfficePPTFile/PPTFormatLib/Reader/Records.cpp
ASCOfficePPTFile/PPTFormatLib/Reader/Records.cpp
+4
-4
ASCOfficePPTFile/PPTFormatLib/Reader/Records.h
ASCOfficePPTFile/PPTFormatLib/Reader/Records.h
+1
-1
ASCOfficePPTFile/PPTFormatLib/Records/Animations/AnimationTypes.h
...ePPTFile/PPTFormatLib/Records/Animations/AnimationTypes.h
+2
-2
ASCOfficePPTFile/PPTFormatLib/Records/DocumentRecords.h
ASCOfficePPTFile/PPTFormatLib/Records/DocumentRecords.h
+12
-19
ASCOfficePPTFile/PPTFormatLib/Records/Drawing/BlipStoreContainer.h
...PPTFile/PPTFormatLib/Records/Drawing/BlipStoreContainer.h
+1
-1
ASCOfficePPTFile/PPTFormatLib/Records/Drawing/GroupShapeContainer.h
...PTFile/PPTFormatLib/Records/Drawing/GroupShapeContainer.h
+2
-2
ASCOfficePPTFile/PPTFormatLib/Records/Drawing/ShapeContainer.h
...ficePPTFile/PPTFormatLib/Records/Drawing/ShapeContainer.h
+1
-1
ASCOfficePPTFile/PPTFormatLib/Records/HeadersFootersAtom.h
ASCOfficePPTFile/PPTFormatLib/Records/HeadersFootersAtom.h
+1
-1
ASCOfficePPTFile/PPTFormatLib/Records/NotesAtom.h
ASCOfficePPTFile/PPTFormatLib/Records/NotesAtom.h
+5
-6
ASCOfficePPTFile/PPTFormatLib/Records/RecordsIncluder.h
ASCOfficePPTFile/PPTFormatLib/Records/RecordsIncluder.h
+1
-0
ASCOfficePPTFile/PPTFormatLib/Records/RoundTripColorMappingAtom.h
...ePPTFile/PPTFormatLib/Records/RoundTripColorMappingAtom.h
+3
-3
ASCOfficePPTFile/PPTFormatLib/Records/RoundTripThemeAtom.h
ASCOfficePPTFile/PPTFormatLib/Records/RoundTripThemeAtom.h
+3
-3
ASCOfficePPTFile/PPTFormatLib/Records/SlideContainer.h
ASCOfficePPTFile/PPTFormatLib/Records/SlideContainer.h
+1
-1
ASCOfficePPTFile/PPTFormatLib/Records/TextBytesAtom.h
ASCOfficePPTFile/PPTFormatLib/Records/TextBytesAtom.h
+1
-1
ASCOfficePPTFile/PPTFormatLib/Records/TextSpecInfoAtom.h
ASCOfficePPTFile/PPTFormatLib/Records/TextSpecInfoAtom.h
+3
-2
ASCOfficePPTXFile/Editor/Drawing/Document.h
ASCOfficePPTXFile/Editor/Drawing/Document.h
+17
-18
ASCOfficePPTXFile/Editor/Drawing/Slide.h
ASCOfficePPTXFile/Editor/Drawing/Slide.h
+7
-0
ASCOfficePPTXFile/Editor/Drawing/Theme.h
ASCOfficePPTXFile/Editor/Drawing/Theme.h
+0
-1
No files found.
ASCOfficePPTFile/PPTFormatLib/PPTXWriter/Converter.cpp
View file @
7d188b22
...
@@ -208,9 +208,9 @@ void NSPresentationEditor::CPPTXWriter::WriteContentTypes()
...
@@ -208,9 +208,9 @@ void NSPresentationEditor::CPPTXWriter::WriteContentTypes()
<Override PartName=
\"
/docProps/core.xml
\"
ContentType=
\"
application/vnd.openxmlformats-package.core-properties+xml
\"
/>\
<Override PartName=
\"
/docProps/core.xml
\"
ContentType=
\"
application/vnd.openxmlformats-package.core-properties+xml
\"
/>\
<Override PartName=
\"
/docProps/app.xml
\"
ContentType=
\"
application/vnd.openxmlformats-officedocument.extended-properties+xml
\"
/>"
);
<Override PartName=
\"
/docProps/app.xml
\"
ContentType=
\"
application/vnd.openxmlformats-officedocument.extended-properties+xml
\"
/>"
);
int
nThemes
=
(
int
)
m_pDocument
->
m_arThemes
.
size
();
int
nIndexLayout
=
0
;
int
nIndexLayout
=
0
;
for
(
int
nT
=
0
;
nT
<
nThemes
;
++
nT
)
for
(
size_t
nT
=
0
;
nT
<
m_pDocument
->
m_arThemes
.
size
();
++
nT
)
{
{
strContentTypes
+=
L"<Override PartName=
\"
/ppt/theme/theme"
+
std
::
to_wstring
(
nT
+
1
)
+
strContentTypes
+=
L"<Override PartName=
\"
/ppt/theme/theme"
+
std
::
to_wstring
(
nT
+
1
)
+
L".xml
\"
ContentType=
\"
application/vnd.openxmlformats-officedocument.theme+xml
\"
/>\
L".xml
\"
ContentType=
\"
application/vnd.openxmlformats-officedocument.theme+xml
\"
/>\
...
@@ -218,30 +218,30 @@ void NSPresentationEditor::CPPTXWriter::WriteContentTypes()
...
@@ -218,30 +218,30 @@ void NSPresentationEditor::CPPTXWriter::WriteContentTypes()
L".xml
\"
ContentType=
\"
application/vnd.openxmlformats-officedocument.presentationml.slideMaster+xml
\"
/>"
;
L".xml
\"
ContentType=
\"
application/vnd.openxmlformats-officedocument.presentationml.slideMaster+xml
\"
/>"
;
int
nCountL
=
(
int
)
m_pDocument
->
m_arThemes
[
nT
].
m_arLayouts
.
size
();
for
(
size_t
nL
=
0
;
nL
<
m_pDocument
->
m_arThemes
[
nT
].
m_arLayouts
.
size
();
++
nL
,
++
nIndexLayout
)
for
(
int
nL
=
0
;
nL
<
nCountL
;
++
nL
,
++
nIndexLayout
)
{
{
strContentTypes
+=
L"<Override PartName=
\"
/ppt/slideLayouts/slideLayout"
+
std
::
to_wstring
(
nIndexLayout
+
1
)
+
strContentTypes
+=
L"<Override PartName=
\"
/ppt/slideLayouts/slideLayout"
+
std
::
to_wstring
(
nIndexLayout
+
1
)
+
L".xml
\"
ContentType=
\"
application/vnd.openxmlformats-officedocument.presentationml.slideLayout+xml
\"
/>"
;
L".xml
\"
ContentType=
\"
application/vnd.openxmlformats-officedocument.presentationml.slideLayout+xml
\"
/>"
;
}
}
}
}
std
::
wstring
strNotesTheme
=
L"<Override PartName=
\"
/ppt/theme/theme"
+
std
::
to_wstring
(
nThemes
+
1
)
+
L".xml
\"
\
std
::
wstring
strNotesTheme
=
L"<Override PartName=
\"
/ppt/theme/theme"
+
std
::
to_wstring
(
m_pDocument
->
m_arThemes
.
size
()
+
1
)
+
L".xml
\"
\
ContentType=
\"
application/vnd.openxmlformats-officedocument.theme+xml
\"
/>"
;
ContentType=
\"
application/vnd.openxmlformats-officedocument.theme+xml
\"
/>"
;
strContentTypes
+=
strNotesTheme
;
strContentTypes
+=
strNotesTheme
;
strContentTypes
+=
_T
(
"<Override PartName=
\"
/ppt/notesMasters/notesMaster1.xml
\"
ContentType=
\"
application/vnd.openxmlformats-officedocument.presentationml.notesMaster+xml
\"
/>"
);
strContentTypes
+=
_T
(
"<Override PartName=
\"
/ppt/notesMasters/notesMaster1.xml
\"
ContentType=
\"
application/vnd.openxmlformats-officedocument.presentationml.notesMaster+xml
\"
/>"
);
int
nCountS
=
(
int
)
m_pDocument
->
m_arSlides
.
size
();
for
(
size_t
nS
=
0
;
nS
<
m_pDocument
->
m_arSlides
.
size
();
++
nS
)
for
(
int
nS
=
0
;
nS
<
nCountS
;
++
nS
)
{
{
strContentTypes
+=
L"<Override PartName=
\"
/ppt/slides/slide"
+
std
::
to_wstring
(
nS
+
1
)
strContentTypes
+=
L"<Override PartName=
\"
/ppt/slides/slide"
+
std
::
to_wstring
(
nS
+
1
)
+
L".xml
\"
ContentType=
\"
application/vnd.openxmlformats-officedocument.presentationml.slide+xml
\"
/>"
;
+
L".xml
\"
ContentType=
\"
application/vnd.openxmlformats-officedocument.presentationml.slide+xml
\"
/>"
;
}
for
(
size_t
nS
=
0
;
nS
<
m_pDocument
->
m_arNotes
.
size
();
++
nS
)
{
strContentTypes
+=
L"<Override PartName=
\"
/ppt/notesSlides/notesSlide"
+
std
::
to_wstring
(
nS
+
1
)
strContentTypes
+=
L"<Override PartName=
\"
/ppt/notesSlides/notesSlide"
+
std
::
to_wstring
(
nS
+
1
)
+
L".xml
\"
ContentType=
\"
application/vnd.openxmlformats-officedocument.presentationml.notesSlide+xml
\"
/>"
;
+
L".xml
\"
ContentType=
\"
application/vnd.openxmlformats-officedocument.presentationml.notesSlide+xml
\"
/>"
;
}
}
strContentTypes
+=
_T
(
"</Types>"
);
strContentTypes
+=
_T
(
"</Types>"
);
CFile
oFile
;
CFile
oFile
;
...
@@ -264,9 +264,9 @@ void NSPresentationEditor::CPPTXWriter::WriteApp(CFile& oFile)
...
@@ -264,9 +264,9 @@ void NSPresentationEditor::CPPTXWriter::WriteApp(CFile& oFile)
oFile
.
WriteStringUTF8
(
str1
);
oFile
.
WriteStringUTF8
(
str1
);
oFile
.
WriteStringUTF8
(
L"<Slides>"
+
std
::
to_wstring
(
m_pDocument
->
m_arSlides
.
size
())
+
L"</Slides>"
);
oFile
.
WriteStringUTF8
(
L"<Slides>"
+
std
::
to_wstring
(
m_pDocument
->
m_arSlides
.
size
())
+
L"</Slides>"
);
oFile
.
WriteStringUTF8
(
L"<Notes>"
+
std
::
to_wstring
(
m_pDocument
->
m_arNotes
.
size
())
+
L"</Notes>"
);
oFile
.
WriteStringUTF8
(
L"<Notes>0</Notes>\
oFile
.
WriteStringUTF8
(
L"<HiddenSlides>0</HiddenSlides>\
<HiddenSlides>0</HiddenSlides>\
<MMClips>2</MMClips>\
<MMClips>2</MMClips>\
<ScaleCrop>false</ScaleCrop>\
<ScaleCrop>false</ScaleCrop>\
<HeadingPairs>\
<HeadingPairs>\
...
@@ -301,7 +301,7 @@ void NSPresentationEditor::CPPTXWriter::WriteApp(CFile& oFile)
...
@@ -301,7 +301,7 @@ void NSPresentationEditor::CPPTXWriter::WriteApp(CFile& oFile)
<LinksUpToDate>false</LinksUpToDate>\
<LinksUpToDate>false</LinksUpToDate>\
<SharedDoc>false</SharedDoc>\
<SharedDoc>false</SharedDoc>\
<HyperlinksChanged>false</HyperlinksChanged>\
<HyperlinksChanged>false</HyperlinksChanged>\
<AppVersion>
1.0
000</AppVersion>\
<AppVersion>
4.4
000</AppVersion>\
</Properties>"
);
</Properties>"
);
strMemory
+=
str5
;
strMemory
+=
str5
;
...
@@ -437,7 +437,7 @@ void NSPresentationEditor::CPPTXWriter::WriteAll()
...
@@ -437,7 +437,7 @@ void NSPresentationEditor::CPPTXWriter::WriteAll()
NSDirectory
::
CreateDirectory
(
strPptDirectory
+
_T
(
"slideLayouts"
));
NSDirectory
::
CreateDirectory
(
strPptDirectory
+
_T
(
"slideLayouts"
));
NSDirectory
::
CreateDirectory
(
strPptDirectory
+
_T
(
"slideLayouts"
)
+
FILE_SEPARATOR_STR
+
_T
(
"_rels"
));
NSDirectory
::
CreateDirectory
(
strPptDirectory
+
_T
(
"slideLayouts"
)
+
FILE_SEPARATOR_STR
+
_T
(
"_rels"
));
NSDirectory
::
CreateDirectory
(
strPptDirectory
+
_T
(
"slides"
));
NSDirectory
::
CreateDirectory
(
strPptDirectory
+
_T
(
"slides"
));
NSDirectory
::
CreateDirectory
(
strPptDirectory
+
_T
(
"slides"
)
+
FILE_SEPARATOR_STR
+
_T
(
"_rels"
));
NSDirectory
::
CreateDirectory
(
strPptDirectory
+
_T
(
"slides"
)
+
FILE_SEPARATOR_STR
+
_T
(
"_rels"
));
NSDirectory
::
CreateDirectory
(
strPptDirectory
+
_T
(
"notesMasters"
));
NSDirectory
::
CreateDirectory
(
strPptDirectory
+
_T
(
"notesMasters"
));
NSDirectory
::
CreateDirectory
(
strPptDirectory
+
_T
(
"notesMasters"
)
+
FILE_SEPARATOR_STR
+
_T
(
"_rels"
));
NSDirectory
::
CreateDirectory
(
strPptDirectory
+
_T
(
"notesMasters"
)
+
FILE_SEPARATOR_STR
+
_T
(
"_rels"
));
NSDirectory
::
CreateDirectory
(
strPptDirectory
+
_T
(
"notesSlides"
));
NSDirectory
::
CreateDirectory
(
strPptDirectory
+
_T
(
"notesSlides"
));
...
@@ -467,11 +467,12 @@ void NSPresentationEditor::CPPTXWriter::WriteAll()
...
@@ -467,11 +467,12 @@ void NSPresentationEditor::CPPTXWriter::WriteAll()
oFileRels
.
CreateFile
(
strNotesMasterRelsFile
);
oFileRels
.
CreateFile
(
strNotesMasterRelsFile
);
oFileRels
.
WriteStringUTF8
(
strVal
);
oFileRels
.
WriteStringUTF8
(
strVal
);
oFileRels
.
CloseFile
();
oFileRels
.
CloseFile
();
// -----------------------------------------------------
// -----------------------------------------------------
WriteThemes
();
WriteThemes
();
WriteSlides
();
WriteSlides
();
WriteNotes
();
}
}
void
NSPresentationEditor
::
CPPTXWriter
::
WriteThemes
()
void
NSPresentationEditor
::
CPPTXWriter
::
WriteThemes
()
...
@@ -826,14 +827,14 @@ void NSPresentationEditor::CPPTXWriter::WriteSlide(int nIndexSlide)
...
@@ -826,14 +827,14 @@ void NSPresentationEditor::CPPTXWriter::WriteSlide(int nIndexSlide)
CSlide
*
pSlide
=
m_pDocument
->
m_arSlides
[
nIndexSlide
];
CSlide
*
pSlide
=
m_pDocument
->
m_arSlides
[
nIndexSlide
];
if
(
0
==
pSlide
->
m_lThemeID
)
if
(
0
==
pSlide
->
m_lThemeID
)
oRels
.
StartSlide
(
pSlide
->
m_lLayoutID
,
nIndexSlide
);
oRels
.
StartSlide
(
pSlide
->
m_lLayoutID
,
pSlide
->
m_lNotesID
);
else
else
{
{
int
nLayout
=
pSlide
->
m_lLayoutID
;
int
nLayout
=
pSlide
->
m_lLayoutID
;
for
(
int
i
=
0
;
i
<
pSlide
->
m_lThemeID
;
++
i
)
for
(
int
i
=
0
;
i
<
pSlide
->
m_lThemeID
;
++
i
)
nLayout
+=
(
int
)
m_pDocument
->
m_arThemes
[
i
].
m_arLayouts
.
size
();
nLayout
+=
(
int
)
m_pDocument
->
m_arThemes
[
i
].
m_arLayouts
.
size
();
oRels
.
StartSlide
(
nLayout
,
nIndexSlide
);
oRels
.
StartSlide
(
nLayout
,
pSlide
->
m_lNotesID
);
}
}
oWriter
.
WriteString
(
std
::
wstring
(
L"<?xml version=
\"
1.0
\"
encoding=
\"
UTF-8
\"
standalone=
\"
yes
\"
?>"
));
oWriter
.
WriteString
(
std
::
wstring
(
L"<?xml version=
\"
1.0
\"
encoding=
\"
UTF-8
\"
standalone=
\"
yes
\"
?>"
));
...
@@ -881,7 +882,54 @@ void NSPresentationEditor::CPPTXWriter::WriteSlide(int nIndexSlide)
...
@@ -881,7 +882,54 @@ void NSPresentationEditor::CPPTXWriter::WriteSlide(int nIndexSlide)
strFile
=
L"slide"
+
std
::
to_wstring
(
nIndexSlide
+
1
)
+
L".xml.rels"
;
strFile
=
L"slide"
+
std
::
to_wstring
(
nIndexSlide
+
1
)
+
L".xml.rels"
;
oRels
.
SaveRels
(
strFileSlidePath
+
_T
(
"_rels"
)
+
FILE_SEPARATOR_STR
+
strFile
);
oRels
.
SaveRels
(
strFileSlidePath
+
_T
(
"_rels"
)
+
FILE_SEPARATOR_STR
+
strFile
);
}
}
void
NSPresentationEditor
::
CPPTXWriter
::
WriteNotes
(
int
nIndexNotes
)
{
CStringWriter
oWriter
;
CRelsGenerator
oRels
(
&
m_oManager
);
CSlide
*
pNotes
=
m_pDocument
->
m_arNotes
[
nIndexNotes
];
oRels
.
StartNotes
(
pNotes
->
m_lSlideID
);
oWriter
.
WriteString
(
std
::
wstring
(
L"<?xml version=
\"
1.0
\"
encoding=
\"
UTF-8
\"
standalone=
\"
yes
\"
?>"
));
oWriter
.
WriteString
(
std
::
wstring
(
L"<p:notes xmlns:a=
\"
http://schemas.openxmlformats.org/drawingml/2006/main
\"
xmlns:r=
\"
http://schemas.openxmlformats.org/officeDocument/2006/relationships
\"
xmlns:p=
\"
http://schemas.openxmlformats.org/presentationml/2006/main
\"
"
));
if
(
!
pNotes
->
m_bShowMasterShapes
)
oWriter
.
WriteString
(
std
::
wstring
(
L" showMasterSp=
\"
0
\"
"
));
oWriter
.
WriteString
(
std
::
wstring
(
L">"
));
oWriter
.
WriteString
(
std
::
wstring
(
L"<p:cSld>"
));
if
(
pNotes
->
m_bIsBackground
)
{
WriteBackground
(
oWriter
,
oRels
,
pNotes
->
m_oBackground
);
}
oWriter
.
WriteString
(
std
::
wstring
(
L"<p:spTree><p:nvGrpSpPr><p:cNvPr id=
\"
1
\"
name=
\"\"
/><p:cNvGrpSpPr/><p:nvPr/></p:nvGrpSpPr><p:grpSpPr>\
<a:xfrm><a:off x=
\"
0
\"
y=
\"
0
\"
/><a:ext cx=
\"
0
\"
cy=
\"
0
\"
/><a:chOff x=
\"
0
\"
y=
\"
0
\"
/><a:chExt cx=
\"
0
\"
cy=
\"
0
\"
/></a:xfrm></p:grpSpPr>"
));
for
(
size_t
nEl
=
0
;
nEl
<
pNotes
->
m_arElements
.
size
();
++
nEl
)
{
WriteElement
(
oWriter
,
oRels
,
pNotes
->
m_arElements
[
nEl
],
NULL
);
}
oWriter
.
WriteString
(
std
::
wstring
(
L"</p:spTree></p:cSld>"
));
oWriter
.
WriteString
(
std
::
wstring
(
L"<p:clrMapOvr><a:masterClrMapping/></p:clrMapOvr>"
));
oWriter
.
WriteString
(
std
::
wstring
(
L"</p:notes>"
));
oRels
.
CloseRels
();
std
::
wstring
strXml
=
oWriter
.
GetData
();
std
::
wstring
strFile
=
L"notesSlide"
+
std
::
to_wstring
(
nIndexNotes
+
1
)
+
L".xml"
;
std
::
wstring
strFileSlidePath
=
m_strTempDirectory
+
FILE_SEPARATOR_STR
+
_T
(
"ppt"
)
+
FILE_SEPARATOR_STR
+
_T
(
"notesSlides"
)
+
FILE_SEPARATOR_STR
;
CFile
oFile
;
oFile
.
CreateFile
(
strFileSlidePath
+
strFile
);
oFile
.
WriteStringUTF8
(
strXml
);
oFile
.
CloseFile
();
strFile
=
L"notesSlide"
+
std
::
to_wstring
(
nIndexNotes
+
1
)
+
L".xml.rels"
;
oRels
.
SaveRels
(
strFileSlidePath
+
_T
(
"_rels"
)
+
FILE_SEPARATOR_STR
+
strFile
);
}
void
NSPresentationEditor
::
CPPTXWriter
::
WriteSlides
()
void
NSPresentationEditor
::
CPPTXWriter
::
WriteSlides
()
{
{
...
@@ -889,7 +937,15 @@ void NSPresentationEditor::CPPTXWriter::WriteSlides()
...
@@ -889,7 +937,15 @@ void NSPresentationEditor::CPPTXWriter::WriteSlides()
for
(
size_t
nIndexS
=
0
;
nIndexS
<
nCountSlides
;
++
nIndexS
)
for
(
size_t
nIndexS
=
0
;
nIndexS
<
nCountSlides
;
++
nIndexS
)
{
{
CRelsGenerator
::
StartNotes
((
int
)
nIndexS
,
m_strTempDirectory
,
m_pDocument
->
m_arSlides
[
nIndexS
]
->
m_strComment
);
WriteSlide
((
int
)
nIndexS
);
WriteSlide
((
int
)
nIndexS
);
}
}
}
}
void
NSPresentationEditor
::
CPPTXWriter
::
WriteNotes
()
{
size_t
nCountSlides
=
m_pDocument
->
m_arSlides
.
size
();
for
(
size_t
nIndexS
=
0
;
nIndexS
<
nCountSlides
;
++
nIndexS
)
{
WriteNotes
((
int
)
nIndexS
);
}
}
ASCOfficePPTFile/PPTFormatLib/PPTXWriter/Converter.h
View file @
7d188b22
...
@@ -54,8 +54,6 @@ namespace NSPresentationEditor
...
@@ -54,8 +54,6 @@ namespace NSPresentationEditor
CShapeWriter
*
m_pShapeWriter
;
CShapeWriter
*
m_pShapeWriter
;
public:
CPPTXWriter
();
CPPTXWriter
();
~
CPPTXWriter
();
~
CPPTXWriter
();
...
@@ -75,8 +73,10 @@ namespace NSPresentationEditor
...
@@ -75,8 +73,10 @@ namespace NSPresentationEditor
void
WriteAll
();
void
WriteAll
();
void
WriteThemes
();
void
WriteThemes
();
void
WriteSlides
();
void
WriteSlides
();
void
WriteNotes
();
void
WriteLayout
(
CLayout
&
oLayout
,
int
nIndexLayout
,
int
nStartLayout
,
int
nIndexTheme
);
void
WriteLayout
(
CLayout
&
oLayout
,
int
nIndexLayout
,
int
nStartLayout
,
int
nIndexTheme
);
void
WriteSlide
(
int
nIndexSlide
);
void
WriteSlide
(
int
nIndexSlide
);
void
WriteNotes
(
int
nIndexNotes
);
void
WriteColorScheme
(
CStringWriter
&
oWriter
,
const
std
::
wstring
&
name
,
const
std
::
vector
<
CColor
>
&
colors
,
bool
extra
=
false
);
void
WriteColorScheme
(
CStringWriter
&
oWriter
,
const
std
::
wstring
&
name
,
const
std
::
vector
<
CColor
>
&
colors
,
bool
extra
=
false
);
void
WriteBackground
(
CStringWriter
&
oWriter
,
CRelsGenerator
&
oRels
,
CBrush
&
oBackground
);
void
WriteBackground
(
CStringWriter
&
oWriter
,
CRelsGenerator
&
oRels
,
CBrush
&
oBackground
);
...
...
ASCOfficePPTFile/PPTFormatLib/PPTXWriter/ImageManager.h
View file @
7d188b22
...
@@ -196,59 +196,34 @@ namespace NSPresentationEditor
...
@@ -196,59 +196,34 @@ namespace NSPresentationEditor
m_oWriter
.
WriteString
(
str
);
m_oWriter
.
WriteString
(
str
);
}
}
inline
void
StartSlide
(
int
nIndexLayout
,
int
nIndexSlide
)
inline
void
StartNotes
(
int
nIndexSlide
)
{
{
m_oWriter
.
WriteString
(
L"<?xml version=
\"
1.0
\"
encoding=
\"
UTF-8
\"
standalone=
\"
yes
\"
?>\
m_oWriter
.
WriteString
(
L"<?xml version=
\"
1.0
\"
encoding=
\"
UTF-8
\"
standalone=
\"
yes
\"
?>\
<Relationships xmlns=
\"
http://schemas.openxmlformats.org/package/2006/relationships
\"
>"
);
<Relationships xmlns=
\"
http://schemas.openxmlformats.org/package/2006/relationships
\"
>"
);
m_oWriter
.
WriteString
(
L"<Relationship Id=
\"
rId"
+
std
::
to_wstring
(
m_lNextRelsID
++
)
+
L"
\"
Type=
\"
http://schemas.openxmlformats.org/officeDocument/2006/relationships/slideLayout
\"
Target=
\"
../slideLayouts/slideLayout"
if
(
nIndexSlide
>=
0
)
+
std
::
to_wstring
(
nIndexLayout
+
1
)
+
L".xml
\"
/>"
);
{
m_oWriter
.
WriteString
(
L"<Relationship Id=
\"
rId"
+
std
::
to_wstring
(
m_lNextRelsID
++
)
+
m_oWriter
.
WriteString
(
L"<Relationship Id=
\"
rId"
+
std
::
to_wstring
(
m_lNextRelsID
++
)
+
L"
\"
Type=
\"
http://schemas.openxmlformats.org/officeDocument/2006/relationships/notesSlide
\"
Target=
\"
../slides/slide"
L"
\"
Type=
\"
http://schemas.openxmlformats.org/officeDocument/2006/relationships/notesSlide
\"
Target=
\"
../notesSlides/notesSlide"
+
std
::
to_wstring
(
nIndexSlide
+
1
)
+
L".xml
\"
/>"
);
+
std
::
to_wstring
(
nIndexSlide
+
1
)
+
L".xml
\"
/>"
);
}
}
}
static
inline
void
StartNotes
(
int
nIndexSlide
,
std
::
wstring
strDirectory
,
std
::
wstring
strComment
)
inline
void
StartSlide
(
int
nIndexLayout
,
int
nIndexNotes
)
{
{
std
::
wstring
sNum
=
std
::
to_wstring
(
nIndexSlide
+
1
);
m_oWriter
.
WriteString
(
L"<?xml version=
\"
1.0
\"
encoding=
\"
UTF-8
\"
standalone=
\"
yes
\"
?>\
<Relationships xmlns=
\"
http://schemas.openxmlformats.org/package/2006/relationships
\"
>"
);
std
::
wstring
strNoteSlideRels
=
_T
(
"<?xml version=
\"
1.0
\"
encoding=
\"
UTF-8
\"
standalone=
\"
yes
\"
?>\
<Relationships xmlns=
\"
http://schemas.openxmlformats.org/package/2006/relationships
\"
>\
<Relationship Id=
\"
rId2
\"
Type=
\"
http://schemas.openxmlformats.org/officeDocument/2006/relationships/slide
\"
Target=
\"
../slides/slide"
)
+
sNum
+
_T
(
".xml
\"
/>\
<Relationship Id=
\"
rId1
\"
Type=
\"
http://schemas.openxmlformats.org/officeDocument/2006/relationships/notesMaster
\"
Target=
\"
../notesMasters/notesMaster1.xml
\"
/>\
</Relationships>"
);
std
::
wstring
strNoteRels
=
strDirectory
+
FILE_SEPARATOR_STR
+
_T
(
"ppt"
)
+
+
FILE_SEPARATOR_STR
+
_T
(
"notesSlides"
)
+
FILE_SEPARATOR_STR
+
_T
(
"_rels"
)
+
FILE_SEPARATOR_STR
+
_T
(
"notesSlide"
)
+
sNum
+
_T
(
".xml.rels"
);
CFile
oFile
;
oFile
.
CreateFile
(
strNoteRels
);
oFile
.
WriteStringUTF8
(
strNoteSlideRels
);
oFile
.
CloseFile
();
std
::
wstring
strNoteSlide
=
strDirectory
+
FILE_SEPARATOR_STR
+
_T
(
"ppt"
)
+
+
FILE_SEPARATOR_STR
+
_T
(
"notesSlides"
)
+
FILE_SEPARATOR_STR
+
_T
(
"notesSlide"
)
+
sNum
+
_T
(
".xml"
);
oFile
.
CreateFile
(
strNoteSlide
);
std
::
wstring
strW1
=
_T
(
"<?xml version=
\"
1.0
\"
encoding=
\"
UTF-8
\"
standalone=
\"
yes
\"
?>\
<p:notes xmlns:a=
\"
http://schemas.openxmlformats.org/drawingml/2006/main
\"
xmlns:r=
\"
http://schemas.openxmlformats.org/officeDocument/2006/relationships
\"
xmlns:p=
\"
http://schemas.openxmlformats.org/presentationml/2006/main
\"
>\
<p:cSld><p:spTree><p:nvGrpSpPr><p:cNvPr id=
\"
1
\"
name=
\"\"
/><p:cNvGrpSpPr/><p:nvPr/></p:nvGrpSpPr><p:grpSpPr><a:xfrm><a:off x=
\"
0
\"
y=
\"
0
\"
/>\
<a:ext cx=
\"
0
\"
cy=
\"
0
\"
/><a:chOff x=
\"
0
\"
y=
\"
0
\"
/><a:chExt cx=
\"
0
\"
cy=
\"
0
\"
/></a:xfrm></p:grpSpPr><p:sp><p:nvSpPr><p:cNvPr id=
\"
100000
\"
name=
\"\"
/>\
<p:cNvSpPr><a:spLocks noGrp=
\"
1
\"
noChangeArrowheads=
\"
1
\"
/></p:cNvSpPr><p:nvPr><p:ph type=
\"
body
\"
idx=
\"
1
\"
/></p:nvPr></p:nvSpPr><p:spPr/>\
<p:txBody><a:bodyPr/><a:lstStyle/><a:p><a:r><a:rPr smtClean=
\"
0
\"
/><a:t>"
);
std
::
wstring
strW2
=
_T
(
"</a:t></a:r><a:endParaRPr/></a:p></p:txBody></p:sp></p:spTree></p:cSld><p:clrMapOvr><a:masterClrMapping/></p:clrMapOvr></p:notes>"
);
CorrectXmlString
(
strComment
);
oFile
.
WriteStringUTF8
(
strW1
);
m_oWriter
.
WriteString
(
L"<Relationship Id=
\"
rId"
+
std
::
to_wstring
(
m_lNextRelsID
++
)
+
L"
\"
Type=
\"
http://schemas.openxmlformats.org/officeDocument/2006/relationships/slideLayout
\"
Target=
\"
../slideLayouts/slideLayout"
oFile
.
WriteStringUTF8
(
strComment
);
+
std
::
to_wstring
(
nIndexLayout
+
1
)
+
L".xml
\"
/>"
);
oFile
.
WriteStringUTF8
(
strW2
);
oFile
.
CloseFile
();
if
(
nIndexNotes
>=
0
)
{
m_oWriter
.
WriteString
(
L"<Relationship Id=
\"
rId"
+
std
::
to_wstring
(
m_lNextRelsID
++
)
+
L"
\"
Type=
\"
http://schemas.openxmlformats.org/officeDocument/2006/relationships/notesSlide
\"
Target=
\"
../notesSlides/notesSlide"
+
std
::
to_wstring
(
nIndexNotes
+
1
)
+
L".xml
\"
/>"
);
}
}
}
inline
void
CloseRels
()
inline
void
CloseRels
()
{
{
std
::
wstring
str
=
_T
(
"</Relationships>"
);
std
::
wstring
str
=
_T
(
"</Relationships>"
);
m_oWriter
.
WriteString
(
str
);
m_oWriter
.
WriteString
(
str
);
...
...
ASCOfficePPTFile/PPTFormatLib/Reader/PPTDocumentInfoOneUser.cpp
View file @
7d188b22
This diff is collapsed.
Click to expand it.
ASCOfficePPTFile/PPTFormatLib/Reader/PPTDocumentInfoOneUser.h
View file @
7d188b22
...
@@ -47,8 +47,6 @@ public:
...
@@ -47,8 +47,6 @@ public:
std
::
map
<
DWORD
,
DWORD
>
m_mapOffsetInPIDs
;
std
::
map
<
DWORD
,
DWORD
>
m_mapOffsetInPIDs
;
CRecordDocument
m_oDocument
;
CRecordDocument
m_oDocument
;
//todooo при переходе на C++11 использовать НУЖНЫЙ здесь unsorted_map - m_arr .. Order уберутся
std
::
map
<
DWORD
,
CRecordSlide
*>
m_mapSlides
;
std
::
map
<
DWORD
,
CRecordSlide
*>
m_mapSlides
;
std
::
map
<
DWORD
,
CRecordSlide
*>
m_mapMasters
;
std
::
map
<
DWORD
,
CRecordSlide
*>
m_mapMasters
;
std
::
map
<
DWORD
,
CRecordSlide
*>
m_mapNotes
;
std
::
map
<
DWORD
,
CRecordSlide
*>
m_mapNotes
;
...
@@ -66,6 +64,7 @@ public:
...
@@ -66,6 +64,7 @@ public:
// это как бы ППT-шная обертка над слайдом
// это как бы ППT-шная обертка над слайдом
std
::
vector
<
CSlideInfo
>
m_arSlideWrapper
;
std
::
vector
<
CSlideInfo
>
m_arSlideWrapper
;
std
::
vector
<
CSlideInfo
>
m_arMasterWrapper
;
std
::
vector
<
CSlideInfo
>
m_arMasterWrapper
;
std
::
vector
<
CSlideInfo
>
m_arNotesWrapper
;
// эти параметры - одни на весь документ.
// эти параметры - одни на весь документ.
// чтобы поддержать нашу схему (пптх) - копируем их в темы
// чтобы поддержать нашу схему (пптх) - копируем их в темы
...
@@ -106,8 +105,8 @@ public:
...
@@ -106,8 +105,8 @@ public:
nullable
<
WORD
>
m_wLanguage
;
// язык пользователя (редактора)
nullable
<
WORD
>
m_wLanguage
;
// язык пользователя (редактора)
bool
m_bRtl
;
bool
m_bRtl
;
bool
m_bShowComments
;
bool
m_bShowComments
;
public:
//-----------------------------------------------------------------------------------------------------
CPPTUserInfo
();
CPPTUserInfo
();
~
CPPTUserInfo
();
~
CPPTUserInfo
();
...
@@ -119,6 +118,7 @@ public:
...
@@ -119,6 +118,7 @@ public:
void
NormalizeCoords
(
long
lWidth
,
long
lHeight
);
void
NormalizeCoords
(
long
lWidth
,
long
lHeight
);
void
LoadSlide
(
DWORD
dwSlideID
,
CSlide
*
pSlide
);
void
LoadSlide
(
DWORD
dwSlideID
,
CSlide
*
pSlide
);
void
LoadNotes
(
DWORD
dwNotesID
,
CSlide
*
pSlide
);
void
LoadMasters
(
const
LONG
&
lOriginWidth
,
const
LONG
&
lOriginHeight
);
void
LoadMasters
(
const
LONG
&
lOriginWidth
,
const
LONG
&
lOriginHeight
);
...
@@ -169,7 +169,6 @@ public:
...
@@ -169,7 +169,6 @@ public:
oScheme
=
oArrayMem
;
oScheme
=
oArrayMem
;
}
}
std
::
wstring
ConvertLayoutType
(
INT
nGeom
,
BYTE
*
pPlaceholders
)
std
::
wstring
ConvertLayoutType
(
INT
nGeom
,
BYTE
*
pPlaceholders
)
{
{
...
@@ -287,6 +286,7 @@ public:
...
@@ -287,6 +286,7 @@ public:
return
_T
(
"blank"
);
return
_T
(
"blank"
);
}
}
void
AddAnimation
(
DWORD
dwSlideID
,
double
Width
,
double
Height
,
IElement
*
pElement
);
void
AddAnimation
(
DWORD
dwSlideID
,
double
Width
,
double
Height
,
IElement
*
pElement
);
void
AddAudioTransition
(
DWORD
dwSlideID
,
CTransition
*
pTransition
,
const
std
::
wstring
&
strFilePath
);
void
AddAudioTransition
(
DWORD
dwSlideID
,
CTransition
*
pTransition
,
const
std
::
wstring
&
strFilePath
);
...
...
ASCOfficePPTFile/PPTFormatLib/Reader/PPTFileDefines.h
View file @
7d188b22
...
@@ -73,10 +73,26 @@ typedef BYTE BOOL1;
...
@@ -73,10 +73,26 @@ typedef BYTE BOOL1;
#define RECORD_TYPE_EXOBJLIST_ATOM 1034
#define RECORD_TYPE_EXOBJLIST_ATOM 1034
#define RECORD_TYPE_PPDRAWING_GROUP 1035
#define RECORD_TYPE_PPDRAWING_GROUP 1035
#define RECORD_TYPE_PPDRAWING 1036
#define RECORD_TYPE_PPDRAWING 1036
#define RT_RoundTripTheme12Atom 1038
#define RT_RoundTripColorMapping12Atom 1039
#define RECORD_TYPE_NAMEDSHOWS 1040
#define RECORD_TYPE_NAMEDSHOWS 1040
#define RECORD_TYPE_NAMEDSHOW 1041
#define RECORD_TYPE_NAMEDSHOW 1041
#define RECORD_TYPE_NAMEDSHOW_SLIDES 1042
#define RECORD_TYPE_NAMEDSHOW_SLIDES 1042
#define RECORD_TYPE_SHEET_PROPERTIES 1044
#define RECORD_TYPE_SHEET_PROPERTIES 1044
#define RECORD_TYPE_ORIGINALMAINMASTERID 1052
#define RECORD_TYPE_COMPOSITEMASTERID 1053
#define RECORD_TYPE_ROUNDTRIPCONTENTMASTERINFO12 1054
#define RECORD_TYPE_ROUNDTRIPSHAPEID12 1055
#define RECORD_TYPE_ROUNDTRIPHFPLACEHOLDER12 1056
#define RECORD_TYPE_ROUNDTRIPCONTENTMASTERID 1058
#define RECORD_TYPE_ROUNDTRIPOARTTEXTSTYLES12 1059
#define RECORD_TYPE_ROUNDTRIPHEADERFOOTERDEFAULTS12ATOM 1060
#define RECORD_TYPE_ROUNDTRIPDOCFLAGS12 1061
#define RECORD_TYPE_ROUNDTRIPSHAPECHECKSUMFORCUSTOMLAYOUTS12 1062
#define RECORD_TYPE_ROUNDTRIPNOTESMASTERTEXTSTYLES12 1063
#define RECORD_TYPE_ROUNDTRIPCUSTOMTABLESTYLES12 1064
#define RECORD_TYPE_LIST 2000
#define RECORD_TYPE_LIST 2000
#define RECORD_TYPE_FONTCOLLECTION 2005
#define RECORD_TYPE_FONTCOLLECTION 2005
#define RECORD_TYPE_BOOKMARKCOLLECTION 2019
#define RECORD_TYPE_BOOKMARKCOLLECTION 2019
...
@@ -182,19 +198,6 @@ typedef BYTE BOOL1;
...
@@ -182,19 +198,6 @@ typedef BYTE BOOL1;
// Records ~12050 seem to be related to Document Encryption
// Records ~12050 seem to be related to Document Encryption
#define RECORD_TYPE_DOCUMENT_ENCRYPTION_ATOM 12052
#define RECORD_TYPE_DOCUMENT_ENCRYPTION_ATOM 12052
#define RECORD_TYPE_ORIGINALMAINMASTERID 1052
#define RECORD_TYPE_COMPOSITEMASTERID 1053
#define RECORD_TYPE_ROUNDTRIPCONTENTMASTERINFO12 1054
#define RECORD_TYPE_ROUNDTRIPSHAPEID12 1055
#define RECORD_TYPE_ROUNDTRIPHFPLACEHOLDER12 1056
#define RECORD_TYPE_ROUNDTRIPCONTENTMASTERID 1058
#define RECORD_TYPE_ROUNDTRIPOARTTEXTSTYLES12 1059
#define RECORD_TYPE_ROUNDTRIPHEADERFOOTERDEFAULTS12ATOM 1060
#define RECORD_TYPE_ROUNDTRIPDOCFLAGS12 1061
#define RECORD_TYPE_ROUNDTRIPSHAPECHECKSUMFORCUSTOMLAYOUTS12 1062
#define RECORD_TYPE_ROUNDTRIPNOTESMASTERTEXTSTYLES12 1063
#define RECORD_TYPE_ROUNDTRIPCUSTOMTABLESTYLES12 1064
//records greater then 0xF000 belong to with Microsoft Office Drawing format also known as Escher
//records greater then 0xF000 belong to with Microsoft Office Drawing format also known as Escher
#define RECORD_TYPE_ESCHER_DGG_CONTAINER 0xF000
#define RECORD_TYPE_ESCHER_DGG_CONTAINER 0xF000
#define RECORD_TYPE_ESCHER_DGG 0xF006
#define RECORD_TYPE_ESCHER_DGG 0xF006
...
...
ASCOfficePPTFile/PPTFormatLib/Reader/Records.cpp
View file @
7d188b22
...
@@ -95,8 +95,8 @@ IRecord* CreateByType(SRecordHeader oHeader)
...
@@ -95,8 +95,8 @@ IRecord* CreateByType(SRecordHeader oHeader)
//CREATE_BY_TYPE(RECORD_TYPE_DOC_ROUTING_SLIP , CRecordDocRoutingSlipAtom)
//CREATE_BY_TYPE(RECORD_TYPE_DOC_ROUTING_SLIP , CRecordDocRoutingSlipAtom)
//CREATE_BY_TYPE(RECORD_TYPE_EXOBJLIST_ATOM , CRecordExObjListAtom)
//CREATE_BY_TYPE(RECORD_TYPE_EXOBJLIST_ATOM , CRecordExObjListAtom)
//CREATE_BY_TYPE(RECORD_TYPE_UNKNOWN , CRecordGridSpacing10Atom)
//CREATE_BY_TYPE(RECORD_TYPE_UNKNOWN , CRecordGridSpacing10Atom)
//CREATE_BY_TYPE(RECORD_TYPE_UNKNOWN
, CRecordRoundTripThemeAtom)
CREATE_BY_TYPE
(
RT_RoundTripTheme12Atom
,
CRecordRoundTripThemeAtom
)
//CREATE_BY_TYPE(RECORD_TYPE_UNKNOWN
, CRecordRoundTripColorMappingAtom)
CREATE_BY_TYPE
(
RT_RoundTripColorMapping12Atom
,
CRecordRoundTripColorMappingAtom
)
//CREATE_BY_TYPE(RECORD_TYPE_NAMEDSHOW_SLIDES , CRecordNamedShowSlidesAtom)
//CREATE_BY_TYPE(RECORD_TYPE_NAMEDSHOW_SLIDES , CRecordNamedShowSlidesAtom)
//CREATE_BY_TYPE(RECORD_TYPE_SHEET_PROPERTIES , CRecordNormalViewSetInfoAtom)
//CREATE_BY_TYPE(RECORD_TYPE_SHEET_PROPERTIES , CRecordNormalViewSetInfoAtom)
...
@@ -109,10 +109,10 @@ IRecord* CreateByType(SRecordHeader oHeader)
...
@@ -109,10 +109,10 @@ IRecord* CreateByType(SRecordHeader oHeader)
CREATE_BY_TYPE
(
RECORD_TYPE_ROUNDTRIPHFPLACEHOLDER12
,
CRecordRoundTripHFPlaceholder12Atom
)
CREATE_BY_TYPE
(
RECORD_TYPE_ROUNDTRIPHFPLACEHOLDER12
,
CRecordRoundTripHFPlaceholder12Atom
)
//CREATE_BY_TYPE(RECORD_TYPE_ROUNDTRIPCONTENTMASTERID , CRecordRoundTripContentMasterId12Atom)
//CREATE_BY_TYPE(RECORD_TYPE_ROUNDTRIPCONTENTMASTERID , CRecordRoundTripContentMasterId12Atom)
//CREATE_BY_TYPE(RECORD_TYPE_ROUNDTRIPOARTTEXTSTYLES12 , CRecordRoundTripOArtTextStyles12Atom)
//CREATE_BY_TYPE(RECORD_TYPE_ROUNDTRIPOARTTEXTSTYLES12 , CRecordRoundTripOArtTextStyles12Atom)
CREATE_BY_TYPE
(
RECORD_TYPE_ROUNDTRIPHEADERFOOTERDEFAULTS12ATOM
,
CRecordRoundTripHeaderFooterDefaults12Atom
)
CREATE_BY_TYPE
(
RECORD_TYPE_ROUNDTRIPHEADERFOOTERDEFAULTS12ATOM
,
CRecordRoundTripHeaderFooterDefaults12Atom
)
CREATE_BY_TYPE
(
RECORD_TYPE_ROUNDTRIPNOTESMASTERTEXTSTYLES12
,
CRecordRoundTripNotesMasterTextStyles12Atom
)
//CREATE_BY_TYPE(RECORD_TYPE_ROUNDTRIPDOCFLAGS12 , CRecordRoundTripDocFlags12Atom)
//CREATE_BY_TYPE(RECORD_TYPE_ROUNDTRIPDOCFLAGS12 , CRecordRoundTripDocFlags12Atom)
//CREATE_BY_TYPE(RECORD_TYPE_ROUNDTRIPSHAPECHECKSUMFORCUSTOMLAYOUTS12 , CRecordRoundTripShapeCheckSumForCustomLayouts12Atom)
//CREATE_BY_TYPE(RECORD_TYPE_ROUNDTRIPSHAPECHECKSUMFORCUSTOMLAYOUTS12 , CRecordRoundTripShapeCheckSumForCustomLayouts12Atom)
//CREATE_BY_TYPE(RECORD_TYPE_ROUNDTRIPNOTESMASTERTEXTSTYLES12 , CRecordRoundTripNotesMasterTextStyles12Atom)
//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_BOOKMARK_SEED_ATOM , CRecordBookmarkSeedAtom)
...
...
ASCOfficePPTFile/PPTFormatLib/Reader/Records.h
View file @
7d188b22
...
@@ -182,7 +182,7 @@ public:
...
@@ -182,7 +182,7 @@ public:
return
;
return
;
// возвращаем указатели, их не удалять наверху!!!!
// возвращаем указатели, их не удалять наверху!!!!
for
(
in
t
nIndex
=
0
;
nIndex
<
m_arRecords
.
size
();
++
nIndex
)
for
(
size_
t
nIndex
=
0
;
nIndex
<
m_arRecords
.
size
();
++
nIndex
)
{
{
T
pRec
=
dynamic_cast
<
T
>
(
m_arRecords
[
nIndex
]);
T
pRec
=
dynamic_cast
<
T
>
(
m_arRecords
[
nIndex
]);
if
(
NULL
!=
pRec
)
if
(
NULL
!=
pRec
)
...
...
ASCOfficePPTFile/PPTFormatLib/Records/Animations/AnimationTypes.h
View file @
7d188b22
...
@@ -206,7 +206,7 @@ namespace Animations
...
@@ -206,7 +206,7 @@ namespace Animations
std
::
vector
<
std
::
wstring
>
arMovePath
;
std
::
vector
<
std
::
wstring
>
arMovePath
;
boost
::
algorithm
::
split
(
arMovePath
,
MovePath
,
boost
::
algorithm
::
is_any_of
(
L" "
),
boost
::
algorithm
::
token_compress_on
);
boost
::
algorithm
::
split
(
arMovePath
,
MovePath
,
boost
::
algorithm
::
is_any_of
(
L" "
),
boost
::
algorithm
::
token_compress_on
);
for
(
in
t
i
=
0
;
i
<
arMovePath
.
size
();
i
++
)
for
(
size_
t
i
=
0
;
i
<
arMovePath
.
size
();
i
++
)
{
{
ActionPoint
aPoint
;
ActionPoint
aPoint
;
aPoint
.
TYPE
=
arMovePath
[
i
++
][
0
];
aPoint
.
TYPE
=
arMovePath
[
i
++
][
0
];
...
@@ -245,7 +245,7 @@ namespace Animations
...
@@ -245,7 +245,7 @@ namespace Animations
{
{
std
::
wstring
MovePath
;
std
::
wstring
MovePath
;
for
(
in
t
i
=
0
;
i
<
m_Points
.
size
();
++
i
)
for
(
size_
t
i
=
0
;
i
<
m_Points
.
size
();
++
i
)
{
{
std
::
wstring
NextPoint
;
std
::
wstring
NextPoint
;
...
...
ASCOfficePPTFile/PPTFormatLib/Records/DocumentRecords.h
View file @
7d188b22
...
@@ -39,9 +39,7 @@ public:
...
@@ -39,9 +39,7 @@ public:
std
::
vector
<
SSlidePersist
>
m_arNotePersists
;
std
::
vector
<
SSlidePersist
>
m_arNotePersists
;
std
::
vector
<
SSlidePersist
>
m_arSlidePersists
;
std
::
vector
<
SSlidePersist
>
m_arSlidePersists
;
public:
CRecordDocument
()
CRecordDocument
()
:
m_arMasterPersists
(),
m_arNotePersists
(),
m_arSlidePersists
()
{
{
}
}
...
@@ -145,31 +143,26 @@ public:
...
@@ -145,31 +143,26 @@ public:
std
::
vector
<
CRecordSlideListWithText
*>
oArraySlideWithText
;
std
::
vector
<
CRecordSlideListWithText
*>
oArraySlideWithText
;
this
->
GetRecordsByType
(
&
oArraySlideWithText
,
true
,
false
);
this
->
GetRecordsByType
(
&
oArraySlideWithText
,
true
,
false
);
for
(
in
t
nIndexList
=
0
;
nIndexList
<
oArraySlideWithText
.
size
();
++
nIndexList
)
for
(
size_
t
nIndexList
=
0
;
nIndexList
<
oArraySlideWithText
.
size
();
++
nIndexList
)
{
{
CRecordSlideListWithText
*
pAtom
=
oArraySlideWithText
[
nIndexList
];
CRecordSlideListWithText
*
pAtom
=
oArraySlideWithText
[
nIndexList
];
std
::
vector
<
SSlidePersist
>*
pArray
=
NULL
;
std
::
vector
<
SSlidePersist
>*
pArray
=
NULL
;
switch
(
pAtom
->
m_Type
)
switch
(
pAtom
->
m_Type
)
{
{
case
CRecordSlideListWithText
:
:
CollectionOfMasterSlides
:
case
CRecordSlideListWithText
:
:
CollectionOfMasterSlides
:
{
{
pArray
=
&
m_arMasterPersists
;
pArray
=
&
m_arMasterPersists
;
break
;
}
break
;
}
case
CRecordSlideListWithText
:
:
CollectionOfNotesSlides
:
case
CRecordSlideListWithText
:
:
CollectionOfNotesSlides
:
{
{
pArray
=
&
m_arNotePersists
;
pArray
=
&
m_arNotePersists
;
break
;
}
break
;
}
case
CRecordSlideListWithText
:
:
CollectionOfSlides
:
case
CRecordSlideListWithText
:
:
CollectionOfSlides
:
{
{
pArray
=
&
m_arSlidePersists
;
pArray
=
&
m_arSlidePersists
;
break
;
}
break
;
}
default:
default:
{
{
// этого не может быть...
// этого не может быть...
continue
;
continue
;
...
...
ASCOfficePPTFile/PPTFormatLib/Records/Drawing/BlipStoreContainer.h
View file @
7d188b22
...
@@ -53,7 +53,7 @@ public:
...
@@ -53,7 +53,7 @@ public:
pArray
->
clear
();
pArray
->
clear
();
std
::
map
<
DWORD
,
int
>
image_map
;
std
::
map
<
DWORD
,
int
>
image_map
;
for
(
in
t
nIndex
=
0
;
nIndex
<
m_arRecords
.
size
();
++
nIndex
)
for
(
size_
t
nIndex
=
0
;
nIndex
<
m_arRecords
.
size
();
++
nIndex
)
{
{
CRecordBlipStoreEntry
*
pEntry
=
dynamic_cast
<
CRecordBlipStoreEntry
*>
(
m_arRecords
[
nIndex
]);
CRecordBlipStoreEntry
*
pEntry
=
dynamic_cast
<
CRecordBlipStoreEntry
*>
(
m_arRecords
[
nIndex
]);
if
(
NULL
!=
pEntry
)
if
(
NULL
!=
pEntry
)
...
...
ASCOfficePPTFile/PPTFormatLib/Records/Drawing/GroupShapeContainer.h
View file @
7d188b22
...
@@ -71,7 +71,7 @@ public:
...
@@ -71,7 +71,7 @@ public:
oArrayShapes
[
0
]
->
bGroupShape
=
true
;
//тут описание самой группы
oArrayShapes
[
0
]
->
bGroupShape
=
true
;
//тут описание самой группы
int
nIndexBreak
=
-
1
;
int
nIndexBreak
=
-
1
;
for
(
in
t
nIndex
=
0
;
nIndex
<
oArrayShapes
.
size
();
++
nIndex
)
for
(
size_
t
nIndex
=
0
;
nIndex
<
oArrayShapes
.
size
();
++
nIndex
)
{
{
std
::
vector
<
CRecordGroupShape
*>
oArrayGroupShapes
;
std
::
vector
<
CRecordGroupShape
*>
oArrayGroupShapes
;
oArrayShapes
[
nIndex
]
->
GetRecordsByType
(
&
oArrayGroupShapes
,
false
,
true
);
oArrayShapes
[
nIndex
]
->
GetRecordsByType
(
&
oArrayGroupShapes
,
false
,
true
);
...
@@ -120,7 +120,7 @@ public:
...
@@ -120,7 +120,7 @@ public:
bool
bIsRecalc
=
((
lW1
>
0
)
&&
(
lH1
>
0
)
&&
(
lW2
>
0
)
&&
(
lH2
>
0
));
bool
bIsRecalc
=
((
lW1
>
0
)
&&
(
lH1
>
0
)
&&
(
lW2
>
0
)
&&
(
lH2
>
0
));
if
(
bIsRecalc
)
if
(
bIsRecalc
)
{
{
for
(
in
t
nIndex
=
0
;
nIndex
<
oArrayShapes
.
size
();
++
nIndex
)
for
(
size_
t
nIndex
=
0
;
nIndex
<
oArrayShapes
.
size
();
++
nIndex
)
{
{
if
(
nIndex
!=
nIndexBreak
)
if
(
nIndex
!=
nIndexBreak
)
{
{
...
...
ASCOfficePPTFile/PPTFormatLib/Records/Drawing/ShapeContainer.h
View file @
7d188b22
...
@@ -1890,7 +1890,7 @@ protected:
...
@@ -1890,7 +1890,7 @@ protected:
if
(
master_levels
)
if
(
master_levels
)
{
{
for
(
in
t
i
=
0
;
i
<
pText
->
m_arParagraphs
.
size
();
i
++
)
for
(
size_
t
i
=
0
;
i
<
pText
->
m_arParagraphs
.
size
();
i
++
)
{
{
if
(
i
>=
master_levels
->
m_arrProps
.
size
())
break
;
if
(
i
>=
master_levels
->
m_arrProps
.
size
())
break
;
...
...
ASCOfficePPTFile/PPTFormatLib/Records/HeadersFootersAtom.h
View file @
7d188b22
...
@@ -198,7 +198,7 @@ public:
...
@@ -198,7 +198,7 @@ public:
{
{
CRecordsContainer
::
ReadFromStream
(
oHeader
,
pStream
);
CRecordsContainer
::
ReadFromStream
(
oHeader
,
pStream
);
for
(
in
t
i
=
0
;
i
<
m_arRecords
.
size
();
i
++
)
for
(
size_
t
i
=
0
;
i
<
m_arRecords
.
size
();
i
++
)
{
{
switch
(
m_arRecords
[
i
]
->
m_oHeader
.
RecType
)
switch
(
m_arRecords
[
i
]
->
m_oHeader
.
RecType
)
{
{
...
...
ASCOfficePPTFile/PPTFormatLib/Records/NotesAtom.h
View file @
7d188b22
...
@@ -34,13 +34,12 @@
...
@@ -34,13 +34,12 @@
class
CRecordNotesAtom
:
public
CUnknownRecord
class
CRecordNotesAtom
:
public
CUnknownRecord
{
{
public:
UINT
m_nSlideIDRef
;
UINT
m_nSlideIDRef
;
bool
m_bMasterObjects
;
bool
m_bMasterObjects
;
bool
m_bMasterScheme
;
bool
m_bMasterScheme
;
bool
m_bMasterBackground
;
bool
m_bMasterBackground
;
public:
CRecordNotesAtom
()
CRecordNotesAtom
()
{
{
...
@@ -54,11 +53,11 @@ public:
...
@@ -54,11 +53,11 @@ public:
{
{
m_oHeader
=
oHeader
;
m_oHeader
=
oHeader
;
m_nSlideIDRef
=
(
UINT
)
StreamUtils
::
ReadDWORD
(
pStream
);
m_nSlideIDRef
=
(
UINT
)
StreamUtils
::
ReadDWORD
(
pStream
);
USHORT
nFlag
=
StreamUtils
::
ReadWORD
(
pStream
);
USHORT
nFlag
=
StreamUtils
::
ReadWORD
(
pStream
);
m_bMasterObjects
=
((
nFlag
&
0x01
)
==
0x01
);
m_bMasterObjects
=
((
nFlag
&
0x01
)
==
0x01
);
m_bMasterScheme
=
((
nFlag
&
0x02
)
==
0x02
);
m_bMasterScheme
=
((
nFlag
&
0x02
)
==
0x02
);
m_bMasterBackground
=
((
nFlag
&
0x04
)
==
0x04
);
m_bMasterBackground
=
((
nFlag
&
0x04
)
==
0x04
);
StreamUtils
::
StreamSkip
(
2
,
pStream
);
StreamUtils
::
StreamSkip
(
2
,
pStream
);
...
...
ASCOfficePPTFile/PPTFormatLib/Records/RecordsIncluder.h
View file @
7d188b22
...
@@ -91,6 +91,7 @@
...
@@ -91,6 +91,7 @@
#include "RoundTripColorMappingAtom.h"
#include "RoundTripColorMappingAtom.h"
#include "RoundTripNewPlaceholderId12Atom.h"
#include "RoundTripNewPlaceholderId12Atom.h"
#include "RoundTripThemeAtom.h"
#include "RoundTripThemeAtom.h"
#include "RoundTripNotesMasterTextStyles12Atom.h"
#include "TextRulerAtom.h"
#include "TextRulerAtom.h"
#include "ShapeFlags10Atom.h"
#include "ShapeFlags10Atom.h"
#include "ShapeFlagsAtom.h"
#include "ShapeFlagsAtom.h"
...
...
ASCOfficePPTFile/PPTFormatLib/Records/RoundTripColorMappingAtom.h
View file @
7d188b22
...
@@ -34,9 +34,8 @@
...
@@ -34,9 +34,8 @@
class
CRecordRoundTripColorMappingAtom
:
public
CUnknownRecord
class
CRecordRoundTripColorMappingAtom
:
public
CUnknownRecord
{
{
std
::
wstring
m_pString
;
public:
public:
std
::
string
m_strData
;
CRecordRoundTripColorMappingAtom
()
CRecordRoundTripColorMappingAtom
()
{
{
...
@@ -48,6 +47,7 @@ public:
...
@@ -48,6 +47,7 @@ public:
virtual
void
ReadFromStream
(
SRecordHeader
&
oHeader
,
POLE
::
Stream
*
pStream
)
virtual
void
ReadFromStream
(
SRecordHeader
&
oHeader
,
POLE
::
Stream
*
pStream
)
{
{
return
CUnknownRecord
::
ReadFromStream
(
oHeader
,
pStream
);
m_oHeader
=
oHeader
;
m_strData
=
StreamUtils
::
ReadStringA
(
pStream
,
(
long
)
m_oHeader
.
RecLen
);
}
}
};
};
ASCOfficePPTFile/PPTFormatLib/Records/RoundTripThemeAtom.h
View file @
7d188b22
...
@@ -34,9 +34,8 @@
...
@@ -34,9 +34,8 @@
class
CRecordRoundTripThemeAtom
:
public
CUnknownRecord
class
CRecordRoundTripThemeAtom
:
public
CUnknownRecord
{
{
std
::
wstring
m_strData
;
public:
public:
std
::
string
m_strData
;
CRecordRoundTripThemeAtom
()
CRecordRoundTripThemeAtom
()
{
{
...
@@ -48,6 +47,7 @@ public:
...
@@ -48,6 +47,7 @@ public:
virtual
void
ReadFromStream
(
SRecordHeader
&
oHeader
,
POLE
::
Stream
*
pStream
)
virtual
void
ReadFromStream
(
SRecordHeader
&
oHeader
,
POLE
::
Stream
*
pStream
)
{
{
return
CUnknownRecord
::
ReadFromStream
(
oHeader
,
pStream
);
m_oHeader
=
oHeader
;
m_strData
=
StreamUtils
::
ReadStringA
(
pStream
,
(
long
)
m_oHeader
.
RecLen
);
}
}
};
};
ASCOfficePPTFile/PPTFormatLib/Records/SlideContainer.h
View file @
7d188b22
...
@@ -129,7 +129,7 @@ public:
...
@@ -129,7 +129,7 @@ public:
bool
IsSlide
()
bool
IsSlide
()
{
{
for
(
in
t
nIndex
=
0
;
nIndex
<
m_arRecords
.
size
();
++
nIndex
)
for
(
size_
t
nIndex
=
0
;
nIndex
<
m_arRecords
.
size
();
++
nIndex
)
{
{
if
((
RECORD_TYPE_SLIDE
==
m_arRecords
[
nIndex
]
->
m_oHeader
.
RecType
)
||
if
((
RECORD_TYPE_SLIDE
==
m_arRecords
[
nIndex
]
->
m_oHeader
.
RecType
)
||
(
RECORD_TYPE_MAINMASTER
==
m_arRecords
[
nIndex
]
->
m_oHeader
.
RecType
)
||
(
RECORD_TYPE_MAINMASTER
==
m_arRecords
[
nIndex
]
->
m_oHeader
.
RecType
)
||
...
...
ASCOfficePPTFile/PPTFormatLib/Records/TextBytesAtom.h
View file @
7d188b22
...
@@ -59,7 +59,7 @@ public:
...
@@ -59,7 +59,7 @@ public:
{
{
pStream
->
read
(
pUTF16_low
,
m_oHeader
.
RecLen
);
pStream
->
read
(
pUTF16_low
,
m_oHeader
.
RecLen
);
for
(
int
i
=
0
;
i
<
m_oHeader
.
RecLen
;
i
++
)
for
(
UINT
i
=
0
;
i
<
m_oHeader
.
RecLen
;
i
++
)
{
{
pUTF16
[
i
]
=
pUTF16_low
[
i
];
pUTF16
[
i
]
=
pUTF16_low
[
i
];
}
}
...
...
ASCOfficePPTFile/PPTFormatLib/Records/TextSpecInfoAtom.h
View file @
7d188b22
...
@@ -86,11 +86,12 @@ public:
...
@@ -86,11 +86,12 @@ public:
int
pos_text
=
0
,
pos_si
=
0
;
int
pos_text
=
0
,
pos_si
=
0
;
int
ind
=
0
;
int
ind
=
0
;
for
(
int
i
=
0
;
i
<
pText
->
m_arParagraphs
.
size
();
i
++
)
for
(
size_t
i
=
0
;
i
<
pText
->
m_arParagraphs
.
size
();
i
++
)
{
{
if
(
ind
>=
m_arrSIs
.
size
())
break
;
if
(
ind
>=
m_arrSIs
.
size
())
break
;
for
(
in
t
j
=
0
;
j
<
pText
->
m_arParagraphs
[
i
].
m_arSpans
.
size
();
j
++
)
for
(
size_
t
j
=
0
;
j
<
pText
->
m_arParagraphs
[
i
].
m_arSpans
.
size
();
j
++
)
{
{
if
(
pos_text
+
pText
->
m_arParagraphs
[
i
].
m_arSpans
[
j
].
m_strText
.
length
()
>
pos_si
+
m_arrSIs
[
ind
].
lCount
)
if
(
pos_text
+
pText
->
m_arParagraphs
[
i
].
m_arSpans
[
j
].
m_strText
.
length
()
>
pos_si
+
m_arrSIs
[
ind
].
lCount
)
{
{
...
...
ASCOfficePPTXFile/Editor/Drawing/Document.h
View file @
7d188b22
...
@@ -41,11 +41,10 @@ namespace NSPresentationEditor
...
@@ -41,11 +41,10 @@ namespace NSPresentationEditor
public:
public:
std
::
vector
<
CTheme
>
m_arThemes
;
std
::
vector
<
CTheme
>
m_arThemes
;
std
::
vector
<
CSlide
*>
m_arSlides
;
std
::
vector
<
CSlide
*>
m_arSlides
;
std
::
vector
<
CSlide
*>
m_arNotes
;
CMetricInfo
m_oInfo
;
CMetricInfo
m_oInfo
;
public:
CDocument
()
:
m_arThemes
(),
m_arSlides
()
CDocument
()
:
m_arThemes
(),
m_arSlides
()
{
{
}
}
...
@@ -56,8 +55,9 @@ namespace NSPresentationEditor
...
@@ -56,8 +55,9 @@ namespace NSPresentationEditor
CDocument
&
operator
=
(
const
CDocument
&
oSrc
)
CDocument
&
operator
=
(
const
CDocument
&
oSrc
)
{
{
m_arThemes
=
oSrc
.
m_arThemes
;
m_arThemes
=
oSrc
.
m_arThemes
;
m_arSlides
=
oSrc
.
m_arSlides
;
m_arSlides
=
oSrc
.
m_arSlides
;
m_arNotes
=
oSrc
.
m_arNotes
;
m_oInfo
=
oSrc
.
m_oInfo
;
m_oInfo
=
oSrc
.
m_oInfo
;
...
@@ -69,19 +69,18 @@ namespace NSPresentationEditor
...
@@ -69,19 +69,18 @@ namespace NSPresentationEditor
*
this
=
oSrc
;
*
this
=
oSrc
;
}
}
public:
inline
void
Clear
()
inline
void
Clear
()
{
{
ClearThemes
();
ClearThemes
();
try
try
{
{
ClearSlides
();
ClearSlides
();
ClearNotes
();
}
catch
(...)
}
catch
(...)
{
{
}
}
}
}
// работа с темами
inline
void
ClearThemes
()
inline
void
ClearThemes
()
{
{
m_arThemes
.
clear
();
m_arThemes
.
clear
();
...
@@ -97,26 +96,27 @@ namespace NSPresentationEditor
...
@@ -97,26 +96,27 @@ namespace NSPresentationEditor
m_arThemes
[
nIndex
]
=
oTheme
;
m_arThemes
[
nIndex
]
=
oTheme
;
}
}
// работа со слайдом
inline
void
ClearSlides
()
inline
void
ClearSlides
()
{
{
for
(
in
t
i
=
0
;
i
<
m_arSlides
.
size
();
i
++
)
for
(
size_
t
i
=
0
;
i
<
m_arSlides
.
size
();
i
++
)
{
{
RELEASEOBJECT
(
m_arSlides
[
i
]);
RELEASEOBJECT
(
m_arSlides
[
i
]);
}
}
m_arSlides
.
clear
();
m_arSlides
.
clear
();
}
}
inline
void
AddSlide
(
CSlide
*
oSlide
)
inline
void
ClearNotes
(
)
{
{
m_arSlides
.
push_back
(
oSlide
);
for
(
size_t
i
=
0
;
i
<
m_arNotes
.
size
();
i
++
)
{
RELEASEOBJECT
(
m_arNotes
[
i
]);
}
m_arNotes
.
clear
();
}
}
public:
#if defined (_DEBUG)
std
::
wstring
GetXmlSlideTransition
(
CSlide
&
oSlide
/*, CAudioOverlay& oAudioOverlay*/
)
// функция производит расчет по теме и слайдам
std
::
wstring
GetXmlSlideTransition
(
CSlide
&
oSlide
/*, CAudioOverlay& oAudioOverlay*/
)
{
{
std
::
wstring
Source
=
std
::
wstring
(
_T
(
""
)
);
std
::
wstring
Source
=
std
::
wstring
(
_T
(
""
)
);
int
EffectID
=
1
;
int
EffectID
=
1
;
int
lEffectDirection
=
oSlide
.
m_oSlideShow
.
m_oTransition
.
m_nEffectDirection
;
int
lEffectDirection
=
oSlide
.
m_oSlideShow
.
m_oTransition
.
m_nEffectDirection
;
...
@@ -314,7 +314,7 @@ namespace NSPresentationEditor
...
@@ -314,7 +314,7 @@ namespace NSPresentationEditor
break
;
break
;
}
}
Source
=
L"<VideoCompose Time=
\"
"
+
std
::
to_wstring
(
oSlide
.
m_oSlideShow
.
m_oTransition
.
m_dSpeed
)
+
L"
\"
effectid=
\"
"
+
std
::
to_wstring
(
EffectID
)
+
L"
\"
/>"
;
Source
=
L"<VideoCompose Time=
\"
"
+
std
::
to_wstring
(
oSlide
.
m_oSlideShow
.
m_oTransition
.
m_dSpeed
)
+
L"
\"
effectid=
\"
"
+
std
::
to_wstring
(
EffectID
)
+
L"
\"
/>"
;
/*
/*
...
@@ -338,7 +338,7 @@ namespace NSPresentationEditor
...
@@ -338,7 +338,7 @@ namespace NSPresentationEditor
return
Source
;
return
Source
;
}
}
#endif
double
CalculateTimes
(
CAudioOverlay
&
oAudioOverlay
)
double
CalculateTimes
(
CAudioOverlay
&
oAudioOverlay
)
{
{
CaclulateSlideTimes
();
CaclulateSlideTimes
();
...
@@ -486,7 +486,6 @@ namespace NSPresentationEditor
...
@@ -486,7 +486,6 @@ namespace NSPresentationEditor
}
}
}
}
public:
void
ResetAutoText
(
IElement
*
pElement
,
vector_string
const
(
&
placeholdersReplaceString
)[
3
])
void
ResetAutoText
(
IElement
*
pElement
,
vector_string
const
(
&
placeholdersReplaceString
)[
3
])
{
{
CShapeElement
*
pShape
=
dynamic_cast
<
CShapeElement
*>
(
pElement
);
CShapeElement
*
pShape
=
dynamic_cast
<
CShapeElement
*>
(
pElement
);
...
...
ASCOfficePPTXFile/Editor/Drawing/Slide.h
View file @
7d188b22
...
@@ -41,6 +41,9 @@ namespace NSPresentationEditor
...
@@ -41,6 +41,9 @@ namespace NSPresentationEditor
LONG
m_lThemeID
;
LONG
m_lThemeID
;
LONG
m_lLayoutID
;
LONG
m_lLayoutID
;
LONG
m_lSlideID
;
//for notes rels
LONG
m_lNotesID
;
//for slide rels
std
::
vector
<
IElement
*>
m_arElements
;
std
::
vector
<
IElement
*>
m_arElements
;
CSlideShowInfo
m_oSlideShow
;
CSlideShowInfo
m_oSlideShow
;
std
::
multimap
<
int
,
int
>
m_mapPlaceholders
;
std
::
multimap
<
int
,
int
>
m_mapPlaceholders
;
...
@@ -91,6 +94,8 @@ namespace NSPresentationEditor
...
@@ -91,6 +94,8 @@ namespace NSPresentationEditor
m_lThemeID
=
-
1
;
m_lThemeID
=
-
1
;
m_lLayoutID
=
-
1
;
m_lLayoutID
=
-
1
;
m_lSlideID
=
-
1
;
m_lNotesID
=
-
1
;
m_lWidth
=
270
;
m_lWidth
=
270
;
m_lHeight
=
190
;
m_lHeight
=
190
;
...
@@ -125,6 +130,8 @@ namespace NSPresentationEditor
...
@@ -125,6 +130,8 @@ namespace NSPresentationEditor
m_lThemeID
=
oSrc
.
m_lThemeID
;
m_lThemeID
=
oSrc
.
m_lThemeID
;
m_lLayoutID
=
oSrc
.
m_lLayoutID
;
m_lLayoutID
=
oSrc
.
m_lLayoutID
;
m_lNotesID
=
oSrc
.
m_lNotesID
;
m_lSlideID
=
oSrc
.
m_lSlideID
;
m_lWidth
=
oSrc
.
m_lWidth
;
m_lWidth
=
oSrc
.
m_lWidth
;
m_lHeight
=
oSrc
.
m_lHeight
;
m_lHeight
=
oSrc
.
m_lHeight
;
...
...
ASCOfficePPTXFile/Editor/Drawing/Theme.h
View file @
7d188b22
...
@@ -32,7 +32,6 @@
...
@@ -32,7 +32,6 @@
#pragma once
#pragma once
#include "Structures.h"
#include "Structures.h"
#include "Layout.h"
#include "Layout.h"
//#include "../PPTXWriter/CSS.h"
namespace
NSPresentationEditor
namespace
NSPresentationEditor
{
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment