OLD | NEW |
1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 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 CHROME_BROWSER_UI_VIEWS_HARMONY_CHROME_TYPOGRAPHY_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_HARMONY_CHROME_TYPOGRAPHY_H_ |
6 #define CHROME_BROWSER_UI_VIEWS_HARMONY_CHROME_TYPOGRAPHY_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_HARMONY_CHROME_TYPOGRAPHY_H_ |
7 | 7 |
8 #include "base/macros.h" | 8 #include "base/macros.h" |
9 #include "ui/views/style/typography.h" | 9 #include "ui/views/style/typography.h" |
10 #include "ui/views/style/typography_provider.h" | 10 #include "ui/views/style/typography_provider.h" |
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
54 // or hostname. | 54 // or hostname. |
55 STYLE_EMPHASIZED, | 55 STYLE_EMPHASIZED, |
56 }; | 56 }; |
57 | 57 |
58 // TypographyProvider that provides pre-Harmony fonts in Chrome. | 58 // TypographyProvider that provides pre-Harmony fonts in Chrome. |
59 class LegacyTypographyProvider : public views::DefaultTypographyProvider { | 59 class LegacyTypographyProvider : public views::DefaultTypographyProvider { |
60 public: | 60 public: |
61 LegacyTypographyProvider() = default; | 61 LegacyTypographyProvider() = default; |
62 | 62 |
63 // DefaultTypographyProvider: | 63 // DefaultTypographyProvider: |
64 const gfx::FontList& GetFont(int text_context, int text_style) const override; | 64 const gfx::FontList& GetFont(int context, int style) const override; |
| 65 SkColor GetColor(int context, |
| 66 int style, |
| 67 const ui::NativeTheme& theme) const override; |
65 | 68 |
66 private: | 69 private: |
67 DISALLOW_COPY_AND_ASSIGN(LegacyTypographyProvider); | 70 DISALLOW_COPY_AND_ASSIGN(LegacyTypographyProvider); |
68 }; | 71 }; |
69 | 72 |
70 #endif // CHROME_BROWSER_UI_VIEWS_HARMONY_CHROME_TYPOGRAPHY_H_ | 73 #endif // CHROME_BROWSER_UI_VIEWS_HARMONY_CHROME_TYPOGRAPHY_H_ |
OLD | NEW |