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

关于当JXSegmentedCollectionView的ContentSize小于父视图宽度时整体居中的问题 #239

Closed
wxw962530118 opened this issue Dec 3, 2023 · 1 comment

Comments

@wxw962530118
Copy link

举例说明如下:
1.JXSegmentedView与当前父视图都是屏幕宽度,但是在数据源很少的时候(JXSegmentedCollectionView的ContentSize小于父视图宽度),设置contentEdgeInsetLeft和contentEdgeInsetRight并不能达到整体居中,相同配置在两台设备上显示效果完全不同
iPad效果
Snipaste_2023-12-03_22-26-24
iPhone效果
Snipaste_2023-12-03_22-27-06

@pujiaxin33
Copy link
Owner

可以参考《导航栏使用》示例,让JXSegmentedView居中显示在视图中,但是宽度只是内容宽度。

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

No branches or pull requests

2 participants