summaryrefslogtreecommitdiff
path: root/oox/source
diff options
context:
space:
mode:
authorRegina Henschel <rb.henschel@t-online.de>2021-10-17 23:49:17 +0200
committerXisco Fauli <xiscofauli@libreoffice.org>2021-10-19 11:37:02 +0200
commit516a4a59b7d16fbd803f55c37c51564f46a29f7d (patch)
tree6b5042c159b259173f3d6705bfa353adb65cf17d /oox/source
parent2a5b91903a4a5572bfd7f6c53799d717838bf8a6 (diff)
tdf#125582 use TextVerticalAlign_BOTTOM for textCircle
PowerPoint aligns the bottom of the text to the path for prstTxWarp 'textCircle'. That preset type is mapped to 'fontwork-circle-curve' on import with additional attribute ScaleX=true. Currently the property TextVerticalAlign is only evaluated in case ScaleX=true. Therefore I have written the condition similar as the already existing with 'fontwork-arch-up-curve'. If it will be necessary later, all those conditions can be changed to use rPresetType instead of rClass. The rendering is slightly different compared to PowerPoint, because descenders and paragraphs line-spacing are handled differently. The rendering has still the problem, that in PowerPoint the letters are placed without gap, but in LO they have additional distances from each other. The needed ODF attribute draw:text-path-mode is not yet implemented in LO. Its value 'normal' would be needed here. Change-Id: I1f03d4845312885eff9ee8dbe1d51ddd437ed8e4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123726 Tested-by: Jenkins Reviewed-by: Regina Henschel <rb.henschel@t-online.de> (cherry picked from commit 9142d19ddc751e05041471aa1bbeca2f06729522) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123775 Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
Diffstat (limited to 'oox/source')
-rw-r--r--oox/source/drawingml/shape.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/oox/source/drawingml/shape.cxx b/oox/source/drawingml/shape.cxx
index b6900b8d1aeb..d9ee434dcb79 100644
--- a/oox/source/drawingml/shape.cxx
+++ b/oox/source/drawingml/shape.cxx
@@ -567,7 +567,7 @@ static void lcl_createPresetShape(const uno::Reference<drawing::XShape>& xShape,
// ToDo: The property is currently not evaluated.
SdrObject* pShape = SdrObject::getSdrObjectFromXShape(xShape);
assert(pShape);
- if (rClass == "fontwork-arch-up-curve")
+ if (rClass == "fontwork-arch-up-curve" || rClass == "fontwork-circle-curve")
pShape->SetMergedItem( SdrTextVertAdjustItem( SdrTextVertAdjust::SDRTEXTVERTADJUST_BOTTOM ) );
else if (rClass == "fontwork-arch-down-curve")
pShape->SetMergedItem( SdrTextVertAdjustItem( SdrTextVertAdjust::SDRTEXTVERTADJUST_TOP ) );