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

Unified Diff: Source/core/style/ComputedStyle.h

Issue 950623002: Store resolved color in AppliedTextDecoration (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: removed inherited_flags.m_textunderline Created 5 years, 7 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/style/ComputedStyle.h
diff --git a/Source/core/style/ComputedStyle.h b/Source/core/style/ComputedStyle.h
index 378a1022d4d06a822e9b1c2ed7e82935bb863183..256f0b084c8ad740298548c34022ff088a3eeb25 100644
--- a/Source/core/style/ComputedStyle.h
+++ b/Source/core/style/ComputedStyle.h
@@ -164,7 +164,6 @@ protected:
&& (_visibility == other._visibility)
&& (_text_align == other._text_align)
&& (_text_transform == other._text_transform)
- && (m_textUnderline == other.m_textUnderline)
&& (_cursor_style == other._cursor_style)
&& (_direction == other._direction)
&& (_white_space == other._white_space)
@@ -186,7 +185,6 @@ protected:
unsigned _visibility : 2; // EVisibility
unsigned _text_align : 4; // ETextAlign
unsigned _text_transform : 2; // ETextTransform
- unsigned m_textUnderline : 1;
unsigned _cursor_style : 6; // ECursor
unsigned _direction : 1; // TextDirection
unsigned _white_space : 3; // EWhiteSpace
@@ -288,7 +286,6 @@ protected:
inherited_flags._visibility = initialVisibility();
inherited_flags._text_align = initialTextAlign();
inherited_flags._text_transform = initialTextTransform();
- inherited_flags.m_textUnderline = false;
inherited_flags._cursor_style = initialCursor();
inherited_flags._direction = initialDirection();
inherited_flags._white_space = initialWhiteSpace();
@@ -574,6 +571,7 @@ public:
TextDecoration textDecorationsInEffect() const;
const Vector<AppliedTextDecoration>& appliedTextDecorations() const;
TextDecoration textDecoration() const { return static_cast<TextDecoration>(visual->textDecoration); }
+ bool isSimpleUnderlineDecoration() const { return visual->textDecoration & TextDecorationUnderline; }
wkorman 2015/07/01 15:16:14 Suggest adding comment explaining more on what sim
TextUnderlinePosition textUnderlinePosition() const { return static_cast<TextUnderlinePosition>(rareInheritedData->m_textUnderlinePosition); }
TextDecorationStyle textDecorationStyle() const { return static_cast<TextDecorationStyle>(rareNonInheritedData->m_textDecorationStyle); }
float wordSpacing() const;
@@ -1096,7 +1094,7 @@ public:
void setTextAlignLast(TextAlignLast v) { SET_VAR(rareInheritedData, m_textAlignLast, v); }
void setTextJustify(TextJustify v) { SET_VAR(rareInheritedData, m_textJustify, v); }
void setTextTransform(ETextTransform v) { inherited_flags._text_transform = v; }
- void applyTextDecorations();
+ void applyTextDecorations(const ComputedStyle& parentStyle);
void clearAppliedTextDecorations();
void setTextDecoration(TextDecoration v) { SET_VAR(visual, textDecoration, v); }
void setTextUnderlinePosition(TextUnderlinePosition v) { SET_VAR(rareInheritedData, m_textUnderlinePosition, v); }

Powered by Google App Engine
This is Rietveld 408576698