Beispiel #1
0
 public static void UpdateTextColor(this AppCompatButton button, XColor color, ColorStateList?defaultColor)
 {
     if (color.IsDefault)
     {
         button.SetTextColor(defaultColor);
     }
     else
     {
         button.SetTextColor(color.ToNative());
     }
 }
Beispiel #2
0
 public static void SetTextColor(this TextView label, Color color)
 {
     label.SetTextColor(color.ToNative());
 }
Beispiel #3
0
 public static void SetTextColor(this UIButton button, Color color)
 {
     button.SetTitleColor(color.ToNative(), UIControlState.Normal);
 }
Beispiel #4
0
 public static void SetTextColor(this UILabel label, Color color)
 {
     label.TextColor = color.ToNative();
 }
Beispiel #5
0
 public static void SetTextColor(this TextBlock textBlock, Color color)
 {
     textBlock.Foreground = new SolidColorBrush(color.ToNative());
 }
Beispiel #6
0
 public static Bitmap AssertContainsColor(this AView view, Xamarin.Forms.Color expectedColor) =>
 AssertContainsColor(view, expectedColor.ToNative());
 public static UIImage AssertContainsColor(this UIView view, Xamarin.Forms.Color expectedColor) =>
 AssertContainsColor(view, expectedColor.ToNative());