From ed3873ae03a770dc475ea1b8c7ff0be33b49e134 Mon Sep 17 00:00:00 2001 From: ElenaSubbotina Date: Fri, 25 Mar 2016 17:17:11 +0300 Subject: [PATCH] bug #32029 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit OdfFormatReader - AS acknowledgement slip.odt - нулевой размер пропорционального шрифта (0%) --- ASCOfficeOdfFile/src/odf/style_text_properties.cpp | 5 +++-- ASCOfficeOdfFile/win32/ASCOfficeOdfFile.sln | 6 +++++- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/ASCOfficeOdfFile/src/odf/style_text_properties.cpp b/ASCOfficeOdfFile/src/odf/style_text_properties.cpp index 80598867e5..6887b94256 100644 --- a/ASCOfficeOdfFile/src/odf/style_text_properties.cpp +++ b/ASCOfficeOdfFile/src/odf/style_text_properties.cpp @@ -833,7 +833,7 @@ void text_format_properties_content::docx_convert(oox::docx_conversion_context & if (style_text_position_->has_font_size() && !noNeedSize) { const double mul = style_text_position_->font_size().get_value() / 100.0; - if (fontSizeVal > 0) + if (fontSizeVal > 0 && mul > 0) { const std::wstring fontSize = boost::lexical_cast((int)(fontSizeVal * mul + 0.5)); if (!fontSize.empty()) @@ -870,7 +870,8 @@ void text_format_properties_content::docx_convert(oox::docx_conversion_context & if (fontSize>0) { - _rPr << L""; + std::wstring str_fontSize = boost::lexical_cast(fontSize); + _rPr << L""; } } diff --git a/ASCOfficeOdfFile/win32/ASCOfficeOdfFile.sln b/ASCOfficeOdfFile/win32/ASCOfficeOdfFile.sln index 455ae45263..7bd0ed6f54 100644 --- a/ASCOfficeOdfFile/win32/ASCOfficeOdfFile.sln +++ b/ASCOfficeOdfFile/win32/ASCOfficeOdfFile.sln @@ -5,11 +5,12 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "xml_wrapper", "cpxml.vcproj EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "OdfFormatReaderLib", "cpodf.vcproj", "{50E20601-4A8D-4AFB-8870-63828D328429}" ProjectSection(ProjectDependencies) = postProject + {C739151F-5384-41DF-A1A6-F089E2C1AD56} = {C739151F-5384-41DF-A1A6-F089E2C1AD56} + {37CA072A-5BDE-498B-B3A7-5E404F5F9BF2} = {37CA072A-5BDE-498B-B3A7-5E404F5F9BF2} {94954A67-A853-43B1-A727-6EF2774C5A6A} = {94954A67-A853-43B1-A727-6EF2774C5A6A} {9CAA294E-58C3-4CEB-ABA0-CB9786CA5540} = {9CAA294E-58C3-4CEB-ABA0-CB9786CA5540} {609ED938-3CA8-4BED-B363-25096D4C4812} = {609ED938-3CA8-4BED-B363-25096D4C4812} {41BED424-4EAF-4053-8A5F-1E2A387D53D1} = {41BED424-4EAF-4053-8A5F-1E2A387D53D1} - {C739151F-5384-41DF-A1A6-F089E2C1AD56} = {C739151F-5384-41DF-A1A6-F089E2C1AD56} EndProjectSection EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "OdfCommon", "cpcommon.vcproj", "{609ED938-3CA8-4BED-B363-25096D4C4812}" @@ -28,6 +29,9 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "ASCOfficeOdfFile", "..\ASCO EndProjectSection EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "ASCOfficeOdfFileTest", "..\Test\ASCOfficeOdfFileTest\ASCOfficeOdfFileTest.vcproj", "{C2882DDD-07E6-4314-AD4B-48F43F38D722}" + ProjectSection(ProjectDependencies) = postProject + {64B09C98-22DC-494E-A882-9E2D7D18557C} = {64B09C98-22DC-494E-A882-9E2D7D18557C} + EndProjectSection EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libxml2", "..\..\Common\DocxFormat\Source\XML\libxml2\win_build\libxml2.vcproj", "{21663823-DE45-479B-91D0-B4FEF4916EF0}" EndProject