@@ -125,7 +125,9 @@ def draw(self) -> None:
125
125
"""
126
126
127
127
def _on_update_layers (self ) -> None :
128
- """This function is called when self.layers is updated via self.update_layers()
128
+ """
129
+ This function is called when self.layers is updated via
130
+ ``self.update_layers()``.
129
131
130
132
This is a no-op, and is intended for derived classes to override.
131
133
"""
@@ -136,11 +138,13 @@ def _replace_toolbar_icons(self):
136
138
text = action .text ()
137
139
if text == "Pan" :
138
140
action .setToolTip (
139
- "Pan/Zoom: Left button pans; Right button zooms; Click once to activate; Click again to deactivate"
141
+ "Pan/Zoom: Left button pans; Right button zooms; "
142
+ "Click once to activate; Click again to deactivate"
140
143
)
141
144
if text == "Zoom" :
142
145
action .setToolTip (
143
- "Zoom to rectangle; Click once to activate; Click again to deactivate"
146
+ "Zoom to rectangle; Click once to activate; "
147
+ "Click again to deactivate"
144
148
)
145
149
if len (text ) > 0 : # i.e. not a separator item
146
150
icon_path = os .path .join (ICON_ROOT , text + ".png" )
@@ -150,9 +154,6 @@ def _replace_toolbar_icons(self):
150
154
class NapariNavigationToolbar (NavigationToolbar2QT ):
151
155
"""Custom Toolbar style for Napari."""
152
156
153
- def __init__ (self , canvas , parent ):
154
- super ().__init__ (canvas , parent )
155
-
156
157
def _update_buttons_checked (self ):
157
158
"""Update toggle tool icons when selected/unselected."""
158
159
super ()._update_buttons_checked ()
0 commit comments