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
7c9be7e2
Commit
7c9be7e2
authored
Jun 27, 2017
by
ElenaSubbotina
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
XlsFormat ...
parent
bad29929
Changes
11
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
99 additions
and
16 deletions
+99
-16
ASCOfficeXlsFile2/source/XlsFormat/Logic/Biff_records/SXAddl.cpp
...ceXlsFile2/source/XlsFormat/Logic/Biff_records/SXAddl.cpp
+14
-0
ASCOfficeXlsFile2/source/XlsFormat/Logic/Biff_records/SXAddl.h
...ficeXlsFile2/source/XlsFormat/Logic/Biff_records/SXAddl.h
+9
-1
ASCOfficeXlsFile2/source/XlsFormat/Logic/Biff_records/SXViewLink.cpp
...sFile2/source/XlsFormat/Logic/Biff_records/SXViewLink.cpp
+1
-1
ASCOfficeXlsFile2/source/XlsFormat/Logic/Biff_structures/CellXF.h
...eXlsFile2/source/XlsFormat/Logic/Biff_structures/CellXF.h
+1
-2
ASCOfficeXlsFile2/source/XlsFormat/Logic/Biff_structures/ExtNameParsedFormula.h
...ce/XlsFormat/Logic/Biff_structures/ExtNameParsedFormula.h
+0
-4
ASCOfficeXlsFile2/source/XlsFormat/Logic/Biff_unions/PIVOTFRT.cpp
...eXlsFile2/source/XlsFormat/Logic/Biff_unions/PIVOTFRT.cpp
+4
-0
ASCOfficeXlsFile2/source/XlsFormat/Logic/Biff_unions/PIVOTFRT.h
...iceXlsFile2/source/XlsFormat/Logic/Biff_unions/PIVOTFRT.h
+4
-3
ASCOfficeXlsFile2/source/XlsFormat/Logic/WorksheetSubstream.cpp
...iceXlsFile2/source/XlsFormat/Logic/WorksheetSubstream.cpp
+35
-5
ASCOfficeXlsFile2/source/XlsFormat/Logic/WorksheetSubstream.h
...fficeXlsFile2/source/XlsFormat/Logic/WorksheetSubstream.h
+4
-0
ASCOfficeXlsFile2/source/XlsXlsxConverter/XlsConverter.cpp
ASCOfficeXlsFile2/source/XlsXlsxConverter/XlsConverter.cpp
+23
-0
ASCOfficeXlsFile2/source/XlsXlsxConverter/XlsConverter.h
ASCOfficeXlsFile2/source/XlsXlsxConverter/XlsConverter.h
+4
-0
No files found.
ASCOfficeXlsFile2/source/XlsFormat/Logic/Biff_records/SXAddl.cpp
View file @
7c9be7e2
...
...
@@ -131,6 +131,20 @@ void SXAddl_SXCCache_SXDVer10Info::readFields(CFRecord& record)
record
>>
reserved2
;
}
//----------------------------------------------------------------------------
BaseObjectPtr
SXAddl_SXCCache_SXDVerUpdInv
::
clone
()
{
return
BaseObjectPtr
(
new
SXAddl_SXCCache_SXDVerUpdInv
(
*
this
));
}
void
SXAddl_SXCCache_SXDVerUpdInv
::
readFields
(
CFRecord
&
record
)
{
m_SXAddlHdr
.
load
(
record
);
record
>>
dwVersionInvalidates
;
record
.
skipNunBytes
(
5
);
}
//----------------------------------------------------------------------------
BaseObjectPtr
SXAddl_SXCCache_SXDInfo12
::
clone
()
{
return
BaseObjectPtr
(
new
SXAddl_SXCCache_SXDInfo12
(
*
this
));
...
...
ASCOfficeXlsFile2/source/XlsFormat/Logic/Biff_records/SXAddl.h
View file @
7c9be7e2
...
...
@@ -147,7 +147,15 @@ public:
unsigned
char
dwVer
;
};
class
SXAddl_SXCCache_SXDVerUpdInv
:
public
SXAddl
{};
class
SXAddl_SXCCache_SXDVerUpdInv
:
public
SXAddl
{
public:
virtual
void
readFields
(
CFRecord
&
record
);
virtual
BaseObjectPtr
clone
();
unsigned
char
dwVersionInvalidates
;
};
class
SXAddl_SXCCacheField_SXDCaption
:
public
SXAddl
{};
class
SXAddl_SXCCacheField_SXDEnd
:
public
SXAddl
{};
class
SXAddl_SXCCacheField_SXDId
:
public
SXAddl
{};
...
...
ASCOfficeXlsFile2/source/XlsFormat/Logic/Biff_records/SXViewLink.cpp
View file @
7c9be7e2
...
...
@@ -52,7 +52,7 @@ BaseObjectPtr SXViewLink::clone()
void
SXViewLink
::
readFields
(
CFRecord
&
record
)
{
unsigned
short
unused
,
reserved
;
unsigned
short
unused
,
reserved
;
record
>>
rt
>>
unused
>>
reserved
>>
cch
;
...
...
ASCOfficeXlsFile2/source/XlsFormat/Logic/Biff_structures/CellXF.h
View file @
7c9be7e2
...
...
@@ -51,8 +51,7 @@ public:
virtual
void
load
(
CFRecord
&
record
);
static
const
ElementType
type
=
typeCellXF
;
static
const
ElementType
type
=
typeCellXF
;
GlobalWorkbookInfoPtr
m_GlobalWorkbookInfo
;
...
...
ASCOfficeXlsFile2/source/XlsFormat/Logic/Biff_structures/ExtNameParsedFormula.h
View file @
7c9be7e2
...
...
@@ -46,11 +46,7 @@ public:
ExtNameParsedFormula
();
BiffStructurePtr
clone
();
void
load
(
CFRecord
&
record
);
private:
// stub to make the class non-abstract
private:
PtgPtr
val
;
};
...
...
ASCOfficeXlsFile2/source/XlsFormat/Logic/Biff_unions/PIVOTFRT.cpp
View file @
7c9be7e2
...
...
@@ -61,9 +61,13 @@ const bool PIVOTFRT::loadContent(BinProcessor& proc)
{
return
false
;
}
m_PIVOTFRT9
=
elements_
.
back
();
elements_
.
pop_back
();
if
(
proc
.
optional
<
PIVOTADDL
>
())
{
m_PIVOTADDL
=
elements_
.
back
();
elements_
.
pop_back
();
}
return
true
;
}
...
...
ASCOfficeXlsFile2/source/XlsFormat/Logic/Biff_unions/PIVOTFRT.h
View file @
7c9be7e2
...
...
@@ -36,8 +36,6 @@
namespace
XLS
{
// Logical representation of PIVOTFRT union of records
class
PIVOTFRT
:
public
CompositeObject
{
BASE_OBJECT_DEFINE_CLASS_NAME
(
PIVOTFRT
)
...
...
@@ -49,7 +47,10 @@ public:
virtual
const
bool
loadContent
(
BinProcessor
&
proc
);
static
const
ElementType
type
=
typePIVOTFRT
;
static
const
ElementType
type
=
typePIVOTFRT
;
BaseObjectPtr
m_PIVOTFRT9
;
BaseObjectPtr
m_PIVOTADDL
;
};
}
// namespace XLS
...
...
ASCOfficeXlsFile2/source/XlsFormat/Logic/WorksheetSubstream.cpp
View file @
7c9be7e2
...
...
@@ -294,7 +294,14 @@ const bool WorksheetSubstream::loadContent(BinProcessor& proc)
count
--
;
}
}
break
;
case
rt_DCon
:
proc
.
optional
<
DCON
>
();
break
;
case
rt_DCon
:
{
if
(
proc
.
optional
<
DCON
>
())
{
m_DCON
=
elements_
.
back
();
elements_
.
pop_back
();
}
}
break
;
case
rt_UserSViewBegin
:
{
count
=
proc
.
repeated
<
CUSTOMVIEW
>
(
0
,
0
);
...
...
@@ -341,8 +348,24 @@ const bool WorksheetSubstream::loadContent(BinProcessor& proc)
}
}
break
;
case
rt_LRng
:
proc
.
optional
<
LRng
>
();
break
;
case
rt_Qsi
:
proc
.
repeated
<
QUERYTABLE
>
(
0
,
0
);
break
;
case
rt_LRng
:
{
if
(
proc
.
optional
<
LRng
>
())
{
m_LRng
=
elements_
.
back
();
elements_
.
pop_back
();
}
}
break
;
case
rt_Qsi
:
{
count
=
proc
.
repeated
<
QUERYTABLE
>
(
0
,
0
);
while
(
count
>
0
)
{
m_arQUERYTABLE
.
insert
(
m_arQUERYTABLE
.
begin
(),
elements_
.
back
());
elements_
.
pop_back
();
count
--
;
}
}
break
;
case
rt_PhoneticInfo
:
proc
.
optional
<
PHONETICINFO
>
();
break
;
case
rt_CondFmt
:
case
rt_CondFmt12
:
...
...
@@ -413,8 +436,15 @@ const bool WorksheetSubstream::loadContent(BinProcessor& proc)
}
}
break
;
case
rt_HeaderFooter
:
proc
.
repeated
<
RECORD12
>
(
0
,
0
);
break
;
{
count
=
proc
.
repeated
<
RECORD12
>
(
0
,
0
);
while
(
count
>
0
)
{
m_arRECORD12
.
insert
(
m_arRECORD12
.
begin
(),
elements_
.
back
());
elements_
.
pop_back
();
count
--
;
}
}
break
;
default:
//unknown .... skip
{
proc
.
SkipRecord
();
...
...
ASCOfficeXlsFile2/source/XlsFormat/Logic/WorksheetSubstream.h
View file @
7c9be7e2
...
...
@@ -71,11 +71,14 @@ public:
BaseObjectPtr
m_SheetExt
;
BaseObjectPtr
m_DxGCol
;
BaseObjectPtr
m_DVAL
;
BaseObjectPtr
m_DCON
;
BaseObjectPtr
m_LRng
;
std
::
vector
<
BaseObjectPtr
>
m_arMergeCells
;
std
::
vector
<
BaseObjectPtr
>
m_arWINDOW
;
std
::
vector
<
BaseObjectPtr
>
m_arCUSTOMVIEW
;
std
::
vector
<
BaseObjectPtr
>
m_arPIVOTVIEW
;
std
::
vector
<
BaseObjectPtr
>
m_arQUERYTABLE
;
std
::
vector
<
BaseObjectPtr
>
m_arFEAT
;
std
::
vector
<
BaseObjectPtr
>
m_arFEAT11
;
std
::
vector
<
BaseObjectPtr
>
m_arNote
;
...
...
@@ -83,6 +86,7 @@ public:
std
::
vector
<
BaseObjectPtr
>
m_arSORT
;
std
::
vector
<
BaseObjectPtr
>
m_arLabel
;
std
::
vector
<
BaseObjectPtr
>
m_arHFPicture
;
std
::
vector
<
BaseObjectPtr
>
m_arRECORD12
;
std
::
vector
<
BiffStructurePtr
>
m_arHFPictureDrawing
;
...
...
ASCOfficeXlsFile2/source/XlsXlsxConverter/XlsConverter.cpp
View file @
7c9be7e2
...
...
@@ -57,6 +57,7 @@
#include "../XlsFormat/Logic/Biff_unions/TEXTOBJECT.h"
#include "../XlsFormat/Logic/Biff_unions/CHART.h"
#include "../XlsFormat/Logic/Biff_unions/BACKGROUND.h"
#include "../XlsFormat/Logic/Biff_unions/PIVOTVIEW.h"
#include <Logic/Biff_records/BkHim.h>
#include <Logic/Biff_records/HLink.h>
...
...
@@ -433,6 +434,11 @@ void XlsConverter::convert(XLS::WorksheetSubstream* sheet)
sheet
->
m_DVAL
->
serialize
(
xlsx_context
->
current_sheet
().
dataValidations
());
}
for
(
size_t
i
=
0
;
i
<
sheet
->
m_arPIVOTVIEW
.
size
();
i
++
)
{
convert
((
XLS
::
PIVOTVIEW
*
)
sheet
->
m_arPIVOTVIEW
[
i
].
get
());
}
convert
((
XLS
::
OBJECTS
*
)
sheet
->
m_OBJECTS
.
get
(),
sheet
);
if
(
!
sheet
->
m_arNote
.
empty
()
&&
xls_global_info
->
Version
<
0x0600
)
...
...
@@ -515,6 +521,11 @@ void XlsConverter::convert(XLS::GlobalsSubstream* global)
{
global
->
m_arUserBView
[
i
]
->
serialize
(
xlsx_context
->
custom_views
());
}
for
(
size_t
i
=
0
;
i
<
global
->
m_arPIVOTCACHEDEFINITION
.
size
();
i
++
)
{
convert
((
XLS
::
PIVOTCACHEDEFINITION
*
)
global
->
m_arPIVOTCACHEDEFINITION
[
i
].
get
());
}
}
typedef
boost
::
unordered_map
<
XLS
::
FillInfo
,
int
>
mapFillInfo
;
...
...
@@ -1893,3 +1904,15 @@ void XlsConverter::convert(XLS::ChartSheetSubstream * chart)
chart
->
serialize
(
xlsx_context
->
current_chart
().
chartData
());
//convert(chart->m_OBJECTSCHART.get());непонятные какие то текстбоксы - пустые и бз привязок
}
void
XlsConverter
::
convert
(
XLS
::
PIVOTVIEW
*
pivot_view
)
{
if
(
pivot_view
==
NULL
)
return
;
}
void
XlsConverter
::
convert
(
XLS
::
PIVOTCACHEDEFINITION
*
pivot_cached
)
{
if
(
pivot_cached
==
NULL
)
return
;
}
\ No newline at end of file
ASCOfficeXlsFile2/source/XlsXlsxConverter/XlsConverter.h
View file @
7c9be7e2
...
...
@@ -70,6 +70,8 @@ namespace XLS
class
OBJECTS
;
class
MSODRAWINGGROUP
;
class
IMDATA
;
class
PIVOTVIEW
;
class
PIVOTCACHEDEFINITION
;
class
Note
;
class
TxO
;
...
...
@@ -117,6 +119,8 @@ public:
void
convert
(
XLS
::
TxO
*
text_obj
);
void
convert
(
XLS
::
Note
*
note
);
void
convert
(
XLS
::
IMDATA
*
imadata
);
void
convert
(
XLS
::
PIVOTVIEW
*
pivot_view
);
void
convert
(
XLS
::
PIVOTCACHEDEFINITION
*
pivot_cached
);
void
convert
(
ODRAW
::
OfficeArtRecord
*
art
);
void
convert
(
ODRAW
::
OfficeArtBStoreContainer
*
art_bstore
,
int
start_id
=
0
);
...
...
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