Use composed breves, add combining dot above
authorDan Scott <dan@coffeecode.net>
Fri, 29 Jul 2011 18:34:42 +0000 (14:34 -0400)
committerDan Scott <dscott@laurentian.ca>
Tue, 7 May 2013 18:37:02 +0000 (14:37 -0400)
Signed-off-by: Dan Scott <dscott@laurentian.ca>
tools/ebooks/prep_ebook_records.py

index 9fd228a..e6fed11 100644 (file)
@@ -382,13 +382,21 @@ def clean_diacritics(field):
         tmpsf = tmpsf.replace(u'\xd4S', u'\u015a')
         tmpsf = tmpsf.replace(u'\xd4s', u'\u015b')
 
-        # COMBINING BREVE
-        tmpsf = tmpsf.replace(u'\xe6i', u'i\u0306')
-
         # R CARON
         tmpsf = tmpsf.replace(u'\xdaR', u'\u0158')
         tmpsf = tmpsf.replace(u'\xdar', u'\u0159')
 
+        # G BREVE
+        tmpsf = tmpsf.replace(u'\xe6G', u'\u011e')
+        tmpsf = tmpsf.replace(u'\xe6g', u'\u011f')
+
+        # I BREVE
+        tmpsf = tmpsf.replace(u'\xe6I', u'i\u012c')
+        tmpsf = tmpsf.replace(u'\xe6i', u'i\u012d')
+
+        # COMBINING DOT ABOVE
+        tmpsf = tmpsf.replace(u'\xfeI', u'I\u0307')
+
         new_field.add_subfield(subfield[0], tmpsf)
         if r'\x' in repr(tmpsf):
             global RECORD_COUNT