API Proposal - CollapsibleContainer
- Dominant language
- Python
- Stars
- 5.4k
- Forks
- 827
- Avg merge
- 15h 39m
- Merged PRs (30d)
- 40
Description
**Is your feature request related to a problem? Please describe.**
It occurred to me that right now *Toga* doesn't have a collapsible widget (aka. a "box" that can be expanded or collapsed by usually clicking a button with an arrow at the top of it).
I was about to implement this new widget in Windows when I figured out that while WPF has the [expander](https://docs.microsoft.com/en-us/dotnet/api/system.windows.controls.expander?redirectedfrom=MSDN&view=net-5.0) class, Windows form does not. I tried to find a similar widget for Mac but couldn't find either.
It seems too basic not to be supported by all of these platforms and consequentially in *Toga*. Am I missing something?
ATM, we could implement this feature by creating a `toga.Box` with a `toga.Button` that toggles the visibility of this box by pressing on it. However, by doing so we'll lose the "sweeping" effect most collapsible I've seen had.
What are your thoughts?
Contributor guide
Research direction
Start by reviewing Toga's existing Box and Button widgets and the platform support for native GUI controls. Compare the proposed CollapsibleContainer with WPF's Expander and determine whether equivalent behavior exists on the other platforms. Done would require an agreed cross-platform API and implementation plan, including the requested expanding and collapsing effect.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- desktop
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100