From 6331a2a66690726fbce04dc0ab6a1ce5f9e006bd Mon Sep 17 00:00:00 2001 From: Cyano Hao Date: Sat, 7 Mar 2020 10:13:46 +0800 Subject: [PATCH] fix osf --- LICENSE.txt | 2 +- configure.py | 4 ++-- merge.py | 5 +++++ 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/LICENSE.txt b/LICENSE.txt index bf2c969..fb1882b 100644 --- a/LICENSE.txt +++ b/LICENSE.txt @@ -1,4 +1,4 @@ -Copyright © 2018—2019 Cyano Hao and Nowar Typeface, with reserved font name “Nowar”, “有爱”, and “有愛”. +Copyright © 2018—2020 Cyano Hao and Nowar Typeface, with reserved font name “Nowar”, “有爱”, and “有愛”. Portions Copyright 2015 Google Inc. diff --git a/configure.py b/configure.py index 2a002d0..24f40ce 100644 --- a/configure.py +++ b/configure.py @@ -5,8 +5,8 @@ from types import SimpleNamespace as Namespace class Config: - version = "0.7.1" - fontRevision = 0.0701 + version = "0.7.2" + fontRevision = 0.0702 vendor = "Nowar Typeface" vendorId = "NOWR" vendorUrl = "https://github.com/nowar-fonts" diff --git a/merge.py b/merge.py index 82cdfc5..b690a43 100644 --- a/merge.py +++ b/merge.py @@ -5,6 +5,7 @@ from types import SimpleNamespace as Namespace from libotd.merge import MergeBelow, MergeAbove from libotd.pkana import ApplyPalt, NowarApplyPaltMultiplied +from libotd.dereference import Dereference from libotd.transform import Transform, ChangeAdvanceWidth from libotd.gsub import GetGsubFlat, ApplyGsubSingle from libotd.gc import Gc, NowarRemoveFeatures @@ -219,6 +220,10 @@ def GenerateAsianSymbolFont(font): numWidth = numFont['glyf'][num[0]]['advanceWidth'] changeWidth = maxWidth - numWidth if numWidth > maxWidth else 0 + # dereference glyphs for futher modification + for n in num + pnum + onum + tonum: + numFont['glyf'][n] = Dereference(numFont['glyf'][n], numFont) + for n in num + tonum: tGlyph = numFont['glyf'][n] tWidth = tGlyph['advanceWidth']