parseTTF method

Future<PMFont> parseTTF(
  1. dynamic path
)

Use this method to convert a .ttf file into a PMFont object. It expects you to pass the path of the .ttf file as its only argument.

Implementation

Future<PMFont> parseTTF(path) {
  return File(path).readAsBytes().then((data) {
    fontData = ByteData.view(data.buffer);
    return _parseTTF();
  });
}