Skip to content

Commit

Permalink
Added a useful test/debug program.
Browse files Browse the repository at this point in the history
  • Loading branch information
sedwards2009 committed Jun 21, 2016
1 parent f492cb4 commit 6cd5bcf
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions src/test/list_fonts.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
const fontManager = require('font-manager');


const monofonts = fontManager.findFontsSync( { monospace: true}); //.map( (font) => font.path);

const fonts = fontManager.getAvailableFontsSync();
const monofonts2 = fonts.filter( (font) => font.monospace).map( (font) => font.path);

monofonts.sort();
monofonts2.sort();

console.log("[findFonts]-----------------");
console.log(JSON.stringify(monofonts, null, " "));
console.log("[getAvailableFonts & filter]-----------------");
// console.log(JSON.stringify(monofonts2, null, " "));

0 comments on commit 6cd5bcf

Please sign in to comment.