Make credits optional.

This commit is contained in:
Sergey Vartanov 2022-08-17 02:41:42 +03:00
parent c76e1f0301
commit 7e2d9ba5af
2 changed files with 3 additions and 1 deletions

View file

@ -60,6 +60,7 @@ class MapConfiguration:
use_building_colors: bool = False use_building_colors: bool = False
show_overlapped: bool = False show_overlapped: bool = False
credit: Optional[str] = "© OpenStreetMap contributors" credit: Optional[str] = "© OpenStreetMap contributors"
show_credit: bool = True
@classmethod @classmethod
def from_options( def from_options(

View file

@ -130,6 +130,7 @@ class Map:
self.svg, occupied, self.configuration.label_mode self.svg, occupied, self.configuration.label_mode
) )
if self.configuration.show_credit:
self.draw_credits(constructor.flinger.size) self.draw_credits(constructor.flinger.size)
def draw_buildings(self, constructor: Constructor) -> None: def draw_buildings(self, constructor: Constructor) -> None: