Use the shorter GetScaledWidth() method
Change-Id: Id3ad483d3830310b8d13c86e407ff88d9a709464
This commit is contained in:
parent
1ae3638dbf
commit
922e4ba299
6 changed files with 9 additions and 10 deletions
|
@ -661,8 +661,8 @@ OUString SvxBorderLine::GetValueString( SfxMapUnit eSrcUnit,
|
|||
|
||||
bool SvxBorderLine::HasPriority( const SvxBorderLine& rOtherLine ) const
|
||||
{
|
||||
const sal_uInt16 nThisSize = GetOutWidth() + GetDistance() + GetInWidth();
|
||||
const sal_uInt16 nOtherSize = rOtherLine.GetOutWidth() + rOtherLine.GetDistance() + rOtherLine.GetInWidth();
|
||||
const sal_uInt16 nThisSize = GetScaledWidth();
|
||||
const sal_uInt16 nOtherSize = rOtherLine.GetScaledWidth();
|
||||
|
||||
if ( nThisSize > nOtherSize )
|
||||
{
|
||||
|
|
|
@ -2461,7 +2461,7 @@ sal_uInt16 SvxBoxItem::CalcLineSpace( sal_uInt16 nLine, sal_Bool bIgnoreLine ) c
|
|||
|
||||
if( pTmp )
|
||||
{
|
||||
nDist = nDist + (sal_uInt16)(pTmp->GetOutWidth()) + (sal_uInt16)(pTmp->GetInWidth()) + (sal_uInt16)(pTmp->GetDistance());
|
||||
nDist = nDist + pTmp->GetScaledWidth();
|
||||
}
|
||||
else if( !bIgnoreLine )
|
||||
nDist = 0;
|
||||
|
|
|
@ -67,8 +67,8 @@ bool ScHasPriority( const ::editeng::SvxBorderLine* pThis, const ::editeng::SvxB
|
|||
if (!pOther)
|
||||
return true;
|
||||
|
||||
sal_uInt16 nThisSize = pThis->GetOutWidth() + pThis->GetDistance() + pThis->GetInWidth();
|
||||
sal_uInt16 nOtherSize = pOther->GetOutWidth() + pOther->GetDistance() + pOther->GetInWidth();
|
||||
sal_uInt16 nThisSize = pThis->GetScaledWidth();
|
||||
sal_uInt16 nOtherSize = pOther->GetScaledWidth();
|
||||
|
||||
if (nThisSize > nOtherSize)
|
||||
return true;
|
||||
|
|
|
@ -165,7 +165,7 @@ size_t ScPageRowEntry::CountVisible() const
|
|||
|
||||
static long lcl_LineTotal(const ::editeng::SvxBorderLine* pLine)
|
||||
{
|
||||
return pLine ? ( pLine->GetOutWidth() + pLine->GetInWidth() + pLine->GetDistance() ) : 0;
|
||||
return pLine ? ( pLine->GetScaledWidth() ) : 0;
|
||||
}
|
||||
|
||||
void ScPrintFunc::Construct( const ScPrintOptions* pOptions )
|
||||
|
|
|
@ -901,8 +901,8 @@ bool TableLayouter::HasPriority( const SvxBorderLine* pThis, const SvxBorderLine
|
|||
if (!pOther || (pOther == &gEmptyBorder))
|
||||
return true;
|
||||
|
||||
sal_uInt16 nThisSize = pThis->GetOutWidth() + pThis->GetDistance() + pThis->GetInWidth();
|
||||
sal_uInt16 nOtherSize = pOther->GetOutWidth() + pOther->GetDistance() + pOther->GetInWidth();
|
||||
sal_uInt16 nThisSize = pThis->GetScaledWidth();
|
||||
sal_uInt16 nOtherSize = pOther->GetScaledWidth();
|
||||
|
||||
if (nThisSize > nOtherSize)
|
||||
return true;
|
||||
|
|
|
@ -204,8 +204,7 @@ bool sw_frmitems_setXMLBorder( SvxBorderLine*& rpLine,
|
|||
else
|
||||
{
|
||||
if (!bHasWidth)
|
||||
nWidth = rpLine->GetInWidth() + rpLine->GetDistance() +
|
||||
rpLine->GetOutWidth();
|
||||
nWidth = rpLine->GetScaledWidth();
|
||||
|
||||
rpLine->SetWidth( nWidth );
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue