From e828432f94fe68eda42b22ecc351be89af0ecc9f Mon Sep 17 00:00:00 2001 From: tophf Date: Wed, 25 Dec 2024 03:59:12 +0300 Subject: [PATCH] account for the UC length in name calc --- src/manage/render.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/manage/render.js b/src/manage/render.js index 799e898e23..d6e0e2b26e 100644 --- a/src/manage/render.js +++ b/src/manage/render.js @@ -226,6 +226,7 @@ export function fitNameColumn(styles, style) { function calcNameLenKey(style) { const name = style.displayName || style.name || ''; const len = 1e9 + // aligning the key for sort() which uses string comparison + (style[UCD] ? 4 : 0) + (style.enabled ? 1.05/*bold factor*/ : 1) * (name.length + name.replace(rxNonCJK, '').length/*CJK glyph is 2x wide*/) | 0; nameLengths.set(style.id, len);