53#define U_PS_JOIN_MASK (U_PS_JOIN_BEVEL|U_PS_JOIN_MITER|U_PS_JOIN_ROUND)
71 const gchar *oldconst;
77 oldconst = mod->get_param_string(
"destination");
78 oldoutput = g_strdup(oldconst);
79 mod->set_param_string(
"destination", filename);
88 mod->root = mod->base->invoke_show(drawing, mod->dkey, SP_ITEM_SHOW_DISPLAY);
91 if (mod->begin(doc)) {
93 mod->base->invoke_hide(mod->dkey);
98 mod->base->invoke_print(&context);
101 mod->base->invoke_hide(mod->dkey);
106 mod->set_param_string(
"destination", oldoutput);
122 bool new_val = mod->get_param_bool(
"textToPath");
123 bool new_FixPPTCharPos = mod->get_param_bool(
"FixPPTCharPos");
125 bool new_FixPPTDashLine = mod->get_param_bool(
"FixPPTDashLine");
126 bool new_FixPPTGrad2Polys = mod->get_param_bool(
"FixPPTGrad2Polys");
127 bool new_FixPPTPatternAsHatch = mod->get_param_bool(
"FixPPTPatternAsHatch");
130 mod->get_param_bool(
"TnrToSymbol"),
131 mod->get_param_bool(
"TnrToWingdings"),
132 mod->get_param_bool(
"TnrToZapfDingbats"),
133 mod->get_param_bool(
"UsePUA")
139 ext->
set_param_bool(
"FixPPTPatternAsHatch",new_FixPPTPatternAsHatch);
143 char *oldlocale = g_strdup(setlocale(LC_NUMERIC,
nullptr));
144 setlocale(LC_NUMERIC,
"C");
149 setlocale(LC_NUMERIC, oldlocale);
165 cxform <<
"\"matrix(";
166 cxform << 1.0/
scale; cxform <<
",";
167 cxform << 0.0; cxform <<
",";
168 cxform << 0.0; cxform <<
",";
169 cxform << 1.0/
scale; cxform <<
",";
170 if(useoffset){ cxform << x; cxform <<
","; cxform << y; }
171 else { cxform <<
"0,0"; }
173 return(cxform.
str());
201 TagEmitter(Glib::ustring & p_defs,
char * p_tmpcolor,
char * p_hpathname):
202 defs(p_defs), tmpcolor(p_tmpcolor), hpathname(p_hpathname)
205 void append(
const char *prefix,
const char *
inner)
216 Glib::ustring & defs;
217 char * tmpcolor, * hpathname;
233 case U_HS_SOLIDTEXTCLR:
234 case U_HS_DITHEREDTEXTCLR:
237 case U_HS_SOLIDBKCLR:
238 case U_HS_DITHEREDBKCLR:
242 safeprintf(tmpcolor,
"%6.6X",
sethexcolor(hatchColor));
245 auto & defs = d->
defs;
246 TagEmitter a(defs, tmpcolor, hpathname);
252 safeprintf(hpathname,
"WMFhpath%d_%s",hatchType,tmpcolor);
260 case U_HS_HORIZONTAL:
261 a.append(
"<path id=\"",
262 "\" d=\"M 0 0 6 0\" style=\"fill:none;stroke:#");
265 a.append(
"<path id=\"",
266 "\" d=\"M 0 0 0 6\" style=\"fill:none;stroke:#");
269 a.append(
"<line id=\"sub",
270 "\" x1=\"-1\" y1=\"-1\" x2=\"7\" y2=\"7\" stroke=\"#");
273 a.append(
"<line id=\"sub",
274 "\" x1=\"-1\" y1=\"7\" x2=\"7\" y2=\"-1\" stroke=\"#");
277 a.append(
"<path id=\"",
278 "\" d=\"M 0 0 6 0 M 0 0 0 6\" style=\"fill:none;stroke:#");
281 a.append(
"<line id=\"subfd",
282 "\" x1=\"-1\" y1=\"-1\" x2=\"7\" y2=\"7\" stroke=\"#");
283 a.append(
"<line id=\"subbd",
284 "\" x1=\"-1\" y1=\"7\" x2=\"7\" y2=\"-1\" stroke=\"#");
287 case U_HS_DITHEREDCLR:
288 case U_HS_SOLIDTEXTCLR:
289 case U_HS_DITHEREDTEXTCLR:
290 case U_HS_SOLIDBKCLR:
291 case U_HS_DITHEREDBKCLR:
293 a.append(
"<path id=\"",
294 "\" d=\"M 0 0 6 0 6 6 0 6 z\" style=\"stroke:none;fill:#");
301 case U_HS_HORIZONTAL:
305 case U_HS_DITHEREDCLR:
306 case U_HS_SOLIDTEXTCLR:
307 case U_HS_DITHEREDTEXTCLR:
308 case U_HS_SOLIDBKCLR:
309 case U_HS_DITHEREDBKCLR:
311 refpath +=
" <use xlink:href=\"#";
312 refpath += hpathname;
313 refpath +=
"\" />\n";
317 refpath +=
" <use xlink:href=\"#sub";
318 refpath += hpathname;
319 refpath +=
"\" />\n";
320 refpath +=
" <use xlink:href=\"#sub";
321 refpath += hpathname;
322 refpath +=
"\" transform=\"translate(6,0)\" />\n";
323 refpath +=
" <use xlink:href=\"#sub";
324 refpath += hpathname;
325 refpath +=
"\" transform=\"translate(-6,0)\" />\n";
328 refpath +=
" <use xlink:href=\"#subfd";
329 refpath += hpathname;
330 refpath +=
"\" />\n";
331 refpath +=
" <use xlink:href=\"#subfd";
332 refpath += hpathname;
333 refpath +=
"\" transform=\"translate(6,0)\"/>\n";
334 refpath +=
" <use xlink:href=\"#subfd";
335 refpath += hpathname;
336 refpath +=
"\" transform=\"translate(-6,0)\"/>\n";
337 refpath +=
" <use xlink:href=\"#subbd";
338 refpath += hpathname;
339 refpath +=
"\" />\n";
340 refpath +=
" <use xlink:href=\"#subbd";
341 refpath += hpathname;
342 refpath +=
"\" transform=\"translate(6,0)\"/>\n";
343 refpath +=
" <use xlink:href=\"#subbd";
344 refpath += hpathname;
345 refpath +=
"\" transform=\"translate(-6,0)\"/>\n";
349 if(d->
dc[d->
level].
bkMode == U_TRANSPARENT || hatchType >= U_HS_SOLIDCLR){
350 safeprintf(hatchname,
"WMFhatch%d_%s",hatchType,tmpcolor);
351 safeprintf(hpathname,
"WMFhpath%d_%s",hatchType,tmpcolor);
357 defs +=
" <pattern id=\"";
359 defs +=
"\" xlink:href=\"#WMFhbasepattern\">\n";
361 defs +=
" </pattern>\n";
368 safeprintf(hbkname,
"WMFhbkclr_%s",bkcolor);
375 defs +=
" <rect id=\"";
377 defs +=
"\" x=\"0\" y=\"0\" width=\"6\" height=\"6\" fill=\"#";
383 safeprintf(hatchname,
"WMFhatch%d_%s_%s",hatchType,tmpcolor,bkcolor);
389 defs +=
" <pattern id=\"";
391 defs +=
"\" xlink:href=\"#WMFhbasepattern\">\n";
392 defs +=
" <use xlink:href=\"#";
396 defs +=
" </pattern>\n";
429 int dibparams = U_BI_UNKNOWN;
434 char *rgba_px =
nullptr;
435 const char *px =
nullptr;
439 if(iUsage == U_DIB_RGB_COLORS){
441 dibparams = wget_DIB_params(dib, &px, &ct, &numCt, &
width, &
height, &colortype, &
invert);
442 if(dibparams == U_BI_RGB){
464 gchar *base64String=
nullptr;
465 if(dibparams == U_BI_JPEG || dibparams==U_BI_PNG){
466 base64String = g_base64_encode((guchar*) px, numCt );
469 base64String = g_base64_encode((guchar*) mempng.
buffer, mempng.
size );
477 idx =
in_images(d, (
char *) base64String);
478 auto & defs = d->
defs;
484 safeprintf(imagename,
"WMFimage%d",idx++);
485 safeprintf(xywh,
" x=\"0\" y=\"0\" width=\"%d\" height=\"%d\" ",
width,
height);
488 defs +=
" <image id=\"";
493 if(dibparams == U_BI_JPEG){ defs +=
" xlink:href=\"data:image/jpeg;base64,"; }
494 else { defs +=
" xlink:href=\"data:image/png;base64,"; }
495 defs += base64String;
497 defs +=
" preserveAspectRatio=\"none\"\n";
502 defs +=
" <pattern id=\"";
506 defs +=
"\n patternUnits=\"userSpaceOnUse\"";
508 defs +=
" <use id=\"";
511 defs +=
" xlink:href=\"#";
515 defs +=
" </pattern>\n";
517 g_free(base64String);
534 char *rgba_px =
nullptr;
542 if(colortype < 16)
return(U_WMR_INVALID);
563 gchar *base64String=
nullptr;
565 base64String = g_base64_encode((guchar*) mempng.
buffer, mempng.
size );
574 idx =
in_images(d, (
char *) base64String);
575 auto & defs = d->
defs;
581 safeprintf(imagename,
"WMFimage%d",idx++);
582 safeprintf(xywh,
" x=\"0\" y=\"0\" width=\"%d\" height=\"%d\" ",
width,
height);
585 defs +=
" <image id=\"";
590 defs +=
" xlink:href=\"data:image/png;base64,";
591 defs += base64String;
593 defs +=
" preserveAspectRatio=\"none\"\n";
598 defs +=
" <pattern id=\"";
602 defs +=
"\n patternUnits=\"userSpaceOnUse\"";
604 defs +=
" <use id=\"";
607 defs +=
" xlink:href=\"#";
610 defs +=
" </pattern>\n";
612 g_free(base64String);
640 std::string combined;
652 uint32_t idx =
in_clips(d, combined.c_str());
658 tmp_clippath <<
"\n<clipPath";
659 tmp_clippath <<
"\n\tclipPathUnits=\"userSpaceOnUse\" ";
660 tmp_clippath <<
"\n\tid=\"clipWmfPath" << d->
dc[d->
level].
clip_id <<
"\"";
661 tmp_clippath <<
" >";
662 tmp_clippath <<
"\n\t<path d=\"";
663 tmp_clippath << combined;
664 tmp_clippath <<
"\"";
665 tmp_clippath <<
"\n\t/>";
666 tmp_clippath <<
"\n</clipPath>";
681 char tmp[1024] = {0};
724 case U_R2_NOTMERGEPEN:
725 case U_R2_MASKNOTPEN:
727 case U_R2_NOTCOPYPEN:
731 case U_R2_MASKPENNOT:
734 case U_R2_NOTMASKPEN:
737 case U_R2_MERGENOTPEN:
740 case U_R2_MERGEPENNOT:
754 d->
outsvg +=
"\n\tstyle=\"";
756 tmp_style <<
"fill:none;";
765 snprintf(tmp, 1023,
"fill:url(#WMFimage%d_ref); ",d->
dc[d->
level].
fill_idx);
771 tmp_style <<
"fill:" <<
fill.toString(
false).c_str() <<
";";
780 tmp_style <<
"fill-opacity:1;";
798 tmp_style <<
"stroke:none;";
813 tmp_style <<
"stroke:" <<
stroke.toString(
false).c_str() <<
";";
817 tmp_style <<
"stroke-width:" <<
824 tmp_style <<
"stroke-linecap:" <<
832 tmp_style <<
"stroke-linejoin:" <<
841 tmp_style <<
"stroke-miterlimit:" <<
847 tmp_style <<
"stroke-dasharray:";
854 tmp_style <<
"stroke-dashoffset:0;";
856 tmp_style <<
"stroke-dasharray:none;";
858 tmp_style <<
"stroke-opacity:1;";
862 tmp_style <<
"\n\tclip-path=\"url(#clipWmfPath" << d->
dc[d->
level].
clip_id <<
")\" ";
918 return(cxform.
str());
926 char *record =
nullptr;
929 if (index < 0 && index >= d->
n_obj){
return; }
931 if(!record){
return; }
934 (void) U_WMRCREATEPENINDIRECT_get(record, &up);
937 switch (up.
Style & U_PS_STYLE_MASK) {
941 case U_PS_DASHDOTDOT:
943 int penstyle = (up.
Style & U_PS_STYLE_MASK);
949 if (penstyle==U_PS_DASH || penstyle==U_PS_DASHDOT || penstyle==U_PS_DASHDOTDOT) {
955 if (penstyle==U_PS_DOT || penstyle==U_PS_DASHDOT || penstyle==U_PS_DASHDOTDOT) {
959 if (penstyle==U_PS_DASHDOTDOT) {
976 switch (up.
Style & U_PS_ENDCAP_MASK) {
979 case U_PS_ENDCAP_FLAT:
983 switch (up.
Style & U_PS_JOIN_MASK) {
986 case U_PS_JOIN_ROUND:
992 if (up.
Style == U_PS_NULL) {
997 int cur_level = d->
level;
1000 d->
level = cur_level;
1003 int cur_level = d->
level;
1006 d->
level = cur_level;
1018 const char *membrush;
1020 if (index < 0 || index >= d->
n_obj)
return;
1025 iType = *(uint8_t *)(record + offsetof(
U_METARECORD, iType ) );
1028 (void) U_WMRCREATEBRUSHINDIRECT_get(record, &membrush);
1029 memcpy(&lb, membrush, U_SIZE_WLOGBRUSH);
1030 if(lb.
Style == U_BS_SOLID){
1035 else if(lb.
Style == U_BS_HATCHED){
1041 else if(lb.
Style == U_BS_NULL){
1050 const char *Bm16h =
nullptr;
1051 const char *dib =
nullptr;
1052 (void) U_WMRDIBCREATEPATTERNBRUSH_get(record, &Style, &cUsage, &Bm16h, &dib);
1058 memcpy(&Bm16, Bm16h, U_SIZE_BITMAP16);
1059 px = Bm16h + U_SIZE_BITMAP16;
1062 if(tidx == U_WMR_INVALID){
1073 g_message(
"Please send WMF file to developers - select_brush U_WMR_DIBCREATEPATTERNBRUSH not bm16 or dib, not handled");
1081 if(U_WMRCREATEPATTERNBRUSH_get(record, &Bm16h, &cbPx, &px)){
1083 if(tidx == 0xFFFFFFFF){
1100 char *record =
nullptr;
1101 const char *memfont;
1102 const char *facename;
1105 if (index < 0 || index >= d->
n_obj)
return;
1111 (void) U_WMRCREATEFONTINDIRECT_get(record, &memfont);
1112 memcpy(&font,memfont,U_SIZE_FONT_CORE);
1113 facename = memfont + U_SIZE_FONT_CORE;
1119 int cur_level = d->
level;
1127 font_size = round(20.0 * 0.8 * font_size)/(20.0 * 0.8);
1128 d->
level = cur_level;
1177 if (
index >= 0 && index < d->n_obj) {
1236 uint32_t *res = (uint32_t *) malloc(
sizeof(uint32_t) * (count + 1));
1237 if(!res)
throw "Inkscape fatal memory allocation error - cannot continue";
1238 for(uint32_t i=0; i<count; i++){ res[i] = 0xFFFD; }
1256 double dx,
double dy,
double dw,
double dh,
int sx,
int sy,
int sw,
int sh, uint32_t iUsage){
1259 int dibparams = U_BI_UNKNOWN;
1261 tmp_image <<
"\n\t <image\n";
1263 tmp_image <<
"\tclip-path=\"url(#clipWmfPath" << d->
dc[d->
level].
clip_id <<
")\"\n";
1265 tmp_image <<
" y=\"" << dy <<
"\"\n x=\"" << dx <<
"\"\n ";
1270 char *rgba_px =
nullptr;
1271 char *sub_px =
nullptr;
1272 const char *px =
nullptr;
1276 if(iUsage == U_DIB_RGB_COLORS){
1278 dibparams = wget_DIB_params(dib, &px, &ct, &numCt, &
width, &
height, &colortype, &
invert);
1279 if(dibparams == U_BI_RGB){
1280 if(sw == 0 || sh == 0){
1295 sub_px = RGBA_to_RGBA(
1303 if(!sub_px)sub_px=rgba_px;
1314 gchar *base64String=
nullptr;
1315 if(dibparams == U_BI_JPEG){
1316 tmp_image <<
" xlink:href=\"data:image/jpeg;base64,";
1317 base64String = g_base64_encode((guchar*) px, numCt );
1319 else if(dibparams==U_BI_PNG){
1320 tmp_image <<
" xlink:href=\"data:image/png;base64,";
1321 base64String = g_base64_encode((guchar*) px, numCt );
1324 tmp_image <<
" xlink:href=\"data:image/png;base64,";
1325 base64String = g_base64_encode((guchar*) mempng.
buffer, mempng.
size );
1329 tmp_image <<
" xlink:href=\"data:image/png;base64,";
1332 tmp_image << base64String;
1333 g_free(base64String);
1335 tmp_image <<
"\"\n height=\"" << dh <<
"\"\n width=\"" << dw <<
"\"\n";
1337 tmp_image <<
" preserveAspectRatio=\"none\"\n";
1338 tmp_image <<
"/> \n";
1358 double dx,
double dy,
double dw,
double dh,
int sx,
int sy,
int sw,
int sh){
1362 tmp_image <<
"\n\t <image\n";
1364 tmp_image <<
"\tclip-path=\"url(#clipWmfPath" << d->
dc[d->
level].
clip_id <<
")\"\n";
1366 tmp_image <<
" y=\"" << dy <<
"\"\n x=\"" << dx <<
"\"\n ";
1371 char *rgba_px =
nullptr;
1372 char *sub_px =
nullptr;
1382 if(sw == 0 || sh == 0){
1387 if(colortype < 16)
return;
1400 sub_px = RGBA_to_RGBA(
1408 if(!sub_px)sub_px=rgba_px;
1417 gchar *base64String=
nullptr;
1419 tmp_image <<
" xlink:href=\"data:image/png;base64,";
1420 base64String = g_base64_encode((guchar*) mempng.
buffer, mempng.
size );
1424 tmp_image <<
" xlink:href=\"data:image/png;base64,";
1427 tmp_image << base64String;
1428 g_free(base64String);
1430 tmp_image <<
"\"\n height=\"" << dh <<
"\"\n width=\"" << dw <<
"\"\n";
1432 tmp_image <<
" preserveAspectRatio=\"none\"\n";
1433 tmp_image <<
"/> \n";
1456 const char *blimit = contents + length;
1478 double left, right, top, bottom;
1480 uint16_t tbkMode = U_TRANSPARENT;
1487 char const* wDbgString = getenv(
"INKSCAPE_DBG_WMF" );
1488 if ( wDbgString !=
nullptr ) {
1489 if(strstr(wDbgString,
"RECORD")){ wDbgRecord = 1; }
1490 if(strstr(wDbgString,
"COMMENT")){ wDbgComment = 1; }
1491 if(strstr(wDbgString,
"FINAL")){ wDbgFinal = 1; }
1502 tsp.
taln = ALILEFT + ALIBASE;
1528 nSize = wmfheader_get(contents, blimit, &Placeable, &Header);
1541 for(
int i=0; i < d->
n_obj; ++i )
1545 if(!Placeable.
Inch){ Placeable.
Inch= 1440; }
1549 int hold_nSize =
off = nSize;
1553 nSize = U_WMRRECSAFE_get(contents +
off, blimit);
1555 iType = *(uint8_t *)(contents +
off + offsetof(
U_METARECORD, iType ) );
1558 (void) U_WMRSETWINDOWEXT_get(contents +
off, &Dst);
1565 Placeable.
Dst.
right = round(((
double) Placeable.
Inch) * 297.0/25.4);
1566 Placeable.
Dst.
bottom = round(((
double) Placeable.
Inch) * 210.0/25.4);
1611 dbg_str <<
"<!-- U_WMR_HEADER -->\n";
1613 d->
outdef +=
"<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\n";
1616 tmp_outdef <<
"<svg\n";
1617 tmp_outdef <<
" xmlns:svg=\"http://www.w3.org/2000/svg\"\n";
1618 tmp_outdef <<
" xmlns=\"http://www.w3.org/2000/svg\"\n";
1619 tmp_outdef <<
" xmlns:xlink=\"http://www.w3.org/1999/xlink\"\n";
1620 tmp_outdef <<
" xmlns:sodipodi=\"http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd\"\n";
1621 tmp_outdef <<
" version=\"1.0\"\n";
1645 nSize = U_WMRRECSAFE_get(contents, blimit);
1651 iType = *(uint8_t *)(contents + offsetof(
U_METARECORD, iType ) );
1653 wmr_mask = U_wmr_properties(iType);
1654 if (wmr_mask == U_WMR_INVALID) {
1661 std::cout <<
"record type: " << iType <<
" name " << U_wmr_names(iType) <<
" length: " << nSize <<
" offset: " <<
off <<std::endl;
1673 if ((d->
dc[d->
level].
dirty & DIRTY_TEXT) || ((wmr_mask != U_WMR_INVALID) && (wmr_mask & U_DRAW_TEXT) && d->
tri->
dirty)){
1677 tmp_clip <<
"\n<g\n\tclip-path=\"url(#clipWmfPath" << d->
dc[d->
level].
clip_id <<
")\"\n>";
1729 if((d->
mask & U_DRAW_NOFILL) && !(d->
mask & U_DRAW_VISIBLE) &&
1730 !(wmr_mask & U_DRAW_ONLYTO) && (wmr_mask & U_DRAW_VISIBLE)){
1731 d->
mask ^= U_DRAW_NOFILL;
1735 (wmr_mask != U_WMR_INVALID) &&
1736 (d->
mask & U_DRAW_VISIBLE) &&
1738 (d->
mask & U_DRAW_FORCE) ||
1739 (wmr_mask & U_DRAW_ALTERS) ||
1740 ((d->
mask & U_DRAW_NOFILL) != (wmr_mask & U_DRAW_NOFILL)) ||
1741 ( (wmr_mask & U_DRAW_VISIBLE) &&
1743 ( !(d->
mask & U_DRAW_ONLYTO) ) ||
1744 ((d->
mask & U_DRAW_ONLYTO) && !(wmr_mask & U_DRAW_ONLYTO) )
1750 if(!(d->
path.empty())){
1756 d->
outsvg +=
" \" /> \n";
1768 dbg_str <<
"<!-- U_WMR_EOF -->\n";
1776 dbg_str <<
"<!-- U_WMR_SETBKCOLOR -->\n";
1777 nSize = U_WMRSETBKCOLOR_get(contents, &tbkColor);
1786 dbg_str <<
"<!-- U_WMR_SETBKMODE -->\n";
1787 nSize = U_WMRSETBKMODE_get(contents, &tbkMode);
1799 dbg_str <<
"<!-- U_WMR_SETMAPMODE -->\n";
1800 nSize = U_WMRSETMAPMODE_get(contents, &utmp16);
1811 case U_MM_LOENGLISH:
1812 case U_MM_HIENGLISH:
1817 case U_MM_ISOTROPIC:
1818 case U_MM_ANISOTROPIC:
1825 dbg_str <<
"<!-- U_WMR_SETROP2 -->\n";
1826 nSize = U_WMRSETROP2_get(contents, &utmp16);
1833 dbg_str <<
"<!-- U_WMR_SETPOLYFILLMODE -->\n";
1834 nSize = U_WMRSETPOLYFILLMODE_get(contents, &utmp16);
1842 dbg_str <<
"<!-- U_WMR_SETSTRETCHBLTMODE -->\n";
1843 nSize = U_WMRSETSTRETCHBLTMODE_get(contents, &utmp16);
1850 dbg_str <<
"<!-- U_WMR_SETTEXTCOLOR -->\n";
1861 dbg_str <<
"<!-- U_WMR_SETWINDOWORG -->\n";
1862 nSize = U_WMRSETWINDOWORG_get(contents, &d->
dc[d->
level].
winorg);
1869 dbg_str <<
"<!-- U_WMR_SETWINDOWEXT -->\n";
1871 nSize = U_WMRSETWINDOWEXT_get(contents, &d->
dc[d->
level].
sizeWnd);
1918 dbg_str <<
"<!-- U_WMR_SETWINDOWORG -->\n";
1919 nSize = U_WMRSETVIEWPORTORG_get(contents, &d->
dc[d->
level].
vieworg);
1924 dbg_str <<
"<!-- U_WMR_SETVIEWPORTEXTEX -->\n";
1961 dbg_str <<
"<!-- U_WMR_LINETO -->\n";
1963 nSize = U_WMRLINETO_get(contents, &pt16);
1965 d->
mask |= wmr_mask;
1967 tmp_path <<
"\n\tL " <<
pix_to_xy( d, pt16.
x, pt16.
y) <<
" ";
1972 dbg_str <<
"<!-- U_WMR_MOVETO -->\n";
1974 nSize = U_WMRLINETO_get(contents, &pt16);
1976 d->
mask |= wmr_mask;
1981 "\n\tM " <<
pix_to_xy( d, pt16.
x, pt16.
y ) <<
" ";
1986 dbg_str <<
"<!-- U_WMR_EXCLUDECLIPRECT -->\n";
1989 nSize = U_WMREXCLUDECLIPRECT_get(contents, &
rc);
2000 tmp_path <<
"M " <<
pix_to_xy( d,
rc.left ,
rc.top ) <<
" ";
2001 tmp_path <<
"L " <<
pix_to_xy( d,
rc.right,
rc.top ) <<
" ";
2002 tmp_path <<
"L " <<
pix_to_xy( d,
rc.right,
rc.bottom ) <<
" ";
2003 tmp_path <<
"L " <<
pix_to_xy( d,
rc.left,
rc.bottom ) <<
" ";
2014 dbg_str <<
"<!-- U_WMR_INTERSECTCLIPRECT -->\n";
2016 nSize = U_WMRINTERSECTCLIPRECT_get(contents, &
rc);
2019 tmp_path <<
"M " <<
pix_to_xy( d,
rc.left ,
rc.top ) <<
" ";
2020 tmp_path <<
"L " <<
pix_to_xy( d,
rc.right,
rc.top ) <<
" ";
2021 tmp_path <<
"L " <<
pix_to_xy( d,
rc.right,
rc.bottom ) <<
" ";
2022 tmp_path <<
"L " <<
pix_to_xy( d,
rc.left,
rc.bottom ) <<
" ";
2033 dbg_str <<
"<!-- U_WMR_ARC -->\n";
2035 nSize = U_WMRARC_get(contents, &ArcStart, &ArcEnd, &
rc);
2039 int f2 = (d->
arcdir == U_AD_COUNTERCLOCKWISE ? 0 : 1);
2040 int stat = wmr_arc_points(
rc, ArcStart, ArcEnd,&f1, f2, ¢er, &
start, &
end, &
size);
2047 tmp_path <<
" " << f1 <<
"," << f2 <<
" ";
2049 d->
mask |= wmr_mask;
2052 dbg_str <<
"<!-- ARC record is invalid -->\n";
2058 dbg_str <<
"<!-- U_WMR_ELLIPSE -->\n";
2060 nSize = U_WMRELLIPSE_get(contents, &
rc);
2068 tmp_ellipse <<
"cx=\"" << cx <<
"\" ";
2069 tmp_ellipse <<
"cy=\"" << cy <<
"\" ";
2070 tmp_ellipse <<
"rx=\"" << rx <<
"\" ";
2071 tmp_ellipse <<
"ry=\"" << ry <<
"\" ";
2073 d->
mask |= wmr_mask;
2075 d->
outsvg +=
" <ellipse ";
2083 case U_WMR_FLOODFILL: dbg_str <<
"<!-- U_WMR_EXTFLOODFILL -->\n";
break;
2086 dbg_str <<
"<!-- U_WMR_PIE -->\n";
2088 nSize = U_WMRPIE_get(contents, &ArcStart, &ArcEnd, &
rc);
2091 int f2 = (d->
arcdir == U_AD_COUNTERCLOCKWISE ? 0 : 1);
2092 if(!wmr_arc_points(
rc, ArcStart, ArcEnd, &f1, f2, ¢er, &
start, &
end, &
size)){
2093 tmp_path <<
"\n\tM " <<
pix_to_xy(d, center.
x, center.
y);
2099 tmp_path <<
" " << f1 <<
"," << f2 <<
" ";
2102 d->
mask |= wmr_mask;
2105 dbg_str <<
"<!-- PIE record is invalid -->\n";
2111 dbg_str <<
"<!-- U_WMR_RECTANGLE -->\n";
2113 nSize = U_WMRRECTANGLE_get(contents, &
rc);
2114 U_sanerect16(
rc, &left, &top, &right, &bottom);
2117 tmp_rectangle <<
"\n\tM " <<
pix_to_xy( d, left , top ) <<
" ";
2118 tmp_rectangle <<
"\n\tL " <<
pix_to_xy( d, right, top ) <<
" ";
2119 tmp_rectangle <<
"\n\tL " <<
pix_to_xy( d, right, bottom ) <<
" ";
2120 tmp_rectangle <<
"\n\tL " <<
pix_to_xy( d, left, bottom ) <<
" ";
2121 tmp_rectangle <<
"\n\tz";
2123 d->
mask |= wmr_mask;
2125 tmp_path << tmp_rectangle.
str().c_str();
2130 dbg_str <<
"<!-- U_WMR_ROUNDRECT -->\n";
2132 int16_t Height,Width;
2133 nSize = U_WMRROUNDRECT_get(contents, &Width, &Height, &
rc);
2134 U_sanerect16(
rc, &left, &top, &right, &bottom);
2135 double f = 4.*(sqrt(2) - 1)/3;
2136 double f1 = 1.0 - f;
2137 double cnx = Width/2;
2138 double cny = Height/2;
2142 tmp_rectangle <<
"\n"
2146 tmp_rectangle <<
" C "
2153 tmp_rectangle <<
" L "
2156 tmp_rectangle <<
" C "
2163 tmp_rectangle <<
" L "
2166 tmp_rectangle <<
" C "
2167 <<
pix_to_xy(d, right , bottom - cny*f1 )
2169 <<
pix_to_xy(d, right - cnx*f1 , bottom )
2173 tmp_rectangle <<
" L "
2176 tmp_rectangle <<
" C "
2177 <<
pix_to_xy(d, left + cnx*f1 , bottom )
2179 <<
pix_to_xy(d, left , bottom - cny*f1 )
2183 tmp_rectangle <<
" z\n";
2186 d->
mask |= wmr_mask;
2188 tmp_path << tmp_rectangle.
str().c_str();
2193 dbg_str <<
"<!-- U_WMR_PATBLT -->\n";
2195 nSize = U_WMRPATBLT_get(contents, &Dst, &cwh, &dwRop3);
2197 tmp_rectangle <<
"\n\tM " <<
pix_to_xy( d, Dst.
x , Dst.
y ) <<
" ";
2198 tmp_rectangle <<
"\n\tL " <<
pix_to_xy( d, Dst.
x + cwh.
x, Dst.
y ) <<
" ";
2199 tmp_rectangle <<
"\n\tL " <<
pix_to_xy( d, Dst.
x + cwh.
x, Dst.
y + cwh.
y ) <<
" ";
2200 tmp_rectangle <<
"\n\tL " <<
pix_to_xy( d, Dst.
x, Dst.
y + cwh.
y ) <<
" ";
2201 tmp_rectangle <<
"\n\tz";
2203 d->
mask |= wmr_mask;
2205 tmp_path << tmp_rectangle.
str().c_str();
2210 dbg_str <<
"<!-- U_WMR_SAVEDC -->\n";
2221 case U_WMR_SETPIXEL: dbg_str <<
"<!-- U_WMR_SETPIXEL -->\n";
break;
2224 dbg_str <<
"<!-- U_EMR_OFFSETCLIPRGN -->\n";
2226 nSize = U_WMROFFSETCLIPRGN_get(contents,&
off);
2241 dbg_str <<
"<!-- U_WMR_BITBLT -->\n";
2242 nSize = U_WMRBITBLT_get(contents,&Dst,&cwh,&Src,&dwRop3,&Bm16,&px);
2244 if(dwRop3 == U_NOOP)
break;
2250 tmp_rectangle <<
"\n\tM " <<
pix_to_xy( d, dx, dy ) <<
" ";
2251 tmp_rectangle <<
"\n\tL " <<
pix_to_xy( d, dx + dw, dy ) <<
" ";
2252 tmp_rectangle <<
"\n\tL " <<
pix_to_xy( d, dx + dw, dy + dh ) <<
" ";
2253 tmp_rectangle <<
"\n\tL " <<
pix_to_xy( d, dx, dy + dh ) <<
" ";
2254 tmp_rectangle <<
"\n\tz";
2256 d->
mask |= wmr_mask;
2258 d->
mask |= U_DRAW_CLOSED;
2260 tmp_path << tmp_rectangle.
str().c_str();
2274 common_bm16_to_image(d,Bm16,px,dx,dy,dw,dh,sx,sy,sw,sh);
2279 dbg_str <<
"<!-- U_WMR_STRETCHBLT -->\n";
2280 nSize = U_WMRSTRETCHBLT_get(contents,&Dst,&cDst,&Src,&cSrc,&dwRop3,&Bm16,&px);
2282 if(dwRop3 == U_NOOP)
break;
2285 int32_t dw = cDst.
x;
2286 int32_t dh = cDst.
y;
2288 tmp_rectangle <<
"\n\tM " <<
pix_to_xy( d, dx, dy ) <<
" ";
2289 tmp_rectangle <<
"\n\tL " <<
pix_to_xy( d, dx + dw, dy ) <<
" ";
2290 tmp_rectangle <<
"\n\tL " <<
pix_to_xy( d, dx + dw, dy + dh ) <<
" ";
2291 tmp_rectangle <<
"\n\tL " <<
pix_to_xy( d, dx, dy + dh ) <<
" ";
2292 tmp_rectangle <<
"\n\tz";
2294 d->
mask |= wmr_mask;
2296 d->
mask |= U_DRAW_CLOSED;
2298 tmp_path << tmp_rectangle.
str().c_str();
2312 common_bm16_to_image(d,Bm16,px,dx,dy,dw,dh,sx,sy,sw,sh);
2318 dbg_str <<
"<!-- U_WMR_POLYGON/POLYLINE -->\n";
2319 nSize = U_WMRPOLYGON_get(contents, &cPts, &points);
2324 d->
mask |= wmr_mask;
2325 memcpy(&pt16,points,U_SIZE_POINT16); points += U_SIZE_POINT16;
2327 tmp_str <<
"\n\tM " <<
pix_to_xy( d, pt16.
x, pt16.
y) <<
" ";
2329 for (i=1; i<cPts; i++) {
2330 memcpy(&pt16,points,U_SIZE_POINT16); points+=U_SIZE_POINT16;
2331 tmp_str <<
"\n\tL " <<
pix_to_xy( d, pt16.
x, pt16.
y) <<
" ";
2334 tmp_path << tmp_str.
str().c_str();
2341 dbg_str <<
"<!-- U_WMR_ESCAPE -->\n";
2342 uint16_t Escape, elen;
2343 nSize = U_WMRESCAPE_get(contents, &Escape, &elen, &
text);
2346 memcpy(&utmp4,
text ,4);
2347 if(Escape == U_MFE_SETLINECAP){
2348 switch (utmp4 & U_PS_ENDCAP_MASK) {
2351 case U_PS_ENDCAP_FLAT:
2355 else if(Escape == U_MFE_SETLINEJOIN){
2356 switch (utmp4 & U_PS_JOIN_MASK) {
2359 case U_PS_JOIN_ROUND:
2363 else if(Escape == U_MFE_SETMITERLIMIT){
2365 float miterlimit = utmp4;
2375 dbg_str <<
"<!-- U_WMR_RESTOREDC -->\n";
2378 nSize = U_WMRRESTOREDC_get(contents, &DC);
2379 int old_level = d->
level;
2385 if (d->
level + DC >= 0)
2388 while (old_level > d->
level) {
2408 dbg_str <<
"<!-- U_WMR_EXTSELECTCLIPRGN -->\n";
2409 nSize = U_WMRSELECTCLIPREGION_get(contents, &utmp16);
2410 if (utmp16 == U_RGN_COPY)
2416 dbg_str <<
"<!-- U_WMR_SELECTOBJECT -->\n";
2418 nSize = U_WMRSELECTOBJECT_get(contents, &utmp16);
2419 unsigned int index = utmp16;
2448 dbg_str <<
"<!-- U_WMR_SETTEXTALIGN -->\n";
2452 case U_WMR_DRAWTEXT: dbg_str <<
"<!-- U_WMR_DRAWTEXT -->\n";
break;
2455 dbg_str <<
"<!-- U_WMR_CHORD -->\n";
2457 nSize = U_WMRCHORD_get(contents, &ArcStart, &ArcEnd, &
rc);
2460 int f2 = (d->
arcdir == U_AD_COUNTERCLOCKWISE ? 0 : 1);
2461 if(!wmr_arc_points(
rc, ArcStart, ArcEnd, &f1, f2, ¢er, &
start, &
end, &
size)){
2467 tmp_path <<
" " << f1 <<
"," << f2 <<
" ";
2470 d->
mask |= wmr_mask;
2473 dbg_str <<
"<!-- CHORD record is invalid -->\n";
2482 dbg_str <<
"<!-- U_WMR_TEXTOUT -->\n";
2483 nSize = U_WMRTEXTOUT_get(contents, &Dst, &tlen, &
text);
2487 dbg_str <<
"<!-- U_WMR_EXTTEXTOUT -->\n";
2488 nSize = U_WMREXTTEXTOUT_get(contents, &Dst, &tlen, &Opts, &
text, &dx, &
rc );
2490 uint32_t fOptions = Opts;
2508 uint32_t *dup_wt =
nullptr;
2524 if(*((uint8_t *)ansi_text) <= 0x1F){
2533 gchar *escaped_text = g_markup_escape_text(ansi_text, -1);
2543 tsp.
italics = FC_SLANT_OBLIQUE;
break;
2545 tsp.
italics = FC_SLANT_ITALIC;
break;
2548 tsp.
italics = FC_SLANT_ROMAN;
break;
2564 default: tsp.
weight = FC_WEIGHT_NORMAL ;
break;
2580 if( (fOptions & U_ETO_RTLREADING) || (d->
dc[d->
level].
textAlign & U_TA_RTLREADING) ){ tsp.
ldir = LDIR_RL; }
2581 else{ tsp.
ldir = LDIR_LR; }
2603 tmp_clip <<
"\n<g\n\tclip-path=\"url(#clipWmfPath" << d->
dc[d->
level].
clip_id <<
")\"\n>";
2616 g_free(escaped_text);
2629 dbg_str <<
"<!-- U_WMR_POLYPOLYGON16 -->\n";
2631 const uint16_t *aPolyCounts;
2634 nSize = U_WMRPOLYPOLYGON_get(contents, &nPolys, &aPolyCounts, &Points);
2637 d->
mask |= wmr_mask;
2640 for (n=cpts=0; n < nPolys; n++) { cpts += aPolyCounts[n]; }
2642 cpts *= U_SIZE_POINT16;
2644 for (n=0; n < nPolys && i<cpts; n++) {
2647 memcpy(&apt, Points + i, U_SIZE_POINT16);
2649 poly_path <<
"\n\tM " <<
pix_to_xy( d, apt.
x, apt.
y) <<
" ";
2650 i += U_SIZE_POINT16;
2652 for (j=1; j < aPolyCounts[n] && i < cpts; j++) {
2653 memcpy(&apt, Points + i, U_SIZE_POINT16);
2654 poly_path <<
"\n\tL " <<
pix_to_xy( d, apt.
x, apt.
y) <<
" ";
2655 i += U_SIZE_POINT16;
2658 tmp_str << poly_path.
str().c_str();
2663 tmp_path << tmp_str.
str().c_str();
2675 dbg_str <<
"<!-- U_WMR_3A..3F -->\n";
2680 dbg_str <<
"<!-- U_WMR_DIBBITBLT -->\n";
2681 nSize = U_WMRDIBBITBLT_get(contents, &Dst, &cwh, &Src, &dwRop3, &dib);
2688 if(dwRop3 == U_NOOP)
break;
2694 tmp_rectangle <<
"\n\tM " <<
pix_to_xy( d, dx, dy ) <<
" ";
2695 tmp_rectangle <<
"\n\tL " <<
pix_to_xy( d, dx + dw, dy ) <<
" ";
2696 tmp_rectangle <<
"\n\tL " <<
pix_to_xy( d, dx + dw, dy + dh ) <<
" ";
2697 tmp_rectangle <<
"\n\tL " <<
pix_to_xy( d, dx, dy + dh ) <<
" ";
2698 tmp_rectangle <<
"\n\tz";
2700 d->
mask |= wmr_mask;
2702 d->
mask |= U_DRAW_CLOSED;
2704 tmp_path << tmp_rectangle.
str().c_str();
2719 common_dib_to_image(d,dib,dx,dy,dw,dh,sx,sy,sw,sh,U_DIB_RGB_COLORS);
2725 dbg_str <<
"<!-- U_WMR_DIBSTRETCHBLT -->\n";
2726 nSize = U_WMRDIBSTRETCHBLT_get(contents, &Dst, &cDst, &Src, &cSrc, &dwRop3, &dib);
2739 common_dib_to_image(d,dib,dx,dy,dw,dh,sx,sy,sw,sh, U_DIB_RGB_COLORS);
2745 dbg_str <<
"<!-- U_WMR_DIBCREATEPATTERNBRUSH -->\n";
2751 dbg_str <<
"<!-- U_WMR_STRETCHDIB -->\n";
2752 nSize = U_WMRSTRETCHDIB_get(contents, &Dst, &cDst, &Src, &cSrc, &cUsage, &dwRop3, &dib);
2763 common_dib_to_image(d,dib,dx,dy,dw,dh,sx,sy,sw,sh,iUsageSrc);
2772 dbg_str <<
"<!-- U_WMR_44..47 -->\n";
2944 dbg_str <<
"<!-- U_WMR_EXTFLOODFILL..EF -->\n";
2949 dbg_str <<
"<!-- U_WMR_DELETEOBJECT -->\n";
2950 nSize = U_WMRDELETEOBJECT_get(contents, &utmp16);
2961 dbg_str <<
"<!-- F1..F6 -->\n";
2966 dbg_str <<
"<!-- U_WMR_CREATEPALETTE -->\n";
2970 case U_WMR_F8: dbg_str <<
"<!-- F8 -->\n";
break;
2973 dbg_str <<
"<!-- U_WMR_CREATEPATTERNBRUSH -->\n";
2979 dbg_str <<
"<!-- U_WMR_EXTCREATEPEN -->\n";
2985 dbg_str <<
"<!-- U_WMR_CREATEFONTINDIRECT -->\n";
2991 dbg_str <<
"<!-- U_WMR_CREATEBRUSHINDIRECT -->\n";
2997 dbg_str <<
"<!-- U_WMR_CREATEBITMAPINDIRECT -->\n";
3003 dbg_str <<
"<!-- U_WMR_CREATEBITMAP -->\n";
3009 dbg_str <<
"<!-- U_WMR_CREATEREGION -->\n";
3014 dbg_str <<
"<!-- U_WMR_??? -->\n";
3022 d->
path += tmp_path.
str().c_str();
3032 std::cout << d->
outsvg << std::endl;
3034 (void) U_wmr_properties(U_WMR_INVALID);
3036 return(file_status);
3041 for(
int i=0; i<
name.count; i++){ free(
name.strings[i]); }
3055 char *oldlocale = g_strdup(setlocale(LC_NUMERIC,
nullptr));
3056 setlocale(LC_NUMERIC,
"C");
3088 d.
defs +=
" <pattern id=\"WMFhbasepattern\" \n";
3089 d.
defs +=
" patternUnits=\"userSpaceOnUse\"\n";
3090 d.
defs +=
" width=\"6\" \n";
3091 d.
defs +=
" height=\"6\" \n";
3092 d.
defs +=
" x=\"0\" \n";
3093 d.
defs +=
" y=\"0\"> \n";
3094 d.
defs +=
" </pattern> \n";
3099 if(wmf_readdata(uri, &contents, &length))
return(
nullptr);
3104 FT_LOAD_NO_SCALE | FT_LOAD_NO_HINTING | FT_LOAD_NO_BITMAP,
3105 FT_KERNING_UNSCALED);
3112 std::unique_ptr<SPDocument> doc;
3123 for (i=0; i<d.
n_obj; i++)
3139 setlocale(LC_NUMERIC, oldlocale);
3150 "<inkscape-extension xmlns=\"" INKSCAPE_EXTENSION_URI
"\">\n"
3151 "<name>" N_(
"WMF Input")
"</name>\n"
3152 "<id>org.inkscape.input.wmf</id>\n"
3154 "<extension>.wmf</extension>\n"
3155 "<mimetype>image/x-wmf</mimetype>\n"
3156 "<filetypename>" N_(
"Windows Metafiles (*.wmf)")
"</filetypename>\n"
3157 "<filetypetooltip>" N_(
"Windows Metafiles")
"</filetypetooltip>\n"
3159 "</inkscape-extension>", std::make_unique<Wmf>());
3163 "<inkscape-extension xmlns=\"" INKSCAPE_EXTENSION_URI
"\">\n"
3164 "<name>" N_(
"WMF Output")
"</name>\n"
3165 "<id>org.inkscape.output.wmf</id>\n"
3166 "<param name=\"textToPath\" gui-text=\"" N_(
"Convert texts to paths")
"\" type=\"bool\">true</param>\n"
3167 "<param name=\"TnrToSymbol\" gui-text=\"" N_(
"Map Unicode to Symbol font")
"\" type=\"bool\">true</param>\n"
3168 "<param name=\"TnrToWingdings\" gui-text=\"" N_(
"Map Unicode to Wingdings")
"\" type=\"bool\">true</param>\n"
3169 "<param name=\"TnrToZapfDingbats\" gui-text=\"" N_(
"Map Unicode to Zapf Dingbats")
"\" type=\"bool\">true</param>\n"
3170 "<param name=\"UsePUA\" gui-text=\"" N_(
"Use MS Unicode PUA (0xF020-0xF0FF) for converted characters")
"\" type=\"bool\">false</param>\n"
3171 "<param name=\"FixPPTCharPos\" gui-text=\"" N_(
"Compensate for PPT font bug")
"\" type=\"bool\">false</param>\n"
3172 "<param name=\"FixPPTDashLine\" gui-text=\"" N_(
"Convert dashed/dotted lines to single lines")
"\" type=\"bool\">false</param>\n"
3173 "<param name=\"FixPPTGrad2Polys\" gui-text=\"" N_(
"Convert gradients to colored polygon series")
"\" type=\"bool\">false</param>\n"
3174 "<param name=\"FixPPTPatternAsHatch\" gui-text=\"" N_(
"Map all fill patterns to standard WMF hatches")
"\" type=\"bool\">false</param>\n"
3176 "<extension>.wmf</extension>\n"
3177 "<mimetype>image/x-wmf</mimetype>\n"
3178 "<filetypename>" N_(
"Windows Metafile (*.wmf)")
"</filetypename>\n"
3179 "<filetypetooltip>" N_(
"Windows Metafile")
"</filetypetooltip>\n"
3181 "</inkscape-extension>", std::make_unique<Wmf>());
3x3 matrix representing an affine transformation.
constexpr Coord y() const noexcept
constexpr Coord x() const noexcept
void setRoot(DrawingItem *root)
Extension * get(const gchar *key) const
This function looks up a Inkscape::Extension::Extension by using its unique id. It then returns a ref...
The object that is the basis for the Extension system.
bool set_param_bool(char const *name, bool value)
Sets a parameter identified by name with the boolean in the parameter value.
virtual unsigned fill(Inkscape::Extension::Print *, Geom::PathVector const &, Geom::Affine const &, SPStyle const *, Geom::OptRect const &, Geom::OptRect const &, Geom::OptRect const &)
virtual unsigned text(Inkscape::Extension::Print *, char const *, Geom::Point const &, SPStyle const *)
virtual unsigned stroke(Inkscape::Extension::Print *, Geom::PathVector const &, Geom::Affine const &, SPStyle const *, Geom::OptRect const &, Geom::OptRect const &, Geom::OptRect const &)
static int in_images(PWMF_CALLBACK_DATA d, char *test)
static double pix_to_x_point(PWMF_CALLBACK_DATA d, double px, double py)
static double pix_to_abs_size(PWMF_CALLBACK_DATA d, double px)
static double _pix_y_to_point(PWMF_CALLBACK_DATA d, double py)
static void select_pen(PWMF_CALLBACK_DATA d, int index)
static uint32_t add_bm16_image(PWMF_CALLBACK_DATA d, U_BITMAP16 Bm16, const char *px)
static void enlarge_hatches(PWMF_CALLBACK_DATA d)
static uint32_t add_dib_image(PWMF_CALLBACK_DATA d, const char *dib, uint32_t iUsage)
static void add_clips(PWMF_CALLBACK_DATA d, const char *clippath, unsigned int logic)
std::unique_ptr< SPDocument > open(Inkscape::Extension::Input *mod, char const *uri, bool is_importing) override
Open a file.
static double pix_to_y_point(PWMF_CALLBACK_DATA d, double px, double py)
static void select_font(PWMF_CALLBACK_DATA d, int index)
static int myMetaFileProc(const char *contents, unsigned int length, PWMF_CALLBACK_DATA d)
static void output_style(PWMF_CALLBACK_DATA d)
static void delete_object(PWMF_CALLBACK_DATA d, int index)
static double current_scale(PWMF_CALLBACK_DATA d)
static double current_rotation(PWMF_CALLBACK_DATA d)
static std::string current_matrix(PWMF_CALLBACK_DATA d, double x, double y, int useoffset)
static void common_dib_to_image(PWMF_CALLBACK_DATA d, const char *dib, double dx, double dy, double dw, double dh, int sx, int sy, int sw, int sh, uint32_t iUsage)
store SVG for an image given the pixmap and various coordinate information
static void enlarge_images(PWMF_CALLBACK_DATA d)
static void common_bm16_to_image(PWMF_CALLBACK_DATA d, U_BITMAP16 Bm16, const char *px, double dx, double dy, double dw, double dh, int sx, int sy, int sw, int sh)
store SVG for an image given the pixmap and various coordinate information
static int insert_object(PWMF_CALLBACK_DATA d, int type, const char *record)
void save(Inkscape::Extension::Output *mod, SPDocument *doc, char const *filename) override
static double _pix_x_to_point(PWMF_CALLBACK_DATA d, double px)
static uint32_t * unknown_chars(size_t count)
static int in_hatches(PWMF_CALLBACK_DATA d, char *test)
static void free_wmf_strings(WMF_STRINGS name)
bool check(Inkscape::Extension::Extension *module) override
Verify any dependencies.
static int in_clips(PWMF_CALLBACK_DATA d, const char *test)
static uint32_t add_hatch(PWMF_CALLBACK_DATA d, uint32_t hatchType, U_COLORREF hatchColor)
static void print_document_to_file(SPDocument *doc, const gchar *filename)
static void enlarge_clips(PWMF_CALLBACK_DATA d)
static std::string pix_to_xy(PWMF_CALLBACK_DATA d, double x, double y)
static int insertable_object(PWMF_CALLBACK_DATA d)
static void select_brush(PWMF_CALLBACK_DATA d, int index)
Generic failure for an undescribed reason.
static double convert(double from_dist, Unit const *from, Unit const *to)
Convert distances.
Typed SVG document implementation.
static std::unique_ptr< SPDocument > createNewDocFromMem(std::span< char const > buffer, bool keepalive, std::string const &filename="")
SPRoot * getRoot()
Returns our SPRoot.
int ensureUpToDate(unsigned int object_modified_tag=0)
Repeatedly works on getting the document updated, since sometimes it takes more than one pass to get ...
Length type internal to SPStyle.
static unsigned int display_key_new(unsigned numkeys)
Allocates unique integer keys.
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::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.
T< SPAttr::BASELINE_SHIFT, SPIBaselineShift > baseline_shift
Baseline shift (svg1.1 10.9.2)
A way to clear the N_ macro, which is defined as an inline function.
double inner(valarray< double > const &x, valarray< double > const &y)
bool are_near(Affine const &a1, Affine const &a2, Coord eps=EPSILON)
constexpr auto WMF_MAX_DC
DB db
This is the actual database object.
Print * get_print(gchar const *key)
void build_from_mem(gchar const *buffer, std::unique_ptr< Implementation::Implementation > in_imp)
Create a module from a buffer holding an XML description.
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.
void invert(const double v[16], double alpha[16])
SPRoot: SVG <svg> implementation.
WMF_DEVICE_CONTEXT dc[WMF_MAX_DC+1]
Information for a single text object.
int rt_tidx
index of rectangle that contains it
int decoration
text decorations, ignored during assembly, used during output
int weight
weight, as in FontConfig
int taln
text alignment with respect to x,y
double boff
Y LL corner - boff finds baseline
int spaces
count of spaces converted from wide kerning (1 or 2)
int co
condensed override, if set Font name included narrow
double ori
Orientation, angle of characters with respect to baseline in degrees.
int fi_idx
index of the font it uses
uint8_t * string
UTF-8 text
double fs
font size of text
int ldir
language direction LDIR_*
double vadvance
Line spacing typically 1.25 or 1.2, only set on the first text element in a complex
int italics
italics, as in FontConfig
double x
x coordinate, relative to TR_INFO x,y, in points
double y
y coordinate, relative to TR_INFO x,y, in points
int condensed
condensed, as in FontConfig
uint8_t Red
Red color (0-255)
uint8_t Green
Green color (0-255)
uint8_t Reserved
Not used.
uint8_t Blue
Blue color (0-255)
uint8_t * out
buffer to hold formatted output
int dirty
1 if text records are loaded
FT_INFO * fti
Font info storage
Bitmap16 Object WMF manual 2.2.2.1.
int16_t Height
bitmap height in scan lines.
uint8_t BitsPixel
number of adjacent color bits on each plane (R bits + G bits + B bits ????)
int16_t Width
bitmap width in pixels.
uint8_t Red
Red color (0-255)
uint8_t Blue
Blue color (0-255)
uint8_t Green
Green color (0-255)
Font Object WMF manual 2.2.1.2 Warning, only pass by pointer, passing by value will will truncate in ...
int16_t Weight
LF_Weight Enumeration.
int16_t Escapement
Angle in 0.1 degrees betweem escapement vector and X axis.
uint8_t Italic
LF_Italic Enumeration.
int16_t Height
Height in Logical units.
uint8_t StrikeOut
LF_StrikeOut Enumeration.
uint8_t Underline
LF_Underline Enumeration.
Any generic pair of floats.
Pen Object WMF manual 2.2.1.4.
uint16_t Widthw[2]
reassemble/store the Pen Width in object dimensions using Widthw, the 32 bit value is not aligned
U_COLORREF Color
Pen Color, the 32 bit value is not aligned.
uint16_t Style
PenStyle Enumeration.
Rect Object WMF manual 2.2.2.18.
int16_t bottom
bottom coordinate
int16_t right
right coordinate
int16_t top
top coordinate
int16_t left
left coordinate
BitmapInfoHeader Object WMF manual 2.2.2.3 Same as "EMF BITMAPINFOHEADER Object" in uemf....
uint16_t Style
BrushStyle Enumeration.
U_COLORREF Color
Brush Color value, 32 bit value is not aligned.
uint16_t Hatch
HatchStyle Enumeration.
WMF manual 2.3.2.3 META_PLACEABLE If present this must immediately precede the header.
uint16_t Inch
Logical units/inch (convention if not specified: 1440 logical units/inch)
U_RECT16 Dst
Destination bounding box in logical units.
@ SP_STROKE_LINEJOIN_MITER
@ SP_STROKE_LINEJOIN_BEVEL
@ SP_STROKE_LINEJOIN_ROUND
@ SP_CSS_FONT_STYLE_NORMAL
@ SP_CSS_FONT_STYLE_OBLIQUE
@ SP_CSS_FONT_STYLE_ITALIC
@ SP_STROKE_LINECAP_SQUARE
@ SP_STROKE_LINECAP_ROUND
@ SP_CSS_FONT_WEIGHT_LIGHTER
@ SP_CSS_FONT_WEIGHT_NORMAL
@ SP_CSS_FONT_WEIGHT_BOLD
@ SP_CSS_FONT_WEIGHT_BOLDER
Geom::PathVector sp_svg_read_pathv(char const *str)
static void sp_svg_write_path(Inkscape::SVG::PathString &str, Geom::Path const &p, bool normalize=false)
Enhanced Metafile Input/Output.
int NonToUnicode(uint32_t *text, char *font)
void msdepua(uint32_t *text)
void TableGen(bool symb, bool wing, bool zdng, bool pua)
int trinfo_load_qe(TR_INFO *tri, double qe)
TR_INFO * trinfo_init(TR_INFO *tri)
char * TR_construct_fontspec(const TCHUNK_SPECS *tsp, const char *fontname)
int TR_layout_analyze(TR_INFO *tri)
int trinfo_load_bk(TR_INFO *tri, int usebk, TRCOLORREF bkcolor)
void TR_layout_2_svg(TR_INFO *tri)
TR_INFO * trinfo_clear(TR_INFO *tri)
TR_INFO * trinfo_release_except_FC(TR_INFO *tri)
int trinfo_load_ft_opts(TR_INFO *tri, int use_kern, int load_flags, int kern_mode)
int TR_findcasesub(const char *string, const char *sub)
int trinfo_load_textrec(TR_INFO *tri, const TCHUNK_SPECS *tsp, double escapement, int flags)
int ftinfo_load_fontname(FT_INFO *fti, const char *fontspec)
char * U_strdup(const char *s)
uint32_t * U_Latin1ToUtf32le(const char *src, size_t max, size_t *len)
char * U_Utf32leToUtf8(const uint32_t *src, size_t max, size_t *len)
@ U_WMR_PAINTREGION
0x012B U_WMRPAINTREGION record
@ U_WMR_CREATEPATTERNBRUSH
0x01F9 U_WMRCREATEPATTERNBRUSH record
@ U_WMR_C1
0x00C1 U_WMRC1 record
@ U_WMR_POLYGON
0x0324 U_WMRPOLYGON record
@ U_WMR_4F
0x004F U_WMR4F record
@ U_WMR_ED
0x00ED U_WMRED record
@ U_WMR_59
0x0059 U_WMR59 record
@ U_WMR_47
0x0047 U_WMR47 record
@ U_WMR_86
0x0086 U_WMR86 record
@ U_WMR_80
0x0080 U_WMR80 record
@ U_WMR_D4
0x00D4 U_WMRD4 record
@ U_WMR_RECTANGLE
0x041B U_WMRRECTANGLE record
@ U_WMR_INTERSECTCLIPRECT
0x0416 U_WMRINTERSECTCLIPRECT record
@ U_WMR_SETROP2
0x0104 U_WMRSETROP2 record
@ U_WMR_OFFSETCLIPRGN
0x0220 U_WMROFFSETCLIPRGN record
@ U_WMR_AD
0x00AD U_WMRAD record
@ U_WMR_EOF
0x0000 U_WMREOF record
@ U_WMR_91
0x0091 U_WMR91 record
@ U_WMR_3E
0x003E U_WMR3E record
@ U_WMR_DB
0x00DB U_WMRDB record
@ U_WMR_92
0x0092 U_WMR92 record
@ U_WMR_AF
0x00AF U_WMRAF record
@ U_WMR_84
0x0084 U_WMR84 record
@ U_WMR_SCALEVIEWPORTEXT
0x0412 U_WMRSCALEVIEWPORTEXT record
@ U_WMR_B2
0x00B2 U_WMRB2 record
@ U_WMR_DA
0x00DA U_WMRDA record
@ U_WMR_6E
0x006E U_WMR6E record
@ U_WMR_7C
0x007C U_WMR7C record
@ U_WMR_64
0x0064 U_WMR64 record
@ U_WMR_87
0x0087 U_WMR87 record
@ U_WMR_E8
0x00E8 U_WMRE8 record
@ U_WMR_FRAMEREGION
0x0429 U_WMRFRAMEREGION record
@ U_WMR_PATBLT
0x061D U_WMRPATBLT record
@ U_WMR_A2
0x00A2 U_WMRA2 record
@ U_WMR_C8
0x00C8 U_WMRC8 record
@ U_WMR_72
0x0072 U_WMR72 record
@ U_WMR_3A
0x003A U_WMR3A record
@ U_WMR_DIBCREATEPATTERNBRUSH
0x0142 U_WMRDIBCREATEPATTERNBRUSH record
@ U_WMR_F2
0x00F2 U_WMRF2 record
@ U_WMR_C5
0x00C5 U_WMRC5 record
@ U_WMR_9E
0x009E U_WMR9E record
@ U_WMR_53
0x0053 U_WMR53 record
@ U_WMR_67
0x0067 U_WMR67 record
@ U_WMR_A8
0x00A8 U_WMRA8 record
@ U_WMR_51
0x0051 U_WMR51 record
@ U_WMR_EB
0x00EB U_WMREB record
@ U_WMR_SELECTPALETTE
0x0234 U_WMRSELECTPALETTE record
@ U_WMR_6F
0x006F U_WMR6F record
@ U_WMR_7F
0x007F U_WMR7F record
@ U_WMR_C6
0x00C6 U_WMRC6 record
@ U_WMR_55
0x0055 U_WMR55 record
@ U_WMR_F6
0x00F6 U_WMRF6 record
@ U_WMR_5B
0x005B U_WMR5B record
@ U_WMR_AB
0x00AB U_WMRAB record
@ U_WMR_63
0x0063 U_WMR63 record
@ U_WMR_D9
0x00D9 U_WMRD9 record
@ U_WMR_SETMAPPERFLAGS
0x0231 U_WMRSETMAPPERFLAGS record
@ U_WMR_E6
0x00E6 U_WMRE6 record
@ U_WMR_3D
0x003D U_WMR3D record
@ U_WMR_76
0x0076 U_WMR76 record
@ U_WMR_DIBBITBLT
0x0940 U_WMRDIBBITBLT record
@ U_WMR_CE
0x00CE U_WMRCE record
@ U_WMR_9A
0x009A U_WMR9A record
@ U_WMR_EE
0x00EE U_WMREE record
@ U_WMR_44
0x0044 U_WMR44 record
@ U_WMR_7A
0x007A U_WMR7A record
@ U_WMR_70
0x0070 U_WMR70 record
@ U_WMR_4A
0x004A U_WMR4A record
@ U_WMR_B4
0x00B4 U_WMRB4 record
@ U_WMR_D1
0x00D1 U_WMRD1 record
@ U_WMR_E9
0x00E9 U_WMRE9 record
@ U_WMR_56
0x0056 U_WMR56 record
@ U_WMR_8A
0x008A U_WMR8A record
@ U_WMR_A5
0x00A5 U_WMRA5 record
@ U_WMR_EXTTEXTOUT
0x0A32 U_WMREXTTEXTOUT record
@ U_WMR_61
0x0061 U_WMR61 record
@ U_WMR_SETTEXTCOLOR
0x0209 U_WMRSETTEXTCOLOR record
@ U_WMR_8E
0x008E U_WMR8E record
@ U_WMR_71
0x0071 U_WMR71 record
@ U_WMR_88
0x0088 U_WMR88 record
@ U_WMR_6B
0x006B U_WMR6B record
@ U_WMR_8D
0x008D U_WMR8D record
@ U_WMR_C7
0x00C7 U_WMRC7 record
@ U_WMR_83
0x0083 U_WMR83 record
@ U_WMR_SETWINDOWEXT
0x020C U_WMRSETWINDOWEXT record
@ U_WMR_90
0x0090 U_WMR90 record
@ U_WMR_A1
0x00A1 U_WMRA1 record
@ U_WMR_INVERTREGION
0x012A U_WMRINVERTREGION record
@ U_WMR_B9
0x00B9 U_WMRB9 record
@ U_WMR_C3
0x00C3 U_WMRC3 record
@ U_WMR_SETDIBTODEV
0x0D33 U_WMRSETDIBTODEV record
@ U_WMR_D8
0x00D8 U_WMRD8 record
@ U_WMR_SETBKCOLOR
0x0201 U_WMRSETBKCOLOR record
@ U_WMR_ANIMATEPALETTE
0x0436 U_WMRANIMATEPALETTE record
@ U_WMR_3F
0x003F U_WMR3F record
@ U_WMR_SETWINDOWORG
0x020B U_WMRSETWINDOWORG record
@ U_WMR_BF
0x00BF U_WMRBF record
@ U_WMR_SETBKMODE
0x0102 U_WMRSETBKMODE record
@ U_WMR_POLYLINE
0x0325 U_WMRPOLYLINE record
@ U_WMR_9C
0x009C U_WMR9C record
@ U_WMR_SETTEXTALIGN
0x012E U_WMRSETTEXTALIGN record
@ U_WMR_F3
0x00F3 U_WMRF3 record
@ U_WMR_A9
0x00A9 U_WMRA9 record
@ U_WMR_AA
0x00AA U_WMRAA record
@ U_WMR_B6
0x00B6 U_WMRB6 record
@ U_WMR_BA
0x00BA U_WMRBA record
@ U_WMR_SETSTRETCHBLTMODE
0x0107 U_WMRSETSTRETCHBLTMODE record
@ U_WMR_68
0x0068 U_WMR68 record
@ U_WMR_77
0x0077 U_WMR77 record
@ U_WMR_5F
0x005F U_WMR5F record
@ U_WMR_9D
0x009D U_WMR9D record
@ U_WMR_BB
0x00BB U_WMRBB record
@ U_WMR_SETTEXTCHAREXTRA
0x0108 U_WMRSETTEXTCHAREXTRA record
@ U_WMR_E5
0x00E5 U_WMRE5 record
@ U_WMR_58
0x0058 U_WMR58 record
@ U_WMR_CREATEPALETTE
0x00F7 U_WMRCREATEPALETTE record
@ U_WMR_8F
0x008F U_WMR8F record
@ U_WMR_EF
0x00EF U_WMREF record
@ U_WMR_D7
0x00D7 U_WMRD7 record
@ U_WMR_MOVETO
0x0214 U_WMRMOVETO record
@ U_WMR_89
0x0089 U_WMR89 record
@ U_WMR_DF
0x00DF U_WMRDF record
@ U_WMR_6D
0x006D U_WMR6D record
@ U_WMR_STRETCHBLT
0x0B23 U_WMRSTRETCHBLT record
@ U_WMR_CREATEBITMAP
0x06FE U_WMRCREATEBITMAP record
@ U_WMR_E2
0x00E2 U_WMRE2 record
@ U_WMR_SETPOLYFILLMODE
0x0106 U_WMRSETPOLYFILLMODE record
@ U_WMR_85
0x0085 U_WMR85 record
@ U_WMR_4D
0x014D U_WMR4D record
@ U_WMR_4E
0x004E U_WMR4E record
@ U_WMR_FLOODFILL
0x0419 U_WMRFLOODFILL record
@ U_WMR_6C
0x006C U_WMR6C record
@ U_WMR_SETPIXEL
0x041F U_WMRSETPIXEL record
@ U_WMR_D3
0x00D3 U_WMRD3 record
@ U_WMR_5A
0x005A U_WMR5A record
@ U_WMR_79
0x0079 U_WMR79 record
@ U_WMR_49
0x0049 U_WMR49 record
@ U_WMR_DRAWTEXT
0x062F U_WMRDRAWTEXT record
@ U_WMR_OFFSETVIEWPORTORG
0x0211 U_WMROFFSETVIEWPORTORG record
@ U_WMR_C0
0x00C0 U_WMRC0 record
@ U_WMR_D0
0x00D0 U_WMRD0 record
@ U_WMR_AE
0x00AE U_WMRAE record
@ U_WMR_ESCAPE
0x0626 U_WMRESCAPE record
@ U_WMR_DE
0x00DE U_WMRDE record
@ U_WMR_PIE
0x081A U_WMRPIE record
@ U_WMR_TEXTOUT
0x0521 U_WMRTEXTOUT record
@ U_WMR_DELETEOBJECT
0x01F0 U_WMRDELETEOBJECT record
@ U_WMR_SELECTCLIPREGION
0x012C U_WMRSELECTCLIPREGION record
@ U_WMR_E7
0x00E7 U_WMRE7 record
@ U_WMR_EXTFLOODFILL
0x0548 U_WMREXTFLOODFILL record
@ U_WMR_BITBLT
0x0922 U_WMRBITBLT record
@ U_WMR_93
0x0093 U_WMR93 record
@ U_WMR_50
0x0050 U_WMR50 record
@ U_WMR_9F
0x009F U_WMR9F record
@ U_WMR_CF
0x00CF U_WMRCF record
@ U_WMR_DIBSTRETCHBLT
0x0B41 U_WMRDIBSTRETCHBLT record
@ U_WMR_RESTOREDC
0x0127 U_WMRRESTOREDC record
@ U_WMR_95
0x0095 U_WMR95 record
@ U_WMR_STRETCHDIB
0x0F43 U_WMRSTRETCHDIB record
@ U_WMR_5C
0x005C U_WMR5C record
@ U_WMR_SELECTOBJECT
0x012D U_WMRSELECTOBJECT record
@ U_WMR_SETMAPMODE
0x0103 U_WMRSETMAPMODE record
@ U_WMR_99
0x0099 U_WMR99 record
@ U_WMR_DC
0x00DC U_WMRDC record
@ U_WMR_7E
0x007E U_WMR7E record
@ U_WMR_D6
0x00D6 U_WMRD6 record
@ U_WMR_CREATEREGION
0x06FF U_WMRCREATEREGION record
@ U_WMR_7B
0x007B U_WMR7B record
@ U_WMR_BD
0x00BD U_WMRBD record
@ U_WMR_8C
0x008C U_WMR8C record
@ U_WMR_96
0x0096 U_WMR96 record
@ U_WMR_45
0x0045 U_WMR45 record
@ U_WMR_F4
0x00F4 U_WMRF4 record
@ U_WMR_57
0x0057 U_WMR57 record
@ U_WMR_82
0x0082 U_WMR82 record
@ U_WMR_ROUNDRECT
0x061C U_WMRROUNDRECT record
@ U_WMR_5D
0x005D U_WMR5D record
@ U_WMR_97
0x0097 U_WMR97 record
@ U_WMR_D5
0x00D5 U_WMRD5 record
@ U_WMR_6A
0x006A U_WMR6A record
@ U_WMR_CA
0x00CA U_WMRCA record
@ U_WMR_CHORD
0x0830 U_WMRCHORD record
@ U_WMR_60
0x0060 U_WMR60 record
@ U_WMR_A3
0x00A3 U_WMRA3 record
@ U_WMR_C9
0x00C9 U_WMRC9 record
@ U_WMR_SETRELABS
0x0105 U_WMRSETRELABS record
@ U_WMR_A7
0x00A7 U_WMRA7 record
@ U_WMR_73
0x0073 U_WMR73 record
@ U_WMR_POLYPOLYGON
0x0538 U_WMRPOLYPOLYGON record
@ U_WMR_C2
0x00C2 U_WMRC2 record
@ U_WMR_EXCLUDECLIPRECT
0x0415 U_WMREXCLUDECLIPRECT record
@ U_WMR_C4
0x00C4 U_WMRC4 record
@ U_WMR_8B
0x008B U_WMR8B record
@ U_WMR_F5
0x00F5 U_WMRF5 record
@ U_WMR_A4
0x00A4 U_WMRA4 record
@ U_WMR_E4
0x00E4 U_WMRE4 record
@ U_WMR_F8
0x00F8 U_WMRF8 record
@ U_WMR_E3
0x00E3 U_WMRE3 record
@ U_WMR_F1
0x00F1 U_WMRF1 record
@ U_WMR_E1
0x00E1 U_WMRE1 record
@ U_WMR_B0
0x00B0 U_WMRB0 record
@ U_WMR_BE
0x00BE U_WMRBE record
@ U_WMR_SCALEWINDOWEXT
0x0410 U_WMRSCALEWINDOWEXT record
@ U_WMR_D2
0x00D2 U_WMRD2 record
@ U_WMR_CREATEBITMAPINDIRECT
0x02FD U_WMRCREATEBITMAPINDIRECT record
@ U_WMR_DD
0x00DD U_WMRDD record
@ U_WMR_EC
0x00EC U_WMREC record
@ U_WMR_3B
0x003B U_WMR3B record
@ U_WMR_81
0x0081 U_WMR81 record
@ U_WMR_CC
0x00CC U_WMRCC record
@ U_WMR_62
0x0062 U_WMR62 record
@ U_WMR_74
0x0074 U_WMR74 record
@ U_WMR_SETVIEWPORTORG
0x020D U_WMRSETVIEWPORTORG record
@ U_WMR_SETVIEWPORTEXT
0x020E U_WMRSETVIEWPORTEXT record
@ U_WMR_A0
0x00A0 U_WMRA0 record
@ U_WMR_65
0x0065 U_WMR65 record
@ U_WMR_54
0x0054 U_WMR54 record
@ U_WMR_EA
0x00EA U_WMREA record
@ U_WMR_B1
0x00B1 U_WMRB1 record
@ U_WMR_B5
0x00B5 U_WMRB5 record
@ U_WMR_B7
0x00B7 U_WMRB7 record
@ U_WMR_LINETO
0x0213 U_WMRLINETO record
@ U_WMR_98
0x0098 U_WMR98 record
@ U_WMR_SETPALENTRIES
0x0037 U_WMRSETPALENTRIES record
@ U_WMR_BC
0x00BC U_WMRBC record
@ U_WMR_CD
0x00CD U_WMRCD record
@ U_WMR_SAVEDC
0x001E U_WMRSAVEDC record
@ U_WMR_94
0x0094 U_WMR94 record
@ U_WMR_AC
0x00AC U_WMRAC record
@ U_WMR_3C
0x003C U_WMR3C record
@ U_WMR_RESIZEPALETTE
0x0139 U_WMRRESIZEPALETTE record
@ U_WMR_69
0x0069 U_WMR69 record
@ U_WMR_ARC
0x0817 U_WMRARC record
@ U_WMR_52
0x0052 U_WMR52 record
@ U_WMR_75
0x0075 U_WMR75 record
@ U_WMR_7D
0x007D U_WMR7D record
@ U_WMR_9B
0x009B U_WMR9B record
@ U_WMR_CREATEFONTINDIRECT
0x02FB U_WMRCREATEFONTINDIRECT record
@ U_WMR_FILLREGION
0x0228 U_WMRFILLREGION record
@ U_WMR_CREATEBRUSHINDIRECT
0x02FC U_WMRCREATEBRUSHINDIRECT record
@ U_WMR_REALIZEPALETTE
0x0035 U_WMRREALIZEPALETTE record
@ U_WMR_CREATEPENINDIRECT
0x02FA U_WMRCREATEPENINDIRECT record
@ U_WMR_46
0x0046 U_WMR46 record
@ U_WMR_B3
0x00B3 U_WMRB3 record
@ U_WMR_5E
0x005E U_WMR5E record
@ U_WMR_78
0x0078 U_WMR78 record
@ U_WMR_4B
0x004B U_WMR4B record
@ U_WMR_SETTEXTJUSTIFICATION
0x020A U_WMRSETTEXTJUSTIFICATION record
@ U_WMR_ELLIPSE
0x0418 U_WMRELLIPSE record
@ U_WMR_A6
0x00A6 U_WMRA6 record
@ U_WMR_4C
0x014C U_WMR4C record
@ U_WMR_66
0x0066 U_WMR66 record
@ U_WMR_OFFSETWINDOWORG
0x020F U_WMROFFSETWINDOWORG record
@ U_WMR_E0
0x00E0 U_WMRE0 record
@ U_WMR_B8
0x00B8 U_WMRB8 record
@ U_WMR_CB
0x00CB U_WMRCB record
Windows Metafile Input/Output.