diff options
author | 2015-03-31 12:30:20 -0700 | |
---|---|---|
committer | 2015-03-31 12:30:20 -0700 | |
commit | 37c46cad21632cfc1411b08d73af37a1fffe2944 (patch) | |
tree | 9184735eca86ec7110cd970be674d19d4812e1f6 /src/pdf/SkPDFFont.cpp | |
parent | e0f812a7a107986dfa72e6855c1608b077428136 (diff) |
SkPDF: Factor SkPDFCatalog into SkPDFObjNumMap and SkPDFSubstituteMap
Motivation: Keep separate features separate. Also, future
linearization work will need to have several objNumMap
objects share a substituteMap. Also "catalog" has a
specific meaning in PDF. This catalog did not map to that
catalog.
- Modify SkPDFObject::emitObject and SkPDFObject::addResources
interface to requiore SkPDFObjNumMap and SkPDFSubstituteMap.
- SkPDFObjNumMap const in SkPDFObject::emitObject.
- Remove SkPDFCatalog.cpp/.h
- Modify SkDocument_PDF.cpp to use new functions
- Fold in SkPDFStream::populate
- Fold in SkPDFBitmap::emitDict
- Move SkPDFObjNumMap and SkPDFSubstituteMap to SkPDFTypes.h
- Note (via assert) that SkPDFArray & SkPDFDict don't need to
check substitutes.
- Remove extra space from SkPDFDict serialization.
- SkPDFBitmap SkPDFType0Font SkPDFGraphicState SkPDFStream
updated to new interface.
- PDFPrimitivesTest updated for new interface.
BUG=skia:3585
Review URL: https://codereview.chromium.org/1049753002
Diffstat (limited to 'src/pdf/SkPDFFont.cpp')
-rw-r--r-- | src/pdf/SkPDFFont.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/pdf/SkPDFFont.cpp b/src/pdf/SkPDFFont.cpp index d36a1d75c9..1a396c7da2 100644 --- a/src/pdf/SkPDFFont.cpp +++ b/src/pdf/SkPDFFont.cpp @@ -10,7 +10,6 @@ #include "SkData.h" #include "SkGlyphCache.h" #include "SkPaint.h" -#include "SkPDFCatalog.h" #include "SkPDFCanon.h" #include "SkPDFDevice.h" #include "SkPDFFont.h" @@ -1016,9 +1015,11 @@ SkPDFFont* SkPDFType0Font::getFontSubset(const SkPDFGlyphSet* subset) { } #ifdef SK_DEBUG -void SkPDFType0Font::emitObject(SkWStream* stream, SkPDFCatalog* catalog) { +void SkPDFType0Font::emitObject(SkWStream* stream, + const SkPDFObjNumMap& objNumMap, + const SkPDFSubstituteMap& substitutes) { SkASSERT(fPopulated); - return INHERITED::emitObject(stream, catalog); + return INHERITED::emitObject(stream, objNumMap, substitutes); } #endif |