Modules§
- measurer
- 字符宽度表消费器,等价于 JS 版 CharWidthTableConsumer。 支持从 JSON 文件加载字体宽度表,区间二分查找字符宽度,字符串宽度计算,接口风格与 JS 保持一致。
Structs§
Enums§
Traits§
- Font
Metrics - 字体宽度计算 trait,主项目需实现并注入
Functions§
- default_
label_ color - default_
message_ color - get_
text_ width - 计算文本在 Verdana 11px 下的宽度(像素)
- render_
badge_ svg - 公开 API:生成 SVG 字符串