This package has been deprecated

Author message:

this package has been deprecated

jimpfont

0.0.6 • Public • Published
JimpFONT

JimpFONT

NPM version NPM downloads

npm installnfo

A Simple module for using .ttf font on Jimp

Installation

To use JimpFONT, install GraphicsMagick.

$ npm install jimpfont

Example usage

const Jimp = require("jimp");
const JimpFONT = require("jimpfont");
const jimpFONT = new JimpFONT();
 
new Jimp(80, 30, async(err, image) => {
    let text = await jimpFONT.CreateFont("Sworder", 80, 30, "./assets/fonts/Font.ttf", 20, "#FFFFFF"); //Text, width, height, path, size, HexaColor
    image.composite(text, 0, 0);
    image.getBuffer(Jimp.MIME_PNG,  async (err, buffer) => {
        if (err) console.log(err);
        return buffer; //Buffer
    });
});

Readme

Keywords

Package Sidebar

Install

npm i jimpfont

Weekly Downloads

35

Version

0.0.6

License

Apache-2.0

Unpacked Size

87.4 kB

Total Files

6

Last publish

Collaborators

  • npm