pdf-mini.h revision 3027d46e220d40848a2a56135aa0cbe2384c2ae4
/** \file
* PDF Mini library.
*/
/*
* Authors:
* Ulf Erikson <ulferikson@users.sf.net>
*
* Minimalistic library to support generation of PDF files.
*
* Copyright (C) 2006 Authors
*
* Released under GNU GPL, read the file 'COPYING' for more information
*/
#ifndef PDF_MINI_H_SEEN
#define PDF_MINI_H_SEEN
enum pdf_resource_type { pdf_none, pdf_extgstate, pdf_colorspace, pdf_pattern, pdf_shading, pdf_xobject, pdf_font, pdf_properties };
"Shading", "XObject", "Font", "Properties" };
~PdfFile();
long tell();
long length;
long stream_pos;
};
long alloc_id() {
entries++;
}
return entries;
}
}
return id;
}
long *table;
long entries;
long size;
};
~PdfObject() {}
long id;
};
}
}
if (res >= 0) {
}
return res;
}
}
char buffer[32];
int i;
os << "xref\n";
for (i = 1; i < size; i++) {
}
}
return length;
}
length = 0;
obj_info = begin_object();
*obj_info << "<<\n";
obj_catalog = begin_object();
obj_root = begin_object();
*obj_root << "<<\n";
*obj_root << " /Type /Catalog\n";
*obj_root << ">>\n";
return obj_info;
}
long startxref;
int i;
*doc_info << ">>\n";
*obj_catalog << "<<\n"
<< " /Type /Pages\n"
<< " /Kids [\n";
}
*obj_catalog << " ]\n"
<< ">>\n";
os << "trailer\n"
<< "<<\n"
<< ">>\n";
os << "startxref\n"
<< startxref << "\n";
os << "%%EOF\n";
}
obj_contents = begin_object();
obj_length = begin_object();
*obj_page << "<<\n"
<< " /Type /Page\n"
<< ">>\n";
*obj_contents << "<<\n"
<< ">>\n"
<< "stream\n";
return obj_contents;
}
*page << "endstream\n";
*obj_resources << "<<\n";
*obj_resources << " /ProcSet [/PDF /Text /ImageB /ImageC /ImageI]\n";
int res;
*obj_resources << " <<\n";
int i;
*obj_resources << " /"
}
*obj_resources << " >>\n";
}
}
*obj_resources << ">>\n";
while (o) {
puts(o);
delete o;
o = t;
}
}
return obj;
}
*object << "endobj\n";
}
}
return obj;
}
}
#endif /* !PDF_MINI_H_SEEN */