webkit  2cdf99a9e3038c7e01b3c37e8ad903ecbe5eecf1
https://github.com/WebKit/webkit
FontCustomPlatformData.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2007 Apple Inc.
3  *
4  * This library is free software; you can redistribute it and/or
5  * modify it under the terms of the GNU Library General Public
6  * License as published by the Free Software Foundation; either
7  * version 2 of the License, or (at your option) any later version.
8  *
9  * This library is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12  * Library General Public License for more details.
13  *
14  * You should have received a copy of the GNU Library General Public License
15  * along with this library; see the file COPYING.LIB. If not, write to
16  * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
17  * Boston, MA 02110-1301, USA.
18  *
19  */
20 
21 #ifndef FontCustomPlatformData_h
22 #define FontCustomPlatformData_h
23 
24 #include "TextFlags.h"
25 #include <CoreFoundation/CFBase.h>
26 #include <wtf/Forward.h>
27 #include <wtf/Noncopyable.h>
28 #include <wtf/RetainPtr.h>
29 
30 typedef struct CGFont* CGFontRef;
31 typedef const struct __CTFontDescriptor* CTFontDescriptorRef;
32 
33 namespace WebCore {
34 
35 class FontDescription;
36 class FontPlatformData;
37 class SharedBuffer;
38 
39 template <typename T> class FontTaggedSettings;
40 typedef FontTaggedSettings<int> FontFeatureSettings;
41 
44 public:
46  : m_fontDescriptor(fontDescriptor)
47  {
48  }
49 
51 
52  FontPlatformData fontPlatformData(const FontDescription&, bool bold, bool italic, const FontFeatureSettings& fontFaceFeatures, const FontVariantSettings& fontFaceVariantSettings);
53 
54  static bool supportsFormat(const String&);
55 
57 };
58 
59 std::unique_ptr<FontCustomPlatformData> createFontCustomPlatformData(SharedBuffer&);
60 
61 }
62 
63 #endif
WTF_MAKE_NONCOPYABLE(FontCustomPlatformData)
~FontCustomPlatformData()
Definition: FontCustomPlatformDataFreeType.cpp:71
Definition: WTFString.h:78
const struct __CTFontDescriptor * CTFontDescriptorRef
Definition: FontCustomPlatformData.h:31
Definition: FontCustomPlatformData.h:42
RetainPtr< CTFontDescriptorRef > m_fontDescriptor
Definition: FontCustomPlatformData.h:56
FontCustomPlatformData(CTFontDescriptorRef fontDescriptor)
Definition: FontCustomPlatformData.h:45
Definition: FontPlatformData.h:77
Definition: SharedBuffer.h:52
std::unique_ptr< FontCustomPlatformData > createFontCustomPlatformData(SharedBuffer &buffer)
Definition: FontCustomPlatformDataFreeType.cpp:81
static bool supportsFormat(const String &)
Definition: FontCustomPlatformDataFreeType.cpp:95
Definition: TextFlags.h:144
Definition: FontDescription.h:41
FontTaggedSettings< int > FontFeatureSettings
Definition: FontTaggedSettings.h:138
FontPlatformData fontPlatformData(const FontDescription &, bool bold, bool italic, const FontFeatureSettings &fontFaceFeatures, const FontVariantSettings &fontFaceVariantSettings)
Definition: FontCustomPlatformData.cpp:37
This file is generated by create-http-header-name-table, do not edit.
Definition: CharsetData.cpp:6
WTF_MAKE_FAST_ALLOCATED
Definition: FontCustomPlatformData.h:43
struct CGFont * CGFontRef
Definition: FontCustomPlatformData.h:30