| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2011 Google Inc. | 2 * Copyright 2011 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 SkPDFDevice_DEFINED | 8 #ifndef SkPDFDevice_DEFINED |
| 9 #define SkPDFDevice_DEFINED | 9 #define SkPDFDevice_DEFINED |
| 10 | 10 |
| (...skipping 273 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 284 | 284 |
| 285 void populateGraphicStateEntryFromPaint(const SkMatrix& matrix, | 285 void populateGraphicStateEntryFromPaint(const SkMatrix& matrix, |
| 286 const SkClipStack& clipStack, | 286 const SkClipStack& clipStack, |
| 287 const SkRegion& clipRegion, | 287 const SkRegion& clipRegion, |
| 288 const SkPaint& paint, | 288 const SkPaint& paint, |
| 289 bool hasText, | 289 bool hasText, |
| 290 GraphicStateEntry* entry); | 290 GraphicStateEntry* entry); |
| 291 int addGraphicStateResource(SkPDFObject* gs); | 291 int addGraphicStateResource(SkPDFObject* gs); |
| 292 int addXObjectResource(SkPDFObject* xObject); | 292 int addXObjectResource(SkPDFObject* xObject); |
| 293 | 293 |
| 294 void updateFont(const SkPaint& paint, uint16_t glyphID, ContentEntry* conten
tEntry); | 294 // returns false when a valid SkFont can not be produced |
| 295 bool updateFont(const SkPaint& paint, uint16_t glyphID, ContentEntry* conten
tEntry); |
| 295 int getFontResourceIndex(SkTypeface* typeface, uint16_t glyphID); | 296 int getFontResourceIndex(SkTypeface* typeface, uint16_t glyphID); |
| 296 | 297 |
| 297 void internalDrawPaint(const SkPaint& paint, ContentEntry* contentEntry); | 298 void internalDrawPaint(const SkPaint& paint, ContentEntry* contentEntry); |
| 298 | 299 |
| 299 void internalDrawImage(const SkMatrix& origMatrix, | 300 void internalDrawImage(const SkMatrix& origMatrix, |
| 300 const SkClipStack* clipStack, | 301 const SkClipStack* clipStack, |
| 301 const SkRegion& origClipRegion, | 302 const SkRegion& origClipRegion, |
| 302 SkImageBitmap imageBitmap, | 303 SkImageBitmap imageBitmap, |
| 303 const SkPaint& paint); | 304 const SkPaint& paint); |
| 304 | 305 |
| 305 bool handleInversePath(const SkDraw& d, const SkPath& origPath, | 306 bool handleInversePath(const SkDraw& d, const SkPath& origPath, |
| 306 const SkPaint& paint, bool pathIsMutable, | 307 const SkPaint& paint, bool pathIsMutable, |
| 307 const SkMatrix* prePathMatrix = nullptr); | 308 const SkMatrix* prePathMatrix = nullptr); |
| 308 void handlePointAnnotation(const SkPoint&, const SkMatrix&, const char key[]
, SkData* value); | 309 void handlePointAnnotation(const SkPoint&, const SkMatrix&, const char key[]
, SkData* value); |
| 309 void handlePathAnnotation(const SkPath&, const SkDraw& d, const char key[],
SkData* value); | 310 void handlePathAnnotation(const SkPath&, const SkDraw& d, const char key[],
SkData* value); |
| 310 | 311 |
| 311 typedef SkBaseDevice INHERITED; | 312 typedef SkBaseDevice INHERITED; |
| 312 | 313 |
| 313 // TODO(edisonn): Only SkDocument_PDF and SkPDFImageShader should be able to
create | 314 // TODO(edisonn): Only SkDocument_PDF and SkPDFImageShader should be able to
create |
| 314 // an SkPDFDevice | 315 // an SkPDFDevice |
| 315 //friend class SkDocument_PDF; | 316 //friend class SkDocument_PDF; |
| 316 //friend class SkPDFImageShader; | 317 //friend class SkPDFImageShader; |
| 317 }; | 318 }; |
| 318 | 319 |
| 319 #endif | 320 #endif |
| OLD | NEW |