OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2014 Google Inc. | 2 * Copyright 2014 Google Inc. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
6 */ | 6 */ |
7 | 7 |
8 #include "SkTypes.h" | 8 #include "SkTypes.h" |
9 #if defined(SK_BUILD_FOR_WIN32) | 9 #if defined(SK_BUILD_FOR_WIN32) |
10 | 10 |
11 #include "SkDWrite.h" | 11 #include "SkDWrite.h" |
12 #include "SkDWriteFontFileStream.h" | 12 #include "SkDWriteFontFileStream.h" |
13 #include "SkFontMgr.h" | 13 #include "SkFontMgr.h" |
14 #include "SkHRESULT.h" | 14 #include "SkHRESULT.h" |
15 #include "SkMutex.h" | 15 #include "SkMutex.h" |
16 #include "SkStream.h" | 16 #include "SkStream.h" |
17 #include "SkTScopedComPtr.h" | 17 #include "SkTScopedComPtr.h" |
18 #include "SkTypeface.h" | 18 #include "SkTypeface.h" |
19 #include "SkTypefaceCache.h" | 19 #include "SkTypefaceCache.h" |
| 20 #include "SkTypeface_win.h" |
20 #include "SkTypeface_win_dw.h" | 21 #include "SkTypeface_win_dw.h" |
21 #include "SkTypes.h" | 22 #include "SkTypes.h" |
22 #include "SkUtils.h" | 23 #include "SkUtils.h" |
23 | 24 |
24 #include <dwrite.h> | 25 #include <dwrite.h> |
25 | |
26 #if SK_HAS_DWRITE_2_H | 26 #if SK_HAS_DWRITE_2_H |
27 #include <dwrite_2.h> | 27 #include <dwrite_2.h> |
28 #endif | 28 #endif |
29 | 29 |
30 //////////////////////////////////////////////////////////////////////////////// | 30 //////////////////////////////////////////////////////////////////////////////// |
31 | 31 |
32 class StreamFontFileLoader : public IDWriteFontFileLoader { | 32 class StreamFontFileLoader : public IDWriteFontFileLoader { |
33 public: | 33 public: |
34 // IUnknown methods | 34 // IUnknown methods |
35 virtual HRESULT STDMETHODCALLTYPE QueryInterface(REFIID iid, void** ppvObjec
t); | 35 virtual HRESULT STDMETHODCALLTYPE QueryInterface(REFIID iid, void** ppvObjec
t); |
(...skipping 1050 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1086 | 1086 |
1087 #include "SkFontMgr_indirect.h" | 1087 #include "SkFontMgr_indirect.h" |
1088 SK_API SkFontMgr* SkFontMgr_New_DirectWriteRenderer(SkRemotableFontMgr* proxy) { | 1088 SK_API SkFontMgr* SkFontMgr_New_DirectWriteRenderer(SkRemotableFontMgr* proxy) { |
1089 SkAutoTUnref<SkFontMgr> impl(SkFontMgr_New_DirectWrite()); | 1089 SkAutoTUnref<SkFontMgr> impl(SkFontMgr_New_DirectWrite()); |
1090 if (impl.get() == nullptr) { | 1090 if (impl.get() == nullptr) { |
1091 return nullptr; | 1091 return nullptr; |
1092 } | 1092 } |
1093 return new SkFontMgr_Indirect(impl.get(), proxy); | 1093 return new SkFontMgr_Indirect(impl.get(), proxy); |
1094 } | 1094 } |
1095 #endif//defined(SK_BUILD_FOR_WIN32) | 1095 #endif//defined(SK_BUILD_FOR_WIN32) |
OLD | NEW |