From ec91514656b32c8cbcedb4898b37c6120fd892a2 Mon Sep 17 00:00:00 2001 From: k_taka Date: Mon, 20 May 2024 17:37:33 +0900 Subject: [PATCH 1/3] Fix Japanese settings in scr/utils/fontList.ts --- src/utils/fontList.ts | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/utils/fontList.ts b/src/utils/fontList.ts index 8d3e7639b7..a1215e10f1 100644 --- a/src/utils/fontList.ts +++ b/src/utils/fontList.ts @@ -58,23 +58,23 @@ export const FONT_LIST: Font[] = const FONT_LIST_JA: Font[] = [{ id: "JA", - label: "日本語 SERIF (H)", + label: "日本語 明朝(横書き)", // eslint-disable-next-line quotes - fontFamily: `"MS P明朝", "MS PMincho", "Hiragino Mincho Pro", "ヒラギノ明朝 Pro W3", "游明朝", "YuMincho", "MS 明朝", "MS Mincho", "Hiragino Mincho ProN", serif`, + fontFamily: `"Hiragino Mincho ProN", "BIZ UDPMincho", "Yu Mincho", "MS PMincho", serif`, }, { id: "JA-SANS", - label: "日本語 SANS (H)", + label: "日本語 ゴシック(横書き)", // eslint-disable-next-line quotes - fontFamily: `"MS Pゴシック", "MS PGothic", "Hiragino Kaku Gothic Pro W3", "ヒラギノ角ゴ Pro W3", "Hiragino Sans GB", "ヒラギノ角ゴシック W3", "游ゴシック", "YuGothic", "MS ゴシック", "MS Gothic", "Hiragino Sans", sans-serif`, + fontFamily: `"Hiragino Kaku Gothic ProN", "Hiragino Sans W3", "Hiragino Sans", "BIZ UDPGothic", "Yu Gothic", "MS PGothic", sans-serif`, }, { id: "JA-V", - label: "日本語 SERIF (V)", + label: "日本語 明朝 (縦書き)", // eslint-disable-next-line quotes - fontFamily: `"MS 明朝", "MS Mincho", "Hiragino Mincho Pro", "ヒラギノ明朝 Pro W3", "游明朝", "YuMincho", "MS P明朝", "MS PMincho", "Hiragino Mincho ProN", serif`, + fontFamily: `"Hiragino Mincho ProN", "BIZ UDMincho", "Yu Mincho", "MS Mincho", serif`, }, { id: "JA-V-SANS", - label: "日本語 SANS (V)", + label: "日本語 ゴシック (縦書き)", // eslint-disable-next-line quotes - fontFamily: `"MS ゴシック", "MS Gothic", "Hiragino Kaku Gothic Pro W3", "ヒラギノ角ゴ Pro W3", "Hiragino Sans GB", "ヒラギノ角ゴシック W3", "游ゴシック", "YuGothic", "MS Pゴシック", "MS PGothic", "Hiragino Sans", sans-serif`, + fontFamily: `"Hiragino Kaku Gothic ProN", "Hiragino Sans W3", "Hiragino Sans", "BIZ UDGothic", "Yu Gothic", "MS Gothic", sans-serif`, }]; export const FONT_LIST_WITH_JA = FONT_LIST.concat(...FONT_LIST_JA); From 45460839dcc78fd0c5498d0fcffb85c62c20257d Mon Sep 17 00:00:00 2001 From: k_taka Date: Wed, 29 May 2024 20:31:44 +0900 Subject: [PATCH 2/3] Fix old fonts and font priority in macOS environments according to the pull request submitted to Readium-CSS. --- src/utils/fontList.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/utils/fontList.ts b/src/utils/fontList.ts index a1215e10f1..7341da4160 100644 --- a/src/utils/fontList.ts +++ b/src/utils/fontList.ts @@ -60,21 +60,21 @@ const FONT_LIST_JA: Font[] = id: "JA", label: "日本語 明朝(横書き)", // eslint-disable-next-line quotes - fontFamily: `"Hiragino Mincho ProN", "BIZ UDPMincho", "Yu Mincho", "MS PMincho", serif`, + fontFamily: `"Hiragino Mincho ProN", "Hiragino Mincho Pro", "YuMincho", "BIZ UDPMincho", "Yu Mincho", "MS P明朝", "MS PMincho", serif`, }, { id: "JA-SANS", label: "日本語 ゴシック(横書き)", // eslint-disable-next-line quotes - fontFamily: `"Hiragino Kaku Gothic ProN", "Hiragino Sans W3", "Hiragino Sans", "BIZ UDPGothic", "Yu Gothic", "MS PGothic", sans-serif`, + fontFamily: `"Hiragino Sans", "Hiragino Kaku Gothic ProN", "Hiragino Kaku Gothic Pro", "ヒラギノ角ゴ W3", "YuGothic", "BIZ UDPGothic", "Yu Gothic", "MS Pゴシック", "MS PGothic", sans-serif`, }, { id: "JA-V", label: "日本語 明朝 (縦書き)", // eslint-disable-next-line quotes - fontFamily: `"Hiragino Mincho ProN", "BIZ UDMincho", "Yu Mincho", "MS Mincho", serif`, + fontFamily: `"Hiragino Mincho ProN", "Hiragino Mincho Pro", "YuMincho", "BIZ UDMincho", "Yu Mincho", "MS明朝", "MS Mincho", serif`, }, { id: "JA-V-SANS", label: "日本語 ゴシック (縦書き)", // eslint-disable-next-line quotes - fontFamily: `"Hiragino Kaku Gothic ProN", "Hiragino Sans W3", "Hiragino Sans", "BIZ UDGothic", "Yu Gothic", "MS Gothic", sans-serif`, + fontFamily: `"Hiragino Sans", "Hiragino Kaku Gothic ProN", "Hiragino Kaku Gothic Pro", "ヒラギノ角ゴ W3", "YuGothic", "BIZ UDGothic", "Yu Gothic", "MSゴシック", "MS Gothic", sans-serif`, }]; export const FONT_LIST_WITH_JA = FONT_LIST.concat(...FONT_LIST_JA); From 9e933f7fa651659693d486b78f0ab5225b7ced93 Mon Sep 17 00:00:00 2001 From: k_taka Date: Thu, 6 Jun 2024 14:24:16 +0900 Subject: [PATCH 3/3] Use "Yu Gothic Medium" for sans-serif font in Windows Japanese environment --- src/utils/fontList.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/utils/fontList.ts b/src/utils/fontList.ts index 7341da4160..839d69ce32 100644 --- a/src/utils/fontList.ts +++ b/src/utils/fontList.ts @@ -65,7 +65,7 @@ const FONT_LIST_JA: Font[] = id: "JA-SANS", label: "日本語 ゴシック(横書き)", // eslint-disable-next-line quotes - fontFamily: `"Hiragino Sans", "Hiragino Kaku Gothic ProN", "Hiragino Kaku Gothic Pro", "ヒラギノ角ゴ W3", "YuGothic", "BIZ UDPGothic", "Yu Gothic", "MS Pゴシック", "MS PGothic", sans-serif`, + fontFamily: `"Hiragino Sans", "Hiragino Kaku Gothic ProN", "Hiragino Kaku Gothic Pro", "ヒラギノ角ゴ W3", "YuGothic", "Yu Gothic Medium", "BIZ UDPGothic", "Yu Gothic", "MS Pゴシック", "MS PGothic", sans-serif`, }, { id: "JA-V", label: "日本語 明朝 (縦書き)", @@ -75,6 +75,6 @@ const FONT_LIST_JA: Font[] = id: "JA-V-SANS", label: "日本語 ゴシック (縦書き)", // eslint-disable-next-line quotes - fontFamily: `"Hiragino Sans", "Hiragino Kaku Gothic ProN", "Hiragino Kaku Gothic Pro", "ヒラギノ角ゴ W3", "YuGothic", "BIZ UDGothic", "Yu Gothic", "MSゴシック", "MS Gothic", sans-serif`, + fontFamily: `"Hiragino Sans", "Hiragino Kaku Gothic ProN", "Hiragino Kaku Gothic Pro", "ヒラギノ角ゴ W3", "YuGothic", Yu Gothic Medium", "BIZ UDGothic", "Yu Gothic", "MSゴシック", "MS Gothic", sans-serif`, }]; export const FONT_LIST_WITH_JA = FONT_LIST.concat(...FONT_LIST_JA);