mojira.dev
MC-277677

Invalid font characters remember their width and the placeholder glyph incorrectly uses it

Discovered while testing MC-277670.

The bug

If an invalid texture is used for a text character, the missing glyph will replace it. However, the character will still behave as though it has the expected size from the provided texture file.

How to reproduce

A resource pack is attached to this ticket that replaces "A" with a 257-wide, 1-high texture, and "a" with a 1-wide, 257-high texture. Both of these exceed the maximum dimensions for a font character.

  1. Download and apply the attached resource pack

  2. Observe the letters "A" and "a" in context

  3. Optionally compare to a character with no defined glyph: 

Expected results

These would appear as normal missing glyphs.

Actual results

"A" causes a huge gap after itself, and "a" bleeds into the next character.

How to fix

When making these use the missing glyph, it should also set the dimensions to the correct value.

Attachments

Comments 2

Thank you for your report!
After consideration, the issue is being closed as Won't Fix.

Please note that this is not the same as Working as Intended, as this bug report correctly describes behavior in the game that might not be the intended or desirable behavior, but it will not be fixed right now. Sometimes, this is because the issue reported is minor and/or impossible to change without large architectural changes to the code base.

Quick Links:
📓 Bug Tracker Guidelines – 💬 Community Support – 📧 Mojang Support (Technical Issues) – 📧 Microsoft Support (Account Issues)
📓 Project Summary – ✍️ Feedback and Suggestions – 📖 Game Wiki

muzikbike

(Unassigned)

Community Consensus

Resource Packs

1.21.2 Release Candidate 1

Retrieved