diff --git a/assets/icons/dc-cap-butt.svg b/assets/icons/dc-cap-butt.svg
index bf39a170a6..dee85e09a0 100644
--- a/assets/icons/dc-cap-butt.svg
+++ b/assets/icons/dc-cap-butt.svg
@@ -1 +1 @@
-
+
diff --git a/assets/icons/dc-cap-round.svg b/assets/icons/dc-cap-round.svg
index 06af9d07ea..bcf2e976c4 100644
--- a/assets/icons/dc-cap-round.svg
+++ b/assets/icons/dc-cap-round.svg
@@ -1 +1 @@
-
+
diff --git a/assets/icons/dc-cap-square.svg b/assets/icons/dc-cap-square.svg
index 4a82a10d9a..5fcb2e3c5d 100644
--- a/assets/icons/dc-cap-square.svg
+++ b/assets/icons/dc-cap-square.svg
@@ -1 +1 @@
-
+
diff --git a/crates/ui-egui/src/icons.rs b/crates/ui-egui/src/icons.rs
index 6a6c34a5e6..30b6edfb49 100644
--- a/crates/ui-egui/src/icons.rs
+++ b/crates/ui-egui/src/icons.rs
@@ -207,6 +207,39 @@ mod tests {
assert!(appearance.contains(" String {
+ let last = icon.rsplit(" f32 {
+ icon.split(r#"fill-opacity=""#).nth(1).and_then(|s| s.split('"').next()).and_then(|v| v.parse().ok()).unwrap_or(1.0)
+ };
+ let icons = [("butt", svg("dc-cap-butt")), ("round", svg("dc-cap-round")), ("square", svg("dc-cap-square"))];
+ let butt_end = end_line(&icons[0].1);
+ assert!(butt_end.starts_with('M') && butt_end.contains('V'), "the butt cap icon ends with a vertical end-of-path line: {butt_end}");
+ for (name, icon) in &icons {
+ assert_eq!(end_line(icon), butt_end, "the {name} cap icon marks the end of the path where the butt cap icon does");
+ assert!(stroke_opacity(icon) < 1.0, "the {name} cap icon's stroke is lighter than its end-of-path line");
+ }
+ // The stroke bar, everything before the end-of-path line, shows each cap differently.
+ let bar = |icon: &str| -> String { icon.rsplit_once("