summaryrefslogtreecommitdiffstats
path: root/svgbob/src/buffer/fragment_buffer/fragment/rect.rs
diff options
context:
space:
mode:
Diffstat (limited to 'svgbob/src/buffer/fragment_buffer/fragment/rect.rs')
-rw-r--r--svgbob/src/buffer/fragment_buffer/fragment/rect.rs8
1 files changed, 8 insertions, 0 deletions
diff --git a/svgbob/src/buffer/fragment_buffer/fragment/rect.rs b/svgbob/src/buffer/fragment_buffer/fragment/rect.rs
index 51f8481..a74cc6c 100644
--- a/svgbob/src/buffer/fragment_buffer/fragment/rect.rs
+++ b/svgbob/src/buffer/fragment_buffer/fragment/rect.rs
@@ -97,6 +97,14 @@ impl Rect {
pub(crate) fn is_broken(&self) -> bool {
self.is_broken
}
+
+ pub fn is_rounded(&self) -> bool {
+ if let Some(ref r) = &self.radius {
+ *r > 0.0
+ } else {
+ false
+ }
+ }
}
impl Bounds for Rect {