The Birdfont Source Code


All Repositories / birdfont.git / commitdiff – RSS feed

Fix file dialog on windows

These changes was commited to the Birdfont repository Fri, 26 Jun 2015 13:05:42 +0000.

Contributing

Send patches or pull requests to johan.mattsson.m@gmail.com.
Clone this repository: git clone https://github.com/johanmattssonm/birdfont.git
[Fri, 26 Jun 2015 13:05:42 +0000]

Updated Files

libbirdfont/FileDialogTab.vala
libbirdfont/Glyph.vala
scripts/complete_translations.py
--- a/libbirdfont/FileDialogTab.vala +++ b/libbirdfont/FileDialogTab.vala @@ -127,8 +127,11 @@ if (f.file_name.index_of (":") > -1) { propagate_files (f.file_name); } else { - printd (@"Subdir: $(f.file_name) in $((!) current_dir.get_path ()) path_separator: $path_separator\n"); - propagate_files (((!) current_dir.get_path ()) + path_separator + f.file_name); + string d = (!) current_dir.get_path (); + printd (@"Subdir: $(f.file_name) in $d path_separator: $path_separator\n"); + string p = d + path_separator + f.file_name; + p = p.replace ("\\\\", "\\"); + propagate_files (p); } selected_filename = "";
--- a/libbirdfont/Glyph.vala +++ b/libbirdfont/Glyph.vala @@ -73,10 +73,6 @@ } set { - if (value == 0) { - warning (@"zero left_limit in $(get_name ())"); - } - _left_limit = value; } }
--- a/scripts/complete_translations.py +++ b/scripts/complete_translations.py @@ -14,7 +14,7 @@ def completeness (pofile): """ Returns the completeness of the translation in percent """ - with open (pofile) as f: + with open (pofile, 'r', encoding='utf-8') as f: content = f.readlines () translated = 0.0 @@ -65,6 +65,7 @@ completed = completeness (pofile) podir = pofile.replace ("po/", "") podir = podir.replace (".po", "") + podir = podir.replace ("\\", "/") if completed >= float (options.threshold): print ("Releasing " + podir) else: