Skip to main content
egoltzman
Senior
June 2, 2020
Question

Binary fonts does not generated after the first time

  • June 2, 2020
  • 5 replies
  • 954 views

Hi,

I set the binary option in the designer (4.13) and successfully generated the bin files. I then unset the option and generate again the fonts fileד. All this session worked as expected.

Now, after a while, in the same project, I set the binary option again but this time the bin directory was not created.

Any idea?

Thanks

This topic has been closed for replies.

5 replies

Martin KJELDSEN
Principal III
June 2, 2020

Are you sure it wasn't just deleted? Using binary fonts is a bit convoluted at the moment and we're working on a better solution - We've got a script that can generate glyphs without using the excel sheet. When you uncheck the "binary" option you need to store the generated bin file before re-generating.

egoltzman
egoltzmanAuthor
Senior
June 2, 2020

Since the project includes various fonts and only one of the fonts need to be use as a cached binary font we did the following:

  • Set the binary font option
  • Generated fonts
  • Copy the binary fonts to a safe place out of the project tree
  • copy the font source to a safe place out of the project tree.
  • unset the binary font option
  • Regenerate the fonts
  • Replace the source of the Table_fontname_4bpp.cpp with the one from the safe place mention above that is actually an empty font table.
  • Replace the source of the Kerning_fontname_4bpp.cpp as well
  • Delete all the Font_fontname_4bpp_*.cpp
  • Add support in the code for loading the binary font and use it as fontname.

Now, in that stage, if I want to repeat the process, maybe with another font from the project, and I set the binary font option and generate I can't get the bin directory again any more.

Martin KJELDSEN
Principal III
June 3, 2020

Okay, i'll try out your flow when i can! Thanks

/Martin

egoltzman
egoltzmanAuthor
Senior
August 18, 2020

Hi Martin,

In another 4.13 project that is up and running without binary option set I need to add the binary font option.

I set the binary fonts option in the designer, generated the code rebuild and the bin directory is created but it is empty, any idea what could be wrong?

Thanks,

Eyal

egoltzman
egoltzmanAuthor
Senior
August 18, 2020

I can see that if the bin directory exist the binary fonts are created into it