Skip to content

Is there a way to make table columns automatically shrink to fit contents? #10

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

Open
mackler opened this issue Jun 10, 2024 · 1 comment

Comments

@mackler
Copy link

mackler commented Jun 10, 2024

New here so sorry if I'm asking something obvious.

I see Column Trait requires function width to return "the fixed width for this column." But must the width be fixed? Because I also see that iced has enum Length with variant Shrink.

Is there a way for the table automatically to figure out how wide its columns should be based on the table content, such that each column is no wider than necessary to fit the widest content in any cell in that column? (aka "shrink to fit")

@Creative-Difficulty
Copy link

@tarkah

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

No branches or pull requests

2 participants