I found some answers of how you can move the cell text to the right, BUT HOW can I move the section's text to the right?
Asked
Active
Viewed 1,200 times
2 Answers
3
If by "section's text" you mean the text in the header for the section, you'll need to switch from using tableView:titleForHeaderInSection:
in your data source to supplying a custom UILabel
with textAlignment
set to UITextAlignmentRight
via tableView:viewForHeaderInSection:
in your delegate.

warrenm
- 31,094
- 6
- 92
- 116
-
Thanks!Now I just have to figure out hot to place it correctly. It's a little bit behind its items... – AYBABTU Nov 12 '10 at 19:23
-
You'll also want to implement `tableView:heightForHeaderInSection:` to tell the table view how much space should be allocated to the label. Sounds like it's a bit large for the default size. – warrenm Nov 12 '10 at 22:04
2
Instead of -tableView:titleForHeaderInSection:
, override -tableView:viewForHeaderInSection:
and return a custom view for each section. You can format it in any way you want.

Ole Begemann
- 135,006
- 31
- 278
- 256