首页 > 解决方案 > 如何在我的单元格中更改附件类型 -> 披露指示器颜色?

问题描述

我无法更改Accessory Type->Disclosure Indicator viewUItableviewCell 中的默认颜色。

当我更改 tableviewcell 色调颜色时,它会更改以下附件类型视图颜色。

但我无法更改“披露指示器”颜色。

除了在附件视图中设置图像之外,您还有其他选择来更改“披露指示器”颜色吗?

截图:

细胞:
细胞

Xcode 菜单:
xcodemenu

标签: iosiphonexcodeuitableview

解决方案


你可以把你的形象放进去accessoryView,你的问题就解决了。

示例代码 将此代码放入cellForRowAtIndexPath

UIImageView *imgView = [[UIImageView alloc] initWithFrame:CGRectMake(0, 11, 22, 22)];
imgView.contentMode = UIViewContentModeScaleAspectFit;
imgView.image = [UIImage imageNamed:@"IconMore"];
cell.accessoryView = imgView;

在此处输入图像描述


推荐阅读