[Libreoffice-commits] .: Branch 'libreoffice-3-5' - editeng/source
Michael Stahl
mst at kemper.freedesktop.org
Fri Feb 3 03:10:15 PST 2012
editeng/source/items/borderline.cxx | 16 ++++++++++++++++
1 file changed, 16 insertions(+)
New commits:
commit e44b64d297293b83459fddda968923750e2f6a5b
Author: Eike Rathke <erack at redhat.com>
Date: Thu Feb 2 19:11:37 2012 +0100
resolved fdo#42784 BorderLine with only InnerWidth set does not work
(cherry picked from commit 971f826a96f0938bfcfd8dfe26edd50d8e031bb4)
Signed-off-by: Michael Stahl <mstahl at redhat.com>
diff --git a/editeng/source/items/borderline.cxx b/editeng/source/items/borderline.cxx
index 61cecce..d15f53c 100644
--- a/editeng/source/items/borderline.cxx
+++ b/editeng/source/items/borderline.cxx
@@ -300,6 +300,22 @@ void SvxBorderLine::GuessLinesWidths( SvxBorderStyle nStyle, sal_uInt16 nOut, sa
else
{
SetStyle( nStyle );
+ if (nOut == 0 && nIn > 0)
+ {
+ // If only inner width is given swap inner and outer widths for
+ // single line styles, otherwise GuessWidth() marks this as invalid
+ // and returns a 0 width.
+ switch (nStyle)
+ {
+ case SOLID:
+ case DOTTED:
+ case DASHED:
+ ::std::swap( nOut, nIn);
+ break;
+ default:
+ ; // nothing
+ }
+ }
m_nWidth = m_aWidthImpl.GuessWidth( nOut, nIn, nDist );
}
}
More information about the Libreoffice-commits
mailing list