git.lucas.co / cce-fonts
font browser

commit18627803f92e42958d90d522863b2ae6186d9d40
parent51817d0453
authorLucas Galante <[email protected]>
date2026-06-28 10:01
Filter out root window background in flat all_quads to prevent flat overdraw

 src/main.rs | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/src/main.rs b/src/main.rs
index c426883..57f3ecf 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -832,7 +832,13 @@ impl Application for TypefaceApp {
         self.root_window.background_color = Some(bg_color);
 
         // Draw active containers and all child widgets (including panel plates)
-        quads.extend(self.root_window.all_quads(&self.ui_context));
+        let (rx, ry, rw, rh) = self.root_window.rect();
+        for (qx, qy, qw, qh, qc) in self.root_window.all_quads(&self.ui_context) {
+            if (qx - rx).abs() < 0.1 && (qy - ry).abs() < 0.1 && (qw - rw).abs() < 0.1 && (qh - rh).abs() < 0.1 {
+                continue;
+            }
+            quads.push((qx, qy, qw, qh, qc));
+        }
 
         // 5. Page Content Outline Borders
         // Left Panel Borders