index 816d7bfc7f6e0166baa831161bf1ee95bd9e8c69..c309add15aaf1183c5a23ff125b782d7efba8c63 100644 (file)
# include "config.h"
#endif
+#ifdef HAVE_CAIRO_PDF
+
#include "extension/extension.h"
#include "extension/implementation/implementation.h"
#include <set>
#include <string>
-#include "libnr/nr-path.h"
#include "libnrtype/font-instance.h"
#include "svg/stringstream.h"
@@ -42,14 +43,12 @@ class PrintCairoPDF : public Inkscape::Extension::Implementation::Implementation
cairo_surface_t *pdf_surface;
PangoLayout *_layout;
// PangoContext *_context;
- float *_alpha_stack;
- int _num_alphas, _alpha_ptr;
+ std::vector<float> _alpha_stack;
double _last_tx, _last_ty;
unsigned short _dpi;
bool _bitmap;
- void print_bpath(cairo_t *cr, NArtBpath const *bp);
cairo_pattern_t *create_pattern_for_paint(SPPaintServer const *const paintserver, NRRect const *pbox, float alpha);
void print_fill_style(cairo_t *cr, SPStyle const *const style, NRRect const *pbox);
virtual unsigned int finish(Inkscape::Extension::Print *module);
/* Rendering methods */
- virtual unsigned int bind(Inkscape::Extension::Print *module, NRMatrix const *transform, float opacity);
+ virtual unsigned int bind(Inkscape::Extension::Print *module, NR::Matrix const *transform, float opacity);
virtual unsigned int release(Inkscape::Extension::Print *module);
virtual unsigned int comment(Inkscape::Extension::Print *module, char const *comment);
- virtual unsigned int fill(Inkscape::Extension::Print *module, NRBPath const *bpath, NRMatrix const *ctm, SPStyle const *style,
+ virtual unsigned int fill(Inkscape::Extension::Print *module, Geom::PathVector const &pathv, NR::Matrix const *ctm, SPStyle const *style,
NRRect const *pbox, NRRect const *dbox, NRRect const *bbox);
- virtual unsigned int stroke(Inkscape::Extension::Print *module, NRBPath const *bpath, NRMatrix const *transform, SPStyle const *style,
+ virtual unsigned int stroke(Inkscape::Extension::Print *module, Geom::PathVector const &pathv, NR::Matrix const *transform, SPStyle const *style,
NRRect const *pbox, NRRect const *dbox, NRRect const *bbox);
virtual unsigned int image(Inkscape::Extension::Print *module, unsigned char *px, unsigned int w, unsigned int h, unsigned int rs,
- NRMatrix const *transform, SPStyle const *style);
+ NR::Matrix const *transform, SPStyle const *style);
virtual unsigned int text(Inkscape::Extension::Print *module, char const *text,
NR::Point p, SPStyle const *style);
} /* namespace Extension */
} /* namespace Inkscape */
+#endif /* HAVE_CAIRO_PDF */
#endif /* !EXTENSION_INTERNAL_PDF_CAIRO_H_SEEN */