Untitled
unknown
plain_text
2 years ago
587 B
5
Indexable
public partial class MainPage : ContentPage
{
public MainPage()
{
InitializeComponent();
}
private void Slider_ValueChanged(object sender, ValueChangedEventArgs e)
{
var red = sldRed.Value;
var green = sldGreen.Value;
var blue = sldBlue.Value;
Color color = Color.FromRgb(red, green, blue);
SetColor(color);
}
private void SetColor(Color color)
{
btnRandom.BackgroundColor = color;
Container.BackgroundColor = color;
lblHex.Text = color.ToHex();
}
}Editor is loading...
Leave a Comment