kopia lustrzana https://github.com/hholzgra/ocitysmap
Fix message at the bottom/right of maps
It was showing a date of "12 Dec 2009" even for maps rendered today, because I mistakenly used %m (decimal number of month) instead of %d (decimal number of day in month). Also improve the wording. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>stable
rodzic
ad2a36dcdf
commit
e7aab658c5
|
|
@ -147,7 +147,7 @@ def add_logo(ctx, paperwidth, paperheight, logo_path,
|
|||
|
||||
ctx.move_to(png.get_width(), png.get_height() * 0.33 + fontheight)
|
||||
today = datetime.date.today()
|
||||
gendatetext = "This map has been rendered on %s and may not be complete or accurate." % today.strftime("%m %b %Y")
|
||||
gendatetext = "This map has been rendered on %s and may be incomplete or inaccurate." % today.strftime("%d %b %Y")
|
||||
textwidth = max(textwidth, ctx.text_extents(gendatetext)[2])
|
||||
ctx.show_text(gendatetext)
|
||||
|
||||
|
|
|
|||
Ładowanie…
Reference in New Issue