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

Fix issue with NSCollectionView and single column views #319

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

johnathan-becker
Copy link
Contributor

This pull request improves the frameForItemAtIndex: method by refining the layout calculation logic for items. I removed the _horizontalMargin offset from the initial x position to align items more precisely with the view’s edges, standardizing row alignment by resetting x to 0 at the start of each row, and introducing dynamic resizing for single-column layouts, ensuring items span the full width of the view. These updates enhance the visual consistency of both multi-column and single-column layouts, while maintaining functionality for features like dragging offsets. The changes have been tested to ensure alignment and layout behavior remain robust and predictable.

Screenshot from 2024-11-15 13-03-50
Screenshot from 2024-11-15 12-56-32

@johnathan-becker
Copy link
Contributor Author

@fredkiefer I believe automation is just broken on master. I am getting the same failures on this MR.

@fredkiefer
Copy link
Member

As this class was mostly written by Greg, I think it would be better for him to review this change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants