Skip to main content

MaterialSkin for .NET WinForms C# & VB.NET

DOWNLOAD 

images:

alt tag
A simple demo interface with MaterialSkin components.
alt tag
The MaterialSkin checkboxes.
alt tag
The MaterialSkin radiobuttons.
alt tag
The MaterialSkin ListView.
alt tag
1. Add the library to your project
You can do this on multiple ways. The easiest way would be adding the NuGet Package. Right click on your project and click 'Manage NuGet Packages...'. Search for 'MaterialSkin' and click on install. Once installed the library will be included in your project references. (Or install it through the package manager console: PM> Install-Package MaterialSkin)
Another way of doing this step would be cloning the project from GitHub, compiling the library yourself and adding it as a reference.
2. Add the MaterialSkin components to your ToolBox
If you have installed the NuGet package, the MaterialSkin.dll file should be in the folder //bin/Debug. Simply drag the MaterialSkin.dll file into your IDE's ToolBox and all the controls should be added there.
3. Inherit from MaterialForm
Open the code behind your Form you wish to skin. Make it inherit from MaterialForm rather than Form. Don't forget to put the library in your imports, so it can find the MaterialForm class!
C# (Form1.cs)
public partial class Form1 : MaterialForm
VB.NET (Form1.Designer.vb)
Partial Class Form1
  Inherits MaterialSkin.Controls.MaterialForm
4. Initialize your colorscheme
Set your preferred colors & theme. Also add the form to the manager so it keeps updated if the color scheme or theme changes later on.
C# (Form1.cs)
public Form1()
{
    InitializeComponent();

    var materialSkinManager = MaterialSkinManager.Instance;
    materialSkinManager.AddFormToManage(this);
    materialSkinManager.Theme = MaterialSkinManager.Themes.LIGHT;
    materialSkinManager.ColorScheme = new ColorScheme(Primary.BlueGrey800, Primary.BlueGrey900, Primary.BlueGrey500, Accent.LightBlue200, TextShade.WHITE);
}
VB.NET (Form1.vb)
Imports MaterialSkin

Public Class Form1

    Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
        Dim SkinManager As MaterialSkinManager = MaterialSkinManager.Instance
        SkinManager.AddFormToManage(Me)
        SkinManager.Theme = MaterialSkinManager.Themes.LIGHT
        SkinManager.ColorScheme = New ColorScheme(Primary.BlueGrey800, Primary.BlueGrey900, Primary.BlueGrey500, Accent.LightBlue200, TextShade.WHITE)
    End Sub
End Class


Comments

Popular posts from this blog

Bottom Dialogs Sheet

Bottom Dialogs Sheet      Android Library that shows a customizable Material-based bottom sheet. How to include Add the repository to your project  build.gradle : repositories { maven { url " https://jitpack.io " } } And add the library to your module  build.gradle : dependencies { compile ' com.github.javiersantos:BottomDialogs:1.2.1 ' } Usage Basic Bottom Dialog A basic bottom dialog will be shown. You have access to methods such as  setTitle() ,  setContent() ,  setIcon() ,  setCancelable() ,  dismiss() , etc. Customizations are explained below. new BottomDialog . Builder ( this ) .setTitle( " Awesome! " ) .setContent( " What can we improve? Your feedback is always welcome. " ) .show(); or BottomDialog bottomDialog = new BottomDialog . Builder ( this ) .setTitle( " Awesome! " ) .setContent( " What can we improve? Your feedback is always welcome. " ) .build(); .

New ver Of Android Studio 3.1.2

Android Studio provides the fastest tools for building apps on every type of Android device. ___________ This update to Android Studio 3.1 includes fixes for the following bugs: In some cases, Android Studio hung indefinitely during exit. Builds configured with  source sets  failed with the following message when Instant Run was enabled: "The SourceSet  name  is not recognized by the Android Gradle Plugin." When Instant Run was enabled, builds of new Kotlin projects failed when triggered by the  Run command. During editing of the  build.gradle  file, there was sometimes a noticeable delay between typing a character and the character appearing on the screen. Build failures occurred during dexing in some projects with large numbers of modules or external dependencies, with the following error message: "RejectedExecutionException: Thread limit exceeded replacing blocked worker" The computation of the D8 main DEX list was not taking into a