We have noticed inconsistent left and right margins on iPhone 6+ and iPad, and tracked them down to this spot:
|
- (void)layoutDetailView:(UIView *)view minimumWidth:(CGFloat)minimumWidth |
|
{ |
|
CGFloat cellOffset = 10.0; |
|
CGFloat fieldOffset = 10.0; |
|
|
|
if (self.section.style.contentViewMargin <= 0) |
|
cellOffset += 5.0; |
I guess this was written under the assumption that the default left margin for table cells is always 10.0, which is only true on the smaller iPhone models. We have worked around this issue in our fork by changing the method like this:
jlnr@90fb0b3
I guess one could also fix the inconsistency by resizing self.textLabel, which iOS provides by default, to match the size and margins of RETableViewManager’s custom views. But we want our app to look as native as possible.
This is not ready for a Pull Request because the cellOffset of 10.0 also appears in other cell types which we don't use and haven't tested, and I don't know if we have broken the way the contentViewMargin works.
If you compare the before/after screenshots of the example on iPhone 6+ and iPad, it really looks much more consistent. This is possibly related to issues #249 and #115.
iPhone 6 Plus, before

iPhone 6 Plus, after

iPad, before

iPad, after

We have noticed inconsistent left and right margins on iPhone 6+ and iPad, and tracked them down to this spot:
RETableViewManager/RETableViewManager/RETableViewCell.m
Lines 171 to 177 in 1c71a41
I guess this was written under the assumption that the default left margin for table cells is always 10.0, which is only true on the smaller iPhone models. We have worked around this issue in our fork by changing the method like this:
jlnr@90fb0b3
I guess one could also fix the inconsistency by resizing
self.textLabel, which iOS provides by default, to match the size and margins of RETableViewManager’s custom views. But we want our app to look as native as possible.This is not ready for a Pull Request because the
cellOffsetof 10.0 also appears in other cell types which we don't use and haven't tested, and I don't know if we have broken the way thecontentViewMarginworks.If you compare the before/after screenshots of the example on iPhone 6+ and iPad, it really looks much more consistent. This is possibly related to issues #249 and #115.
iPhone 6 Plus, before
iPhone 6 Plus, after
iPad, before
iPad, after