Skip to content

Commit

Permalink
Bump version to 27
Browse files Browse the repository at this point in the history
  • Loading branch information
simonsmh committed Dec 18, 2024
1 parent 3bf3cec commit 1e7e0c8
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 21 deletions.
20 changes: 5 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@

NotoSansCJK & NotoSerifCJK full weight patch for Android devices.

* NotoSansCJK VF support as full weight patch applies to Android O+
* NotoSerifCJK full weight patch applies to Android P+
* NotoSansCJK VF support as full weight patch applies to Android 8-15
* NotoSerifCJK full weight patch applies to Android 9-15

Fonts are provided by [Google](https://github.com/googlefonts/noto-cjk).

Expand All @@ -15,29 +15,19 @@ Currently, this module is still maintained. It was used to be stored at official
[John Wu's Twitter for details](https://twitter.com/topjohnwu/status/1229896206584664065)

## NOTICE

* You should use latest Magisk Manager to install this module. If you meet any problem under installation from Magisk Manager, please try to install it from recovery.

* New features:

Upgrade Noto Serif CJK to 2.000(R) that supports variable fonts.

![Noto Serif CJK variable test](extra/serif-variable-test.gif)
* Android 15+ doesn't need this module anymore.
* You should use latest Magisk Manager/KernelSU to install this module.

* Recent fixes:

Support system_ext [#40](https://github.com/simonsmh/notocjk/issues/40)
Remove invalid old fonts which prevent MinikinFont from loading with npe when Magisk/KernelSU triggers unmounting.

* Known issues:

HK fonts style is pending & waiting for Google solution in later android versions.

Font weight in Firefox is not current (all be thin) if force it to use Noto Sans CJK VF. ([#28](https://github.com/simonsmh/notocjk/issues/28))

Android 12 may crash in some app after installed version 10 and above with Magisk Hide enabled. See: (Chinese only, more details of logs in comments) https://t.me/magiskalpha/297

## Credit & Support

* Copyright (C) 2017-2022 simonsmh <[email protected]>
* Any issue or pull request is welcomed.
* Star this module at [GitHub](https://github.com/simonsmh/notocjk).
7 changes: 5 additions & 2 deletions customize.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
if [ "$API" -lt 26 ]; then
if [ "$API" -gt 34 ]; then
ui_print "*********************************************************"
ui_print "! Android 15+ already supports full weight variable fonts"
ui_print "*********************************************************"
elif [ "$API" -lt 26 ]; then
ui_print "*********************************************************"
ui_print "! Please upgrade your system to Android 8+"
abort "*********************************************************"
Expand Down Expand Up @@ -59,7 +63,6 @@ sed -i '
/<family lang=\"ko\">/,/<\/family>/ {:a;N;/<\/family>/!ba;
s/<family lang=\"ko\">.*Noto.*CJK.*<\/family>/<family lang="ko">\n<font weight="100" style="normal" index="1" postScriptName="NotoSansCJKjp-Thin">NotoSansCJK-VF.otf.ttc<axis tag="wght" stylevalue="100" \/><\/font>\n<font weight="300" style="normal" index="1" postScriptName="NotoSansCJKjp-Thin">NotoSansCJK-VF.otf.ttc<axis tag="wght" stylevalue="300" \/><\/font>\n<font weight="400" style="normal" index="1" postScriptName="NotoSansCJKjp-Thin">NotoSansCJK-VF.otf.ttc<axis tag="wght" stylevalue="400" \/><\/font>\n<font weight="500" style="normal" index="1" postScriptName="NotoSansCJKjp-Thin">NotoSansCJK-VF.otf.ttc<axis tag="wght" stylevalue="500" \/><\/font>\n<font weight="600" style="normal" index="1" postScriptName="NotoSansCJKjp-Thin">NotoSansCJK-VF.otf.ttc<axis tag="wght" stylevalue="600" \/><\/font>\n<font weight="700" style="normal" index="1" postScriptName="NotoSansCJKjp-Thin">NotoSansCJK-VF.otf.ttc<axis tag="wght" stylevalue="700" \/><\/font>\n<font weight="900" style="normal" index="1" postScriptName="NotoSansCJKjp-Thin">NotoSansCJK-VF.otf.ttc<axis tag="wght" stylevalue="900" \/><\/font>\n<font weight="200" style="normal" index="1" fallbackFor="serif" postScriptName="NotoSerifCJKjp-ExtraLight">NotoSerifCJK-VF.otf.ttc<axis tag="wght" stylevalue="200" \/><\/font>\n<font weight="300" style="normal" index="1" fallbackFor="serif" postScriptName="NotoSerifCJKjp-ExtraLight">NotoSerifCJK-VF.otf.ttc<axis tag="wght" stylevalue="300" \/><\/font>\n<font weight="400" style="normal" index="1" fallbackFor="serif" postScriptName="NotoSerifCJKjp-ExtraLight">NotoSerifCJK-VF.otf.ttc<axis tag="wght" stylevalue="400" \/><\/font>\n<font weight="500" style="normal" index="1" fallbackFor="serif" postScriptName="NotoSerifCJKjp-ExtraLight">NotoSerifCJK-VF.otf.ttc<axis tag="wght" stylevalue="500" \/><\/font>\n<font weight="600" style="normal" index="1" fallbackFor="serif" postScriptName="NotoSerifCJKjp-ExtraLight">NotoSerifCJK-VF.otf.ttc<axis tag="wght" stylevalue="600" \/><\/font>\n<font weight="700" style="normal" index="1" fallbackFor="serif" postScriptName="NotoSerifCJKjp-ExtraLight">NotoSerifCJK-VF.otf.ttc<axis tag="wght" stylevalue="700" \/><\/font>\n<font weight="900" style="normal" index="1" fallbackFor="serif" postScriptName="NotoSerifCJKjp-ExtraLight">NotoSerifCJK-VF.otf.ttc<axis tag="wght" stylevalue="900" \/><\/font>\n<\/family>\n<family lang="ko">\n<font weight="400" style="normal" index="1" postScriptName="NotoSansCJKjp-Regular">NotoSansCJK-Regular.ttc<\/font>\n<font weight="400" style="normal" index="1" fallbackFor="serif" postScriptName="NotoSerifCJKjp-Regular">NotoSerifCJK-Regular.ttc<\/font>\n<\/family>/};
' $MODPATH$SYSTEMFILEPATH$FILE
grep -q DroidSansFallback.ttf $MODPATH$SYSTEMFILEPATH$FILE || sed -i 's/<\/familyset>/<family>\n<font weight="400" style="normal">DroidSansFallback.ttf<\/font>\n<\/family>\n<\/familyset>/g' $MODPATH$SYSTEMFILEPATH$FILE
sed -i 's/<\/familyset>/<family>\n<font weight="400" style="normal">DroidSansFallbackFull.ttf<\/font>\n<\/family>\n<\/familyset>/g' $MODPATH$SYSTEMFILEPATH$FILE
fi
done
Expand Down
5 changes: 3 additions & 2 deletions extra/changelog.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# Changelog v26
# Changelog v27

Update Noto Serif CJK to [2.003](https://github.com/notofonts/noto-cjk/tree/9b0f1436e455d902de067a2501422e5dc71ad16b/Serif)
* Added an installation warning for Android 15+
* Removed an old font that prevent MinikinFont from loading with an NPE when Magisk/KernelSU triggers unmounting.

> The fonts were modified by `subset_noto_cjk.py` to remove cmap entries for characters that should default to the emoji style on Android.
> The fonts have been modified to include a `chws` table.
Expand Down
4 changes: 2 additions & 2 deletions module.prop
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
id=notocjk
name=NotoCJK
version=26 (Sans-2.004-VF/Serif-2.003-VF)
versionCode=26
version=27 (Sans-2.004-VF/Serif-2.003-VF)
versionCode=27
author=simonsmh
description=NotoCJK (NotoSansCJK & NotoSerifCJK) full weight fonts patch for every Android devices.
updateJson=https://cdn.jsdelivr.net/gh/simonsmh/notocjk/version.json
Binary file removed system/fonts/DroidSansFallback.ttf
Binary file not shown.

0 comments on commit 1e7e0c8

Please sign in to comment.