Skip to content

Commit 8276ba7

Browse files
committed
no message
1 parent 7bde223 commit 8276ba7

File tree

3 files changed

+20
-8
lines changed

3 files changed

+20
-8
lines changed

checkMissingGlyph.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
#!/usr/bin/env python
22
# -*- coding: utf-8 -*-
33

4-
from io import open
5-
import sys
64
import collections
75
import fontforge
6+
from io import open
7+
import sys
88

99
# ignore warning
1010
# import warnings

copyReferenceAtoB

+8
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
##Extend by my Experience
2+
當 当
3+
歷 历
4+
復 复
5+
崗 岗
6+
簽 签
7+
蕩 荡
8+
## End of Extension
19
內 内
210
勻 匀
311
戶 户

copyReferenceAtoB.py

+10-6
Original file line numberDiff line numberDiff line change
@@ -68,12 +68,12 @@ def bye(self, items):
6868
inFilePrompt = "File to read"
6969
defaultInFile = "copyReferenceAtoB"
7070

71-
outFilePrompt = "TTF File to write"
72-
defaultOutFile = "out.ttf"
71+
# outFilePrompt = "TTF File to write"
72+
# defaultOutFile = "out.ttf"
7373

7474
items = collections.OrderedDict()
7575
items[inFilePrompt] = defaultInFile
76-
items[outFilePrompt] = defaultOutFile
76+
# items[outFilePrompt] = defaultOutFile
7777

7878
app = QApplication(sys.argv)
7979
ask = askSetting(app=app, items=items)
@@ -97,6 +97,8 @@ def bye(self, items):
9797
## ie. word
9898
count = 0
9999
for line in f:
100+
if line.startswith("##"):
101+
continue
100102
words = line.encode("raw_unicode_escape").split()
101103
# words = line.split()
102104
# print(len(words))
@@ -126,10 +128,12 @@ def bye(self, items):
126128
ttfFile.selection.select(words[1])
127129
ttfFile.paste()
128130

129-
ttfFile.fontname = ttfFile.fontname + "-TWEAK"
131+
ttfFile.fontname = "Z-"+ttfFile.fontname
132+
ttfFile.familyname = "Z-"+ttfFile.familyname
133+
130134
if not os.path.exists("out"):
131135
os.makedirs("out")
132136

133-
ttfFile.generate("out/"+defaultOutFile)
137+
ttfFile.generate("out/"+ttfFile.fontname+".ttf")
134138

135-
print(u'\nGenerated '+ttfFile.fontname+u" as out/"+defaultOutFile+u"\n")
139+
print(u'\nGenerated '+ttfFile.fontname+u" as out/"+ttfFile.fontname+u"\n")

0 commit comments

Comments
 (0)