Skip to main content

Module drawing

Module drawing 

Source
Expand description

Logical drawing contracts and bounded rectangle/path fill commands.

Re-exports§

pub use crate::shape::Shape;
pub use crate::shape::Styled;
pub use mesh::MAX_MESH_POINTS_PER_AXIS;
pub use mesh::MAX_MESH_SUBDIVISIONS;
pub use mesh::MeshGradient;
pub use mesh::MeshImage;
pub use mesh::MeshPaint;
pub use mesh::MeshPatch;
pub use mesh::MeshVertex;
pub use paint::GradientExtend;
pub use paint::GradientSpace;
pub use paint::GradientUnits;
pub use paint::ImagePattern;
pub use paint::LinearGradient;
pub use paint::Paint;
pub use paint::PatternImage;
pub use paint::RadialGradient;
pub use paint::SweepGradient;
pub use paint::WeakPatternImage;

Modules§

mesh
Mesh gradients with analytic paint descriptors and explicit image baking.
paint
Gradient and static image-pattern descriptions.

Structs§

AtmospherePaint
Immutable, admitted atmospheric paint with explicit time and canvas coordinates.
AtmosphereParameters
Editable unvalidated atmospheric parameters; paint construction validates all fields.
Canvas
A bounded command recorder passed to content.
DrawContext
Drawing inputs for the frontend.
Evaluation
Time, quality and explicit resources for one evaluation.
PathClip
A checked path used as a coverage mask on an isolated subtree.
RectClip
A local rectangle whose transformed region intersects ancestor rectangles.
ShapeClip
A snapshotted Shape used for geometric intersection, not coverage multiplication.
StrokeStyle
logical-unit stroke style, with explicit caps, joins and dash geometry.

Enums§

AtmosphereKind
Spatial envelope applied to amplitude-normalized Perlin fractal noise.
BlendMode
Linear-light layer blending, with explicit compositing space.
BlendSpace
Color space used for compositing, independent of stored linear pixels.
ClipGeometry
Immutable rectangle or path geometry used to intersect geometric clipping domains.
ClipMode
How a subtree clip combines with its geometric ancestors.
DrawCommand
A fill or isolated-layer boundary; more primitives await their contracts.
FillRule
How closed contours determine the filled interior.
LineCap
Shape of the ends of an open stroke.
LineJoin
Connection between adjacent stroke segments.
MaskMode
How linear-premultiplied content becomes a layer’s mask coverage.
RenderQuality
Explicit preview approximation policy. Final preserves production rendering.

Constants§

MAX_STROKE_VERBS
Maximum input verbs in one path/curve stroke expansion.

Traits§

DeferredContent
Content that expands into ordinary nodes at the current drawing time.
Drawable
Content whose bounds and drawing share the same logical coordinates.
IntoShapeClip
Values accepted by crate::NodeModifiers::clip that convert to a ShapeClip.

Functions§

validate_rect
Rejects nonfinite/inverted corners or nonfinite spans; zero-area rectangles are valid.