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

Improve column autosizing #3343

Open
karliss opened this issue May 19, 2024 · 0 comments
Open

Improve column autosizing #3343

karliss opened this issue May 19, 2024 · 0 comments
Labels

Comments

@karliss
Copy link
Member

karliss commented May 19, 2024

Is your feature request related to a problem? Please describe.

Multiple panels in Cutter are using the same function for autosizing column width based on content. It somewhat solves the issue of hardcoded default width being too small.

The problem is that if some of table entries contain very long text, that stretches the whole table horizontally to the point where it becomes impractical.

It's always possible for user to manually adjust column width, but cutter should do it's best to minimize the situations where it's necessary.

With the current behavior once a column gets assigned width greater than table width, it becomes a bit finicky to even manually resize it. It's easier to manually make a narrow column wider, than the opposite. Having many columns to wide also makes it easier to not notices that there are more columns if you don't pay attention to horizontal scrollbar.

Describe the solution you'd like

Add a bit more logic to column autosizing function to reduce the chance of badly chosen default column width:

  • maybe limit automatically assigned column width to no more than %50 of table width
  • the previous rule could be ignored if total width of preferred column widths wouldn't exceed available space (for example 10%+80% would be fine, but 70%+70%+80% is not)

Describe alternatives you've considered

Additional context

@karliss karliss added the UI label May 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant