Index: ui/gfx/canvas_linux.cc |
diff --git a/ui/gfx/canvas_linux.cc b/ui/gfx/canvas_linux.cc |
index 9d417c998c7a629b1339fb81a198ae7b8ce24c0b..8b12b3d293b58a62b3091ca1727e61c5cf469476 100644 |
--- a/ui/gfx/canvas_linux.cc |
+++ b/ui/gfx/canvas_linux.cc |
@@ -112,7 +112,7 @@ void DrawStringContext::Draw(SkColor text_color) { |
void DrawStringContext::DrawWithHalo(SkColor text_color, |
SkColor halo_color) { |
gfx::Size size(bounds_.width() + 2, bounds_.height() + 2); |
- gfx::Canvas text_canvas(size, false); |
+ gfx::Canvas text_canvas(size, scale_factor(), false); |
text_canvas.FillRect(gfx::Rect(size), static_cast<SkColor>(0)); |
{ |
@@ -157,6 +157,8 @@ void DrawStringContext::DrawWithHalo(SkColor text_color, |
const SkBitmap& text_bitmap = const_cast<SkBitmap&>( |
skia::GetTopDevice(*text_canvas.sk_canvas())->accessBitmap(false)); |
+ const gfx::ImageSkia text_image = gfx::ImageSkia(gfx::ImageSkiaRep( |
+ text_bitmap, text_canvas.scale_factor())); |
canvas_->DrawImageInt(text_bitmap, text_rect_.x() - 1, text_rect_.y() - 1); |
} |