🔧 Refactor ParagraphBuilder and fix auto height

This commit is contained in:
Elena Torro 2025-07-11 13:29:22 +02:00
parent 4c21468850
commit b40b1fa2e4
9 changed files with 161 additions and 166 deletions

View file

@ -1,3 +1,4 @@
use crate::skia::textlayout::FontCollection;
use crate::skia::Image;
use crate::uuid::Uuid;
use crate::with_state_mut;
@ -31,3 +32,7 @@ pub fn get_image(image_id: &Uuid) -> Option<&Image> {
pub fn get_fallback_fonts() -> &'static HashSet<String> {
with_state_mut!(state, { state.render_state().fonts().get_fallback() })
}
pub fn get_font_collection() -> &'static FontCollection {
with_state_mut!(state, { state.font_collection() })
}