iOS透明UIButton实现方法

- (UIView *)tableView:(UITableView *)tableView viewForHeaderInSection:(NSInteger)section
{
    UIButton *sbutton = [UIButton buttonWithType:UIButtonTypeRoundedRect];
   
    sbutton.backgroundColor = [UIColor clearColor];
   
    [sbutton addTarget:self action:@selector(changename) forControlEvents:UIControlEventTouchUpInside];

    return sbutton;
   
}

猜你喜欢

转载自lizhuang.iteye.com/blog/1985116