69#define PXPERMETER 2835
84 const char *cptr = &
string[strlen(
string) + 1];
88 sscanf(cptr,
"%7d", ndx);
93 ladx = (int16_t *) malloc(*ndx *
sizeof(int16_t));
95 g_error(
"Out of memory");
98 for (i = 0; i < *ndx; i++, cptr += 7, ladx++) {
99 sscanf(cptr,
"%7f", &fdx);
100 *ladx = (int16_t) round(fdx *
scale);
103 sscanf(cptr,
"%7f", &fdx);
106 sscanf(cptr,
"%07d", rtl);
124 gchar
const *utf8_fn = mod->get_param_string(
"destination");
133 (void) wmf_start(utf8_fn, 1000000, 250000, &
wt);
134 (void) wmf_htable_create(128, 128, &
wht);
146 const char *p1 = nv->
attribute(
"pagecolor");
148 uint32_t lc = strtoul(&p1[1], &p2, 16);
153 gv.
rgb[0] = (float) U_RGBAGetR(
gv.
bgc) / 255.0;
154 gv.
rgb[1] = (float) U_RGBAGetG(
gv.
bgc) / 255.0;
155 gv.
rgb[2] = (float) U_RGBAGetB(
gv.
bgc) / 255.0;
158 bool pageBoundingBox;
159 pageBoundingBox = mod->get_param_bool(
"pageBoundingBox");
162 if (pageBoundingBox) {
175 float dwInchesX = d.
width() - 1.0 / 1200.0;
176 float dwInchesY = d.
height() - 1.0 / 1200.0;
177 int dwPxX = round(dwInchesX * 1200.0);
178 int dwPxY = round(dwInchesY * 1200.0);
180 float dwInchesX = d.
width();
181 float dwInchesY = d.
height();
182 int dwPxX = round(d.
width() * 1200.0);
183 int dwPxY = round(d.
height() * 1200.0);
186 U_PAIRF *ps = U_PAIRF_set(dwInchesX, dwInchesY);
187 rec = U_WMRHEADER_set(ps, 1200);
190 g_warning(
"Failed in PrintWmf::begin at WMRHEADER");
195 rec = U_WMRSETWINDOWEXT_set(point16_set(dwPxX, dwPxY));
197 g_warning(
"Failed in PrintWmf::begin at WMRSETWINDOWEXT");
201 rec = U_WMRSETWINDOWORG_set(point16_set(0, 0));
203 g_warning(
"Failed in PrintWmf::begin at WMRSETWINDOWORG");
207 rec = U_WMRSETMAPMODE_set(U_MM_ANISOTROPIC);
209 g_warning(
"Failed in PrintWmf::begin at WMRSETMAPMODE");
215 rec = U_WMRSETBKMODE_set(U_TRANSPARENT);
217 g_warning(
"Failed in PrintWmf::begin at U_WMRSETBKMODE");
222 rec = U_WMRSETPOLYFILLMODE_set(U_WINDING);
224 g_warning(
"Failed in PrintWmf::begin at U_WMRSETPOLYFILLMODE");
232 rec = U_WMRSETTEXTALIGN_set(U_TA_BASELINE | U_TA_LEFT);
234 g_warning(
"Failed in PrintWmf::begin at U_WMRSETTEXTALIGN_set");
239 rec = U_WMRSETTEXTCOLOR_set(U_RGB(0, 0, 0));
241 g_warning(
"Failed in PrintWmf::begin at U_WMRSETTEXTCOLOR_set");
245 rec = U_WMRSETROP2_set(U_R2_COPYPEN);
247 g_warning(
"Failed in PrintWmf::begin at U_WMRSETROP2");
252 rec = wmiterlimit_set(5);
254 g_warning(
"Failed in PrintWmf::begin at wmiterlimit_set");
260 U_PEN up = U_PEN_set(U_PS_SOLID, 1, colorref_set(0, 0, 0));
262 rec = wcreatepenindirect_set(&Pen,
wht, up);
264 g_warning(
"Failed in PrintWmf::begin at wcreatepenindirect_set");
269 up = U_PEN_set(U_PS_NULL, 1, colorref_set(0, 0, 0));
272 g_warning(
"Failed in PrintWmf::begin at wcreatepenindirect_set");
278 U_WLOGBRUSH lb = U_WLOGBRUSH_set(U_BS_NULL, U_RGB(0, 0, 0), U_HS_HORIZONTAL);
281 g_warning(
"Failed in PrintWmf::begin at wcreatebrushindirect_set");
300 g_error(
"Fatal programming error in PrintWmf::finish at wdeleteobject_set null brush");
306 g_error(
"Fatal programming error in PrintWmf::finish at wdeleteobject_set null pen");
311 rec = wdeleteobject_set(&
hpen,
wht);
313 g_error(
"Fatal programming error in PrintWmf::finish at wdeleteobject_set filler object");
316 rec = U_WMREOF_set();
318 g_error(
"Fatal programming error in PrintWmf::finish");
320 (void) wmf_finish(
wt);
322 wmf_htable_free(&
wht);
332 uint32_t brush, fmode;
349 brushStyle = U_BS_SOLID;
350 hatchType = U_HS_SOLIDCLR;
351 bkColor = U_RGB(0, 0, 0);
353 hatchColor = *fcolor;
355 hatchColor = U_RGB(0, 0, 0);
358 if (!fcolor && style) {
359 if (style->
fill.isColor()) {
369 fmode = style->
fill_rule.computed == 0 ? U_WINDING : (style->
fill_rule.computed == 2 ? U_ALTERNATE : U_ALTERNATE);
370 }
else if (is<SPPattern>(SP_STYLE_FILL_SERVER(style))) {
372 auto pat = cast<SPPattern>(paintserver);
373 double dwidth = pat->width();
374 double dheight = pat->height();
377 brush_classify(pat, 0, &pixbuf, &hatchType, &hatchColor, &bkColor);
382 if (hatchType == -1) {
383 hatchType = U_HS_CROSS;
384 hatchColor = U_RGB(0xFF, 0xC3, 0xC3);
388 if (hatchType == -1) {
390 hatchType = U_HS_DIAGCROSS;
391 hatchColor = U_RGB(0xFF, 0xC3, 0xC3);
394 brushStyle = U_BS_HATCHED;
395 }
else if (is<SPGradient>(SP_STYLE_FILL_SERVER(style))) {
401 if (is<SPLinearGradient>(paintserver)) {
402 lg = cast<SPLinearGradient>(paintserver);
405 }
else if (is<SPRadialGradient>(paintserver)) {
406 rg = cast<SPRadialGradient>(paintserver);
438 rec = U_WMRSETBKCOLOR_set(bkColor);
440 g_error(
"Fatal programming error in PrintWmf::create_brush at U_WMRSETBKCOLOR_set");
442 rec = U_WMRSETBKMODE_set(U_OPAQUE);
444 g_error(
"Fatal programming error in PrintWmf::create_brush at U_WMRSETBKMODE_set");
447 lb = U_WLOGBRUSH_set(brushStyle, hatchColor, hatchType);
448 rec = wcreatebrushindirect_set(&brush,
wht, lb);
450 g_error(
"Fatal programming error in PrintWmf::create_brush at createbrushindirect_set");
462 rgba_px = (
char const*)pixbuf->
pixels();
463 colortype = U_BCBM_COLOR32;
464 (void) RGBA_to_DIB(&px, &cbPx, &ct, &numCt, rgba_px,
width,
height,
width * 4, colortype, 0, 1);
467 Bmih = bitmapinfoheader_set(
width,
height, 1, colortype, U_BI_RGB, 0, PXPERMETER, PXPERMETER, numCt, 0);
468 Bmi = bitmapinfo_set(Bmih, ct);
469 rec = wcreatedibpatternbrush_srcdib_set(&brush,
wht, U_DIB_RGB_COLORS, Bmi, cbPx, px);
471 g_error(
"Fatal programming error in PrintWmf::create_brush at createdibpatternbrushpt_set");
479 rec = wselectobject_set(brush,
wht);
481 g_error(
"Fatal programming error in PrintWmf::create_brush at wselectobject_set");
486 rec = U_WMRSETPOLYFILLMODE_set(fmode);
488 g_error(
"Fatal programming error in PrintWmf::create_brush at U_WMRSETPOLYFILLMODE_set");
503 g_error(
"Fatal programming error in PrintWmf::destroy_brush");
512 g_error(
"Fatal programming error in PrintWmf::destroy_brush");
531 penstyle = U_PS_SOLID;
533 penColor = U_RGB(0, 0, 0);
534 uint32_t linewidth = 1;
550 double scale = sqrt((p[X] * p[X]) + (p[Y] * p[Y])) / sqrt(2);
560 modstyle |= U_PS_ENDCAP_FLAT;
562 modstyle |= U_PS_ENDCAP_ROUND;
564 modstyle |= U_PS_ENDCAP_SQUARE;
569 if (miterlimit < 1) {
576 rec = wmiterlimit_set((uint32_t) miterlimit);
578 g_error(
"Fatal programming error in PrintWmf::create_pen at wmiterlimit_set");
581 modstyle |= U_PS_JOIN_MITER;
583 modstyle |= U_PS_JOIN_ROUND;
585 modstyle |= U_PS_JOIN_BEVEL;
592 int mark_short=INT_MAX;
595 for (i=0;i<n_dash;i++) {
597 if (mark > mark_long) {
600 if (mark < mark_short) {
604 if(mark_long == mark_short){
607 else if (n_dash==2) {
608 penstyle = U_PS_DASH;
610 else if (n_dash==4) {
611 penstyle = U_PS_DASHDOT;
614 penstyle = U_PS_DASHDOTDOT;
621 up = U_PEN_set(penstyle | modstyle, linewidth, penColor);
622 rec = wcreatepenindirect_set(&pen,
wht, up);
624 g_error(
"Fatal programming error in PrintWmf::create_pen at wcreatepenindirect_set");
627 rec = wselectobject_set(pen,
wht);
629 g_error(
"Fatal programming error in PrintWmf::create_pen at wselectobject_set");
642 rec = wdeleteobject_set(&
hpen,
wht);
644 g_error(
"Fatal programming error in PrintWmf::destroy_pen");
653 g_error(
"Fatal programming error in PrintWmf::destroy_pen");
686 double doff, doff_base, doff_range;
687 double divisions = 128.0;
704 double rx = hypot(xv[X], xv[Y]);
705 double ry = hypot(yv[X], yv[Y]);
706 double range = fmax(rx, ry);
707 double step = range / divisions;
708 double overlap = step / 4.0;
724 for (
start = 0.0;
start < range;
start += step, doff += 1. / divisions) {
725 stop =
start + step + overlap;
729 wc =
weight_colors(c1, c2, (doff - doff_base) / (doff_range - doff_base));
737 if (doff >= doff_range - doff_base) {
739 if (istop >= nstops) {
742 doff_base = doff_range;
752 double step = range / divisions;
753 double overlap = step / 4.0;
761 pathvc =
rect_cutter(
gv.
p1, uv * (overlap), uv * (-50000.0), puv * 50000.0);
768 pathvc =
rect_cutter(
gv.
p2, uv * (-overlap), uv * (50000.0), puv * 50000.0);
774 for (
start = 0.0;
start < range;
start += step, doff += 1. / divisions) {
775 stop =
start + step + overlap;
781 wc =
weight_colors(c1, c2, (doff - doff_base) / (doff_range - doff_base));
786 if (doff >= doff_range - doff_base) {
788 if (istop >= nstops) {
791 doff_base = doff_range;
798 g_error(
"Fatal programming error in PrintWmf::fill, invalid gradient type detected");
816 bool all_closed =
true;
817 for (
const auto & pit : pathv) {
819 if (pit.end_default() != pit.end_closed()) {
863 double slength = 0.0;
865 for (
const auto & i : pathv) {
866 tmp_pathpw.
concat(i.toPwSb());
868 tlength = length(tmp_pathpw, 0.1);
869 tmp_pathpw2 = arc_length_parametrization(tmp_pathpw);
872 while (slength < tlength) {
874 if (elength > tlength) {
889 tmp_pathpw3.
concat(first_frag);
901 rec = U_WMRSETBKMODE_set(U_TRANSPARENT);
903 g_error(
"Fatal programming error in PrintWmf::stroke at U_WMRSETBKMODE_set");
925 for (
const auto & pit : pv) {
949 for (
const auto & pit : pv) {
958 int32_t
const x0 = (int32_t) round(p0[X]);
959 int32_t
const y0 = (int32_t) round(p0[Y]);
979 int32_t
const x1 = (int32_t) round(p1[X]);
980 int32_t
const y1 = (int32_t) round(p1[Y]);
986 std::vector<Geom::Point> points = cubic->controlPoints();
1003 int32_t
const x1 = (int32_t) round(p1[X]);
1004 int32_t
const y1 = (int32_t) round(p1[Y]);
1005 int32_t
const x2 = (int32_t) round(p2[X]);
1006 int32_t
const y2 = (int32_t) round(p2[Y]);
1007 int32_t
const x3 = (int32_t) round(p3[X]);
1008 int32_t
const y3 = (int32_t) round(p3[Y]);
1012 lpPoints[i + 1].
x = x2;
1013 lpPoints[i + 1].
y = y2;
1014 lpPoints[i + 2].
x = x3;
1015 lpPoints[i + 2].
y = y3;
1022 bool closed = (lpPoints[0].
x == lpPoints[i - 1].
x) && (lpPoints[0].y == lpPoints[i - 1].y);
1023 bool polygon =
false;
1024 bool rectangle =
false;
1025 bool ellipse =
false;
1027 if (moves == 1 && moves + lines == nodes && closed) {
1036 }
else if (moves == 1 && nodes == 5 && moves + curves == nodes && closed) {
1048 if (polygon || ellipse) {
1054 lpPoints[0].
x, lpPoints[0].
y
1056 lpPoints[2].
x, lpPoints[2].
y
1058 rec = U_WMRRECTANGLE_set(rcl);
1060 rec = U_WMRPOLYGON_set(nodes, lpPoints);
1062 }
else if (ellipse) {
1064 lpPoints[6].
x, lpPoints[3].
y
1066 lpPoints[0].
x, lpPoints[9].
y
1068 rec = U_WMRELLIPSE_set(rcl);
1071 g_error(
"Fatal programming error in PrintWmf::print_simple_shape at retangle/ellipse/polygon");
1101 unsigned char *rgba_px,
1108 double x1, y1, dw, dh;
1109 char *rec =
nullptr;
1112 rec = U_WMRSETSTRETCHBLTMODE_set(U_COLORONCOLOR);
1114 g_error(
"Fatal programming error in PrintWmf::image at EMRHEADER");
1119 dw = ((double)
w) * tf_rect[0];
1120 dh = ((double) h) * tf_rect[3];
1138 colortype = U_BCBM_COLOR32;
1139 (void) RGBA_to_DIB(&px, &cbPx, &ct, &numCt, (
char *) rgba_px,
w, h,
w * 4, colortype, 0, 1);
1140 Bmih = bitmapinfoheader_set(
w, h, 1, colortype, U_BI_RGB, 0, PXPERMETER, PXPERMETER, numCt, 0);
1141 Bmi = bitmapinfo_set(Bmih, ct);
1147 rec = U_WMRSTRETCHDIB_set(
1159 g_error(
"Fatal programming error in PrintWmf::image at U_WMRSTRETCHDIB_set");
1172 char *rec =
nullptr;
1196 for (
const auto & pit : pv) {
1197 totPoints += 1 + pit.size_default();
1198 if (pit.end_default() == pit.end_closed()) {
1212 n16hold = n16ptr = (uint16_t *) malloc(nPolys *
sizeof(uint16_t));
1218 for (
const auto & pit : pv) {
1223 *n16ptr++ = pit.size_default();
1231 *pt16ptr++ = point16_set((int32_t) round(p1[X]), (int32_t) round(p1[Y]));
1238 *pt16ptr++ = point16_set((int32_t) round(p1[X]), (int32_t) round(p1[Y]));
1242 rec = U_WMRPOLYPOLYGON_set(nPolys, n16hold, pt16hold);
1244 g_error(
"Fatal programming error in PrintWmf::print_pathv at U_WMRPOLYPOLYGON_set");
1249 for (
const auto & pit : pv) {
1255 if (!(pit.size_default())) {
1262 int nPoints = 1 + pit.size_default();
1275 *pt16ptr++ = point16_set((int32_t) round(p1[X]), (int32_t) round(p1[Y]));
1283 *pt16ptr++ = point16_set((int32_t) round(p1[X]), (int32_t) round(p1[Y]));
1286 if (pit.end_default() == pit.end_closed()) {
1287 rec = U_WMRPOLYGON_set(nPoints, pt16hold);
1289 g_error(
"Fatal programming error in PrintWmf::print_pathv at U_WMRPOLYGON_set");
1291 }
else if (nPoints > 2) {
1292 rec = U_WMRPOLYLINE_set(nPoints, pt16hold);
1294 g_error(
"Fatal programming error in PrintWmf::print_pathv at U_POLYLINE_set");
1296 }
else if (nPoints == 2) {
1297 rec = U_WMRMOVETO_set(pt16hold[0]);
1299 g_error(
"Fatal programming error in PrintWmf::print_pathv at U_WMRMOVETO_set");
1301 rec = U_WMRLINETO_set(pt16hold[1]);
1303 g_error(
"Fatal programming error in PrintWmf::print_pathv at U_WMRLINETO_set");
1332 char *rec =
nullptr;
1333 int ccount, newfont;
1337 double rot = -1800.0 * std::atan2(tf[1], tf[0]) / M_PI;
1338 double rotb = -std::atan2(tf[1], tf[0]);
1348 uint32_t textalignment;
1350 textalignment = U_TA_BASELINE | U_TA_LEFT;
1352 textalignment = U_TA_BASELINE | U_TA_RIGHT | U_TA_RTLREADING;
1356 rec = U_WMRSETTEXTALIGN_set(textalignment);
1358 g_error(
"Fatal programming error in PrintWmf::text at U_WMRSETTEXTALIGN_set");
1362 char *text2 = strdup(
text);
1374 if(!latin1_text){free(adx);
return 0; }
1397 if (params.
f2 != 0 || params.
f3 != 0) {
1398 int irem = ((int) round(rot)) % 900 ;
1399 if (irem <= 9 && irem >= -9) {
1401 rot = (double)(((
int) round(rot)) - irem);
1402 rotb = rot * M_PI / 1800.0;
1403 if (std::abs(rot) == 900.0) {
1432 U_FONT *puf = U_FONT_set(
1442 U_OUT_DEFAULT_PRECIS,
1443 U_CLIP_DEFAULT_PRECIS,
1445 U_DEFAULT_PITCH | U_FF_DONTCARE,
1449 rec = wcreatefontindirect_set(&hfont,
wht, puf);
1451 g_error(
"Fatal programming error in PrintWmf::text at wcreatefontindirect_set");
1456 rec = wselectobject_set(hfont,
wht);
1458 g_error(
"Fatal programming error in PrintWmf::text at wselectobject_set");
1461 auto rgb = style->
fill.getColor();
1467 g_error(
"Fatal programming error in PrintWmf::text at U_WMRSETTEXTCOLOR_set");
1487 p2[
Geom::X] += ky * std::sin(rotb);
1488 p2[
Geom::Y] += ky * std::cos(rotb);
1494 dy = params.
f3 * style->
font_size.computed * std::cos(rotb);
1495 }
else if (fix90n == 2) {
1496 dx = params.
f2 * style->
font_size.computed * std::sin(rotb);
1499 dx = params.
f1 * style->
font_size.computed * std::sin(rotb);
1500 dy = params.
f1 * style->
font_size.computed * std::cos(rotb);
1509 int32_t
const xpos = (int32_t) round(p2[
Geom::X]);
1510 int32_t
const ypos = (int32_t) round(p2[
Geom::Y]);
1522 (int16_t) xpos, (int16_t) ypos
1524 ndx, U_ETO_NONE, latin1_text, adx, U_RCL16_DEF);
1527 (int16_t) xpos, (int16_t) ypos
1529 ndx, U_ETO_RTLREADING, latin1_text, adx, U_RCL16_DEF);
1534 g_error(
"Fatal programming error in PrintWmf::text at U_WMREXTTEXTOUTW_set");
1537 rec = wdeleteobject_set(&hfont,
wht);
1539 g_error(
"Fatal programming error in PrintWmf::text at wdeleteobject_set");
1550 "<inkscape-extension xmlns=\"" INKSCAPE_EXTENSION_URI
"\">\n"
1551 "<name>Windows Metafile Print</name>\n"
1552 "<id>org.inkscape.print.wmf</id>\n"
1553 "<param gui-hidden=\"true\" name=\"destination\" type=\"string\"></param>\n"
1554 "<param gui-hidden=\"true\" name=\"textToPath\" type=\"bool\">true</param>\n"
1555 "<param gui-hidden=\"true\" name=\"pageBoundingBox\" type=\"bool\">true</param>\n"
1556 "<param gui-hidden=\"true\" name=\"FixPPTCharPos\" type=\"bool\">false</param>\n"
1557 "<param gui-hidden=\"true\" name=\"FixPPTDashLine\" type=\"bool\">false</param>\n"
1558 "<param gui-hidden=\"true\" name=\"FixPPTGrad2Polys\" type=\"bool\">false</param>\n"
1559 "<param gui-hidden=\"true\" name=\"FixPPTPatternAsHatch\" type=\"bool\">false</param>\n"
1561 "</inkscape-extension>", std::make_unique<PrintWmf>());
Path - a sequence of contiguous curves.
Cairo integration helpers.
3x3 matrix representing an affine transformation.
Coord expansionX() const
Calculates the amount of x-scaling imparted by the Affine.
Affine withoutTranslation() const
Coord expansionY() const
Calculates the amount of y-scaling imparted by the Affine.
Bezier curve with compile-time specified order.
C height() const
Get the vertical extent of the rectangle.
C width() const
Get the horizontal extent of the rectangle.
Axis-aligned rectangle that can be empty.
bool empty() const
Check whether the vector contains any paths.
Sequence of contiguous curves, aka spline.
Function defined as discrete pieces.
void concat(const Piecewise< T > &other)
Two-dimensional point that doubles as a vector.
constexpr Point cw() const
Return a point like this point but rotated +90 degrees.
Axis aligned, non-empty rectangle.
unsigned int finish(Inkscape::Extension::Print *module) override
unsigned int print_pathv(Geom::PathVector const &pathv, const Geom::Affine &transform)
bool print_simple_shape(Geom::PathVector const &pathv, const Geom::Affine &transform)
int create_brush(SPStyle const *style, PU_COLORREF fcolor) override
unsigned int setup(Inkscape::Extension::Print *module) override
int create_pen(SPStyle const *style, const Geom::Affine &transform) override
unsigned int stroke(Inkscape::Extension::Print *module, Geom::PathVector const &pathv, Geom::Affine const &ctm, SPStyle const *style, Geom::OptRect const &pbox, Geom::OptRect const &dbox, Geom::OptRect const &bbox) override
unsigned int begin(Inkscape::Extension::Print *module, SPDocument *doc) override
unsigned int text(Inkscape::Extension::Print *module, char const *text, Geom::Point const &p, SPStyle const *style) override
unsigned int image(Inkscape::Extension::Print *module, unsigned char *px, unsigned int w, unsigned int h, unsigned int rs, Geom::Affine const &transform, SPStyle const *style) override
Some parts based on win32.cpp by Lauris Kaplinski lauris@kaplinski.com.
void destroy_pen() override
static void smuggle_adxky_out(const char *string, int16_t **adx, double *ky, int *rtl, int *ndx, float scale)
void destroy_brush() override
unsigned int fill(Inkscape::Extension::Print *module, Geom::PathVector const &pathv, Geom::Affine const &ctm, SPStyle const *style, Geom::OptRect const &pbox, Geom::OptRect const &dbox, Geom::OptRect const &bbox) override
Class to hold image data for raster images.
guchar const * pixels() const
PixelFormat pixelFormat() const
static double convert(double from_dist, Unit const *from, Unit const *to)
Convert distances.
Interface for refcounted XML nodes.
virtual char const * attribute(char const *key) const =0
Get the string representation of a node's attribute.
Typed SVG document implementation.
SPRoot * getRoot()
Returns our SPRoot.
Geom::OptRect preferredBounds() const
Inkscape::XML::Node * getReprNamedView()
SPGradientVector vector
Linear and Radial Gradients.
void ensureVector()
Forces vector to be built, if not present (i.e.
Base class for visual SVG elements.
Geom::OptRect desktopVisualBounds() const
Get item's visual bbox in desktop coordinate system.
T< SPAttr::TEXT_DECORATION_LINE, SPITextDecorationLine > text_decoration_line
CSS 3 2.1, 2.2, 2.3.
T< SPAttr::FONT_WEIGHT, SPIEnum< SPCSSFontWeight > > font_weight
Weight of the font.
T< SPAttr::FILL, SPIPaint > fill
fill
T< SPAttr::STROKE_DASHARRAY, SPIDashArray > stroke_dasharray
stroke-dasharray
T< SPAttr::STROKE, SPIPaint > stroke
stroke
T< SPAttr::FONT_FAMILY, SPIString > font_family
Font family.
T< SPAttr::STROKE_WIDTH, SPILength > stroke_width
stroke-width
T< SPAttr::FILL_RULE, SPIEnum< SPWindRule > > fill_rule
fill-rule: 0 nonzero, 1 evenodd
T< SPAttr::FONT_STYLE, SPIEnum< SPCSSFontStyle > > font_style
Font style.
T< SPAttr::STROKE_LINEJOIN, SPIEnum< SPStrokeJoinType > > stroke_linejoin
stroke-linejoin
T< SPAttr::STROKE_MITERLIMIT, SPIFloat > stroke_miterlimit
stroke-miterlimit
T< SPAttr::STROKE_LINECAP, SPIEnum< SPStrokeCapType > > stroke_linecap
stroke-linecap
T< SPAttr::FONT_SIZE, SPIFontSize > font_size
Size of the font.
vector< vpsc::Rectangle * > rs
Specific curve type functions for Inkscape, not provided by lib2geom.
bool is_straight_curve(Geom::BezierCurve const &c)
Geom::PathVector pathv_to_linear(Geom::PathVector const &pathv, double)
Specific geometry functions for Inkscape, not provided my lib2geom.
Mini static library that contains the version of Inkscape.
Angle distance(Angle const &a, Angle const &b)
PathVector path_from_piecewise(Piecewise< D2< SBasis > > const &B, double tol, bool only_cubicbeziers=false)
Make a path from a d2 sbasis.
Point unit_vector(Point const &a)
static bool FixPPTDashLine
static bool FixPPTCharPos
static bool FixPPTGrad2Polys
static bool FixPPTPatternAsHatch
U_COLORREF toColorRef(std::optional< Colors::Color > color)
void build_from_mem(gchar const *buffer, std::unique_ptr< Implementation::Implementation > in_imp)
Create a module from a buffer holding an XML description.
Helper class to stream background task notifications as a series of messages.
Geom::PathVector sp_pathvector_boolop(Geom::PathVector const &pathva, Geom::PathVector const &pathvb, BooleanOp bop, FillRule fra, FillRule frb)
Perform a boolean operation on two pathvectors.
TODO: insert short description here.
PathVector - a sequence of subpaths.
Conversion between SBasis and Bezier basis polynomials.
SVG <image> implementation.
Some things pertinent to all visible shapes: SPItem, SPItemView, SPItemCtx.
TODO: insert short description here.
SVG <pattern> implementation.
TODO: insert short description here.
SPRoot: SVG <svg> implementation.
std::vector< SPGradientStop > stops
For U_EMR_* OffBmi* fields.
Font Object WMF manual 2.2.1.2 Warning, only pass by pointer, passing by value will will truncate in ...
Any generic pair of floats.
Pen Object WMF manual 2.2.1.4.
Rect Object WMF manual 2.2.2.18.
BitmapInfoHeader Object WMF manual 2.2.2.3 Same as "EMF BITMAPINFOHEADER Object" in uemf....
The various create functions need a place to put their handles, these are stored in the table below.
Storage for keeping track of properties of the growing WMF file as records are added.
@ SP_CSS_FONT_STYLE_ITALIC
parse SVG path specifications
Enhanced Metafile Input/Output.
void UnicodeToNon(uint16_t *text, int *ecount, int *edest)
char * FontName(int code)
char * U_Utf8ToLatin1(const char *src, size_t max, size_t *len)
uint16_t * U_Utf8ToUtf16le(const char *src, size_t max, size_t *len)
char * U_Utf16leToLatin1(const uint16_t *src, size_t max, size_t *len)
Windows Metafile printing - implementation.