Skip to content

Draw text with Twemoji on skia-canvas

License

Notifications You must be signed in to change notification settings

PolestarLabs/skia-canvas-twemoji

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

49 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

skia-canvas-twemoji

This is a module that is able to draw emoji on skia-canvas.

Quick Example

const { Canvas } = require('skia-canvas');
const { fillTextWithTwemoji } = require('@polestar/skia-canvas-twemoji');

async function main () {
    const canvas = new Canvas(200, 200);
    const context = canvas.getContext('2d');

    context.fillStyle = '#000000';
    context.font = '30px Arial';
    await fillTextWithTwemoji(context, 'emoji 🎀', 100, 100);
}

main();

Dependencies

Licence

skia-canvas-twemoji

Copyright (c) 2020-2021 cagpie / Shun Kobayashi cagpie@gmail.com, Polestar Labs labs@pollux.gg

Code licensed under the MIT License: http://opensource.org/licenses/MIT

About

Draw text with Twemoji on skia-canvas

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 100.0%