OLD | NEW |
1 | 1 |
2 /* | 2 /* |
3 * Copyright 2010 The Android Open Source Project | 3 * Copyright 2010 The Android Open Source Project |
4 * | 4 * |
5 * Use of this source code is governed by a BSD-style license that can be | 5 * Use of this source code is governed by a BSD-style license that can be |
6 * found in the LICENSE file. | 6 * found in the LICENSE file. |
7 */ | 7 */ |
8 | 8 |
9 | 9 |
10 #ifndef SkPDFDocument_DEFINED | 10 #ifndef SkPDFDocument_DEFINED |
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
62 SK_API bool setPage(int pageNumber, SkPDFDevice* pdfDevice); | 62 SK_API bool setPage(int pageNumber, SkPDFDevice* pdfDevice); |
63 | 63 |
64 /** Append the passed pdf device to the document as a new page. Returns | 64 /** Append the passed pdf device to the document as a new page. Returns |
65 * true if successful. Will fail if the document has already been emitted. | 65 * true if successful. Will fail if the document has already been emitted. |
66 * | 66 * |
67 * @param pdfDevice The page to add to this document. | 67 * @param pdfDevice The page to add to this document. |
68 */ | 68 */ |
69 SK_API bool appendPage(SkPDFDevice* pdfDevice); | 69 SK_API bool appendPage(SkPDFDevice* pdfDevice); |
70 | 70 |
71 /** Get the count of unique font types used in the document. | 71 /** Get the count of unique font types used in the document. |
72 * DEPRECATED. | |
73 */ | |
74 SK_API void getCountOfFontTypes( | |
75 int counts[SkAdvancedTypefaceMetrics::kOther_Font + 2]) const; | |
76 | |
77 /** Get the count of unique font types used in the document. | |
78 */ | 72 */ |
79 SK_API void getCountOfFontTypes( | 73 SK_API void getCountOfFontTypes( |
80 int counts[SkAdvancedTypefaceMetrics::kOther_Font + 1], | 74 int counts[SkAdvancedTypefaceMetrics::kNotEmbeddable_Font + 1]) const; |
81 int* notSubsettableCount, | |
82 int* notEmbedddableCount) const; | |
83 | 75 |
84 private: | 76 private: |
85 SkAutoTDelete<SkPDFCatalog> fCatalog; | 77 SkAutoTDelete<SkPDFCatalog> fCatalog; |
86 int64_t fXRefFileOffset; | 78 int64_t fXRefFileOffset; |
87 | 79 |
88 SkTDArray<SkPDFPage*> fPages; | 80 SkTDArray<SkPDFPage*> fPages; |
89 SkTDArray<SkPDFDict*> fPageTree; | 81 SkTDArray<SkPDFDict*> fPageTree; |
90 SkPDFDict* fDocCatalog; | 82 SkPDFDict* fDocCatalog; |
91 SkTSet<SkPDFObject*>* fFirstPageResources; | 83 SkTSet<SkPDFObject*>* fFirstPageResources; |
92 SkTSet<SkPDFObject*>* fOtherPageResources; | 84 SkTSet<SkPDFObject*>* fOtherPageResources; |
(...skipping 11 matching lines...) Expand all Loading... |
104 size_t headerSize(); | 96 size_t headerSize(); |
105 | 97 |
106 /** Output the PDF footer to the passed stream. | 98 /** Output the PDF footer to the passed stream. |
107 * @param stream The writable output stream to send the footer to. | 99 * @param stream The writable output stream to send the footer to. |
108 * @param objCount The number of objects in the PDF. | 100 * @param objCount The number of objects in the PDF. |
109 */ | 101 */ |
110 void emitFooter(SkWStream* stream, int64_t objCount); | 102 void emitFooter(SkWStream* stream, int64_t objCount); |
111 }; | 103 }; |
112 | 104 |
113 #endif | 105 #endif |
OLD | NEW |