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

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

Issue 2330503002: work in progress (Closed)
Patch Set: Created 4 years, 3 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/SkPDFFont.cpp ('k') | src/pdf/SkPDFResourceDict.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 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 SkPDFResourceDict_DEFINED 8 #ifndef SkPDFResourceDict_DEFINED
9 #define SkPDFResourceDict_DEFINED 9 #define SkPDFResourceDict_DEFINED
10 10
(...skipping 14 matching lines...) Expand all
25 enum SkPDFResourceType { 25 enum SkPDFResourceType {
26 kExtGState_ResourceType, 26 kExtGState_ResourceType,
27 kPattern_ResourceType, 27 kPattern_ResourceType,
28 kXObject_ResourceType, 28 kXObject_ResourceType,
29 kFont_ResourceType, 29 kFont_ResourceType,
30 // These additional types are defined by the spec, but not 30 // These additional types are defined by the spec, but not
31 // currently used by Skia: ColorSpace, Shading, Properties 31 // currently used by Skia: ColorSpace, Shading, Properties
32 kResourceTypeCount 32 kResourceTypeCount
33 }; 33 };
34 34
35 static char GetResourceTypePrefix(SkPDFResourceDict::SkPDFResourceType type) ;
36
35 /** Create a PDF resource dictionary. 37 /** Create a PDF resource dictionary.
36 * The full set of ProcSet entries is automatically created for backwards 38 * The full set of ProcSet entries is automatically created for backwards
37 * compatibility, as recommended by the PDF spec. 39 * compatibility, as recommended by the PDF spec.
38 * 40 *
39 * Any arguments can be nullptr. 41 * Any arguments can be nullptr.
40 */ 42 */
41 static sk_sp<SkPDFDict> Make( 43 static sk_sp<SkPDFDict> Make(
42 const SkTDArray<SkPDFObject*>* gStateResources, 44 const SkTDArray<SkPDFObject*>* gStateResources,
43 const SkTDArray<SkPDFObject*>* patternResources, 45 const SkTDArray<SkPDFObject*>* patternResources,
44 const SkTDArray<SkPDFObject*>* xObjectResources, 46 const SkTDArray<SkPDFObject*>* xObjectResources,
45 const SkTDArray<SkPDFObject*>* fontResources); 47 const SkTDArray<SkPDFObject*>* fontResources);
46 48
47 /** 49 /**
48 * Returns the name for the resource that will be generated by the resource 50 * Returns the name for the resource that will be generated by the resource
49 * dict. 51 * dict.
50 * 52 *
51 * @param type The type of resource being entered, like 53 * @param type The type of resource being entered, like
52 * kPattern_ResourceType or kExtGState_ResourceType. 54 * kPattern_ResourceType or kExtGState_ResourceType.
53 * @param key The resource key, should be unique within its type. 55 * @param key The resource key, should be unique within its type.
54 */ 56 */
55 static SkString getResourceName(SkPDFResourceType type, int key); 57 static SkString getResourceName(SkPDFResourceType type, int key);
56 }; 58 };
57 59
58 #endif 60 #endif
OLDNEW
« no previous file with comments | « src/pdf/SkPDFFont.cpp ('k') | src/pdf/SkPDFResourceDict.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698