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
3 // found in the LICENSE file.
4 
5 #ifndef THIRD_PARTY_BLINK_RENDERER_CORE_CSS_RESOLVER_FONT_STYLE_RESOLVER_H_
6 #define THIRD_PARTY_BLINK_RENDERER_CORE_CSS_RESOLVER_FONT_STYLE_RESOLVER_H_
7 
8 #include "third_party/blink/renderer/core/css/css_primitive_value_mappings.h"
9 #include "third_party/blink/renderer/core/css/css_property_value_set.h"
10 #include "third_party/blink/renderer/core/css/css_value_id_mappings.h"
11 #include "third_party/blink/renderer/platform/fonts/font_description.h"
12 #include "third_party/blink/renderer/platform/fonts/font_selector.h"
13 
14 namespace blink {
15 
16 // FontStyleResolver is a simpler version of Font-related parts of
17 // StyleResolver. This is needed because ComputedStyle/StyleResolver can't run
18 // outside the main thread or without a document. This is a way of minimizing
19 // duplicate code for when font parsing is needed.
20 class CORE_EXPORT FontStyleResolver {
21   STATIC_ONLY(FontStyleResolver);
22 
23  public:
24   static FontDescription ComputeFont(const CSSPropertyValueSet&, FontSelector*);
25 };
26 
27 }  // namespace blink
28 
29 #endif
30