encourage use of `BoxConstraints::constrain` in all layout methods
Open
Nobody has claimed this yet.
discussion
- Dominant language
- Rust
- Stars
- 9.7k
- Forks
- 565
- PR merge metrics
- No merged PRs in 30d
Description
a general note; I think it's good to call `bc.constrain(size)` anytime you return from layout, as a way of ensuring all returned sizes are appropriate for the constraints.
_Originally posted by @cmyr in https://github.com/xi-editor/druid/pull/845_
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by searching the layout methods that return sizes and the BoxConstraints::constrain API. Determine which returns do not apply the constraints, then verify that each affected layout path returns an appropriate constrained size; the issue names no files or tests, so the full scope must be mapped first.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- frontend
- Issue type
- Refactor
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100