Skip to content
This repository has been archived by the owner on Aug 6, 2023. It is now read-only.

chore: fix table example #562

Merged
merged 1 commit into from Nov 21, 2021
Merged

chore: fix table example #562

merged 1 commit into from Nov 21, 2021

Conversation

fdehau
Copy link
Owner

@fdehau fdehau commented Nov 21, 2021

Description

Third column in table example was using the Max constraint.

But since version 0.16, the layout system does not add a hidden constraint on the last column which would ensure that it fills the remaining available space (a change that was already mentioned in #525). In addition, tui does not support sizing based on content because of its immediate mode nature. Therefore, Max is now resolved to 0. Replacing with Min fixes the issue.

A new way of specifying constraints is being worked on at #519 which should for more deterministic and advanced layout.

Fixes #561

Testing guidelines

cargo run --example table

Checklist

Third column in table example was using the `Max` constraint.

But since version 0.16, the layout system does not add a hidden constraint on the last column which would ensure that it fills the remaining available space (a change that was already mentioned in #525). In addition, `tui` does not support sizing based on content because of its immediate mode nature. Therefore, `Max` is now resolved to `0`. Replacing with `Min` fixes the issue.

A new way of specifying constraints is being worked on at #519 which should for more deterministic and advanced layout.
@fdehau fdehau merged commit 8032191 into master Nov 21, 2021
@fdehau fdehau deleted the table-example branch November 21, 2021 20:00
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Table example does not work
1 participant