Bug 26895 - Video for Xamarin Forms 1.3.x visibility issue from forum post
Summary: Video for Xamarin Forms 1.3.x visibility issue from forum post
Status: RESOLVED FIXED
Alias: None
Product: Forms
Classification: Xamarin
Component: Forms ()
Version: 1.3.3
Hardware: PC Mac OS
: Highest normal
Target Milestone: ---
Assignee: Seth Rosetter
URL:
Depends on:
Blocks:
 
Reported: 2015-02-10 01:12 UTC by Dominic N [MSFT]
Modified: 2015-06-15 11:41 UTC (History)
11 users (show)

Tags: isvisible RA
Is this bug a regression?: ---
Last known good build:


Attachments
Sample IsVisible Control Rendering Issue (5.12 MB, application/x-zip-compressed)
2015-02-10 10:11 UTC, Wayne
Details
IsVisible in a StackLayout painting wrong w 1.3.4 (327.40 KB, application/x-zip-compressed)
2015-02-10 18:05 UTC, Wayne
Details
IsVisibleTest2-5 showing button IsVisible fail (5.13 MB, application/x-zip-compressed)
2015-02-13 16:55 UTC, Wayne
Details


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:
Status:
RESOLVED FIXED

Description Dominic N [MSFT] 2015-02-10 01:12:34 UTC
## Overview

After being requested to share a video by Jason, a customer from the forums emailed into the support team a video of an issue they were seeing with refresh/repainting issues when hiding/showing controls using the IsVisible flag with the 1.3.x releases. They indicate that the issue was not present with the 1.2.x releases. 

They have tried to put together a sample to repro the issue, but haven't been successful thus far.

The forum post in question is: http://forums.xamarin.com/discussion/comment/101413/#Comment_101413
Comment 2 Wayne 2015-02-10 10:11:33 UTC
Created attachment 9751 [details]
Sample IsVisible Control Rendering Issue

I've created a sample project with the issue.  It happens in 1.3.x releases.  It happens less with 1.3.4 Pre-release; however, it has kind of morphed on this latest pre-release to occur when toggling the IsVisible property on a custom control (ImageButton in sample project).  In prior 1.3.x releases, once the control (Label, Image, ImageButton, etc.) was painted for the first time, it had no problem re-painting on subsequent toggles for the IsVisibleProperty.  With the 1.3.4 pre-release, subsequent toggles of the IsVisibleProperty to true can result in re-painting issues for the custom control.
Comment 3 Wayne 2015-02-10 18:05:12 UTC
Created attachment 9759 [details]
IsVisible in a StackLayout painting wrong w 1.3.4

The attached solution was tested with 1.3.4 pre1.  It shows that when a control in a stackLayout is toggled to invisible (bound to IsVisibleProperty), the stacklayout width goes to zero (even though other contents exist in the stacklayout that should be rendered).  In the sample, click the refresh button to see the container widths rendered.  Then click the collapse image in the right stackLayout...immediately, the entire stackLayout width is set to 0.  Refresh to see that the StackLayout still has a view with width.  Then click the Add right stack view back to get the view to be put back...note: if the view is put back with the expand/collapse image that is bound to IsVisible = false, the view will not render.

Only the Image should be invisible...not the entire stackLayout set to 0.
Comment 4 Jason Smith [MSFT] 2015-02-13 07:35:30 UTC
This is resolved completely now in 1.3.4-pre4
Comment 5 Wayne 2015-02-13 16:49:34 UTC
Hey Jason,

1.3.4-pre4 is looking better and also working better on Android too.

I have confirmed that this issue seems to be mostly resolved with 1.3.4-pre4.  It looks like buttons are still having problems re-rendering when going to IsVisible=true from a bound value (sometimes).  We're also experiencing it on a custom ImageButton (that's based on a button); however, it's also happening on standard button controls as well.

I'll submit another IsVisibleTest2-5 project to show the issue.  Just set the count of toggles to 1 and click to toggle from visible-to invisible-to visible. After a while I was able to see the problem in iOS 8.1 iPad Retina simulator.

Thanks for your quick response to this issue,

Wayne
Comment 6 Wayne 2015-02-13 16:55:25 UTC
Created attachment 9830 [details]
IsVisibleTest2-5 showing button IsVisible fail

As promised, here's the sample.
Comment 7 Dominic N [MSFT] 2015-02-17 15:06:27 UTC
I have tested this out with Forms 1.3.4 final and have been able to reproduce the issue Wayne is seeing using the test project in comment #c6.
Comment 8 Jason Smith [MSFT] 2015-02-17 15:08:56 UTC
Thank you will look into it.
Comment 10 Seth Rosetter 2015-05-29 17:54:12 UTC
Wayne, 

Updating to 1.4.2 seems to resolve the issue. Please re-open if you can still reproduce the problem on 1.4.2.

Thank you for providing the reproduction.

- Seth
Comment 11 Guy Lescalier 2015-06-12 05:17:39 UTC
Still having issues with 1.4.2 on iOS.
I have images (used as buttons) displayed or not according to the state of my UI.
Sometimes the image supposed to be displayed is just not.