mirror of
https://github.com/enzet/map-machine.git
synced 2025-06-12 07:41:55 +02:00
Fix floating point numbers.
This commit is contained in:
parent
6e20668e24
commit
ed0e0384b7
23 changed files with 358 additions and 332 deletions
|
@ -293,7 +293,7 @@ def add_render_arguments(parser: argparse.ArgumentParser) -> None:
|
|||
type=float,
|
||||
metavar="<float>",
|
||||
help="OSM zoom level",
|
||||
default=18,
|
||||
default=18.0,
|
||||
)
|
||||
parser.add_argument(
|
||||
"-c",
|
||||
|
@ -354,6 +354,7 @@ def progress_bar(
|
|||
fill_length: int = int(parts / BOXES_LENGTH)
|
||||
box: str = BOXES[int(parts - fill_length * BOXES_LENGTH)]
|
||||
sys.stdout.write(
|
||||
f"{str(int(int(ratio * 1000) / 10)):>3} % {fill_length * '█'}{box}"
|
||||
f"{str(int(int(ratio * 1000.0) / 10.0)):>3} % "
|
||||
f"{fill_length * '█'}{box}"
|
||||
f"{int(length - fill_length - 1) * ' '}▏{text}\n\033[F"
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue