-
Notifications
You must be signed in to change notification settings - Fork 54
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Search Box Suggestion Display Fix (1.21) #752
base: 1.21
Are you sure you want to change the base?
Search Box Suggestion Display Fix (1.21) #752
Conversation
Apparently, the same change would have to be done for the config field, as well, it has the same issue. |
The title calls this change a "fix" but I'm not sure either behavior is more correct. Does vanilla have examples where it might disagree with this, or is there something else justifying this? It is probably just me being used to it, but I kinda prefer it as is. |
Well, the insertion point overlaps with the placeholder text, looks like a visual bug to me. I've got that from other players of the mod pack I'm maintaining right now. Generally, in input fields where the placeholder text stays, the insertion point is a vertical bar, not an underscore, so there it can't intersect. Vanilla Minecraft doesn't have a lot of examples, it doesn't use many text fields and some don't have a placeholder at all (like chat input). I took the effort to go through gameplay recordings to give you the most direct comparison, this is REI: Their devs seem to have either used an existing option to use a vertical bar as an insertion point or actually built their own little rendering logic for it. From a UX standpoint, it's simple. If the search box is not focussed, it may be useful to convey what it does with the placeholder label. If the player clicks the search box, they want to type. They already know what the search box is for, they don't need a placeholder. |
Alright that's reasonable to me then, I will request you remove the non-functionality formatting changes made to the file |
Am I going to have to write the changes for the config text field, too? And then open eight individual pull requests for every version of Minecraft EMI supports? |
I handle all the versioning, if it gets merged into 1.21 then it'll get merged backwards. Adjusting the config text field is your choice, I just asked for the formatting changes to be removed. |
This pull request fixes the placeholder/suggestion text (e.g. "Search EMI…") being visible together with the insertion point, overlapping each other. These changes make it so the
TextFieldWidget
used for EMI's search now hides its suggestion text whenever the field has focus, when the player wants to type. Once it loses focus, the suggestion is displayed again. Existing logic for hiding the suggestion when the text field has input is kept as-is.I’m opening this because the one for 1.20 was rejected and closed.