Skip to main content

Crate oxitext_shape

Crate oxitext_shape 

Source
Expand description

oxitext-shape — Swash-based text shaper for OxiText.

Provides SwashShaper, which wraps swash’s ShapeContext and produces ShapedRuns from UTF-8 text + raw font bytes.

M1: LTR Latin shaping. Bidi (M2) and script-specific itemisation (M3) are deferred.

§M3 additions

§M5 additions (Slice 5a)

§Feature-aware shaping (Slice 6)

Re-exports§

pub use backend::ShapeBackend;
pub use backend::SwashShaperBackend;
pub use cache::FontId;
pub use cache::ShapeCache;
pub use cache::ShapeKey;
pub use script_detect::requires_arabic_shaping;
pub use script_detect::requires_indic_shaping;
pub use script_detect::requires_mark_positioning;

Modules§

backend
Swappable text shaping backends.
batch
Batch shaping: shape multiple text segments in a single call.
cache
Bounded LRU shape cache for crate::SwashShaper.
script_detect
Script detection helpers for oxitext-shape.
variational
Variable font support and vertical shaping tests.

Structs§

ShapeFeature
An OpenType feature tag-value pair.
ShapeRequest
A complete shaping request with all parameters.
ShapeRequestBuilder
Builder for ShapeRequest.
ShapeResult
Extended shaping result with metadata.
SwashShaper
Text shaper backed by swash.

Enums§

ShapeDirection
Text direction for a shaping request.
ShapeRequestError
Errors that can occur when building a ShapeRequest.

Functions§

detect_emoji_zwj_sequences
Returns byte ranges in text that correspond to ZWJ-joined emoji sequences.
find_kashida_opportunities
Returns glyph indices (into glyphs) after which a kashida stretch can be inserted for Arabic justification.