iphone - 两个UITableViewCellStyleDefault单元格之间的一个像素-无法在其上绘制

标签 iphone ios uitableview uibutton

我想在一个单元格中绘制2个按钮,当按下按钮时,蓝色图像将覆盖单元格的一半。

但是我无法绘制1个像素。

情况如下:

和代码:

[self addGood12ToView:cell.contentView productDetail:productDetail];

在此函数中,我调用了:
UIButton *lbGood1 = [UIButton buttonWithType:UIButtonTypeCustom];
[lbGood1 setFrame:CGRectMake(0, 0, 150, lbGood1_Size.height+19)];
...
[cell.contentView addSubview:lbGood1];

最佳答案

对此进行检查可能对您有很大帮助。

self.yourTableView.separatorStyle=UITableViewCellSeparatorStyleNone;

关于iphone - 两个UITableViewCellStyleDefault单元格之间的一个像素-无法在其上绘制,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11392340/

相关文章:

iphone - shouldChangeCharactersInRange 一次只取一位数字

ios - 仅显示 7 个 uicollectionview 单元格

ios - 由于 prepareForReuse,图像在单元格中时 UITableView 滚动错误

ios - UITableView 的 LikeButton

ios - iOS 中有类似 Telephony.SECRET_CODE 的东西吗?

iphone - 如何删除 UITextView 中的所有按钮?

iPhone - 将相机照片保存到 iPhone 相册时崩溃

ios - 找不到广告网络适配器

ios - AVSpeechsynthesizer 无法在 swift 的 api 调用中工作

ios - 将数据源分离到 Swift 中的另一个类