| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2013 Google Inc. | 2 * Copyright 2013 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 SkDocument_DEFINED | 8 #ifndef SkDocument_DEFINED |
| 9 #define SkDocument_DEFINED | 9 #define SkDocument_DEFINED |
| 10 | 10 |
| (...skipping 29 matching lines...) Expand all Loading... |
| 40 struct OptionalTimestamp { | 40 struct OptionalTimestamp { |
| 41 SkTime::DateTime fDateTime; | 41 SkTime::DateTime fDateTime; |
| 42 bool fEnabled; | 42 bool fEnabled; |
| 43 OptionalTimestamp() : fEnabled(false) {} | 43 OptionalTimestamp() : fEnabled(false) {} |
| 44 }; | 44 }; |
| 45 | 45 |
| 46 /** | 46 /** |
| 47 * Optional metadata to be passed into the PDF factory function. | 47 * Optional metadata to be passed into the PDF factory function. |
| 48 */ | 48 */ |
| 49 struct PDFMetadata { | 49 struct PDFMetadata { |
| 50 /** |
| 51 * The document’s title. |
| 52 */ |
| 50 SkString fTitle; | 53 SkString fTitle; |
| 54 /** |
| 55 * The name of the person who created the document. |
| 56 */ |
| 51 SkString fAuthor; | 57 SkString fAuthor; |
| 58 /** |
| 59 * The subject of the document. |
| 60 */ |
| 52 SkString fSubject; | 61 SkString fSubject; |
| 62 /** |
| 63 * Keywords associated with the document. Commas may be used |
| 64 * to delineate keywords within the string. |
| 65 */ |
| 53 SkString fKeywords; | 66 SkString fKeywords; |
| 67 /** |
| 68 * If the document was converted to PDF from another format, |
| 69 * the name of the conforming product that created the |
| 70 * original document from which it was converted. |
| 71 */ |
| 54 SkString fCreator; | 72 SkString fCreator; |
| 73 /** |
| 74 * The product that is converting this document to PDF. |
| 75 * |
| 76 * Leave fProducer empty to get the default, correct value. |
| 77 */ |
| 78 SkString fProducer; |
| 79 /** |
| 80 * The date and time the document was created. |
| 81 */ |
| 55 OptionalTimestamp fCreation; | 82 OptionalTimestamp fCreation; |
| 83 /** |
| 84 * The date and time the document was most recently modified. |
| 85 */ |
| 56 OptionalTimestamp fModified; | 86 OptionalTimestamp fModified; |
| 57 }; | 87 }; |
| 58 | 88 |
| 59 /** | 89 /** |
| 60 * Create a PDF-backed document, writing the results into a | 90 * Create a PDF-backed document, writing the results into a |
| 61 * SkWStream. | 91 * SkWStream. |
| 62 * | 92 * |
| 63 * PDF pages are sized in point units. 1 pt == 1/72 inch == | 93 * PDF pages are sized in point units. 1 pt == 1/72 inch == |
| 64 * 127/360 mm. | 94 * 127/360 mm. |
| 65 * | 95 * |
| (...skipping 205 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 271 | 301 |
| 272 private: | 302 private: |
| 273 SkWStream* fStream; | 303 SkWStream* fStream; |
| 274 void (*fDoneProc)(SkWStream*, bool aborted); | 304 void (*fDoneProc)(SkWStream*, bool aborted); |
| 275 State fState; | 305 State fState; |
| 276 | 306 |
| 277 typedef SkRefCnt INHERITED; | 307 typedef SkRefCnt INHERITED; |
| 278 }; | 308 }; |
| 279 | 309 |
| 280 #endif | 310 #endif |
| OLD | NEW |