Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(394)

Side by Side Diff: src/pdf/SkPDFMetadata.h

Issue 1916093002: SkDocument/PDF: new API (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: 2016-04-26 (Tuesday) 15:55:33 EDT Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/pdf/SkPDFDocument.cpp ('k') | src/pdf/SkPDFMetadata.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2015 Google Inc. 2 * Copyright 2015 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 #ifndef SkPDFMetadata_DEFINED 8 #ifndef SkPDFMetadata_DEFINED
9 #define SkPDFMetadata_DEFINED 9 #define SkPDFMetadata_DEFINED
10 10
11 #include "SkDocument.h" 11 #include "SkDocument.h"
12 #include "SkTime.h" 12 #include "SkTime.h"
13 13
14 class SkPDFObject; 14 class SkPDFObject;
15 15
16 struct SkPDFMetadata { 16 namespace SkPDFMetadata {
17 SkTArray<SkDocument::Attribute> fInfo; 17 sk_sp<SkPDFObject> MakeDocumentInformationDict(const SkDocument::PDFMetadata&);
18 std::unique_ptr<const SkTime::DateTime> fCreation;
19 std::unique_ptr<const SkTime::DateTime> fModified;
20 18
21 SkPDFObject* createDocumentInformationDict() const; 19 struct UUID {
22 20 uint8_t fData[16];
23 struct UUID {
24 uint8_t fData[16];
25 };
26 UUID uuid() const;
27 static SkPDFObject* CreatePdfId(const UUID& doc, const UUID& instance);
28 SkPDFObject* createXMPObject(const UUID& doc, const UUID& instance) const;
29 }; 21 };
30 22
23 UUID CreateUUID(const SkDocument::PDFMetadata&);
24
25 sk_sp<SkPDFObject> MakePdfId(const UUID& doc, const UUID& instance);
26
27 sk_sp<SkPDFObject> MakeXMPObject(const SkDocument::PDFMetadata&,
28 const UUID& doc,
29 const UUID& instance);
30
31 #ifdef SK_SUPPORT_LEGACY_DOCUMENT_API
32 void SetMetadataByKey(const SkString& key,
33 const SkString& value,
34 SkDocument::PDFMetadata*);
35 #endif
36 }
31 #endif // SkPDFMetadata_DEFINED 37 #endif // SkPDFMetadata_DEFINED
OLDNEW
« no previous file with comments | « src/pdf/SkPDFDocument.cpp ('k') | src/pdf/SkPDFMetadata.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698