This is a migrated thread and some comments may be shown as answers.

Disabled Checkbox color in UWP

3 Answers 279 Views
CheckBox
This is a migrated thread and some comments may be shown as answers.
Larry
Top achievements
Rank 1
Iron
Iron
Veteran
Larry asked on 11 Apr 2021, 02:51 AM
     How do I change the color of disabled check boxes in UWP? The color now is a dark blue.

3 Answers, 1 is accepted

Sort by
0
Accepted
Yana
Telerik team
answered on 13 Apr 2021, 05:09 AM

Hello Larry,

You would need to copy the default template and styles of the UWP CheckBox to the UWP project app resources and modify the required colors directly there. By default, the disabled colors are set to the system disabled brushes.

Please find attached a sample app showing the approach - just copy the Style targeting ExtendedCheckBox into your App.xaml file inside the UWP project, add the needed telerik namespace:

xmlns:telerik="using:Telerik.XamarinForms.PrimitivesRenderer.UWP"

And modify the colors inside UncheckedDisabled and CheckedDisabled visual states.

I hope I was of help.

Regards,
Yana
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

0
Larry
Top achievements
Rank 1
Iron
Iron
Veteran
answered on 13 Apr 2021, 10:35 PM

Thank you, I'm sure this is exactly what I need. At the risk of asking a dumb question... :)

How would I have gotten the default template and styles of the Xamarin Forms UWP CheckBox for myself?

0
Yana
Telerik team
answered on 14 Apr 2021, 07:32 AM

Hi Larry,

I am afraid for the time being we do not ship separately the UWP styles and templates. In general, we provide styling API which should be enough to style the controls. In the case with disabled checkbox color - usually users would prefer relying on the native styling (coming from the target platform), that's the reason we do not expose it as a separate property.  If this becomes a common requirement, we'll consider exposing it as a style property. 

In the meantime, if you have any additional questions on styling the CheckBox, or any other control, we'll be glad to help.

Regards,
Yana
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

Tags
CheckBox
Asked by
Larry
Top achievements
Rank 1
Iron
Iron
Veteran
Answers by
Yana
Telerik team
Larry
Top achievements
Rank 1
Iron
Iron
Veteran
Share this question
or