1349 {
1350 if (el.hasAttribute("fill")) {
1351 if (el.attribute("fill") != "none") {
1352 QColor c = QColor(el.attribute("fill"));
1353
1354 styleDict["/FillFlag"] = true;
1355 styleDict["/FillColor"] = QVariantHash({ {"/StreamTag", "/SimplePaint"},
1356 { "/Color", QVariantHash({
1357 {"/Type", 1},
1358 {"/Values", QVariantList({1.0, c.redF(), c.greenF(), c.blueF()})
1359 }})}
1360 });
1361 } else {
1362 styleDict["/FillFlag"] = false;
1363 }
1364 }
1365 if (el.hasAttribute("stroke")) {
1366 if (el.attribute("stroke") != "none" && el.attribute("stroke-width").toDouble() != 0) {
1367 QColor c = QColor(el.attribute("stroke"));
1368
1369 styleDict["/StrokeFlag"] = true;
1370 styleDict["/StrokeColor"] = QVariantHash({ {"/StreamTag", "/SimplePaint"},
1371 { "/Color", QVariantHash({
1372 {"/Type", 1},
1373 {"/Values", QVariantList({1.0, c.redF(), c.greenF(), c.blueF()})
1374 }})}
1375 });
1376 } else {
1377 styleDict["/StrokeFlag"] = false;
1378 }
1379 }
1380 if (el.hasAttribute("stroke-linejoin")) {
1381 QString val = el.attribute("stroke-linejoin");
1382 if (val == "miter") {
1383 styleDict["/LineJoin"] = 0;
1384 } else if (val == "round") {
1385 styleDict["/LineJoin"] = 1;
1386 } else if (val == "bevel") {
1387 styleDict["/LineJoin"] = 2;
1388 }
1389 }
1390 if (el.hasAttribute("stroke-linecap")) {
1391 QString val = el.attribute("stroke-linecap");
1392 if (val == "butt") {
1393 styleDict["/LineCap"] = 0;
1394 } else if (val == "round") {
1395 styleDict["/LineCap"] = 1;
1396 } else if (val == "square") {
1397 styleDict["/LineCap"] = 2;
1398 }
1399 }
1400 if (el.hasAttribute("stroke-width") && el.attribute("stroke-width").toDouble() != 0) {
1401 styleDict["/LineWidth"] = el.attribute("stroke-width").toDouble();
1402 }
1403}