summaryrefslogtreecommitdiff
path: root/svx/source/svdraw/svdotxtr.cxx
diff options
context:
space:
mode:
authorArmin Le Grand <alg@apache.org>2013-09-19 10:11:03 +0000
committerDavid Tardon <dtardon@redhat.com>2014-03-23 06:57:05 +0100
commit120e469d176026ceb59abbf74d2ad255323cbc9a (patch)
tree9ed4fe3aeeddd3a7c6333f1305bfb5ce6cf48561 /svx/source/svdraw/svdotxtr.cxx
parent8931ab3fc27acb0665fa636eb6390034cbb3eec6 (diff)
i#115391 better support for MinTextSize settings
... for TextShapes and CustomShapes Conflicts: include/svx/svdotext.hxx svx/source/sdr/properties/customshapeproperties.cxx svx/source/svdraw/svdoashp.cxx svx/source/svdraw/svdotext.cxx svx/source/svdraw/svdotxdr.cxx svx/source/svdraw/svdotxtr.cxx Change-Id: Ie6f490801b6887568135ed5f83c8bbe7ab6daa08
Diffstat (limited to 'svx/source/svdraw/svdotxtr.cxx')
-rw-r--r--svx/source/svdraw/svdotxtr.cxx31
1 files changed, 22 insertions, 9 deletions
diff --git a/svx/source/svdraw/svdotxtr.cxx b/svx/source/svdraw/svdotxtr.cxx
index 409af9f24c07..a0267ddae4ca 100644
--- a/svx/source/svdraw/svdotxtr.cxx
+++ b/svx/source/svdraw/svdotxtr.cxx
@@ -58,11 +58,15 @@ void SdrTextObj::NbcSetSnapRect(const Rectangle& rRect)
long nTHgt1=rRect.GetHeight()-1-nVDist; if (nTHgt1<0) nTHgt1=0;
aRect=rRect;
ImpJustifyRect(aRect);
- if (bTextFrame && (pModel==NULL || !pModel->IsPasteResize())) {
- if (nTWdt0!=nTWdt1 && IsAutoGrowWidth() ) NbcSetMinTextFrameWidth(nTWdt1);
- if (nTHgt0!=nTHgt1 && IsAutoGrowHeight()) NbcSetMinTextFrameHeight(nTHgt1);
+
+ // #115391#
+ AdaptTextMinSize();
+
+ if (bTextFrame && (pModel==NULL || !pModel->IsPasteResize()))
+ {
NbcAdjustTextFrameWidthAndHeight();
}
+
ImpCheckShear();
SetRectsDirty();
}
@@ -83,11 +87,15 @@ void SdrTextObj::NbcSetLogicRect(const Rectangle& rRect)
long nTHgt1=rRect.GetHeight()-1-nVDist; if (nTHgt1<0) nTHgt1=0;
aRect=rRect;
ImpJustifyRect(aRect);
- if (bTextFrame) {
- if (nTWdt0!=nTWdt1 && IsAutoGrowWidth() ) NbcSetMinTextFrameWidth(nTWdt1);
- if (nTHgt0!=nTHgt1 && IsAutoGrowHeight()) NbcSetMinTextFrameHeight(nTHgt1);
+
+ // #115391#
+ AdaptTextMinSize();
+
+ if(bTextFrame)
+ {
NbcAdjustTextFrameWidthAndHeight();
}
+
SetRectsDirty();
}
@@ -185,13 +193,18 @@ void SdrTextObj::NbcResize(const Point& rRef, const Fraction& xFact, const Fract
}
ImpJustifyRect(aRect);
+
long nTWdt1=aRect.GetWidth ()-1-nHDist; if (nTWdt1<0) nTWdt1=0;
long nTHgt1=aRect.GetHeight()-1-nVDist; if (nTHgt1<0) nTHgt1=0;
- if (bTextFrame && (pModel==NULL || !pModel->IsPasteResize())) {
- if (nTWdt0!=nTWdt1 && IsAutoGrowWidth() ) NbcSetMinTextFrameWidth(nTWdt1);
- if (nTHgt0!=nTHgt1 && IsAutoGrowHeight()) NbcSetMinTextFrameHeight(nTHgt1);
+
+ // #115391#
+ AdaptTextMinSize();
+
+ if(bTextFrame && (!pModel || !pModel->IsPasteResize()))
+ {
NbcAdjustTextFrameWidthAndHeight();
}
+
ImpCheckShear();
SetRectsDirty();
}