79824304

Date: 2025-11-19 10:14:16
Score: 1
Natty:
Report link
You can connect to the Home button by listening to tool_triggered and checking the tool name:

fig.canvas.manager.toolmanager.tool_triggered.connect(
    lambda event: print("Home pressed") if event.name=='home' else None
)


This works reliably in Matplotlib ≥3.3.
Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: Carl Bidwell