"Search box" right in the tool bar of the shader editor?

It seems that people repeat adding new items a lot in the shader editor. To do that, one would press Shift+A, and then S to search. (There are so many items, that manually navigating to the submenu is not very practical.) There also is “Add” menu in the tool bar, but one would click “Add” and then “Search” to begin searching. That’s two clicks.

But can’t it be more convenient? There is a large empty area on the toolbar between the pin icon and the up arrow icon. What if you add the search bar there, so that one could just click it and begin searching right away, and then press enter to insert that item?

Something like this:

PS: Come to think of it, there is an even better way. How about showing the search box when one double-clicks anywhere on the empty area of the node area (background)? Then, Blender can add the new node where it was double-clicked. These days, a lot of applications use this semantics: “double-click empty area to add a new item”. For example, in VS Code, double-clicking on the empty area of the tab bar adds a new document. In Gimp, double-clicking on the empty area of the window shows open-file dialogue. So, this would not be a weird behaviour.

1 Like
  1. This will look like searching for a node (Ctrl-F) rather than adding a new one.
  2. Just add a double-click shortcut for “node.add_search” to get what you want.
2 Likes

Woah, thanks. I did not think it was possible to add a shortcut like “double click” (most applications do not support such detailed settings for custom shortcuts, but just keys). I have added it and not it works just as I wanted. A lot easier/faster to add new nodes.

PS: There seems to be a little problem with this, though. if I double click near the edge of window, the search pop-up’s top-left coordinate is not where the mouse is double-clicked but moves a little bit to make the search pop-up be inside the node window, and default items drop-down of the search result would be under where the mouse is double-clicked. And then Blender seem to think that the second click of the double click is for clicking the item. So, in short, double-clicking on an empty area near the edge inserts a random item in the search pop-up’s drop down list…

PS2: Found a workaround for that… Double click, but do not release the mouse at the second click at that location (where the menu item appears). That is, double click while dragging the mouse slightly to the left. It may take a little bit of practice, but does not seem unattainable.