soimy / msdf-bmfont-xml

Generate BMFont texture and spec XML using msdfgen

Home Page:https://soimy.github.io/msdf-bmfont-xml/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Misc Enhancement Suggestions

PrimaryFeather opened this issue · comments

After using the command line tool for a while, I have to repeat I'm extremely grateful that you created it — hands-down the best way to create distance field bitmap fonts!!

I ran into a few minor things that caused me a little more work than would probably be necessary. This issue contains suggestions for small changes that seem to make sense for me. Perhaps one or more of them can be implemented in the future.

Enhancement ideas:

Enhance tool output

When the command line tool runs, it shows the following output:

Using following settings
========================================
version         : msdf-bmfont-xml v2.3.0
outputType      : xml
filename        : temp/fonts.png
fontSize        : undefined
charsetFile     : charset.txt
textureSize     : undefined
texturePadding  : undefined
distanceRange   : undefined
fieldType       : undefined
roundDecimal    : 0
vector          : undefined
reuse           : true
tolerance       : 0
smartSize       : true
pot             : undefined
square          : undefined
========================================

The string "undefined" is used whenever a setting was not assigned by the user.
It would be useful to show the actual value that is used in that case (i.e. the default value of that setting).

Allow manually naming config file

When the command line tool is run with the --reuse option and the specified file is not found, the process is aborted. Instead, it would be better if that file name would then be used as name of the config file that's created.

Omit .0

Oftentimes, there will be only one PNG file in the output. In that case, it would be useful if you omitted the .0 suffix. It makes it a little hard to use the tool in a script, for example, because you can only guess the output name.

Ignore 'new line' characters in charset file

It's useful to group characters into multiple lines in the charset files. However, this means that the newline character is added to the font XML file, which is not desired.

Fix typo in command line output

Replace "genrating" with "generating" ;)

Thanks for such detailed review and suggestions! I'll be working on these issues soon.
Currently, I'm working on rewrite this tool and all its sub-modules in typescript (learning typescript) and will have some major change in the structure of this tool.

Close via 9b689dc

Wonderful, thanks a lot! 😄

You are welcome 🍺 Still need some testing on different platform, then I'll push new version to npm