Home > SYS_FontManager > getFontsList
SYS_FontManager.getFontsList() method
获取当前已经配置的字体列表
签名
typescript
function getFontsList(): Promise<Array<string>>;1
返回值
Promise<Array<string>>
字体列表
示例
javascript
// 1. 获取当前已配置的字体列表
const fonts = await eda.sys_FontManager.getFontsList();
// 2. 输出字体数量与全部字体名
console.log('字体数量:', fonts.length);
console.log('字体列表:', fonts.join('、'));1
2
3
4
5
6
2
3
4
5
6