资源简介
winform materialskin好看的皮肤组件
皮肤颜色可以随意更改,不会出现卡顿
代码片段和文件信息
using System.Drawing;
namespace MaterialSkin
{
public class ColorScheme
{
public readonly Color PrimaryColor DarkPrimaryColor LightPrimaryColor AccentColor TextColor;
public readonly Pen PrimaryPen DarkPrimaryPen LightPrimaryPen AccentPen TextPen;
public readonly Brush PrimaryBrush DarkPrimaryBrush LightPrimaryBrush AccentBrush TextBrush;
///
/// Defines the Color Scheme to be used for all forms.
///
/// The primary color a -500 color is suggested here.
/// A darker version of the primary color a -700 color is suggested here.
/// A lighter version of the primary color a -100 color is suggested here.
/// The accent color a -200 color is suggested here.
/// The text color the one with the highest contrast is suggested.
public ColorScheme(Primary primary Primary darkPrimary Primary lightPrimary Accent accent TextShade textShade)
{
//Color
PrimaryColor = ((int)primary).ToColor();
DarkPrimaryColor = ((int)darkPrimary).ToColor();
LightPrimaryColor = ((int)lightPrimary).ToColor();
AccentColor = ((int)accent).ToColor();
TextColor = ((int)textShade).ToColor();
//Pen
PrimaryPen = new Pen(PrimaryColor);
DarkPrimaryPen = new Pen(DarkPrimaryColor);
LightPrimaryPen = new Pen(LightPrimaryColor);
AccentPen = new Pen(AccentColor);
TextPen = new Pen(TextColor);
//Brush
PrimaryBrush = new SolidBrush(PrimaryColor);
DarkPrimaryBrush = new SolidBrush(DarkPrimaryColor);
LightPrimaryBrush = new SolidBrush(LightPrimaryColor);
AccentBrush = new SolidBrush(AccentColor);
TextBrush = new SolidBrush(TextColor);
}
}
public static class ColorExtension
{
///
/// Convert an integer number to a Color.
///
///
public static Color ToColor(this int argb)
{
return Color.FromArgb(
(argb & 0xff0000) >> 16
(argb & 0xff00) >> 8
argb & 0xff);
}
///
/// Removes the alpha component of a color.
///
///
///
public static Color RemoveAlpha(this Color color)
{
return Color.FromArgb(color.R color.G color.B);
}
///
/// Converts a 0-100 integer to a 0-255 color component.
///
///
///
public static int PercentageToColorComponent(t
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
....... 2518 2019-12-06 18:21 MaterialSkin-master\.gitattributes
....... 773 2019-12-06 18:21 MaterialSkin-master\.github\FUNDING.yml
....... 2806 2019-12-06 18:21 MaterialSkin-master\.gitignore
..A..H. 72704 2022-02-11 16:36 MaterialSkin-master\.vs\MaterialSkin\v15\.suo
....... 1078 2019-12-06 18:21 MaterialSkin-master\LICENSE
....... 432 2019-12-06 18:21 MaterialSkin-master\MaterialSkin\Animations\AnimationDirection.cs
....... 13889 2019-12-06 18:21 MaterialSkin-master\MaterialSkin\Animations\AnimationManager.cs
....... 1194 2019-12-06 18:21 MaterialSkin-master\MaterialSkin\Animations\Animations.cs
文件 589824 2022-02-11 16:36 MaterialSkin-master\MaterialSkin\bin\Debug\MaterialSkin.dll
文件 208384 2022-02-11 16:36 MaterialSkin-master\MaterialSkin\bin\Debug\MaterialSkin.pdb
....... 10880 2019-12-06 18:21 MaterialSkin-master\MaterialSkin\ColorScheme.cs
....... 9575 2019-12-06 18:21 MaterialSkin-master\MaterialSkin\Controls\MaterialCheckbox.cs
....... 7675 2019-12-06 18:21 MaterialSkin-master\MaterialSkin\Controls\MaterialContextMenuStrip.cs
....... 634 2019-12-06 18:21 MaterialSkin-master\MaterialSkin\Controls\MaterialDivider.cs
....... 6551 2019-12-06 18:21 MaterialSkin-master\MaterialSkin\Controls\MaterialFlatButton.cs
....... 23408 2019-12-06 18:21 MaterialSkin-master\MaterialSkin\Controls\MaterialForm.cs
....... 731 2019-12-06 18:21 MaterialSkin-master\MaterialSkin\Controls\MaterialLabel.cs
....... 6759 2019-12-06 18:21 MaterialSkin-master\MaterialSkin\Controls\MaterialListView.cs
....... 4980 2019-12-06 18:21 MaterialSkin-master\MaterialSkin\Controls\MaterialMenuStrip.cs
....... 2925 2019-12-06 18:21 MaterialSkin-master\MaterialSkin\Controls\MaterialProgressBar.cs
....... 8510 2019-12-06 18:21 MaterialSkin-master\MaterialSkin\Controls\MaterialRadioButton.cs
....... 5090 2019-12-06 18:21 MaterialSkin-master\MaterialSkin\Controls\MaterialRaisedButton.cs
....... 31060 2019-12-06 18:21 MaterialSkin-master\MaterialSkin\Controls\MaterialSingleLineTextField.cs
....... 625 2019-12-06 18:21 MaterialSkin-master\MaterialSkin\Controls\MaterialTabControl.cs
....... 7275 2019-12-06 18:21 MaterialSkin-master\MaterialSkin\Controls\MaterialTabSelector.cs
....... 1846 2019-12-06 18:21 MaterialSkin-master\MaterialSkin\DrawHelper.cs
....... 287 2019-12-06 18:21 MaterialSkin-master\MaterialSkin\IMaterialControl.cs
....... 4526 2019-12-06 18:21 MaterialSkin-master\MaterialSkin\MaterialSkin.csproj
....... 14724 2019-12-06 18:21 MaterialSkin-master\MaterialSkin\MaterialSkinManager.cs
文件 1443 2021-04-02 16:28 MaterialSkin-master\MaterialSkin\obj\Debug\DesignTimeResolveAssemblyReferences.cache
............此处省略84个文件信息
- 上一篇:winform 皮肤
- 下一篇:桌面应用界面(C#)
相关资源
- winform 皮肤
- C#全套皮肤一共73款(IrisSkin4)
- UI界面皮肤(winform)
- winform开发的人脸识别打卡系统
- winform下拉多选自定义控件(带全选)
- winform控件库
- C# winform简洁漂亮的图形界面库SunnyU
- C# 斑马标签打印 (WEBamp;WINFORM)
- winform shell编程
- winform实时获取网卡网速全部源码,获
- winform实现饼状图、柱状图、折线图(
- winform简单用户登录(带验证码)
- 输入框自动切换中文(C#winform)vs20
- winform右下角弹窗
- windorm 加载WPF控件 ,实现dxf文件显示
- C# 俄罗斯方块(winform)
- C# 贪吃蛇(winform)
- C# 五子棋(winform源码)
- Winform中嵌入excel
- C# 华容道 winform源码
- c# winform ftp 文件
- c# winform 打开网页(基于WebBrowser)
- Winform图表(MSChart)
- 酒店电子管理系统winform源代码(附数
- winform 界面图片轮播效果
- winform 功能完整地记事本
- SignalR 2.0 Winform版
- C# winform Socket大文件传输
- C#将Excel导入到Access数据库表(winFor
- winform图片标尺,画矩形
评论
共有 条评论