diff options
Diffstat (limited to 'layout/generic')
-rw-r--r-- | layout/generic/nsTextFrame.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/layout/generic/nsTextFrame.cpp b/layout/generic/nsTextFrame.cpp index 749b8b944..83e50ca43 100644 --- a/layout/generic/nsTextFrame.cpp +++ b/layout/generic/nsTextFrame.cpp @@ -3437,7 +3437,7 @@ PropertyProvider::GetSpacingInternal(Range aRange, Spacing* aSpacing, if (!aIgnoreTabs) { gfxFloat tabWidth = ComputeTabWidthAppUnits(mFrame, mTextRun); if (tabWidth > 0) { - CalcTabWidths(aRange); + CalcTabWidths(aRange, tabWidth); if (mTabWidths) { mTabWidths->ApplySpacing(aSpacing, aRange.start - mStart.GetSkippedOffset(), @@ -3468,13 +3468,13 @@ PropertyProvider::GetSpacingInternal(Range aRange, Spacing* aSpacing, // aX and the result are in whole appunits. static gfxFloat AdvanceToNextTab(gfxFloat aX, nsIFrame* aFrame, - gfxTextRun* aTextRun, gfxFloat* aTabWidth) + gfxTextRun* aTextRun, gfxFloat aTabWidth) { // Advance aX to the next multiple of *aCachedTabWidth. We must advance // by at least 1 appunit. // XXX should we make this 1 CSS pixel? - return ceil((aX + 1)/ aTabWidth) * aTabWidth; + return NS_round((aX + 1) / aTabWidth) * aTabWidth; } void |