Skip to content

Commit

Permalink
Fix empty toolbar tool tips
Browse files Browse the repository at this point in the history
  • Loading branch information
soininen committed Oct 4, 2024
1 parent c574b1b commit 5c248a5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion spinetoolbox/widgets/toolbars.py
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,8 @@ def _make_tool_button(self, icon, text, slot=None, tip=None):
button = NiceButton()
button.setIcon(icon)
button.setText(text)
button.setToolTip(f"<p>{tip}</p>")
if tip is not None:
button.setToolTip(f"<p>{tip}</p>")

Check warning on line 163 in spinetoolbox/widgets/toolbars.py

View check run for this annotation

Codecov / codecov/patch

spinetoolbox/widgets/toolbars.py#L163

Added line #L163 was not covered by tests
if slot is not None:
button.clicked.connect(slot)
self._add_tool_button(button)
Expand Down

0 comments on commit 5c248a5

Please sign in to comment.