blob: b77f23de160a508d8e96fe5cfeeb30e685277753 [file] [log] [blame]
halcanary8eccc302016-08-09 13:04:34 -07001/*
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
Mike Kleinc0bd9f92019-04-23 12:05:21 -050010#include "include/core/SkStream.h"
11#include "src/pdf/SkPDFFont.h"
halcanary8eccc302016-08-09 13:04:34 -070012
Hal Canary9a3f5542018-12-10 19:59:07 -050013std::unique_ptr<SkStreamAsset> SkPDFMakeToUnicodeCmap(
Hal Canary46cc3da2018-05-09 11:50:34 -040014 const SkUnichar* glyphToUnicode,
Hal Canary31355982018-10-19 12:21:41 -040015 const SkPDFGlyphUse* subset,
halcanary8eccc302016-08-09 13:04:34 -070016 bool multiByteGlyphs,
17 SkGlyphID firstGlyphID,
18 SkGlyphID lastGlyphID);
19
20// Exposed for unit testing.
Hal Canary46cc3da2018-05-09 11:50:34 -040021void SkPDFAppendCmapSections(const SkUnichar* glyphToUnicode,
Hal Canary31355982018-10-19 12:21:41 -040022 const SkPDFGlyphUse* subset,
halcanary8eccc302016-08-09 13:04:34 -070023 SkDynamicMemoryWStream* cmap,
24 bool multiByteGlyphs,
25 SkGlyphID firstGlyphID,
26 SkGlyphID lastGlyphID);
27
28#endif // SkPDFMakeToUnicodeCmap_DEFINED