Skip to content

Commit

Permalink
fix typsetter overflow check
Browse files Browse the repository at this point in the history
got the axes inverted. oops.
  • Loading branch information
bunnie committed Jul 5, 2023
1 parent ecb42c6 commit 17fb590
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion services/graphics-server/src/wordwrap.rs
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,7 @@ impl Typesetter {
// going out of scope at the end of the call.
let mut composition = Vec::<TypesetWord>::new();

if self.bb.max.y - self.bb.min.y < glyph_to_height_hint(GlyphStyle::Regular) as i16 {
if self.bb.max.x - self.bb.min.x < glyph_to_height_hint(GlyphStyle::Regular) as i16 {
// we flag this because the typesetter algorithm may never converge if it can't set any characters
// because the region is just too narrow.
log::error!("Words cannot be typset because the width of the typset region is too narrow.");
Expand Down

0 comments on commit 17fb590

Please sign in to comment.