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

New SplitLayout #570

Merged
merged 34 commits into from
Sep 6, 2024
Merged

New SplitLayout #570

merged 34 commits into from
Sep 6, 2024

Conversation

hamen
Copy link
Collaborator

@hamen hamen commented Aug 30, 2024

This PR introduces the new SplitLayout. The implementation takes inspiration from the existing one and from the Accompanist TwoPane one.

Main points

  • Colors match Swing
  • The divider is draggable
  • The divider is 1.dp wide, with an invisible wider area around it to facilitate click & dragging
  • The divider position can be remembered in upper components or in a ViewModel
  • The divider cannot be focused
  • It allows nested layouts
  • It allows minimum widths. When the available width is less than the desired panes minimum width, it shrinks the panes, keeping the expected ratio. This mirrors the Swing behavior.

@hamen hamen requested a review from rock3r August 30, 2024 11:22
@hamen hamen self-assigned this Aug 30, 2024
@hamen hamen linked an issue Sep 3, 2024 that may be closed by this pull request
5 tasks
@hamen hamen marked this pull request as ready for review September 3, 2024 09:27
@rock3r rock3r added bug Something isn't working feature New feature or request labels Sep 3, 2024
@hamen hamen force-pushed the im-splitlayout branch 3 times, most recently from 79da995 to a55e52b Compare September 4, 2024 14:01
hamen added a commit that referenced this pull request Sep 5, 2024
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
hamen added a commit that referenced this pull request Sep 5, 2024
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
hamen added a commit that referenced this pull request Sep 5, 2024
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
hamen added a commit that referenced this pull request Sep 5, 2024
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
hamen added a commit that referenced this pull request Sep 5, 2024
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
hamen added a commit that referenced this pull request Sep 5, 2024
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
hamen added a commit that referenced this pull request Sep 5, 2024
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
hamen added a commit that referenced this pull request Sep 5, 2024
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
hamen added a commit that referenced this pull request Sep 5, 2024
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
hamen added a commit that referenced this pull request Sep 5, 2024
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
hamen added a commit that referenced this pull request Sep 5, 2024
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
hamen added a commit that referenced this pull request Sep 5, 2024
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
hamen added a commit that referenced this pull request Sep 5, 2024
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
hamen added a commit that referenced this pull request Sep 5, 2024
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
hamen added a commit that referenced this pull request Sep 5, 2024
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
hamen added a commit that referenced this pull request Sep 5, 2024
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
hamen added a commit that referenced this pull request Sep 5, 2024
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
hamen added a commit that referenced this pull request Sep 5, 2024
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
reference: #570 (comment)
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
Signed-off-by: Ivan Morgillo <imorgillo@gmail.com>
@rock3r rock3r enabled auto-merge (squash) September 6, 2024 12:29
@hamen hamen requested a review from rock3r September 6, 2024 12:30
Copy link
Collaborator

@rock3r rock3r left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested and validated locally, great job!

@rock3r rock3r merged commit 5efee37 into main Sep 6, 2024
1 check passed
@rock3r rock3r deleted the im-splitlayout branch September 6, 2024 12:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working feature New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Rewrite split layouts
2 participants