Skip to content

Commit

Permalink
fix: Fix symbol labels
Browse files Browse the repository at this point in the history
Symbol labels should have more space.
  • Loading branch information
ewuerger committed Apr 17, 2024
1 parent 6849fe8 commit b71ca08
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion capellambse_context_diagrams/collectors/makers.py
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,9 @@ def make_box(
[`ELKInputChild`][capellambse_context_diagrams._elkjs.ELKInputChild].
"""
layout_options = layout_options or CENTRIC_LABEL_LAYOUT_OPTIONS
if symbol := not no_symbol and is_symbol(obj):
max_label_width = 200

labels: list[_elkjs.ELKInputLabel] = []
for label_builder in label_getter(obj):
if not label_builder.get("layout_options"):
Expand All @@ -156,7 +159,7 @@ def make_box(

labels.extend(make_label(**label_builder, max_width=max_label_width))

if not no_symbol and is_symbol(obj):
if symbol:
if height < MIN_SYMBOL_HEIGHT:
height = MIN_SYMBOL_HEIGHT
elif height > MAX_SYMBOL_HEIGHT:
Expand Down

0 comments on commit b71ca08

Please sign in to comment.