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

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

Issue 150403003: Consider text alignment and direction when computing the left offset for horizontal writing modes. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@issue313593
Patch Set: Created 6 years, 11 months 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/RenderObject.h
diff --git a/Source/core/rendering/RenderObject.h b/Source/core/rendering/RenderObject.h
index ebf19e4851e6920b5a5223981a1edac89ceb55b7..08063511016ea76056bcf3b1d0a1a6ea2eaf8ba4 100644
--- a/Source/core/rendering/RenderObject.h
+++ b/Source/core/rendering/RenderObject.h
@@ -68,6 +68,7 @@ class RenderTable;
class RenderTheme;
class RenderView;
class ResourceLoadPriorityOptimizer;
+class RootInlineBox;
class TransformState;
struct PaintInfo;
@@ -806,6 +807,11 @@ public:
// This is typically only relevant when repainting.
virtual RenderStyle* outlineStyleForRepaint() const { return style(); }
+ // Return LEFT, RIGHT, CENTER or JUSTIFY considering text alignment and direction.
+ // If a specific RootInlineBox is specified, it will be used to calculate the direction to be considered,
+ // otherwise the default direction for the associated style will be used.
+ ETextAlign simplifiedTextAlign(const ETextAlign&, const RootInlineBox* = 0) const;
+
virtual CursorDirective getCursor(const LayoutPoint&, Cursor&) const;
void getTextDecorationColors(unsigned decorations, Color& underline, Color& overline, Color& linethrough, bool quirksMode = false, bool firstlineStyle = false);

Powered by Google App Engine
This is Rietveld 408576698