Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
While all of the changes work well, I am quite new to Rust, and I imagine that many changes will have to be made for the code quality to meet the rest of the Iced code base.
3 things in this pull request:
Adding scroll to
pick_list
sI think that this functionality for pick_lists should be expected. Just allows for selecting from a
pick_list
by scrolling over a closedpick_list
. Though I am not confident with my code quality. It works reliably, but code is a mess. Please let me know how to improve it.Adding
on_scroll
functions totext_input
I added
on_scroll_up
andon_scroll_down
toText_Input
s. I am not confident on implementation nor code quality on this one. I needed it on my project specifically forText_Input
s that the user enters integers, and then scroll for tweaks if wanted (think a timer input that allows to typing in the time as well as scrolling to the time). These functions could also be useful for other widgets (on_scroll_left
could be useful for a slider for example). Though I am open to any code implementation ideas.3. Adding convenience functions forscrollable
sSimple functions just for convenience, rather than having to play with
Rectangles
and content, just one function call to scroll to the bottom. (I use this on a GUI that creates new elements in a list above the create button. The create button is always at the bottom of aScrollable
thus scrolling to the bottom after pressing the create button is convenient).Implemented by #607