// Does this device use drawChar() or drawString()?
virtual GBool useDrawChar();
+ // Can this device draw gradients?
+ virtual GBool useGradients();
+
virtual GBool interpretType3Chars() {return gTrue;}
//----- initialization and control
int pbminfo; // did we write "File contains jpegs" yet?
int linkinfo; // did we write "File contains links" yet?
int ttfinfo; // did we write "File contains TrueType Fonts" yet?
+ int gradientinfo; // did we write "File contains Gradients yet?
int type3active; // are we between beginType3()/endType3()?
{
return gTrue;
}
+GBool SWFOutputDev::useGradients()
+{
+ if(!gradientinfo)
+ {
+ msg("<notice> File contains gradients");
+ gradientinfo = 1;
+ }
+ return gTrue;
+}
void SWFOutputDev::beginString(GfxState *state, GString *s)
{
state->transform(x, y, &x1, &y1);
Unicode u=0;
- if(_u)
+ if(_u && uLen)
u = *_u;
-
+
/* find out the character name */
char*name=0;
if(font->isCIDFont() && u) {
if(rot!=0)
msg("<verbose> page is rotated %d degrees\n", rot);
- msg("<notice> processing page %d", pageNum);
-
/* state->transform(state->getX1(),state->getY1(),&x1,&y1);
state->transform(state->getX2(),state->getY2(),&x2,&y2);
Use CropBox, not MediaBox, as page size
if(!outputstarted) {
msg("<verbose> Bounding box is (%f,%f)-(%f,%f)", x1,y1,x2,y2);
- swfoutput_init(&output, swffilename,(int)x1,(int)y1,(int)x2,(int)y2);
+ swfoutput_init(&output, swffilename);
outputstarted = 1;
}
- else
- swfoutput_newpage(&output);
+
+ swfoutput_newpage(&output, pageNum, (int)x1, (int)y1, (int)x2, (int)y2);
}
void SWFOutputDev::drawLink(Link *link, Catalog *catalog)