From 06562b8f407466cbf78f6a7060164e1744ef1c30 Mon Sep 17 00:00:00 2001 From: Jonathan Peppers Date: Fri, 5 Mar 2021 09:27:27 -0600 Subject: [PATCH] [catalyst] make label visible in dark mode In dark mode, the app was completely white. It seems we can just use no background color, and I get the system default background color. I used `Blue` text like the iOS sample. --- HelloMacCatalyst/AppDelegate.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/HelloMacCatalyst/AppDelegate.cs b/HelloMacCatalyst/AppDelegate.cs index f87c1b24a..c58112f11 100644 --- a/HelloMacCatalyst/AppDelegate.cs +++ b/HelloMacCatalyst/AppDelegate.cs @@ -23,9 +23,9 @@ public override bool FinishedLaunching(UIApplication application, NSDictionary l var vc = new UIViewController (); vc.View.AddSubview (new UILabel (Window.Frame) { - BackgroundColor = UIColor.White, TextAlignment = UITextAlignment.Center, - Text = "Hello, .NET 6!" + Text = "Hello, .NET 6!", + TextColor = UIColor.Blue, }); Window.RootViewController = vc;