Improve viewport rulers by tilting tick marks to align with tilted documents (#3844)

* Add support for tilted rulers

* Fix Ruler Text

* Address PR review

* Fix per review

* Code review

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
This commit is contained in:
Kulcode
2026-05-01 17:01:43 +00:00
committed by Timon
co-authored by Keavon Chambers
parent 4474de4662
commit 4c1974c200
4 changed files with 116 additions and 34 deletions
@@ -244,6 +244,7 @@ pub enum FrontendMessage {
spacing: f64,
interval: f64,
visible: bool,
tilt: f64,
},
UpdateDocumentScrollbars {
position: (f64, f64),
@@ -843,6 +843,7 @@ impl MessageHandler<DocumentMessage, DocumentMessageContext<'_>> for DocumentMes
spacing: ruler_spacing,
interval: ruler_interval,
visible: self.rulers_visible,
tilt: if self.graph_view_overlay_open { 0. } else { current_ptz.tilt() },
});
}
DocumentMessage::RenderScrollbars => {