feat(annotation): show all scales on highlight

This commit is contained in:
Hakan Seven 2026-08-02 14:37:12 +03:00
commit baf9b240a4
3 changed files with 238 additions and 3 deletions

View file

@ -1485,6 +1485,10 @@ pub struct Scene {
/// id — one slot would thrash between them every frame.
sdf_text_cache:
RefCell<HashMap<u64, std::sync::Arc<Vec<crate::scene::pipeline::text_gpu::TextVertex>>>>,
/// Extra scale representations for highlighted annotative entities. These
/// stay outside the resident wire set so rollover and selection never
/// invalidate normal geometry, picking, or snapping caches.
annotation_highlight_cache: RefCell<HashMap<u64, Arc<Vec<WireModel>>>>,
/// Per wire-source `(geometry_epoch, gathered text)` of the most recent
/// SDF-text build. When a new content id misses the cache but the journal
/// shows no text-bearing entity changed since that epoch, the same glyphs
@ -1915,6 +1919,7 @@ impl Scene {
}]),
active_model_tile: std::cell::Cell::new(0),
sdf_text_cache: RefCell::new(HashMap::default()),
annotation_highlight_cache: RefCell::new(HashMap::default()),
last_sdf_text: RefCell::new(HashMap::default()),
// One pane mapped to tile 0 — matches the single default tile above.
model_panes: iced::widget::pane_grid::State::new(0).0,