objective-c 随便记记

时间:2023-03-09 03:38:37
objective-c 随便记记

1、tableview滚动到某一位置

[tableViewShow setContentOffset:CGPointMake(0, 0) animated:YES];

//解决tableView分割线左边不到边的情况
    if ([tableView respondsToSelector:@selector(setSeparatorInset:)]) {
        [tableView setSeparatorInset:UIEdgeInsetsZero];
    }

按钮中的文字的左对齐

[titleButton setContentHorizontalAlignment:UIControlContentHorizontalAlignmentLeft];