This exposes ShapePlan outside of the rustybuzz crate, and provides a new shape_with_plan function that takes in a ShapePlan instead of a list of user features.
Callers are expected to properly cache ShapePlans to avoid incorrect rendering due to mismatches between the ShapePlan and the provided buffer. To help avoid bugs due to mismatches, I added two debug_assert!() lines to verify that the plan and buffer use the same direction and script.
Given that ShapePlan is now public outside of the crate, I changed a number of pub specifiers to pub(crate) to maintain the same effective visibility.
This exposes
ShapePlan
outside of therustybuzz
crate, and provides a newshape_with_plan
function that takes in aShapePlan
instead of a list of user features.Callers are expected to properly cache
ShapePlan
s to avoid incorrect rendering due to mismatches between theShapePlan
and the provided buffer. To help avoid bugs due to mismatches, I added twodebug_assert!()
lines to verify that the plan and buffer use the same direction and script.Given that
ShapePlan
is now public outside of the crate, I changed a number ofpub
specifiers topub(crate)
to maintain the same effective visibility.