@@ -519,16 +519,14 @@ def create_dotted_font(fname):
519
519
args .em = input_font .em
520
520
new_font = fontforge .font ()
521
521
for glyphname in input_font :
522
- print "Processing glyph named" , glyphname
523
522
if glyphname in ('.notdef' , '.null' ): continue
524
523
glyph = input_font [glyphname ]
524
+ print "Processing glyph named {} at codepoint U+{:04X}" .format (glyphname , glyph .encoding )
525
525
glyph .unlinkRef ()
526
526
new_glyph = new_font .createChar (glyph .encoding )
527
527
copy_glyph (glyph , new_glyph )
528
528
new_font .generate (args .output )
529
- dots = extract_dots (glyph )
530
- print "{} dots found" .format (len (dots ))
531
- wait_for_keypress (args .em , args .zoom )
529
+ print "Dotted font created as" , args .output
532
530
533
531
def extraction_demo (fname , letter ):
534
532
font = silent_fontopen (fname )
@@ -631,7 +629,6 @@ def extract_dots(glyph, show_glyph=True):
631
629
632
630
def copy_glyph (orig_glyph , new_glyph ):
633
631
# (new_glyph was created with font.createChar(orig_glyph.encoding)
634
- print "Copying glyph at U+{:04X}" .format (orig_glyph .encoding ) # TODO: move this line to a different function
635
632
new_glyph .glyphname = orig_glyph .glyphname
636
633
dots = extract_dots (orig_glyph , False ) # TODO: Refactor extract_dots to remove drawing code or make it optional
637
634
for dot in dots :
0 commit comments