metafile-print.h revision 1710c8729db34263e50b443e7fcf541d3cffa005
/** @file
* @brief Metafile printing - common functions
*//*
* Authors:
* Krzysztof KosiĆski <tweenk.pl@gmail.com>
*
* Copyright (C) 2013 Authors
* Released under GNU GPL, read the file 'COPYING' for more information
*/
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include <map>
#include <stack>
#include "extension/implementation/implementation.h"
#include "splivarot.h"
#include "display/canvas-bpath.h"
struct SPGradient;
struct SPObject;
struct FontfixParams {
double f1; //Vertical (rotating) offset factor (* font height)
double f2; //Vertical (nonrotating) offset factor (* font height)
double f3; //Horizontal (nonrotating) offset factor (* font height)
};
{
PrintMetafile() {}
~PrintMetafile();
unsigned int bind(Inkscape::Extension::Print *module, Geom::Affine const &transform, float opacity);
struct GRADVALUES {
double r; // radius or unused
void *grad; // to access the stops information
int mode; // DRAW_LINEAR_GRADIENT or DRAW_RADIAL_GRADIENT, if GRADVALUES is valid, else any value
};
double _width;
double _height;
bool use_stroke;
bool use_fill;
bool simple_shape;
bool usebk;
static bool _load_ppt_fontfix_data();
void brush_classify(SPObject *parent, int depth, GdkPixbuf **epixbuf, int *hatchType, U_COLORREF *hatchColor, U_COLORREF *bkColor);
static Geom::PathVector center_ellipse_as_SVG_PathV(Geom::Point ctr, double rx, double ry, double F);
static Geom::PathVector center_elliptical_ring_as_SVG_PathV(Geom::Point ctr, double rx1, double ry1, double rx2, double ry2, double F);
static Geom::PathVector center_elliptical_hole_as_SVG_PathV(Geom::Point ctr, double rx, double ry, double F);
static Geom::PathVector rect_cutter(Geom::Point ctr, Geom::Point pos, Geom::Point neg, Geom::Point width);
virtual void destroy_brush() = 0;
virtual void destroy_pen() = 0;
static FontfixMap _ppt_fixable_fonts;
static bool _ppt_fontfix_read;
};
} // namespace Internal
} // namespace Extension
} // namespace Inkscape
#endif
/*
Local Variables:
mode:c++
c-file-style:"stroustrup"
c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))
indent-tabs-mode:nil
fill-column:99
End:
*/
// vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:fileencoding=utf-8:textwidth=99 :