sys.stderr.write (_('Extracted %s')
% curr_font_name + '\n')
- extract_from_this.remove (curr_font_name)
+ extract_from_this.remove (curr_font_name)
elif in_font:
curr_font.append (l)
if not extract_from_this:
if extract_from_this:
sys.stderr.write ("Failed to extract %s from %s\n"
- % (string.join (extract_from_this, ', '), f))
+ % (string.join (extract_from_this, ', '), filename))
def write_extracted_fonts (output_file_name, font_dict):
+ if verbose:
+ sys.stderr.write( _('Writing fonts to %s') % output_file_name + '\n')
output = open (output_file_name, 'w')
output.write ('''%!PS-Adobe-3.0
+%%VMusage: 0 0
%%Creator: lilypond-extract-fonts
''')
for (k,v) in font_dict.items ():
output.write ('\n%%%%BeginFont: %s\n' % k)
output.write (v)
- output.write ('\n%%%%EndFont')
+ output.write ('\n%%EndFont')
def extract_fonts (output_file_name, input_files):