]> granicus.if.org Git - graphviz/commitdiff
tests: GraphvizEdge: handle primitive arrow shape 'dot' in arrowtail_outline_bbox
authorMagnus Jacobsson <Magnus.Jacobsson@berotec.se>
Wed, 5 Oct 2022 20:28:14 +0000 (22:28 +0200)
committerMagnus Jacobsson <Magnus.Jacobsson@berotec.se>
Tue, 18 Oct 2022 18:58:25 +0000 (20:58 +0200)
tests/graphviz_edge.cpp

index 72754195eeac69e9b54a50bc5d57af9543e6043c..6f7a36a564a8df962c4cb6b92d1ce320dead6fa0 100644 (file)
@@ -87,8 +87,10 @@ SVG::SVGRect GraphvizEdge::arrowtail_outline_bbox(
                     primitive_arrow_shape)};
   }
   const auto index = 0;
+  const auto main_svg_element_type =
+      edge_arrowhead_main_svg_element_type(primitive_arrow_shape);
   auto edge_arrowtail =
-      m_svg_g_element.find_child(SVG::SVGElementType::Polygon, index);
+      m_svg_g_element.find_child(main_svg_element_type, index);
   auto edge_arrowtail_bbox = edge_arrowtail.outline_bbox();
   if (primitive_arrow_shape == "box") {
     auto edge_arrowtail_stem =