Add various input dialogs
I haven't seem much discussion about whether those dialogs should be added to SDL; I open this PR also as a discussion as to whether or not they should be, and which ones are relevant to SDL. I presumed it would be easier to discuss with working code available.
Description
This PR adds the following input dialogs types:
- Text/password input
- Progress/loading bar
- Color picker
- Date picker
These also seem to be available, but I'm not sure if they're globally useful:
- List selection dialogs
- Scale number picker
As of opening the PR, only the Zenity implementation is supported. I chose to open this PR early to get feedback on the current API.
Should I add the two remaining dialog types? More generally, which ones are good to add in SDL?
If some would be good to add:
- Currently all dialogs take an
SDL_PropertiesIDargument; should I make a simple version for each, similarly toSDL_ShowSimpleMessageBox? - Should I re-use the same property field macros for fields that are similar across dialogs? (such as a single
SDL_PROP_DIALOG_TITLE_STRINGfor all dialogs) - For the date picker, I did not re-use the existing SDL_DateTime struct because it seems to be a complete representation of a given timestamp (including the day of the week and the UTC offset), and I wasn't sure how to handle this. I probably should move the code to SDL_DateTime, but I would need guidance on how to design the API.
I should be able to take care of the Windows implementation, but I haven't yet gotten my hands on a new macOS device; help would be welcome.
Existing Issue(s)
Fixes #12792