You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the problem or limitation you are having in your project
The Lookup Symbol context menu entry lists no hotkey and the most intuitive solution is to select or position my text cursor within the identifier I want to look up and hit F1... which doesn't have the desired result.
Describe the feature / enhancement and how it helps to overcome the problem or limitation
When F1 is pressed, pre-fill the identifer under the text cursor in the Search Help window so the user only needs to press Enter if that's what they wanted and pre-select the filled text so they still don't need to manually erase it otherwise.
Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams
If the cursor is on or at the end of something that is not an identifier, pre-fill the search field with that text and pre-select it so the user doesn't need to manually erase it if that was undesired.
If Lookup Symbol and the Search Help window's as-you-type selection use different algorithms, run a safety check to ensure that it highlighted the entry that Lookup Symbol would have.
This approach has three advantages:
It makes typing vecF1 and F1vec functionally equivalent, minimizing the need for the user to maintain more complex habits and making the system more forgiving of errors.
It achieves keyboard-friendly "put the cursor inside a recognized identifier, press F1, and then press Enter to look it up" behaviour by reusing as much existing behaviour as possible.
It's makes something someone may intuitively try Just Work™
Alternatively, you could add a keybind for Lookup Symbol that doesn't go via the Search Help dialog, though I'd still like to have it pre-fill F1 so I don't have to go "Oops. Ctrl+Shift+Left, Ctrl+C, F1, Ctrl+V" when working off habits from other systems which expect you to type into the document and then trigger something to consume the word you typed, such as Vim leader commands. (eg. UltiSnips)
If this enhancement will not be used often, can it be worked around with a few lines of script?
No. It's an editor ergonomics enhancement.
Is there a reason why this should be core and not an add-on in the asset library?
So it can enhance the existing F1 keybind and Lookup Identifier functionality with a trivial bit of glue rather than reinventing them on a less intuitive keybinding.
The text was updated successfully, but these errors were encountered:
This is already available with Contextual Help, which defaults to Alt + F1.
However, this begs the question of whether we should do this by default when pressing F1 (and remove Contextual Help as it'll no longer be needed). The text is already selected, so if you enter anything, it'll be overwritten anyway.
Describe the project you are working on
A 2D game using GDScript
Describe the problem or limitation you are having in your project
The Lookup Symbol context menu entry lists no hotkey and the most intuitive solution is to select or position my text cursor within the identifier I want to look up and hit F1... which doesn't have the desired result.
Describe the feature / enhancement and how it helps to overcome the problem or limitation
When F1 is pressed, pre-fill the identifer under the text cursor in the Search Help window so the user only needs to press Enter if that's what they wanted and pre-select the filled text so they still don't need to manually erase it otherwise.
Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams
This approach has three advantages:
vec
F1 and F1vec
functionally equivalent, minimizing the need for the user to maintain more complex habits and making the system more forgiving of errors.Alternatively, you could add a keybind for Lookup Symbol that doesn't go via the Search Help dialog, though I'd still like to have it pre-fill F1 so I don't have to go "Oops. Ctrl+Shift+Left, Ctrl+C, F1, Ctrl+V" when working off habits from other systems which expect you to type into the document and then trigger something to consume the word you typed, such as Vim leader commands. (eg. UltiSnips)
If this enhancement will not be used often, can it be worked around with a few lines of script?
No. It's an editor ergonomics enhancement.
Is there a reason why this should be core and not an add-on in the asset library?
So it can enhance the existing F1 keybind and Lookup Identifier functionality with a trivial bit of glue rather than reinventing them on a less intuitive keybinding.
The text was updated successfully, but these errors were encountered: