I'd call my skills to be almost "basic", I understand most of what i read and see when it comes to objective-c but this is a bit outta the grasp of my comprehension.
i have a tableView with a transparent background along with transparent cells, unfortunately the person i am developing the app for insists on having a background show thru that is primarily grey. My issue is the index bar to the right. I have read that text color, background color and the likes are off limits when it comes to customization. Has anyone created their own index bar and attached it to the tableView's scrolling methods?
like i said i am at a loss when it comes as to where to even begin. All i need i belive is a point in the right direction. do i need to create a small UIView and play with the touch events?
The tableview is the instance of the UITableView class, which inherits the UIScrollView class.
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.
A table view displays a single column of vertically scrolling content, divided into rows and sections. Each row of a table displays a single piece of information related to your app. Sections let you group related rows together. For example, the Contacts app uses a table to display the names of the user's contacts.
Just do it like that:
if ([[self tableView] respondsToSelector:@selector(setSectionIndexColor:)])
{
// In iOS 6 there is a own method available to set the index color
[[self tableView] setSectionIndexColor:[UIColor whiteColor]];
}
else
{
// Use this hack in previous iOS releases
for(UIView *view in [self.tableView subviews])
{
if([view respondsToSelector:@selector(setIndexColor:)])
{
[view performSelector:@selector(setIndexColor:) withObject:[UIColor whiteColor]];
}
}
}
if yo want to make any change in indexbar you should use CAlayer.
Set UITableViewCell background color using a CALayer
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With