| 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/platform_font_linux.h" | 5 #include "ui/gfx/platform_font_linux.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "base/macros.h" |
| 9 #include "base/memory/ref_counted.h" | 10 #include "base/memory/ref_counted.h" |
| 11 #include "build/build_config.h" |
| 10 #include "testing/gtest/include/gtest/gtest.h" | 12 #include "testing/gtest/include/gtest/gtest.h" |
| 11 #include "ui/gfx/font.h" | 13 #include "ui/gfx/font.h" |
| 12 #include "ui/gfx/font_render_params.h" | 14 #include "ui/gfx/font_render_params.h" |
| 13 #include "ui/gfx/linux_font_delegate.h" | 15 #include "ui/gfx/linux_font_delegate.h" |
| 14 #include "ui/gfx/test/fontconfig_util_linux.h" | 16 #include "ui/gfx/test/fontconfig_util_linux.h" |
| 15 | 17 |
| 16 namespace gfx { | 18 namespace gfx { |
| 17 | 19 |
| 18 // Implementation of LinuxFontDelegate used to control the default font | 20 // Implementation of LinuxFontDelegate used to control the default font |
| 19 // description on Linux. | 21 // description on Linux. |
| (...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 113 test_font_delegate_.set_style(gfx::Font::BOLD); | 115 test_font_delegate_.set_style(gfx::Font::BOLD); |
| 114 #endif | 116 #endif |
| 115 PlatformFontLinux::ReloadDefaultFont(); | 117 PlatformFontLinux::ReloadDefaultFont(); |
| 116 scoped_refptr<gfx::PlatformFontLinux> font2(new gfx::PlatformFontLinux()); | 118 scoped_refptr<gfx::PlatformFontLinux> font2(new gfx::PlatformFontLinux()); |
| 117 EXPECT_EQ("Times New Roman", font2->GetFontName()); | 119 EXPECT_EQ("Times New Roman", font2->GetFontName()); |
| 118 EXPECT_EQ(15, font2->GetFontSize()); | 120 EXPECT_EQ(15, font2->GetFontSize()); |
| 119 EXPECT_EQ(gfx::Font::BOLD, font2->GetStyle()); | 121 EXPECT_EQ(gfx::Font::BOLD, font2->GetStyle()); |
| 120 } | 122 } |
| 121 | 123 |
| 122 } // namespace gfx | 124 } // namespace gfx |
| OLD | NEW |