Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

UITableView Separator line

How can I change the separator line that appears at the end of each cell in UITableView? I want to have an image that is a thin separator type line image.

like image 694
Mobile Developer iOS Android Avatar asked Jan 26 '11 12:01

Mobile Developer iOS Android


People also ask

How do I remove a separator from a table view?

To hide UITableViewCell separator completely, simply set it's colour to UIColor. clearColor(). This will make the cell separator not visible.

What is a UITableView?

UITableView manages the basic appearance of the table, but your app provides the cells ( UITableViewCell objects) that display the actual content. The standard cell configurations display a simple combination of text and images, but you can define custom cells that display any content you want.


1 Answers

Set the separatorStyle of the tableview to UITableViewCellSeparatorStyleNone. Add your separator image as subview to each cell and set the frame properly.

like image 52
Felix Avatar answered Sep 19 '22 03:09

Felix