X-Git-Url: http://git.asbjorn.biz/?p=swftools.git;a=blobdiff_plain;f=pdf2swf%2Fxpdf%2FOutputDev.h;h=cb825e0076e74073bcc318cc54b6136160b4bea9;hp=d7de97abdf02fb104a535ec5ff129b2901ad56a6;hb=50dd339d3d6262763616efe8d7ee415ab19befb9;hpb=33b4efceb35f7582426665aba920fd950edc0602 diff --git a/pdf2swf/xpdf/OutputDev.h b/pdf2swf/xpdf/OutputDev.h index d7de97a..cb825e0 100644 --- a/pdf2swf/xpdf/OutputDev.h +++ b/pdf2swf/xpdf/OutputDev.h @@ -2,7 +2,7 @@ // // OutputDev.h // -// Copyright 1996 Derek B. Noonburg +// Copyright 1996-2002 Glyph & Cog, LLC // //======================================================================== @@ -14,6 +14,7 @@ #endif #include "gtypes.h" +#include "CharTypes.h" class GString; class GfxState; @@ -45,10 +46,17 @@ public: // Does this device use drawChar() or drawString()? virtual GBool useDrawChar() = 0; + // Does this device use beginType3Char/endType3Char? Otherwise, + // text in Type 3 fonts will be drawn with drawChar/drawString. + virtual GBool interpretType3Chars() = 0; + + // Does this device need non-text content? + virtual GBool needNonText() { return gTrue; } + //----- initialization and control // Set default transform matrix. - virtual void setDefaultCTM(double *ctm1); + virtual void setDefaultCTM(double *ctm); // Start a page. virtual void startPage(int pageNum, GfxState *state) {} @@ -111,11 +119,13 @@ public: virtual void beginString(GfxState *state, GString *s) {} virtual void endString(GfxState *state) {} virtual void drawChar(GfxState *state, double x, double y, - double dx, double dy, Guchar c) {} - virtual void drawChar16(GfxState *state, double x, double y, - double dx, double dy, int c) {} + double dx, double dy, + double originX, double originY, + CharCode code, Unicode *u, int uLen) {} virtual void drawString(GfxState *state, GString *s) {} - virtual void drawString16(GfxState *state, GString *s) {} + virtual GBool beginType3Char(GfxState *state, + CharCode code, Unicode *u, int uLen); + virtual void endType3Char(GfxState *state) {} //----- image drawing virtual void drawImageMask(GfxState *state, Object *ref, Stream *str, @@ -123,7 +133,7 @@ public: GBool inlineImg); virtual void drawImage(GfxState *state, Object *ref, Stream *str, int width, int height, GfxImageColorMap *colorMap, - GBool inlineImg); + int *maskColors, GBool inlineImg); #if OPI_SUPPORT //----- OPI functions @@ -131,10 +141,18 @@ public: virtual void opiEnd(GfxState *state, Dict *opiDict); #endif + //----- Type 3 font operators + virtual void type3D0(GfxState *state, double wx, double wy) {} + virtual void type3D1(GfxState *state, double wx, double wy, + double llx, double lly, double urx, double ury) {} + + //----- PostScript XObjects + virtual void psXObject(Stream *psStream, Stream *level1Stream) {} + private: - double ctm[6]; // coordinate transform matrix - double ictm[6]; // inverse CTM + double defCTM[6]; // default coordinate transform matrix + double defICTM[6]; // inverse of default CTM }; #endif