Bug 43161 - Setting Accessory in ViewCellRenderer breakes layout
Summary: Setting Accessory in ViewCellRenderer breakes layout
Alias: None
Product: Forms
Classification: Xamarin
Component: iOS ()
Version: 2.3.1
Hardware: PC Windows
: Normal normal
Target Milestone: ---
Assignee: Bugzilla
Depends on:
Reported: 2016-08-08 09:16 UTC by John Eriksson
Modified: 2016-09-15 16:25 UTC (History)
5 users (show)

Tags: ac
Is this bug a regression?: Yes
Last known good build:

Small sample project showing the problem. (160.44 KB, application/x-zip-compressed)
2016-08-08 09:16 UTC, John Eriksson

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.

Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:

Description John Eriksson 2016-08-08 09:16:17 UTC
Created attachment 16940 [details]
Small sample project showing the problem.

​When setting the Accessory on a ViewCell in a custom ViewCellRenderer on iOS (8.4 and 9.3) the layout starts outside the screen to the left.

* If we use a TextCell and a TextCellRenderer it works.
* If we change the caching strategy to RetainElement instead of RecycleElement it works.
* It works in Xamarin.Forms and
* It doesn’t work in Xamarin.Forms or
Comment 1 Hrafn Loftsson 2016-08-15 08:52:43 UTC
I can confirm this bug as well in Xamarin.Forms  Additional info:

This only happens if a ViewCellRenderer in iOS sets the cell.Accessory and either
caching strategy is set to RecycleElement or ViewCell.ContextActions (e.g. MenuItem) is set.

A sample project is here: https://github.com/KolibriDev/TestLayoutXaml
Comment 2 David.Withnall 2016-08-29 07:58:25 UTC
We have come across this bug as well since moving to

Confirmed that is is broken (offset on left of screen) when using:
 Disclosure accessory AND ContextActions AND RetainElement
Comment 3 Samantha Houts [MSFT] 2016-09-13 16:54:21 UTC
Should be fixed in 2.3.2 stable. Thank you!
Comment 4 Parmendra Kumar 2016-09-15 16:25:21 UTC
I have checked this issue with Xamarin.Forms and its working fine.

Hence closing this issue.