mirror of
https://github.com/ONLYOFFICE/core.git
synced 2026-02-19 06:16:02 +08:00
Compare commits
105 Commits
core-linux
...
core-linux
| Author | SHA1 | Date | |
|---|---|---|---|
| 2e40b96ed9 | |||
| 50ee7d7cc1 | |||
| f9b54bffd4 | |||
| a52a8e982e | |||
| 128529ba80 | |||
| a571c88798 | |||
| 34bb84a792 | |||
| 92d0d0d7ea | |||
| 449e3fc131 | |||
| ce9fdb33b5 | |||
| 2591f0a202 | |||
| 6bc04fc06f | |||
| 047850dbd6 | |||
| 465b903ec5 | |||
| 6afa54ebef | |||
| 27a0e77ef1 | |||
| c7b45910f8 | |||
| ab1abb96fe | |||
| 566d9e68e4 | |||
| 243b8eccdd | |||
| 76b682063e | |||
| effdab1ff4 | |||
| 658040f77b | |||
| 48aa99af83 | |||
| a1b738fc42 | |||
| 00e9ce56df | |||
| 2a4ce1f93f | |||
| 261e48227d | |||
| 29e3f90ebf | |||
| d4a70d306f | |||
| b9b843f25d | |||
| d7e2bedc6b | |||
| 234459f37c | |||
| 58cd45f4ee | |||
| 33f7ee49df | |||
| e7ed48af49 | |||
| cbd79c902e | |||
| 40c24b1577 | |||
| 95a49140cb | |||
| aad12cf471 | |||
| f0ffb7f14c | |||
| da329135e1 | |||
| 60ca9a2347 | |||
| 5fdace28d2 | |||
| 85549c5b20 | |||
| 4c8bc2227a | |||
| 23ca735f23 | |||
| 4acefb020f | |||
| 684d697cae | |||
| 1aa604c584 | |||
| 51569b626f | |||
| 89d7eb559d | |||
| f6b3a78fe8 | |||
| 1900e2f0a0 | |||
| d0e1785086 | |||
| 221d1ecbb5 | |||
| 2fc3b140d0 | |||
| bdb2ca8241 | |||
| 4055201322 | |||
| 5b305ec75d | |||
| 433686c01f | |||
| ccfc921883 | |||
| 6b0d6fe890 | |||
| 5ae20c58ed | |||
| 7b45fb8931 | |||
| d0ffc6f555 | |||
| 54e5bb8419 | |||
| f7bb1766c0 | |||
| f0bb87ba14 | |||
| a484dc1fd7 | |||
| 19cc78060c | |||
| 2682eda9c6 | |||
| 8d750adb7b | |||
| c517b3ac19 | |||
| f57b28cd24 | |||
| 4cb984684d | |||
| 903d903aad | |||
| fe53ae9b11 | |||
| 8ca218d600 | |||
| a0b32c1523 | |||
| a2cc70233e | |||
| 42c35a9803 | |||
| 8100a2860f | |||
| c4abf6d149 | |||
| c749cbf081 | |||
| c7accf4370 | |||
| 322bc72ad1 | |||
| 33bf2df39d | |||
| aa344408b0 | |||
| 2a5d29c874 | |||
| 3e9e70655c | |||
| ed9a6e7e5c | |||
| 284b04574a | |||
| 67eb5ac139 | |||
| 563014f8d7 | |||
| 290d845d7a | |||
| 935e9396af | |||
| 4de2649dcd | |||
| 46bc4e5e96 | |||
| 56475b7e8a | |||
| 69a69d9fc2 | |||
| 7d2f96d284 | |||
| e753476826 | |||
| 983873d010 | |||
| af037642dd |
@ -58,6 +58,9 @@
|
||||
|
||||
#include <boost/format.hpp>
|
||||
|
||||
#define GETBITS(from, numL, numH) ((from & (((1 << (numH - numL + 1)) - 1) << numL)) >> numL)
|
||||
#define GETBIT(from, num) ((from & (1 << num)) != 0)
|
||||
|
||||
namespace DocFileFormat
|
||||
{
|
||||
typedef unsigned char Bool8;
|
||||
@ -638,14 +641,12 @@ namespace DocFileFormat
|
||||
else
|
||||
{
|
||||
std::string sCodePage;
|
||||
for (int i = 0; i < UNICODE_CONVERTER_ENCODINGS_COUNT; ++i)
|
||||
std::map<int, std::string>::const_iterator pFind = NSUnicodeConverter::mapEncodingsICU.find(code_page);
|
||||
if (pFind != NSUnicodeConverter::mapEncodingsICU.end())
|
||||
{
|
||||
if (code_page == NSUnicodeConverter::Encodings[i].WindowsCodePage)
|
||||
{
|
||||
sCodePage = NSUnicodeConverter::Encodings[i].Name;
|
||||
break;
|
||||
}
|
||||
sCodePage = pFind->second;
|
||||
}
|
||||
|
||||
if (sCodePage.empty())
|
||||
sCodePage = "CP1250"/* + std::to_string(code_page)*/;
|
||||
|
||||
|
||||
@ -72,10 +72,14 @@ namespace DocFileFormat
|
||||
{
|
||||
AnnotationReferenceDescriptor* atrdPre10 = static_cast<AnnotationReferenceDescriptor*>(m_document->AnnotationsReferencePlex->Elements[index]);
|
||||
|
||||
unsigned short index_author = atrdPre10->GetAuthorIndex();
|
||||
m_pXmlWriter->WriteNodeBegin( L"w:comment", TRUE );
|
||||
m_pXmlWriter->WriteAttribute( L"w:id", FormatUtils::IntToWideString( index + 1 ));
|
||||
m_pXmlWriter->WriteAttribute( L"w:author",
|
||||
FormatUtils::XmlEncode(m_document->AnnotationOwners->at( atrdPre10->GetAuthorIndex() ) ));
|
||||
if (index_author < m_document->AnnotationOwners->size()) //conv_253l2H1CehgKwsxCtNk__docx.doc
|
||||
{
|
||||
m_pXmlWriter->WriteAttribute( L"w:author",
|
||||
FormatUtils::XmlEncode(m_document->AnnotationOwners->at( index_author ) ));
|
||||
}
|
||||
m_pXmlWriter->WriteAttribute( L"w:initials", atrdPre10->GetUserInitials());
|
||||
|
||||
//!!!TODO!!!
|
||||
|
||||
@ -53,7 +53,7 @@ namespace DocFileFormat
|
||||
/*========================================================================================================*/
|
||||
|
||||
FormattedDiskPageCHPX::FormattedDiskPageCHPX( POLE::Stream* wordStream, int offset, int nWordVersion ):
|
||||
FormattedDiskPage(), rgb(NULL), grpchpxSize(NULL), grpchpx(NULL)
|
||||
FormattedDiskPage(), rgb(NULL), grpchpxSize(0), grpchpx(NULL)
|
||||
{
|
||||
Type = Character;
|
||||
WordStream = wordStream;
|
||||
|
||||
@ -34,8 +34,8 @@
|
||||
|
||||
namespace DocFileFormat
|
||||
{
|
||||
std::map<unsigned char, std::wstring> PropertiesMapping::brcTypeMap;
|
||||
OfficeCriticalSection PropertiesMapping::brcTypeMapLock;
|
||||
std::map<unsigned char, std::wstring> PropertiesMapping::brcTypeMap;
|
||||
NSCriticalSection::CRITICAL_SECTION_SMART PropertiesMapping::brcTypeMapLock;
|
||||
|
||||
void PropertiesMapping::init()
|
||||
{
|
||||
|
||||
@ -39,8 +39,7 @@
|
||||
#include "ShadingDescriptor.h"
|
||||
#include "SinglePropertyModifier.h"
|
||||
|
||||
|
||||
#include "../../OfficeUtils/src/ASCOfficeCriticalSection.h" //for linux make inside
|
||||
#include "../../DesktopEditor/graphics/TemporaryCS.h"
|
||||
|
||||
namespace DocFileFormat
|
||||
{
|
||||
@ -75,7 +74,7 @@ namespace DocFileFormat
|
||||
|
||||
XMLTools::CStringXmlWriter* m_pXmlWriter;
|
||||
|
||||
static std::map<unsigned char, std::wstring> brcTypeMap;
|
||||
static OfficeCriticalSection brcTypeMapLock;
|
||||
static std::map<unsigned char, std::wstring> brcTypeMap;
|
||||
static NSCriticalSection::CRITICAL_SECTION_SMART brcTypeMapLock;
|
||||
};
|
||||
}
|
||||
|
||||
@ -35,8 +35,8 @@
|
||||
|
||||
namespace DocFileFormat
|
||||
{
|
||||
std::map<std::wstring, std::wstring> StyleSheetMapping::m_mapStyleId;
|
||||
OfficeCriticalSection StyleSheetMapping::m_mapStyleIdLock;
|
||||
std::map<std::wstring, std::wstring> StyleSheetMapping::m_mapStyleId;
|
||||
NSCriticalSection::CRITICAL_SECTION_SMART StyleSheetMapping::m_mapStyleIdLock;
|
||||
|
||||
StyleSheetMapping::StyleSheetMapping( ConversionContext* ctx ) : AbstractOpenXmlMapping( new XMLTools::CStringXmlWriter() )
|
||||
{
|
||||
|
||||
@ -55,7 +55,7 @@ namespace DocFileFormat
|
||||
/// Generates a style id for custom style names or returns the build-in identifier for build-in styles.
|
||||
static std::wstring MakeStyleId( StyleSheetDescription* std );
|
||||
static std::map<std::wstring, std::wstring> m_mapStyleId;
|
||||
static OfficeCriticalSection m_mapStyleIdLock;
|
||||
static NSCriticalSection::CRITICAL_SECTION_SMART m_mapStyleIdLock;
|
||||
virtual ~StyleSheetMapping();
|
||||
|
||||
private:
|
||||
@ -67,4 +67,4 @@ namespace DocFileFormat
|
||||
/// Writes the "NormalTable" default style
|
||||
void writeNormalTableStyle();
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
@ -21,13 +21,7 @@ include($$PWD/../../../Common/3dParty/boost/boost.pri)
|
||||
|
||||
DEFINES += UNICODE \
|
||||
_UNICODE \
|
||||
_USE_LIBXML2_READER_ \
|
||||
LIBXML_READER_ENABLED \
|
||||
DONT_WRITE_EMBEDDED_FONTS \
|
||||
|
||||
INCLUDEPATH += \
|
||||
../../../DesktopEditor/freetype-2.5.2/include \
|
||||
../../../DesktopEditor/xml/libxml2/include
|
||||
DONT_WRITE_EMBEDDED_FONTS
|
||||
|
||||
core_mac {
|
||||
#QMAKE_MAC_SDK = macosx10.11
|
||||
|
||||
@ -47,7 +47,7 @@
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;_USE_LIBXML2_READER_;LIBXML_READER_ENABLED;USE_LITE_READER;_USE_XMLLITE_READER_;PPTX_DEF;PPT_DEF;ENABLE_PPT_TO_PPTX_CONVERT;AVS_USE_CONVERT_PPTX_TOCUSTOM_VML;DONT_WRITE_EMBEDDED_FONTS"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
|
||||
@ -7,66 +7,14 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DocFormatLib", "..\DocForma
|
||||
{77DDC8D7-5B12-4FF2-9629-26AEBCA8436D} = {77DDC8D7-5B12-4FF2-9629-26AEBCA8436D}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "graphics", "..\..\DesktopEditor\graphics\graphics_vs2005.vcproj", "{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540} = {9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36} = {BC52A07C-A797-423D-8C4F-8678805BBB36}
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD} = {617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B} = {78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56} = {C739151F-5384-41DF-A1A6-F089E2C1AD56}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "OfficeUtilsLib", "..\..\OfficeUtils\win32\OfficeUtilsLib.vcproj", "{F8274B05-168E-4D6E-B843-AA7510725363}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "raster", "..\..\DesktopEditor\raster\raster_vs2005.vcproj", "{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36} = {BC52A07C-A797-423D-8C4F-8678805BBB36}
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1} = {EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "cximage", "..\..\DesktopEditor\cximage\CxImage\cximage_vs2005.vcproj", "{BC52A07C-A797-423D-8C4F-8678805BBB36}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470} = {818753F2-DBB9-4D3B-898A-A604309BE470}
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D} = {FFDA5DA1-BB65-4695-B678-BE59B4A1355D}
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E} = {9A037A69-D1DF-4505-AB2A-6CB3641C476E}
|
||||
{40A69F40-063E-43FD-8543-455495D8733E} = {40A69F40-063E-43FD-8543-455495D8733E}
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3} = {0588563C-F05C-428C-B21A-DD74756628B3}
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169} = {DF861D33-9BC1-418C-82B1-581F590FE169}
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239} = {764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7} = {43A0E60E-5C4A-4C09-A29B-7683F503BBD7}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "jasper", "..\..\DesktopEditor\cximage\jasper\jasper_vs2005.vcproj", "{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "jbig", "..\..\DesktopEditor\cximage\jbig\jbig_vs2005.vcproj", "{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "jpeg", "..\..\DesktopEditor\cximage\jpeg\Jpeg_vs2005.vcproj", "{818753F2-DBB9-4D3B-898A-A604309BE470}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libpsd", "..\..\DesktopEditor\cximage\libpsd\libpsd_vs2005.vcproj", "{9A037A69-D1DF-4505-AB2A-6CB3641C476E}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "mng", "..\..\DesktopEditor\cximage\mng\mng_vs2005.vcproj", "{40A69F40-063E-43FD-8543-455495D8733E}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "png", "..\..\DesktopEditor\cximage\png\png_vs2005.vcproj", "{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libdcr", "..\..\DesktopEditor\cximage\raw\libdcr_vs2005.vcproj", "{DF861D33-9BC1-418C-82B1-581F590FE169}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "tiff", "..\..\DesktopEditor\cximage\tiff\Tiff_vs2005.vcproj", "{0588563C-F05C-428C-B21A-DD74756628B3}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "jbig2", "..\..\DesktopEditor\raster\JBig2\win32\jbig2.vcproj", "{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "XlsFormat", "..\..\ASCOfficeXlsFile2\source\win32\XlsFormat.vcproj", "{77DDC8D7-5B12-4FF2-9629-26AEBCA8436D}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DocFormatTest", "DocFormatTest.vcproj", "{0F49D5D1-A8D3-4F97-8BC1-E2F65BB00C10}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0} = {21663823-DE45-479B-91D0-B4FEF4916EF0}
|
||||
{36636678-AE25-4BE6-9A34-2561D1BCF302} = {36636678-AE25-4BE6-9A34-2561D1BCF302}
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36} = {BC52A07C-A797-423D-8C4F-8678805BBB36}
|
||||
{A100103A-353E-45E8-A9B8-90B87CC5C0B0} = {A100103A-353E-45E8-A9B8-90B87CC5C0B0}
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363} = {F8274B05-168E-4D6E-B843-AA7510725363}
|
||||
{3423EC9A-52E4-4A4D-9753-EDEBC38785EF} = {3423EC9A-52E4-4A4D-9753-EDEBC38785EF}
|
||||
{C27E9A9F-3A17-4482-9C5F-BF15C01E747C} = {C27E9A9F-3A17-4482-9C5F-BF15C01E747C}
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540} = {9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2} = {37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}
|
||||
{C5371405-338F-4B70-83BD-2A5CDF64F383} = {C5371405-338F-4B70-83BD-2A5CDF64F383}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
@ -78,17 +26,6 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "cryptlib", "..\..\Common\3d
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "PPTXFormat", "..\..\ASCOfficePPTXFile\PPTXLib\PPTXFormat.vcproj", "{36636678-AE25-4BE6-9A34-2561D1BCF302}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "agg2d", "..\..\DesktopEditor\agg-2.4\agg_vs2005.vcproj", "{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "font_engine", "..\..\DesktopEditor\fontengine\font_engine_vs2005.vcproj", "{C739151F-5384-41DF-A1A6-F089E2C1AD56}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B} = {78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "freetype", "..\..\DesktopEditor\freetype-2.5.2\builds\windows\vc2005\freetype.vcproj", "{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libxml2", "..\..\DesktopEditor\xml\build\vs2005\libxml2.vcproj", "{21663823-DE45-479B-91D0-B4FEF4916EF0}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Win32 = Debug|Win32
|
||||
@ -105,110 +42,6 @@ Global
|
||||
{C5371405-338F-4B70-83BD-2A5CDF64F383}.Release|Win32.Build.0 = Release|Win32
|
||||
{C5371405-338F-4B70-83BD-2A5CDF64F383}.Release|x64.ActiveCfg = Release|x64
|
||||
{C5371405-338F-4B70-83BD-2A5CDF64F383}.Release|x64.Build.0 = Release|x64
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.Debug|x64.Build.0 = Debug|x64
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.Release|Win32.Build.0 = Release|Win32
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.Release|x64.ActiveCfg = Release|x64
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.Release|x64.Build.0 = Release|x64
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.Debug|x64.Build.0 = Debug|x64
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.Release|Win32.Build.0 = Release|Win32
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.Release|x64.ActiveCfg = Release|x64
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.Release|x64.Build.0 = Release|x64
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.Debug|x64.Build.0 = Debug|x64
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.Release|Win32.Build.0 = Release|Win32
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.Release|x64.ActiveCfg = Release|x64
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.Release|x64.Build.0 = Release|x64
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.Debug|x64.Build.0 = Debug|x64
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.Release|Win32.Build.0 = Release|Win32
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.Release|x64.ActiveCfg = Release|x64
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.Release|x64.Build.0 = Release|x64
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.Debug|x64.Build.0 = Debug|x64
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.Release|Win32.Build.0 = Release|Win32
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.Release|x64.ActiveCfg = Release|x64
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.Release|x64.Build.0 = Release|x64
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.Debug|x64.Build.0 = Debug|x64
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.Release|Win32.Build.0 = Release|Win32
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.Release|x64.ActiveCfg = Release|x64
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.Release|x64.Build.0 = Release|x64
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.Debug|x64.Build.0 = Debug|x64
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.Release|Win32.Build.0 = Release|Win32
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.Release|x64.ActiveCfg = Release|x64
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.Release|x64.Build.0 = Release|x64
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.Debug|x64.Build.0 = Debug|x64
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.Release|Win32.Build.0 = Release|Win32
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.Release|x64.ActiveCfg = Release|x64
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.Release|x64.Build.0 = Release|x64
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.Debug|x64.Build.0 = Debug|x64
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.Release|Win32.Build.0 = Release|Win32
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.Release|x64.ActiveCfg = Release|x64
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.Release|x64.Build.0 = Release|x64
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.Debug|x64.Build.0 = Debug|x64
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.Release|Win32.Build.0 = Release|Win32
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.Release|x64.ActiveCfg = Release|x64
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.Release|x64.Build.0 = Release|x64
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.Debug|x64.Build.0 = Debug|x64
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.Release|Win32.Build.0 = Release|Win32
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.Release|x64.ActiveCfg = Release|x64
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.Release|x64.Build.0 = Release|x64
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.Debug|x64.Build.0 = Debug|x64
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.Release|Win32.Build.0 = Release|Win32
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.Release|x64.ActiveCfg = Release|x64
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.Release|x64.Build.0 = Release|x64
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.Debug|x64.Build.0 = Debug|x64
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.Release|Win32.Build.0 = Release|Win32
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.Release|x64.ActiveCfg = Release|x64
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.Release|x64.Build.0 = Release|x64
|
||||
{77DDC8D7-5B12-4FF2-9629-26AEBCA8436D}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{77DDC8D7-5B12-4FF2-9629-26AEBCA8436D}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{77DDC8D7-5B12-4FF2-9629-26AEBCA8436D}.Debug|x64.ActiveCfg = Debug|x64
|
||||
@ -255,38 +88,6 @@ Global
|
||||
{36636678-AE25-4BE6-9A34-2561D1BCF302}.Release|Win32.Build.0 = Release|Win32
|
||||
{36636678-AE25-4BE6-9A34-2561D1BCF302}.Release|x64.ActiveCfg = Release|x64
|
||||
{36636678-AE25-4BE6-9A34-2561D1BCF302}.Release|x64.Build.0 = Release|x64
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.Debug|x64.Build.0 = Debug|x64
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.Release|Win32.Build.0 = Release|Win32
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.Release|x64.ActiveCfg = Release|x64
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.Release|x64.Build.0 = Release|x64
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.Debug|x64.Build.0 = Debug|x64
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.Release|Win32.Build.0 = Release|Win32
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.Release|x64.ActiveCfg = Release|x64
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.Release|x64.Build.0 = Release|x64
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.Debug|x64.Build.0 = Debug|x64
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.Release|Win32.Build.0 = Release|Win32
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.Release|x64.ActiveCfg = Release|x64
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.Release|x64.Build.0 = Release|x64
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.Debug|x64.Build.0 = Debug|x64
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.Release|Win32.Build.0 = Release|Win32
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.Release|x64.ActiveCfg = Release|x64
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.Release|x64.Build.0 = Release|x64
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
|
||||
@ -46,6 +46,16 @@
|
||||
#if defined(_WIN64)
|
||||
#pragma comment(lib, "../../build/bin/icu/win_64/icuuc.lib")
|
||||
#elif defined (_WIN32)
|
||||
|
||||
#if defined(_DEBUG)
|
||||
#pragma comment(lib, "../../build/lib/win_32/DEBUG/graphics.lib")
|
||||
#pragma comment(lib, "../../build/lib/win_32/DEBUG/kernel.lib")
|
||||
#pragma comment(lib, "../../build/lib/win_32/DEBUG/UnicodeConverter.lib")
|
||||
#else
|
||||
#pragma comment(lib, "../../build/lib/win_32/graphics.lib")
|
||||
#pragma comment(lib, "../../build/lib/win_32/kernel.lib")
|
||||
#pragma comment(lib, "../../build/lib/win_32/UnicodeConverter.lib")
|
||||
#endif
|
||||
#pragma comment(lib, "../../build/bin/icu/win_32/icuuc.lib")
|
||||
#endif
|
||||
|
||||
@ -83,7 +93,7 @@ HRESULT convert_single(std::wstring srcFileName)
|
||||
if (hRes == S_OK)
|
||||
{
|
||||
COfficeUtils oCOfficeUtils(NULL);
|
||||
hRes = oCOfficeUtils.CompressFileOrDirectory(dstTempPath.c_str(), dstPath, -1);
|
||||
hRes = oCOfficeUtils.CompressFileOrDirectory(dstTempPath.c_str(), dstPath, true);
|
||||
}
|
||||
|
||||
NSDirectory::DeleteDirectory(dstTempPath);
|
||||
|
||||
@ -48,7 +48,7 @@
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;USE_ATL_CSTRINGS;_USE_LIBXML2_READER_;LIBXML_READER_ENABLED;USE_LITE_READER;_USE_XMLLITE_READER_;DONT_WRITE_EMBEDDED_FONTS"
|
||||
MinimalRebuild="false"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
@ -341,6 +341,10 @@
|
||||
<Filter
|
||||
Name="Common"
|
||||
>
|
||||
<File
|
||||
RelativePath="..\..\DesktopEditor\common\Base64.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\ASCOfficeDocxFile2\BinWriter\BinWriters.cpp"
|
||||
>
|
||||
@ -385,6 +389,10 @@
|
||||
RelativePath="..\..\ASCOfficeDocxFile2\DocWrapper\FontProcessor.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\Common\3dParty\pole\pole.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\ASCOfficeDocxFile2\BinReader\Readers.cpp"
|
||||
>
|
||||
@ -442,30 +450,10 @@
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\Common\FileDownloader\FileDownloader_win.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\Common\OfficeFileFormatChecker2.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\Common\3dParty\pole\pole.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\build\lib\win_32\DEBUG\UnicodeConverter.lib"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\DesktopEditor\xml\src\xmldom.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\DesktopEditor\xml\src\xmllight.cpp"
|
||||
>
|
||||
</File>
|
||||
</Files>
|
||||
<Globals>
|
||||
</Globals>
|
||||
|
||||
@ -53,6 +53,8 @@
|
||||
#include "../../DesktopEditor/common/ASCVariant.h"
|
||||
#include "../../OfficeUtils/src/OfficeUtils.h"
|
||||
|
||||
#include "../../DesktopEditor/common/Directory.h"
|
||||
|
||||
namespace BinDocxRW {
|
||||
|
||||
enum ETblStyleOverrideType
|
||||
@ -7509,7 +7511,7 @@ public:
|
||||
oXlsx.Write(strDstEmbeddedTemp, *oSaveParams.pContentTypes);
|
||||
|
||||
COfficeUtils oOfficeUtils(NULL);
|
||||
oOfficeUtils.CompressFileOrDirectory(strDstEmbeddedTemp, strDstEmbedded + FILE_SEPARATOR_STR + sXlsxFilename, -1);
|
||||
oOfficeUtils.CompressFileOrDirectory(strDstEmbeddedTemp, strDstEmbedded + FILE_SEPARATOR_STR + sXlsxFilename, true);
|
||||
|
||||
std::wstring sEmbWorksheetRelsName = L"embeddings/" + sXlsxFilename;
|
||||
std::wstring bstrEmbWorksheetRelType = OOX::FileTypes::MicrosoftOfficeExcelWorksheet.RelationType();
|
||||
|
||||
@ -37,7 +37,7 @@
|
||||
namespace Writers
|
||||
{
|
||||
static std::wstring g_string_set_Start = _T("<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"yes\" ?><w:settings xmlns:w=\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\" xmlns:m=\"http://schemas.openxmlformats.org/officeDocument/2006/math\" xmlns:o=\"urn:schemas-microsoft-com:office:office\" xmlns:v=\"urn:schemas-microsoft-com:vml\">");
|
||||
static std::wstring g_string_set_Default = _T("<w:zoom w:percent=\"100\"/><w:characterSpacingControl w:val=\"doNotCompress\"/><w:compat><w:compatSetting w:name=\"compatibilityMode\" w:uri=\"http://schemas.microsoft.com/office/word\" w:val=\"14\"/><w:compatSetting w:name=\"overrideTableStyleFontSizeAndJustification\" w:uri=\"http://schemas.microsoft.com/office/word\" w:val=\"1\"/><w:compatSetting w:name=\"enableOpenTypeFeatures\" w:uri=\"http://schemas.microsoft.com/office/word\" w:val=\"1\"/><w:compatSetting w:name=\"doNotFlipMirrorIndents\" w:uri=\"http://schemas.microsoft.com/office/word\" w:val=\"1\"/></w:compat><w:themeFontLang w:val=\"en-US\" w:eastAsia=\"zh-CN\"/><w:shapeDefaults><o:shapedefaults v:ext=\"edit\" spidmax=\"1026\"/><o:shapelayout v:ext=\"edit\"><o:idmap v:ext=\"edit\" data=\"1\"/></o:shapelayout></w:shapeDefaults><w:decimalSymbol w:val=\".\"/><w:listSeparator w:val=\",\"/>");
|
||||
static std::wstring g_string_set_Default = _T("<w:zoom w:percent=\"100\"/><w:characterSpacingControl w:val=\"doNotCompress\"/><w:compat><w:compatSetting w:name=\"compatibilityMode\" w:uri=\"http://schemas.microsoft.com/office/word\" w:val=\"15\"/><w:compatSetting w:name=\"overrideTableStyleFontSizeAndJustification\" w:uri=\"http://schemas.microsoft.com/office/word\" w:val=\"1\"/><w:compatSetting w:name=\"enableOpenTypeFeatures\" w:uri=\"http://schemas.microsoft.com/office/word\" w:val=\"1\"/><w:compatSetting w:name=\"doNotFlipMirrorIndents\" w:uri=\"http://schemas.microsoft.com/office/word\" w:val=\"1\"/></w:compat><w:themeFontLang w:val=\"en-US\" w:eastAsia=\"zh-CN\"/><w:shapeDefaults><o:shapedefaults v:ext=\"edit\" spidmax=\"1026\"/><o:shapelayout v:ext=\"edit\"><o:idmap v:ext=\"edit\" data=\"1\"/></o:shapelayout></w:shapeDefaults><w:decimalSymbol w:val=\".\"/><w:listSeparator w:val=\",\"/>");
|
||||
static std::wstring g_string_set_End = _T("</w:settings>");
|
||||
|
||||
class SettingWriter
|
||||
|
||||
@ -33,8 +33,7 @@
|
||||
#define FONT_TABLE_WRITER
|
||||
|
||||
#include "../../XlsxSerializerCom/Common/Common.h"
|
||||
#include "../../DesktopEditor/fontengine/FontManager.h"
|
||||
#include "../../DesktopEditor/fontengine/ApplicationFonts.h"
|
||||
#include "../../DesktopEditor/graphics/pro/Fonts.h"
|
||||
#include <boost/unordered_map.hpp>
|
||||
|
||||
namespace Writers
|
||||
@ -46,32 +45,28 @@ namespace Writers
|
||||
{
|
||||
XmlUtils::CStringWriter m_oWriter;
|
||||
std::wstring m_sDir;
|
||||
CApplicationFonts m_oApplicationFonts;
|
||||
CFontManager* m_pFontManager;
|
||||
NSFonts::IApplicationFonts* m_pApplicationFonts;
|
||||
NSFonts::IFontManager* m_pFontManager;
|
||||
public:
|
||||
boost::unordered_map<std::wstring, int> m_mapFonts;
|
||||
|
||||
FontTableWriter(std::wstring sDir, std::wstring sFontDir, bool bNoFontDir):m_sDir(sDir)
|
||||
{
|
||||
m_pApplicationFonts = NSFonts::NSApplication::Create();
|
||||
m_pFontManager = NULL;
|
||||
if(!bNoFontDir)
|
||||
{
|
||||
if(sFontDir.empty())
|
||||
m_oApplicationFonts.Initialize();
|
||||
m_pApplicationFonts->Initialize();
|
||||
else
|
||||
m_oApplicationFonts.InitializeFromFolder(sFontDir);
|
||||
CFontList* pFontList = m_oApplicationFonts.GetList();
|
||||
if(NULL != pFontList)
|
||||
{
|
||||
std::wstring sDefaultFont(_T("Arial"));
|
||||
pFontList->SetDefaultFont(sDefaultFont);
|
||||
}
|
||||
m_pFontManager = m_oApplicationFonts.GenerateFontManager();
|
||||
m_pApplicationFonts->InitializeFromFolder(sFontDir);
|
||||
m_pFontManager = m_pApplicationFonts->GenerateFontManager();
|
||||
}
|
||||
}
|
||||
~FontTableWriter()
|
||||
{
|
||||
RELEASEOBJECT(m_pFontManager);
|
||||
RELEASEOBJECT(m_pApplicationFonts);
|
||||
}
|
||||
|
||||
void Write()
|
||||
@ -116,11 +111,11 @@ namespace Writers
|
||||
bool bUsePanose = false;
|
||||
if(NULL != m_pFontManager)
|
||||
{
|
||||
CFontSelectFormat oFontSelectFormat;
|
||||
NSFonts::CFontSelectFormat oFontSelectFormat;
|
||||
oFontSelectFormat.wsName = new std::wstring;
|
||||
*oFontSelectFormat.wsName = sFontName;
|
||||
|
||||
CFontInfo* pFontInfo = m_pFontManager->GetFontInfoByParams(oFontSelectFormat);
|
||||
NSFonts::CFontInfo* pFontInfo = m_pFontManager->GetFontInfoByParams(oFontSelectFormat);
|
||||
if(NULL != pFontInfo)
|
||||
{
|
||||
for (size_t i = 0; i < 10; ++i)
|
||||
|
||||
@ -599,7 +599,7 @@ namespace BinXlsxRW{
|
||||
//как в CsvReader - подозрительный код
|
||||
WCHAR *pEndPtr;
|
||||
wcstod(val.c_str(), &pEndPtr);
|
||||
if (NULL != *pEndPtr)
|
||||
if (0 != *pEndPtr)
|
||||
{
|
||||
// Не число
|
||||
aSharedStrings.push_back(val);
|
||||
|
||||
@ -67,7 +67,7 @@ bool BinDocxRW::CDocxSerializer::saveToFile(const std::wstring& sSrcFileName, co
|
||||
|
||||
COfficeFontPicker* pFontPicker = new COfficeFontPicker();
|
||||
pFontPicker->Init(m_sFontDir);
|
||||
CFontManager* pFontManager = pFontPicker->get_FontManager();
|
||||
NSFonts::IFontManager* pFontManager = pFontPicker->get_FontManager();
|
||||
DocWrapper::FontProcessor fp;
|
||||
fp.setFontManager(pFontManager);
|
||||
|
||||
|
||||
@ -52,11 +52,11 @@ namespace DocWrapper {
|
||||
{
|
||||
}
|
||||
|
||||
void FontProcessor::setFontManager(CFontManager* pFontManager)
|
||||
void FontProcessor::setFontManager(NSFonts::IFontManager* pFontManager)
|
||||
{
|
||||
m_pFontManager = pFontManager;
|
||||
}
|
||||
CFontManager* FontProcessor::getFontManager()
|
||||
NSFonts::IFontManager* FontProcessor::getFontManager()
|
||||
{
|
||||
return m_pFontManager;
|
||||
}
|
||||
@ -88,7 +88,7 @@ namespace DocWrapper {
|
||||
|
||||
std::wstring FontProcessor::getFont(const NSCommon::nullable<OOX::Spreadsheet::CFontScheme>& oScheme, const NSCommon::nullable<ComplexTypes::Spreadsheet::String>& oRFont, const NSCommon::nullable<OOX::Spreadsheet::CCharset>& oCharset, const NSCommon::nullable<OOX::Spreadsheet::CFontFamily >& oFamily, PPTX::Theme* pTheme)
|
||||
{
|
||||
CFontSelectFormat oFontSelectFormat;
|
||||
NSFonts::CFontSelectFormat oFontSelectFormat;
|
||||
std::wstring sFontName;
|
||||
if(NULL != pTheme && oScheme.IsInit() && oScheme->m_oFontScheme.IsInit())
|
||||
{
|
||||
@ -125,7 +125,7 @@ namespace DocWrapper {
|
||||
}
|
||||
|
||||
std::wstring sRes;
|
||||
CFontInfo* pFontInfo = m_pFontManager->GetFontInfoByParams(oFontSelectFormat);
|
||||
NSFonts::CFontInfo* pFontInfo = m_pFontManager->GetFontInfoByParams(oFontSelectFormat);
|
||||
if(NULL != pFontInfo)
|
||||
sRes = pFontInfo->m_wsFontName;
|
||||
else
|
||||
@ -135,7 +135,7 @@ namespace DocWrapper {
|
||||
}
|
||||
void FontProcessor::addToFontMap(OOX::CFont& font)
|
||||
{
|
||||
CFontSelectFormat oFontSelectFormat;
|
||||
NSFonts::CFontSelectFormat oFontSelectFormat;
|
||||
std::wstring sFontName;
|
||||
|
||||
if(font.m_sName.empty())
|
||||
@ -221,7 +221,7 @@ namespace DocWrapper {
|
||||
*oFontSelectFormat.ulCodeRange2 = ulCodeRange2;
|
||||
}
|
||||
|
||||
CFontInfo* pFontInfo = m_pFontManager->GetFontInfoByParams(oFontSelectFormat);
|
||||
NSFonts::CFontInfo* pFontInfo = m_pFontManager->GetFontInfoByParams(oFontSelectFormat);
|
||||
if(NULL != pFontInfo)
|
||||
fontMap[sFontName] = pFontInfo->m_wsFontName;
|
||||
else
|
||||
|
||||
@ -33,7 +33,7 @@
|
||||
|
||||
#include <map>
|
||||
|
||||
#include "../../DesktopEditor/fontengine/ApplicationFonts.h"
|
||||
#include "../../DesktopEditor/graphics/pro/Fonts.h"
|
||||
|
||||
namespace NSCommon{
|
||||
template<class Type> class nullable;
|
||||
@ -68,15 +68,15 @@ namespace DocWrapper
|
||||
{
|
||||
class FontProcessor
|
||||
{
|
||||
CFontManager* m_pFontManager;
|
||||
NSFonts::IFontManager* m_pFontManager;
|
||||
std::map<std::wstring, std::wstring> fontMap;
|
||||
|
||||
public:
|
||||
FontProcessor();
|
||||
~FontProcessor();
|
||||
|
||||
void setFontManager(CFontManager* pFontManager);
|
||||
CFontManager* getFontManager();
|
||||
void setFontManager(NSFonts::IFontManager* pFontManager);
|
||||
NSFonts::IFontManager* getFontManager();
|
||||
void setFontTable(OOX::CFontTable* fontTable);
|
||||
|
||||
std::wstring getFont(const std::wstring& name);
|
||||
|
||||
@ -104,7 +104,7 @@ namespace BinXlsxRW{
|
||||
{
|
||||
COfficeFontPicker* pFontPicker = new COfficeFontPicker();
|
||||
pFontPicker->Init(m_sFontDir);
|
||||
CFontManager* pFontManager = pFontPicker->get_FontManager();
|
||||
NSFonts::IFontManager* pFontManager = pFontPicker->get_FontManager();
|
||||
DocWrapper::FontProcessor fp;
|
||||
fp.setFontManager(pFontManager);
|
||||
|
||||
|
||||
@ -16,17 +16,9 @@ include($$PWD/../../Common/3dParty/boost/boost.pri)
|
||||
|
||||
DEFINES += UNICODE \
|
||||
_UNICODE \
|
||||
USE_AVSOFFICESTUDIO_XMLUTILS \
|
||||
SOLUTION_ASCOFFICEDOCXFILE2 \
|
||||
#DISABLE_FILE_DOWNLOADER \
|
||||
_USE_LIBXML2_READER_ \
|
||||
LIBXML_READER_ENABLED \
|
||||
DONT_WRITE_EMBEDDED_FONTS
|
||||
|
||||
|
||||
INCLUDEPATH += \
|
||||
../../DesktopEditor/freetype-2.5.2/include \
|
||||
../../DesktopEditor/xml/libxml2/include \
|
||||
#DISABLE_FILE_DOWNLOADER \
|
||||
DONT_WRITE_EMBEDDED_FONTS
|
||||
|
||||
|
||||
SOURCES += \
|
||||
|
||||
@ -51,6 +51,8 @@
|
||||
6967917F1D9E8AEE002CA4BA /* BinWriters.h in Headers */ = {isa = PBXBuildFile; fileRef = 6967917B1D9E8AEE002CA4BA /* BinWriters.h */; };
|
||||
69BBDF251F0B8AAC00EB1BF7 /* FileDownloader_mac.mm in Sources */ = {isa = PBXBuildFile; fileRef = 69BBDF241F0B8AAC00EB1BF7 /* FileDownloader_mac.mm */; };
|
||||
69F181AF1C77274E00B2952B /* FileDownloader.h in Headers */ = {isa = PBXBuildFile; fileRef = 69F181AD1C77274E00B2952B /* FileDownloader.h */; };
|
||||
8A404FD3208A01AF00F2D5CF /* FileDownloader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8A404FD2208A01AF00F2D5CF /* FileDownloader.cpp */; };
|
||||
8A404FD5208A01CE00F2D5CF /* FileDownloader_private.h in Headers */ = {isa = PBXBuildFile; fileRef = 8A404FD4208A01CE00F2D5CF /* FileDownloader_private.h */; };
|
||||
/* End PBXBuildFile section */
|
||||
|
||||
/* Begin PBXFileReference section */
|
||||
@ -99,6 +101,8 @@
|
||||
6967917B1D9E8AEE002CA4BA /* BinWriters.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = BinWriters.h; path = ../../BinWriter/BinWriters.h; sourceTree = "<group>"; };
|
||||
69BBDF241F0B8AAC00EB1BF7 /* FileDownloader_mac.mm */ = {isa = PBXFileReference; explicitFileType = sourcecode.cpp.objcpp.preprocessed; fileEncoding = 4; name = FileDownloader_mac.mm; path = ../../../Common/FileDownloader/FileDownloader_mac.mm; sourceTree = "<group>"; };
|
||||
69F181AD1C77274E00B2952B /* FileDownloader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = FileDownloader.h; path = ../../../Common/FileDownloader/FileDownloader.h; sourceTree = "<group>"; };
|
||||
8A404FD2208A01AF00F2D5CF /* FileDownloader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = FileDownloader.cpp; path = ../../../Common/FileDownloader/FileDownloader.cpp; sourceTree = "<group>"; };
|
||||
8A404FD4208A01CE00F2D5CF /* FileDownloader_private.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = FileDownloader_private.h; path = ../../../Common/FileDownloader/FileDownloader_private.h; sourceTree = "<group>"; };
|
||||
/* End PBXFileReference section */
|
||||
|
||||
/* Begin PBXFrameworksBuildPhase section */
|
||||
@ -231,6 +235,8 @@
|
||||
children = (
|
||||
69F181AD1C77274E00B2952B /* FileDownloader.h */,
|
||||
69BBDF241F0B8AAC00EB1BF7 /* FileDownloader_mac.mm */,
|
||||
8A404FD2208A01AF00F2D5CF /* FileDownloader.cpp */,
|
||||
8A404FD4208A01CE00F2D5CF /* FileDownloader_private.h */,
|
||||
);
|
||||
name = Common;
|
||||
sourceTree = "<group>";
|
||||
@ -273,6 +279,7 @@
|
||||
69F181AF1C77274E00B2952B /* FileDownloader.h in Headers */,
|
||||
17C1FEB01ACC42C4006B99B3 /* BinaryCommonReader.h in Headers */,
|
||||
17C1FEB11ACC42C4006B99B3 /* Common.h in Headers */,
|
||||
8A404FD5208A01CE00F2D5CF /* FileDownloader_private.h in Headers */,
|
||||
17C1FEB21ACC42C4006B99B3 /* XlsxSerializer.h in Headers */,
|
||||
17C1FEB31ACC42C4006B99B3 /* CSVReader.h in Headers */,
|
||||
6967917D1D9E8AEE002CA4BA /* BinReaderWriterDefines.h in Headers */,
|
||||
@ -351,6 +358,7 @@
|
||||
17C1FE9C1ACC42C4006B99B3 /* XlsxSerializer.cpp in Sources */,
|
||||
690FE0851E9BBD68004B26D0 /* Readers.cpp in Sources */,
|
||||
17C1FE9D1ACC42C4006B99B3 /* FontProcessor.cpp in Sources */,
|
||||
8A404FD3208A01AF00F2D5CF /* FileDownloader.cpp in Sources */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
|
||||
@ -2,14 +2,12 @@
|
||||
Microsoft Visual Studio Solution File, Format Version 9.00
|
||||
# Visual Studio 2005
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "xml_wrapper", "..\win32\cpxml.vcproj", "{41BED424-4EAF-4053-8A5F-1E2A387D53D1}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0} = {21663823-DE45-479B-91D0-B4FEF4916EF0}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "OdfFormatReaderLib", "..\win32\cpodf.vcproj", "{50E20601-4A8D-4AFB-8870-63828D328429}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{94954A67-A853-43B1-A727-6EF2774C5A6A} = {94954A67-A853-43B1-A727-6EF2774C5A6A}
|
||||
{41BED424-4EAF-4053-8A5F-1E2A387D53D1} = {41BED424-4EAF-4053-8A5F-1E2A387D53D1}
|
||||
{609ED938-3CA8-4BED-B363-25096D4C4812} = {609ED938-3CA8-4BED-B363-25096D4C4812}
|
||||
{94954A67-A853-43B1-A727-6EF2774C5A6A} = {94954A67-A853-43B1-A727-6EF2774C5A6A}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "OdfCommon", "..\win32\cpcommon.vcproj", "{609ED938-3CA8-4BED-B363-25096D4C4812}"
|
||||
@ -22,73 +20,10 @@ EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "OdfFileReaderTest", "OdfFileTest.vcproj", "{C2882DDD-07E6-4314-AD4B-48F43F38D722}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{C27E9A9F-3A17-4482-9C5F-BF15C01E747C} = {C27E9A9F-3A17-4482-9C5F-BF15C01E747C}
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36} = {BC52A07C-A797-423D-8C4F-8678805BBB36}
|
||||
{41BED424-4EAF-4053-8A5F-1E2A387D53D1} = {41BED424-4EAF-4053-8A5F-1E2A387D53D1}
|
||||
{50E20601-4A8D-4AFB-8870-63828D328429} = {50E20601-4A8D-4AFB-8870-63828D328429}
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2} = {37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}
|
||||
{94954A67-A853-43B1-A727-6EF2774C5A6A} = {94954A67-A853-43B1-A727-6EF2774C5A6A}
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363} = {F8274B05-168E-4D6E-B843-AA7510725363}
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540} = {9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0} = {21663823-DE45-479B-91D0-B4FEF4916EF0}
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD} = {617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56} = {C739151F-5384-41DF-A1A6-F089E2C1AD56}
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B} = {78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "graphics", "..\..\DesktopEditor\graphics\graphics_vs2005.vcproj", "{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD} = {617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "font_engine", "..\..\DesktopEditor\fontengine\font_engine_vs2005.vcproj", "{C739151F-5384-41DF-A1A6-F089E2C1AD56}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B} = {78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "freetype", "..\..\DesktopEditor\freetype-2.5.2\builds\windows\vc2005\freetype.vcproj", "{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "raster", "..\..\DesktopEditor\raster\raster_vs2005.vcproj", "{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36} = {BC52A07C-A797-423D-8C4F-8678805BBB36}
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1} = {EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "cximage", "..\..\DesktopEditor\cximage\CxImage\cximage_vs2005.vcproj", "{BC52A07C-A797-423D-8C4F-8678805BBB36}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239} = {764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169} = {DF861D33-9BC1-418C-82B1-581F590FE169}
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3} = {0588563C-F05C-428C-B21A-DD74756628B3}
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7} = {43A0E60E-5C4A-4C09-A29B-7683F503BBD7}
|
||||
{40A69F40-063E-43FD-8543-455495D8733E} = {40A69F40-063E-43FD-8543-455495D8733E}
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E} = {9A037A69-D1DF-4505-AB2A-6CB3641C476E}
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D} = {FFDA5DA1-BB65-4695-B678-BE59B4A1355D}
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470} = {818753F2-DBB9-4D3B-898A-A604309BE470}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "jasper", "..\..\DesktopEditor\cximage\jasper\jasper_vs2005.vcproj", "{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "jbig", "..\..\DesktopEditor\cximage\jbig\jbig_vs2005.vcproj", "{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "jpeg", "..\..\DesktopEditor\cximage\jpeg\Jpeg_vs2005.vcproj", "{818753F2-DBB9-4D3B-898A-A604309BE470}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libpsd", "..\..\DesktopEditor\cximage\libpsd\libpsd_vs2005.vcproj", "{9A037A69-D1DF-4505-AB2A-6CB3641C476E}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "mng", "..\..\DesktopEditor\cximage\mng\mng_vs2005.vcproj", "{40A69F40-063E-43FD-8543-455495D8733E}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "png", "..\..\DesktopEditor\cximage\png\png_vs2005.vcproj", "{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libdcr", "..\..\DesktopEditor\cximage\raw\libdcr_vs2005.vcproj", "{DF861D33-9BC1-418C-82B1-581F590FE169}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "tiff", "..\..\DesktopEditor\cximage\tiff\Tiff_vs2005.vcproj", "{0588563C-F05C-428C-B21A-DD74756628B3}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "jbig2", "..\..\DesktopEditor\raster\JBig2\win32\jbig2.vcproj", "{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "agg2d", "..\..\DesktopEditor\agg-2.4\agg_vs2005.vcproj", "{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "OfficeUtilsLib", "..\..\OfficeUtils\win32\OfficeUtilsLib.vcproj", "{F8274B05-168E-4D6E-B843-AA7510725363}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libxml2", "..\..\DesktopEditor\xml\build\vs2005\libxml2.vcproj", "{21663823-DE45-479B-91D0-B4FEF4916EF0}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "OfficeFileCrypt", "..\..\OfficeCryptReader\win32\ECMACryptReader.vcproj", "{C27E9A9F-3A17-4482-9C5F-BF15C01E747C}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{3423EC9A-52E4-4A4D-9753-EDEBC38785EF} = {3423EC9A-52E4-4A4D-9753-EDEBC38785EF}
|
||||
@ -188,278 +123,6 @@ Global
|
||||
{C2882DDD-07E6-4314-AD4B-48F43F38D722}.Release|Win32.Build.0 = Release|Win32
|
||||
{C2882DDD-07E6-4314-AD4B-48F43F38D722}.Release|x64.ActiveCfg = Release|x64
|
||||
{C2882DDD-07E6-4314-AD4B-48F43F38D722}.Release|x64.Build.0 = Release|x64
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.Debug|x64.Build.0 = Debug|x64
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.Release|Win32.Build.0 = Release|Win32
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.Release|x64.ActiveCfg = Release|x64
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.Release|x64.Build.0 = Release|x64
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.Debug|x64.Build.0 = Debug|x64
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.Release|Win32.Build.0 = Release|Win32
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.Release|x64.ActiveCfg = Release|x64
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.Release|x64.Build.0 = Release|x64
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.Debug|x64.Build.0 = Debug|x64
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.Release|Win32.Build.0 = Release|Win32
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.Release|x64.ActiveCfg = Release|x64
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.Release|x64.Build.0 = Release|x64
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.Debug|x64.Build.0 = Debug|x64
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.Release|Win32.Build.0 = Release|Win32
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.Release|x64.ActiveCfg = Release|x64
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.Release|x64.Build.0 = Release|x64
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.Debug|x64.Build.0 = Debug|x64
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.Release|Win32.Build.0 = Release|Win32
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.Release|x64.ActiveCfg = Release|x64
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.Release|x64.Build.0 = Release|x64
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.Debug|x64.Build.0 = Debug|x64
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.Release|Win32.Build.0 = Release|Win32
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.Release|x64.ActiveCfg = Release|x64
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.Release|x64.Build.0 = Release|x64
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.Debug|x64.Build.0 = Debug|x64
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.Release|Win32.Build.0 = Release|Win32
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.Release|x64.ActiveCfg = Release|x64
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.Release|x64.Build.0 = Release|x64
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.Debug|x64.Build.0 = Debug|x64
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.Release|Win32.Build.0 = Release|Win32
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.Release|x64.ActiveCfg = Release|x64
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.Release|x64.Build.0 = Release|x64
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.Debug|x64.Build.0 = Debug|x64
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.Release|Win32.Build.0 = Release|Win32
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.Release|x64.ActiveCfg = Release|x64
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.Release|x64.Build.0 = Release|x64
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.Debug|x64.Build.0 = Debug|x64
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.Release|Win32.Build.0 = Release|Win32
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.Release|x64.ActiveCfg = Release|x64
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.Release|x64.Build.0 = Release|x64
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.Debug|x64.Build.0 = Debug|x64
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.Release|Win32.Build.0 = Release|Win32
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.Release|x64.ActiveCfg = Release|x64
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.Release|x64.Build.0 = Release|x64
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.Debug|x64.Build.0 = Debug|x64
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.Release|Win32.Build.0 = Release|Win32
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.Release|x64.ActiveCfg = Release|x64
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.Release|x64.Build.0 = Release|x64
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.Debug|x64.Build.0 = Debug|x64
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.Release|Win32.Build.0 = Release|Win32
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.Release|x64.ActiveCfg = Release|x64
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.Release|x64.Build.0 = Release|x64
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.Debug|x64.Build.0 = Debug|x64
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.Release|Win32.Build.0 = Release|Win32
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.Release|x64.ActiveCfg = Release|x64
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.Release|x64.Build.0 = Release|x64
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.Debug|x64.Build.0 = Debug|x64
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.Release|Win32.Build.0 = Release|Win32
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.Release|x64.ActiveCfg = Release|x64
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.Release|x64.Build.0 = Release|x64
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.Debug|x64.Build.0 = Debug|x64
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.Release|Win32.Build.0 = Release|Win32
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.Release|x64.ActiveCfg = Release|x64
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.Release|x64.Build.0 = Release|x64
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.Debug|x64.Build.0 = Debug|x64
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.Release|Win32.Build.0 = Release|Win32
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.Release|x64.ActiveCfg = Release|x64
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.Release|x64.Build.0 = Release|x64
|
||||
{C27E9A9F-3A17-4482-9C5F-BF15C01E747C}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{C27E9A9F-3A17-4482-9C5F-BF15C01E747C}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{C27E9A9F-3A17-4482-9C5F-BF15C01E747C}.Debug|x64.ActiveCfg = Debug|x64
|
||||
|
||||
@ -44,6 +44,14 @@
|
||||
#if defined(_WIN64)
|
||||
#pragma comment(lib, "../../build/bin/icu/win_64/icuuc.lib")
|
||||
#elif defined (_WIN32)
|
||||
|
||||
#if defined(_DEBUG)
|
||||
#pragma comment(lib, "../../build/lib/win_32/DEBUG/graphics.lib")
|
||||
#pragma comment(lib, "../../build/lib/win_32/DEBUG/kernel.lib")
|
||||
#else
|
||||
#pragma comment(lib, "../../build/lib/win_32/graphics.lib")
|
||||
#pragma comment(lib, "../../build/lib/win_32/kernel.lib")
|
||||
#endif
|
||||
#pragma comment(lib, "../../build/bin/icu/win_32/icuuc.lib")
|
||||
#endif
|
||||
|
||||
|
||||
@ -47,7 +47,7 @@
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;_UNICODE;UNICODE"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
Detect64BitPortabilityProblems="false"
|
||||
@ -357,46 +357,6 @@
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\Common\DocxFormat\Source\Base\unicode_util.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\UnicodeConverter\UnicodeConverter.cpp"
|
||||
>
|
||||
<FileConfiguration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
UsePrecompiledHeader="0"
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\DesktopEditor\xml\src\xmldom.cpp"
|
||||
>
|
||||
<FileConfiguration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
UsePrecompiledHeader="0"
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\DesktopEditor\xml\src\xmllight.cpp"
|
||||
>
|
||||
<FileConfiguration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
UsePrecompiledHeader="0"
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
</Filter>
|
||||
<File
|
||||
RelativePath="OdfFileTest.cpp"
|
||||
@ -410,6 +370,10 @@
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\Common\DocxFormat\Source\Base\unicode_util.cpp"
|
||||
>
|
||||
</File>
|
||||
</Files>
|
||||
<Globals>
|
||||
</Globals>
|
||||
|
||||
@ -21,14 +21,9 @@ include($$PWD/../../Common/3dParty/boost/boost.pri)
|
||||
|
||||
DEFINES += UNICODE \
|
||||
_UNICODE \
|
||||
_USE_LIBXML2_READER_ \
|
||||
LIBXML_READER_ENABLED \
|
||||
DONT_WRITE_EMBEDDED_FONTS
|
||||
|
||||
INCLUDEPATH += ../include
|
||||
INCLUDEPATH += ../../DesktopEditor/freetype-2.5.2/include
|
||||
INCLUDEPATH += ../../DesktopEditor/xml/libxml2/include
|
||||
INCLUDEPATH += ../../DesktopEditor/xml/build/qt
|
||||
|
||||
CONFIG(debug, debug|release){
|
||||
DEFINES += _DEBUG
|
||||
|
||||
@ -51,7 +51,7 @@
|
||||
#include "oox_rels.h"
|
||||
#include "logging.h"
|
||||
|
||||
#include "../../../DesktopEditor/fontengine/ApplicationFonts.h"
|
||||
#include "../../../DesktopEditor/graphics/pro/Fonts.h"
|
||||
#include "../../../Common/DocxFormat/Source/XML/Utils.h"
|
||||
|
||||
static int current_id_changes = 0;
|
||||
@ -158,7 +158,7 @@ docx_conversion_context::docx_conversion_context(odf_reader::odf_document * OdfD
|
||||
odf_document_ (OdfDocument)
|
||||
{
|
||||
streams_man_ = streams_man::create(temp_stream_);
|
||||
applicationFonts_ = new CApplicationFonts();
|
||||
applicationFonts_ = NSFonts::NSApplication::Create();
|
||||
}
|
||||
docx_conversion_context::~docx_conversion_context()
|
||||
{
|
||||
|
||||
@ -47,7 +47,7 @@
|
||||
#include "oox_conversion_context.h"
|
||||
#include "oox_chart_context.h"
|
||||
|
||||
class CApplicationFonts;
|
||||
#include "../../../DesktopEditor/graphics/pro/Fonts.h"
|
||||
|
||||
namespace cpdoccore {
|
||||
|
||||
@ -758,7 +758,7 @@ private:
|
||||
|
||||
package::docx_document * output_document_;
|
||||
odf_reader::odf_document * odf_document_;
|
||||
CApplicationFonts * applicationFonts_;
|
||||
NSFonts::IApplicationFonts * applicationFonts_;
|
||||
|
||||
std::vector<odf_reader::_property> settings_properties_;
|
||||
|
||||
|
||||
@ -140,7 +140,7 @@ void word_files::update_rels(docx_conversion_context & Context)
|
||||
Context.dump_notes (rels_files_.get_rel_file()->get_rels());
|
||||
}
|
||||
|
||||
void word_files::set_media(mediaitems & _Mediaitems, CApplicationFonts *pAppFonts)
|
||||
void word_files::set_media(mediaitems & _Mediaitems, NSFonts::IApplicationFonts *pAppFonts)
|
||||
{
|
||||
if (_Mediaitems.count_image + _Mediaitems.count_media > 0)
|
||||
{
|
||||
|
||||
@ -40,7 +40,7 @@
|
||||
#include "docx_content_type.h"
|
||||
#include "oox_package.h"
|
||||
|
||||
class CApplicationFonts;
|
||||
#include "../../../DesktopEditor/graphics/pro/Fonts.h"
|
||||
|
||||
namespace cpdoccore {
|
||||
namespace oox {
|
||||
@ -130,7 +130,7 @@ public:
|
||||
void set_numbering (element_ptr Element);
|
||||
void set_settings (element_ptr Element);
|
||||
bool has_numbering ();
|
||||
void set_media (mediaitems & _Mediaitems, CApplicationFonts *pAppFonts);
|
||||
void set_media (mediaitems & _Mediaitems, NSFonts::IApplicationFonts *pAppFonts);
|
||||
void set_headers_footers(headers_footers & HeadersFooters);
|
||||
void set_notes (notes_context & notesContext);
|
||||
void set_comments (comments_context & commentsContext);
|
||||
|
||||
@ -36,8 +36,7 @@
|
||||
|
||||
#include <float.h>
|
||||
|
||||
#include "../../DesktopEditor/fontengine/FontManager.h"
|
||||
#include "../../DesktopEditor/fontengine/ApplicationFonts.h"
|
||||
#include "../../DesktopEditor/graphics/pro/Fonts.h"
|
||||
|
||||
namespace cpdoccore {
|
||||
namespace utils {
|
||||
@ -49,7 +48,7 @@ namespace
|
||||
class MeasureError : public Error {};
|
||||
}
|
||||
|
||||
std::pair<float, float> GetMaxDigitSizePixelsImpl(const std::wstring & fontName, double fontSize, double dpi, long fontStyle, CFontManager *pFontManager)
|
||||
std::pair<float, float> GetMaxDigitSizePixelsImpl(const std::wstring & fontName, double fontSize, double dpi, long fontStyle, NSFonts::IFontManager *pFontManager)
|
||||
{
|
||||
if (pFontManager == NULL) return std::pair<float, float>(7,8);
|
||||
|
||||
@ -102,7 +101,7 @@ std::pair<float, float> GetMaxDigitSizePixelsImpl(const std::wstring & fontName,
|
||||
}
|
||||
|
||||
|
||||
std::pair<float, float> GetMaxDigitSizePixels(const std::wstring & fontName, double fontSize, double dpi, long fontStyle, CApplicationFonts *appFonts)
|
||||
std::pair<float, float> GetMaxDigitSizePixels(const std::wstring & fontName, double fontSize, double dpi, long fontStyle, NSFonts::IApplicationFonts *appFonts)
|
||||
{
|
||||
try
|
||||
{
|
||||
@ -110,13 +109,12 @@ std::pair<float, float> GetMaxDigitSizePixels(const std::wstring & fontName, dou
|
||||
|
||||
if (appFonts)
|
||||
{
|
||||
CFontManager *pFontManager = appFonts->GenerateFontManager();
|
||||
NSFonts::IFontManager *pFontManager = appFonts->GenerateFontManager();
|
||||
|
||||
std::pair<float, float> val = GetMaxDigitSizePixelsImpl(fontName, fontSize, dpi, fontStyle, pFontManager);
|
||||
|
||||
if (pFontManager)
|
||||
{
|
||||
pFontManager->m_pApplication = NULL;
|
||||
{
|
||||
delete pFontManager;
|
||||
}
|
||||
|
||||
|
||||
@ -34,12 +34,15 @@
|
||||
#include <utility>
|
||||
#include <string>
|
||||
|
||||
class CApplicationFonts;
|
||||
namespace NSFonts
|
||||
{
|
||||
class IApplicationFonts;
|
||||
}
|
||||
|
||||
namespace cpdoccore {
|
||||
namespace utils {
|
||||
|
||||
std::pair<float, float> GetMaxDigitSizePixels(const std::wstring & fontName, double fontSize, double dpi, long fontStyle, CApplicationFonts *appFonts);
|
||||
std::pair<float, float> GetMaxDigitSizePixels(const std::wstring & fontName, double fontSize, double dpi, long fontStyle, NSFonts::IApplicationFonts *appFonts);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@ -38,7 +38,7 @@
|
||||
|
||||
#include "mediaitems.h"
|
||||
#include "../../DesktopEditor/common/File.h"
|
||||
#include "../../DesktopEditor/raster/Metafile/MetaFile.h"
|
||||
#include "../../DesktopEditor/graphics/pro/Image.h"
|
||||
#include "../../DesktopEditor/raster/ImageFileFormatChecker.h"
|
||||
#include "../../Common/DocxFormat/Source/Base/Base.h"
|
||||
|
||||
@ -46,17 +46,19 @@ namespace cpdoccore {
|
||||
namespace oox {
|
||||
namespace package {
|
||||
|
||||
static void ConvertSvmToImage(std::wstring &file_svm, std::wstring &file_png, CApplicationFonts *pAppFonts)
|
||||
static void ConvertSvmToImage(std::wstring &file_svm, std::wstring &file_png, NSFonts::IApplicationFonts *pAppFonts)
|
||||
{
|
||||
MetaFile::CMetaFile oMetaFile(pAppFonts);
|
||||
MetaFile::IMetaFile* pMetaFile = MetaFile::Create(pAppFonts);
|
||||
|
||||
if (oMetaFile.LoadFromFile(file_svm.c_str()))
|
||||
if (pMetaFile->LoadFromFile(file_svm.c_str()))
|
||||
{
|
||||
double w, h, x, y;
|
||||
oMetaFile.GetBounds(&x, &y, &w, &h);
|
||||
oMetaFile.ConvertToRaster(file_png.c_str(), 4, w);
|
||||
oMetaFile.Close();
|
||||
pMetaFile->GetBounds(&x, &y, &w, &h);
|
||||
pMetaFile->ConvertToRaster(file_png.c_str(), 4, w);
|
||||
pMetaFile->Close();
|
||||
}
|
||||
|
||||
RELEASEOBJECT(pMetaFile);
|
||||
}
|
||||
|
||||
static std::wstring get_mime_type(const std::wstring & extension)
|
||||
@ -331,7 +333,7 @@ void docProps_files::write(const std::wstring & RootPath)
|
||||
////////////
|
||||
|
||||
|
||||
media::media(mediaitems & _Mediaitems, CApplicationFonts *pAppFonts) : mediaitems_(_Mediaitems), appFonts_(pAppFonts)
|
||||
media::media(mediaitems & _Mediaitems, NSFonts::IApplicationFonts *pAppFonts) : mediaitems_(_Mediaitems), appFonts_(pAppFonts)
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
@ -42,7 +42,10 @@
|
||||
#include "../../../Common/DocxFormat/Source/Base/Base.h"
|
||||
#include "../../../DesktopEditor/common/Directory.h"
|
||||
|
||||
class CApplicationFonts;
|
||||
namespace NSFonts
|
||||
{
|
||||
class IApplicationFonts;
|
||||
}
|
||||
|
||||
namespace cpdoccore {
|
||||
namespace oox {
|
||||
@ -202,14 +205,14 @@ private:
|
||||
class media : public element
|
||||
{
|
||||
public:
|
||||
media(mediaitems & _Mediaitems, CApplicationFonts *pAppFonts);
|
||||
media(mediaitems & _Mediaitems, NSFonts::IApplicationFonts *pAppFonts);
|
||||
|
||||
public:
|
||||
virtual void write(const std::wstring & RootPath);
|
||||
|
||||
private:
|
||||
mediaitems & mediaitems_;
|
||||
CApplicationFonts * appFonts_;
|
||||
NSFonts::IApplicationFonts * appFonts_;
|
||||
|
||||
};
|
||||
|
||||
|
||||
@ -45,7 +45,7 @@
|
||||
|
||||
#include "pptx_default_serializes.h"
|
||||
|
||||
#include "../../DesktopEditor/fontengine/ApplicationFonts.h"
|
||||
#include "../../DesktopEditor/graphics/pro/Fonts.h"
|
||||
|
||||
namespace cpdoccore {
|
||||
|
||||
@ -72,7 +72,7 @@ pptx_conversion_context::pptx_conversion_context( odf_reader::odf_document * odf
|
||||
,last_idx_placeHolder (1)
|
||||
,last_uniq_big_id (1)
|
||||
{
|
||||
applicationFonts_ = new CApplicationFonts();
|
||||
applicationFonts_ = NSFonts::NSApplication::Create();
|
||||
}
|
||||
|
||||
pptx_conversion_context::~pptx_conversion_context()
|
||||
|
||||
@ -44,7 +44,10 @@
|
||||
|
||||
#include "mediaitems.h"
|
||||
|
||||
class CApplicationFonts;
|
||||
namespace NSFonts
|
||||
{
|
||||
class IApplicationFonts;
|
||||
}
|
||||
|
||||
namespace cpdoccore {
|
||||
|
||||
@ -152,7 +155,7 @@ private:
|
||||
|
||||
package::pptx_document * output_document_;
|
||||
odf_reader::odf_document * odf_document_;
|
||||
CApplicationFonts * applicationFonts_;
|
||||
NSFonts::IApplicationFonts * applicationFonts_;
|
||||
|
||||
pptx_slide_context pptx_slide_context_;
|
||||
pptx_text_context pptx_text_context_;
|
||||
|
||||
@ -504,7 +504,7 @@ void ppt_files::add_notesMaster(slide_content_ptr slide)
|
||||
{
|
||||
notesMaster_files_.add_slide(slide);
|
||||
}
|
||||
void ppt_files::set_media(mediaitems & _Mediaitems, CApplicationFonts *pAppFonts)
|
||||
void ppt_files::set_media(mediaitems & _Mediaitems, NSFonts::IApplicationFonts *pAppFonts)
|
||||
{
|
||||
if (_Mediaitems.count_image + _Mediaitems.count_media > 0)
|
||||
{
|
||||
|
||||
@ -35,7 +35,10 @@
|
||||
#include <cpdoccore/CPNoncopyable.h>
|
||||
#include "pptx_comments.h"
|
||||
|
||||
class CApplicationFonts;
|
||||
namespace NSFonts
|
||||
{
|
||||
class IApplicationFonts;
|
||||
}
|
||||
|
||||
namespace cpdoccore {
|
||||
namespace oox {
|
||||
@ -214,7 +217,7 @@ public:
|
||||
void add_notes (slide_content_ptr sheet);
|
||||
void add_notesMaster(slide_content_ptr sheet);
|
||||
|
||||
void set_media(mediaitems & _Mediaitems, CApplicationFonts *pAppFonts);
|
||||
void set_media(mediaitems & _Mediaitems, NSFonts::IApplicationFonts *pAppFonts);
|
||||
void add_charts(chart_content_ptr chart);
|
||||
void add_theme (pptx_xml_theme_ptr theme);
|
||||
|
||||
|
||||
@ -36,6 +36,8 @@
|
||||
|
||||
#include <cpdoccore/utf8cpp/utf8.h>
|
||||
|
||||
#include "../../../DesktopEditor/common/Directory.h"
|
||||
|
||||
namespace cpdoccore {
|
||||
namespace oox {
|
||||
namespace package {
|
||||
@ -275,7 +277,7 @@ void xl_files::add_sheet(sheet_content_ptr sheet)
|
||||
sheets_files_.add_sheet(sheet);
|
||||
}
|
||||
|
||||
void xl_files::set_media(mediaitems & _Mediaitems, CApplicationFonts *pAppFonts)
|
||||
void xl_files::set_media(mediaitems & _Mediaitems, NSFonts::IApplicationFonts *pAppFonts)
|
||||
{
|
||||
if (_Mediaitems.count_image + _Mediaitems.count_media > 0)
|
||||
{
|
||||
|
||||
@ -38,7 +38,10 @@
|
||||
#include "xlsx_drawings.h"
|
||||
#include "xlsx_comments.h"
|
||||
|
||||
class CApplicationFonts;
|
||||
namespace NSFonts
|
||||
{
|
||||
class IApplicationFonts;
|
||||
}
|
||||
|
||||
namespace cpdoccore {
|
||||
namespace oox {
|
||||
@ -222,7 +225,7 @@ public:
|
||||
void set_sharedStrings (element_ptr Element);
|
||||
void set_connections (element_ptr Element);
|
||||
void add_sheet (sheet_content_ptr sheet);
|
||||
void set_media (mediaitems & _Mediaitems, CApplicationFonts *pAppFonts);
|
||||
void set_media (mediaitems & _Mediaitems, NSFonts::IApplicationFonts *pAppFonts);
|
||||
void set_drawings (element_ptr Element);
|
||||
void set_vml_drawings (element_ptr Element);
|
||||
void set_comments (element_ptr Element);
|
||||
|
||||
@ -45,7 +45,7 @@
|
||||
#include "../odf/odfcontext.h"
|
||||
#include "../odf/calcs_styles.h"
|
||||
|
||||
#include "../../DesktopEditor/fontengine/ApplicationFonts.h"
|
||||
#include "../../DesktopEditor/graphics/pro/Fonts.h"
|
||||
|
||||
|
||||
namespace cpdoccore {
|
||||
@ -76,7 +76,7 @@ xlsx_conversion_context::xlsx_conversion_context(odf_reader::odf_document * odfD
|
||||
mediaitems_ (odf_document_->get_folder()),
|
||||
xlsx_drawing_context_handle_(mediaitems_)
|
||||
{
|
||||
applicationFonts_ = new CApplicationFonts();
|
||||
applicationFonts_ = NSFonts::NSApplication::Create();
|
||||
}
|
||||
|
||||
void xlsx_conversion_context::set_output_document (package::xlsx_document * document)
|
||||
|
||||
@ -54,7 +54,10 @@
|
||||
|
||||
#include "mediaitems.h"
|
||||
|
||||
class CApplicationFonts;
|
||||
namespace NSFonts
|
||||
{
|
||||
class IApplicationFonts;
|
||||
}
|
||||
|
||||
namespace cpdoccore {
|
||||
|
||||
@ -194,7 +197,7 @@ private:
|
||||
const odf_reader::office_element *spreadsheet_;
|
||||
odf_reader::odf_document *odf_document_;
|
||||
|
||||
CApplicationFonts *applicationFonts_;
|
||||
NSFonts::IApplicationFonts *applicationFonts_;
|
||||
|
||||
std::vector<xlsx_xml_worksheet_ptr> sheets_;
|
||||
std::vector<oox_chart_context_ptr> charts_;
|
||||
|
||||
@ -51,20 +51,21 @@
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////////
|
||||
#include "../../../DesktopEditor/raster/BgraFrame.h"
|
||||
#include "../../../DesktopEditor/raster/Metafile/MetaFile.h"
|
||||
#include "../../../DesktopEditor/graphics/pro/Image.h"
|
||||
#include "../../../Common/DocxFormat/Source/XML/Utils.h"
|
||||
|
||||
namespace _image_file_
|
||||
{
|
||||
bool GetResolution(const wchar_t* fileName, int & Width, int &Height, CApplicationFonts * appFonts)
|
||||
bool GetResolution(const wchar_t* fileName, int & Width, int &Height, NSFonts::IApplicationFonts* appFonts)
|
||||
{
|
||||
CBgraFrame image;
|
||||
MetaFile::CMetaFile meta_file(appFonts);
|
||||
MetaFile::IMetaFile* meta_file = MetaFile::Create(appFonts);
|
||||
|
||||
if ( meta_file.LoadFromFile(fileName))
|
||||
bool bRet = false;
|
||||
if ( meta_file->LoadFromFile(fileName))
|
||||
{
|
||||
double dX = 0, dY = 0, dW = 0, dH = 0;
|
||||
meta_file.GetBounds(&dX, &dY, &dW, &dH);
|
||||
meta_file->GetBounds(&dX, &dY, &dW, &dH);
|
||||
|
||||
Width = dW;
|
||||
Height = dH;
|
||||
@ -74,13 +75,13 @@ namespace _image_file_
|
||||
Width = image.get_Width();
|
||||
Height = image.get_Height();
|
||||
|
||||
return true;
|
||||
bRet = true;
|
||||
}
|
||||
|
||||
|
||||
return false;
|
||||
RELEASEOBJECT(meta_file);
|
||||
return bRet;
|
||||
}
|
||||
};
|
||||
}
|
||||
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
namespace cpdoccore {
|
||||
|
||||
@ -98,7 +99,7 @@ int get_value_emu(double pt)
|
||||
{
|
||||
return static_cast<int>((pt* 360000 * 2.54) / 72);
|
||||
}
|
||||
bool parse_clipping(std::wstring strClipping,std::wstring fileName, double_4 & clip_rect, CApplicationFonts * appFonts)
|
||||
bool parse_clipping(std::wstring strClipping,std::wstring fileName, double_4 & clip_rect, NSFonts::IApplicationFonts * appFonts)
|
||||
{
|
||||
memset(clip_rect, 0, 4*sizeof(double));
|
||||
|
||||
|
||||
@ -50,11 +50,9 @@
|
||||
#include "datatypes/targetframename.h"
|
||||
#include "datatypes/common_attlists.h"
|
||||
|
||||
//class CApplicationFonts;
|
||||
|
||||
namespace _image_file_
|
||||
{
|
||||
bool GetResolution(const wchar_t* fileName, int & Width, int &Height, CApplicationFonts * appFonts);
|
||||
bool GetResolution(const wchar_t* fileName, int & Width, int &Height, NSFonts::IApplicationFonts * appFonts);
|
||||
}
|
||||
|
||||
namespace cpdoccore {
|
||||
@ -76,7 +74,7 @@ void Compute_GraphicFill(const odf_types::common_draw_fill_attlist & props,
|
||||
const office_element_ptr & style_image, styles_lite_container &styles, oox::_oox_fill & fill, bool txbx = false);
|
||||
|
||||
typedef double double_4[4];
|
||||
bool parse_clipping(std::wstring strClipping,std::wstring fileName,double_4 & clip_rect, CApplicationFonts * appFonts);
|
||||
bool parse_clipping(std::wstring strClipping,std::wstring fileName,double_4 & clip_rect, NSFonts::IApplicationFonts * appFonts);
|
||||
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
class draw_a : public office_element_impl<draw_a>
|
||||
{
|
||||
@ -118,4 +116,4 @@ void oox_convert_transforms(std::wstring transformStr,std::vector<odf_reader::_p
|
||||
//void docx_convert_transforms(std::wstring transformStr, oox::xlsx_conversion_context & Context);
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -148,8 +148,8 @@ odf_document::Impl::Impl(xml::sax * Reader, const std::wstring & tempPath):
|
||||
}
|
||||
}
|
||||
|
||||
odf_document::Impl::Impl(const std::wstring & srcPath, const std::wstring & tempPath, const std::wstring & Password, const ProgressCallback* CallBack) :
|
||||
context_(new odf_read_context()), pCallBack(CallBack), bUserStopConvert (0), bError(false)
|
||||
odf_document::Impl::Impl(const std::wstring & srcPath, const std::wstring & tempPath, const std::wstring & password, const ProgressCallback* callBack) :
|
||||
context_(new odf_read_context()), pCallBack(callBack), bUserStopConvert (0), bError(false)
|
||||
{
|
||||
office_mime_type_ = 0;
|
||||
|
||||
@ -178,12 +178,12 @@ odf_document::Impl::Impl(const std::wstring & srcPath, const std::wstring & temp
|
||||
|
||||
if (false == map_encryptions_.empty())
|
||||
{
|
||||
if (Password.empty()) return;
|
||||
if (password.empty()) return;
|
||||
|
||||
//decrypt files
|
||||
tmp_folder_ = NSDirectory::CreateDirectoryWithUniqueName(tempPath);
|
||||
|
||||
bError = !decrypt_folder(base_folder_, tmp_folder_);
|
||||
bError = !decrypt_folder(password, base_folder_, tmp_folder_);
|
||||
|
||||
if (bError)
|
||||
return;
|
||||
@ -248,7 +248,7 @@ odf_document::Impl::~Impl()
|
||||
NSDirectory::DeleteDirectory(tmp_folder_);
|
||||
}
|
||||
|
||||
bool odf_document::Impl::decrypt_folder (const std::wstring & srcPath, const std::wstring & dstPath)
|
||||
bool odf_document::Impl::decrypt_folder (const std::wstring &password, const std::wstring & srcPath, const std::wstring & dstPath)
|
||||
{
|
||||
std::vector<std::wstring> arFiles = NSDirectory::GetFiles(srcPath, false);
|
||||
std::vector<std::wstring> arDirectories = NSDirectory::GetDirectories(srcPath);
|
||||
@ -261,7 +261,7 @@ bool odf_document::Impl::decrypt_folder (const std::wstring & srcPath, const std
|
||||
std::map<std::wstring, std::pair<office_element_ptr, int>>::iterator pFind = map_encryptions_.find(arFiles[i]);
|
||||
if ( pFind != map_encryptions_.end() )
|
||||
{
|
||||
result = decrypt_file(arFiles[i], dstPath + FILE_SEPARATOR_STR + sFileName, pFind->second.first, pFind->second.second);
|
||||
result = decrypt_file(password, arFiles[i], dstPath + FILE_SEPARATOR_STR + sFileName, pFind->second.first, pFind->second.second);
|
||||
|
||||
if (false == result)
|
||||
break;
|
||||
@ -277,7 +277,7 @@ bool odf_document::Impl::decrypt_folder (const std::wstring & srcPath, const std
|
||||
|
||||
NSDirectory::CreateDirectory(dstPath + FILE_SEPARATOR_STR + sDirName);
|
||||
|
||||
result = decrypt_folder(arDirectories[i], dstPath + FILE_SEPARATOR_STR + sDirName);
|
||||
result = decrypt_folder(password, arDirectories[i], dstPath + FILE_SEPARATOR_STR + sDirName);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
@ -297,72 +297,120 @@ std::string DecodeBase64(const std::wstring & value1)
|
||||
}
|
||||
return result;
|
||||
}
|
||||
bool odf_document::Impl::decrypt_file (const std::wstring & srcPath, const std::wstring & dstPath, office_element_ptr data, int size )
|
||||
bool odf_document::Impl::decrypt_file (const std::wstring &password, const std::wstring & srcPath, const std::wstring & dstPath, office_element_ptr element, int file_size )
|
||||
{
|
||||
manifest_encryption_data* encryption_data = dynamic_cast<manifest_encryption_data*>(data.get());
|
||||
manifest_encryption_data* encryption_data = dynamic_cast<manifest_encryption_data*>(element.get());
|
||||
if (!encryption_data) return false;
|
||||
|
||||
//std::wstring checksum_;
|
||||
//std::wstring checksum_type_;
|
||||
|
||||
manifest_algorithm* algorithm = dynamic_cast<manifest_algorithm*>(encryption_data->algorithm_.get());
|
||||
manifest_key_derivation* key_derivation = dynamic_cast<manifest_key_derivation*>(encryption_data->key_derivation_.get());
|
||||
manifest_start_key_generation* start_key_generation = dynamic_cast<manifest_start_key_generation*>(encryption_data->start_key_generation_.get());
|
||||
|
||||
CRYPT::ODFDecryptor decryptor;
|
||||
CRYPT::_odfCryptData cryptData;
|
||||
|
||||
cryptData.saltValue = DecodeBase64(key_derivation->salt_);
|
||||
cryptData.saltSize = cryptData.saltValue.length();
|
||||
|
||||
cryptData.hashSize = start_key_generation->key_size_;
|
||||
|
||||
cryptData.checksumData = DecodeBase64(encryption_data->checksum_);
|
||||
cryptData.initializationVector = DecodeBase64(algorithm->initialisation_vector_);
|
||||
|
||||
//------------------------------------------------------------------------------------------
|
||||
cryptData.hashAlgorithm = CRYPT_METHOD::SHA256;
|
||||
cryptData.spinCount = key_derivation->iteration_count_;
|
||||
cryptData.cipherAlgorithm = CRYPT_METHOD::AES_CBC;
|
||||
cryptData.keySize = 256 /8;
|
||||
|
||||
decryptor.SetCryptData(cryptData);
|
||||
|
||||
if (!decryptor.SetPassword(L"password"))
|
||||
if (key_derivation)
|
||||
{
|
||||
return false;
|
||||
cryptData.saltValue = DecodeBase64(key_derivation->salt_);
|
||||
cryptData.spinCount = key_derivation->iteration_count_;
|
||||
cryptData.keySize = key_derivation->key_size_;
|
||||
}
|
||||
//------------------------------------------------------------------------------------------
|
||||
if (start_key_generation)
|
||||
{
|
||||
if (std::wstring::npos != start_key_generation->start_key_generation_name_.find(L"sha"))
|
||||
{
|
||||
if (std::wstring::npos != start_key_generation->start_key_generation_name_.find(L"512"))
|
||||
{
|
||||
cryptData.start_hashAlgorithm = CRYPT_METHOD::SHA512;
|
||||
}
|
||||
if (std::wstring::npos != start_key_generation->start_key_generation_name_.find(L"256"))
|
||||
{
|
||||
cryptData.start_hashAlgorithm = CRYPT_METHOD::SHA256;
|
||||
}
|
||||
}
|
||||
cryptData.start_hashSize = start_key_generation->key_size_;
|
||||
}
|
||||
//------------------------------------------------------------------------------------------
|
||||
if (algorithm)
|
||||
{
|
||||
cryptData.initializationVector = DecodeBase64(algorithm->initialisation_vector_);
|
||||
|
||||
if (std::wstring::npos != algorithm->algorithm_name_.find(L"aes"))
|
||||
{
|
||||
if (std::wstring::npos != algorithm->algorithm_name_.find(L"cbc"))
|
||||
cryptData.cipherAlgorithm = CRYPT_METHOD::AES_CBC;
|
||||
else
|
||||
cryptData.cipherAlgorithm = CRYPT_METHOD::AES_ECB;//??
|
||||
}
|
||||
else if (std::wstring::npos != algorithm->algorithm_name_.find(L"blowfish"))
|
||||
{
|
||||
cryptData.cipherAlgorithm = CRYPT_METHOD::Blowfish_CFB;
|
||||
}
|
||||
}
|
||||
//------------------------------------------------------------------------------------------
|
||||
if (encryption_data)
|
||||
{
|
||||
cryptData.checksum = DecodeBase64(encryption_data->checksum_);
|
||||
|
||||
cryptData.checksum_hashAlgorithm = CRYPT_METHOD::SHA1;
|
||||
if (std::wstring::npos != encryption_data->checksum_type_.find(L"sha"))
|
||||
{
|
||||
if (std::wstring::npos != encryption_data->checksum_type_.find(L"512"))
|
||||
{
|
||||
cryptData.checksum_hashAlgorithm = CRYPT_METHOD::SHA512;
|
||||
}
|
||||
if (std::wstring::npos != encryption_data->checksum_type_.find(L"256"))
|
||||
{
|
||||
cryptData.checksum_hashAlgorithm = CRYPT_METHOD::SHA256;
|
||||
}
|
||||
}
|
||||
|
||||
size_t nPosChecksumSize = encryption_data->checksum_type_.find(L"-");
|
||||
if (std::wstring::npos == nPosChecksumSize)
|
||||
nPosChecksumSize = encryption_data->checksum_type_.find(L"/");
|
||||
if (std::wstring::npos != nPosChecksumSize)
|
||||
{
|
||||
std::wstring strSize = encryption_data->checksum_type_.substr(nPosChecksumSize + 1);
|
||||
if (strSize == L"1k")
|
||||
{
|
||||
cryptData.checksum_size = 1024;
|
||||
}
|
||||
else
|
||||
{
|
||||
//???
|
||||
}
|
||||
}
|
||||
}
|
||||
//------------------------------------------------------------------------------------------------------------
|
||||
bool result = false;
|
||||
|
||||
NSFile::CFileBinary file_inp;
|
||||
if (file_inp.OpenFile(srcPath))
|
||||
|
||||
if (false == file_inp.OpenFile(srcPath))
|
||||
return false;
|
||||
|
||||
DWORD dwSizeRead = 0;
|
||||
_UINT64 lengthRead = file_inp.GetFileSize();
|
||||
|
||||
unsigned char* data = new unsigned char[lengthRead];
|
||||
unsigned char* data_out = NULL;
|
||||
|
||||
file_inp.ReadFile(data, lengthRead, dwSizeRead);
|
||||
file_inp.CloseFile();
|
||||
//------------------------------------------------------------------------------------------
|
||||
CRYPT::ODFDecryptor decryptor;
|
||||
decryptor.SetCryptData(cryptData);
|
||||
|
||||
bool result = decryptor.Decrypt(password, data, dwSizeRead, data_out, file_size);
|
||||
delete []data;
|
||||
|
||||
//------------------------------------------------------------------------------------------------------------
|
||||
if (result && data_out)
|
||||
{
|
||||
_UINT64 lengthData, lengthRead = file_inp.GetFileSize();
|
||||
|
||||
unsigned char* data = new unsigned char[lengthRead];
|
||||
unsigned char* data_out = NULL;
|
||||
DWORD dwSizeRead = 0;
|
||||
|
||||
int readTrue = file_inp.ReadFile(data, lengthRead, dwSizeRead);
|
||||
int readData = readTrue - 8;
|
||||
|
||||
lengthData = *((_UINT64*)data);
|
||||
|
||||
decryptor.Decrypt(data + 8, readData, data_out, 0);//todoo сделать покусочное чтение декриптование
|
||||
|
||||
if (data_out)
|
||||
{
|
||||
NSFile::CFileBinary file_out;
|
||||
file_out.CreateFileW(dstPath);
|
||||
file_out.WriteFile(data_out, lengthData);
|
||||
file_out.CloseFile();
|
||||
|
||||
delete []data_out;
|
||||
result = true;
|
||||
}
|
||||
|
||||
delete []data;
|
||||
NSFile::CFileBinary file_out;
|
||||
file_out.CreateFileW(dstPath);
|
||||
file_out.WriteFile(data_out, file_size);
|
||||
file_out.CloseFile();
|
||||
|
||||
delete []data_out;
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
@ -97,8 +97,8 @@ private:
|
||||
void parse_manifests(office_element *element);
|
||||
void parse_settings (office_element *element);
|
||||
|
||||
bool decrypt_folder (const std::wstring & srcPath, const std::wstring & dstPath);
|
||||
bool decrypt_file (const std::wstring & srcPath, const std::wstring & dstPath, office_element_ptr data, int size );
|
||||
bool decrypt_folder (const std::wstring &password, const std::wstring & srcPath, const std::wstring & dstPath);
|
||||
bool decrypt_file (const std::wstring &password, const std::wstring & srcPath, const std::wstring & dstPath, office_element_ptr data, int size );
|
||||
|
||||
content_xml_t_ptr content_xml_;
|
||||
content_xml_t_ptr styles_xml_;
|
||||
|
||||
@ -158,6 +158,13 @@ void manifest_encryption_data::add_attributes( const xml::attributes_wc_ptr & At
|
||||
{
|
||||
CP_APPLY_ATTR(L"manifest:checksum", checksum_, std::wstring(L""));
|
||||
CP_APPLY_ATTR(L"manifest:checksum-type", checksum_type_, std::wstring(L""));
|
||||
|
||||
size_t nFind = checksum_type_.find(L"#");
|
||||
if (nFind != std::wstring::npos)
|
||||
{
|
||||
checksum_type_ = checksum_type_.substr(nFind + 1);
|
||||
}
|
||||
checksum_type_ = XmlUtils::GetLower(checksum_type_);
|
||||
}
|
||||
void manifest_encryption_data::add_child_element(cpdoccore::xml::sax *Reader, const std::wstring &Ns, const std::wstring &Name)
|
||||
{
|
||||
@ -181,8 +188,15 @@ const wchar_t * manifest_algorithm::name = L"algorithm";
|
||||
|
||||
void manifest_algorithm::add_attributes( const xml::attributes_wc_ptr & Attributes )
|
||||
{
|
||||
CP_APPLY_ATTR(L"manifest:algorithm-name", algorithm_name, std::wstring(L""));
|
||||
CP_APPLY_ATTR(L"manifest:algorithm-name", algorithm_name_, std::wstring(L""));
|
||||
CP_APPLY_ATTR(L"manifest:initialisation-vector", initialisation_vector_, std::wstring(L""));
|
||||
|
||||
size_t nFind = algorithm_name_.find(L"#");
|
||||
if (nFind != std::wstring::npos)
|
||||
{
|
||||
algorithm_name_ = algorithm_name_.substr(nFind + 1);
|
||||
}
|
||||
algorithm_name_ = XmlUtils::GetLower(algorithm_name_);
|
||||
}
|
||||
// manifest:key-derivation
|
||||
//////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
@ -193,8 +207,15 @@ void manifest_key_derivation::add_attributes( const xml::attributes_wc_ptr & Att
|
||||
{
|
||||
CP_APPLY_ATTR(L"manifest:key-derivation-name", key_derivation_name_, std::wstring(L""));
|
||||
CP_APPLY_ATTR(L"manifest:key-size", key_size_, 16);
|
||||
CP_APPLY_ATTR(L"manifest:iteration-count", iteration_count_, 100000);
|
||||
CP_APPLY_ATTR(L"manifest:iteration-count", iteration_count_, 1024);
|
||||
CP_APPLY_ATTR(L"manifest:salt", salt_, std::wstring(L""));
|
||||
|
||||
size_t nFind = key_derivation_name_.find(L"#");
|
||||
if (nFind != std::wstring::npos)
|
||||
{
|
||||
key_derivation_name_ = key_derivation_name_.substr(nFind + 1);
|
||||
}
|
||||
key_derivation_name_ = XmlUtils::GetLower(key_derivation_name_);
|
||||
}
|
||||
// manifest:start-key-generation
|
||||
//////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
@ -205,6 +226,13 @@ void manifest_start_key_generation::add_attributes( const xml::attributes_wc_ptr
|
||||
{
|
||||
CP_APPLY_ATTR(L"manifest:start-key-generation-name", start_key_generation_name_, std::wstring(L""));
|
||||
CP_APPLY_ATTR(L"manifest:key-size", key_size_, 20);
|
||||
|
||||
size_t nFind = start_key_generation_name_.find(L"#");
|
||||
if (nFind != std::wstring::npos)
|
||||
{
|
||||
start_key_generation_name_ = start_key_generation_name_.substr(nFind + 1);
|
||||
}
|
||||
start_key_generation_name_ = XmlUtils::GetLower(start_key_generation_name_);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -253,7 +253,7 @@ public:
|
||||
|
||||
CPDOCCORE_DEFINE_VISITABLE();
|
||||
|
||||
std::wstring algorithm_name;
|
||||
std::wstring algorithm_name_;
|
||||
std::wstring initialisation_vector_;
|
||||
};
|
||||
CP_REGISTER_OFFICE_ELEMENT2(manifest_algorithm);
|
||||
|
||||
@ -109,14 +109,20 @@ namespace svg_path
|
||||
aChar = rStr[++io_rPos];
|
||||
}
|
||||
}
|
||||
|
||||
bool result = false;
|
||||
if(!sNumberString.empty())
|
||||
{
|
||||
o_fRetval = boost::lexical_cast<double>(sNumberString);
|
||||
return true;
|
||||
try
|
||||
{
|
||||
o_fRetval = boost::lexical_cast<double>(sNumberString);
|
||||
result = true;
|
||||
}
|
||||
catch(...)
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
return result;
|
||||
}
|
||||
|
||||
bool importDoubleAndSpaces( double& o_fRetval, int& io_rPos, const std::wstring& rStr, const int nLen )
|
||||
|
||||
@ -34,7 +34,6 @@
|
||||
#include "../../../Common/DocxFormat/Source/Base/Nullable.h"
|
||||
|
||||
#include "../../../DesktopEditor/xml/include/xmlutils.h"
|
||||
#include "../../../DesktopEditor/xml/src/xmllight_private.h"
|
||||
|
||||
#include "../../include/cpdoccore/xml/sax.h"
|
||||
|
||||
@ -73,7 +72,7 @@ public:
|
||||
virtual NodeType next(int Depth);
|
||||
|
||||
private:
|
||||
smart_ptr< XmlUtils::CXmlLiteReader_Private > xml_;
|
||||
smart_ptr< XmlUtils::CXmlLiteReader > xml_;
|
||||
|
||||
};
|
||||
|
||||
@ -113,7 +112,7 @@ namespace
|
||||
|
||||
saxXmlLiteReader::saxXmlLiteReader(const wchar_t * FileName)
|
||||
{
|
||||
xml_ = new XmlUtils::CXmlLiteReader_Private();
|
||||
xml_ = new XmlUtils::CXmlLiteReader();
|
||||
|
||||
xml_->FromFile(FileName);
|
||||
|
||||
@ -157,20 +156,14 @@ std::wstring saxXmlLiteReader::namespacePrefix()
|
||||
{
|
||||
if (xml_.IsInit() == false) return _T("");
|
||||
|
||||
xmlChar* pName = xmlTextReaderPrefix(xml_->getNativeReader());
|
||||
if (NULL == pName)
|
||||
return L"";
|
||||
|
||||
std::wstring sTemp = NSFile::CUtf8Converter::GetUnicodeStringFromUTF8((BYTE*)pName, (LONG)strlen((const char*)pName));
|
||||
free(pName);
|
||||
return sTemp;
|
||||
return xml_->GetNamespacePrefix();
|
||||
}
|
||||
|
||||
NodeType saxXmlLiteReader::nodeType()
|
||||
{
|
||||
if (xml_.IsInit() == false) return typeNone;
|
||||
|
||||
XmlUtils::XmlNodeType nTempType = (XmlUtils::XmlNodeType)xmlTextReaderNodeType(xml_->getNativeReader());
|
||||
XmlUtils::XmlNodeType nTempType = xml_->GetNodeType();
|
||||
return NodeTypeConvert(nTempType);
|
||||
}
|
||||
|
||||
@ -214,14 +207,14 @@ bool saxXmlLiteReader::attrDefault()
|
||||
{
|
||||
if (xml_.IsInit() == false) return false;
|
||||
|
||||
return (FALSE != xmlTextReaderIsDefault(xml_->getNativeReader()));
|
||||
return xml_->IsDefaultAttribute();
|
||||
}
|
||||
|
||||
NodeType saxXmlLiteReader::next(int Depth)
|
||||
{
|
||||
if (xml_->ReadNextSiblingNode2(Depth))
|
||||
{
|
||||
XmlUtils::XmlNodeType nTempType = (XmlUtils::XmlNodeType)xmlTextReaderNodeType(xml_->getNativeReader());
|
||||
XmlUtils::XmlNodeType nTempType = xml_->GetNodeType();
|
||||
return NodeTypeConvert(nTempType);
|
||||
}
|
||||
else
|
||||
|
||||
@ -47,7 +47,7 @@
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
PrecompiledHeaderThrough=""
|
||||
WarningLevel="3"
|
||||
|
||||
@ -47,7 +47,7 @@
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;USE_LITE_READER;_USE_XMLLITE_READER_;_USE_LIBXML2_READER_;LIBXML_READER_ENABLED"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
PrecompiledHeaderThrough=""
|
||||
WarningLevel="3"
|
||||
|
||||
@ -47,7 +47,7 @@
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;USE_LITE_READER;_USE_XMLLITE_READER_;_USE_LIBXML2_READER_;LIBXML_READER_ENABLED"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
PrecompiledHeaderThrough=""
|
||||
WarningLevel="3"
|
||||
|
||||
@ -45,7 +45,7 @@
|
||||
AdditionalIncludeDirectories=""
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
RuntimeLibrary="3"
|
||||
WarningLevel="3"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="4"
|
||||
|
||||
@ -46,6 +46,16 @@
|
||||
#if defined(_WIN64)
|
||||
#pragma comment(lib, "../../build/bin/icu/win_64/icuuc.lib")
|
||||
#elif defined (_WIN32)
|
||||
|
||||
#if defined(_DEBUG)
|
||||
#pragma comment(lib, "../../build/lib/win_32/DEBUG/graphics.lib")
|
||||
#pragma comment(lib, "../../build/lib/win_32/DEBUG/kernel.lib")
|
||||
#pragma comment(lib, "../../build/lib/win_32/DEBUG/UnicodeConverter.lib")
|
||||
#else
|
||||
#pragma comment(lib, "../../build/lib/win_32/graphics.lib")
|
||||
#pragma comment(lib, "../../build/lib/win_32/kernel.lib")
|
||||
#pragma comment(lib, "../../build/lib/win_32/UnicodeConverter.lib")
|
||||
#endif
|
||||
#pragma comment(lib, "../../build/bin/icu/win_32/icuuc.lib")
|
||||
#endif
|
||||
|
||||
@ -86,14 +96,16 @@ HRESULT convert_single(std::wstring srcFileName)
|
||||
|
||||
Oox2Odf::Converter converter(srcTempPath, type, L"C:\\Windows\\Fonts", NULL);
|
||||
|
||||
std::wstring sPassword = L"password";
|
||||
|
||||
converter.convert();
|
||||
converter.write(dstTempPath);
|
||||
converter.write(dstTempPath, srcTempPath, sPassword);
|
||||
|
||||
NSDirectory::DeleteDirectory(srcTempPath);
|
||||
|
||||
if (hr != S_OK) return hr;
|
||||
|
||||
if (S_OK != oCOfficeUtils.CompressFileOrDirectory(dstTempPath.c_str(), dstPath.c_str(), -1))
|
||||
if (S_OK != oCOfficeUtils.CompressFileOrDirectory(dstTempPath.c_str(), dstPath.c_str(), false, sPassword.empty() ? Z_DEFLATED : 0))
|
||||
return hr;
|
||||
|
||||
NSDirectory::DeleteDirectory(dstTempPath);
|
||||
|
||||
@ -7,86 +7,39 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Oox2OdfConverter", "..\sour
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "OdfFileWriterTest", "OdfFileWTest.vcproj", "{FBA8446A-150F-4A10-B4DA-1022048D6473}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2} = {37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}
|
||||
{609ED938-3CA8-4BED-B363-25096D4C4812} = {609ED938-3CA8-4BED-B363-25096D4C4812}
|
||||
{BEE01B53-244A-44E6-8947-ED9342D9247E} = {BEE01B53-244A-44E6-8947-ED9342D9247E}
|
||||
{E5A67556-44DA-4481-8F87-0A3AEDBD20DD} = {E5A67556-44DA-4481-8F87-0A3AEDBD20DD}
|
||||
{94954A67-A853-43B1-A727-6EF2774C5A6A} = {94954A67-A853-43B1-A727-6EF2774C5A6A}
|
||||
{36636678-AE25-4BE6-9A34-2561D1BCF302} = {36636678-AE25-4BE6-9A34-2561D1BCF302}
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540} = {9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363} = {F8274B05-168E-4D6E-B843-AA7510725363}
|
||||
{3423EC9A-52E4-4A4D-9753-EDEBC38785EF} = {3423EC9A-52E4-4A4D-9753-EDEBC38785EF}
|
||||
{94954A67-A853-43B1-A727-6EF2774C5A6A} = {94954A67-A853-43B1-A727-6EF2774C5A6A}
|
||||
{E5A67556-44DA-4481-8F87-0A3AEDBD20DD} = {E5A67556-44DA-4481-8F87-0A3AEDBD20DD}
|
||||
{BEE01B53-244A-44E6-8947-ED9342D9247E} = {BEE01B53-244A-44E6-8947-ED9342D9247E}
|
||||
{A100103A-353E-45E8-A9B8-90B87CC5C0B0} = {A100103A-353E-45E8-A9B8-90B87CC5C0B0}
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0} = {21663823-DE45-479B-91D0-B4FEF4916EF0}
|
||||
{609ED938-3CA8-4BED-B363-25096D4C4812} = {609ED938-3CA8-4BED-B363-25096D4C4812}
|
||||
{C27E9A9F-3A17-4482-9C5F-BF15C01E747C} = {C27E9A9F-3A17-4482-9C5F-BF15C01E747C}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DocxFormat", "..\..\Common\DocxFormat\Projects\DocxFormat2005.vcproj", "{A100103A-353E-45E8-A9B8-90B87CC5C0B0}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "OdfFormulasConvert", "..\..\ASCOfficeOdfFile\win32\formulasconvert.vcproj", "{94954A67-A853-43B1-A727-6EF2774C5A6A}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "graphics", "..\..\DesktopEditor\graphics\graphics_vs2005.vcproj", "{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56} = {C739151F-5384-41DF-A1A6-F089E2C1AD56}
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD} = {617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36} = {BC52A07C-A797-423D-8C4F-8678805BBB36}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "OdfCommon", "..\..\ASCOfficeOdfFile\win32\cpcommon.vcproj", "{609ED938-3CA8-4BED-B363-25096D4C4812}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "raster", "..\..\DesktopEditor\raster\raster_vs2005.vcproj", "{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1} = {EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36} = {BC52A07C-A797-423D-8C4F-8678805BBB36}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "jbig2", "..\..\DesktopEditor\raster\JBig2\win32\jbig2.vcproj", "{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "cximage", "..\..\DesktopEditor\cximage\CxImage\cximage_vs2005.vcproj", "{BC52A07C-A797-423D-8C4F-8678805BBB36}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7} = {43A0E60E-5C4A-4C09-A29B-7683F503BBD7}
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239} = {764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169} = {DF861D33-9BC1-418C-82B1-581F590FE169}
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3} = {0588563C-F05C-428C-B21A-DD74756628B3}
|
||||
{40A69F40-063E-43FD-8543-455495D8733E} = {40A69F40-063E-43FD-8543-455495D8733E}
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E} = {9A037A69-D1DF-4505-AB2A-6CB3641C476E}
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D} = {FFDA5DA1-BB65-4695-B678-BE59B4A1355D}
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470} = {818753F2-DBB9-4D3B-898A-A604309BE470}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "jasper", "..\..\DesktopEditor\cximage\jasper\jasper_vs2005.vcproj", "{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "jbig", "..\..\DesktopEditor\cximage\jbig\jbig_vs2005.vcproj", "{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "jpeg", "..\..\DesktopEditor\cximage\jpeg\Jpeg_vs2005.vcproj", "{818753F2-DBB9-4D3B-898A-A604309BE470}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libpsd", "..\..\DesktopEditor\cximage\libpsd\libpsd_vs2005.vcproj", "{9A037A69-D1DF-4505-AB2A-6CB3641C476E}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "mng", "..\..\DesktopEditor\cximage\mng\mng_vs2005.vcproj", "{40A69F40-063E-43FD-8543-455495D8733E}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "png", "..\..\DesktopEditor\cximage\png\png_vs2005.vcproj", "{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libdcr", "..\..\DesktopEditor\cximage\raw\libdcr_vs2005.vcproj", "{DF861D33-9BC1-418C-82B1-581F590FE169}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "tiff", "..\..\DesktopEditor\cximage\tiff\Tiff_vs2005.vcproj", "{0588563C-F05C-428C-B21A-DD74756628B3}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "font_engine", "..\..\DesktopEditor\fontengine\font_engine_vs2005.vcproj", "{C739151F-5384-41DF-A1A6-F089E2C1AD56}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B} = {78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "freetype", "..\..\DesktopEditor\freetype-2.5.2\builds\windows\vc2005\freetype.vcproj", "{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "OfficeUtilsLib", "..\..\OfficeUtils\win32\OfficeUtilsLib.vcproj", "{F8274B05-168E-4D6E-B843-AA7510725363}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "agg2d", "..\..\DesktopEditor\agg-2.4\agg_vs2005.vcproj", "{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "PPTXFormat", "..\..\ASCOfficePPTXFile\PPTXLib\PPTXFormat.vcproj", "{36636678-AE25-4BE6-9A34-2561D1BCF302}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libxml2", "..\..\DesktopEditor\xml\build\vs2005\libxml2.vcproj", "{21663823-DE45-479B-91D0-B4FEF4916EF0}"
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "OfficeFileCrypt", "..\..\OfficeCryptReader\win32\ECMACryptReader.vcproj", "{C27E9A9F-3A17-4482-9C5F-BF15C01E747C}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{3423EC9A-52E4-4A4D-9753-EDEBC38785EF} = {3423EC9A-52E4-4A4D-9753-EDEBC38785EF}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "cryptlib", "..\..\Common\3dParty\cryptopp\cryptlib.vcproj", "{3423EC9A-52E4-4A4D-9753-EDEBC38785EF}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Win32 = Debug|Win32
|
||||
Debug|x64 = Debug|x64
|
||||
DLL-Import Debug|Win32 = DLL-Import Debug|Win32
|
||||
DLL-Import Debug|x64 = DLL-Import Debug|x64
|
||||
DLL-Import Release|Win32 = DLL-Import Release|Win32
|
||||
DLL-Import Release|x64 = DLL-Import Release|x64
|
||||
Release|Win32 = Release|Win32
|
||||
Release|x64 = Release|x64
|
||||
EndGlobalSection
|
||||
@ -95,6 +48,14 @@ Global
|
||||
{E5A67556-44DA-4481-8F87-0A3AEDBD20DD}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{E5A67556-44DA-4481-8F87-0A3AEDBD20DD}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{E5A67556-44DA-4481-8F87-0A3AEDBD20DD}.Debug|x64.Build.0 = Debug|x64
|
||||
{E5A67556-44DA-4481-8F87-0A3AEDBD20DD}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{E5A67556-44DA-4481-8F87-0A3AEDBD20DD}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{E5A67556-44DA-4481-8F87-0A3AEDBD20DD}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{E5A67556-44DA-4481-8F87-0A3AEDBD20DD}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{E5A67556-44DA-4481-8F87-0A3AEDBD20DD}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{E5A67556-44DA-4481-8F87-0A3AEDBD20DD}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{E5A67556-44DA-4481-8F87-0A3AEDBD20DD}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{E5A67556-44DA-4481-8F87-0A3AEDBD20DD}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{E5A67556-44DA-4481-8F87-0A3AEDBD20DD}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{E5A67556-44DA-4481-8F87-0A3AEDBD20DD}.Release|Win32.Build.0 = Release|Win32
|
||||
{E5A67556-44DA-4481-8F87-0A3AEDBD20DD}.Release|x64.ActiveCfg = Release|x64
|
||||
@ -103,6 +64,14 @@ Global
|
||||
{BEE01B53-244A-44E6-8947-ED9342D9247E}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{BEE01B53-244A-44E6-8947-ED9342D9247E}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{BEE01B53-244A-44E6-8947-ED9342D9247E}.Debug|x64.Build.0 = Debug|x64
|
||||
{BEE01B53-244A-44E6-8947-ED9342D9247E}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{BEE01B53-244A-44E6-8947-ED9342D9247E}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{BEE01B53-244A-44E6-8947-ED9342D9247E}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{BEE01B53-244A-44E6-8947-ED9342D9247E}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{BEE01B53-244A-44E6-8947-ED9342D9247E}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{BEE01B53-244A-44E6-8947-ED9342D9247E}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{BEE01B53-244A-44E6-8947-ED9342D9247E}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{BEE01B53-244A-44E6-8947-ED9342D9247E}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{BEE01B53-244A-44E6-8947-ED9342D9247E}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{BEE01B53-244A-44E6-8947-ED9342D9247E}.Release|Win32.Build.0 = Release|Win32
|
||||
{BEE01B53-244A-44E6-8947-ED9342D9247E}.Release|x64.ActiveCfg = Release|x64
|
||||
@ -111,6 +80,14 @@ Global
|
||||
{FBA8446A-150F-4A10-B4DA-1022048D6473}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{FBA8446A-150F-4A10-B4DA-1022048D6473}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{FBA8446A-150F-4A10-B4DA-1022048D6473}.Debug|x64.Build.0 = Debug|x64
|
||||
{FBA8446A-150F-4A10-B4DA-1022048D6473}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{FBA8446A-150F-4A10-B4DA-1022048D6473}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{FBA8446A-150F-4A10-B4DA-1022048D6473}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{FBA8446A-150F-4A10-B4DA-1022048D6473}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{FBA8446A-150F-4A10-B4DA-1022048D6473}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{FBA8446A-150F-4A10-B4DA-1022048D6473}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{FBA8446A-150F-4A10-B4DA-1022048D6473}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{FBA8446A-150F-4A10-B4DA-1022048D6473}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{FBA8446A-150F-4A10-B4DA-1022048D6473}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{FBA8446A-150F-4A10-B4DA-1022048D6473}.Release|Win32.Build.0 = Release|Win32
|
||||
{FBA8446A-150F-4A10-B4DA-1022048D6473}.Release|x64.ActiveCfg = Release|x64
|
||||
@ -119,6 +96,14 @@ Global
|
||||
{A100103A-353E-45E8-A9B8-90B87CC5C0B0}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{A100103A-353E-45E8-A9B8-90B87CC5C0B0}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{A100103A-353E-45E8-A9B8-90B87CC5C0B0}.Debug|x64.Build.0 = Debug|x64
|
||||
{A100103A-353E-45E8-A9B8-90B87CC5C0B0}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{A100103A-353E-45E8-A9B8-90B87CC5C0B0}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{A100103A-353E-45E8-A9B8-90B87CC5C0B0}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{A100103A-353E-45E8-A9B8-90B87CC5C0B0}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{A100103A-353E-45E8-A9B8-90B87CC5C0B0}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{A100103A-353E-45E8-A9B8-90B87CC5C0B0}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{A100103A-353E-45E8-A9B8-90B87CC5C0B0}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{A100103A-353E-45E8-A9B8-90B87CC5C0B0}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{A100103A-353E-45E8-A9B8-90B87CC5C0B0}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{A100103A-353E-45E8-A9B8-90B87CC5C0B0}.Release|Win32.Build.0 = Release|Win32
|
||||
{A100103A-353E-45E8-A9B8-90B87CC5C0B0}.Release|x64.ActiveCfg = Release|x64
|
||||
@ -127,162 +112,82 @@ Global
|
||||
{94954A67-A853-43B1-A727-6EF2774C5A6A}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{94954A67-A853-43B1-A727-6EF2774C5A6A}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{94954A67-A853-43B1-A727-6EF2774C5A6A}.Debug|x64.Build.0 = Debug|x64
|
||||
{94954A67-A853-43B1-A727-6EF2774C5A6A}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{94954A67-A853-43B1-A727-6EF2774C5A6A}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{94954A67-A853-43B1-A727-6EF2774C5A6A}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{94954A67-A853-43B1-A727-6EF2774C5A6A}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{94954A67-A853-43B1-A727-6EF2774C5A6A}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{94954A67-A853-43B1-A727-6EF2774C5A6A}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{94954A67-A853-43B1-A727-6EF2774C5A6A}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{94954A67-A853-43B1-A727-6EF2774C5A6A}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{94954A67-A853-43B1-A727-6EF2774C5A6A}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{94954A67-A853-43B1-A727-6EF2774C5A6A}.Release|Win32.Build.0 = Release|Win32
|
||||
{94954A67-A853-43B1-A727-6EF2774C5A6A}.Release|x64.ActiveCfg = Release|x64
|
||||
{94954A67-A853-43B1-A727-6EF2774C5A6A}.Release|x64.Build.0 = Release|x64
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.Debug|x64.Build.0 = Debug|x64
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.Release|Win32.Build.0 = Release|Win32
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.Release|x64.ActiveCfg = Release|x64
|
||||
{37CA072A-5BDE-498B-B3A7-5E404F5F9BF2}.Release|x64.Build.0 = Release|x64
|
||||
{609ED938-3CA8-4BED-B363-25096D4C4812}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{609ED938-3CA8-4BED-B363-25096D4C4812}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{609ED938-3CA8-4BED-B363-25096D4C4812}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{609ED938-3CA8-4BED-B363-25096D4C4812}.Debug|x64.Build.0 = Debug|x64
|
||||
{609ED938-3CA8-4BED-B363-25096D4C4812}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{609ED938-3CA8-4BED-B363-25096D4C4812}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{609ED938-3CA8-4BED-B363-25096D4C4812}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{609ED938-3CA8-4BED-B363-25096D4C4812}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{609ED938-3CA8-4BED-B363-25096D4C4812}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{609ED938-3CA8-4BED-B363-25096D4C4812}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{609ED938-3CA8-4BED-B363-25096D4C4812}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{609ED938-3CA8-4BED-B363-25096D4C4812}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{609ED938-3CA8-4BED-B363-25096D4C4812}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{609ED938-3CA8-4BED-B363-25096D4C4812}.Release|Win32.Build.0 = Release|Win32
|
||||
{609ED938-3CA8-4BED-B363-25096D4C4812}.Release|x64.ActiveCfg = Release|x64
|
||||
{609ED938-3CA8-4BED-B363-25096D4C4812}.Release|x64.Build.0 = Release|x64
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.Debug|x64.Build.0 = Debug|x64
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.Release|Win32.Build.0 = Release|Win32
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.Release|x64.ActiveCfg = Release|x64
|
||||
{9CAA294E-58C3-4CEB-ABA0-CB9786CA5540}.Release|x64.Build.0 = Release|x64
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.Debug|x64.Build.0 = Debug|x64
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.Release|Win32.Build.0 = Release|Win32
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.Release|x64.ActiveCfg = Release|x64
|
||||
{EE1B576A-07C5-4ACC-920F-81C41DD0C8C1}.Release|x64.Build.0 = Release|x64
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.Debug|x64.Build.0 = Debug|x64
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.Release|Win32.Build.0 = Release|Win32
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.Release|x64.ActiveCfg = Release|x64
|
||||
{BC52A07C-A797-423D-8C4F-8678805BBB36}.Release|x64.Build.0 = Release|x64
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.Debug|x64.Build.0 = Debug|x64
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.Release|Win32.Build.0 = Release|Win32
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.Release|x64.ActiveCfg = Release|x64
|
||||
{FFDA5DA1-BB65-4695-B678-BE59B4A1355D}.Release|x64.Build.0 = Release|x64
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.Debug|x64.Build.0 = Debug|x64
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.Release|Win32.Build.0 = Release|Win32
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.Release|x64.ActiveCfg = Release|x64
|
||||
{764C3A2D-FB0F-428E-B1C7-62D1DD2CE239}.Release|x64.Build.0 = Release|x64
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.Debug|x64.Build.0 = Debug|x64
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.Release|Win32.Build.0 = Release|Win32
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.Release|x64.ActiveCfg = Release|x64
|
||||
{818753F2-DBB9-4D3B-898A-A604309BE470}.Release|x64.Build.0 = Release|x64
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.Debug|x64.Build.0 = Debug|x64
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.Release|Win32.Build.0 = Release|Win32
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.Release|x64.ActiveCfg = Release|x64
|
||||
{9A037A69-D1DF-4505-AB2A-6CB3641C476E}.Release|x64.Build.0 = Release|x64
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.Debug|x64.Build.0 = Debug|x64
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.Release|Win32.Build.0 = Release|Win32
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.Release|x64.ActiveCfg = Release|x64
|
||||
{40A69F40-063E-43FD-8543-455495D8733E}.Release|x64.Build.0 = Release|x64
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.Debug|x64.Build.0 = Debug|x64
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.Release|Win32.Build.0 = Release|Win32
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.Release|x64.ActiveCfg = Release|x64
|
||||
{43A0E60E-5C4A-4C09-A29B-7683F503BBD7}.Release|x64.Build.0 = Release|x64
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.Debug|x64.Build.0 = Debug|x64
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.Release|Win32.Build.0 = Release|Win32
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.Release|x64.ActiveCfg = Release|x64
|
||||
{DF861D33-9BC1-418C-82B1-581F590FE169}.Release|x64.Build.0 = Release|x64
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.Debug|x64.Build.0 = Debug|x64
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.Release|Win32.Build.0 = Release|Win32
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.Release|x64.ActiveCfg = Release|x64
|
||||
{0588563C-F05C-428C-B21A-DD74756628B3}.Release|x64.Build.0 = Release|x64
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.Debug|x64.Build.0 = Debug|x64
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.Release|Win32.Build.0 = Release|Win32
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.Release|x64.ActiveCfg = Release|x64
|
||||
{C739151F-5384-41DF-A1A6-F089E2C1AD56}.Release|x64.Build.0 = Release|x64
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.Debug|x64.Build.0 = Debug|x64
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.Release|Win32.Build.0 = Release|Win32
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.Release|x64.ActiveCfg = Release|x64
|
||||
{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}.Release|x64.Build.0 = Release|x64
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.Debug|x64.Build.0 = Debug|x64
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.Release|Win32.Build.0 = Release|Win32
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.Release|x64.ActiveCfg = Release|x64
|
||||
{F8274B05-168E-4D6E-B843-AA7510725363}.Release|x64.Build.0 = Release|x64
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.Debug|x64.Build.0 = Debug|x64
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.Release|Win32.Build.0 = Release|Win32
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.Release|x64.ActiveCfg = Release|x64
|
||||
{617F9069-5E37-4B80-9A3A-E77AFC4CC7AD}.Release|x64.Build.0 = Release|x64
|
||||
{36636678-AE25-4BE6-9A34-2561D1BCF302}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{36636678-AE25-4BE6-9A34-2561D1BCF302}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{36636678-AE25-4BE6-9A34-2561D1BCF302}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{36636678-AE25-4BE6-9A34-2561D1BCF302}.Debug|x64.Build.0 = Debug|x64
|
||||
{36636678-AE25-4BE6-9A34-2561D1BCF302}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{36636678-AE25-4BE6-9A34-2561D1BCF302}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{36636678-AE25-4BE6-9A34-2561D1BCF302}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{36636678-AE25-4BE6-9A34-2561D1BCF302}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{36636678-AE25-4BE6-9A34-2561D1BCF302}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{36636678-AE25-4BE6-9A34-2561D1BCF302}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{36636678-AE25-4BE6-9A34-2561D1BCF302}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{36636678-AE25-4BE6-9A34-2561D1BCF302}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{36636678-AE25-4BE6-9A34-2561D1BCF302}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{36636678-AE25-4BE6-9A34-2561D1BCF302}.Release|Win32.Build.0 = Release|Win32
|
||||
{36636678-AE25-4BE6-9A34-2561D1BCF302}.Release|x64.ActiveCfg = Release|x64
|
||||
{36636678-AE25-4BE6-9A34-2561D1BCF302}.Release|x64.Build.0 = Release|x64
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.Debug|x64.Build.0 = Debug|x64
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.Release|Win32.Build.0 = Release|Win32
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.Release|x64.ActiveCfg = Release|x64
|
||||
{21663823-DE45-479B-91D0-B4FEF4916EF0}.Release|x64.Build.0 = Release|x64
|
||||
{C27E9A9F-3A17-4482-9C5F-BF15C01E747C}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{C27E9A9F-3A17-4482-9C5F-BF15C01E747C}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{C27E9A9F-3A17-4482-9C5F-BF15C01E747C}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{C27E9A9F-3A17-4482-9C5F-BF15C01E747C}.Debug|x64.Build.0 = Debug|x64
|
||||
{C27E9A9F-3A17-4482-9C5F-BF15C01E747C}.DLL-Import Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{C27E9A9F-3A17-4482-9C5F-BF15C01E747C}.DLL-Import Debug|Win32.Build.0 = Debug|Win32
|
||||
{C27E9A9F-3A17-4482-9C5F-BF15C01E747C}.DLL-Import Debug|x64.ActiveCfg = Debug|x64
|
||||
{C27E9A9F-3A17-4482-9C5F-BF15C01E747C}.DLL-Import Debug|x64.Build.0 = Debug|x64
|
||||
{C27E9A9F-3A17-4482-9C5F-BF15C01E747C}.DLL-Import Release|Win32.ActiveCfg = Release|Win32
|
||||
{C27E9A9F-3A17-4482-9C5F-BF15C01E747C}.DLL-Import Release|Win32.Build.0 = Release|Win32
|
||||
{C27E9A9F-3A17-4482-9C5F-BF15C01E747C}.DLL-Import Release|x64.ActiveCfg = Release|x64
|
||||
{C27E9A9F-3A17-4482-9C5F-BF15C01E747C}.DLL-Import Release|x64.Build.0 = Release|x64
|
||||
{C27E9A9F-3A17-4482-9C5F-BF15C01E747C}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{C27E9A9F-3A17-4482-9C5F-BF15C01E747C}.Release|Win32.Build.0 = Release|Win32
|
||||
{C27E9A9F-3A17-4482-9C5F-BF15C01E747C}.Release|x64.ActiveCfg = Release|x64
|
||||
{C27E9A9F-3A17-4482-9C5F-BF15C01E747C}.Release|x64.Build.0 = Release|x64
|
||||
{3423EC9A-52E4-4A4D-9753-EDEBC38785EF}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{3423EC9A-52E4-4A4D-9753-EDEBC38785EF}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{3423EC9A-52E4-4A4D-9753-EDEBC38785EF}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{3423EC9A-52E4-4A4D-9753-EDEBC38785EF}.Debug|x64.Build.0 = Debug|x64
|
||||
{3423EC9A-52E4-4A4D-9753-EDEBC38785EF}.DLL-Import Debug|Win32.ActiveCfg = DLL-Import Debug|Win32
|
||||
{3423EC9A-52E4-4A4D-9753-EDEBC38785EF}.DLL-Import Debug|Win32.Build.0 = DLL-Import Debug|Win32
|
||||
{3423EC9A-52E4-4A4D-9753-EDEBC38785EF}.DLL-Import Debug|x64.ActiveCfg = DLL-Import Debug|x64
|
||||
{3423EC9A-52E4-4A4D-9753-EDEBC38785EF}.DLL-Import Debug|x64.Build.0 = DLL-Import Debug|x64
|
||||
{3423EC9A-52E4-4A4D-9753-EDEBC38785EF}.DLL-Import Release|Win32.ActiveCfg = DLL-Import Release|Win32
|
||||
{3423EC9A-52E4-4A4D-9753-EDEBC38785EF}.DLL-Import Release|Win32.Build.0 = DLL-Import Release|Win32
|
||||
{3423EC9A-52E4-4A4D-9753-EDEBC38785EF}.DLL-Import Release|x64.ActiveCfg = DLL-Import Release|x64
|
||||
{3423EC9A-52E4-4A4D-9753-EDEBC38785EF}.DLL-Import Release|x64.Build.0 = DLL-Import Release|x64
|
||||
{3423EC9A-52E4-4A4D-9753-EDEBC38785EF}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{3423EC9A-52E4-4A4D-9753-EDEBC38785EF}.Release|Win32.Build.0 = Release|Win32
|
||||
{3423EC9A-52E4-4A4D-9753-EDEBC38785EF}.Release|x64.ActiveCfg = Release|x64
|
||||
{3423EC9A-52E4-4A4D-9753-EDEBC38785EF}.Release|x64.Build.0 = Release|x64
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
|
||||
@ -47,7 +47,7 @@
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;USE_LITE_READER;_USE_XMLLITE_READER_;_USE_LIBXML2_READER_;LIBXML_READER_ENABLED;__WORDSIZE=32;DONT_WRITE_EMBEDDED_FONTS"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
ProgramDataBaseFileName="$(IntDir)\OdfFileWriterTest.pdb"
|
||||
WarningLevel="3"
|
||||
@ -67,7 +67,7 @@
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="
Rpcrt4.lib"
|
||||
LinkIncremental="2"
|
||||
IgnoreDefaultLibraryNames="MSVCRTD.lib"
|
||||
IgnoreDefaultLibraryNames=""
|
||||
GenerateDebugInformation="true"
|
||||
SubSystem="1"
|
||||
TargetMachine="1"
|
||||
@ -333,18 +333,6 @@
|
||||
Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
|
||||
UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
|
||||
>
|
||||
<File
|
||||
RelativePath="..\..\Common\FileDownloader\FileDownloader_win.cpp"
|
||||
>
|
||||
<FileConfiguration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
UsePrecompiledHeader="0"
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\Common\3dParty\pole\pole.cpp"
|
||||
>
|
||||
@ -357,42 +345,6 @@
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\UnicodeConverter\UnicodeConverter.cpp"
|
||||
>
|
||||
<FileConfiguration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
UsePrecompiledHeader="0"
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\DesktopEditor\xml\src\xmldom.cpp"
|
||||
>
|
||||
<FileConfiguration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
UsePrecompiledHeader="0"
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\DesktopEditor\xml\src\xmllight.cpp"
|
||||
>
|
||||
<FileConfiguration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
UsePrecompiledHeader="0"
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
<Filter
|
||||
Name="oox"
|
||||
>
|
||||
|
||||
@ -21,14 +21,10 @@ include($$PWD/../../Common/3dParty/boost/boost.pri)
|
||||
|
||||
DEFINES += UNICODE \
|
||||
_UNICODE \
|
||||
_USE_LIBXML2_READER_ \
|
||||
LIBXML_READER_ENABLED \
|
||||
DONT_WRITE_EMBEDDED_FONTS
|
||||
|
||||
INCLUDEPATH += ../../DesktopEditor/freetype-2.5.2/include
|
||||
INCLUDEPATH += ../../ASCOfficeOdfFile/include
|
||||
INCLUDEPATH += ../../ASCOfficeOdfFile/src/odf/datatypes
|
||||
INCLUDEPATH += ../../DesktopEditor/xml/libxml2/include
|
||||
|
||||
CONFIG(debug, debug|release){
|
||||
DEFINES += _DEBUG
|
||||
@ -41,6 +37,8 @@ SOURCES += \
|
||||
|
||||
core_debug {
|
||||
SOURCES += \
|
||||
../source/utils.cpp \
|
||||
../source/OdfFormat/office_document.cpp \
|
||||
../source/OdfFormat/abstract_xml.cpp \
|
||||
../source/OdfFormat/calcext_elements.cpp \
|
||||
../source/OdfFormat/draw_base.cpp \
|
||||
@ -118,6 +116,7 @@ SOURCES += \
|
||||
../source/Oox2OdfConverter/PptxConverter.cpp
|
||||
|
||||
HEADERS += \
|
||||
../source/OdfFormat/office_document.h \
|
||||
../source/OdfFormat/abstract_xml.h \
|
||||
../source/OdfFormat/calcext_elements.h \
|
||||
../source/OdfFormat/draw_base.h \
|
||||
|
||||
@ -29,6 +29,15 @@
|
||||
* terms at http://creativecommons.org/licenses/by-sa/4.0/legalcode
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef min
|
||||
#define min(a,b) ((a) < (b) ? (a) : (b))
|
||||
#endif
|
||||
#ifndef max
|
||||
#define max(a,b) ((a) > (b) ? (a) : (b))
|
||||
#endif
|
||||
|
||||
#include "../source/OdfFormat/office_document.cpp"
|
||||
#include "../source/OdfFormat/calcext_elements.cpp"
|
||||
#include "../source/OdfFormat/draw_base.cpp"
|
||||
#include "../source/OdfFormat/draw_frame.cpp"
|
||||
@ -93,3 +102,4 @@
|
||||
#include "../source/OdfFormat/style_presentation.cpp"
|
||||
#include "../source/OdfFormat/office_scripts.cpp"
|
||||
#include "../source/OdfFormat/office_event_listeners.cpp"
|
||||
#include "../source/utils.cpp"
|
||||
|
||||
@ -40,6 +40,7 @@
|
||||
#include "../../../DesktopEditor/common/Directory.h"
|
||||
|
||||
#include "../../../Common/DocxFormat/Source/SystemUtility/SystemUtility.h"
|
||||
#include "../../../Common/3dParty/cryptopp/osrng.h"
|
||||
|
||||
namespace cpdoccore
|
||||
{
|
||||
@ -56,7 +57,7 @@ namespace odf_writer
|
||||
content_utf8_ = std::string( Content.begin(), Content.end());
|
||||
}
|
||||
|
||||
void simple_element::write(const std::wstring & RootPath)
|
||||
void simple_element::write(const std::wstring & RootPath, bool add_padding)
|
||||
{
|
||||
NSFile::CFileBinary file;
|
||||
|
||||
@ -65,9 +66,34 @@ namespace odf_writer
|
||||
if (utf8_)
|
||||
{
|
||||
std::string root = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>";
|
||||
file.WriteFile((BYTE*)root.c_str(), root.length());
|
||||
file.WriteFile((BYTE*)root.c_str(), (DWORD)root.length());
|
||||
if (add_padding)
|
||||
{
|
||||
CryptoPP::RandomPool prng;
|
||||
|
||||
CryptoPP::SecByteBlock padding(1024);
|
||||
CryptoPP::OS_GenerateRandomBlock(false, padding, padding.size());
|
||||
prng.IncorporateEntropy(padding, padding.size());
|
||||
|
||||
std::string padding_start = "<!-- ";
|
||||
std::string padding_end = "-->";
|
||||
|
||||
file.WriteFile((BYTE*)padding_start.c_str(), (DWORD)padding_start.length());
|
||||
//--------------------------------
|
||||
int nLength = 0;
|
||||
char *pData = NULL;
|
||||
NSFile::CBase64Converter::Encode(padding.data(), padding.size(), pData, nLength, NSBase64::B64_BASE64_FLAG_NOCRLF);
|
||||
if (pData)
|
||||
{
|
||||
file.WriteFile((BYTE*)pData, nLength);
|
||||
delete []pData; pData = NULL;
|
||||
}
|
||||
//--------------------------------
|
||||
file.WriteFile((BYTE*)padding_end.c_str(), (DWORD)padding_end.length());
|
||||
|
||||
}
|
||||
}
|
||||
file.WriteFile((BYTE*)content_utf8_.c_str(), content_utf8_.length());
|
||||
file.WriteFile((BYTE*)content_utf8_.c_str(), (DWORD)content_utf8_.length());
|
||||
|
||||
file.CloseFile();
|
||||
}
|
||||
@ -89,10 +115,9 @@ namespace odf_writer
|
||||
//-------------------------------------------------------------------------------
|
||||
void manifect_file::add_rels(rels & r)
|
||||
{
|
||||
std::vector<relationship> & rels = r.relationships();
|
||||
for (size_t i = 0; i < rels.size(); i++)
|
||||
for (size_t i = 0; i < r.relationships_.size(); i++)
|
||||
{
|
||||
rels_.add(rels[i]);
|
||||
rels_.add(r.relationships_[i]);
|
||||
}
|
||||
}
|
||||
manifect_file::manifect_file(std::wstring t)
|
||||
@ -103,7 +128,7 @@ namespace odf_writer
|
||||
{
|
||||
type_ = t;
|
||||
}
|
||||
void mimetype_file::write(const std::wstring & RootPath)
|
||||
void mimetype_file::write(const std::wstring & RootPath, bool add_padding)
|
||||
{
|
||||
std::wstringstream resStream;
|
||||
|
||||
@ -111,9 +136,9 @@ namespace odf_writer
|
||||
resStream << type_;
|
||||
|
||||
simple_element elm(L"mimetype", resStream.str(),false);
|
||||
elm.write(RootPath);
|
||||
elm.write(RootPath, false);
|
||||
}
|
||||
void manifect_file::write(const std::wstring & RootPath)
|
||||
void manifect_file::write(const std::wstring & RootPath, bool add_padding)
|
||||
{
|
||||
std::wstringstream resStream;
|
||||
|
||||
@ -129,10 +154,10 @@ namespace odf_writer
|
||||
std::wstring path = RootPath + FILE_SEPARATOR_STR + L"META-INF";
|
||||
NSDirectory::CreateDirectory(path);
|
||||
simple_element elm(L"manifest.xml", resStream.str());
|
||||
elm.write(path);
|
||||
elm.write(path, false);
|
||||
}
|
||||
|
||||
void meta_file::write(const std::wstring & RootPath)
|
||||
void meta_file::write(const std::wstring & RootPath, bool add_padding)
|
||||
{
|
||||
std::wstringstream resStream;
|
||||
CP_XML_WRITER(resStream)
|
||||
@ -175,14 +200,14 @@ namespace odf_writer
|
||||
}
|
||||
|
||||
simple_element elm(L"meta.xml", resStream.str());
|
||||
elm.write(RootPath);
|
||||
elm.write(RootPath, add_padding);
|
||||
}
|
||||
//-------------------------------------------------------------------------------
|
||||
media::media(_mediaitems & mediaitems, const std::wstring internal_folder, int type) : mediaitems_(mediaitems), type_(type), folder_(internal_folder)
|
||||
media_files::media_files(_mediaitems & mediaitems, const std::wstring internal_folder, int type) : mediaitems_(mediaitems), type_(type), folder_(internal_folder)
|
||||
{
|
||||
}
|
||||
|
||||
void media::write(const std::wstring & RootPath)
|
||||
void media_files::write(const std::wstring & RootPath, bool add_padding)
|
||||
{
|
||||
OOX::CPath path (RootPath + (folder_.empty() ? L"" : FILE_SEPARATOR_STR) + folder_);
|
||||
NSDirectory::CreateDirectory(path.GetPath());
|
||||
@ -204,48 +229,48 @@ namespace odf_writer
|
||||
//-------------------------------------------------------------------------------
|
||||
void object_files::set_content(content_content_ptr & _content)
|
||||
{
|
||||
content_.set_content(_content);
|
||||
meta_ = element_ptr(new meta_file());
|
||||
content.set_content(_content);
|
||||
meta = element_ptr(new meta_file());
|
||||
}
|
||||
void object_files::set_mediaitems(_mediaitems & mediaitems)
|
||||
{
|
||||
if (mediaitems.count_image > 0)
|
||||
{
|
||||
pictures_ = element_ptr( new media(mediaitems, L"Pictures", 1) );
|
||||
pictures = element_ptr( new media_files(mediaitems, L"Pictures", 1) );
|
||||
}
|
||||
if (mediaitems.count_media > 0)
|
||||
{
|
||||
media_ = element_ptr( new media(mediaitems, L"Media", 2) );
|
||||
media = element_ptr( new media_files(mediaitems, L"Media", 2) );
|
||||
}
|
||||
if (mediaitems.count_object > 0)
|
||||
{
|
||||
oleObjects_ = element_ptr( new media(mediaitems, L"", 3) );
|
||||
oleObjects = element_ptr( new media_files(mediaitems, L"", 3) );
|
||||
}
|
||||
if (mediaitems.count_object > 0)
|
||||
{
|
||||
imageObjects_ = element_ptr( new media(mediaitems, L"ObjectReplacements", 4) );
|
||||
imageObjects = element_ptr( new media_files(mediaitems, L"ObjectReplacements", 4) );
|
||||
}
|
||||
}
|
||||
void object_files::set_styles(content_simple_ptr & _content)
|
||||
{
|
||||
styles_.set_content(_content);
|
||||
styles.set_content(_content);
|
||||
}
|
||||
void object_files::set_settings(content_simple_ptr & _content)
|
||||
{
|
||||
settings_.set_content(_content);
|
||||
settings.set_content(_content);
|
||||
}
|
||||
void object_files::write(const std::wstring & RootPath)
|
||||
void object_files::write(const std::wstring & RootPath, bool add_padding)
|
||||
{
|
||||
content_.write(RootPath);
|
||||
styles_.write(RootPath);
|
||||
settings_.write(RootPath);
|
||||
content.write(RootPath, add_padding);
|
||||
styles.write(RootPath, add_padding);
|
||||
settings.write(RootPath, add_padding);
|
||||
|
||||
if (meta_) meta_->write(RootPath);
|
||||
if (meta) meta->write(RootPath, add_padding);
|
||||
|
||||
if (media_) media_->write(RootPath);
|
||||
if (pictures_) pictures_->write(RootPath);
|
||||
if (oleObjects_) oleObjects_->write(RootPath);
|
||||
if (imageObjects_) imageObjects_->write(RootPath);
|
||||
if (media) media->write(RootPath, add_padding);
|
||||
if (pictures) pictures->write(RootPath, add_padding);
|
||||
if (oleObjects) oleObjects->write(RootPath, add_padding);
|
||||
if (imageObjects) imageObjects->write(RootPath, add_padding);
|
||||
}
|
||||
|
||||
void odf_document::add_object(element_ptr _object, bool root)
|
||||
@ -272,23 +297,30 @@ namespace odf_writer
|
||||
manifest_ = element_ptr(new manifect_file(type));
|
||||
mimetype_ = element_ptr(new mimetype_file(type));
|
||||
}
|
||||
void odf_document::write(const std::wstring & RootPath)
|
||||
void odf_document::write_manifest(const std::wstring & RootPath)
|
||||
{
|
||||
if (base_)base_->write(RootPath);
|
||||
if (mimetype_)
|
||||
mimetype_->write(RootPath);
|
||||
if (manifest_)
|
||||
manifest_->write(RootPath);
|
||||
}
|
||||
void odf_document::write(const std::wstring & RootPath, bool add_padding)
|
||||
{
|
||||
if (base_)base_->write(RootPath, add_padding);
|
||||
|
||||
for (size_t i = 0; i < objects_.size(); i++)
|
||||
{
|
||||
std::wstring path = RootPath + FILE_SEPARATOR_STR + objects_[i]->local_path;
|
||||
NSDirectory::CreateDirectory(path);
|
||||
|
||||
objects_[i]->write(path);
|
||||
objects_[i]->write(path, add_padding);
|
||||
}
|
||||
if (manifest_) manifest_->write(RootPath);
|
||||
if (mimetype_) mimetype_->write(RootPath);
|
||||
if (settings_) settings_->write(RootPath);
|
||||
if (manifest_) manifest_->write(RootPath, add_padding);
|
||||
if (mimetype_) mimetype_->write(RootPath, add_padding);
|
||||
if (settings_) settings_->write(RootPath, add_padding);
|
||||
}
|
||||
|
||||
void content_file::write(const std::wstring & RootPath)
|
||||
void content_file::write(const std::wstring & RootPath, bool add_padding)
|
||||
{
|
||||
std::wstringstream resStream;
|
||||
CP_XML_WRITER(resStream)
|
||||
@ -339,24 +371,24 @@ namespace odf_writer
|
||||
CP_XML_ATTR(L"office:version", L"1.2");
|
||||
|
||||
CP_XML_NODE(L"office:font-face-decls");
|
||||
if (content_)
|
||||
if (content)
|
||||
{
|
||||
CP_XML_STREAM() << content_->styles_str();
|
||||
CP_XML_STREAM() << content->styles_str();
|
||||
}
|
||||
CP_XML_NODE(L"office:body")
|
||||
{
|
||||
if (content_)
|
||||
if (content)
|
||||
{
|
||||
CP_XML_STREAM() << content_->content_str();
|
||||
CP_XML_STREAM() << content->content_str();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
simple_element elm(L"content.xml", resStream.str());
|
||||
elm.write(RootPath);
|
||||
elm.write(RootPath, add_padding);
|
||||
}
|
||||
void styles_file::write(const std::wstring & RootPath)
|
||||
void styles_file::write(const std::wstring & RootPath, bool add_padding)
|
||||
{
|
||||
std::wstringstream resStream;
|
||||
CP_XML_WRITER(resStream)
|
||||
@ -414,9 +446,9 @@ namespace odf_writer
|
||||
}
|
||||
|
||||
simple_element elm(L"styles.xml", resStream.str());
|
||||
elm.write(RootPath);
|
||||
elm.write(RootPath, add_padding);
|
||||
}
|
||||
void settings_file::write(const std::wstring & RootPath)
|
||||
void settings_file::write(const std::wstring & RootPath, bool add_padding)
|
||||
{
|
||||
std::wstringstream resStream;
|
||||
CP_XML_WRITER(resStream)
|
||||
@ -438,7 +470,7 @@ namespace odf_writer
|
||||
}
|
||||
|
||||
simple_element elm(L"settings.xml", resStream.str());
|
||||
elm.write(RootPath);
|
||||
elm.write(RootPath, add_padding);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -44,8 +44,6 @@ namespace cpdoccore
|
||||
namespace odf_writer
|
||||
{
|
||||
class _mediaitems;//picture & media
|
||||
|
||||
class rels;
|
||||
|
||||
namespace package
|
||||
{
|
||||
@ -91,7 +89,7 @@ namespace odf_writer
|
||||
public:
|
||||
virtual ~element() = 0;
|
||||
|
||||
virtual void write(const std::wstring & RootPath) = 0;
|
||||
virtual void write(const std::wstring & RootPath, bool add_padding = false) = 0;
|
||||
std::wstring local_path;
|
||||
private:
|
||||
element * element_;
|
||||
@ -107,35 +105,35 @@ namespace odf_writer
|
||||
simple_element(const std::wstring & FileName, const std::wstring & Content, bool utf8 = true);
|
||||
static element_ptr create(const std::wstring & FileName, const std::wstring & Content, bool utf8 = true);
|
||||
|
||||
virtual void write(const std::wstring & RootPath);
|
||||
virtual void write(const std::wstring & RootPath, bool add_padding = false);
|
||||
|
||||
private:
|
||||
std::wstring file_name_;
|
||||
std::string content_utf8_;
|
||||
bool utf8_;
|
||||
std::wstring file_name_;
|
||||
std::string content_utf8_;
|
||||
bool utf8_;
|
||||
|
||||
};
|
||||
|
||||
class meta_file : public element
|
||||
{
|
||||
public:
|
||||
virtual void write(const std::wstring & RootPath);
|
||||
virtual void write(const std::wstring & RootPath, bool add_padding = false);
|
||||
};
|
||||
|
||||
class content_file : public element
|
||||
{
|
||||
public:
|
||||
void set_content(content_content_ptr & c){content_ = c;}
|
||||
virtual void write(const std::wstring & RootPath);
|
||||
void set_content(content_content_ptr & c){content = c;}
|
||||
virtual void write(const std::wstring & RootPath, bool add_padding = false);
|
||||
|
||||
content_content_ptr content_;
|
||||
content_content_ptr content;
|
||||
};
|
||||
|
||||
class styles_file : public element
|
||||
{
|
||||
public:
|
||||
void set_content(content_simple_ptr & c) {content_ = c;}
|
||||
virtual void write(const std::wstring & RootPath);
|
||||
virtual void write(const std::wstring & RootPath, bool add_padding = false);
|
||||
content_simple_ptr content_;
|
||||
};
|
||||
|
||||
@ -143,7 +141,7 @@ namespace odf_writer
|
||||
{
|
||||
public:
|
||||
void set_content(content_simple_ptr & c) {content_ = c;}
|
||||
virtual void write(const std::wstring & RootPath);
|
||||
virtual void write(const std::wstring & RootPath, bool add_padding = false);
|
||||
content_simple_ptr content_;
|
||||
};
|
||||
|
||||
@ -152,9 +150,11 @@ namespace odf_writer
|
||||
public:
|
||||
manifect_file(std::wstring type);
|
||||
|
||||
virtual void write(const std::wstring & RootPath);
|
||||
virtual void write(const std::wstring & RootPath, bool add_padding = false);
|
||||
void add_rels(rels & r);
|
||||
|
||||
rels *get_rels() {return &rels_;}
|
||||
|
||||
private:
|
||||
rels rels_;
|
||||
std::wstring type_;
|
||||
@ -165,17 +165,17 @@ namespace odf_writer
|
||||
public:
|
||||
mimetype_file(std::wstring type);
|
||||
|
||||
virtual void write(const std::wstring & RootPath);
|
||||
virtual void write(const std::wstring & RootPath, bool add_padding = false);
|
||||
|
||||
private:
|
||||
std::wstring type_;
|
||||
|
||||
};
|
||||
class media : public element
|
||||
class media_files : public element
|
||||
{
|
||||
public:
|
||||
media(_mediaitems & mediaitems, const std::wstring internal_folder, int type);
|
||||
virtual void write(const std::wstring & RootPath);
|
||||
media_files(_mediaitems & mediaitems, const std::wstring internal_folder, int type);
|
||||
virtual void write(const std::wstring & RootPath, bool add_padding = false);
|
||||
|
||||
private:
|
||||
_mediaitems& mediaitems_;
|
||||
@ -195,19 +195,19 @@ namespace odf_writer
|
||||
|
||||
void set_mediaitems (_mediaitems & mediaitems);
|
||||
|
||||
virtual void write(const std::wstring & RootPath);
|
||||
virtual void write(const std::wstring & RootPath, bool add_padding = false);
|
||||
|
||||
private:
|
||||
content_file content_;
|
||||
settings_file settings_;
|
||||
styles_file styles_;
|
||||
content_file content;
|
||||
settings_file settings;
|
||||
styles_file styles;
|
||||
|
||||
element_ptr meta_;
|
||||
element_ptr meta;
|
||||
|
||||
element_ptr media_;
|
||||
element_ptr pictures_;
|
||||
element_ptr oleObjects_;
|
||||
element_ptr imageObjects_;
|
||||
element_ptr media;
|
||||
element_ptr pictures;
|
||||
element_ptr oleObjects;
|
||||
element_ptr imageObjects;
|
||||
};
|
||||
class odf_document : public element
|
||||
{
|
||||
@ -218,7 +218,11 @@ namespace odf_writer
|
||||
|
||||
void set_rels(rels & r);
|
||||
|
||||
virtual void write(const std::wstring & RootPath);
|
||||
virtual void write(const std::wstring & RootPath, bool add_padding = false);
|
||||
|
||||
void write_manifest(const std::wstring & RootPath);
|
||||
|
||||
manifect_file* get_manifest() {return dynamic_cast<manifect_file*>(manifest_.get());}
|
||||
|
||||
private:
|
||||
element_ptr base_;
|
||||
|
||||
@ -43,7 +43,7 @@
|
||||
|
||||
#include "style_paragraph_properties.h"
|
||||
|
||||
#include "../../DesktopEditor/fontengine/ApplicationFonts.h"
|
||||
#include "../../DesktopEditor/graphics/pro/Fonts.h"
|
||||
|
||||
|
||||
namespace cpdoccore {
|
||||
@ -60,7 +60,7 @@ odf_conversion_context::odf_conversion_context(_office_type_document type_, pack
|
||||
output_document_ = outputDocument;
|
||||
current_object_ = 0;
|
||||
|
||||
applicationFonts_ = new CApplicationFonts();
|
||||
applicationFonts_ = NSFonts::NSApplication::Create();
|
||||
|
||||
}
|
||||
odf_conversion_context::~odf_conversion_context()
|
||||
|
||||
@ -43,7 +43,10 @@
|
||||
|
||||
#include "mediaitems.h"
|
||||
|
||||
class CApplicationFonts;
|
||||
namespace NSFonts
|
||||
{
|
||||
class IApplicationFonts;
|
||||
}
|
||||
|
||||
namespace cpdoccore {
|
||||
namespace odf_writer {
|
||||
@ -86,8 +89,8 @@ public:
|
||||
virtual void start_document() = 0 ;
|
||||
virtual void end_document();
|
||||
|
||||
package::odf_document *output_document_;
|
||||
CApplicationFonts *applicationFonts_;
|
||||
package::odf_document *output_document_;
|
||||
NSFonts::IApplicationFonts *applicationFonts_;
|
||||
|
||||
|
||||
virtual odf_drawing_context * drawing_context() = 0;
|
||||
|
||||
@ -1101,7 +1101,7 @@ void odf_drawing_context::end_frame()
|
||||
/////////////////////
|
||||
void odf_drawing_context::start_element(office_element_ptr elm, office_element_ptr style_elm)
|
||||
{
|
||||
size_t level = impl_->current_level_.size();
|
||||
size_t level = (int)impl_->current_level_.size();
|
||||
|
||||
if (impl_->current_level_.size() > 0 && elm)
|
||||
impl_->current_level_.back()->add_child_element(elm);
|
||||
|
||||
@ -45,23 +45,38 @@ void relationship::serialize(std::wostream & _Wostream)
|
||||
{
|
||||
CP_XML_NODE(L"manifest:file-entry")
|
||||
{
|
||||
CP_XML_ATTR(L"manifest:full-path", target());
|
||||
CP_XML_ATTR(L"manifest:media-type", type());
|
||||
}
|
||||
CP_XML_ATTR(L"manifest:full-path", target_);
|
||||
|
||||
if (target_ == L"/")
|
||||
{
|
||||
CP_XML_ATTR(L"manifest:version", L"1.2");
|
||||
}
|
||||
CP_XML_ATTR(L"manifest:media-type", type_);
|
||||
|
||||
if (size_ >= 0)
|
||||
{
|
||||
CP_XML_ATTR(L"manifest:size", size_);
|
||||
}
|
||||
|
||||
if (!encryption_.empty())
|
||||
{
|
||||
CP_XML_STREAM() << encryption_;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void rels::serialize(std::wostream & strm)
|
||||
{
|
||||
for (size_t i = 0; i < relationship_.size(); i++)
|
||||
for (size_t i = 0; i < relationships_.size(); i++)
|
||||
{
|
||||
relationship_[i].serialize(strm);
|
||||
relationships_[i].serialize(strm);
|
||||
}
|
||||
}
|
||||
|
||||
void rels::add(relationship const & r)
|
||||
{
|
||||
relationships().push_back(r);
|
||||
relationships_.push_back(r);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -45,37 +45,30 @@ class relationship /*: public xml::element_impl<relationship>*/
|
||||
public:
|
||||
relationship() {}
|
||||
|
||||
relationship(const std::wstring & Type,const std::wstring & Target) : type_(Type), target_(Target)
|
||||
relationship(const std::wstring & Type,const std::wstring & Target) : type_(Type), target_(Target), size_(-1)
|
||||
{}
|
||||
|
||||
void serialize(std::wostream & _Wostream);
|
||||
|
||||
const std::wstring & type() const { return type_; }
|
||||
const std::wstring & target() const { return target_; }
|
||||
int size_;
|
||||
std::wstring type_;
|
||||
std::wstring target_;
|
||||
|
||||
private:
|
||||
std::wstring type_;
|
||||
std::wstring target_;
|
||||
std::wstring encryption_;
|
||||
};
|
||||
|
||||
class rels;
|
||||
typedef _CP_PTR(rels) rels_ptr;
|
||||
|
||||
/// \class rels
|
||||
class rels
|
||||
{
|
||||
public:
|
||||
rels() {}
|
||||
rels() {}
|
||||
|
||||
void serialize(std::wostream & _Wostream);
|
||||
void serialize(std::wostream & _Wostream);
|
||||
void add(relationship const & r);
|
||||
|
||||
std::vector<relationship> & relationships() { return relationship_; }
|
||||
void add(relationship const & r);
|
||||
bool empty() { return relationship_.empty(); }
|
||||
|
||||
private:
|
||||
std::vector<relationship> relationship_;
|
||||
|
||||
std::vector<relationship> relationships_;
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
@ -342,6 +342,16 @@ void odf_table_context::change_current_column_width(double width)
|
||||
int index = impl_->current_table().current_column ;
|
||||
if (index < 0) return;
|
||||
|
||||
while(index >= impl_->current_table().columns.size())
|
||||
{
|
||||
office_element_ptr elm;
|
||||
create_element(L"table", L"table-column", elm, impl_->odf_context_);
|
||||
|
||||
impl_->styles_context()->create_style(L"", style_family::TableColumn, true, false, -1);
|
||||
|
||||
add_column(elm, true);
|
||||
|
||||
}
|
||||
style *style_ = dynamic_cast<style*>(impl_->current_table().columns[index].style_elm.get());
|
||||
|
||||
if (style_ == NULL) return;
|
||||
@ -517,7 +527,7 @@ void odf_table_context::set_cell_row_span_restart()
|
||||
int col = impl_->current_table().current_column-1;
|
||||
odf_column_state & state = impl_->current_table().columns[col];
|
||||
|
||||
size_t sz = state.spanned_row_cell.size();
|
||||
int sz = state.spanned_row_cell.size();
|
||||
|
||||
if (sz > 1)
|
||||
{
|
||||
@ -527,7 +537,11 @@ void odf_table_context::set_cell_row_span_restart()
|
||||
cell->table_table_cell_attlist_extra_.table_number_rows_spanned_ = sz;
|
||||
}
|
||||
state.spanned_row_cell.clear();
|
||||
state.spanned_row_cell.push_back(impl_->current_table().cells.back().elm);
|
||||
|
||||
if (false == impl_->current_table().cells.empty())
|
||||
{
|
||||
state.spanned_row_cell.push_back(impl_->current_table().cells.back().elm);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
@ -30,6 +30,13 @@
|
||||
*
|
||||
*/
|
||||
|
||||
//#ifndef min
|
||||
//#define min(a,b) ((a) < (b) ? (a) : (b))
|
||||
//#endif
|
||||
//#ifndef max
|
||||
//#define max(a,b) ((a) > (b) ? (a) : (b))
|
||||
//#endif
|
||||
|
||||
#include <boost/algorithm/string.hpp>
|
||||
|
||||
#include "../utils.h"
|
||||
@ -44,7 +51,6 @@
|
||||
#include "paragraph_elements.h"
|
||||
#include "odf_settings_context.h"
|
||||
|
||||
|
||||
namespace cpdoccore {
|
||||
|
||||
using namespace odf_types;
|
||||
@ -54,7 +60,7 @@ namespace odf_writer {
|
||||
namespace utils
|
||||
{
|
||||
|
||||
void calculate_size_font_symbols(_font_metrix & metrix, CApplicationFonts *appFonts)
|
||||
void calculate_size_font_symbols(_font_metrix & metrix, NSFonts::IApplicationFonts *appFonts)
|
||||
{
|
||||
double appr_px = _graphics_utils_::calculate_size_symbol_asc(metrix.font_name, metrix.font_size, metrix.italic, metrix.bold, appFonts);
|
||||
|
||||
@ -178,14 +184,17 @@ void ods_conversion_context::end_sheet()
|
||||
|
||||
styles_context()->reset_defaults();
|
||||
}
|
||||
|
||||
void ods_conversion_context::add_row_repeated()
|
||||
{
|
||||
current_table().add_row_repeated();
|
||||
}
|
||||
void ods_conversion_context::start_row(int _start_row, int repeated, int level, bool _default)
|
||||
{
|
||||
if (_start_row > current_table().current_row()+1)
|
||||
if (_start_row > current_table().current_row() + 1)
|
||||
{
|
||||
int repeated_default = _start_row - current_table().current_row()-1;
|
||||
|
||||
start_row(_start_row-repeated_default, repeated_default,0, true);
|
||||
start_row(_start_row - repeated_default, repeated_default, 0, true);
|
||||
end_row();
|
||||
}
|
||||
/////////////////////////////////////////////////////////////////
|
||||
@ -416,7 +425,7 @@ void ods_conversion_context::end_rows()
|
||||
repeated -= (1 + rows);
|
||||
}
|
||||
|
||||
if (repeated > 0)
|
||||
if (repeated > 0 && current_table().get_last_row_repeated() < 1024)
|
||||
{
|
||||
start_row(current_table().current_row() + 1, repeated, 0, true);
|
||||
end_row();
|
||||
|
||||
@ -77,6 +77,8 @@ public:
|
||||
|
||||
void start_cell(std::wstring & ref, int xfd_style);
|
||||
void end_cell();
|
||||
|
||||
void add_row_repeated();
|
||||
void end_rows();
|
||||
|
||||
void start_cell_text();
|
||||
|
||||
@ -245,7 +245,7 @@ void ods_table_state::end_headers()
|
||||
current_level_.pop_back();
|
||||
}
|
||||
|
||||
void ods_table_state::add_column(office_element_ptr & elm, short repeated,office_element_ptr & style_elm)
|
||||
void ods_table_state::add_column(office_element_ptr & elm, unsigned int repeated,office_element_ptr & style_elm)
|
||||
{
|
||||
current_level_.back()->add_child_element(elm);
|
||||
|
||||
@ -254,7 +254,7 @@ void ods_table_state::add_column(office_element_ptr & elm, short repeated,office
|
||||
odf_writer::style* style = dynamic_cast<odf_writer::style*>(style_elm.get());
|
||||
if (style)style_name = style->style_name_;
|
||||
|
||||
ods_element_state state = {elm, repeated,style_name, style_elm, defaut_column_width_ , (short)current_level_.size()};
|
||||
ods_element_state state = {elm, repeated,style_name, style_elm, defaut_column_width_ , (unsigned int)current_level_.size()};
|
||||
|
||||
if (repeated > 10000)repeated = 1024;//????
|
||||
|
||||
@ -331,7 +331,7 @@ void ods_table_state::set_table_dimension(int col, int row)
|
||||
if (dimension_row < row) dimension_row = row + 1;
|
||||
}
|
||||
|
||||
void ods_table_state::add_row(office_element_ptr & elm, short repeated, office_element_ptr & style_elm)
|
||||
void ods_table_state::add_row(office_element_ptr & elm, unsigned int repeated, office_element_ptr & style_elm)
|
||||
{
|
||||
current_table_column_ = 0;
|
||||
current_table_row_ += repeated;
|
||||
@ -343,7 +343,7 @@ void ods_table_state::add_row(office_element_ptr & elm, short repeated, office_e
|
||||
odf_writer::style* style = dynamic_cast<odf_writer::style*>(style_elm.get());
|
||||
if (style)style_name = style->style_name_;
|
||||
|
||||
ods_element_state state = {elm, repeated,style_name, style_elm, defaut_row_height_ , (short)current_level_.size()};
|
||||
ods_element_state state = {elm, repeated,style_name, style_elm, defaut_row_height_ , (unsigned int)current_level_.size()};
|
||||
|
||||
rows_.push_back(state);
|
||||
|
||||
@ -356,6 +356,16 @@ void ods_table_state::add_row(office_element_ptr & elm, short repeated, office_e
|
||||
row_default_cell_style_name_ = L"";
|
||||
|
||||
}
|
||||
void ods_table_state::add_row_repeated()
|
||||
{
|
||||
table_table_row* row = dynamic_cast<table_table_row*>(rows_.back().elm.get());
|
||||
if (row == NULL)return;
|
||||
|
||||
unsigned int t = rows_.back().repeated;
|
||||
rows_.back().repeated++;
|
||||
current_table_row_++;
|
||||
row->table_table_row_attlist_.table_number_rows_repeated_ = rows_.back().repeated;
|
||||
}
|
||||
void ods_table_state::set_row_hidden(bool Val)
|
||||
{
|
||||
table_table_row* row = dynamic_cast<table_table_row*>(rows_.back().elm.get());
|
||||
@ -409,7 +419,7 @@ int ods_table_state::is_cell_hyperlink(int col, int row)
|
||||
}
|
||||
return -1;
|
||||
}
|
||||
int ods_table_state::is_cell_comment(int col, int row, short repeate_col)
|
||||
int ods_table_state::is_cell_comment(int col, int row, unsigned int repeate_col)
|
||||
{
|
||||
for (size_t i = 0; i < comments_.size(); i++)
|
||||
{
|
||||
@ -442,6 +452,11 @@ int ods_table_state::current_row() const
|
||||
return current_table_row_;
|
||||
}
|
||||
|
||||
unsigned int ods_table_state::get_last_row_repeated ()
|
||||
{
|
||||
return rows_.empty() ? 1 : rows_.back().repeated;
|
||||
}
|
||||
|
||||
void ods_table_state::set_row_default_cell_style(std::wstring & style_name)
|
||||
{
|
||||
row_default_cell_style_name_= style_name; //обязательно нужно определить default-style (table_cell)!!!
|
||||
@ -760,7 +775,7 @@ void ods_table_state::add_or_find_cell_shared_formula(std::wstring & formula, st
|
||||
if (row2-row1 >0)moving_type = 2;
|
||||
if (col2-col1 >0)moving_type = 1;
|
||||
}
|
||||
ods_shared_formula_state state = {(short)ind, odf_formula,ref, current_table_column_,current_table_row_, moving_type};
|
||||
ods_shared_formula_state state = {(unsigned int)ind, odf_formula,ref, current_table_column_,current_table_row_, moving_type};
|
||||
shared_formulas_.push_back(state);
|
||||
|
||||
cell->table_table_cell_attlist_.table_formula_ = odf_formula;
|
||||
@ -1043,7 +1058,7 @@ void ods_table_state::end_cell()
|
||||
}
|
||||
}
|
||||
|
||||
void ods_table_state::add_default_cell( short repeated)
|
||||
void ods_table_state::add_default_cell( unsigned int repeated)
|
||||
{
|
||||
int comment_idx = is_cell_comment(current_table_column_ + 1 , current_table_row_, repeated);
|
||||
if (comment_idx >= 0 && repeated > 1)
|
||||
|
||||
@ -161,13 +161,13 @@ struct ods_element_state
|
||||
{
|
||||
office_element_ptr elm;
|
||||
|
||||
short repeated;
|
||||
unsigned int repeated;
|
||||
std::wstring style_name;
|
||||
office_element_ptr style_elm;
|
||||
|
||||
double size;
|
||||
|
||||
short level;
|
||||
unsigned int level;
|
||||
|
||||
std::wstring cell_style_name;
|
||||
};
|
||||
@ -177,8 +177,8 @@ struct ods_cell_state : ods_element_state
|
||||
int col;
|
||||
int row;
|
||||
|
||||
short hyperlink_idx;
|
||||
short comment_idx;
|
||||
unsigned int hyperlink_idx;
|
||||
unsigned int comment_idx;
|
||||
|
||||
bool empty;
|
||||
};
|
||||
@ -201,7 +201,7 @@ struct ods_comment_state
|
||||
};
|
||||
struct ods_shared_formula_state
|
||||
{
|
||||
short index;
|
||||
unsigned int index;
|
||||
std::wstring formula;
|
||||
std::wstring ref;
|
||||
|
||||
@ -248,7 +248,7 @@ public:
|
||||
void set_table_dimension(int col, int row);
|
||||
void set_print_range(std::wstring range);
|
||||
|
||||
void add_column(office_element_ptr & elm, short repeated ,office_element_ptr & style);
|
||||
void add_column(office_element_ptr & elm, unsigned int repeated ,office_element_ptr & style);
|
||||
void set_column_width(double width);
|
||||
void set_column_optimal_width(bool val);
|
||||
void set_column_hidden(bool val);
|
||||
@ -264,15 +264,16 @@ public:
|
||||
void start_headers(office_element_ptr & elm);
|
||||
void end_headers();
|
||||
|
||||
void add_row(office_element_ptr & elm, short repeated , office_element_ptr & style);//const std::wstring & StyleName, const std::wstring & defaultCellStyleName);
|
||||
void add_row(office_element_ptr & elm, unsigned int repeated , office_element_ptr & style);//const std::wstring & StyleName, const std::wstring & defaultCellStyleName);
|
||||
void set_row_hidden(bool Val);
|
||||
void set_row_optimal_height(bool val);
|
||||
void set_row_height(double height);
|
||||
void set_row_default_cell_style(std::wstring & style_name);
|
||||
void add_row_repeated();
|
||||
|
||||
void start_cell(office_element_ptr & elm ,office_element_ptr & style);
|
||||
void end_cell();
|
||||
void add_default_cell(short repeated);
|
||||
void add_default_cell(unsigned int repeated);
|
||||
|
||||
void set_cell_format_value(odf_types::office_value_type::type value_type);
|
||||
void set_cell_type(int type);
|
||||
@ -318,9 +319,11 @@ public:
|
||||
bool is_cell_hyperlink ();
|
||||
int is_cell_hyperlink (int col, int row);
|
||||
bool is_cell_comment ();
|
||||
int is_cell_comment (int col, int row, short repeate_col = 1);
|
||||
int is_cell_comment (int col, int row, unsigned int repeate_col = 1);
|
||||
int is_row_comment (int row, int repeate_row = 1);
|
||||
|
||||
unsigned int get_last_row_repeated ();
|
||||
|
||||
ods_hyperlink_state & current_hyperlink();
|
||||
|
||||
int current_column() const;
|
||||
|
||||
@ -60,7 +60,7 @@ namespace odf_writer {
|
||||
namespace utils
|
||||
{
|
||||
|
||||
double calculate_size_font_symbols(std::wstring str_test, std::wstring font_name, double font_size, CApplicationFonts *appFonts)
|
||||
double calculate_size_font_symbols(std::wstring str_test, std::wstring font_name, double font_size, NSFonts::IApplicationFonts *appFonts)
|
||||
{
|
||||
double appr_px = _graphics_utils_::calculate_size_symbol_asc(font_name, font_size, false, false, appFonts);
|
||||
|
||||
@ -200,7 +200,7 @@ void odt_conversion_context::add_text_content(const std::wstring & text)
|
||||
{
|
||||
if (drop_cap_state_.enabled)
|
||||
{
|
||||
size_t count = text.length();
|
||||
int count = (int)text.length();
|
||||
drop_cap_state_.characters += count;
|
||||
|
||||
style_text_properties * props = text_context()->get_text_properties();
|
||||
@ -984,7 +984,7 @@ void odt_conversion_context::start_drop_cap(style_paragraph_properties *paragrap
|
||||
create_element(L"style", L"drop-cap", drop_cap_state_.paragraph_properties->content_.style_drop_cap_, this);
|
||||
}
|
||||
|
||||
void odt_conversion_context::set_drop_cap_lines(size_t lines)
|
||||
void odt_conversion_context::set_drop_cap_lines(int lines)
|
||||
{
|
||||
if (!drop_cap_state_.enabled) return;
|
||||
if (!drop_cap_state_.paragraph_properties) return;
|
||||
|
||||
@ -110,7 +110,7 @@ public:
|
||||
void set_master_page_name(std::wstring master_name);
|
||||
|
||||
void start_drop_cap (style_paragraph_properties * paragraph_properties);
|
||||
void set_drop_cap_lines (size_t lines);
|
||||
void set_drop_cap_lines (int lines);
|
||||
void set_drop_cap_margin(bool val);
|
||||
void end_drop_cap ();
|
||||
bool in_drop_cap () {return drop_cap_state_.enabled;}
|
||||
@ -221,8 +221,8 @@ private:
|
||||
style_paragraph_properties *paragraph_properties = NULL;
|
||||
office_element_ptr text_properties;
|
||||
|
||||
size_t lines = 0;
|
||||
size_t characters = 0;
|
||||
int lines = 0;
|
||||
int characters = 0;
|
||||
bool inline_style = false;
|
||||
double characters_size_pt = 0;
|
||||
}drop_cap_state_;
|
||||
|
||||
151
ASCOfficeOdfFileW/source/OdfFormat/office_document.cpp
Normal file
151
ASCOfficeOdfFileW/source/OdfFormat/office_document.cpp
Normal file
@ -0,0 +1,151 @@
|
||||
/*
|
||||
* (c) Copyright Ascensio System SIA 2010-2018
|
||||
*
|
||||
* This program is a free software product. You can redistribute it and/or
|
||||
* modify it under the terms of the GNU Affero General Public License (AGPL)
|
||||
* version 3 as published by the Free Software Foundation. In accordance with
|
||||
* Section 7(a) of the GNU AGPL its Section 15 shall be amended to the effect
|
||||
* that Ascensio System SIA expressly excludes the warranty of non-infringement
|
||||
* of any third-party rights.
|
||||
*
|
||||
* This program is distributed WITHOUT ANY WARRANTY; without even the implied
|
||||
* warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For
|
||||
* details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html
|
||||
*
|
||||
* You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia,
|
||||
* EU, LV-1021.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of the Program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU AGPL version 3.
|
||||
*
|
||||
* Pursuant to Section 7(b) of the License you must retain the original Product
|
||||
* logo when distributing the program. Pursuant to Section 7(e) we decline to
|
||||
* grant you any rights under trademark law for use of our trademarks.
|
||||
*
|
||||
* All the Product's GUI elements, including illustrations and icon sets, as
|
||||
* well as technical writing content are licensed under the terms of the
|
||||
* Creative Commons Attribution-ShareAlike 4.0 International. See the License
|
||||
* terms at http://creativecommons.org/licenses/by-sa/4.0/legalcode
|
||||
*
|
||||
*/
|
||||
|
||||
#include "office_document.h"
|
||||
|
||||
#include <cpdoccore/xml/xmlchar.h>
|
||||
|
||||
#include <cpdoccore/xml/attributes.h>
|
||||
#include <cpdoccore/xml/utils.h>
|
||||
|
||||
namespace cpdoccore {
|
||||
|
||||
namespace odf_writer {
|
||||
|
||||
// manifest:encryption-data
|
||||
//////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
const wchar_t * manifest_encryption_data::ns = L"manifest";
|
||||
const wchar_t * manifest_encryption_data::name = L"encryption-data";
|
||||
|
||||
void manifest_encryption_data::create_child_element(const std::wstring & Ns, const std::wstring & Name)
|
||||
{
|
||||
if CP_CHECK_NAME(L"manifest", L"algorithm")
|
||||
{
|
||||
CP_CREATE_ELEMENT(algorithm_);
|
||||
}
|
||||
else if CP_CHECK_NAME(L"manifest", L"key-derivation")
|
||||
{
|
||||
CP_CREATE_ELEMENT(key_derivation_);
|
||||
}
|
||||
else if CP_CHECK_NAME(L"manifest", L"start-key-generation")
|
||||
{
|
||||
CP_CREATE_ELEMENT(start_key_generation_);
|
||||
}
|
||||
}
|
||||
void manifest_encryption_data::add_child_element( const office_element_ptr & child_element)
|
||||
{
|
||||
if (!child_element) return;
|
||||
|
||||
ElementType type = child_element->get_type();
|
||||
|
||||
if (type == typeManifestAlgorithm)
|
||||
{
|
||||
algorithm_ = child_element;
|
||||
}
|
||||
else if (type == typeManifestKeyDerivation)
|
||||
{
|
||||
key_derivation_ = child_element;
|
||||
}
|
||||
else if (type == typeManifestStartKeyGeneration)
|
||||
{
|
||||
start_key_generation_ = child_element;
|
||||
}
|
||||
}
|
||||
void manifest_encryption_data::serialize(std::wostream & _Wostream)
|
||||
{
|
||||
CP_XML_WRITER(_Wostream)
|
||||
{
|
||||
CP_XML_NODE_SIMPLE()
|
||||
{
|
||||
CP_XML_ATTR(L"manifest:checksum-type", checksum_type_);
|
||||
CP_XML_ATTR(L"manifest:checksum", checksum_);
|
||||
|
||||
if (algorithm_) algorithm_->serialize(CP_XML_STREAM());
|
||||
if (key_derivation_) key_derivation_->serialize(CP_XML_STREAM());
|
||||
if (start_key_generation_) start_key_generation_->serialize(CP_XML_STREAM());
|
||||
}
|
||||
}
|
||||
}
|
||||
// manifest:algorithm
|
||||
//////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
const wchar_t * manifest_algorithm::ns = L"manifest";
|
||||
const wchar_t * manifest_algorithm::name = L"algorithm";
|
||||
|
||||
void manifest_algorithm::serialize(std::wostream & _Wostream)
|
||||
{
|
||||
CP_XML_WRITER(_Wostream)
|
||||
{
|
||||
CP_XML_NODE_SIMPLE()
|
||||
{
|
||||
CP_XML_ATTR(L"manifest:algorithm-name", algorithm_name_);
|
||||
CP_XML_ATTR(L"manifest:initialisation-vector", initialisation_vector_);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
// manifest:key-derivation
|
||||
//////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
const wchar_t * manifest_key_derivation::ns = L"manifest";
|
||||
const wchar_t * manifest_key_derivation::name = L"key-derivation";
|
||||
|
||||
void manifest_key_derivation::serialize(std::wostream & _Wostream)
|
||||
{
|
||||
CP_XML_WRITER(_Wostream)
|
||||
{
|
||||
CP_XML_NODE_SIMPLE()
|
||||
{
|
||||
CP_XML_ATTR(L"manifest:key-derivation-name", L"PBKDF2");
|
||||
CP_XML_ATTR(L"manifest:key-size", key_size_);
|
||||
CP_XML_ATTR(L"manifest:iteration-count", iteration_count_);
|
||||
CP_XML_ATTR(L"manifest:salt", salt_);
|
||||
}
|
||||
}
|
||||
}
|
||||
// manifest:start-key-generation
|
||||
//////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
const wchar_t * manifest_start_key_generation::ns = L"manifest";
|
||||
const wchar_t * manifest_start_key_generation::name = L"start-key-generation";
|
||||
|
||||
void manifest_start_key_generation::serialize(std::wostream & _Wostream)
|
||||
{
|
||||
CP_XML_WRITER(_Wostream)
|
||||
{
|
||||
CP_XML_NODE_SIMPLE()
|
||||
{
|
||||
CP_XML_ATTR(L"manifest:start-key-generation-name", start_key_generation_name_);
|
||||
CP_XML_ATTR(L"manifest:key-size", key_size_);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
136
ASCOfficeOdfFileW/source/OdfFormat/office_document.h
Normal file
136
ASCOfficeOdfFileW/source/OdfFormat/office_document.h
Normal file
@ -0,0 +1,136 @@
|
||||
/*
|
||||
* (c) Copyright Ascensio System SIA 2010-2018
|
||||
*
|
||||
* This program is a free software product. You can redistribute it and/or
|
||||
* modify it under the terms of the GNU Affero General Public License (AGPL)
|
||||
* version 3 as published by the Free Software Foundation. In accordance with
|
||||
* Section 7(a) of the GNU AGPL its Section 15 shall be amended to the effect
|
||||
* that Ascensio System SIA expressly excludes the warranty of non-infringement
|
||||
* of any third-party rights.
|
||||
*
|
||||
* This program is distributed WITHOUT ANY WARRANTY; without even the implied
|
||||
* warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For
|
||||
* details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html
|
||||
*
|
||||
* You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia,
|
||||
* EU, LV-1021.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of the Program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU AGPL version 3.
|
||||
*
|
||||
* Pursuant to Section 7(b) of the License you must retain the original Product
|
||||
* logo when distributing the program. Pursuant to Section 7(e) we decline to
|
||||
* grant you any rights under trademark law for use of our trademarks.
|
||||
*
|
||||
* All the Product's GUI elements, including illustrations and icon sets, as
|
||||
* well as technical writing content are licensed under the terms of the
|
||||
* Creative Commons Attribution-ShareAlike 4.0 International. See the License
|
||||
* terms at http://creativecommons.org/licenses/by-sa/4.0/legalcode
|
||||
*
|
||||
*/
|
||||
#pragma once
|
||||
|
||||
#include <iosfwd>
|
||||
#include <vector>
|
||||
#include <cpdoccore/CPOptional.h>
|
||||
#include <cpdoccore/xml/nodetype.h>
|
||||
#include <cpdoccore/xml/simple_xml_writer.h>
|
||||
|
||||
#include "office_elements_create.h"
|
||||
|
||||
#include "bool.h"
|
||||
#include "length.h"
|
||||
|
||||
namespace cpdoccore {
|
||||
namespace odf_writer {
|
||||
|
||||
// manifest:encryption-data
|
||||
class manifest_encryption_data : public office_element_impl<manifest_encryption_data>
|
||||
{
|
||||
public:
|
||||
static const wchar_t * ns;
|
||||
static const wchar_t * name;
|
||||
static const xml::NodeType xml_type = xml::typeElement;
|
||||
static const ElementType type = typeManifestEncryptionData;
|
||||
CPDOCCORE_DEFINE_VISITABLE();
|
||||
|
||||
virtual void create_child_element( const std::wstring & Ns, const std::wstring & Name);
|
||||
virtual void add_child_element( const office_element_ptr & child_element);
|
||||
|
||||
virtual void serialize(std::wostream & _Wostream);
|
||||
|
||||
std::wstring checksum_;
|
||||
std::wstring checksum_type_;
|
||||
|
||||
office_element_ptr algorithm_;
|
||||
office_element_ptr key_derivation_;
|
||||
office_element_ptr start_key_generation_;
|
||||
};
|
||||
|
||||
CP_REGISTER_OFFICE_ELEMENT2(manifest_encryption_data);
|
||||
|
||||
// manifest:algorithm
|
||||
class manifest_algorithm : public office_element_impl<manifest_algorithm>
|
||||
{
|
||||
public:
|
||||
static const wchar_t * ns;
|
||||
static const wchar_t * name;
|
||||
static const xml::NodeType xml_type = xml::typeElement;
|
||||
static const ElementType type = typeManifestAlgorithm;
|
||||
CPDOCCORE_DEFINE_VISITABLE();
|
||||
|
||||
virtual void create_child_element( const std::wstring & Ns, const std::wstring & Name){}
|
||||
virtual void add_child_element( const office_element_ptr & child_element){}
|
||||
|
||||
virtual void serialize(std::wostream & _Wostream);
|
||||
|
||||
std::wstring algorithm_name_;
|
||||
std::wstring initialisation_vector_;
|
||||
};
|
||||
CP_REGISTER_OFFICE_ELEMENT2(manifest_algorithm);
|
||||
|
||||
// manifest:key_derivation
|
||||
class manifest_key_derivation : public office_element_impl<manifest_key_derivation>
|
||||
{
|
||||
public:
|
||||
static const wchar_t * ns;
|
||||
static const wchar_t * name;
|
||||
static const xml::NodeType xml_type = xml::typeElement;
|
||||
static const ElementType type = typeManifestKeyDerivation;
|
||||
CPDOCCORE_DEFINE_VISITABLE();
|
||||
|
||||
virtual void create_child_element( const std::wstring & Ns, const std::wstring & Name){}
|
||||
virtual void add_child_element( const office_element_ptr & child_element){}
|
||||
|
||||
virtual void serialize(std::wostream & _Wostream);
|
||||
|
||||
std::wstring key_derivation_name_;
|
||||
int key_size_;
|
||||
int iteration_count_;
|
||||
std::wstring salt_;
|
||||
};
|
||||
CP_REGISTER_OFFICE_ELEMENT2(manifest_key_derivation);
|
||||
|
||||
// manifest:start-key-generation
|
||||
class manifest_start_key_generation : public office_element_impl<manifest_start_key_generation>
|
||||
{
|
||||
public:
|
||||
static const wchar_t * ns;
|
||||
static const wchar_t * name;
|
||||
static const xml::NodeType xml_type = xml::typeElement;
|
||||
static const ElementType type = typeManifestStartKeyGeneration;
|
||||
CPDOCCORE_DEFINE_VISITABLE();
|
||||
|
||||
virtual void create_child_element( const std::wstring & Ns, const std::wstring & Name){}
|
||||
virtual void add_child_element( const office_element_ptr & child_element){}
|
||||
|
||||
virtual void serialize(std::wostream & _Wostream);
|
||||
|
||||
std::wstring start_key_generation_name_;
|
||||
int key_size_;
|
||||
};
|
||||
CP_REGISTER_OFFICE_ELEMENT2(manifest_start_key_generation);
|
||||
|
||||
}
|
||||
}
|
||||
@ -222,6 +222,10 @@ enum ElementType
|
||||
typeManifestEntry,
|
||||
typeManifestEncryptionData,
|
||||
|
||||
typeManifestAlgorithm,
|
||||
typeManifestStartKeyGeneration,
|
||||
typeManifestKeyDerivation,
|
||||
|
||||
typeOfficeSettings,
|
||||
typeOfficeSettingsConfigItemSet,
|
||||
typeOfficeSettingsConfigItem,
|
||||
|
||||
@ -37,6 +37,7 @@
|
||||
|
||||
#include "../../../Common/DocxFormat/Source/DocxFormat/Diagram/DiagramDrawing.h"
|
||||
#include "../../../Common/DocxFormat/Source/XlsxFormat/Chart/Chart.h"
|
||||
#include "../../../ASCOfficePPTXFile/PPTXFormat/Slide.h"
|
||||
#include "../../../ASCOfficePPTXFile/PPTXFormat/Logic/SpTreeElem.h"
|
||||
#include "../../../ASCOfficePPTXFile/PPTXFormat/Logic/GraphicFrame.h"
|
||||
#include "../../../ASCOfficePPTXFile/PPTXFormat/Logic/Shape.h"
|
||||
@ -267,6 +268,10 @@ void OoxConverter::convert(PPTX::Logic::Pic *oox_picture)
|
||||
}
|
||||
if (oox_picture->oleObject.IsInit())
|
||||
{
|
||||
if (pathImage.empty() && oox_picture->blipFill.blip.IsInit())
|
||||
{
|
||||
pathImage = oox_picture->blipFill.blip->oleFilepathImage;
|
||||
}
|
||||
std::wstring pathOle;
|
||||
|
||||
if (oox_picture->oleObject->m_oId.IsInit())
|
||||
@ -283,6 +288,58 @@ void OoxConverter::convert(PPTX::Logic::Pic *oox_picture)
|
||||
{
|
||||
odf_context()->drawing_context()->set_program(*oox_picture->oleObject->m_sProgId);
|
||||
}
|
||||
|
||||
if (pathImage.empty() && oox_picture->oleObject->m_sShapeId.IsInit())
|
||||
{
|
||||
PPTX::Slide *pSlide = dynamic_cast<PPTX::Slide*>(current_document());
|
||||
PPTX::SlideMaster *pSlideMaster = dynamic_cast<PPTX::SlideMaster*>(current_document());
|
||||
|
||||
OOX::CVmlDrawing *pVml = pSlide ? pSlide->Vml.operator->() : (pSlideMaster ? pSlideMaster->Vml.operator->() : NULL);
|
||||
|
||||
if (pVml)
|
||||
{
|
||||
std::wstring sShapeId = oox_picture->oleObject->m_sShapeId.get();
|
||||
boost::unordered_map<std::wstring, OOX::CVmlDrawing::_vml_shape>::iterator pFind = pVml->m_mapShapes.find(sShapeId);
|
||||
|
||||
if (pVml->m_mapShapes.end() != pFind)
|
||||
{
|
||||
OOX::Vml::CVmlCommonElements* pShape = dynamic_cast<OOX::Vml::CVmlCommonElements*>(pFind->second.pElement);
|
||||
|
||||
if (pShape)
|
||||
{
|
||||
for(size_t i = 0; i < pShape->m_arrItems.size(); ++i)
|
||||
{
|
||||
OOX::WritingElement* pChildElemShape = pShape->m_arrItems[i];
|
||||
|
||||
if(OOX::et_v_imagedata == pChildElemShape->getType())
|
||||
{
|
||||
OOX::Vml::CImageData* pImageData = static_cast<OOX::Vml::CImageData*>(pChildElemShape);
|
||||
|
||||
std::wstring sIdImageFileCache;
|
||||
|
||||
if (pImageData->m_oRelId.IsInit()) sIdImageFileCache = pImageData->m_oRelId->GetValue();
|
||||
else if (pImageData->m_rId.IsInit()) sIdImageFileCache = pImageData->m_rId->GetValue();
|
||||
|
||||
if (!sIdImageFileCache.empty())
|
||||
{
|
||||
//ищем физический файл ( rId относительно vml_drawing)
|
||||
smart_ptr<OOX::File> pFile = pVml->Find(sIdImageFileCache);
|
||||
|
||||
if (pFile.IsInit() && ( OOX::FileTypes::Image == pFile->type()))
|
||||
{
|
||||
OOX::Image* pImageFileCache = static_cast<OOX::Image*>(pFile.operator->());
|
||||
|
||||
pathImage = pImageFileCache->filename().GetPath();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
odf_ref_image = bEmbedded ? odf_context()->add_imageobject(pathImage) : pathImage;
|
||||
odf_context()->drawing_context()->set_image_replacement(odf_ref_image);
|
||||
|
||||
@ -309,10 +366,10 @@ void OoxConverter::convert(PPTX::Logic::Pic *oox_picture)
|
||||
if (oox_picture->blipFill.srcRect.IsInit() && Width > 0 && Height >0 )
|
||||
{
|
||||
odf_context()->drawing_context()->set_image_client_rect_inch(
|
||||
XmlUtils::GetInteger(oox_picture->blipFill.srcRect->l.get_value_or(L"0")) * Width /100. /currentSystemDPI,
|
||||
XmlUtils::GetInteger(oox_picture->blipFill.srcRect->t.get_value_or(L"0")) * Height /100. /currentSystemDPI,
|
||||
XmlUtils::GetInteger(oox_picture->blipFill.srcRect->r.get_value_or(L"0")) * Width /100. /currentSystemDPI,
|
||||
XmlUtils::GetInteger(oox_picture->blipFill.srcRect->b.get_value_or(L"0")) * Height /100. /currentSystemDPI);
|
||||
XmlUtils::GetInteger(oox_picture->blipFill.srcRect->l.get_value_or(L"0")) * Width /100. / 96.,
|
||||
XmlUtils::GetInteger(oox_picture->blipFill.srcRect->t.get_value_or(L"0")) * Height /100. / 96.,
|
||||
XmlUtils::GetInteger(oox_picture->blipFill.srcRect->r.get_value_or(L"0")) * Width /100. / 96.,
|
||||
XmlUtils::GetInteger(oox_picture->blipFill.srcRect->b.get_value_or(L"0")) * Height /100. / 96.);
|
||||
}
|
||||
|
||||
OoxConverter::convert(&oox_picture->nvPicPr.cNvPr);
|
||||
@ -915,10 +972,10 @@ void OoxConverter::convert(PPTX::Logic::BlipFill *oox_bitmap_fill)
|
||||
if (oox_bitmap_fill->srcRect.IsInit() && Width > 0 && Height > 0)//часть изображения
|
||||
{
|
||||
odf_context()->drawing_context()->set_image_client_rect_inch(
|
||||
(oox_bitmap_fill->srcRect->l.IsInit() ? XmlUtils::GetInteger(oox_bitmap_fill->srcRect->l.get()) : 0 ) /100. * Width / currentSystemDPI,
|
||||
(oox_bitmap_fill->srcRect->t.IsInit() ? XmlUtils::GetInteger(oox_bitmap_fill->srcRect->t.get()) : 0 ) /100. * Height/ currentSystemDPI,
|
||||
(oox_bitmap_fill->srcRect->r.IsInit() ? XmlUtils::GetInteger(oox_bitmap_fill->srcRect->r.get()) : 0 ) /100. * Width / currentSystemDPI,
|
||||
(oox_bitmap_fill->srcRect->b.IsInit() ? XmlUtils::GetInteger(oox_bitmap_fill->srcRect->b.get()) : 0 ) /100. * Height/ currentSystemDPI);
|
||||
(oox_bitmap_fill->srcRect->l.IsInit() ? XmlUtils::GetInteger(oox_bitmap_fill->srcRect->l.get()) : 0 ) /100. * Width / 96.,
|
||||
(oox_bitmap_fill->srcRect->t.IsInit() ? XmlUtils::GetInteger(oox_bitmap_fill->srcRect->t.get()) : 0 ) /100. * Height/ 96.,
|
||||
(oox_bitmap_fill->srcRect->r.IsInit() ? XmlUtils::GetInteger(oox_bitmap_fill->srcRect->r.get()) : 0 ) /100. * Width / 96.,
|
||||
(oox_bitmap_fill->srcRect->b.IsInit() ? XmlUtils::GetInteger(oox_bitmap_fill->srcRect->b.get()) : 0 ) /100. * Height/ 96.);
|
||||
}
|
||||
if (oox_bitmap_fill->tile.IsInit())
|
||||
{
|
||||
@ -1973,24 +2030,26 @@ void OoxConverter::convert(PPTX::Logic::Run *oox_run)
|
||||
if (!oox_run) return;
|
||||
bool styled = false;
|
||||
|
||||
odf_writer::odf_text_context* text_context = odf_context()->text_context();
|
||||
|
||||
if (oox_run->rPr.IsInit())
|
||||
{
|
||||
odf_writer::style_text_properties * text_properties = odf_context()->text_context()->get_text_properties();
|
||||
odf_writer::style_text_properties * text_properties = text_context->get_text_properties();
|
||||
|
||||
if (!text_properties)
|
||||
{
|
||||
odf_context()->styles_context()->create_style(L"", odf_types::style_family::Text, true, false, -1);
|
||||
text_properties = odf_context()->styles_context()->last_state()->get_text_properties();
|
||||
text_context->get_styles_context()->create_style(L"", odf_types::style_family::Text, true, false, -1);
|
||||
text_properties = text_context->get_styles_context()->last_state()->get_text_properties();
|
||||
styled = true;
|
||||
}
|
||||
convert(oox_run->rPr.GetPointer(), text_properties);
|
||||
}
|
||||
|
||||
odf_context()->text_context()->start_span(styled);
|
||||
text_context->start_span(styled);
|
||||
|
||||
if ((oox_run->rPr.IsInit()) && (oox_run->rPr->hlinkClick.IsInit()) && (oox_run->rPr->hlinkClick->id.IsInit()))
|
||||
{
|
||||
odf_writer::style_text_properties * text_properties = odf_context()->text_context()->get_text_properties();
|
||||
odf_writer::style_text_properties * text_properties = text_context->get_text_properties();
|
||||
|
||||
if (!text_properties->content_.fo_color_)
|
||||
{
|
||||
@ -2010,13 +2069,13 @@ void OoxConverter::convert(PPTX::Logic::Run *oox_run)
|
||||
text_properties->content_.style_text_underline_style_ = odf_types::line_style::Solid;
|
||||
|
||||
std::wstring hlink = find_link_by_id(oox_run->rPr->hlinkClick->id.get(), 2);
|
||||
odf_context()->text_context()->add_hyperlink(hlink, oox_run->GetText());
|
||||
text_context->add_hyperlink(hlink, oox_run->GetText());
|
||||
}
|
||||
else
|
||||
{
|
||||
odf_context()->text_context()->add_text_content( oox_run->GetText());
|
||||
text_context->add_text_content( oox_run->GetText());
|
||||
}
|
||||
odf_context()->text_context()->end_span();
|
||||
text_context->end_span();
|
||||
}
|
||||
void OoxConverter::convert(PPTX::Logic::Fld *oox_fld)
|
||||
{
|
||||
|
||||
@ -40,8 +40,8 @@
|
||||
#include "DocxConverter.h"
|
||||
#include "PptxConverter.h"
|
||||
|
||||
#include "../OdfFormat/office_document.h"
|
||||
#include "../OdfFormat/odf_conversion_context.h"
|
||||
|
||||
#include "../OdfFormat/odf_text_context.h"
|
||||
#include "../OdfFormat/odf_drawing_context.h"
|
||||
|
||||
@ -63,9 +63,13 @@
|
||||
#include "../../../ASCOfficePPTXFile/PPTXFormat/Logic/SmartArt.h"
|
||||
|
||||
#include "../../../Common/DocxFormat/Source/XlsxFormat/Worksheets/Sparkline.h"
|
||||
#include "../../../OfficeCryptReader/source/CryptTransform.h"
|
||||
#include "../../../DesktopEditor/common/Directory.h"
|
||||
|
||||
#define PROGRESSEVENT_ID 0
|
||||
|
||||
using namespace cpdoccore;
|
||||
|
||||
namespace Oox2Odf
|
||||
{
|
||||
static double pt2emu(double Val)
|
||||
@ -97,25 +101,16 @@ namespace Oox2Odf
|
||||
|
||||
impl_->convertDocument();
|
||||
}
|
||||
void Converter::write(const std::wstring & path) const
|
||||
void Converter::write(const std::wstring & out_path, const std::wstring & temp_path, const std::wstring & password) const
|
||||
{
|
||||
if (!impl_)return;
|
||||
|
||||
if (impl_->bUserStopConvert) return;
|
||||
|
||||
return impl_->write(path);
|
||||
return impl_->write(out_path, temp_path, password);
|
||||
}
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
double OoxConverter::getSystemDPI()
|
||||
{
|
||||
//При запросе системных настроек-проблема в linux без графического интерфейса.
|
||||
//Используется в GetMaxDigitSizePixels для измерения символов, можно указывать любой dpi,
|
||||
//потому что после измерения pix переводятся обратно в метрические величины.
|
||||
//Используется для конвертации картинок с процентными размерами oox->odf. Из редактора никогда не приходят относительные размеры,
|
||||
//думаю тут несущественнен dpi.
|
||||
return 96.;
|
||||
}
|
||||
|
||||
bool OoxConverter::UpdateProgress(long nComplete)
|
||||
{
|
||||
@ -131,6 +126,199 @@ bool OoxConverter::UpdateProgress(long nComplete)
|
||||
|
||||
return FALSE;
|
||||
}
|
||||
void OoxConverter::write(const std::wstring & out_path, const std::wstring & temp_path, const std::wstring & password)
|
||||
{
|
||||
if (!output_document)return;
|
||||
|
||||
if (password.empty())
|
||||
{
|
||||
output_document->write(out_path);
|
||||
}
|
||||
else
|
||||
{
|
||||
//encrypt files
|
||||
std::wstring temp_folder = NSDirectory::CreateDirectoryWithUniqueName(temp_path);
|
||||
output_document->write(temp_folder, true);
|
||||
|
||||
encrypt_document(password, temp_folder, out_path);
|
||||
|
||||
output_document->write_manifest(out_path);
|
||||
|
||||
NSDirectory::DeleteDirectory(temp_folder);
|
||||
}
|
||||
|
||||
if (UpdateProgress(1000000))return;
|
||||
}
|
||||
std::wstring EncodeBase64(const std::string & value)
|
||||
{
|
||||
int nLength = 0;
|
||||
char *pData = NULL;
|
||||
std::wstring result;
|
||||
|
||||
NSFile::CBase64Converter::Encode((BYTE*)value.c_str(), value.length(), pData, nLength, NSBase64::B64_BASE64_FLAG_NOCRLF);
|
||||
if (pData)
|
||||
{
|
||||
result = NSFile::CUtf8Converter::GetUnicodeStringFromUTF8((BYTE*)pData, nLength);
|
||||
delete []pData; pData = NULL;
|
||||
}
|
||||
return result;
|
||||
}
|
||||
bool OoxConverter::encrypt_document (const std::wstring &password, const std::wstring & srcPath, const std::wstring & dstPath)
|
||||
{
|
||||
odf_writer::package::manifect_file* manifest = output_document->get_manifest();
|
||||
if (!manifest) return false;
|
||||
|
||||
odf_writer::rels *rels = manifest->get_rels();
|
||||
|
||||
for (size_t i = 0; i < rels->relationships_.size(); i++)
|
||||
{
|
||||
if (rels->relationships_[i].target_ == L"/") continue;
|
||||
|
||||
std::wstring inp_file_name = srcPath + FILE_SEPARATOR_STR + rels->relationships_[i].target_;
|
||||
std::wstring out_file_name = dstPath + FILE_SEPARATOR_STR + rels->relationships_[i].target_;
|
||||
|
||||
if (std::wstring::npos != rels->relationships_[i].target_.find(L"/"))
|
||||
{
|
||||
std::vector<std::wstring> refs;
|
||||
boost::algorithm::split(refs, rels->relationships_[i].target_, boost::algorithm::is_any_of(L"/"), boost::algorithm::token_compress_on);
|
||||
|
||||
std::wstring folder = dstPath;
|
||||
for (size_t j = 0; j < refs.size() - 1; j++)
|
||||
{
|
||||
folder += FILE_SEPARATOR_STR + refs[j];
|
||||
NSDirectory::CreateDirectory(folder);
|
||||
}
|
||||
}
|
||||
|
||||
encrypt_file(password, inp_file_name, out_file_name, rels->relationships_[i].encryption_, rels->relationships_[i].size_);
|
||||
}
|
||||
}
|
||||
bool OoxConverter::encrypt_file (const std::wstring &password, const std::wstring & srcPath, const std::wstring & dstPath, std::wstring &encrypt_info, int &size)
|
||||
{
|
||||
CRYPT::ODFEncryptor encryptor;
|
||||
CRYPT::_odfCryptData cryptData;
|
||||
//-----------------------
|
||||
//aes
|
||||
cryptData.cipherAlgorithm = CRYPT_METHOD::AES_CBC;
|
||||
cryptData.start_hashAlgorithm = CRYPT_METHOD::SHA256;
|
||||
cryptData.start_hashSize = 32;
|
||||
|
||||
cryptData.spinCount = 100000;
|
||||
cryptData.keySize = 32;
|
||||
|
||||
cryptData.checksum_size = 1024;
|
||||
cryptData.checksum_hashAlgorithm = CRYPT_METHOD::SHA256;
|
||||
//-----------------------
|
||||
//blowfish
|
||||
//cryptData.cipherAlgorithm = CRYPT_METHOD::Blowfish_CFB;
|
||||
//cryptData.start_hashAlgorithm = CRYPT_METHOD::SHA1;
|
||||
//cryptData.start_hashSize = 20;
|
||||
|
||||
//cryptData.spinCount = 1024;
|
||||
//cryptData.keySize = 16;
|
||||
|
||||
//cryptData.checksum_size = 1024;
|
||||
//cryptData.checksum_hashAlgorithm = CRYPT_METHOD::SHA1;
|
||||
//-----------------------
|
||||
NSFile::CFileBinary file;
|
||||
|
||||
if (false == file.OpenFile(srcPath))
|
||||
return false;
|
||||
|
||||
DWORD size_inp = 0;
|
||||
size = file.GetFileSize();
|
||||
|
||||
unsigned char* data_inp = new unsigned char[size];
|
||||
unsigned char* data_out = NULL;
|
||||
|
||||
file.ReadFile(data_inp, size, size_inp);
|
||||
file.CloseFile();
|
||||
//------------------------------------------------------------------------------------------
|
||||
encryptor.SetCryptData(cryptData);
|
||||
|
||||
int size_out = encryptor.Encrypt(password, data_inp, size_inp, data_out);
|
||||
delete []data_inp;
|
||||
|
||||
encryptor.GetCryptData(cryptData);
|
||||
//------------------------------------------------------------------------------------------------------------
|
||||
if (!data_out) return false;
|
||||
|
||||
if (false == file.CreateFileW(dstPath)) return false;
|
||||
|
||||
file.WriteFile(data_out, size_out);
|
||||
file.CloseFile();
|
||||
delete []data_out;
|
||||
//------------------------------------------------------------------------------------------
|
||||
odf_writer::office_element_ptr encryption_elm;
|
||||
odf_writer::create_element (L"manifest", L"encryption-data", encryption_elm, odf_context());
|
||||
|
||||
encryption_elm->create_child_element(L"manifest", L"algorithm");
|
||||
encryption_elm->create_child_element(L"manifest", L"key-derivation");
|
||||
encryption_elm->create_child_element(L"manifest", L"start-key-generation");
|
||||
|
||||
odf_writer::manifest_encryption_data* encryption_data = dynamic_cast<odf_writer::manifest_encryption_data*>(encryption_elm.get());
|
||||
|
||||
if (!encryption_data) return false;
|
||||
|
||||
odf_writer::manifest_algorithm* algorithm = dynamic_cast<odf_writer::manifest_algorithm*>(encryption_data->algorithm_.get());
|
||||
odf_writer::manifest_key_derivation* key_derivation = dynamic_cast<odf_writer::manifest_key_derivation*>(encryption_data->key_derivation_.get());
|
||||
odf_writer::manifest_start_key_generation* start_key_generation = dynamic_cast<odf_writer::manifest_start_key_generation*>(encryption_data->start_key_generation_.get());
|
||||
|
||||
if (key_derivation)
|
||||
{
|
||||
key_derivation->salt_ = EncodeBase64(cryptData.saltValue);
|
||||
key_derivation->iteration_count_ = cryptData.spinCount;
|
||||
key_derivation->key_size_ = cryptData.keySize;
|
||||
}
|
||||
//------------------------------------------------------------------------------------------
|
||||
if (start_key_generation)
|
||||
{
|
||||
switch(cryptData.start_hashAlgorithm)
|
||||
{
|
||||
case CRYPT_METHOD::SHA1: start_key_generation->start_key_generation_name_ = L"SHA1"; break;
|
||||
case CRYPT_METHOD::SHA256: start_key_generation->start_key_generation_name_ = L"http://www.w3.org/2000/09/xmldsig#sha256"; break;
|
||||
case CRYPT_METHOD::SHA512: start_key_generation->start_key_generation_name_ = L"http://www.w3.org/2000/09/xmldsig#sha512"; break;
|
||||
}
|
||||
start_key_generation->key_size_ = cryptData.start_hashSize;
|
||||
}
|
||||
//------------------------------------------------------------------------------------------
|
||||
if (algorithm)
|
||||
{
|
||||
algorithm->initialisation_vector_ = EncodeBase64(cryptData.initializationVector);
|
||||
|
||||
switch(cryptData.cipherAlgorithm)
|
||||
{
|
||||
case CRYPT_METHOD::AES_CBC: algorithm->algorithm_name_ = L"http://www.w3.org/2001/04/xmlenc#aes256-cbc"; break;
|
||||
case CRYPT_METHOD::Blowfish_CFB: algorithm->algorithm_name_ = L"Blowfish CFB"; break;
|
||||
}
|
||||
}
|
||||
//------------------------------------------------------------------------------------------
|
||||
if (encryption_data)
|
||||
{
|
||||
encryption_data->checksum_= EncodeBase64(cryptData.checksum);
|
||||
|
||||
switch(cryptData.checksum_hashAlgorithm)
|
||||
{
|
||||
case CRYPT_METHOD::SHA1: encryption_data->checksum_type_ = L"SHA1"; break;
|
||||
case CRYPT_METHOD::SHA256: encryption_data->checksum_type_ = L"urn:oasis:names:tc:opendocument:xmlns:manifest:1.0#sha256"; break;
|
||||
case CRYPT_METHOD::SHA512: encryption_data->checksum_type_ = L"urn:oasis:names:tc:opendocument:xmlns:manifest:1.0#sha512"; break;
|
||||
}
|
||||
if (cryptData.checksum_size == 1024)
|
||||
{
|
||||
if (cryptData.checksum_hashAlgorithm == CRYPT_METHOD::SHA1)
|
||||
encryption_data->checksum_type_ += L"/1K";
|
||||
else
|
||||
encryption_data->checksum_type_ += L"-1k";
|
||||
}
|
||||
}
|
||||
//------------------------------------------------------------------------------------------
|
||||
std::wstringstream strm;
|
||||
encryption_elm->serialize(strm);
|
||||
|
||||
encrypt_info = strm.str();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void OoxConverter::set_fonts_directory(const std::wstring &fontsPath)
|
||||
{
|
||||
|
||||
@ -64,6 +64,11 @@ namespace cpdoccore
|
||||
class style_table_column_properties;
|
||||
class style_chart_properties;
|
||||
class style_drawing_page_properties;
|
||||
|
||||
namespace package
|
||||
{
|
||||
class odf_document;
|
||||
}
|
||||
}
|
||||
}
|
||||
namespace OOX
|
||||
@ -337,31 +342,33 @@ namespace Oox2Odf
|
||||
{
|
||||
public:
|
||||
virtual void convertDocument() = 0;
|
||||
virtual void write(const std::wstring & path) = 0;
|
||||
|
||||
void write(const std::wstring & out_path, const std::wstring & temp_path, const std::wstring & password);
|
||||
|
||||
OoxConverter(const ProgressCallback* CallBack = NULL){
|
||||
oox_current_child_document = NULL;
|
||||
|
||||
pCallBack = CallBack;
|
||||
bUserStopConvert = 0;
|
||||
currentSystemDPI = getSystemDPI();
|
||||
}
|
||||
|
||||
void set_fonts_directory (const std::wstring & fontsPath);
|
||||
|
||||
const ProgressCallback* pCallBack;
|
||||
short bUserStopConvert;
|
||||
bool UpdateProgress(long nComplete);
|
||||
bool UpdateProgress(long nComplete);
|
||||
|
||||
bool encrypt_document (const std::wstring &password, const std::wstring & srcPath, const std::wstring & dstPath);
|
||||
bool encrypt_file (const std::wstring &password, const std::wstring & srcPath, const std::wstring & dstPath, std::wstring &encrypt_info, int &size);
|
||||
|
||||
double currentSystemDPI;
|
||||
double getSystemDPI();
|
||||
|
||||
//.......................................................................................................................
|
||||
virtual OOX::IFileContainer *current_document() = 0;
|
||||
virtual OOX::IFileContainer *current_document() = 0;
|
||||
virtual cpdoccore::odf_writer::odf_conversion_context *odf_context() = 0;
|
||||
virtual PPTX::Theme *oox_theme() = 0;
|
||||
virtual PPTX::Logic::ClrMap *oox_clrMap() {return NULL;}
|
||||
|
||||
cpdoccore::odf_writer::package::odf_document *output_document;
|
||||
|
||||
std::wstring find_link_by (NSCommon::smart_ptr<OOX::File> & oFile, int type);
|
||||
virtual std::wstring find_link_by_id(std::wstring sId, int t) = 0;
|
||||
virtual NSCommon::smart_ptr<OOX::File> find_file_by_id(std::wstring sId) = 0;
|
||||
|
||||
@ -126,14 +126,6 @@ DocxConverter::~DocxConverter()
|
||||
if (docx_document) delete docx_document; docx_document = NULL;
|
||||
if (output_document) delete output_document; output_document = NULL;
|
||||
}
|
||||
void DocxConverter::write(const std::wstring & path)
|
||||
{
|
||||
if (!output_document)return;
|
||||
|
||||
output_document->write(path);
|
||||
|
||||
if (UpdateProgress(1000000))return;
|
||||
}
|
||||
odf_writer::odf_conversion_context* DocxConverter::odf_context()
|
||||
{
|
||||
return odt_context;
|
||||
@ -437,7 +429,10 @@ void DocxConverter::convert(OOX::Logic::CParagraph *oox_paragraph)
|
||||
odt_context->text_context()->set_KeepNextParagraph(false);
|
||||
}
|
||||
//---------------------------------------------------------------------------------------------------------------------
|
||||
current_font_size.erase(current_font_size.begin() + 1, current_font_size.end());
|
||||
if (false == current_font_size.empty())
|
||||
{
|
||||
current_font_size.erase(current_font_size.begin() + 1, current_font_size.end());
|
||||
}
|
||||
|
||||
bool bStyled = false;
|
||||
bool bStartNewParagraph = !odt_context->text_context()->get_KeepNextParagraph();
|
||||
@ -1267,58 +1262,11 @@ void DocxConverter::convert(OOX::Logic::CParagraphProperty *oox_paragraph_pr, cp
|
||||
}
|
||||
if (oox_paragraph_pr->m_oShd.IsInit())
|
||||
{
|
||||
int type_shading = 100; //solid
|
||||
if (oox_paragraph_pr->m_oShd->m_oVal.IsInit())
|
||||
{
|
||||
switch(oox_paragraph_pr->m_oShd->m_oVal->GetValue())
|
||||
{
|
||||
case SimpleTypes::shdClear : type_shading = 0; break;
|
||||
case SimpleTypes::shdNil : type_shading = 0; break;
|
||||
case SimpleTypes::shdPct10 : type_shading = 10; break;;
|
||||
case SimpleTypes::shdPct12 : type_shading = 12; break;
|
||||
case SimpleTypes::shdPct15 : type_shading = 15; break;
|
||||
case SimpleTypes::shdPct20 : type_shading = 20; break;
|
||||
case SimpleTypes::shdPct25 : type_shading = 25; break;
|
||||
case SimpleTypes::shdPct30 : type_shading = 30; break;
|
||||
case SimpleTypes::shdPct35 : type_shading = 35; break;
|
||||
case SimpleTypes::shdPct37 : type_shading = 37; break;
|
||||
case SimpleTypes::shdPct40 : type_shading = 40; break;
|
||||
case SimpleTypes::shdPct45 : type_shading = 45; break;
|
||||
case SimpleTypes::shdPct5 : type_shading = 5; break;
|
||||
case SimpleTypes::shdPct55 : type_shading = 55; break;
|
||||
case SimpleTypes::shdPct60 : type_shading = 60; break;
|
||||
case SimpleTypes::shdPct62 : type_shading = 62; break;
|
||||
case SimpleTypes::shdPct65 : type_shading = 65; break;
|
||||
case SimpleTypes::shdPct70 : type_shading = 70; break;
|
||||
case SimpleTypes::shdPct75 : type_shading = 75; break;
|
||||
case SimpleTypes::shdPct80 : type_shading = 80; break;
|
||||
case SimpleTypes::shdPct85 : type_shading = 85; break;
|
||||
case SimpleTypes::shdPct87 : type_shading = 87; break;
|
||||
case SimpleTypes::shdPct90 : type_shading = 90; break;
|
||||
case SimpleTypes::shdPct95 : type_shading = 95; break;
|
||||
case SimpleTypes::shdSolid : type_shading = 100;break;
|
||||
//case SimpleTypes::shdDiagCross : type_shading = 2; break;
|
||||
//case SimpleTypes::shdDiagStripe : type_shading = 3; break;
|
||||
//case SimpleTypes::shdHorzCross : type_shading = 4; break;
|
||||
//case SimpleTypes::shdHorzStripe : type_shading = 6; break;
|
||||
//case SimpleTypes::shdReverseDiagStripe : type_shading = 7; break;
|
||||
//case SimpleTypes::shdThinDiagCross : type_shading = 8; break;
|
||||
//case SimpleTypes::shdThinDiagStripe : type_shading = 9; break;
|
||||
//case SimpleTypes::shdThinHorzCross : type_shading = 10; break;
|
||||
//case SimpleTypes::shdThinHorzStripe : type_shading = 11; break;
|
||||
//case SimpleTypes::shdThinReverseDiagStripe : type_shading = 12; break;
|
||||
//case SimpleTypes::shdThinVertStripe : type_shading = 13; break;
|
||||
//case SimpleTypes::shdVertStripe : type_shading = 14; break;
|
||||
}
|
||||
}
|
||||
if (type_shading != 0)
|
||||
{
|
||||
_CP_OPT(odf_types::color) odf_color;
|
||||
convert(oox_paragraph_pr->m_oShd->m_oFill.GetPointer(), oox_paragraph_pr->m_oShd->m_oThemeFill.GetPointer(),
|
||||
oox_paragraph_pr->m_oShd->m_oThemeFillTint.GetPointer(), oox_paragraph_pr->m_oShd->m_oThemeShade.GetPointer(), odf_color);
|
||||
if (odf_color)
|
||||
paragraph_properties->content_.fo_background_color_ = *odf_color;
|
||||
}
|
||||
_CP_OPT(odf_types::color) odf_color;
|
||||
convert(oox_paragraph_pr->m_oShd->m_oFill.GetPointer(), oox_paragraph_pr->m_oShd->m_oThemeFill.GetPointer(),
|
||||
oox_paragraph_pr->m_oShd->m_oThemeFillTint.GetPointer(), oox_paragraph_pr->m_oShd->m_oThemeShade.GetPointer(), odf_color);
|
||||
if (odf_color)
|
||||
paragraph_properties->content_.fo_background_color_ = *odf_color;
|
||||
}
|
||||
if (oox_paragraph_pr->m_oTextDirection.IsInit() && oox_paragraph_pr->m_oTextDirection->m_oVal.IsInit())
|
||||
{
|
||||
@ -2159,7 +2107,7 @@ void DocxConverter::convert(ComplexTypes::Word::CTblWidth *oox_size, _CP_OPT(odf
|
||||
//tblwidthNil = 2,
|
||||
//tblwidthPct = 3
|
||||
}
|
||||
void DocxConverter::convert(OOX::Logic::CRunProperty *oox_run_pr, odf_writer::style_text_properties * text_properties)
|
||||
void DocxConverter::convert(OOX::Logic::CRunProperty *oox_run_pr, odf_writer::style_text_properties * text_properties, bool is_list_styles)
|
||||
{
|
||||
if (oox_run_pr == NULL) return;
|
||||
if (text_properties == NULL) return;
|
||||
@ -2167,7 +2115,20 @@ void DocxConverter::convert(OOX::Logic::CRunProperty *oox_run_pr, odf_writer::st
|
||||
if (oox_run_pr->m_oRStyle.IsInit() && oox_run_pr->m_oRStyle->m_sVal.IsInit())
|
||||
{
|
||||
std::wstring style_name = *oox_run_pr->m_oRStyle->m_sVal;
|
||||
odt_context->styles_context()->last_state()->set_parent_style_name(style_name);
|
||||
|
||||
odf_writer::odf_style_state_ptr style_state;
|
||||
//if (is_list_styles)
|
||||
//{
|
||||
// style_state = odt_context->styles_context()->lists_styles()->last_state();
|
||||
//}
|
||||
//else
|
||||
{
|
||||
style_state = odt_context->styles_context()->last_state();
|
||||
}
|
||||
if (style_state)
|
||||
{
|
||||
style_state->set_parent_style_name(style_name);
|
||||
}
|
||||
|
||||
odf_writer::style_text_properties parent_text_properties;
|
||||
odt_context->styles_context()->calc_text_properties(style_name, odf_types::style_family::Text, &parent_text_properties.content_);
|
||||
@ -3280,7 +3241,7 @@ void DocxConverter::convert(OOX::Numbering::CLvl* oox_num_lvl)
|
||||
odf_writer::odf_style_context* styles_context = odf_context()->page_layout_context()->get_local_styles_context();
|
||||
|
||||
odf_writer::style_text_properties *text_props = odt_context->styles_context()->lists_styles().get_text_properties();
|
||||
convert(oox_num_lvl->m_oRPr.GetPointer(), text_props);
|
||||
convert(oox_num_lvl->m_oRPr.GetPointer(), text_props, true);
|
||||
|
||||
//create text style for symbols list НА ЛОКАЛЬНОМ контексте - иначе пересечение имен стилей (todoo вытащить генерацию имен в общую часть)
|
||||
styles_context->create_style(L"", odf_types::style_family::Text, false, true, -1);
|
||||
|
||||
@ -144,9 +144,8 @@ namespace Oox2Odf
|
||||
~DocxConverter();
|
||||
|
||||
virtual void convertDocument();
|
||||
virtual void write(const std::wstring & path);
|
||||
|
||||
virtual OOX::IFileContainer *current_document();
|
||||
virtual OOX::IFileContainer *current_document();
|
||||
virtual odf_writer::odf_conversion_context *odf_context();
|
||||
virtual PPTX::Theme *oox_theme();
|
||||
virtual PPTX::Logic::ClrMap *oox_clrMap();
|
||||
@ -165,7 +164,6 @@ namespace Oox2Odf
|
||||
bool bContinue = false;
|
||||
} *current_section_properties;
|
||||
OOX::CDocx *docx_document;
|
||||
cpdoccore::odf_writer::package::odf_document *output_document;
|
||||
|
||||
odf_writer::odt_conversion_context *odt_context;
|
||||
OOX::Logic::CSectionProperty *last_section_properties;
|
||||
@ -189,7 +187,7 @@ namespace Oox2Odf
|
||||
void convert(OOX::Logic::CRun *oox_run);
|
||||
void convert(OOX::Logic::CParagraphProperty *oox_para_prop, odf_writer::style_paragraph_properties *paragraph_properties);
|
||||
void convert(ComplexTypes::Word::CFramePr *oox_frame_pr, odf_writer::style_paragraph_properties *paragraph_properties);
|
||||
void convert(OOX::Logic::CRunProperty *oox_run_prop, odf_writer::style_text_properties *text_properties);
|
||||
void convert(OOX::Logic::CRunProperty *oox_run_prop, odf_writer::style_text_properties *text_properties, bool is_list_styles = false);
|
||||
void convert(ComplexTypes::Word::CShading *oox_shading, odf_writer::style_text_properties *text_properties );
|
||||
void convert(OOX::Logic::CFldSimple *oox_fld);
|
||||
void convert(OOX::Logic::CFldChar *oox_fld);
|
||||
|
||||
@ -40,15 +40,13 @@ namespace Oox2Odf
|
||||
|
||||
class Converter
|
||||
{
|
||||
|
||||
public:
|
||||
Converter(const std::wstring & path, const std::wstring & type, const std::wstring & fontsPath, const ProgressCallback* ffCallBack);
|
||||
virtual ~Converter();
|
||||
|
||||
public:
|
||||
void convert();
|
||||
|
||||
void write(const std::wstring & path) const;
|
||||
void write(const std::wstring & out_path, const std::wstring & temp_path, const std::wstring & password) const;
|
||||
|
||||
OoxConverter * get_ooxConverter() { return impl_; }
|
||||
|
||||
|
||||
@ -122,14 +122,6 @@ PptxConverter::~PptxConverter()
|
||||
if (pptx_document) delete pptx_document; pptx_document = NULL;
|
||||
if (output_document) delete output_document; output_document = NULL;
|
||||
}
|
||||
void PptxConverter::write(const std::wstring & path)
|
||||
{
|
||||
if (!output_document)return;
|
||||
|
||||
output_document->write(path);
|
||||
|
||||
if (UpdateProgress(1000000))return;
|
||||
}
|
||||
odf_writer::odf_conversion_context* PptxConverter::odf_context()
|
||||
{
|
||||
return odp_context;
|
||||
@ -954,7 +946,9 @@ void PptxConverter::convert(PPTX::Logic::TableCell *oox_table_cell, int numCol)
|
||||
covered = true;
|
||||
|
||||
if (oox_table_cell->CellProperties.IsInit())
|
||||
{
|
||||
styled = (oox_table_cell->CellProperties->is_empty == false);
|
||||
}
|
||||
|
||||
odp_context->slide_context()->start_table_cell(numCol, covered, styled);
|
||||
|
||||
@ -1193,8 +1187,8 @@ bool PptxConverter::convert(PPTX::Logic::TableCellProperties *oox_table_cell_pr)
|
||||
{
|
||||
if (!oox_table_cell_pr) return false;
|
||||
|
||||
odf_writer::style_table_cell_properties *odf_cell_props = odp_context->styles_context()->last_state()->get_table_cell_properties();
|
||||
odf_writer::style_paragraph_properties *odf_para_props = odp_context->styles_context()->last_state(odf_types::style_family::TableCell)->get_paragraph_properties();
|
||||
odf_writer::style_table_cell_properties *odf_cell_props = odp_context->slide_context()->get_styles_context()->last_state()->get_table_cell_properties();
|
||||
odf_writer::style_paragraph_properties *odf_para_props = odp_context->slide_context()->get_styles_context()->last_state(odf_types::style_family::TableCell)->get_paragraph_properties();
|
||||
|
||||
if (!odf_para_props) return false;
|
||||
|
||||
|
||||
@ -114,9 +114,8 @@ namespace Oox2Odf
|
||||
~PptxConverter();
|
||||
|
||||
virtual void convertDocument();
|
||||
virtual void write(const std::wstring & path);
|
||||
|
||||
virtual OOX::IFileContainer *current_document();
|
||||
virtual OOX::IFileContainer *current_document();
|
||||
virtual odf_writer::odf_conversion_context *odf_context();
|
||||
virtual PPTX::Theme *oox_theme();
|
||||
virtual PPTX::Logic::ClrMap *oox_clrMap();
|
||||
@ -163,7 +162,6 @@ private:
|
||||
|
||||
PPTX::Document *pptx_document;
|
||||
PPTX::Presentation *presentation;
|
||||
cpdoccore::odf_writer::package::odf_document *output_document;
|
||||
|
||||
PPTX::Theme *current_theme;
|
||||
PPTX::TableStyles *current_tableStyles;
|
||||
|
||||
@ -84,15 +84,6 @@ XlsxConverter::~XlsxConverter()
|
||||
if (xlsx_document) delete xlsx_document; xlsx_document = NULL;
|
||||
if (output_document) delete output_document; output_document = NULL;
|
||||
}
|
||||
void XlsxConverter::write(const std::wstring & path)
|
||||
{
|
||||
if (!output_document)return;
|
||||
output_document->write(path);
|
||||
|
||||
delete output_document; output_document = NULL;
|
||||
|
||||
if (UpdateProgress(1000000))return;
|
||||
}
|
||||
odf_writer::odf_conversion_context* XlsxConverter::odf_context()
|
||||
{
|
||||
return ods_context;
|
||||
@ -489,10 +480,121 @@ void XlsxConverter::convert(OOX::Spreadsheet::CHyperlink *oox_hyperlink,OOX::Spr
|
||||
|
||||
}
|
||||
|
||||
void XlsxConverter::convert(OOX::Spreadsheet::CRow *oox_row)
|
||||
void XlsxConverter::convert(OOX::Spreadsheet::CRow *oox_row, OOX::Spreadsheet::CRow *oox_row_prev)
|
||||
{
|
||||
if (oox_row == NULL)return;
|
||||
|
||||
if (oox_row_prev)
|
||||
{
|
||||
if (oox_row_prev->m_arrItems.empty() &&
|
||||
oox_row->m_arrItems.empty())
|
||||
{
|
||||
bool bEqual = true;
|
||||
|
||||
if (oox_row->m_oCollapsed.IsInit())
|
||||
{
|
||||
if (oox_row_prev->m_oCollapsed.IsInit())
|
||||
{
|
||||
}
|
||||
else bEqual = false;
|
||||
}
|
||||
if (bEqual && oox_row->m_oCustomFormat.IsInit())
|
||||
{
|
||||
if (oox_row_prev->m_oCustomFormat.IsInit())
|
||||
{
|
||||
if (oox_row->m_oCustomFormat->GetValue() != oox_row_prev->m_oCustomFormat->GetValue()) bEqual = false;
|
||||
}
|
||||
else bEqual = false;
|
||||
}
|
||||
if (bEqual && oox_row->m_oCustomHeight.IsInit())
|
||||
{
|
||||
if (oox_row_prev->m_oCustomHeight.IsInit())
|
||||
{
|
||||
if (oox_row->m_oCustomHeight->GetValue() != oox_row_prev->m_oCustomHeight->GetValue()) bEqual = false;
|
||||
}
|
||||
else bEqual = false;
|
||||
}
|
||||
if (bEqual && oox_row->m_oHidden.IsInit())
|
||||
{
|
||||
if (oox_row_prev->m_oHidden.IsInit())
|
||||
{
|
||||
if (oox_row->m_oHidden->GetValue() != oox_row_prev->m_oHidden->GetValue()) bEqual = false;
|
||||
}
|
||||
else bEqual = false;
|
||||
}
|
||||
if (bEqual && oox_row->m_oHt.IsInit())
|
||||
{
|
||||
if (oox_row_prev->m_oHt.IsInit())
|
||||
{
|
||||
if (oox_row->m_oHt->GetValue() != oox_row_prev->m_oHt->GetValue()) bEqual = false;
|
||||
}
|
||||
else bEqual = false;
|
||||
}
|
||||
if (bEqual && oox_row->m_oOutlineLevel.IsInit())
|
||||
{
|
||||
if (oox_row_prev->m_oOutlineLevel.IsInit())
|
||||
{
|
||||
if (oox_row->m_oOutlineLevel->GetValue() != oox_row_prev->m_oOutlineLevel->GetValue()) bEqual = false;
|
||||
}
|
||||
else bEqual = false;
|
||||
}
|
||||
if (bEqual && oox_row->m_oPh.IsInit())
|
||||
{
|
||||
if (oox_row_prev->m_oPh.IsInit())
|
||||
{
|
||||
if (oox_row->m_oPh->GetValue() != oox_row_prev->m_oPh->GetValue()) bEqual = false;
|
||||
}
|
||||
else bEqual = false;
|
||||
}
|
||||
if (bEqual && oox_row->m_oR.IsInit())
|
||||
{
|
||||
if (oox_row_prev->m_oR.IsInit())
|
||||
{
|
||||
if (oox_row->m_oR->GetValue() != oox_row_prev->m_oR->GetValue() + 1) bEqual = false;
|
||||
}
|
||||
else bEqual = false;
|
||||
}
|
||||
if (bEqual && oox_row->m_oS.IsInit())
|
||||
{
|
||||
if (oox_row_prev->m_oS.IsInit())
|
||||
{
|
||||
if (oox_row->m_oS->GetValue() != oox_row_prev->m_oS->GetValue()) bEqual = false;
|
||||
}
|
||||
else bEqual = false;
|
||||
}
|
||||
if (bEqual && oox_row->m_oThickBot.IsInit())
|
||||
{
|
||||
if (oox_row_prev->m_oThickBot.IsInit())
|
||||
{
|
||||
if (oox_row->m_oThickBot->GetValue() != oox_row_prev->m_oThickBot->GetValue()) bEqual = false;
|
||||
}
|
||||
else bEqual = false;
|
||||
}
|
||||
if (bEqual && oox_row->m_oThickTop.IsInit())
|
||||
{
|
||||
if (oox_row_prev->m_oThickTop.IsInit())
|
||||
{
|
||||
if (oox_row->m_oThickTop->GetValue() != oox_row_prev->m_oThickTop->GetValue()) bEqual = false;
|
||||
}
|
||||
else bEqual = false;
|
||||
}
|
||||
if (bEqual && oox_row->m_oDyDescent.IsInit())
|
||||
{
|
||||
if (oox_row_prev->m_oDyDescent.IsInit())
|
||||
{
|
||||
if (oox_row->m_oDyDescent->GetValue() != oox_row_prev->m_oDyDescent->GetValue()) bEqual = false;
|
||||
}
|
||||
else bEqual = false;
|
||||
}
|
||||
|
||||
if (bEqual)
|
||||
{
|
||||
ods_context->add_row_repeated();
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
int row_number = oox_row->m_oR.IsInit() ? oox_row->m_oR->GetValue() : -1;
|
||||
|
||||
bool _default = true;
|
||||
@ -916,11 +1018,10 @@ void XlsxConverter::convert(OOX::Spreadsheet::CWorkbookView *oox_book_views)
|
||||
{
|
||||
int table_id = oox_book_views->m_oActiveTab->GetValue();
|
||||
|
||||
std::map<int, OOX::Spreadsheet::CSheet*>::iterator pFind = Workbook->m_oSheets->mapSheets.find(table_id);
|
||||
|
||||
if (pFind != Workbook->m_oSheets->mapSheets.end())
|
||||
if (table_id >= 0 && table_id < Workbook->m_oSheets->m_arrItems.size())
|
||||
{
|
||||
ods_context->settings_context()->add_property(L"ActiveTable", L"string", pFind->second->m_oName.get2());
|
||||
ods_context->settings_context()->add_property(L"ActiveTable", L"string",
|
||||
Workbook->m_oSheets->m_arrItems[table_id]->m_oName.get2());
|
||||
}
|
||||
}
|
||||
if (oox_book_views->m_oShowSheetTabs.IsInit())
|
||||
|
||||
@ -135,9 +135,8 @@ namespace Oox2Odf
|
||||
~XlsxConverter();
|
||||
|
||||
virtual void convertDocument();
|
||||
virtual void write(const std::wstring & path);
|
||||
|
||||
virtual OOX::IFileContainer *current_document();
|
||||
virtual OOX::IFileContainer *current_document();
|
||||
virtual odf_writer::odf_conversion_context *odf_context();
|
||||
virtual PPTX::Theme *oox_theme();
|
||||
virtual std::wstring find_link_by_id (std::wstring sId, int t);
|
||||
@ -150,8 +149,6 @@ namespace Oox2Odf
|
||||
|
||||
odf_writer::ods_conversion_context *ods_context;
|
||||
|
||||
odf_writer::package::odf_document *output_document;
|
||||
|
||||
void convert_sheets();
|
||||
void convert_styles();
|
||||
|
||||
@ -163,7 +160,7 @@ namespace Oox2Odf
|
||||
void convert(OOX::Spreadsheet::CHeaderFooter *oox_header_footer);
|
||||
|
||||
void convert(OOX::Spreadsheet::CCol *oox_column);
|
||||
void convert(OOX::Spreadsheet::CRow *oox_row);
|
||||
void convert(OOX::Spreadsheet::CRow *oox_row, OOX::Spreadsheet::CRow *oox_row_prev);
|
||||
void convert(OOX::Spreadsheet::CCell *oox_cell);
|
||||
|
||||
void convert(OOX::Spreadsheet::CRun *oox_text_run);
|
||||
|
||||
151
ASCOfficeOdfFileW/source/utils.cpp
Normal file
151
ASCOfficeOdfFileW/source/utils.cpp
Normal file
@ -0,0 +1,151 @@
|
||||
/*
|
||||
* (c) Copyright Ascensio System SIA 2010-2018
|
||||
*
|
||||
* This program is a free software product. You can redistribute it and/or
|
||||
* modify it under the terms of the GNU Affero General Public License (AGPL)
|
||||
* version 3 as published by the Free Software Foundation. In accordance with
|
||||
* Section 7(a) of the GNU AGPL its Section 15 shall be amended to the effect
|
||||
* that Ascensio System SIA expressly excludes the warranty of non-infringement
|
||||
* of any third-party rights.
|
||||
*
|
||||
* This program is distributed WITHOUT ANY WARRANTY; without even the implied
|
||||
* warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For
|
||||
* details, see the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html
|
||||
*
|
||||
* You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia,
|
||||
* EU, LV-1021.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of the Program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU AGPL version 3.
|
||||
*
|
||||
* Pursuant to Section 7(b) of the License you must retain the original Product
|
||||
* logo when distributing the program. Pursuant to Section 7(e) we decline to
|
||||
* grant you any rights under trademark law for use of our trademarks.
|
||||
*
|
||||
* All the Product's GUI elements, including illustrations and icon sets, as
|
||||
* well as technical writing content are licensed under the terms of the
|
||||
* Creative Commons Attribution-ShareAlike 4.0 International. See the License
|
||||
* terms at http://creativecommons.org/licenses/by-sa/4.0/legalcode
|
||||
*
|
||||
*/
|
||||
|
||||
#include "utils.h"
|
||||
|
||||
#include <vector>
|
||||
|
||||
#if defined(_WIN32) || defined(_WIN64)
|
||||
#include <windows.h>
|
||||
#include <gdiplus.h>
|
||||
#pragma comment(lib, "gdiplus.lib")
|
||||
#endif
|
||||
|
||||
#include "../../../../DesktopEditor/raster/BgraFrame.h"
|
||||
#include "../../../../ASCOfficeOdfFile/src/docx/measuredigits.h"
|
||||
|
||||
#ifndef min
|
||||
#define min(a,b) ((a) < (b) ? (a) : (b))
|
||||
#endif
|
||||
#ifndef max
|
||||
#define max(a,b) ((a) > (b) ? (a) : (b))
|
||||
#endif
|
||||
|
||||
namespace _graphics_utils_
|
||||
{
|
||||
bool GetResolution(const wchar_t* fileName, double & Width, double &Height) //pt
|
||||
{
|
||||
bool result =false;
|
||||
|
||||
CBgraFrame image;
|
||||
if (result = image.OpenFile(fileName, 0 ))
|
||||
{
|
||||
Width = image.get_Width();
|
||||
Height = image.get_Height();
|
||||
|
||||
result = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
#if defined(_WIN32) || defined(_WIN64)
|
||||
Gdiplus::GdiplusStartupInput gdiplusStartupInput;
|
||||
ULONG_PTR gdiplusToken=0;
|
||||
Gdiplus::GdiplusStartup(&gdiplusToken, &gdiplusStartupInput, NULL);
|
||||
|
||||
Gdiplus::Bitmap *file = new Gdiplus::Bitmap(fileName,false);
|
||||
if ((file) && (file->GetLastStatus()==Gdiplus::Ok))
|
||||
{
|
||||
Height = file->GetHeight();
|
||||
Width = file->GetWidth();
|
||||
|
||||
double dpi_x = file->GetHorizontalResolution();
|
||||
double dpi_y = file->GetVerticalResolution();
|
||||
|
||||
if (dpi_x <1 )dpi_x = 96;
|
||||
if (dpi_y <1 )dpi_y = 96;
|
||||
|
||||
Height = Height *72. / dpi_y;
|
||||
Width = Width * 72. /dpi_x;
|
||||
|
||||
result = true;
|
||||
delete file;
|
||||
}
|
||||
Gdiplus::GdiplusShutdown(gdiplusToken);
|
||||
#endif
|
||||
}
|
||||
return result;
|
||||
}
|
||||
double calculate_size_symbol_win(std::wstring name, double size, bool italic, bool bold, std::wstring test_str)
|
||||
{
|
||||
double result =0;
|
||||
#if defined(_WIN32) || defined(_WIN64)
|
||||
Gdiplus::GdiplusStartupInput gdiplusStartupInput;
|
||||
ULONG_PTR gdiplusToken=0;
|
||||
Gdiplus::GdiplusStartup(&gdiplusToken, &gdiplusStartupInput, NULL);
|
||||
////
|
||||
bool to_one_char = false;
|
||||
if (test_str.length() <1 )
|
||||
{
|
||||
test_str = L"0123456789";
|
||||
to_one_char = true;
|
||||
}
|
||||
|
||||
int style = Gdiplus::FontStyleRegular;
|
||||
if (bold && italic) style = Gdiplus::FontStyleBoldItalic;
|
||||
else if (bold) style = Gdiplus::FontStyleBold;
|
||||
else if (italic) style = Gdiplus::FontStyleItalic;
|
||||
|
||||
Gdiplus::Graphics * gr = new Gdiplus::Graphics(GetWindowDC(NULL));
|
||||
if (gr)
|
||||
{
|
||||
Gdiplus::Font *font = new Gdiplus::Font(name.c_str(),size,style);
|
||||
if (font)
|
||||
{
|
||||
|
||||
Gdiplus::SizeF layout;
|
||||
|
||||
Gdiplus::RectF bound;
|
||||
Gdiplus::Status res = gr->MeasureString(test_str.c_str(),test_str.length(),font,layout,&bound);
|
||||
|
||||
if (res==0)result = (bound.Width - 2);
|
||||
if (to_one_char) result /= test_str.length();
|
||||
|
||||
//normalize to dpi = 96;
|
||||
double dpi = gr->GetDpiX();
|
||||
|
||||
result = result * 96./dpi;
|
||||
|
||||
delete font;
|
||||
}
|
||||
delete gr;
|
||||
}
|
||||
Gdiplus::GdiplusShutdown(gdiplusToken);
|
||||
#endif
|
||||
return result;
|
||||
}
|
||||
double calculate_size_symbol_asc(std::wstring name, double size, bool italic, bool bold , NSFonts::IApplicationFonts *appFonts)
|
||||
{
|
||||
std::pair<float,float> val = cpdoccore::utils::GetMaxDigitSizePixels(name, size, 96., 0 , appFonts);
|
||||
|
||||
return val.first;
|
||||
}
|
||||
};
|
||||
@ -32,115 +32,15 @@
|
||||
#pragma once
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
#if defined(_WIN32) || defined(_WIN64)
|
||||
#include <windows.h>
|
||||
#include <gdiplus.h>
|
||||
#pragma comment(lib, "gdiplus.lib")
|
||||
#endif
|
||||
|
||||
#include "../../../DesktopEditor/raster/BgraFrame.h"
|
||||
#include "../../../ASCOfficeOdfFile/src/docx/measuredigits.h"
|
||||
|
||||
class CFontManager;
|
||||
namespace NSFonts
|
||||
{
|
||||
class IApplicationFonts;
|
||||
}
|
||||
|
||||
namespace _graphics_utils_
|
||||
{
|
||||
bool static GetResolution(const wchar_t* fileName, double & Width, double &Height) //pt
|
||||
{
|
||||
bool result =false;
|
||||
|
||||
CBgraFrame image;
|
||||
if (result = image.OpenFile(fileName, 0 ))
|
||||
{
|
||||
Width = image.get_Width();
|
||||
Height = image.get_Height();
|
||||
|
||||
result = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
#if defined(_WIN32) || defined(_WIN64)
|
||||
Gdiplus::GdiplusStartupInput gdiplusStartupInput;
|
||||
ULONG_PTR gdiplusToken=0;
|
||||
Gdiplus::GdiplusStartup(&gdiplusToken, &gdiplusStartupInput, NULL);
|
||||
|
||||
Gdiplus::Bitmap *file = new Gdiplus::Bitmap(fileName,false);
|
||||
if ((file) && (file->GetLastStatus()==Gdiplus::Ok))
|
||||
{
|
||||
Height = file->GetHeight();
|
||||
Width = file->GetWidth();
|
||||
|
||||
double dpi_x = file->GetHorizontalResolution();
|
||||
double dpi_y = file->GetVerticalResolution();
|
||||
|
||||
if (dpi_x <1 )dpi_x = 96;
|
||||
if (dpi_y <1 )dpi_y = 96;
|
||||
|
||||
Height = Height *72. / dpi_y;
|
||||
Width = Width * 72. /dpi_x;
|
||||
|
||||
result = true;
|
||||
delete file;
|
||||
}
|
||||
Gdiplus::GdiplusShutdown(gdiplusToken);
|
||||
#endif
|
||||
}
|
||||
return result;
|
||||
}
|
||||
double static calculate_size_symbol_win(std::wstring name, double size, bool italic, bool bold, std::wstring test_str = L"")
|
||||
{
|
||||
double result =0;
|
||||
#if defined(_WIN32) || defined(_WIN64)
|
||||
Gdiplus::GdiplusStartupInput gdiplusStartupInput;
|
||||
ULONG_PTR gdiplusToken=0;
|
||||
Gdiplus::GdiplusStartup(&gdiplusToken, &gdiplusStartupInput, NULL);
|
||||
////
|
||||
bool to_one_char = false;
|
||||
if (test_str.length() <1 )
|
||||
{
|
||||
test_str = L"0123456789";
|
||||
to_one_char = true;
|
||||
}
|
||||
|
||||
int style = Gdiplus::FontStyleRegular;
|
||||
if (bold && italic) style = Gdiplus::FontStyleBoldItalic;
|
||||
else if (bold) style = Gdiplus::FontStyleBold;
|
||||
else if (italic) style = Gdiplus::FontStyleItalic;
|
||||
|
||||
Gdiplus::Graphics * gr = new Gdiplus::Graphics(GetWindowDC(NULL));
|
||||
if (gr)
|
||||
{
|
||||
Gdiplus::Font *font = new Gdiplus::Font(name.c_str(),size,style);
|
||||
if (font)
|
||||
{
|
||||
|
||||
Gdiplus::SizeF layout;
|
||||
|
||||
Gdiplus::RectF bound;
|
||||
Gdiplus::Status res = gr->MeasureString(test_str.c_str(),test_str.length(),font,layout,&bound);
|
||||
|
||||
if (res==0)result = (bound.Width - 2);
|
||||
if (to_one_char) result /= test_str.length();
|
||||
|
||||
//normalize to dpi = 96;
|
||||
double dpi = gr->GetDpiX();
|
||||
|
||||
result = result * 96./dpi;
|
||||
|
||||
delete font;
|
||||
}
|
||||
delete gr;
|
||||
}
|
||||
Gdiplus::GdiplusShutdown(gdiplusToken);
|
||||
#endif
|
||||
return result;
|
||||
}
|
||||
double static calculate_size_symbol_asc(std::wstring name, double size, bool italic, bool bold , CApplicationFonts *appFonts)
|
||||
{
|
||||
std::pair<float,float> val = cpdoccore::utils::GetMaxDigitSizePixels(name, size, 96., 0 , appFonts);
|
||||
|
||||
return val.first;
|
||||
}
|
||||
bool GetResolution(const wchar_t* fileName, double & Width, double &Height);
|
||||
double calculate_size_symbol_win(std::wstring name, double size, bool italic, bool bold, std::wstring test_str = L"");
|
||||
double calculate_size_symbol_asc(std::wstring name, double size, bool italic, bool bold , NSFonts::IApplicationFonts *appFonts);
|
||||
};
|
||||
|
||||
@ -47,7 +47,7 @@
|
||||
PreprocessorDefinitions="_DEBUG;_LIB;DONT_WRITE_EMBEDDED_FONTS"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
PrecompiledHeaderThrough=""
|
||||
WarningLevel="3"
|
||||
@ -401,6 +401,14 @@
|
||||
RelativePath="..\OdfFormat\office_chart.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\OdfFormat\office_document.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\OdfFormat\office_document.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\OdfFormat\office_event_listeners.cpp"
|
||||
>
|
||||
@ -837,6 +845,46 @@
|
||||
RelativePath="..\OdfFormat\odf_text_context.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\utils.cpp"
|
||||
>
|
||||
<FileConfiguration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
||||
/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="Debug|x64"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
||||
/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="Release|Win32"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
||||
/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="Release|x64"
|
||||
>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
ObjectFile="$(IntDir)\$(InputName)1.obj"
|
||||
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="odf_shapes_defines"
|
||||
|
||||
@ -47,7 +47,7 @@
|
||||
PreprocessorDefinitions="NDEBUG;_LIB;_USE_XMLLITE_READER_;USE_LITE_READER;_USE_LIBXML2_READER_;LIBXML_READER_ENABLED;DONT_WRITE_EMBEDDED_FONTS"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
|
||||
@ -21,22 +21,11 @@ include($$PWD/../../../Common/3dParty/boost/boost.pri)
|
||||
|
||||
DEFINES += UNICODE \
|
||||
_UNICODE \
|
||||
_USE_LIBXML2_READER_ \
|
||||
LIBXML_READER_ENABLED \
|
||||
_PRESENTATION_WRITER_ \
|
||||
_SVG_CONVERT_TO_IMAGE_ \
|
||||
DONT_WRITE_EMBEDDED_FONTS
|
||||
#DISABLE_FILE_DOWNLOADER
|
||||
|
||||
|
||||
INCLUDEPATH += \
|
||||
../../../DesktopEditor/freetype-2.5.2/include \
|
||||
../../../DesktopEditor/xml/libxml2/include
|
||||
|
||||
core_windows {
|
||||
INCLUDEPATH += ../../../OfficeUtils/src/zlib-1.2.3
|
||||
}
|
||||
|
||||
HEADERS += \
|
||||
../PPTFormatLib.h \
|
||||
../Reader/ClassesAtom.h \
|
||||
@ -186,16 +175,3 @@ SOURCES += \
|
||||
../../../ASCOfficePPTXFile/Editor/Drawing/TextAttributesEx.cpp \
|
||||
../../../Common/3dParty/pole/pole.cpp
|
||||
|
||||
core_windows {
|
||||
SOURCES += \
|
||||
../../../Common/FileDownloader/FileDownloader_win.cpp
|
||||
}
|
||||
core_linux {
|
||||
SOURCES += \
|
||||
../../../Common/FileDownloader/FileDownloader_curl.cpp
|
||||
}
|
||||
core_mac {
|
||||
OBJECTIVE_SOURCES += \
|
||||
../../../Common/FileDownloader/FileDownloader_mac.mm
|
||||
}
|
||||
|
||||
|
||||
@ -353,7 +353,7 @@ namespace NSPresentationEditor
|
||||
{
|
||||
if (NULL == m_pFontManager)
|
||||
{
|
||||
m_pFontManager = new CFontManager();
|
||||
m_pFontManager = NSFonts::NSFontManager::Create();
|
||||
m_pFontManager->Initialize();
|
||||
}
|
||||
|
||||
@ -375,7 +375,7 @@ namespace NSPresentationEditor
|
||||
public:
|
||||
|
||||
Aggplus::CGraphicsPathSimpleConverter* m_pSimpleGraphicsConverter; // конвертер сложных гафических путей в простые
|
||||
CFontManager* m_pFontManager; // менеджер шрифтов
|
||||
NSFonts::IFontManager* m_pFontManager; // менеджер шрифтов
|
||||
|
||||
Aggplus::CMatrix m_oBaseTransform; // матрица перерасчета координатных осей (здесь: миллиметры -> пикселы)
|
||||
Aggplus::CMatrix m_oTransform; // текущая матрица преобразований рендерера
|
||||
|
||||
@ -53,7 +53,7 @@ CPPTFileReader::CPPTFileReader(POLE::Storage *pStorage, std::wstring strTemp):
|
||||
m_pStorage(pStorage),
|
||||
m_bIsPPTFile(false),
|
||||
m_nPresentationCodePage(1250),
|
||||
m_pDocumentStream(NULL), m_pPictureStream(NULL), m_pDocumentSummaryStream(NULL), m_pEncryptedSummaryStream(NULL),
|
||||
m_pDocumentStream(), m_pPictureStream(), m_pDocumentSummaryStream(), m_pEncryptedSummaryStream(),
|
||||
m_strTmpDirectory(strTemp),
|
||||
m_oDocumentInfo()
|
||||
{
|
||||
|
||||
@ -36,8 +36,6 @@
|
||||
#include "../../../ASCOfficeDocFile/DocDocxConverter/MemoryStream.h"
|
||||
#include "../../../OfficeCryptReader/source/CryptTransform.h"
|
||||
|
||||
#include <zlib.h>
|
||||
|
||||
using namespace NSPresentationEditor;
|
||||
|
||||
namespace NSPresentationEditor
|
||||
@ -108,25 +106,6 @@ namespace NSPresentationEditor
|
||||
}
|
||||
}
|
||||
|
||||
namespace NSZLib
|
||||
{
|
||||
bool Decompress(const BYTE* pSrcBuffer, const ULONG& lSrcBufferLen,
|
||||
BYTE* pDstBuffer, ULONG& lDstBufferLen)
|
||||
{
|
||||
try
|
||||
{
|
||||
if (Z_OK == uncompress(pDstBuffer, &lDstBufferLen, pSrcBuffer, lSrcBufferLen))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
catch(...)
|
||||
{
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
namespace NSStreamReader
|
||||
{
|
||||
void Read(POLE::Stream* pStream, NSPresentationEditor::CTextSIRun& oRun, bool bIsIndentation)
|
||||
@ -815,4 +794,4 @@ void CMetaHeader::ToPICTHeader(BYTE *& pHeader, int & size)
|
||||
//}
|
||||
int sz = ((BYTE*)picPtr - pHeader);
|
||||
size = sz;
|
||||
}
|
||||
}
|
||||
|
||||
@ -33,16 +33,11 @@
|
||||
|
||||
#include "../../../ASCOfficePPTXFile/Editor/Drawing/TextAttributesEx.h"
|
||||
#include "SlidePersist.h"
|
||||
#include "../../../OfficeUtils/src/OfficeUtils.h"
|
||||
|
||||
|
||||
using namespace NSPresentationEditor;
|
||||
|
||||
|
||||
namespace NSZLib
|
||||
{
|
||||
bool Decompress(const BYTE* pSrcBuffer, const ULONG& lSrcBufferLen,
|
||||
BYTE* pDstBuffer, ULONG& lDstBufferLen);
|
||||
}
|
||||
namespace CRYPT
|
||||
{
|
||||
class ECMADecryptor;
|
||||
@ -235,7 +230,7 @@ public:
|
||||
{
|
||||
ULONG lSize = lUncompressSize;
|
||||
m_pMetaFile = new BYTE[lUncompressSize];
|
||||
bool bRes = NSZLib::Decompress(pCompress, (ULONG)lCompressSize, m_pMetaFile, lSize);
|
||||
bool bRes = NSZip::Decompress(pCompress, (ULONG)lCompressSize, m_pMetaFile, lSize);
|
||||
if (bRes)
|
||||
{
|
||||
m_lMetaFileSize = (LONG)lSize;
|
||||
|
||||
@ -96,7 +96,7 @@ public:
|
||||
if (m_oHeader.RecInstance == 0x01)
|
||||
{
|
||||
BYTE* pDataUncompress = new BYTE[decompressedSize + 64];
|
||||
if (NSZLib::Decompress(pData, compressedSize, pDataUncompress, decompressedSize))
|
||||
if (NSZip::Decompress(pData, compressedSize, pDataUncompress, decompressedSize))
|
||||
{
|
||||
delete []pData;
|
||||
pData = pDataUncompress;
|
||||
|
||||
@ -97,7 +97,7 @@ public:
|
||||
if (m_oHeader.RecInstance == 0x01)
|
||||
{
|
||||
BYTE* pDataUncompress = new BYTE[decompressedSize];
|
||||
NSZLib::Decompress(pData, compressedSize, pDataUncompress, decompressedSize);
|
||||
NSZip::Decompress(pData, compressedSize, pDataUncompress, decompressedSize);
|
||||
|
||||
delete []pData;
|
||||
pData = pDataUncompress;
|
||||
|
||||
@ -59,7 +59,7 @@
|
||||
PreprocessorDefinitions="_DEBUG;_LIB;_USE_MATH_DEFINES;_USE_LIBXML2_READER_;LIBXML_READER_ENABLED;USE_LITE_READER;_USE_XMLLITE_READER_;AVS_USE_CONVERT_PPTX_TOCUSTOM_VML;DONT_WRITE_EMBEDDED_FONTS"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
RuntimeLibrary="3"
|
||||
EnableEnhancedInstructionSet="0"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
|
||||
@ -82,7 +82,7 @@ HRESULT convert_single(std::wstring srcFileName)
|
||||
if (hRes == S_OK)
|
||||
{
|
||||
COfficeUtils oCOfficeUtils(NULL);
|
||||
hRes = oCOfficeUtils.CompressFileOrDirectory(dstTempPath.c_str(), dstPath, -1);
|
||||
hRes = oCOfficeUtils.CompressFileOrDirectory(dstTempPath.c_str(), dstPath, true);
|
||||
}
|
||||
|
||||
NSDirectory::DeleteDirectory(dstTempPath);
|
||||
|
||||
@ -1594,7 +1594,7 @@ void CDrawingConverter::doc_LoadDiagram(PPTX::Logic::SpTreeElem *result, XmlUtil
|
||||
OOX::CDiagramData* pDiagramData = NULL;
|
||||
OOX::CDiagramDrawing* pDiagramDrawing = NULL;
|
||||
|
||||
oNode.ReadAttributeBase(L"r:dm", id_data);
|
||||
XmlMacroReadAttributeBase(oNode, L"r:dm", id_data);
|
||||
|
||||
if (id_data.IsInit())
|
||||
{
|
||||
@ -2051,7 +2051,7 @@ void CDrawingConverter::doc_LoadShape(PPTX::Logic::SpTreeElem *elem, XmlUtils::C
|
||||
int R = 255, G = 255, B = 255;
|
||||
|
||||
nullable_string sFillColor;
|
||||
oNodeShape.ReadAttributeBase(L"fillcolor", sFillColor);
|
||||
XmlMacroReadAttributeBase(oNodeShape, L"fillcolor", sFillColor);
|
||||
if (sFillColor.is_init())
|
||||
{
|
||||
eFillType = etSolidFill;
|
||||
@ -2074,7 +2074,7 @@ void CDrawingConverter::doc_LoadShape(PPTX::Logic::SpTreeElem *elem, XmlUtils::C
|
||||
{
|
||||
// default color for vml = white
|
||||
nullable_string sFilled;
|
||||
oNodeShape.ReadAttributeBase(L"filled", sFilled);
|
||||
XmlMacroReadAttributeBase(oNodeShape, L"filled", sFilled);
|
||||
if (!sFilled.is_init() || (*sFilled != L"false") && *sFilled != L"f")
|
||||
{
|
||||
eFillType = etSolidFill;
|
||||
@ -2139,21 +2139,21 @@ void CDrawingConverter::doc_LoadShape(PPTX::Logic::SpTreeElem *elem, XmlUtils::C
|
||||
}
|
||||
|
||||
nullable_string sFitPath;
|
||||
oNodeP.ReadAttributeBase(L"fitpath", sFitPath);
|
||||
XmlMacroReadAttributeBase(oNodeP, L"fitpath", sFitPath);
|
||||
if (sFitPath.is_init() && (*sFitPath == L"true" || *sFitPath == L"t"))
|
||||
{
|
||||
bFitPath = true;
|
||||
}
|
||||
|
||||
nullable_string sFitShape;
|
||||
oNodeP.ReadAttributeBase(L"fitshape", sFitShape);
|
||||
XmlMacroReadAttributeBase(oNodeP, L"fitshape", sFitShape);
|
||||
if (sFitShape.is_init() && (*sFitShape == L"true" || *sFitShape == L"t"))
|
||||
{
|
||||
bFitShape = true;
|
||||
}
|
||||
|
||||
nullable_string sTrim;
|
||||
oNodeP.ReadAttributeBase(L"trim", sTrim);
|
||||
XmlMacroReadAttributeBase(oNodeP, L"trim", sTrim);
|
||||
if (sTrim.is_init() && (*sTrim == L"true" || *sTrim == L"t"))
|
||||
{
|
||||
bTrimTextPath = true;
|
||||
@ -2171,15 +2171,15 @@ void CDrawingConverter::doc_LoadShape(PPTX::Logic::SpTreeElem *elem, XmlUtils::C
|
||||
nullable_string sAngle;
|
||||
nullable_string sColors;
|
||||
|
||||
oNodeP.ReadAttributeBase(L"opacity" , sOpacity);
|
||||
oNodeP.ReadAttributeBase(L"opacity2" , sOpacity2);
|
||||
oNodeP.ReadAttributeBase(L"color2" , sColor2);
|
||||
oNodeP.ReadAttributeBase(L"type" , sType);
|
||||
oNodeP.ReadAttributeBase(L"focus" , sFocus);
|
||||
oNodeP.ReadAttributeBase(L"focussize" , sFocusSize);
|
||||
oNodeP.ReadAttributeBase(L"focusposition" , sFocusPosition);
|
||||
oNodeP.ReadAttributeBase(L"angle" , sAngle);
|
||||
oNodeP.ReadAttributeBase(L"colors" , sColors);
|
||||
XmlMacroReadAttributeBase(oNodeP, L"opacity" , sOpacity);
|
||||
XmlMacroReadAttributeBase(oNodeP, L"opacity2" , sOpacity2);
|
||||
XmlMacroReadAttributeBase(oNodeP, L"color2" , sColor2);
|
||||
XmlMacroReadAttributeBase(oNodeP, L"type" , sType);
|
||||
XmlMacroReadAttributeBase(oNodeP, L"focus" , sFocus);
|
||||
XmlMacroReadAttributeBase(oNodeP, L"focussize" , sFocusSize);
|
||||
XmlMacroReadAttributeBase(oNodeP, L"focusposition" , sFocusPosition);
|
||||
XmlMacroReadAttributeBase(oNodeP, L"angle" , sAngle);
|
||||
XmlMacroReadAttributeBase(oNodeP, L"colors" , sColors);
|
||||
|
||||
if (sType.is_init())
|
||||
{
|
||||
@ -2350,9 +2350,9 @@ void CDrawingConverter::doc_LoadShape(PPTX::Logic::SpTreeElem *elem, XmlUtils::C
|
||||
nullable_string sStrokeWeight;
|
||||
nullable_string sStroked;
|
||||
|
||||
oNodeShape.ReadAttributeBase(L"strokecolor", sStrokeColor);
|
||||
oNodeShape.ReadAttributeBase(L"strokeweight", sStrokeWeight);
|
||||
oNodeShape.ReadAttributeBase(L"stroked", sStroked);
|
||||
XmlMacroReadAttributeBase(oNodeShape, L"strokecolor", sStrokeColor);
|
||||
XmlMacroReadAttributeBase(oNodeShape, L"strokeweight", sStrokeWeight);
|
||||
XmlMacroReadAttributeBase(oNodeShape, L"stroked", sStroked);
|
||||
|
||||
//textFill
|
||||
strRPr += L"<w14:textFill>";
|
||||
@ -3406,7 +3406,7 @@ std::wstring CDrawingConverter::GetDrawingMainProps(XmlUtils::CXmlNode& oNode, P
|
||||
nullable_bool isAllowInCell;
|
||||
nullable_string sAllowInCell;
|
||||
|
||||
oNode.ReadAttributeBase(L"o:allowincell", sAllowInCell);
|
||||
XmlMacroReadAttributeBase(oNode, L"o:allowincell", sAllowInCell);
|
||||
if (sAllowInCell.is_init())
|
||||
{
|
||||
if ((L"f" == *sAllowInCell) || (L"false"== *sAllowInCell))
|
||||
@ -3417,7 +3417,7 @@ std::wstring CDrawingConverter::GetDrawingMainProps(XmlUtils::CXmlNode& oNode, P
|
||||
nullable_bool isAllowOverlap;
|
||||
nullable_string sAllowOverlap;
|
||||
|
||||
oNode.ReadAttributeBase(L"o:allowoverlap", sAllowOverlap);
|
||||
XmlMacroReadAttributeBase(oNode, L"o:allowoverlap", sAllowOverlap);
|
||||
if (sAllowOverlap.is_init())
|
||||
{
|
||||
if ((L"f" == *sAllowOverlap) || (L"false"== *sAllowOverlap))
|
||||
@ -3937,7 +3937,7 @@ void CDrawingConverter::CheckBorderShape(PPTX::Logic::SpTreeElem* oElem, XmlUtil
|
||||
return; //дублирование обрамлением линией
|
||||
|
||||
nullable_string sColorBorder;
|
||||
oNode.ReadAttributeBase(L"o:borderleftcolor", sColorBorder);
|
||||
XmlMacroReadAttributeBase(oNode, L"o:borderleftcolor", sColorBorder);
|
||||
|
||||
XmlUtils::CXmlNode oNodeBorder = oNode.ReadNode(L"w10:borderleft");
|
||||
|
||||
@ -3945,10 +3945,10 @@ void CDrawingConverter::CheckBorderShape(PPTX::Logic::SpTreeElem* oElem, XmlUtil
|
||||
{
|
||||
pSpPr->ln.Init();
|
||||
nullable_int nWidthBorder;
|
||||
oNode.ReadAttributeBase(L"width", nWidthBorder);
|
||||
XmlMacroReadAttributeBase(oNode, L"width", nWidthBorder);
|
||||
|
||||
nullable_string sTypeBorder;
|
||||
oNode.ReadAttributeBase(L"type", sTypeBorder);
|
||||
XmlMacroReadAttributeBase(oNode, L"type", sTypeBorder);
|
||||
|
||||
if (sTypeBorder.IsInit())
|
||||
{
|
||||
@ -4017,7 +4017,7 @@ void CDrawingConverter::CheckBrushShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils
|
||||
int B = 255;
|
||||
|
||||
nullable_string sFillColor;
|
||||
oNode.ReadAttributeBase(L"fillcolor", sFillColor);
|
||||
XmlMacroReadAttributeBase(oNode, L"fillcolor", sFillColor);
|
||||
if (sFillColor.is_init() && !pPPTShape->IsWordArt())
|
||||
{
|
||||
NSPresentationEditor::CColor color = NS_DWC_Common::getColorFromString(*sFillColor);
|
||||
@ -4043,7 +4043,7 @@ void CDrawingConverter::CheckBrushShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils
|
||||
}
|
||||
|
||||
nullable_string sFilled;
|
||||
oNode.ReadAttributeBase(L"filled", sFilled);
|
||||
XmlMacroReadAttributeBase(oNode, L"filled", sFilled);
|
||||
if (sFilled.is_init())
|
||||
{
|
||||
if (*sFilled == L"false" || *sFilled == L"f")
|
||||
@ -4065,7 +4065,7 @@ void CDrawingConverter::CheckBrushShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils
|
||||
}
|
||||
|
||||
nullable_string sOpacity;
|
||||
oNode.ReadAttributeBase(L"opacity", sOpacity);
|
||||
XmlMacroReadAttributeBase(oNode, L"opacity", sOpacity);
|
||||
if (sOpacity.is_init())
|
||||
{
|
||||
BYTE lAlpha = NS_DWC_Common::getOpacityFromString(*sOpacity);
|
||||
@ -4084,13 +4084,13 @@ void CDrawingConverter::CheckBrushShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils
|
||||
if (oNodeFill.IsValid() && !pPPTShape->IsWordArt())
|
||||
{
|
||||
nullable_string sType;
|
||||
oNodeFill.ReadAttributeBase(L"type", sType);
|
||||
XmlMacroReadAttributeBase(oNodeFill, L"type", sType);
|
||||
|
||||
sOpacity.reset();
|
||||
oNodeFill.ReadAttributeBase(L"opacity", sOpacity);
|
||||
XmlMacroReadAttributeBase(oNodeFill, L"opacity", sOpacity);
|
||||
|
||||
nullable_string sColor;
|
||||
oNodeFill.ReadAttributeBase(L"color", sColor);
|
||||
XmlMacroReadAttributeBase(oNodeFill, L"color", sColor);
|
||||
if (sColor.is_init())
|
||||
{
|
||||
NSPresentationEditor::CColor color = NS_DWC_Common::getColorFromString(*sColor);
|
||||
@ -4109,7 +4109,7 @@ void CDrawingConverter::CheckBrushShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils
|
||||
if (!sColor.is_init()) sColor = sFillColor;
|
||||
|
||||
nullable_string sRid;
|
||||
oNodeFill.ReadAttributeBase(L"r:id", sRid);
|
||||
XmlMacroReadAttributeBase(oNodeFill, L"r:id", sRid);
|
||||
if (sRid.is_init())
|
||||
{
|
||||
PPTX::Logic::BlipFill* pBlipFill = NULL;
|
||||
@ -4138,16 +4138,16 @@ void CDrawingConverter::CheckBrushShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils
|
||||
}
|
||||
}
|
||||
nullable_string sRotate;
|
||||
oNodeFill.ReadAttributeBase(L"rotate", sRotate);
|
||||
XmlMacroReadAttributeBase(oNodeFill, L"rotate", sRotate);
|
||||
|
||||
nullable_string sMethod;
|
||||
oNodeFill.ReadAttributeBase(L"method", sMethod);
|
||||
XmlMacroReadAttributeBase(oNodeFill, L"method", sMethod);
|
||||
|
||||
nullable_string sColor2;
|
||||
oNodeFill.ReadAttributeBase(L"color2", sColor2);
|
||||
XmlMacroReadAttributeBase(oNodeFill, L"color2", sColor2);
|
||||
|
||||
nullable_string sFocus;
|
||||
oNodeFill.ReadAttributeBase(L"focus", sFocus);
|
||||
XmlMacroReadAttributeBase(oNodeFill, L"focus", sFocus);
|
||||
//
|
||||
if (sType.is_init() && (*sType == L"gradient" || *sType == L"gradientradial" || *sType == L"gradientRadial"))
|
||||
{
|
||||
@ -4252,15 +4252,15 @@ void CDrawingConverter::CheckBrushShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils
|
||||
if (oNodeFillID.IsValid())
|
||||
{
|
||||
nullable_string sRid;
|
||||
oNodeFillID.ReadAttributeBase(L"r:id", sRid);
|
||||
XmlMacroReadAttributeBase(oNodeFillID, L"r:id", sRid);
|
||||
|
||||
nullable_string sRelid;
|
||||
oNodeFillID.ReadAttributeBase(L"o:relid", sRelid);
|
||||
XmlMacroReadAttributeBase(oNodeFillID, L"o:relid", sRelid);
|
||||
|
||||
if (sRid.is_init() || sRelid.is_init())
|
||||
{
|
||||
nullable_string sType;
|
||||
oNodeFillID.ReadAttributeBase(L"type", sType);
|
||||
XmlMacroReadAttributeBase(oNodeFillID, L"type", sType);
|
||||
|
||||
PPTX::Logic::BlipFill* pBlipFill = NULL;
|
||||
|
||||
@ -4390,7 +4390,7 @@ void CDrawingConverter::CheckPenShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils::
|
||||
|
||||
// attributes
|
||||
nullable_string sStrokeColor;
|
||||
oNode.ReadAttributeBase(L"strokecolor", sStrokeColor);
|
||||
XmlMacroReadAttributeBase(oNode, L"strokecolor", sStrokeColor);
|
||||
if (sStrokeColor.is_init())
|
||||
{
|
||||
NSPresentationEditor::CColor color = NS_DWC_Common::getColorFromString(*sStrokeColor);
|
||||
@ -4408,7 +4408,7 @@ void CDrawingConverter::CheckPenShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils::
|
||||
}
|
||||
|
||||
nullable_string sStrokeWeight;
|
||||
oNode.ReadAttributeBase(L"strokeweight", sStrokeWeight);
|
||||
XmlMacroReadAttributeBase(oNode, L"strokeweight", sStrokeWeight);
|
||||
if (sStrokeWeight.is_init())
|
||||
{
|
||||
if (!pSpPr->ln.is_init())
|
||||
@ -4427,7 +4427,7 @@ void CDrawingConverter::CheckPenShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils::
|
||||
}
|
||||
|
||||
nullable_string sStroked;
|
||||
oNode.ReadAttributeBase(L"stroked", sStroked);
|
||||
XmlMacroReadAttributeBase(oNode, L"stroked", sStroked);
|
||||
if (sStroked.is_init())
|
||||
{
|
||||
if (*sStroked == L"false" || *sStroked == L"f")
|
||||
@ -4452,7 +4452,7 @@ void CDrawingConverter::CheckPenShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils::
|
||||
if (oNodeStroke.IsValid())
|
||||
{
|
||||
sStrokeColor.reset();
|
||||
oNodeStroke.ReadAttributeBase(L"strokecolor", sStrokeColor);
|
||||
XmlMacroReadAttributeBase(oNodeStroke, L"strokecolor", sStrokeColor);
|
||||
if (sStrokeColor.is_init())
|
||||
{
|
||||
NSPresentationEditor::CColor color = NS_DWC_Common::getColorFromString(*sStrokeColor);
|
||||
@ -4470,7 +4470,7 @@ void CDrawingConverter::CheckPenShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils::
|
||||
}
|
||||
|
||||
nullable_string sStrokeDashStyle;
|
||||
oNodeStroke.ReadAttributeBase(L"dashstyle", sStrokeDashStyle);
|
||||
XmlMacroReadAttributeBase(oNodeStroke, L"dashstyle", sStrokeDashStyle);
|
||||
if (sStrokeDashStyle.is_init())
|
||||
{
|
||||
if (!pSpPr->ln.is_init())
|
||||
@ -4493,7 +4493,7 @@ void CDrawingConverter::CheckPenShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils::
|
||||
}
|
||||
|
||||
nullable_string sEndArraw;
|
||||
oNodeStroke.ReadAttributeBase(L"endarrow", sEndArraw);
|
||||
XmlMacroReadAttributeBase(oNodeStroke, L"endarrow", sEndArraw);
|
||||
if (sEndArraw.is_init())
|
||||
{
|
||||
if (!pSpPr->ln.is_init())
|
||||
@ -4511,7 +4511,7 @@ void CDrawingConverter::CheckPenShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils::
|
||||
}
|
||||
|
||||
nullable_string sEndArrawLen;
|
||||
oNodeStroke.ReadAttributeBase(L"endarrowlength", sEndArrawLen);
|
||||
XmlMacroReadAttributeBase(oNodeStroke, L"endarrowlength", sEndArrawLen);
|
||||
if (sEndArrawLen.is_init())
|
||||
{
|
||||
if (!pSpPr->ln.is_init())
|
||||
@ -4527,7 +4527,7 @@ void CDrawingConverter::CheckPenShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils::
|
||||
}
|
||||
|
||||
nullable_string sEndArrawWidth;
|
||||
oNodeStroke.ReadAttributeBase(L"endarrowwidth", sEndArrawWidth);
|
||||
XmlMacroReadAttributeBase(oNodeStroke, L"endarrowwidth", sEndArrawWidth);
|
||||
if (sEndArrawWidth.is_init())
|
||||
{
|
||||
if (!pSpPr->ln.is_init())
|
||||
@ -4543,7 +4543,7 @@ void CDrawingConverter::CheckPenShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils::
|
||||
}
|
||||
|
||||
nullable_string sStartArraw;
|
||||
oNodeStroke.ReadAttributeBase(L"startarrow", sStartArraw);
|
||||
XmlMacroReadAttributeBase(oNodeStroke, L"startarrow", sStartArraw);
|
||||
if (sStartArraw.is_init())
|
||||
{
|
||||
if (!pSpPr->ln.is_init())
|
||||
@ -4561,7 +4561,7 @@ void CDrawingConverter::CheckPenShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils::
|
||||
}
|
||||
|
||||
nullable_string sStartArrawLen;
|
||||
oNodeStroke.ReadAttributeBase(L"startarrowlength", sStartArrawLen);
|
||||
XmlMacroReadAttributeBase(oNodeStroke, L"startarrowlength", sStartArrawLen);
|
||||
if (sStartArrawLen.is_init())
|
||||
{
|
||||
if (!pSpPr->ln.is_init())
|
||||
@ -4577,7 +4577,7 @@ void CDrawingConverter::CheckPenShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils::
|
||||
}
|
||||
|
||||
nullable_string sStartArrawWidth;
|
||||
oNodeStroke.ReadAttributeBase(L"startarrowwidth", sStartArrawWidth);
|
||||
XmlMacroReadAttributeBase(oNodeStroke, L"startarrowwidth", sStartArrawWidth);
|
||||
if (sStartArrawWidth.is_init())
|
||||
{
|
||||
if (!pSpPr->ln.is_init())
|
||||
@ -4593,7 +4593,7 @@ void CDrawingConverter::CheckPenShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils::
|
||||
}
|
||||
|
||||
nullable_string sEndCap;
|
||||
oNodeStroke.ReadAttributeBase(L"endcap", sEndCap);
|
||||
XmlMacroReadAttributeBase(oNodeStroke, L"endcap", sEndCap);
|
||||
if (sEndCap.is_init())
|
||||
{
|
||||
if (!pSpPr->ln.is_init())
|
||||
@ -4605,7 +4605,7 @@ void CDrawingConverter::CheckPenShape(PPTX::Logic::SpTreeElem* oElem, XmlUtils::
|
||||
}
|
||||
|
||||
nullable_string sLineJoin;
|
||||
oNodeStroke.ReadAttributeBase(L"joinstyle", sLineJoin);
|
||||
XmlMacroReadAttributeBase(oNodeStroke, L"joinstyle", sLineJoin);
|
||||
if (sLineJoin.is_init())
|
||||
{
|
||||
if (!pSpPr->ln.is_init())
|
||||
@ -5004,7 +5004,7 @@ void CDrawingConverter::ConvertTextVML(XmlUtils::CXmlNode &nodeTextBox, PPTX::Lo
|
||||
run->SetText(node1.GetText());
|
||||
|
||||
std::vector<std::wstring > attNames, attValues;
|
||||
node1.ReadAllAttributes(attNames,attValues);
|
||||
node1.GetAllAttributes(attNames,attValues);
|
||||
|
||||
if (attNames.size() > 0)
|
||||
{
|
||||
@ -5062,10 +5062,10 @@ void CDrawingConverter::ConvertMainPropsToVML(const std::wstring& bsMainProps, N
|
||||
double dKoef = 72.0 / (36000 * 25.4);
|
||||
if (L"wp:inline" == oNode.GetName())
|
||||
{
|
||||
nullable_int margT; oNode.ReadAttributeBase(L"distT", margT);
|
||||
nullable_int margB; oNode.ReadAttributeBase(L"distB", margB);
|
||||
nullable_int margL; oNode.ReadAttributeBase(L"distL", margL);
|
||||
nullable_int margR; oNode.ReadAttributeBase(L"distR", margR);
|
||||
nullable_int margT; XmlMacroReadAttributeBase(oNode, L"distT", margT);
|
||||
nullable_int margB; XmlMacroReadAttributeBase(oNode, L"distB", margB);
|
||||
nullable_int margL; XmlMacroReadAttributeBase(oNode, L"distL", margL);
|
||||
nullable_int margR; XmlMacroReadAttributeBase(oNode, L"distR", margR);
|
||||
|
||||
if (margL.is_init())
|
||||
oWriter.WriteAttributeCSS_double1_pt(L"mso-wrap-distance-left", dKoef * (*margL));
|
||||
@ -5089,14 +5089,14 @@ void CDrawingConverter::ConvertMainPropsToVML(const std::wstring& bsMainProps, N
|
||||
else
|
||||
{
|
||||
oWriter.WriteAttributeCSS(L"position", L"absolute");
|
||||
nullable_int margT; oNode.ReadAttributeBase(L"distT", margT);
|
||||
nullable_int margB; oNode.ReadAttributeBase(L"distB", margB);
|
||||
nullable_int margL; oNode.ReadAttributeBase(L"distL", margL);
|
||||
nullable_int margR; oNode.ReadAttributeBase(L"distR", margR);
|
||||
nullable_int margT; XmlMacroReadAttributeBase(oNode, L"distT", margT);
|
||||
nullable_int margB; XmlMacroReadAttributeBase(oNode, L"distB", margB);
|
||||
nullable_int margL; XmlMacroReadAttributeBase(oNode, L"distL", margL);
|
||||
nullable_int margR; XmlMacroReadAttributeBase(oNode, L"distR", margR);
|
||||
|
||||
nullable_bool behindDoc; oNode.ReadAttributeBase(L"behindDoc", behindDoc);
|
||||
nullable_bool allowOverlap; oNode.ReadAttributeBase(L"allowOverlap", allowOverlap);
|
||||
nullable_bool layoutInCell; oNode.ReadAttributeBase(L"layoutInCell", layoutInCell);
|
||||
nullable_bool behindDoc; XmlMacroReadAttributeBase(oNode, L"behindDoc", behindDoc);
|
||||
nullable_bool allowOverlap; XmlMacroReadAttributeBase(oNode, L"allowOverlap", allowOverlap);
|
||||
nullable_bool layoutInCell; XmlMacroReadAttributeBase(oNode, L"layoutInCell", layoutInCell);
|
||||
|
||||
if (margL.is_init())
|
||||
oWriter.WriteAttributeCSS_double1_pt(L"mso-wrap-distance-left", dKoef * (*margL));
|
||||
@ -5107,7 +5107,7 @@ void CDrawingConverter::ConvertMainPropsToVML(const std::wstring& bsMainProps, N
|
||||
if (margB.is_init())
|
||||
oWriter.WriteAttributeCSS_double1_pt(L"mso-wrap-distance-bottom", dKoef * (*margB));
|
||||
|
||||
nullable_int64 zIndex; oNode.ReadAttributeBase(L"relativeHeight", zIndex);
|
||||
nullable_int64 zIndex; XmlMacroReadAttributeBase(oNode, L"relativeHeight", zIndex);
|
||||
if (zIndex.is_init())
|
||||
{
|
||||
_INT64 z_index = *zIndex;
|
||||
@ -5648,11 +5648,11 @@ smart_ptr<OOX::IFileContainer> CDrawingConverter::GetRels()
|
||||
{
|
||||
return *m_pBinaryWriter->m_pCurrentContainer;
|
||||
}
|
||||
void CDrawingConverter::SetFontManager(CFontManager* pFontManager)
|
||||
void CDrawingConverter::SetFontManager(NSFonts::IFontManager* pFontManager)
|
||||
{
|
||||
if(NULL != m_pBinaryWriter && NULL != m_pBinaryWriter->m_pCommon && NULL != m_pBinaryWriter->m_pCommon->m_pMediaManager)
|
||||
{
|
||||
m_pBinaryWriter->m_pCommon->m_pMediaManager->SetFontManager(pFontManager);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user