Quantcast
Channel: Xamarin.Forms — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 58056

Setting accessory type in ViewCellRenderer (iOS) causes misalignment of ListView items

$
0
0

When setting the accessory type (Checkmark, DisclosureIndicator, etc) for a UITableViewCell within a custom ViewCellRenderer, the horizontal positioning of the cell within the ListView becomes inconsistent with other cells that do not have an accessory, as well as with those that have a different accessory type. Basically, all I want to be able to do is have a ListView containing items that potentially have different accessories and decorations.

I must be missing something, but I haven't found a reliable way to force the cell to properly left-align within the ListView/UITableViewCell. If I add a dummy UIView as the AccessoryView for the cells that don't have accessories, the start of the cell is shifted right by a corresponding amount.

Is there a good way to do this that I'm missing, or is there a better approach for what I'm trying to achieve?


Viewing all articles
Browse latest Browse all 58056

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>