Notice (2018-05-24): bugzilla.xamarin.com is now in
Please join us on
Visual Studio Developer Community and in the
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
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.
When a button's style is changed and the button is disabled (IsEnabled=false) the styling does not work.
A sample solution is available at https://github.com/KolibriDev/TestXFBugs
This project has Xamarin.Forms 126.96.36.199 installed.
To replicate the problem:
* Build and run the Droid project.
* Navigate to the PinPage from the LoginPage (by filling out all entries)
* Click twice on any button on the PinPage
* The text for the buttons disappears
When the user clicks twice on any button on the PinPage, all buttons become disabled and the style WhiteButtonDisabled is applied which should change the TextColor of the buttons. Instead, the text for the buttons disappears. Note that if the buttons are not disabled when changing the style, the styling works.
XF doesn't expose properties to set disabled colors on controls. the style looks correctly applied, but given your style and the disabled state applied by android, your text is no longer visible. Tweak your style os that, once desaturated by android, you're still able to read the numbers
e.g., this style shows that the disabled style is applied, and the text is readable
<Style x:Key="WhiteButtonDisabled" TargetType="Button">
<Setter Property="BackgroundColor" Value="Red" />
<Setter Property="TextColor" Value="Black" />
<Setter Property="FontSize" Value="16" />
I have now changed the solution so it uses custom renderers to change text and background colors when the buttons are disabled.
It is strange, however, that the button's text on Droid is visible in XF 188.8.131.52, but not visible in XF 184.108.40.206.