Closed tciuro closed 7 years ago
@tciuro Yes, you are right. It's misaligned for single row. After an initial investigation, I found paragraphStyle.lineSpacing = 5.0;
doesn't work well at that scenario. Set it to zero can fix the issue immediately; however, I'm gonna think a little bit to see if there is any better solution once I have spare time.
Thanks a lot Allen. I'll give it a try.
@tciuro You are welcome. By the way, it turns out that lineSpacing
is applied regardless of how many lines in UILabel, I give up explicitly setting it, instead of adjusting NSLayoutAttributeTop
and NSLayoutAttributeBottom
to avoid the misalignment when tags are in one row.
Looks great. Thank you!
Allen, this is very cool. Very nicely implemented. 👍🏻
I have one comment though: in the example you provide (see your screenshot for reference), the Pinterest row is misaligned: the tags are not centered in the cell. However, for multi-line rows, it looks fine.