Skip to content
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

Allow pasting into input popup on tiles build #47263

Merged
merged 3 commits into from
Feb 14, 2021

Conversation

Qrox
Copy link
Contributor

@Qrox Qrox commented Feb 6, 2021

Summary

Interface "Allow pasting into input popup on tiles build"

Purpose of change

Allow pasting content from the clipboard into input popups. I imagine this can be useful when you want to search for items etc by name from an external source (item browser, for example). This can also be useful for windows IME users to workaround a SDL bug that makes IME input in the game difficult, by inputing the text into a text editor and then pasting the text into the game instead.

Describe the solution

Test ctrl-v in string_input_popup and insert clipboard text into the string.

Testing

Copied some English and Chinese text from a text editor into a input popup successfully.

Additional context

SDL has a half-done implementation of custom IME candidate list, so neither the system IME candidate list nor the custom one is rendered correctly. If we want this fixed we probably need to compile our own patched SDL, as although a patch has been submitted to the SDL bug tracker two years ago, there doesn't seem to be any intention to merge it or fix the implementation.

@Qrox Qrox marked this pull request as draft February 6, 2021 16:13
@BrettDong BrettDong added <Enhancement / Feature> New features, or enhancements on existing Controls / Input Keyboard, mouse, keybindings, input UI, etc. SDL: Tiles / Sound Tiles visual interface and sounds. [C++] Changes (can be) made in C++. Previously named `Code` labels Feb 6, 2021
@Qrox Qrox marked this pull request as ready for review February 7, 2021 06:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[C++] Changes (can be) made in C++. Previously named `Code` Controls / Input Keyboard, mouse, keybindings, input UI, etc. <Enhancement / Feature> New features, or enhancements on existing SDL: Tiles / Sound Tiles visual interface and sounds.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants