Chromium Code Reviews| Index: ui/gfx/platform_font_mac.h |
| diff --git a/ui/gfx/platform_font_mac.h b/ui/gfx/platform_font_mac.h |
| index 66ffc40bd58241ba2d58b983cc48c1bcb59a2fdd..8ec29a1fe308014c16a1df7197987b5b0a657b8e 100644 |
| --- a/ui/gfx/platform_font_mac.h |
| +++ b/ui/gfx/platform_font_mac.h |
| @@ -21,8 +21,11 @@ class PlatformFontMac : public PlatformFont { |
| int font_size); |
| // Overridden from PlatformFont: |
| - Font DeriveFont(int size_delta, int style) const override; |
| + Font DeriveFont(int size_delta, |
| + int style, |
| + Font::Weight weight) const override; |
| int GetHeight() override; |
| + gfx::Font::Weight GetWeight() const override; |
|
Alexei Svitkine (slow)
2016/04/04 16:34:51
No need for gfx:: prefix since this is in gfx:: na
Mikus
2016/04/05 16:18:34
Done.
|
| int GetBaseline() override; |
| int GetCapHeight() override; |
| int GetExpectedTextWidth(int length) override; |
| @@ -34,7 +37,10 @@ class PlatformFontMac : public PlatformFont { |
| NativeFont GetNativeFont() const override; |
| private: |
| - PlatformFontMac(const std::string& font_name, int font_size, int font_style); |
| + PlatformFontMac(const std::string& font_name, |
| + int font_size, |
| + int font_style, |
| + Font::Weight font_weight); |
| ~PlatformFontMac() override; |
| // Calculates and caches the font metrics and inits |render_params_|. |
| @@ -51,6 +57,7 @@ class PlatformFontMac : public PlatformFont { |
| std::string font_name_; // Corresponds to -[NSFont fontFamily]. |
| int font_size_; |
| int font_style_; |
| + Font::Weight font_weight_; |
| // Cached metrics, generated in CalculateMetrics(). |
| int height_; |