nico_font_tool

A tool for converting fonts to NICO Game Framework format fonts.

Pure Nim score 15/100 · tests present · no docs generated

Summary

Latest Version 0.0.2
License MIT
CI Status Failing
Downloads 0
Last Indexed 2026-07-21 05:25

Tags

Authors

  • TakWolf

Installation

nimble install nico_font_tool
choosenim install nico_font_tool
git clone https://github.com/TakWolf/nico-font-tool

OS Compatibility

Platform Linux macOS Windows FreeBSD OpenBSD NetBSD Android iOS WASM Embedded
nico_font_tool - - - - - - -

Dependencies

Package Version Optional
nim >= 1.4.0 No
pixie >= 5.0.6 No
nimPNG >= 0.3.2 No

Source

Repository https://github.com/TakWolf/nico-font-tool
Homepage https://github.com/TakWolf/nico-font-tool
Registry Source nimble_official

README

NICO Font tool

A tool for converting fonts to NICO Game Framework format fonts.

There is also a Python version see: nico-font-tool.python.

Installation

nimble install nico_font_tool

Usage

Command

For example:

nicofont ./assets/fonts/quan/quan.ttf ./examples/assets/fonts/demo quan --fontSize=8

All params:

nicofont {fontFilePath} {outputsDir} {outputsName}

options:
  -fs, --fontSize
      Glyph rasterize size when using OpenType font.
  -gox, --glyphOffsetX
      Glyph offset x.
  -goy, --glyphOffsetY
      Glyph offset y.
  -gaw, --glyphAdjustWidth
      Glyph adjust width.
  -gah, --glyphAdjustHeight
      Glyph adjust height.
  -m, --mode
      Png sheet color mode, can be 'palette' or 'rgba', default is 'palette'.

Scripts

See: gen_fonts

import nico_font_tool

let (sheetData, alphabet) = createSheet("your/font/file/path.ttf", 8)

savePalettePng(sheetData, "outputs/palette/dir", "outputsName")
saveDatFile(alphabet, "outputs/palette/dir", "outputsName")

saveRgbaPng(sheetData, "outputs/rgba/dir", "outputsName")
saveDatFile(alphabet, "outputs/rgba/dir", "outputsName")

Dependencies

License

Under the MIT license.