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

Add a wrap widget #12

Merged
merged 13 commits into from
May 24, 2021
Merged

Add a wrap widget #12

merged 13 commits into from
May 24, 2021

Conversation

Cupnfish
Copy link
Contributor

@Cupnfish Cupnfish commented Apr 28, 2021

Add a wrap widget

  • Finish the document
  • Add optional directions

At present, horizontal direction can be used. My English is not good enough, so I need you to help me think about the document part.
demo

@Kaiden42
Copy link
Collaborator

Kaiden42 commented May 4, 2021

This is a great widget. 👍

I hope I find the time tomorrow evening to take a closer look at it and to add the missing documentation.

@Kaiden42
Copy link
Collaborator

Kaiden42 commented May 6, 2021

Alright, I've now updated the documentation of the code. 🙂

@Cupnfish
Copy link
Contributor Author

Cupnfish commented May 7, 2021

Cool, I will implement optional directions next.

@Cupnfish
Copy link
Contributor Author

Currently supports optional direction, but alignment is not implemented, this part I don't have strong demand, therefore no strong desire to impl it.

Because a lot of changes, the document also needs to be updated.

I haven't implemented alignment yet, but I'll do it in the future if I have time.Of course, it would be nice to see if anyone is interested in making it happen ahead of me.I need you to help me mark this part in the document , to mark that this part has not been implemented yet. Thank you very much.

@Cupnfish Cupnfish marked this pull request as ready for review May 15, 2021 08:49
@Cupnfish
Copy link
Contributor Author

OK, this is actually done, even the align has been implemented.

@Kaiden42
Copy link
Collaborator

Awesome work! 🙂
Could you update the example so, that it is able to show all different kinds of directions and alignments? This would present the possibilities of your widget better.

Is there a reason of why you are using two different structs for the direction instead of one enum?

@Cupnfish
Copy link
Contributor Author

I’ve updated the example, why do I use different structs instead of enumerations because it’s better in performance? This is one of the reasons, mainly to correspond to iced’s row and column.

@Kaiden42 Kaiden42 merged commit ec590af into iced-rs:main May 24, 2021
@Kaiden42
Copy link
Collaborator

why do I use different structs instead of enumerations because it’s better in performance? This is one of the reasons, mainly to correspond to iced’s row and column.

I was just curious. I didn't know there was such a big difference in performance.

Alright! Thank you very much for such a nice widget. 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants