• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright 2016 Google Inc.
3  *
4  * Use of this source code is governed by a BSD-style license that can be
5  * found in the LICENSE file.
6  */
7 #ifndef SkPDFMakeToUnicodeCmap_DEFINED
8 #define SkPDFMakeToUnicodeCmap_DEFINED
9 
10 #include "include/core/SkTypes.h"
11 
12 #include <memory>
13 
14 class SkDynamicMemoryWStream;
15 class SkPDFGlyphUse;
16 class SkStreamAsset;
17 
18 std::unique_ptr<SkStreamAsset> SkPDFMakeToUnicodeCmap(
19         const SkUnichar* glyphToUnicode,
20         const SkPDFGlyphUse* subset,
21         bool multiByteGlyphs,
22         SkGlyphID firstGlyphID,
23         SkGlyphID lastGlyphID);
24 
25 // Exposed for unit testing.
26 void SkPDFAppendCmapSections(const SkUnichar* glyphToUnicode,
27                              const SkPDFGlyphUse* subset,
28                              SkDynamicMemoryWStream* cmap,
29                              bool multiByteGlyphs,
30                              SkGlyphID firstGlyphID,
31                              SkGlyphID lastGlyphID);
32 
33 #endif  // SkPDFMakeToUnicodeCmap_DEFINED
34