SkTScopedComPtr<IStream> fontStream;
int ttcIndex;
SkStream* fontData = typeface->openStream(&ttcIndex);
+ //TODO: cannot handle FON fonts.
HRM(SkIStream::CreateFromSkStream(fontData, true, &fontStream),
"Could not create font stream.");
HRV(CreateTypefaceUse(paint, &typeface));
SkDraw myDraw(d);
+ myDraw.fMatrix = &SkMatrix::I();
SkXPSDrawProcs procs;
text_draw_init(paint, text, byteLen, *typeface->glyphsUsed, myDraw, procs);
HRV(CreateTypefaceUse(paint, &typeface));
SkDraw myDraw(d);
+ myDraw.fMatrix = &SkMatrix::I();
SkXPSDrawProcs procs;
text_draw_init(paint, text, byteLen, *typeface->glyphsUsed, myDraw, procs);
int width, int height,
bool isOpaque,
Usage usage) {
+
+//Conditional for bug compatibility with PDF device.
+#if 0
if (SkBaseDevice::kGeneral_Usage == usage) {
return NULL;
SK_CRASH();
//dev->BeginCanvas(s, s, SkMatrix::I());
//return dev;
}
-
+#endif
return new SkXPSDevice(this->fXpsFactory.get());
}