* UIWaitingBar: 修改可自定义配色
This commit is contained in:
parent
7ff8e13363
commit
547ec9de80
@ -18,6 +18,7 @@
|
||||
*
|
||||
* 2020-07-20: V2.2.6 新增等待滚动条控件
|
||||
* 2022-03-19: V3.1.1 重构主题配色
|
||||
* 2024-02-23: V3.6.3 修改可自定义配色
|
||||
******************************************************************************/
|
||||
|
||||
using System;
|
||||
@ -72,7 +73,7 @@ namespace Sunny.UI
|
||||
protected override void OnPaint(PaintEventArgs e)
|
||||
{
|
||||
base.OnPaint(e);
|
||||
e.Graphics.FillRoundRectangle(rectColor, (int)dz + 1, 1, sliderWidth, Height - 3, Radius);
|
||||
e.Graphics.FillRoundRectangle(foreColor, (int)dz + 1, 1, sliderWidth, Height - 3, Radius);
|
||||
}
|
||||
|
||||
//d是度数,不是弧度
|
||||
@ -153,5 +154,38 @@ namespace Sunny.UI
|
||||
fillColor = uiColor.ProcessBarFillColor;
|
||||
foreColor = uiColor.ProcessBarForeColor;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 边框颜色
|
||||
/// </summary>
|
||||
[Description("边框颜色"), Category("SunnyUI")]
|
||||
[DefaultValue(typeof(Color), "80, 160, 255")]
|
||||
public Color RectColor
|
||||
{
|
||||
get => rectColor;
|
||||
set => SetRectColor(value);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 填充颜色,当值为背景色或透明色或空值则不填充
|
||||
/// </summary>
|
||||
[Description("填充颜色"), Category("SunnyUI")]
|
||||
[DefaultValue(typeof(Color), "80, 160, 255")]
|
||||
public Color FillColor
|
||||
{
|
||||
get => fillColor;
|
||||
set => SetFillColor(value);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 字体颜色
|
||||
/// </summary>
|
||||
[Description("前景颜色"), Category("SunnyUI")]
|
||||
[DefaultValue(typeof(Color), "White")]
|
||||
public override Color ForeColor
|
||||
{
|
||||
get => foreColor;
|
||||
set => SetForeColor(value);
|
||||
}
|
||||
}
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user