diff --git a/gramps/gen/plug/docgen/stylesheet.py b/gramps/gen/plug/docgen/stylesheet.py index 5df5a756e..eaf282adf 100644 --- a/gramps/gen/plug/docgen/stylesheet.py +++ b/gramps/gen/plug/docgen/stylesheet.py @@ -46,7 +46,6 @@ from .paragraphstyle import ParagraphStyle from .fontstyle import FontStyle from .tablestyle import TableStyle, TableCellStyle from .graphicstyle import GraphicsStyle -from gramps.gen.const import GRAMPS_LOCALE as glocale #------------------------------------------------------------------------- # @@ -476,17 +475,17 @@ class SheetParser(handler.ContentHandler): self.p = ParagraphStyle() if 'description' in attrs: self.p.set_description(attrs['description']) - self.p.set_right_margin(glocale.float(attrs['rmargin'])) - self.p.set_left_margin(glocale.float(attrs['lmargin'])) - self.p.set_first_indent(glocale.float(attrs['first'])) + self.p.set_right_margin(float(attrs['rmargin'])) + self.p.set_left_margin(float(attrs['lmargin'])) + self.p.set_first_indent(float(attrs['first'])) try: # This is needed to read older style files # lacking tmargin and bmargin - self.p.set_top_margin(glocale.float(attrs['tmargin'])) - self.p.set_bottom_margin(glocale.float(attrs['bmargin'])) + self.p.set_top_margin(float(attrs['tmargin'])) + self.p.set_bottom_margin(float(attrs['bmargin'])) except KeyError: pass - self.p.set_padding(glocale.float(attrs['pad'])) + self.p.set_padding(float(attrs['pad'])) self.p.set_alignment(int(attrs['align'])) self.p.set_right_border(int(attrs['rborder'])) self.p.set_header_level(int(attrs['level'])) @@ -510,16 +509,16 @@ class SheetParser(handler.ContentHandler): self.c.set_right_border(int(attrs['rborder'])) self.c.set_top_border(int(attrs['tborder'])) self.c.set_bottom_border(int(attrs['bborder'])) - self.c.set_padding(glocale.float(attrs['pad'])) + self.c.set_padding(float(attrs['pad'])) elif tag == "draw": self.g = GraphicsStyle() self.g.set_paragraph_style(attrs['para']) - self.g.set_line_width(glocale.float(attrs['width'])) + self.g.set_line_width(float(attrs['width'])) self.g.set_line_style(int(attrs['style'])) self.g.set_color(cnv2color(attrs['color'])) self.g.set_fill_color(cnv2color(attrs['fillcolor'])) self.g.set_shadow(int(attrs['shadow']), - glocale.float(attrs['space'])) + float(attrs['space'])) def endElement(self, tag): "Overridden class that handles the end of a XML element"