question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

BitmapText using BitmapFont.from() doesn't include punctuation

See original GitHub issue

Thanks for all your hard work on this wonderful library and all the recent improvements to bitmap text.

Could be user error, but I can’t seem to get punctuation (have tried -,.&) to render when using a font declared with PIXI.BitmapFont.from(). I’ve set the chars value to the exact string used, a split array of that string and PIXI.BitmapFont.ASCII to no avail. Though I suspect the issue doesn’t lie with chars given that punctuation is rendering here.

I was able to render punctuation with preloaded bitmap fonts, so I think the bug may be limited to the PIXI.BitmapFont.from() method.

In addition, wanted to flag that 6.0.0 seems to break bitmap fonts entirely (at least with the js fiddle example linked here – I’m using 5.3.7 in the interim).

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
gwezerekcommented, Jan 8, 2021

Ahhhhhh, thank you! Appreciate the quick response.

1reaction
bigtimebuddycommented, Jan 8, 2021

Oh I see what it is. Fixed here: https://jsfiddle.net/bigtimebuddy/ah6pvm2o/

The problem is chars is part of the options, not style. http://pixijs.download/dev/docs/PIXI.BitmapFont.html#from

BitmapFont.from(name, style, options)
Read more comments on GitHub >

github_iconTop Results From Across the Web

BitmapText using BitmapFont.from() doesn't include punctuation
I was able to render punctuation with preloaded bitmap fonts, so I think the bug may be limited to the PIXI.BitmapFont.from() method. In ......
Read more >
Phaser 3 API Documentation - Class: BitmapText
BitmapText objects work by taking a texture file and an XML or JSON file that describes the font structure. During rendering for each...
Read more >
Using bitmap fonts - ct.js Documentation
Unless you need a font to display one word without spaces, you do need to check "Digits and punctuation" — it includes spaces,...
Read more >
new PIXI.BitmapText (text, style) - PixiJS
A BitmapText object will create a line or multiple lines of text using bitmap font. The primary advantage of this class over Text...
Read more >
How to use the BitmapFontTextRenderer component (Starling ...
The BitmapFontTextRenderer class renders text using bitmap fonts. BitmapFontTextRenderer is one of many different text renderers supported by Feathers. Since no ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found