Skip to content

Add AreRowGroupsInitiallyCollapsed for opt-in start-collapsed row groups#242

Open
FoxCouncil wants to merge 2 commits into
AvaloniaUI:masterfrom
FoxCouncil:feat/datagrid-initially-collapsed
Open

Add AreRowGroupsInitiallyCollapsed for opt-in start-collapsed row groups#242
FoxCouncil wants to merge 2 commits into
AvaloniaUI:masterfrom
FoxCouncil:feat/datagrid-initially-collapsed

Conversation

@FoxCouncil

Copy link
Copy Markdown

Adds an opt-in AreRowGroupsInitiallyCollapsed property (default false) so a grouped DataGrid can start with its row groups collapsed.

The only existing way to collapse a group is CollapseRowGroup, which needs a realized header and runs after layout, so the expanded rows show for one frame before they collapse. This seeds the collapsed state while the row groups are generated instead: the groups start hidden, their child slots are added to the collapsed slots table, and they are excluded from the visible slot count. The first layout is already collapsed and the scroll extent is correct.

When false (the default), behavior is unchanged.

Relates to #46.

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

Successfully merging this pull request may close these issues.

1 participant