summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--svtools/source/control/ctrlbox.cxx4
-rw-r--r--sw/source/filter/html/htmltab.cxx3
2 files changed, 5 insertions, 2 deletions
diff --git a/svtools/source/control/ctrlbox.cxx b/svtools/source/control/ctrlbox.cxx
index 56658586d9cc..4a44d0314c8e 100644
--- a/svtools/source/control/ctrlbox.cxx
+++ b/svtools/source/control/ctrlbox.cxx
@@ -327,6 +327,10 @@ long BorderWidthImpl::GetLine1( long nWidth ) const
result = std::max<long>(0,
static_cast<long>((m_nRate1 * nWidth) + 0.5)
- (nConstant2 + nConstantD));
+ if (result == 0 && m_nRate1 > 0.0 && nWidth > 0)
+ { // fdo#51777: hack to essentially treat 1 twip DOUBLE border
+ result = 1; // as 1 twip SINGLE border
+ }
}
return result;
}
diff --git a/sw/source/filter/html/htmltab.cxx b/sw/source/filter/html/htmltab.cxx
index bfde6230dda3..8a3edd91ef4c 100644
--- a/sw/source/filter/html/htmltab.cxx
+++ b/sw/source/filter/html/htmltab.cxx
@@ -2072,8 +2072,7 @@ void HTMLTable::SetBorders()
sal_uInt16 HTMLTable::GetBorderWidth( const SvxBorderLine& rBLine,
sal_Bool bWithDistance ) const
{
- sal_uInt16 nBorderWidth = rBLine.GetOutWidth() + rBLine.GetInWidth() +
- rBLine.GetDistance();
+ sal_uInt16 nBorderWidth = rBLine.GetWidth();
if( bWithDistance )
{
if( nCellPadding )