Recusiwe Recusiwe - 6 months ago 10
iOS Question

Too much space between cells

I'm having trouble with reducing the spacing between my cells, I want it to be 1 px. Inside my cell I have a stackView which fills my entire cell, both set to 70.

I can accomplish almost what I want by adding negative constrains, but then my cells gets too big, I only want it to be 70. I set the cell to 70 in the custom cell class

self.frame.size.height = 70

And my stackView is set to the very same. I don't see why I get that amount of spacing between my cells?

enter image description here


Please use the below method to adjust the cell height;

- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath

    return 78;