Skip to content

Commit

Permalink
Also search for plugins with the napari- prefix
Browse files Browse the repository at this point in the history
  • Loading branch information
goanpeca committed Jun 4, 2024
1 parent ddff56d commit 2e4940b
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions napari_plugin_manager/qt_plugin_dialog.py
Original file line number Diff line number Diff line change
Expand Up @@ -697,6 +697,12 @@ def filter(self, text: str, starts_with_chars: int = 1):
else Qt.MatchFlag.MatchContains
)
shown = [id(it) for it in self.findItems(text, flag)]
if len(text) <= starts_with_chars:
text2 = f'napari-{text}'
shown = set(
[id(it) for it in self.findItems(text2, flag)] + shown
)

for i in range(self.count()):
item = self.item(i)
item.setHidden(id(item) not in shown)
Expand Down

0 comments on commit 2e4940b

Please sign in to comment.