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

Unified Diff: sky/engine/core/painting/Color.dart

Issue 1162573007: Fix RenderParagraph to respect text color. (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Fixed null Created 5 years, 6 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
« no previous file with comments | « no previous file | sky/sdk/lib/framework/rendering/paragraph.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/engine/core/painting/Color.dart
diff --git a/sky/engine/core/painting/Color.dart b/sky/engine/core/painting/Color.dart
index 0ea9fa98063b04f72b28f81c733c91f4f9d3110f..be59871bb10ddd626dfe78d8cc75368fac25c20f 100644
--- a/sky/engine/core/painting/Color.dart
+++ b/sky/engine/core/painting/Color.dart
@@ -15,6 +15,11 @@ class Color {
((g & 0xff) << 8) |
((b & 0xff) << 0));
+ int get alpha => (0xff000000 & _value) >> 24;
+ int get red => (0x00ff0000 & _value) >> 16;
+ int get green => (0x0000ff00 & _value) >> 8;
+ int get blue => (0x000000ff & _value) >> 0;
+
bool operator ==(other) => other is Color && _value == other._value;
int get hashCode => _value.hashCode;
« no previous file with comments | « no previous file | sky/sdk/lib/framework/rendering/paragraph.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698