britzl / defold-input

Simplify input related operations such as gesture detection, input mapping and clicking/dragging game objects
MIT License
111 stars 26 forks source link

Adding textbox modul and example #36

Closed Azurac closed 6 months ago

Azurac commented 8 months ago

Hi, this library was a huge help at the very beginning and will still be in the future since the only modules I used so far were buttons and cursor.

Buttons are really easy to use but what I was still missing was some text field. Therefore I decided to expand this library.

I tried to stick to your code format as much as possible. I did not manage to expand your tests though.. I do not understand them enough. I know the textbox.lua and button.lua share large proportion of the same code now, but I did not want to change your module.

Feel free to reject this pull request, no hard feelings. I just thought it could come in handy to someone at the beginning. Also I did this as an example of your comment in this question: [Inputting into a textbox](https://forum.defold.com/t/inputting-into-a-textbox/71417)

Thanks and regards Azurac

Azurac commented 8 months ago

Both seem very interesting. Thanks for your recommendation, I'll definitely try them. 🙂

Azurac commented 7 months ago

Sorry, I did not have much time lately. I fixed the typo you mentioned.

Azurac commented 6 months ago

Well, since this wasn't merged until you made another changes I suppose it is rejected, so I will close this PR now.

britzl commented 6 months ago

Well, since this wasn't merged until you made another changes I suppose it is rejected, so I will close this PR now.

Ah, sorry about this. It was not rejected. I've merged it now.