-
Notifications
You must be signed in to change notification settings - Fork 786
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
New input element #129
base: master
Are you sure you want to change the base?
New input element #129
Conversation
@sapessi does this work? Then I'll use your fork as the dep unless this is merged :D |
@meetmangukiya It does work, although I have tested all of the use-cases. Have a go and see if it works for you. If you find an issue let me know. |
Ok, I'll have a go at it |
@meetmangukiya Did this work for you? |
@liushuchun Do you expect it to be right to left or also vertical? This is definitely something that can be added. |
@sapessi Great stuff. Would love to see this merged. What is blocking it? |
@sapessi Thanks for the PR. If found a little bug within your PR, this the code I've tested: input := ui.NewInput("FOO BAR", false)
input.StartCapture() On startup just press backspace when the courser is on the first position.
If no string has been passed to the constructor everything works fine. I'm not sure if I did something wrong with the initialisation. Edit: Edit 2:
|
@Griesbacher could be a bug, I'll look into it this weekend. |
@Griesbacher fixed those issues and added unit tests for them in the latest commit. |
what's preventing this to be merged? can we get this one going into master? |
@gizak Should we close this pull request now that you've imported the input in a commit? |
@sapessi which commit? |
Never mind, I confused the pull to another repo for this. @gizak, any idea whether this will be merged? |
Any chances this could get merged? I think an input control would be really handy and I would love to use something already pre-existing. I don’t think it’s useful everyone implements a from scratch input control every time. |
@kellabyte I'm currently finishing up rewriting termui but once I'm done with that I'll merge this and the other PRs too. |
16a8706
to
0819f87
Compare
d3e2ed4
to
0eb6d61
Compare
d95d1d6
to
a795c07
Compare
32a5f54
to
6d201dc
Compare
I am wondering if the rewrite is included in version v3.0.0 released a week ago? I am using termui and now need to implement some sort of input form. Is this pull request still planned to be included at some point? I tried creating a local copy of |
The rewrite is included in v3.0.0. So this PR is incompatible with the recent changes, so I've been working on rewriting it. You can check out the progress at the
The widget is called Feel free to create PR's against that branch if you end up using it. |
Thanks @cjbassi, I will try the code on |
Hi @cjbassi , I started using the textbox widget and it looks cool. I was not able to find a method to retrieve back the text inputted and I am thinking of submitting a pull request adding a GetText() function. Does that make sense to you? For completion I am actually thinking of two functions:
|
@andre-l-mm Both of those sound good! |
Hello, Have you an idea when this will be released ? :D Regards |
God has left us. |
Still missing lots of unit tests :( I'll keep working on them