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
a50fdbe6
Commit
a50fdbe6
authored
Oct 02, 2016
by
ElenaSubbotina
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
7d1a61e8
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
26 additions
and
13 deletions
+26
-13
ASCOfficeRtfFile/RtfFormatLib/source/Basic.h
ASCOfficeRtfFile/RtfFormatLib/source/Basic.h
+4
-2
ASCOfficeRtfFile/RtfFormatLib/source/RtfParagraph.h
ASCOfficeRtfFile/RtfFormatLib/source/RtfParagraph.h
+11
-9
ASCOfficeRtfFile/RtfFormatLib/source/Writer/OOXDocumentWriter.cpp
...eRtfFile/RtfFormatLib/source/Writer/OOXDocumentWriter.cpp
+11
-2
No files found.
ASCOfficeRtfFile/RtfFormatLib/source/Basic.h
View file @
a50fdbe6
...
...
@@ -260,10 +260,12 @@ public:
CString
RenderToOOX
(
RenderParameter
oRenderParameter
)
{
CString
sResult
;
for
(
int
i
=
(
int
)
m_aArray
.
size
()
-
1
;
i
>=
0
;
i
--
)
for
(
int
i
=
0
;
i
<
(
int
)
m_aArray
.
size
();
i
++
)
{
sResult
=
m_aArray
[
i
]
->
RenderToOOX
(
oRenderParameter
)
+
sResult
;
sResult
+=
m_aArray
[
i
]
->
RenderToOOX
(
oRenderParameter
)
;
}
return
sResult
;
}
bool
IsValid
()
...
...
ASCOfficeRtfFile/RtfFormatLib/source/RtfParagraph.h
View file @
a50fdbe6
...
...
@@ -163,17 +163,10 @@ public:
}
else
{
CString
ParagraphContent
;
// todooo проследить за вложенными объектами (inset fields) - св-ва секций
// нужно чтобы были в последнем параграфе!!! - так что и начнем с него - Australia Electronic Transactions Act 1999.rtf
RenderParameter
oNewParam
=
oRenderParameter
;
oNewParam
.
nType
=
RENDER_TO_OOX_PARAM_RUN
;
for
(
int
i
=
m_aArray
.
size
()
-
1
;
i
>=
0
;
i
--
)
{
ParagraphContent
=
m_aArray
[
i
]
->
RenderToOOX
(
oNewParam
)
+
ParagraphContent
;
}
bool
bCanConvertToNumbering
=
false
;
if
(
NULL
!=
m_oOldList
)
bCanConvertToNumbering
=
m_oOldList
->
CanConvertToNumbering
();
...
...
@@ -217,7 +210,16 @@ public:
}
}
sResult
+=
ParagraphContent
;
oNewParam
.
nType
=
RENDER_TO_OOX_PARAM_RUN
;
CString
ParagraphContent
;
for
(
int
i
=
0
;
i
<
m_aArray
.
size
();
i
++
)
{
ParagraphContent
+=
m_aArray
[
i
]
->
RenderToOOX
(
oNewParam
);
}
if
(
!
ParagraphContent
.
IsEmpty
())
sResult
+=
ParagraphContent
;
sResult
+=
_T
(
"</w:p>"
);
}
...
...
ASCOfficeRtfFile/RtfFormatLib/source/Writer/OOXDocumentWriter.cpp
View file @
a50fdbe6
...
...
@@ -237,8 +237,17 @@ bool OOXDocumentWriter::SaveByItem()
{
sXml
=
m_oDocument
[
0
].
props
->
operator
[](
0
)
->
RenderToOOX
(
oNewParam
).
GetBuffer
();
int
nFind
=
sXml
.
rfind
(
L"</w:pPr>"
);
if
(
-
1
!=
nFind
)
int
nFind
=
-
1
,
nFindPict
=
-
1
,
pos
=
sXml
.
size
();
do
{
nFindPict
=
sXml
.
rfind
(
L"<w:pict>"
,
pos
);
nFind
=
sXml
.
rfind
(
L"</w:pPr>"
,
pos
);
pos
=
nFindPict
-
1
;
}
while
(
nFindPict
>
0
&&
nFind
>
nFindPict
);
if
(
-
1
!=
nFind
)
{
sXml
.
insert
(
nFind
,
sectPr
);
}
...
...
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