From 7f73a779e33dd91fad0111629c6b3420c2c9aea0 Mon Sep 17 00:00:00 2001 From: Tomaž Vajngerl Date: Wed, 2 Nov 2022 20:15:31 +0100 Subject: optimize text fitting algorithm to correctly calculate the fit MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit As we converted the chart stretching variable from int to double this can cause the text fitting algorithm to calculate the fit wrong. This commit changes the text fitting algorithm a bit so that it produces similar result as before the change. Change test testAutofittedTextboxIndent from 691200 to 712800 as the fitting algorithm changed a bit. Visually the document still looks correct. Change-Id: Ib75733360039d80a5aed836f757c3f8e8ec56d61 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/142186 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl --- sd/qa/unit/export-tests-ooxml3.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sd') diff --git a/sd/qa/unit/export-tests-ooxml3.cxx b/sd/qa/unit/export-tests-ooxml3.cxx index 62fe34150896..2f2576ed1ce6 100644 --- a/sd/qa/unit/export-tests-ooxml3.cxx +++ b/sd/qa/unit/export-tests-ooxml3.cxx @@ -2068,7 +2068,7 @@ void SdOOXMLExportTest3::testAutofittedTextboxIndent() xmlDocUniquePtr pXmlDocContent1 = parseExport(tempFile, "ppt/slides/slide1.xml"); assertXPath(pXmlDocContent1, "/p:sld/p:cSld/p:spTree/p:sp/p:txBody/a:p[1]/a:pPr", "marL", - "691200"); + "712800"); } CPPUNIT_TEST_SUITE_REGISTRATION(SdOOXMLExportTest3); -- cgit