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
0e5a581f
Commit
0e5a581f
authored
Apr 25, 2016
by
ElenaSubbotina
Committed by
Alexander Trofimov
May 21, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
x2t linux64 build 2.0.2.361
parent
8957e952
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
32 additions
and
25 deletions
+32
-25
ASCOfficeDocFile/DocDocxConverter/DocumentMapping.cpp
ASCOfficeDocFile/DocDocxConverter/DocumentMapping.cpp
+0
-0
X2tConverter/build/Qt/X2tConverter.pro
X2tConverter/build/Qt/X2tConverter.pro
+1
-1
X2tConverter/src/ASCConverters.cpp
X2tConverter/src/ASCConverters.cpp
+10
-10
X2tConverter/src/ASCConverters.h
X2tConverter/src/ASCConverters.h
+5
-5
X2tConverter/src/cextracttools.h
X2tConverter/src/cextracttools.h
+5
-0
X2tConverter/src/main.cpp
X2tConverter/src/main.cpp
+11
-9
No files found.
ASCOfficeDocFile/DocDocxConverter/DocumentMapping.cpp
100644 → 100755
View file @
0e5a581f
File mode changed from 100644 to 100755
X2tConverter/build/Qt/X2tConverter.pro
View file @
0e5a581f
...
...
@@ -7,7 +7,7 @@
QT
-=
core
QT
-=
gui
VERSION
=
2.0
.
2.36
0
VERSION
=
2.0
.
2.36
1
DEFINES
+=
INTVER
=
$$
VERSION
mac
{
...
...
X2tConverter/src/ASCConverters.cpp
View file @
0e5a581f
...
...
@@ -1584,7 +1584,7 @@ namespace NExtractTools
nRes
=
AVS_FILEUTILS_ERROR_CONVERT
;
return
nRes
;
}
int
fromSpreadsheet
(
const
std
::
wstring
&
sFrom
,
int
nFormatFrom
,
const
std
::
wstring
&
sTo
,
int
nFormatTo
,
const
std
::
wstring
&
sTemp
,
const
std
::
wstring
&
sFontPath
,
const
std
::
wstring
&
sXmlOptions
,
const
std
::
wstring
&
sThemeDir
,
bool
bFromChanges
,
bool
bPaid
,
const
InputParams
&
params
)
int
fromSpreadsheet
(
const
std
::
wstring
&
sFrom
,
int
nFormatFrom
,
const
std
::
wstring
&
sTo
,
int
nFormatTo
,
const
std
::
wstring
&
s
Password
,
const
std
::
wstring
&
s
Temp
,
const
std
::
wstring
&
sFontPath
,
const
std
::
wstring
&
sXmlOptions
,
const
std
::
wstring
&
sThemeDir
,
bool
bFromChanges
,
bool
bPaid
,
const
InputParams
&
params
)
{
int
nRes
=
0
;
if
(
AVS_OFFICESTUDIO_FILE_SPREADSHEET_CSV
==
nFormatFrom
)
...
...
@@ -1616,7 +1616,7 @@ namespace NExtractTools
}
else
if
(
AVS_OFFICESTUDIO_FILE_SPREADSHEET_XLS
==
nFormatFrom
)
{
nRes
=
xls2xlsx_dir
(
sFrom
,
sXlsxDir
,
sTemp
,
sFontPath
);
nRes
=
xls2xlsx_dir
(
sFrom
,
sXlsxDir
,
s
Password
,
s
Temp
,
sFontPath
);
}
else
if
(
AVS_OFFICESTUDIO_FILE_SPREADSHEET_ODS
==
nFormatFrom
)
{
...
...
@@ -1842,13 +1842,13 @@ namespace NExtractTools
}
// xls -> xlsx
int
xls2xlsx
(
const
std
::
wstring
&
sFrom
,
const
std
::
wstring
&
sTo
,
const
std
::
wstring
&
sTemp
,
const
std
::
wstring
&
sFontPath
)
int
xls2xlsx
(
const
std
::
wstring
&
sFrom
,
const
std
::
wstring
&
sTo
,
const
std
::
wstring
&
s
Password
,
const
std
::
wstring
&
s
Temp
,
const
std
::
wstring
&
sFontPath
)
{
std
::
wstring
sResultDocxDir
=
sTemp
+
FILE_SEPARATOR_STR
+
_T
(
"xlsx_unpacked"
);
FileSystem
::
Directory
::
CreateDirectory
(
sResultDocxDir
);
int
nRes
=
xls2xlsx_dir
(
sFrom
,
sResultDocxDir
,
sFontPath
,
sTemp
);
int
nRes
=
xls2xlsx_dir
(
sFrom
,
sResultDocxDir
,
s
Password
,
s
FontPath
,
sTemp
);
if
(
SUCCEEDED_X2T
(
nRes
))
{
COfficeUtils
oCOfficeUtils
(
NULL
);
...
...
@@ -1857,13 +1857,13 @@ namespace NExtractTools
}
return
AVS_FILEUTILS_ERROR_CONVERT
;
}
int
xls2xlsx_dir
(
const
std
::
wstring
&
sFrom
,
const
std
::
wstring
&
sTo
,
const
std
::
wstring
&
sTemp
,
const
std
::
wstring
&
sFontPath
)
int
xls2xlsx_dir
(
const
std
::
wstring
&
sFrom
,
const
std
::
wstring
&
sTo
,
const
std
::
wstring
&
s
Password
,
const
std
::
wstring
&
s
Temp
,
const
std
::
wstring
&
sFontPath
)
{
return
S_OK
==
ConvertXls2Xlsx
(
sFrom
,
sTo
,
sFontPath
,
NULL
)
?
0
:
AVS_FILEUTILS_ERROR_CONVERT
;
return
S_OK
==
ConvertXls2Xlsx
(
sFrom
,
sTo
,
s
Password
,
s
FontPath
,
NULL
)
?
0
:
AVS_FILEUTILS_ERROR_CONVERT
;
}
// xls -> xlst
int
xls2xlst
(
const
std
::
wstring
&
sFrom
,
const
std
::
wstring
&
sTo
,
const
std
::
wstring
&
sTemp
,
const
std
::
wstring
&
sFontPath
,
const
std
::
wstring
&
sXmlOptions
)
int
xls2xlst
(
const
std
::
wstring
&
sFrom
,
const
std
::
wstring
&
sTo
,
const
std
::
wstring
&
s
Password
,
const
std
::
wstring
&
s
Temp
,
const
std
::
wstring
&
sFontPath
,
const
std
::
wstring
&
sXmlOptions
)
{
// Extract xlsx to temp directory
std
::
wstring
sResultDoctDir
=
sTemp
+
FILE_SEPARATOR_STR
+
_T
(
"xlst_unpacked"
);
...
...
@@ -1871,7 +1871,7 @@ namespace NExtractTools
FileSystem
::
Directory
::
CreateDirectory
(
sResultDoctDir
);
int
nRes
=
xls2xlst_bin
(
sFrom
,
sResultDoctFileEditor
,
sTemp
,
sFontPath
,
sXmlOptions
);
int
nRes
=
xls2xlst_bin
(
sFrom
,
sResultDoctFileEditor
,
s
Password
,
s
Temp
,
sFontPath
,
sXmlOptions
);
if
(
SUCCEEDED_X2T
(
nRes
))
{
...
...
@@ -1883,13 +1883,13 @@ namespace NExtractTools
}
// xls -> xlst_bin
int
xls2xlst_bin
(
const
std
::
wstring
&
sFrom
,
const
std
::
wstring
&
sTo
,
const
std
::
wstring
&
sTemp
,
const
std
::
wstring
&
sFontPath
,
const
std
::
wstring
&
sXmlOptions
)
int
xls2xlst_bin
(
const
std
::
wstring
&
sFrom
,
const
std
::
wstring
&
sTo
,
const
std
::
wstring
&
s
Password
,
const
std
::
wstring
&
s
Temp
,
const
std
::
wstring
&
sFontPath
,
const
std
::
wstring
&
sXmlOptions
)
{
std
::
wstring
sResultXlsxDir
=
sTemp
+
FILE_SEPARATOR_STR
+
_T
(
"xlsx_unpacked"
);
FileSystem
::
Directory
::
CreateDirectory
(
sResultXlsxDir
);
if
(
ConvertXls2Xlsx
(
sFrom
,
sResultXlsxDir
,
sFontPath
,
NULL
)
==
S_OK
)
if
(
ConvertXls2Xlsx
(
sFrom
,
sResultXlsxDir
,
s
Password
,
s
FontPath
,
NULL
)
==
S_OK
)
{
BinXlsxRW
::
CXlsxSerializer
m_oCXlsxSerializer
;
...
...
X2tConverter/src/ASCConverters.h
View file @
0e5a581f
...
...
@@ -63,10 +63,10 @@ namespace NExtractTools
int
doc2doct_bin
(
const
std
::
wstring
&
sFrom
,
const
std
::
wstring
&
sTo
,
const
std
::
wstring
&
sTemp
,
const
std
::
wstring
&
sFontPath
);
int
docx_dir2doc
(
const
std
::
wstring
&
sDocxDir
,
const
std
::
wstring
&
sTo
,
const
std
::
wstring
&
sTemp
,
const
std
::
wstring
&
sFontPath
);
int
xls2xlsx
(
const
std
::
wstring
&
sFrom
,
const
std
::
wstring
&
sTo
,
const
std
::
wstring
&
sTemp
,
const
std
::
wstring
&
sFontPath
);
int
xls2xlsx_dir
(
const
std
::
wstring
&
sFrom
,
const
std
::
wstring
&
sTo
,
const
std
::
wstring
&
sTemp
,
const
std
::
wstring
&
sFontPath
);
int
xls2xlst
(
const
std
::
wstring
&
sFrom
,
const
std
::
wstring
&
sTo
,
const
std
::
wstring
&
sTemp
,
const
std
::
wstring
&
sFontPath
,
const
std
::
wstring
&
sXmlOptions
);
int
xls2xlst_bin
(
const
std
::
wstring
&
sFrom
,
const
std
::
wstring
&
sTo
,
const
std
::
wstring
&
sTemp
,
const
std
::
wstring
&
sFontPath
,
const
std
::
wstring
&
sXmlOptions
);
int
xls2xlsx
(
const
std
::
wstring
&
sFrom
,
const
std
::
wstring
&
sTo
,
const
std
::
wstring
&
s
Password
,
const
std
::
wstring
&
s
Temp
,
const
std
::
wstring
&
sFontPath
);
int
xls2xlsx_dir
(
const
std
::
wstring
&
sFrom
,
const
std
::
wstring
&
sTo
,
const
std
::
wstring
&
s
Password
,
const
std
::
wstring
&
s
Temp
,
const
std
::
wstring
&
sFontPath
);
int
xls2xlst
(
const
std
::
wstring
&
sFrom
,
const
std
::
wstring
&
sTo
,
const
std
::
wstring
&
s
Password
,
const
std
::
wstring
&
s
Temp
,
const
std
::
wstring
&
sFontPath
,
const
std
::
wstring
&
sXmlOptions
);
int
xls2xlst_bin
(
const
std
::
wstring
&
sFrom
,
const
std
::
wstring
&
sTo
,
const
std
::
wstring
&
s
Password
,
const
std
::
wstring
&
s
Temp
,
const
std
::
wstring
&
sFontPath
,
const
std
::
wstring
&
sXmlOptions
);
int
txt2docx
(
const
std
::
wstring
&
sFrom
,
const
std
::
wstring
&
sTo
,
const
std
::
wstring
&
sXmlOptions
,
const
std
::
wstring
&
sTemp
);
int
txt2docx_dir
(
const
std
::
wstring
&
sFrom
,
const
std
::
wstring
&
sTo
,
const
std
::
wstring
&
sXmlOptions
,
const
std
::
wstring
&
sTemp
);
...
...
@@ -95,7 +95,7 @@ namespace NExtractTools
int
fromXlsxDir
(
const
std
::
wstring
&
sFrom
,
const
std
::
wstring
&
sTo
,
int
nFormatTo
,
const
std
::
wstring
&
sTemp
,
const
std
::
wstring
&
sFontPath
,
const
std
::
wstring
&
sXmlOptions
,
const
std
::
wstring
&
sThemeDir
,
bool
bFromChanges
,
bool
bPaid
,
const
InputParams
&
params
);
int
fromXlstBin
(
const
std
::
wstring
&
sFrom
,
const
std
::
wstring
&
sTo
,
int
nFormatTo
,
const
std
::
wstring
&
sTemp
,
const
std
::
wstring
&
sFontPath
,
const
std
::
wstring
&
sXmlOptions
,
const
std
::
wstring
&
sThemeDir
,
bool
bFromChanges
,
bool
bPaid
,
const
InputParams
&
params
);
int
fromSpreadsheet
(
const
std
::
wstring
&
sFrom
,
int
nFormatFrom
,
const
std
::
wstring
&
sTo
,
int
nFormatTo
,
const
std
::
wstring
&
sTemp
,
const
std
::
wstring
&
sFontPath
,
const
std
::
wstring
&
sXmlOptions
,
const
std
::
wstring
&
sThemeDir
,
bool
bFromChanges
,
bool
bPaid
,
const
InputParams
&
params
);
int
fromSpreadsheet
(
const
std
::
wstring
&
sFrom
,
int
nFormatFrom
,
const
std
::
wstring
&
sTo
,
int
nFormatTo
,
const
std
::
wstring
&
s
Password
,
const
std
::
wstring
&
s
Temp
,
const
std
::
wstring
&
sFontPath
,
const
std
::
wstring
&
sXmlOptions
,
const
std
::
wstring
&
sThemeDir
,
bool
bFromChanges
,
bool
bPaid
,
const
InputParams
&
params
);
int
fromPptxDir
(
const
std
::
wstring
&
sFrom
,
const
std
::
wstring
&
sTo
,
int
nFormatTo
,
const
std
::
wstring
&
sTemp
,
const
std
::
wstring
&
sFontPath
,
const
std
::
wstring
&
sXmlOptions
,
const
std
::
wstring
&
sThemeDir
,
bool
bFromChanges
,
bool
bPaid
,
const
InputParams
&
params
);
int
fromPpttBin
(
const
std
::
wstring
&
sFrom
,
const
std
::
wstring
&
sTo
,
int
nFormatTo
,
const
std
::
wstring
&
sTemp
,
const
std
::
wstring
&
sFontPath
,
const
std
::
wstring
&
sXmlOptions
,
const
std
::
wstring
&
sThemeDir
,
bool
bFromChanges
,
bool
bPaid
,
const
InputParams
&
params
);
...
...
X2tConverter/src/cextracttools.h
View file @
0e5a581f
...
...
@@ -337,6 +337,11 @@ namespace NExtractTools
}
return
true
;
}
std
::
wstring
getPassword
()
{
return
L""
;
}
std
::
wstring
getXmlOptions
()
{
CString
sRes
;
...
...
X2tConverter/src/main.cpp
View file @
0e5a581f
...
...
@@ -72,10 +72,11 @@ int main(int argc, char *argv[])
return
getReturnErrorCode
(
AVS_FILEUTILS_ERROR_CONVERT_PARAMS
);
}
std
::
wstring
sArg1
,
sExePath
;
InputParams
oInputParams
;
TConversionDirection
conversion
=
TCD_AUTO
;
std
::
wstring
sXmlOptions
;
std
::
wstring
sArg1
,
sExePath
;
InputParams
oInputParams
;
TConversionDirection
conversion
=
TCD_AUTO
;
std
::
wstring
sXmlOptions
;
std
::
wstring
sPassword
;
#if !defined(_WIN32) && !defined (_WIN64)
sExePath
=
utf8_to_unicode
(
argv
[
0
]);
...
...
@@ -89,8 +90,9 @@ int main(int argc, char *argv[])
if
(
sXmlExt
==
sArg1
.
substr
(
sArg1
.
length
()
-
sXmlExt
.
length
(),
sXmlExt
.
length
()))
{
oInputParams
.
FromXmlFile
(
sArg1
);
conversion
=
oInputParams
.
getConversionDirection
();
conversion
=
oInputParams
.
getConversionDirection
();
sXmlOptions
=
oInputParams
.
getXmlOptions
();
sPassword
=
oInputParams
.
getPassword
();
}
else
{
...
...
@@ -339,15 +341,15 @@ int main(int argc, char *argv[])
}
else
if
(
TCD_XLS2XLSX
==
conversion
)
{
result
=
xls2xlsx
(
sFileFrom
,
sFileTo
,
sTempDir
,
sFontPath
);
result
=
xls2xlsx
(
sFileFrom
,
sFileTo
,
s
Password
,
s
TempDir
,
sFontPath
);
}
else
if
(
TCD_XLS2XLST
==
conversion
)
{
result
=
xls2xlst
(
sFileFrom
,
sFileTo
,
sTempDir
,
sFontPath
,
sXmlOptions
);
result
=
xls2xlst
(
sFileFrom
,
sFileTo
,
s
Password
,
s
TempDir
,
sFontPath
,
sXmlOptions
);
}
else
if
(
TCD_XLS2XLST_BIN
==
conversion
)
{
result
=
xls2xlst_bin
(
sFileFrom
,
sFileTo
,
sTempDir
,
sFontPath
,
sXmlOptions
);
result
=
xls2xlst_bin
(
sFileFrom
,
sFileTo
,
s
Password
,
s
TempDir
,
sFontPath
,
sXmlOptions
);
}
else
if
(
TCD_ODF2OOX
==
conversion
)
{
...
...
@@ -379,7 +381,7 @@ int main(int argc, char *argv[])
}
else
if
(
TCD_SPREADSHEET2
==
conversion
)
{
result
=
fromSpreadsheet
(
sFileFrom
,
nFormatFrom
,
sFileTo
,
nFormatTo
,
sTempDir
,
sFontPath
,
sXmlOptions
,
sThemeDir
,
bFromChanges
,
bPaid
,
oInputParams
);
result
=
fromSpreadsheet
(
sFileFrom
,
nFormatFrom
,
sFileTo
,
nFormatTo
,
s
Password
,
s
TempDir
,
sFontPath
,
sXmlOptions
,
sThemeDir
,
bFromChanges
,
bPaid
,
oInputParams
);
}
else
if
(
TCD_PRESENTATION2
==
conversion
)
{
...
...
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