| OLD | NEW |
| 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 #include "ui/gfx/font.h" | 5 #include "ui/gfx/font.h" |
| 6 | 6 |
| 7 #include "base/macros.h" |
| 7 #include "base/strings/string16.h" | 8 #include "base/strings/string16.h" |
| 8 #include "base/strings/string_util.h" | 9 #include "base/strings/string_util.h" |
| 9 #include "base/strings/utf_string_conversions.h" | 10 #include "base/strings/utf_string_conversions.h" |
| 11 #include "build/build_config.h" |
| 10 #include "testing/gtest/include/gtest/gtest.h" | 12 #include "testing/gtest/include/gtest/gtest.h" |
| 11 | 13 |
| 12 #if defined(OS_WIN) | 14 #if defined(OS_WIN) |
| 13 #include "ui/gfx/platform_font_win.h" | 15 #include "ui/gfx/platform_font_win.h" |
| 14 #endif | 16 #endif |
| 15 | 17 |
| 16 namespace gfx { | 18 namespace gfx { |
| 17 namespace { | 19 namespace { |
| 18 | 20 |
| 19 using FontTest = testing::Test; | 21 using FontTest = testing::Test; |
| (...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 170 // The minimum font size is set to 5 in browser_main.cc. | 172 // The minimum font size is set to 5 in browser_main.cc. |
| 171 ScopedMinimumFontSizeCallback minimum_size(5); | 173 ScopedMinimumFontSizeCallback minimum_size(5); |
| 172 | 174 |
| 173 Font derived_font = cf.Derive(-2, cf.GetStyle()); | 175 Font derived_font = cf.Derive(-2, cf.GetStyle()); |
| 174 EXPECT_EQ(6, derived_font.GetFontSize()); | 176 EXPECT_EQ(6, derived_font.GetFontSize()); |
| 175 } | 177 } |
| 176 #endif // defined(OS_WIN) | 178 #endif // defined(OS_WIN) |
| 177 | 179 |
| 178 } // namespace | 180 } // namespace |
| 179 } // namespace gfx | 181 } // namespace gfx |
| OLD | NEW |