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

Unified Diff: ui/gfx/render_text.cc

Issue 19352002: Fixes vertical alignment of RenderText. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixes the unit test. Created 7 years, 5 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.cc
diff --git a/ui/gfx/render_text.cc b/ui/gfx/render_text.cc
index d3c6bea6ffe682b03d68e8e071f991769e5edaa8..5c822e878e469b988a252da3dbc64099640973c3 100644
--- a/ui/gfx/render_text.cc
+++ b/ui/gfx/render_text.cc
@@ -357,9 +357,7 @@ void RenderText::SetFont(const Font& font) {
}
void RenderText::SetFontSize(int size) {
- font_list_ = font_list_.DeriveFontListWithSize(size);
- cached_bounds_and_offset_valid_ = false;
- ResetLayout();
+ SetFontList(font_list_.DeriveFontListWithSize(size));
}
void RenderText::SetCursorEnabled(bool cursor_enabled) {

Powered by Google App Engine
This is Rietveld 408576698