Skip to content

Commit

Permalink
Shade current class in diagram
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed Aug 8, 2024
1 parent 5312a34 commit 15cec98
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions inheritance_diagram.py
Original file line number Diff line number Diff line change
Expand Up @@ -327,6 +327,9 @@ def generate_dot(self, name: str, urls: dict[str, str] | None = None,
for name, fullname, bases, tooltip, derived in sorted(self.class_info):
# Write the node
this_node_attrs = n_attrs.copy()
if any(n.endswith(f'.{name}') for n in self.class_names):
this_node_attrs['fillcolor'] = '"#e7f2fa"'

if fullname in urls:
this_node_attrs["URL"] = '"%s"' % urls[fullname]
this_node_attrs["target"] = '"_top"'
Expand Down

0 comments on commit 15cec98

Please sign in to comment.