diff --git a/WinFormsThemes/WinFormsThemes.Example/FrmDefault.Designer.cs b/WinFormsThemes/WinFormsThemes.Example/FrmDefault.Designer.cs index c4913c8..3cccfa2 100644 --- a/WinFormsThemes/WinFormsThemes.Example/FrmDefault.Designer.cs +++ b/WinFormsThemes/WinFormsThemes.Example/FrmDefault.Designer.cs @@ -1,4 +1,4 @@ -namespace StylableWinFormsControls.Example +namespace StylableWinFormsControls.Example { partial class FrmDefault { @@ -218,15 +218,15 @@ private void InitializeComponent() stylableTextBox1.BorderStyle = BorderStyle.None; stylableTextBox1.DelayedTextChangedTimeout = 900; stylableTextBox1.ForeColor = Color.Gray; - stylableTextBox1.Hint = "Hello, my name is ..."; - stylableTextBox1.HintForeColor = Color.Gray; + stylableTextBox1.PlaceholderText = "Hello, my name is ..."; + stylableTextBox1.PlaceholderForeColor = Color.Gray; stylableTextBox1.IsDelayActive = true; stylableTextBox1.Location = new Point(6, 22); stylableTextBox1.Name = "stylableTextBox1"; stylableTextBox1.Size = new Size(207, 16); stylableTextBox1.TabIndex = 8; stylableTextBox1.Text = "Hello, my name is ..."; - stylableTextBox1.TextForeColor = Color.Black; + stylableTextBox1.ForeColor = Color.Black; // // lbl_description // @@ -419,4 +419,4 @@ private void InitializeComponent() private DataGridViewCheckBoxColumn Column3; private DataGridViewTextBoxColumn Column4; } -} \ No newline at end of file +} diff --git a/WinFormsThemes/WinFormsThemes.Example/FrmDefault.cs b/WinFormsThemes/WinFormsThemes.Example/FrmDefault.cs index 7fcb5a3..b402c6b 100644 --- a/WinFormsThemes/WinFormsThemes.Example/FrmDefault.cs +++ b/WinFormsThemes/WinFormsThemes.Example/FrmDefault.cs @@ -7,8 +7,7 @@ public partial class FrmDefault : Form public FrmDefault() { InitializeComponent(); - //ThemeRegistryHolder.ThemeRegistry.Current.Apply(this); - ThemeRegistryHolder.ThemeRegistry.Get(ThemeCapabilities.HighContrast).Apply(this); + ThemeRegistryHolder.ThemeRegistry!.GetTheme(ThemeCapabilities.HighContrast)?.Apply(this); } private void stylableListView1_SelectedIndexChanged(object sender, EventArgs e) @@ -16,4 +15,4 @@ private void stylableListView1_SelectedIndexChanged(object sender, EventArgs e) } } -} \ No newline at end of file +} diff --git a/WinFormsThemes/WinFormsThemes.Example/Program.cs b/WinFormsThemes/WinFormsThemes.Example/Program.cs index 1d0bd77..0a85b3e 100644 --- a/WinFormsThemes/WinFormsThemes.Example/Program.cs +++ b/WinFormsThemes/WinFormsThemes.Example/Program.cs @@ -13,8 +13,8 @@ internal static void Main() // To customize application configuration such as set high DPI settings or default font, // see https://aka.ms/applicationconfiguration. ApplicationConfiguration.Initialize(); - - ThemeRegistryHolder.ThemeRegistry = ThemeRegistryHolder.GetBuilder().WithCurrentThemeSelector((selector) => ThemeRegistryHolder.ThemeRegistry.Get()).Build(); + StylableWinFormsControls.StylableWinFormsControlsSettings.DEFAULT.ErrorHandling = StylableWinFormsControls.ErrorHandling.Continue; + ThemeRegistryHolder.ThemeRegistry = ThemeRegistryHolder.GetBuilder().WithCurrentThemeSelector((selector) => ThemeRegistryHolder.ThemeRegistry!.GetTheme()).Build(); Application.Run(new FrmDefault()); } diff --git a/WinFormsThemes/WinFormsThemes.sln b/WinFormsThemes/WinFormsThemes.sln index 9e20fed..bf428f5 100644 --- a/WinFormsThemes/WinFormsThemes.sln +++ b/WinFormsThemes/WinFormsThemes.sln @@ -12,6 +12,8 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Projektmappenelemente", "Pr ..\stryker-config.json = ..\stryker-config.json EndProjectSection EndProject +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "WinFormsThemes.Example", "WinFormsThemes.Example\WinFormsThemes.Example.csproj", "{BA51ADEB-B00C-4D39-9A0D-364362227427}" +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -26,10 +28,10 @@ Global {27D57027-C5FC-478D-A873-DD11CACEE584}.Debug|Any CPU.Build.0 = Debug|Any CPU {27D57027-C5FC-478D-A873-DD11CACEE584}.Release|Any CPU.ActiveCfg = Release|Any CPU {27D57027-C5FC-478D-A873-DD11CACEE584}.Release|Any CPU.Build.0 = Release|Any CPU - {7EDF3D57-1142-466C-AE79-823DB3B691F0}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {7EDF3D57-1142-466C-AE79-823DB3B691F0}.Debug|Any CPU.Build.0 = Debug|Any CPU - {7EDF3D57-1142-466C-AE79-823DB3B691F0}.Release|Any CPU.ActiveCfg = Release|Any CPU - {7EDF3D57-1142-466C-AE79-823DB3B691F0}.Release|Any CPU.Build.0 = Release|Any CPU + {BA51ADEB-B00C-4D39-9A0D-364362227427}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {BA51ADEB-B00C-4D39-9A0D-364362227427}.Debug|Any CPU.Build.0 = Debug|Any CPU + {BA51ADEB-B00C-4D39-9A0D-364362227427}.Release|Any CPU.ActiveCfg = Release|Any CPU + {BA51ADEB-B00C-4D39-9A0D-364362227427}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE