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

Side by Side Diff: ui/views/controls/label.h

Issue 9688020: views: Add subpixel rendering test for views::Label. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 9 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | ui/views/controls/label_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef UI_VIEWS_CONTROLS_LABEL_H_ 5 #ifndef UI_VIEWS_CONTROLS_LABEL_H_
6 #define UI_VIEWS_CONTROLS_LABEL_H_ 6 #define UI_VIEWS_CONTROLS_LABEL_H_
7 #pragma once 7 #pragma once
8 8
9 #include <string> 9 #include <string>
10 10
(...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after
212 212
213 private: 213 private:
214 // These tests call CalculateDrawStringParams in order to verify the 214 // These tests call CalculateDrawStringParams in order to verify the
215 // calculations done for drawing text. 215 // calculations done for drawing text.
216 FRIEND_TEST_ALL_PREFIXES(LabelTest, DrawSingleLineString); 216 FRIEND_TEST_ALL_PREFIXES(LabelTest, DrawSingleLineString);
217 FRIEND_TEST_ALL_PREFIXES(LabelTest, DrawMultiLineString); 217 FRIEND_TEST_ALL_PREFIXES(LabelTest, DrawMultiLineString);
218 FRIEND_TEST_ALL_PREFIXES(LabelTest, DrawSingleLineStringInRTL); 218 FRIEND_TEST_ALL_PREFIXES(LabelTest, DrawSingleLineStringInRTL);
219 FRIEND_TEST_ALL_PREFIXES(LabelTest, DrawMultiLineStringInRTL); 219 FRIEND_TEST_ALL_PREFIXES(LabelTest, DrawMultiLineStringInRTL);
220 FRIEND_TEST_ALL_PREFIXES(LabelTest, AutoDetectDirectionality); 220 FRIEND_TEST_ALL_PREFIXES(LabelTest, AutoDetectDirectionality);
221 221
222 // Calls ComputeDrawStringFlags().
223 FRIEND_TEST_ALL_PREFIXES(LabelTest, DisableSubpixelRendering);
224
222 static gfx::Font GetDefaultFont(); 225 static gfx::Font GetDefaultFont();
223 226
224 void Init(const string16& text, const gfx::Font& font); 227 void Init(const string16& text, const gfx::Font& font);
225 228
226 void RecalculateColors(); 229 void RecalculateColors();
227 230
228 // If the mouse is over the text, SetContainsMouse(true) is invoked, otherwise 231 // If the mouse is over the text, SetContainsMouse(true) is invoked, otherwise
229 // SetContainsMouse(false) is invoked. 232 // SetContainsMouse(false) is invoked.
230 void UpdateContainsMouse(const MouseEvent& event); 233 void UpdateContainsMouse(const MouseEvent& event);
231 234
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
279 // allows this view to reserve space for a focus border that it otherwise 282 // allows this view to reserve space for a focus border that it otherwise
280 // might not have because it is not itself focusable. 283 // might not have because it is not itself focusable.
281 bool has_focus_border_; 284 bool has_focus_border_;
282 285
283 DISALLOW_COPY_AND_ASSIGN(Label); 286 DISALLOW_COPY_AND_ASSIGN(Label);
284 }; 287 };
285 288
286 } // namespace views 289 } // namespace views
287 290
288 #endif // UI_VIEWS_CONTROLS_LABEL_H_ 291 #endif // UI_VIEWS_CONTROLS_LABEL_H_
OLDNEW
« no previous file with comments | « no previous file | ui/views/controls/label_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698