Skip to content

Commit

Permalink
Fix text wrapping for rich_text
Browse files Browse the repository at this point in the history
  • Loading branch information
hecrj committed Jan 10, 2025
1 parent 664caf7 commit bffe572
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions graphics/src/text/paragraph.rs
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,8 @@ impl core::text::Paragraph for Paragraph {
Some(text.bounds.height),
);

buffer.set_wrap(font_system.raw(), text::to_wrap(text.wrapping));

buffer.set_rich_text(
font_system.raw(),
text.content.iter().enumerate().map(|(i, span)| {
Expand Down

0 comments on commit bffe572

Please sign in to comment.