Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1588)

Unified Diff: Source/core/rendering/LineWidth.h

Issue 25512005: Enable experimental support for sub-pixel font scaling (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/core/rendering/LineWidth.h
diff --git a/Source/core/rendering/LineWidth.h b/Source/core/rendering/LineWidth.h
index 84b4ec58a5c3e6318bfd7230162ccbfc35c1066f..59e1442445e5f3dffad1c6b8d4fc7dc9a0b02301 100644
--- a/Source/core/rendering/LineWidth.h
+++ b/Source/core/rendering/LineWidth.h
@@ -48,8 +48,8 @@ class LineWidth {
public:
LineWidth(RenderBlockFlow&, bool isFirstLine, IndentTextOrNot shouldIndentText);
- bool fitsOnLine() const { return currentWidth() <= m_availableWidth; }
- bool fitsOnLine(float extra) const { return currentWidth() + extra <= m_availableWidth; }
+ bool fitsOnLine() const { return currentWidth() <= (m_availableWidth + LayoutUnit::epsilon()); }
+ bool fitsOnLine(float extra) const { return currentWidth() + extra <= (m_availableWidth + LayoutUnit::epsilon()); }
float currentWidth() const { return m_committedWidth + m_uncommittedWidth; }
// FIXME: We should eventually replace these three functions by ones that work on a higher abstraction.
« no previous file with comments | « Source/core/platform/graphics/win/FontPlatformDataWin.cpp ('k') | Source/platform/RuntimeEnabledFeatures.in » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698