Decimal comma/point, Issue 1939, fixed.
svn: r10321
This commit is contained in:
parent
610443812b
commit
b078464281
@ -261,8 +261,8 @@ class PaperFrame(gtk.HBox):
|
||||
# How can we distinguish custom size though?
|
||||
if papername == _('Custom Size'):
|
||||
try:
|
||||
h = float(unicode(self.pheight.get_text()))
|
||||
w = float(unicode(self.pwidth.get_text()))
|
||||
h = float(unicode(self.pheight.get_text().replace(",",".")))
|
||||
w = float(unicode(self.pwidth.get_text().replace(",",".") ))
|
||||
|
||||
if h <= 1.0 or w <= 1.0:
|
||||
papersize.set_height(29.7)
|
||||
@ -290,7 +290,7 @@ class PaperFrame(gtk.HBox):
|
||||
|
||||
for i, margin in enumerate(paper_margins):
|
||||
try:
|
||||
paper_margins[i] = float(margin)
|
||||
paper_margins[i] = float(margin.replace(",","."))
|
||||
paper_margins[i] = paper_margins[i] * self.paper_unit_multiplier
|
||||
paper_margins[i] = max(paper_margins[i], 0)
|
||||
except:
|
||||
@ -299,8 +299,8 @@ class PaperFrame(gtk.HBox):
|
||||
return paper_margins
|
||||
|
||||
def get_custom_paper_size(self):
|
||||
width = float(self.pwidth.get_text() ) * self.paper_unit_multiplier
|
||||
height = float(self.pheight.get_text()) * self.paper_unit_multiplier
|
||||
width = float(self.pwidth.get_text().replace(",",".")) * self.paper_unit_multiplier
|
||||
height = float(self.pheight.get_text().replace(",",".")) * self.paper_unit_multiplier
|
||||
|
||||
paper_size = []
|
||||
paper_size.append(max(width, 1.0))
|
||||
|
Loading…
Reference in New Issue
Block a user