fix(viewport): adapt layout crosshair contrast

Choose the sheet or desk surface under the cursor instead of the active input space so MSPACE stays visible on light paper.\n\nRefs #611
This commit is contained in:
Hakan Seven committed 2026-07-31 23:47:41 +03:00
1 parent 1cf2b700ce
commit 9382a412df
4 files changed
+84 -5

No files matched your search

+7
View File
@@ -458,6 +458,7 @@ struct PaperViewportCache {
layout_block: Handle,
sheet: Handle,
content: Arc<Vec<Handle>>,
paper_limits: Option<((f64, f64), (f64, f64))>,
}
struct PaperSheetRenderCache {
@@ -3354,6 +3355,12 @@ impl Scene {
return None;
}
if let Some(cache) = self.paper_viewport_cache.borrow().get(&self.current_layout) {
if cache.epoch == self.geometry_epoch && cache.layout == self.current_layout {
return cache.paper_limits;
}
}
self.document
.objects
.values()