Skip to main content

Module view

Module view 

Source

Structs§

Canvas
One canvas frame as the pointer left it: the rect it was laid out in, the moves it read for the session to apply, and the raw input the session resolves. A value rather than a borrow of the view, so the frame can call the editor between reading its input and painting.
CanvasChrome
The colours the canvas paints its own ground with, under the canvas’s own name for them. The two raw colours a backend paints the ground with. The app resolves these from its theme, so a backend never needs to know about roles.
Diagram
What a call answered for the canvas: the display list, the camera it was painted under, the colours under it, and the cursor it left.
Draft 🔒
The draft the editor holds between frames: egui’s field edits a buffer the caller keeps.
View
The canvas as egui shows it: the rect it is laid out in, the pointer and the gestures over it, and the in-place editor drawn into it. Where the diagram is shown from is the session’s; this reads what would move it and reports the move.

Enums§

Camera
Whether the camera is being worked — a drag pan, or a two-finger pan/pinch in flight.

Functions§

button_of 🔒
editor_frame 🔒
The field as an opaque plate ringed in the editor’s border, so it reads as standing over the drawing rather than as more of it. Its geometry is the one the kernel sized the field by.
grid_stroke 🔒
keys 🔒
The keys the frame carries, scoped by who holds the keyboard.
pan_key_held 🔒
Whether the key that turns a left-drag into a pan is held: space, the convention across drawing and diagram editors (Figma, Illustrator, Inkscape, Miro). A text editor owning the keyboard is typing, not panning.
tick
The frame clock as egui states it: the time, and how long it predicts the frame will take, which is what the easing table reads ahead by.