Quantcast
Channel: Active questions tagged uipickerview - Stack Overflow
Viewing all articles
Browse latest Browse all 592

Set Different Sizes for UIPickerView Rows

$
0
0

Is it possible to set a different size for each row in a UIPickerView or do they all need to have the same height?

This is what I've tried, but it returns the same height for all rows:

    public func pickerView(_ pickerView: UIPickerView, rowHeightForComponent component: Int) -> CGFloat {    if component == 0 {        return 60    } else {        return 100    }}

Viewing all articles
Browse latest Browse all 592

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>