godotengine / godot-proposals

Godot Improvement Proposals (GIPs)
MIT License
1.11k stars 69 forks source link

Set a node name in the 'Create New Node' dialog box #1686

Open chucklepie opened 3 years ago

chucklepie commented 3 years ago

Describe the project you are working on: It's a beautiful little 2D retro remake of a class ZX Spectrum game called Rex, from 1989. Check it out :)

Describe the problem or limitation you are having in your project: I'd say about 80% of the time I add a node I then go into the scene pane and rename it. It's a tiny bit tedious

Describe the feature / enhancement and how it helps to overcome the problem or limitation: I did check first for a repeat proposal! Simply add a text box to the create new node dialog, auto-filling with the default, called 'node name' allowing it to be done here. Then you don't have to go to the scene and select rename then type.

Describe how your proposal will work, with code, pseudocode, mockups, and/or diagrams: Please accept my apology, I couldn't be bothered to add a font to my pixel editor ;-) image

Is there a reason why this should be core and not an add-on in the asset library?: It's a quality of life change, one that will speed up things and is a simple addition

KoBeWi commented 3 years ago

You can press enter after adding node to rename it. The catch is that you can't use mouse. RVxtc6Z0WR

chucklepie commented 3 years ago

I my solution better 😉

It matches how other dialogs do it, eg signal connect

On Mon, 19 Oct 2020, 13:54 Tomek, notifications@github.com wrote:

You can press enter after adding node to rename it. The catch is that you can't use mouse. [image: RVxtc6Z0WR] https://user-images.githubusercontent.com/2223172/96453542-e7a91680-121a-11eb-8adb-ac814babf2d5.gif

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/godotengine/godot-proposals/issues/1686#issuecomment-712136140, or unsubscribe https://github.com/notifications/unsubscribe-auth/ADCERRPQEHH6GES3SRLIKPTSLQZJXANCNFSM4SVCZRPQ .

RoniPerson commented 2 years ago

As mentioned in #3568 I would add the addition that when typing something in the searchfield that dos not match any node name it gets copied to the name field automatically, preventing one copy and paste in this case.

dalexeev commented 2 years ago

I would add the addition that when typing something in the searchfield that dos not match any node name it gets copied to the name field automatically

I think you'll get used to using the correct field. :slightly_smiling_face:

We probably need to swap the fields so that the Name is first and does not separate the Filter from the Matches:

RoniPerson commented 2 years ago

I would add the addition that when typing something in the searchfield that dos not match any node name it gets copied to the name field automatically

I think you'll get used to using the correct field. 🙂

We probably need to swap the fields so that the Name is first and does not separate the Filter from the Matches:

I have to say that I liked the mockup with both fields next to each better:

It keeps the interface simpler and nodenames are not so lang that the smaller search bar would overflow.

AaronRecord commented 2 years ago

I my solution better 😉 It matches how other dialogs do it, eg signal connect

The workflow this proposal suggests is you select the node you want, press tab/click to select the name dialog, enter the name, and then hit enter to confirm. With the current workflow, you select the node you want, hit enter, then just hit enter a second time if you want to rename it. In my opinion the current system is less complex and already works better. I'm not strictly against this proposal, but I feel like it's trying to solve a problem that has already been solved.

spindlebink commented 2 years ago

Per my comment here, what about forgoing the dedicated box and instead allowing separation of node type and name with a colon? Doing it this way would turn it into an easily-accessible, minor change to the current workflow which would enable the more keyboard-centric n2d:NodeName shortcut. It also shouldn't require much modification of the current code.

This method also fits with the convenience-oriented nature of the node adding screen--I kind of agree with @LightningAA here and feel like a dedicated box for the name isn't that much better than what we currently have.

RoniPerson commented 2 years ago

This method also fits with the convenience-oriented nature of the node adding screen--I kind of agree with @LightningAA here and feel like a dedicated box for the name isn't that much better than what we currently have.

Yeah I think you are right here though I'm not sure if type:name or name:type would be better. Also solving issues over some sort of string pattern always feels a little bit hacky for me. But it would at least help solving the problem without huge changes to the ui.

spindlebink commented 2 years ago

Yeah I think you are right here though I'm not sure if type:name or name:type would be better

A theoretical type:name pattern would fit with the current workflow and make the convenience name optional. To get the current search functionality with name:type format you'd need to prefix every search with : which would be icky.

feels a little bit hacky for me

Think of it like a hotkey, or like the meta+P go-to-symbol palette that's big in code editors these days.