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

Unified Diff: ui/gfx/render_text_win.cc

Issue 9370026: Respect the system ClearType setting in RenderTextWin. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 8 years, 10 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: ui/gfx/render_text_win.cc
===================================================================
--- ui/gfx/render_text_win.cc (revision 121717)
+++ ui/gfx/render_text_win.cc (working copy)
@@ -11,6 +11,7 @@
#include "base/stl_util.h"
#include "base/string_util.h"
#include "base/utf_string_conversions.h"
+#include "ui/gfx/font_smoothing_win.h"
#include "ui/gfx/screen_compatible_dc_win.h"
#include "ui/gfx/canvas.h"
#include "ui/gfx/canvas_skia.h"
@@ -439,6 +440,11 @@
internal::SkiaTextRenderer renderer(canvas);
ApplyFadeEffects(&renderer);
+ bool smoothing_enabled;
+ bool cleartype_enabled;
+ GetCachedFontSmoothingSettings(&smoothing_enabled, &cleartype_enabled);
+ renderer.SetFontSmoothingSettings(smoothing_enabled, cleartype_enabled);
msw 2012/02/15 00:33:16 Perhaps comment on how enable_lcd_text == cleartyp
asvitkine_google 2012/02/15 15:10:44 Done.
+
for (size_t i = 0; i < runs_.size(); ++i) {
// Get the run specified by the visual-to-logical map.
internal::TextRun* run = runs_[visual_to_logical_[i]];
« ui/gfx/font_smoothing_win.cc ('K') | « ui/gfx/render_text.cc ('k') | ui/ui.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698