OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2016 Google Inc. | 2 * Copyright 2016 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 #ifndef SkPDFDocument_DEFINED | 7 #ifndef SkPDFDocument_DEFINED |
8 #define SkPDFDocument_DEFINED | 8 #define SkPDFDocument_DEFINED |
9 | 9 |
10 #include "SkDocument.h" | 10 #include "SkDocument.h" |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
46 public: | 46 public: |
47 SkPDFDocument(SkWStream*, | 47 SkPDFDocument(SkWStream*, |
48 void (*)(SkWStream*, bool), | 48 void (*)(SkWStream*, bool), |
49 SkScalar, | 49 SkScalar, |
50 const SkDocument::PDFMetadata&, | 50 const SkDocument::PDFMetadata&, |
51 sk_sp<SkPixelSerializer>, | 51 sk_sp<SkPixelSerializer>, |
52 bool); | 52 bool); |
53 virtual ~SkPDFDocument(); | 53 virtual ~SkPDFDocument(); |
54 SkCanvas* onBeginPage(SkScalar, SkScalar, const SkRect&) override; | 54 SkCanvas* onBeginPage(SkScalar, SkScalar, const SkRect&) override; |
55 void onEndPage() override; | 55 void onEndPage() override; |
56 bool onClose(SkWStream*) override; | 56 void onClose(SkWStream*) override; |
57 void onAbort() override; | 57 void onAbort() override; |
58 | 58 |
59 /** | 59 /** |
60 Serialize the object, as well as any other objects it | 60 Serialize the object, as well as any other objects it |
61 indirectly refers to. If any any other objects have been added | 61 indirectly refers to. If any any other objects have been added |
62 to the SkPDFObjNumMap without serializing them, they will be | 62 to the SkPDFObjNumMap without serializing them, they will be |
63 serialized as well. | 63 serialized as well. |
64 | 64 |
65 It might go without saying that objects should not be changed | 65 It might go without saying that objects should not be changed |
66 after calling serialize, since those changes will be too late. | 66 after calling serialize, since those changes will be too late. |
(...skipping 13 matching lines...) Expand all Loading... |
80 sk_sp<SkPDFObject> fID; | 80 sk_sp<SkPDFObject> fID; |
81 sk_sp<SkPDFObject> fXMP; | 81 sk_sp<SkPDFObject> fXMP; |
82 SkScalar fRasterDpi; | 82 SkScalar fRasterDpi; |
83 SkDocument::PDFMetadata fMetadata; | 83 SkDocument::PDFMetadata fMetadata; |
84 bool fPDFA; | 84 bool fPDFA; |
85 | 85 |
86 void reset(); | 86 void reset(); |
87 }; | 87 }; |
88 | 88 |
89 #endif // SkPDFDocument_DEFINED | 89 #endif // SkPDFDocument_DEFINED |
OLD | NEW |