summaryrefslogtreecommitdiffstats
path: root/gfx
diff options
context:
space:
mode:
authorchocobo@chromium.org <chocobo@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-04-09 21:12:06 +0000
committerchocobo@chromium.org <chocobo@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-04-09 21:12:06 +0000
commit7b70a92006d329a3e2df40ec6b61322212f75d95 (patch)
tree76bcda3b513d1f71b611ed3ca2d0ef9a3b56fc80 /gfx
parentcc503bd09b78bc553bf577737f2c78bea84821ac (diff)
downloadchromium_src-7b70a92006d329a3e2df40ec6b61322212f75d95.zip
chromium_src-7b70a92006d329a3e2df40ec6b61322212f75d95.tar.gz
chromium_src-7b70a92006d329a3e2df40ec6b61322212f75d95.tar.bz2
Status area improvements:
- text is now 70% alpha - font is 1 size larger - 6 pixels between status icons - icon and text are lined up better - when clock changes text, bounds are reset properly TEST=none BUG=none Review URL: http://codereview.chromium.org/1589021 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@44128 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'gfx')
-rw-r--r--gfx/canvas_linux.cc9
-rw-r--r--gfx/canvas_mac.mm2
2 files changed, 6 insertions, 5 deletions
diff --git a/gfx/canvas_linux.cc b/gfx/canvas_linux.cc
index 6bc7690..3f658d4 100644
--- a/gfx/canvas_linux.cc
+++ b/gfx/canvas_linux.cc
@@ -218,10 +218,11 @@ void Canvas::DrawStringInt(const std::wstring& text,
pango_layout_set_height(layout, h * PANGO_SCALE);
cairo_save(cr);
- cairo_set_source_rgb(cr,
- SkColorGetR(color) / 255.0,
- SkColorGetG(color) / 255.0,
- SkColorGetB(color) / 255.0);
+ cairo_set_source_rgba(cr,
+ SkColorGetR(color) / 255.0,
+ SkColorGetG(color) / 255.0,
+ SkColorGetB(color) / 255.0,
+ SkColorGetA(color) / 255.0);
int width, height;
pango_layout_get_pixel_size(layout, &width, &height);
diff --git a/gfx/canvas_mac.mm b/gfx/canvas_mac.mm
index ebba090..bffa91f 100644
--- a/gfx/canvas_mac.mm
+++ b/gfx/canvas_mac.mm
@@ -44,7 +44,7 @@ void Canvas::DrawStringInt(const std::wstring& text, const gfx::Font& font,
NSColor* ns_color = [NSColor colorWithDeviceRed:SkColorGetR(color) / 255.0
green:SkColorGetG(color) / 255.0
blue:SkColorGetB(color) / 255.0
- alpha:1.0];
+ alpha:SkColorGetA(color) / 255.0];
NSMutableParagraphStyle *ns_style =
[[[NSParagraphStyle alloc] init] autorelease];
if (flags & TEXT_ALIGN_CENTER)