Compare commits

...
Author SHA1 Message Date
netcatty-bot 5c885c8441 fix(#3332): automated AI fix 2026-09-08 19:15:18 +00:00
2 changed files with 21 additions and 0 deletions

No files matched your search

+17
View File
@@ -63,6 +63,23 @@ describe('queryLocalFonts deduplication', () => {
);
});
it('recognizes Fixedsys Excelsior as a monospace terminal font (#3332)', async () => {
installMockWindow(async () => [
{ family: 'Fixedsys Excelsior 3.01' },
{ family: 'Fixedsys Excelsior' },
{ family: 'Microsoft YaHei UI' },
]);
const monoFonts = await getMonospaceFonts();
const names = monoFonts.map((f) => f.name);
// Both upstream family-name variants must be offered in the picker.
assert.ok(names.includes('Fixedsys Excelsior'));
assert.ok(names.includes('Fixedsys Excelsior 3.01'));
// Proportional system fonts stay excluded.
assert.ok(!names.includes('Microsoft YaHei UI'));
});
it('a second sequential call also reuses the resolved promise (no second API call)', async () => {
let callCount = 0;
installMockWindow(async () => {
+4
View File
@@ -57,6 +57,10 @@ const KNOWN_MONOSPACE_FONTS = new Set([
'meslolgs nf',
'symbols nerd font mono',
'symbols nerd font',
// Fixedsys / Fixedsys Excelsior — classic DOS-style bitmap-look
// monospace font; the community TrueType revival carries no mono
// suffix, so name-based detection would otherwise miss it (#3332).
'fixedsys',
]);
/**