diff --git a/doc/time.png b/doc/time.png index 822cc69..0c04d9a 100644 Binary files a/doc/time.png and b/doc/time.png differ diff --git a/doc/user.png b/doc/user.png index 5f49194..d6cc760 100644 Binary files a/doc/user.png and b/doc/user.png differ diff --git a/roentgen/constructor.py b/roentgen/constructor.py index cf45fe9..56a505e 100644 --- a/roentgen/constructor.py +++ b/roentgen/constructor.py @@ -429,6 +429,7 @@ class Constructor: priority: int icon_set: IconSet + draw_outline: bool = True if self.mode in ["time", "user-coloring"]: if not tags: @@ -440,13 +441,16 @@ class Constructor: dot, _ = self.icon_extractor.get_path(DEFAULT_SMALL_SHAPE_ID) icon_set = IconSet([dot], [], color, set(), True) priority = 0 + draw_outline = False else: icon_set, priority = self.scheme.get_icon( self.icon_extractor, tags ) self.nodes.append(Point( - icon_set, tags, flung, node.coordinates, priority=priority)) + icon_set, tags, flung, node.coordinates, priority=priority, + draw_outline=draw_outline + )) missing_tags.update( f"{key}: {tags[key]}" for key in tags diff --git a/roentgen/point.py b/roentgen/point.py index ecce3c7..5a4a7fe 100644 --- a/roentgen/point.py +++ b/roentgen/point.py @@ -140,7 +140,8 @@ class Point(Tagged): def __init__( self, icon_set: IconSet, tags: Dict[str, str], point: np.array, coordinates: np.array, priority: float = 0, - is_for_node: bool = True): + is_for_node: bool = True, draw_outline: bool = True + ): super().__init__() assert point is not None @@ -152,6 +153,7 @@ class Point(Tagged): self.priority: float = priority self.layer: float = 0 self.is_for_node: bool = is_for_node + self.draw_outline: bool = draw_outline self.y = 0 @@ -210,11 +212,12 @@ class Point(Tagged): # Draw outlines. - for icon in icons: # type: Icon - bright: bool = is_bright(fill) - color: Color = Color("black") if bright else Color("white") - opacity: float = 0.7 if bright else 0.5 - icon.draw(svg, position, color, opacity=opacity, outline=True) + if self.draw_outline: + for icon in icons: # type: Icon + bright: bool = is_bright(fill) + color: Color = Color("black") if bright else Color("white") + opacity: float = 0.7 if bright else 0.5 + icon.draw(svg, position, color, opacity=opacity, outline=True) # Draw icons.