文件名称:CustomGroupBox
- 所属分类:
- C#编程
- 资源属性:
- [Windows] [Visual.Net] [源码]
- 上传时间:
- 2015-06-15
- 文件大小:
- 17kb
- 下载次数:
- 0次
- 提 供 者:
- Mahdi*****
- 相关连接:
- 无
- 下载说明:
- 别用迅雷下载,失败请重下,重下不扣分!
介绍说明--下载内容均来自于网络,请自行研究使用
A New Skin for Ye Olde GroupBox
Creating a custom GroupBox in WinForms that supports skinning-Introduction
When applying a dark skin theme to my Windows Forms application which used a GroupBox
But as soon as I wanted to set the GroupBox.Enabled property to false, things did not look that good anymore.
As can be seen in the screendump, the standard GroupBox on the right automatically chooses a black color for the disabled state:
Background
SkinSettings Class
The skin themes are in a separate class SkinSettings, to keep the example small, it only has a few settings.
It also has a ColorDisabled() method for calculating the custom disabled Color.
Hide Shrink Copy Code
using System
using System.Drawing
namespace CustomControls1
{
/// <summary>
/// A simple SkinSettings class.
/// This could be extended to support more control colors.
/// </summary>
public static class SkinSettings
{
public static Color FormBackColor { get set }
public static Color FormForeColor { get set }
public s
Creating a custom GroupBox in WinForms that supports skinning-Introduction
When applying a dark skin theme to my Windows Forms application which used a GroupBox
But as soon as I wanted to set the GroupBox.Enabled property to false, things did not look that good anymore.
As can be seen in the screendump, the standard GroupBox on the right automatically chooses a black color for the disabled state:
Background
SkinSettings Class
The skin themes are in a separate class SkinSettings, to keep the example small, it only has a few settings.
It also has a ColorDisabled() method for calculating the custom disabled Color.
Hide Shrink Copy Code
using System
using System.Drawing
namespace CustomControls1
{
/// <summary>
/// A simple SkinSettings class.
/// This could be extended to support more control colors.
/// </summary>
public static class SkinSettings
{
public static Color FormBackColor { get set }
public static Color FormForeColor { get set }
public s
(系统自动生成,下载前可以参看下载内容)
下载文件列表
CustomGroupBox\App.config
..............\CustomControls1.csproj
..............\CustomControls1.sln
..............\CustomControls1.v12.suo
..............\CustomGroupBox.cs
..............\Form1.cs
..............\Form1.Designer.cs
..............\Form1.resx
..............\PanelTransparent.cs
..............\Program.cs
..............\Properties
..............\..........\AssemblyInfo.cs
..............\..........\Resources.Designer.cs
..............\..........\Resources.resx
..............\..........\Settings.Designer.cs
..............\..........\Settings.settings
..............\SkinSettings.cs