* 增加XML文档文件
This commit is contained in:
parent
98d8681698
commit
a471882183
@ -189,6 +189,10 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
|
@ -116,6 +116,10 @@ namespace Sunny.UI
|
|||||||
Invalidate();
|
Invalidate();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
|
@ -247,6 +247,10 @@ namespace Sunny.UI
|
|||||||
SetIndex(index);
|
SetIndex(index);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
Size = new Size(253, 148);
|
Size = new Size(253, 148);
|
||||||
|
@ -117,6 +117,10 @@ namespace Sunny.UI
|
|||||||
Invalidate();
|
Invalidate();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
if (Width != Height)
|
if (Width != Height)
|
||||||
|
@ -107,6 +107,10 @@ namespace Sunny.UI
|
|||||||
Version = UIGlobal.Version;
|
Version = UIGlobal.Version;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
e.Graphics.FillRectangle(BackColor, ClientRectangle);
|
e.Graphics.FillRectangle(BackColor, ClientRectangle);
|
||||||
|
@ -224,6 +224,11 @@ namespace Sunny.UI
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 值改变事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="sender">控件</param>
|
||||||
|
/// <param name="value">值</param>
|
||||||
protected virtual void ItemForm_ValueChanged(object sender, object value)
|
protected virtual void ItemForm_ValueChanged(object sender, object value)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
@ -418,6 +423,10 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
protected bool fullControlSelect;
|
protected bool fullControlSelect;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 点击事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">参数</param>
|
||||||
protected override void OnClick(EventArgs e)
|
protected override void OnClick(EventArgs e)
|
||||||
{
|
{
|
||||||
if (!ReadOnly)
|
if (!ReadOnly)
|
||||||
|
@ -328,6 +328,10 @@ namespace Sunny.UI
|
|||||||
Invalidate();
|
Invalidate();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
if (Width <= 0 || Height <= 0) return;
|
if (Width <= 0 || Height <= 0) return;
|
||||||
|
@ -314,9 +314,9 @@ namespace Sunny.UI
|
|||||||
public event PaintEventHandler PaintAgain;
|
public event PaintEventHandler PaintAgain;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// OnPaint
|
/// 重载绘图
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="e">e</param>
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
|
@ -58,6 +58,9 @@ namespace Sunny.UI
|
|||||||
Height = 24;
|
Height = 24;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 电量
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(100), Description("电量"), Category("SunnyUI")]
|
[DefaultValue(100), Description("电量"), Category("SunnyUI")]
|
||||||
public int Power
|
public int Power
|
||||||
{
|
{
|
||||||
@ -85,6 +88,9 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 多种颜色显示电量
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(true), Description("多种颜色"), Category("SunnyUI")]
|
[DefaultValue(true), Description("多种颜色"), Category("SunnyUI")]
|
||||||
public bool MultiColor
|
public bool MultiColor
|
||||||
{
|
{
|
||||||
@ -96,6 +102,9 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 电量为空颜色
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(typeof(Color), "230, 80, 80"), Description("电量为空颜色"), Category("SunnyUI")]
|
[DefaultValue(typeof(Color), "230, 80, 80"), Description("电量为空颜色"), Category("SunnyUI")]
|
||||||
public Color ColorEmpty
|
public Color ColorEmpty
|
||||||
{
|
{
|
||||||
@ -107,6 +116,9 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 电量少时颜色
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(typeof(Color), "220, 155, 40"), Description("电量少时颜色"), Category("SunnyUI")]
|
[DefaultValue(typeof(Color), "220, 155, 40"), Description("电量少时颜色"), Category("SunnyUI")]
|
||||||
public Color ColorDanger
|
public Color ColorDanger
|
||||||
{
|
{
|
||||||
@ -118,6 +130,9 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 电量安全颜色
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(typeof(Color), "110, 190, 40"), Description("电量安全颜色"), Category("SunnyUI")]
|
[DefaultValue(typeof(Color), "110, 190, 40"), Description("电量安全颜色"), Category("SunnyUI")]
|
||||||
public Color ColorSafe
|
public Color ColorSafe
|
||||||
{
|
{
|
||||||
|
@ -33,11 +33,17 @@ using System.Windows.Forms;
|
|||||||
|
|
||||||
namespace Sunny.UI
|
namespace Sunny.UI
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 面包屑导航条
|
||||||
|
/// </summary>
|
||||||
[ToolboxItem(true)]
|
[ToolboxItem(true)]
|
||||||
[DefaultEvent("ItemIndexChanged")]
|
[DefaultEvent("ItemIndexChanged")]
|
||||||
[DefaultProperty("ItemIndex")]
|
[DefaultProperty("ItemIndex")]
|
||||||
public class UIBreadcrumb : UIControl
|
public class UIBreadcrumb : UIControl
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 构造函数
|
||||||
|
/// </summary>
|
||||||
public UIBreadcrumb()
|
public UIBreadcrumb()
|
||||||
{
|
{
|
||||||
items.CountChange += Items_CountChange;
|
items.CountChange += Items_CountChange;
|
||||||
@ -59,6 +65,9 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private bool alignBothEnds;
|
private bool alignBothEnds;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 显示时两端对齐
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(false)]
|
[DefaultValue(false)]
|
||||||
[Description("显示时两端对齐"), Category("SunnyUI")]
|
[Description("显示时两端对齐"), Category("SunnyUI")]
|
||||||
public bool AlignBothEnds
|
public bool AlignBothEnds
|
||||||
@ -74,10 +83,21 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 步骤值变化事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="sender"></param>
|
||||||
|
/// <param name="value"></param>
|
||||||
public delegate void OnValueChanged(object sender, int value);
|
public delegate void OnValueChanged(object sender, int value);
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 步骤值变化事件
|
||||||
|
/// </summary>
|
||||||
public event OnValueChanged ItemIndexChanged;
|
public event OnValueChanged ItemIndexChanged;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 步骤条目列表
|
||||||
|
/// </summary>
|
||||||
[DesignerSerializationVisibility(DesignerSerializationVisibility.Content)]
|
[DesignerSerializationVisibility(DesignerSerializationVisibility.Content)]
|
||||||
[Localizable(true)]
|
[Localizable(true)]
|
||||||
[Editor("System.Windows.Forms.Design.ListControlStringCollectionEditor, " + AssemblyRefEx.SystemDesign, typeof(UITypeEditor))]
|
[Editor("System.Windows.Forms.Design.ListControlStringCollectionEditor, " + AssemblyRefEx.SystemDesign, typeof(UITypeEditor))]
|
||||||
@ -89,11 +109,17 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private readonly ConcurrentDictionary<int, Point[]> ClickArea = new ConcurrentDictionary<int, Point[]>();
|
private readonly ConcurrentDictionary<int, Point[]> ClickArea = new ConcurrentDictionary<int, Point[]>();
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 步骤个数
|
||||||
|
/// </summary>
|
||||||
[Browsable(false)]
|
[Browsable(false)]
|
||||||
public int Count => Items.Count;
|
public int Count => Items.Count;
|
||||||
|
|
||||||
private int itemIndex = -1;
|
private int itemIndex = -1;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 当前节点索引
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(-1)]
|
[DefaultValue(-1)]
|
||||||
[Description("当前节点索引"), Category("SunnyUI")]
|
[Description("当前节点索引"), Category("SunnyUI")]
|
||||||
public int ItemIndex
|
public int ItemIndex
|
||||||
@ -221,6 +247,9 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private int itemWidth;
|
private int itemWidth;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 节点宽度
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(160)]
|
[DefaultValue(160)]
|
||||||
[Description("节点宽度"), Category("SunnyUI")]
|
[Description("节点宽度"), Category("SunnyUI")]
|
||||||
public int ItemWidth
|
public int ItemWidth
|
||||||
@ -235,6 +264,9 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private int interval = 1;
|
private int interval = 1;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 节点间隔
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(1)]
|
[DefaultValue(1)]
|
||||||
[Description("节点间隔"), Category("SunnyUI")]
|
[Description("节点间隔"), Category("SunnyUI")]
|
||||||
public int Interval
|
public int Interval
|
||||||
@ -248,7 +280,7 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 已选节点颜色
|
/// 已选节点颜色
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[Description("已选节点颜色")]
|
[Description("已选节点颜色")]
|
||||||
[Category("SunnyUI")]
|
[Category("SunnyUI")]
|
||||||
@ -260,7 +292,7 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 未选节点颜色
|
/// 未选节点颜色
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[Description("未选节点颜色")]
|
[Description("未选节点颜色")]
|
||||||
[Category("SunnyUI")]
|
[Category("SunnyUI")]
|
||||||
@ -274,7 +306,7 @@ namespace Sunny.UI
|
|||||||
private Color unSelectedForeColor = Color.White;
|
private Color unSelectedForeColor = Color.White;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 未选节点颜色
|
/// 未选节点文字颜色
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[Description("未选节点文字颜色")]
|
[Description("未选节点文字颜色")]
|
||||||
[Category("SunnyUI")]
|
[Category("SunnyUI")]
|
||||||
@ -293,7 +325,7 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 字体颜色
|
/// 字体颜色
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[Description("字体颜色")]
|
[Description("字体颜色")]
|
||||||
[Category("SunnyUI")]
|
[Category("SunnyUI")]
|
||||||
@ -316,6 +348,10 @@ namespace Sunny.UI
|
|||||||
rectColor = uiColor.BreadcrumbUnSelectedColor;
|
rectColor = uiColor.BreadcrumbUnSelectedColor;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 鼠标点击事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">参数</param>
|
||||||
protected override void OnMouseClick(MouseEventArgs e)
|
protected override void OnMouseClick(MouseEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnMouseClick(e);
|
base.OnMouseClick(e);
|
||||||
|
@ -38,11 +38,17 @@ using System.Windows.Forms;
|
|||||||
|
|
||||||
namespace Sunny.UI
|
namespace Sunny.UI
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 按钮
|
||||||
|
/// </summary>
|
||||||
[DefaultEvent("Click")]
|
[DefaultEvent("Click")]
|
||||||
[DefaultProperty("Text")]
|
[DefaultProperty("Text")]
|
||||||
[ToolboxItem(true)]
|
[ToolboxItem(true)]
|
||||||
public class UIButton : UIControl, IButtonControl
|
public class UIButton : UIControl, IButtonControl
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 构造函数
|
||||||
|
/// </summary>
|
||||||
public UIButton()
|
public UIButton()
|
||||||
{
|
{
|
||||||
SetStyleFlags();
|
SetStyleFlags();
|
||||||
@ -65,6 +71,9 @@ namespace Sunny.UI
|
|||||||
SetStyle(ControlStyles.StandardDoubleClick, UseDoubleClick);
|
SetStyle(ControlStyles.StandardDoubleClick, UseDoubleClick);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 是否显示浅色背景
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(false)]
|
[DefaultValue(false)]
|
||||||
[Description("是否显示浅色背景"), Category("SunnyUI")]
|
[Description("是否显示浅色背景"), Category("SunnyUI")]
|
||||||
public bool LightStyle
|
public bool LightStyle
|
||||||
@ -82,6 +91,9 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private bool autoSize;
|
private bool autoSize;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 自动大小
|
||||||
|
/// </summary>
|
||||||
[Browsable(true), DefaultValue(false)]
|
[Browsable(true), DefaultValue(false)]
|
||||||
[Description("自动大小"), Category("SunnyUI")]
|
[Description("自动大小"), Category("SunnyUI")]
|
||||||
public override bool AutoSize
|
public override bool AutoSize
|
||||||
@ -96,6 +108,9 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private bool isClick;
|
private bool isClick;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 调用点击事件
|
||||||
|
/// </summary>
|
||||||
public void PerformClick()
|
public void PerformClick()
|
||||||
{
|
{
|
||||||
if (isClick) return;
|
if (isClick) return;
|
||||||
@ -107,6 +122,10 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载点击事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">参数</param>
|
||||||
protected override void OnClick(EventArgs e)
|
protected override void OnClick(EventArgs e)
|
||||||
{
|
{
|
||||||
Form form = FindFormInternal();
|
Form form = FindFormInternal();
|
||||||
@ -129,6 +148,9 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private bool showTips = false;
|
private bool showTips = false;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 是否显示角标
|
||||||
|
/// </summary>
|
||||||
[Description("是否显示角标"), Category("SunnyUI")]
|
[Description("是否显示角标"), Category("SunnyUI")]
|
||||||
[DefaultValue(false)]
|
[DefaultValue(false)]
|
||||||
public bool ShowTips
|
public bool ShowTips
|
||||||
@ -149,6 +171,9 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private string tipsText = "";
|
private string tipsText = "";
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 角标文字
|
||||||
|
/// </summary>
|
||||||
[Description("角标文字"), Category("SunnyUI")]
|
[Description("角标文字"), Category("SunnyUI")]
|
||||||
[DefaultValue("")]
|
[DefaultValue("")]
|
||||||
public string TipsText
|
public string TipsText
|
||||||
@ -169,6 +194,9 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private Font tipsFont = UIFontColor.SubFont();
|
private Font tipsFont = UIFontColor.SubFont();
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 角标文字字体
|
||||||
|
/// </summary>
|
||||||
[Description("角标文字字体"), Category("SunnyUI")]
|
[Description("角标文字字体"), Category("SunnyUI")]
|
||||||
[DefaultValue(typeof(Font), "微软雅黑, 9pt")]
|
[DefaultValue(typeof(Font), "微软雅黑, 9pt")]
|
||||||
public Font TipsFont
|
public Font TipsFont
|
||||||
@ -213,6 +241,9 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private Color tipsColor = Color.Red;
|
private Color tipsColor = Color.Red;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 角标背景颜色
|
||||||
|
/// </summary>
|
||||||
[Description("角标背景颜色"), Category("SunnyUI")]
|
[Description("角标背景颜色"), Category("SunnyUI")]
|
||||||
[DefaultValue(typeof(Color), "Red")]
|
[DefaultValue(typeof(Color), "Red")]
|
||||||
public Color TipsColor
|
public Color TipsColor
|
||||||
@ -227,6 +258,9 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private Color tipsForeColor = Color.White;
|
private Color tipsForeColor = Color.White;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 角标文字颜色
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(typeof(Color), "White"), Category("SunnyUI"), Description("角标文字颜色")]
|
[DefaultValue(typeof(Color), "White"), Category("SunnyUI"), Description("角标文字颜色")]
|
||||||
public Color TipsForeColor
|
public Color TipsForeColor
|
||||||
{
|
{
|
||||||
@ -254,12 +288,20 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 析构函数
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="disposing">释放参数</param>
|
||||||
protected override void Dispose(bool disposing)
|
protected override void Dispose(bool disposing)
|
||||||
{
|
{
|
||||||
base.Dispose(disposing);
|
base.Dispose(disposing);
|
||||||
tmpFont?.Dispose();
|
tmpFont?.Dispose();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
@ -357,6 +399,9 @@ namespace Sunny.UI
|
|||||||
set => SetFillColor2(value);
|
set => SetFillColor2(value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 填充颜色渐变
|
||||||
|
/// </summary>
|
||||||
[Description("填充颜色渐变"), Category("SunnyUI")]
|
[Description("填充颜色渐变"), Category("SunnyUI")]
|
||||||
[DefaultValue(false)]
|
[DefaultValue(false)]
|
||||||
public bool FillColorGradient
|
public bool FillColorGradient
|
||||||
@ -394,6 +439,9 @@ namespace Sunny.UI
|
|||||||
set => SetForeColor(value);
|
set => SetForeColor(value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 不可用时填充颜色
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(typeof(Color), "244, 244, 244"), Category("SunnyUI")]
|
[DefaultValue(typeof(Color), "244, 244, 244"), Category("SunnyUI")]
|
||||||
[Description("不可用时填充颜色")]
|
[Description("不可用时填充颜色")]
|
||||||
public Color FillDisableColor
|
public Color FillDisableColor
|
||||||
@ -402,6 +450,9 @@ namespace Sunny.UI
|
|||||||
set => SetFillDisableColor(value);
|
set => SetFillDisableColor(value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 不可用时边框颜色
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(typeof(Color), "173, 178, 181"), Category("SunnyUI")]
|
[DefaultValue(typeof(Color), "173, 178, 181"), Category("SunnyUI")]
|
||||||
[Description("不可用时边框颜色")]
|
[Description("不可用时边框颜色")]
|
||||||
public Color RectDisableColor
|
public Color RectDisableColor
|
||||||
@ -410,6 +461,9 @@ namespace Sunny.UI
|
|||||||
set => SetRectDisableColor(value);
|
set => SetRectDisableColor(value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 不可用时字体颜色
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(typeof(Color), "109, 109, 103"), Category("SunnyUI")]
|
[DefaultValue(typeof(Color), "109, 109, 103"), Category("SunnyUI")]
|
||||||
[Description("不可用时字体颜色")]
|
[Description("不可用时字体颜色")]
|
||||||
public Color ForeDisableColor
|
public Color ForeDisableColor
|
||||||
@ -418,6 +472,9 @@ namespace Sunny.UI
|
|||||||
set => SetForeDisableColor(value);
|
set => SetForeDisableColor(value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 鼠标移上时填充颜色
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(typeof(Color), "115, 179, 255"), Category("SunnyUI")]
|
[DefaultValue(typeof(Color), "115, 179, 255"), Category("SunnyUI")]
|
||||||
[Description("鼠标移上时填充颜色")]
|
[Description("鼠标移上时填充颜色")]
|
||||||
public Color FillHoverColor
|
public Color FillHoverColor
|
||||||
@ -426,6 +483,9 @@ namespace Sunny.UI
|
|||||||
set => SetFillHoverColor(value);
|
set => SetFillHoverColor(value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 鼠标按下时填充颜色
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(typeof(Color), "64, 128, 204"), Category("SunnyUI")]
|
[DefaultValue(typeof(Color), "64, 128, 204"), Category("SunnyUI")]
|
||||||
[Description("鼠标按下时填充颜色")]
|
[Description("鼠标按下时填充颜色")]
|
||||||
public Color FillPressColor
|
public Color FillPressColor
|
||||||
@ -434,6 +494,9 @@ namespace Sunny.UI
|
|||||||
set => SetFillPressColor(value);
|
set => SetFillPressColor(value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 鼠标移上时字体颜色
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(typeof(Color), "White"), Category("SunnyUI")]
|
[DefaultValue(typeof(Color), "White"), Category("SunnyUI")]
|
||||||
[Description("鼠标移上时字体颜色")]
|
[Description("鼠标移上时字体颜色")]
|
||||||
public Color ForeHoverColor
|
public Color ForeHoverColor
|
||||||
@ -442,6 +505,9 @@ namespace Sunny.UI
|
|||||||
set => SetForeHoverColor(value);
|
set => SetForeHoverColor(value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 鼠标按下时字体颜色
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(typeof(Color), "White"), Category("SunnyUI")]
|
[DefaultValue(typeof(Color), "White"), Category("SunnyUI")]
|
||||||
[Description("鼠标按下时字体颜色")]
|
[Description("鼠标按下时字体颜色")]
|
||||||
public Color ForePressColor
|
public Color ForePressColor
|
||||||
@ -450,6 +516,9 @@ namespace Sunny.UI
|
|||||||
set => SetForePressColor(value);
|
set => SetForePressColor(value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 鼠标移上时边框颜色
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(typeof(Color), "115, 179, 255"), Category("SunnyUI")]
|
[DefaultValue(typeof(Color), "115, 179, 255"), Category("SunnyUI")]
|
||||||
[Description("鼠标移上时边框颜色")]
|
[Description("鼠标移上时边框颜色")]
|
||||||
public Color RectHoverColor
|
public Color RectHoverColor
|
||||||
@ -458,6 +527,9 @@ namespace Sunny.UI
|
|||||||
set => SetRectHoverColor(value);
|
set => SetRectHoverColor(value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 鼠标按下时边框颜色
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(typeof(Color), "64, 128, 204"), Category("SunnyUI")]
|
[DefaultValue(typeof(Color), "64, 128, 204"), Category("SunnyUI")]
|
||||||
[Description("鼠标按下时边框颜色")]
|
[Description("鼠标按下时边框颜色")]
|
||||||
public Color RectPressColor
|
public Color RectPressColor
|
||||||
@ -466,6 +538,9 @@ namespace Sunny.UI
|
|||||||
set => SetRectPressColor(value);
|
set => SetRectPressColor(value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 选中时填充颜色
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(typeof(Color), "64, 128, 204"), Category("SunnyUI")]
|
[DefaultValue(typeof(Color), "64, 128, 204"), Category("SunnyUI")]
|
||||||
[Description("选中时填充颜色")]
|
[Description("选中时填充颜色")]
|
||||||
public Color FillSelectedColor
|
public Color FillSelectedColor
|
||||||
@ -474,6 +549,9 @@ namespace Sunny.UI
|
|||||||
set => SetFillSelectedColor(value);
|
set => SetFillSelectedColor(value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 选中时字体颜色
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(typeof(Color), "White"), Category("SunnyUI")]
|
[DefaultValue(typeof(Color), "White"), Category("SunnyUI")]
|
||||||
[Description("选中时字体颜色")]
|
[Description("选中时字体颜色")]
|
||||||
public Color ForeSelectedColor
|
public Color ForeSelectedColor
|
||||||
@ -482,6 +560,9 @@ namespace Sunny.UI
|
|||||||
set => SetForeSelectedColor(value);
|
set => SetForeSelectedColor(value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 选中时边框颜色
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(typeof(Color), "64, 128, 204"), Category("SunnyUI")]
|
[DefaultValue(typeof(Color), "64, 128, 204"), Category("SunnyUI")]
|
||||||
[Description("选中时边框颜色")]
|
[Description("选中时边框颜色")]
|
||||||
public Color RectSelectedColor
|
public Color RectSelectedColor
|
||||||
@ -490,6 +571,10 @@ namespace Sunny.UI
|
|||||||
set => SetRectSelectedColor(value);
|
set => SetRectSelectedColor(value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载鼠标按下事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">鼠标参数</param>
|
||||||
protected override void OnMouseDown(MouseEventArgs e)
|
protected override void OnMouseDown(MouseEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnMouseDown(e);
|
base.OnMouseDown(e);
|
||||||
@ -497,6 +582,10 @@ namespace Sunny.UI
|
|||||||
Invalidate();
|
Invalidate();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载鼠标抬起事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">鼠标参数</param>
|
||||||
protected override void OnMouseUp(MouseEventArgs e)
|
protected override void OnMouseUp(MouseEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnMouseUp(e);
|
base.OnMouseUp(e);
|
||||||
@ -504,6 +593,10 @@ namespace Sunny.UI
|
|||||||
Invalidate();
|
Invalidate();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载鼠标离开事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">鼠标参数</param>
|
||||||
protected override void OnMouseLeave(EventArgs e)
|
protected override void OnMouseLeave(EventArgs e)
|
||||||
{
|
{
|
||||||
base.OnMouseLeave(e);
|
base.OnMouseLeave(e);
|
||||||
@ -512,6 +605,10 @@ namespace Sunny.UI
|
|||||||
Invalidate();
|
Invalidate();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载鼠标进入事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">鼠标参数</param>
|
||||||
protected override void OnMouseEnter(EventArgs e)
|
protected override void OnMouseEnter(EventArgs e)
|
||||||
{
|
{
|
||||||
base.OnMouseEnter(e);
|
base.OnMouseEnter(e);
|
||||||
@ -519,14 +616,25 @@ namespace Sunny.UI
|
|||||||
Invalidate();
|
Invalidate();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 通知控件它是默认按钮
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="value"></param>
|
||||||
public void NotifyDefault(bool value)
|
public void NotifyDefault(bool value)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 指定标识符以指示对话框的返回值
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(DialogResult.None)]
|
[DefaultValue(DialogResult.None)]
|
||||||
[Description("指定标识符以指示对话框的返回值"), Category("SunnyUI")]
|
[Description("指定标识符以指示对话框的返回值"), Category("SunnyUI")]
|
||||||
public DialogResult DialogResult { get; set; } = DialogResult.None;
|
public DialogResult DialogResult { get; set; } = DialogResult.None;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 键盘按下事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">按键参数</param>
|
||||||
protected override void OnKeyDown(KeyEventArgs e)
|
protected override void OnKeyDown(KeyEventArgs e)
|
||||||
{
|
{
|
||||||
if (Focused && e.KeyCode == Keys.Space)
|
if (Focused && e.KeyCode == Keys.Space)
|
||||||
@ -539,6 +647,10 @@ namespace Sunny.UI
|
|||||||
base.OnKeyDown(e);
|
base.OnKeyDown(e);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 键盘抬起事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">按键参数</param>
|
||||||
protected override void OnKeyUp(KeyEventArgs e)
|
protected override void OnKeyUp(KeyEventArgs e)
|
||||||
{
|
{
|
||||||
IsPress = false;
|
IsPress = false;
|
||||||
@ -547,6 +659,9 @@ namespace Sunny.UI
|
|||||||
base.OnKeyUp(e);
|
base.OnKeyUp(e);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 显示激活时边框线
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(false)]
|
[DefaultValue(false)]
|
||||||
[Description("显示激活时边框线"), Category("SunnyUI")]
|
[Description("显示激活时边框线"), Category("SunnyUI")]
|
||||||
public bool ShowFocusLine { get; set; }
|
public bool ShowFocusLine { get; set; }
|
||||||
|
@ -31,11 +31,17 @@ using System.Windows.Forms;
|
|||||||
|
|
||||||
namespace Sunny.UI
|
namespace Sunny.UI
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 复选框
|
||||||
|
/// </summary>
|
||||||
[DefaultEvent("CheckedChanged")]
|
[DefaultEvent("CheckedChanged")]
|
||||||
[DefaultProperty("Checked")]
|
[DefaultProperty("Checked")]
|
||||||
[ToolboxItem(true)]
|
[ToolboxItem(true)]
|
||||||
public class UICheckBox : UIControl
|
public class UICheckBox : UIControl
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 构造函数
|
||||||
|
/// </summary>
|
||||||
public UICheckBox()
|
public UICheckBox()
|
||||||
{
|
{
|
||||||
SetStyleFlags();
|
SetStyleFlags();
|
||||||
@ -48,6 +54,10 @@ namespace Sunny.UI
|
|||||||
fillColor = UIStyles.Blue.CheckBoxColor;
|
fillColor = UIStyles.Blue.CheckBoxColor;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
@ -63,6 +73,9 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private bool autoSize;
|
private bool autoSize;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 自动大小
|
||||||
|
/// </summary>
|
||||||
[Browsable(true)]
|
[Browsable(true)]
|
||||||
[Description("自动大小"), Category("SunnyUI")]
|
[Description("自动大小"), Category("SunnyUI")]
|
||||||
public override bool AutoSize
|
public override bool AutoSize
|
||||||
@ -75,13 +88,24 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 值改变事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="sender">控件</param>
|
||||||
|
/// <param name="value">值</param>
|
||||||
public delegate void OnValueChanged(object sender, bool value);
|
public delegate void OnValueChanged(object sender, bool value);
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 值改变事件
|
||||||
|
/// </summary>
|
||||||
public event OnValueChanged ValueChanged;
|
public event OnValueChanged ValueChanged;
|
||||||
|
|
||||||
private int _imageSize = 16;
|
private int _imageSize = 16;
|
||||||
private int _imageInterval = 3;
|
private int _imageInterval = 3;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 图标大小
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(16)]
|
[DefaultValue(16)]
|
||||||
[Description("图标大小"), Category("SunnyUI")]
|
[Description("图标大小"), Category("SunnyUI")]
|
||||||
public int ImageSize
|
public int ImageSize
|
||||||
@ -95,6 +119,9 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 是否只读
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(false)]
|
[DefaultValue(false)]
|
||||||
[Description("是否只读"), Category("SunnyUI")]
|
[Description("是否只读"), Category("SunnyUI")]
|
||||||
public bool ReadOnly { get; set; }
|
public bool ReadOnly { get; set; }
|
||||||
@ -110,6 +137,9 @@ namespace Sunny.UI
|
|||||||
set => SetForeColor(value);
|
set => SetForeColor(value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 图标与文字之间间隔
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(3)]
|
[DefaultValue(3)]
|
||||||
[Description("图标与文字之间间隔"), Category("SunnyUI")]
|
[Description("图标与文字之间间隔"), Category("SunnyUI")]
|
||||||
public int ImageInterval
|
public int ImageInterval
|
||||||
@ -124,6 +154,9 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private bool _checked;
|
private bool _checked;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 是否选中
|
||||||
|
/// </summary>
|
||||||
[Description("是否选中"), Category("SunnyUI")]
|
[Description("是否选中"), Category("SunnyUI")]
|
||||||
[DefaultValue(false)]
|
[DefaultValue(false)]
|
||||||
public bool Checked
|
public bool Checked
|
||||||
@ -142,6 +175,9 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 值改变事件
|
||||||
|
/// </summary>
|
||||||
public event EventHandler CheckedChanged;
|
public event EventHandler CheckedChanged;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -201,6 +237,10 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 点击事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">参数</param>
|
||||||
protected override void OnClick(EventArgs e)
|
protected override void OnClick(EventArgs e)
|
||||||
{
|
{
|
||||||
if (!ReadOnly)
|
if (!ReadOnly)
|
||||||
|
@ -41,7 +41,7 @@ namespace Sunny.UI
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// 值切换事件
|
/// 值切换事件
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="sender">sender</param>
|
/// <param name="sender">控件</param>
|
||||||
/// <param name="index">索引</param>
|
/// <param name="index">索引</param>
|
||||||
/// <param name="text">文字</param>
|
/// <param name="text">文字</param>
|
||||||
/// <param name="isChecked">是否选中</param>
|
/// <param name="isChecked">是否选中</param>
|
||||||
@ -52,6 +52,9 @@ namespace Sunny.UI
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public event OnValueChanged ValueChanged;
|
public event OnValueChanged ValueChanged;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 构造函数
|
||||||
|
/// </summary>
|
||||||
public UICheckBoxGroup()
|
public UICheckBoxGroup()
|
||||||
{
|
{
|
||||||
items.CountChange += Items_CountChange;
|
items.CountChange += Items_CountChange;
|
||||||
@ -62,6 +65,11 @@ namespace Sunny.UI
|
|||||||
Invalidate();
|
Invalidate();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 获取和设置条目值
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="index"></param>
|
||||||
|
/// <returns></returns>
|
||||||
public bool this[int index]
|
public bool this[int index]
|
||||||
{
|
{
|
||||||
get => GetItemCheckState(index);
|
get => GetItemCheckState(index);
|
||||||
@ -87,6 +95,9 @@ namespace Sunny.UI
|
|||||||
boxes.Clear();
|
boxes.Clear();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 清除所有条目
|
||||||
|
/// </summary>
|
||||||
public void Clear()
|
public void Clear()
|
||||||
{
|
{
|
||||||
Items.Clear();
|
Items.Clear();
|
||||||
@ -94,6 +105,9 @@ namespace Sunny.UI
|
|||||||
Invalidate();
|
Invalidate();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 条目列表
|
||||||
|
/// </summary>
|
||||||
[DesignerSerializationVisibility(DesignerSerializationVisibility.Content)]
|
[DesignerSerializationVisibility(DesignerSerializationVisibility.Content)]
|
||||||
[Localizable(true)]
|
[Localizable(true)]
|
||||||
[Editor("System.Windows.Forms.Design.ListControlStringCollectionEditor, System.Design, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a", typeof(UITypeEditor))]
|
[Editor("System.Windows.Forms.Design.ListControlStringCollectionEditor, System.Design, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a", typeof(UITypeEditor))]
|
||||||
@ -124,6 +138,10 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
@ -157,6 +175,9 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 选中状态列表
|
||||||
|
/// </summary>
|
||||||
[Browsable(false)]
|
[Browsable(false)]
|
||||||
public List<int> SelectedIndexes
|
public List<int> SelectedIndexes
|
||||||
{
|
{
|
||||||
@ -189,6 +210,11 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 设置条目状态
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="index">索引</param>
|
||||||
|
/// <param name="isChecked">是否选中</param>
|
||||||
public void SetItemCheckState(int index, bool isChecked)
|
public void SetItemCheckState(int index, bool isChecked)
|
||||||
{
|
{
|
||||||
if (index >= 0 && index < boxes.Count)
|
if (index >= 0 && index < boxes.Count)
|
||||||
@ -197,6 +223,11 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 获取条目状态
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="index">索引</param>
|
||||||
|
/// <returns>是否选中</returns>
|
||||||
public bool GetItemCheckState(int index)
|
public bool GetItemCheckState(int index)
|
||||||
{
|
{
|
||||||
if (index >= 0 && index < items.Count)
|
if (index >= 0 && index < items.Count)
|
||||||
@ -205,6 +236,9 @@ namespace Sunny.UI
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 所有选中条目列表
|
||||||
|
/// </summary>
|
||||||
[Browsable(false)]
|
[Browsable(false)]
|
||||||
public List<object> SelectedItems
|
public List<object> SelectedItems
|
||||||
{
|
{
|
||||||
@ -226,6 +260,9 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private int columnCount = 1;
|
private int columnCount = 1;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 显示列的个数
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(1)]
|
[DefaultValue(1)]
|
||||||
[Description("显示列的个数"), Category("SunnyUI")]
|
[Description("显示列的个数"), Category("SunnyUI")]
|
||||||
public int ColumnCount
|
public int ColumnCount
|
||||||
@ -240,6 +277,9 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private Size _itemSize = new Size(150, 35);
|
private Size _itemSize = new Size(150, 35);
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 显示项的大小
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(typeof(Size), "150, 35")]
|
[DefaultValue(typeof(Size), "150, 35")]
|
||||||
[Description("显示项的大小"), Category("SunnyUI")]
|
[Description("显示项的大小"), Category("SunnyUI")]
|
||||||
public Size ItemSize
|
public Size ItemSize
|
||||||
@ -254,6 +294,9 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private Point startPos = new Point(12, 12);
|
private Point startPos = new Point(12, 12);
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 显示项的起始位置
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(typeof(Point), "12, 12")]
|
[DefaultValue(typeof(Point), "12, 12")]
|
||||||
[Description("显示项的起始位置"), Category("SunnyUI")]
|
[Description("显示项的起始位置"), Category("SunnyUI")]
|
||||||
public Point StartPos
|
public Point StartPos
|
||||||
@ -266,8 +309,12 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public int columnInterval;
|
|
||||||
|
|
||||||
|
private int columnInterval;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 显示项列之间的间隔
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(0)]
|
[DefaultValue(0)]
|
||||||
[Description("显示项列之间的间隔"), Category("SunnyUI")]
|
[Description("显示项列之间的间隔"), Category("SunnyUI")]
|
||||||
public int ColumnInterval
|
public int ColumnInterval
|
||||||
@ -282,6 +329,9 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private int rowInterval;
|
private int rowInterval;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 显示项行之间的间隔
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(0)]
|
[DefaultValue(0)]
|
||||||
[Description("显示项行之间的间隔"), Category("SunnyUI")]
|
[Description("显示项行之间的间隔"), Category("SunnyUI")]
|
||||||
public int RowInterval
|
public int RowInterval
|
||||||
|
@ -34,6 +34,9 @@ using System.Windows.Forms;
|
|||||||
|
|
||||||
namespace Sunny.UI
|
namespace Sunny.UI
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 颜色选择框
|
||||||
|
/// </summary>
|
||||||
[DefaultProperty("ValueChanged")]
|
[DefaultProperty("ValueChanged")]
|
||||||
[ToolboxItem(true)]
|
[ToolboxItem(true)]
|
||||||
public sealed class UIColorPicker : UIDropControl
|
public sealed class UIColorPicker : UIDropControl
|
||||||
@ -52,10 +55,21 @@ namespace Sunny.UI
|
|||||||
this.PerformLayout();
|
this.PerformLayout();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 颜色改变事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="sender">控件</param>
|
||||||
|
/// <param name="value">颜色</param>
|
||||||
public delegate void OnColorChanged(object sender, Color value);
|
public delegate void OnColorChanged(object sender, Color value);
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 颜色改变事件
|
||||||
|
/// </summary>
|
||||||
public event OnColorChanged ValueChanged;
|
public event OnColorChanged ValueChanged;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 构造函数
|
||||||
|
/// </summary>
|
||||||
public UIColorPicker()
|
public UIColorPicker()
|
||||||
{
|
{
|
||||||
InitializeComponent();
|
InitializeComponent();
|
||||||
@ -71,6 +85,9 @@ namespace Sunny.UI
|
|||||||
ItemForm.Show(this);
|
ItemForm.Show(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 整个控件点击下拉选择颜色
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(false)]
|
[DefaultValue(false)]
|
||||||
[Description("整个控件点击下拉选择颜色"), Category("SunnyUI")]
|
[Description("整个控件点击下拉选择颜色"), Category("SunnyUI")]
|
||||||
public bool FullControlSelect
|
public bool FullControlSelect
|
||||||
@ -79,6 +96,11 @@ namespace Sunny.UI
|
|||||||
set => fullControlSelect = value;
|
set => fullControlSelect = value;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 值改变事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="sender">控件</param>
|
||||||
|
/// <param name="value">值</param>
|
||||||
protected override void ItemForm_ValueChanged(object sender, object value)
|
protected override void ItemForm_ValueChanged(object sender, object value)
|
||||||
{
|
{
|
||||||
if (Value != (Color)value)
|
if (Value != (Color)value)
|
||||||
@ -91,6 +113,9 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private readonly UIColorItem item = new UIColorItem();
|
private readonly UIColorItem item = new UIColorItem();
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 创建对象
|
||||||
|
/// </summary>
|
||||||
protected override void CreateInstance()
|
protected override void CreateInstance()
|
||||||
{
|
{
|
||||||
ItemForm = new UIDropDown(item);
|
ItemForm = new UIDropDown(item);
|
||||||
@ -98,6 +123,9 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private Color selectColor;
|
private Color selectColor;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 选中颜色
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(typeof(Color), "80, 160, 255")]
|
[DefaultValue(typeof(Color), "80, 160, 255")]
|
||||||
[Description("选中颜色"), Category("SunnyUI")]
|
[Description("选中颜色"), Category("SunnyUI")]
|
||||||
public Color Value
|
public Color Value
|
||||||
@ -124,6 +152,10 @@ namespace Sunny.UI
|
|||||||
g.FillPath(Value, pathColor);
|
g.FillPath(Value, pathColor);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
|
@ -40,12 +40,18 @@ using System.Windows.Forms;
|
|||||||
|
|
||||||
namespace Sunny.UI
|
namespace Sunny.UI
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 组合框
|
||||||
|
/// </summary>
|
||||||
[DefaultProperty("Items")]
|
[DefaultProperty("Items")]
|
||||||
[DefaultEvent("SelectedIndexChanged")]
|
[DefaultEvent("SelectedIndexChanged")]
|
||||||
[ToolboxItem(true)]
|
[ToolboxItem(true)]
|
||||||
[LookupBindingProperties("DataSource", "DisplayMember", "ValueMember", "SelectedValue")]
|
[LookupBindingProperties("DataSource", "DisplayMember", "ValueMember", "SelectedValue")]
|
||||||
public sealed partial class UIComboBox : UIDropControl, IToolTip
|
public sealed partial class UIComboBox : UIDropControl, IToolTip
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 构造函数
|
||||||
|
/// </summary>
|
||||||
public UIComboBox()
|
public UIComboBox()
|
||||||
{
|
{
|
||||||
InitializeComponent();
|
InitializeComponent();
|
||||||
@ -176,6 +182,9 @@ namespace Sunny.UI
|
|||||||
private object filterSelectedValue;
|
private object filterSelectedValue;
|
||||||
private bool showFilter;
|
private bool showFilter;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 显示过滤
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(false)]
|
[DefaultValue(false)]
|
||||||
[Description("显示过滤"), Category("SunnyUI")]
|
[Description("显示过滤"), Category("SunnyUI")]
|
||||||
public bool ShowFilter
|
public bool ShowFilter
|
||||||
@ -191,10 +200,16 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 过滤显示最大条目数
|
||||||
|
/// </summary>
|
||||||
[DefaultValue(100)]
|
[DefaultValue(100)]
|
||||||
[Description("过滤显示最大条目数"), Category("SunnyUI")]
|
[Description("过滤显示最大条目数"), Category("SunnyUI")]
|
||||||
public int FilterMaxCount { get; set; } = 100;
|
public int FilterMaxCount { get; set; } = 100;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 下拉状态改变事件
|
||||||
|
/// </summary>
|
||||||
protected override void DropDownStyleChanged()
|
protected override void DropDownStyleChanged()
|
||||||
{
|
{
|
||||||
if (DropDownStyle == UIDropDownStyle.DropDownList)
|
if (DropDownStyle == UIDropDownStyle.DropDownList)
|
||||||
@ -232,6 +247,10 @@ namespace Sunny.UI
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 需要额外设置ToolTip的控件
|
||||||
|
/// </summary>
|
||||||
|
/// <returns>控件</returns>
|
||||||
public Control ExToolTipControl()
|
public Control ExToolTipControl()
|
||||||
{
|
{
|
||||||
return edit;
|
return edit;
|
||||||
@ -443,6 +462,11 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
public event EventHandler SelectedValueChanged;
|
public event EventHandler SelectedValueChanged;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 值改变事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="sender">控件</param>
|
||||||
|
/// <param name="value">值</param>
|
||||||
protected override void ItemForm_ValueChanged(object sender, object value)
|
protected override void ItemForm_ValueChanged(object sender, object value)
|
||||||
{
|
{
|
||||||
Invalidate();
|
Invalidate();
|
||||||
@ -482,6 +506,9 @@ namespace Sunny.UI
|
|||||||
Invalidate();
|
Invalidate();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 创建对象
|
||||||
|
/// </summary>
|
||||||
protected override void CreateInstance()
|
protected override void CreateInstance()
|
||||||
{
|
{
|
||||||
ItemForm = new UIDropDown(dropForm);
|
ItemForm = new UIDropDown(dropForm);
|
||||||
|
@ -91,6 +91,10 @@ namespace Sunny.UI
|
|||||||
CreateInstance();
|
CreateInstance();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 需要额外设置ToolTip的控件
|
||||||
|
/// </summary>
|
||||||
|
/// <returns>控件</returns>
|
||||||
public Control ExToolTipControl()
|
public Control ExToolTipControl()
|
||||||
{
|
{
|
||||||
return edit;
|
return edit;
|
||||||
@ -107,6 +111,9 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private readonly UIComboDataGridViewItem item = new UIComboDataGridViewItem();
|
private readonly UIComboDataGridViewItem item = new UIComboDataGridViewItem();
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 创建对象
|
||||||
|
/// </summary>
|
||||||
protected override void CreateInstance()
|
protected override void CreateInstance()
|
||||||
{
|
{
|
||||||
ItemForm = new UIDropDown(item);
|
ItemForm = new UIDropDown(item);
|
||||||
@ -119,6 +126,11 @@ namespace Sunny.UI
|
|||||||
public delegate void OnValueChanged(object sender, object value);
|
public delegate void OnValueChanged(object sender, object value);
|
||||||
public event OnValueChanged ValueChanged;
|
public event OnValueChanged ValueChanged;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 值改变事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="sender">控件</param>
|
||||||
|
/// <param name="value">值</param>
|
||||||
protected override void ItemForm_ValueChanged(object sender, object value)
|
protected override void ItemForm_ValueChanged(object sender, object value)
|
||||||
{
|
{
|
||||||
if (DataGridView.MultiSelect)
|
if (DataGridView.MultiSelect)
|
||||||
|
@ -67,6 +67,10 @@ namespace Sunny.UI
|
|||||||
[Description("下拉框高度"), Category("SunnyUI")]
|
[Description("下拉框高度"), Category("SunnyUI")]
|
||||||
public int DropDownHeight { get; set; }
|
public int DropDownHeight { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 需要额外设置ToolTip的控件
|
||||||
|
/// </summary>
|
||||||
|
/// <returns>控件</returns>
|
||||||
public Control ExToolTipControl()
|
public Control ExToolTipControl()
|
||||||
{
|
{
|
||||||
return edit;
|
return edit;
|
||||||
@ -124,6 +128,9 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private readonly UIComboTreeViewItem item = new UIComboTreeViewItem();
|
private readonly UIComboTreeViewItem item = new UIComboTreeViewItem();
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 创建对象
|
||||||
|
/// </summary>
|
||||||
protected override void CreateInstance()
|
protected override void CreateInstance()
|
||||||
{
|
{
|
||||||
ItemForm = new UIDropDown(item);
|
ItemForm = new UIDropDown(item);
|
||||||
@ -146,6 +153,11 @@ namespace Sunny.UI
|
|||||||
public event OnNodeSelected NodeSelected;
|
public event OnNodeSelected NodeSelected;
|
||||||
public event OnNodesSelected NodesSelected;
|
public event OnNodesSelected NodesSelected;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 值改变事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="sender">控件</param>
|
||||||
|
/// <param name="value">值</param>
|
||||||
protected override void ItemForm_ValueChanged(object sender, object value)
|
protected override void ItemForm_ValueChanged(object sender, object value)
|
||||||
{
|
{
|
||||||
if (!CheckBoxes)
|
if (!CheckBoxes)
|
||||||
|
@ -389,9 +389,9 @@ namespace Sunny.UI
|
|||||||
protected bool lightStyle;
|
protected bool lightStyle;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// OnPaint
|
/// 重载绘图
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="e">e</param>
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
if (!Visible || Width <= 0 || Height <= 0) return;
|
if (!Visible || Width <= 0 || Height <= 0) return;
|
||||||
|
@ -337,6 +337,10 @@ namespace Sunny.UI
|
|||||||
SetBarPosition();
|
SetBarPosition();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
|
@ -79,6 +79,10 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 需要额外设置ToolTip的控件
|
||||||
|
/// </summary>
|
||||||
|
/// <returns>控件</returns>
|
||||||
public Control ExToolTipControl()
|
public Control ExToolTipControl()
|
||||||
{
|
{
|
||||||
return edit;
|
return edit;
|
||||||
@ -124,6 +128,11 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
public event OnDateTimeChanged ValueChanged;
|
public event OnDateTimeChanged ValueChanged;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 值改变事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="sender">控件</param>
|
||||||
|
/// <param name="value">值</param>
|
||||||
protected override void ItemForm_ValueChanged(object sender, object value)
|
protected override void ItemForm_ValueChanged(object sender, object value)
|
||||||
{
|
{
|
||||||
Value = (DateTime)value;
|
Value = (DateTime)value;
|
||||||
@ -132,6 +141,9 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private readonly UIDateItem item = new UIDateItem();
|
private readonly UIDateItem item = new UIDateItem();
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 创建对象
|
||||||
|
/// </summary>
|
||||||
protected override void CreateInstance()
|
protected override void CreateInstance()
|
||||||
{
|
{
|
||||||
ItemForm = new UIDropDown(item);
|
ItemForm = new UIDropDown(item);
|
||||||
|
@ -50,6 +50,10 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 需要额外设置ToolTip的控件
|
||||||
|
/// </summary>
|
||||||
|
/// <returns>控件</returns>
|
||||||
public Control ExToolTipControl()
|
public Control ExToolTipControl()
|
||||||
{
|
{
|
||||||
return edit;
|
return edit;
|
||||||
@ -115,6 +119,11 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
public event OnDateTimeChanged ValueChanged;
|
public event OnDateTimeChanged ValueChanged;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 值改变事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="sender">控件</param>
|
||||||
|
/// <param name="value">值</param>
|
||||||
protected override void ItemForm_ValueChanged(object sender, object value)
|
protected override void ItemForm_ValueChanged(object sender, object value)
|
||||||
{
|
{
|
||||||
Value = (DateTime)value;
|
Value = (DateTime)value;
|
||||||
@ -123,6 +132,9 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private readonly UIDateTimeItem item = new UIDateTimeItem();
|
private readonly UIDateTimeItem item = new UIDateTimeItem();
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 创建对象
|
||||||
|
/// </summary>
|
||||||
protected override void CreateInstance()
|
protected override void CreateInstance()
|
||||||
{
|
{
|
||||||
ItemForm = new UIDropDown(item);
|
ItemForm = new UIDropDown(item);
|
||||||
|
@ -59,6 +59,10 @@ namespace Sunny.UI
|
|||||||
[Description("禁止输入"), Category("SunnyUI")]
|
[Description("禁止输入"), Category("SunnyUI")]
|
||||||
public bool ForbidInput { get; set; }
|
public bool ForbidInput { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 需要额外设置ToolTip的控件
|
||||||
|
/// </summary>
|
||||||
|
/// <returns>控件</returns>
|
||||||
public Control ExToolTipControl()
|
public Control ExToolTipControl()
|
||||||
{
|
{
|
||||||
return pnlValue;
|
return pnlValue;
|
||||||
|
@ -137,6 +137,10 @@ namespace Sunny.UI
|
|||||||
this.Focus();
|
this.Focus();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
|
@ -74,6 +74,10 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
public new event ScrollEventHandler Scroll;
|
public new event ScrollEventHandler Scroll;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 需要额外设置ToolTip的控件
|
||||||
|
/// </summary>
|
||||||
|
/// <returns>控件</returns>
|
||||||
public Control ExToolTipControl()
|
public Control ExToolTipControl()
|
||||||
{
|
{
|
||||||
return Panel;
|
return Panel;
|
||||||
|
@ -174,6 +174,10 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 点击事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">参数</param>
|
||||||
protected override void OnClick(EventArgs e)
|
protected override void OnClick(EventArgs e)
|
||||||
{
|
{
|
||||||
Focus();
|
Focus();
|
||||||
@ -583,6 +587,10 @@ namespace Sunny.UI
|
|||||||
base.OnKeyUp(e);
|
base.OnKeyUp(e);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
//重绘父类
|
//重绘父类
|
||||||
|
@ -162,6 +162,10 @@ namespace Sunny.UI
|
|||||||
return new Rectangle(17, 1, Width - 17 * 2, Height - 2);
|
return new Rectangle(17, 1, Width - 17 * 2, Height - 2);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
e.Graphics.Clear(fillColor);
|
e.Graphics.Clear(fillColor);
|
||||||
|
@ -250,6 +250,10 @@ namespace Sunny.UI
|
|||||||
txt4.ForeColor = UIFontColor.Primary;
|
txt4.ForeColor = UIFontColor.Primary;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
|
@ -67,6 +67,10 @@ namespace Sunny.UI
|
|||||||
listbox.MouseMove += Listbox_MouseMove;
|
listbox.MouseMove += Listbox_MouseMove;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 需要额外设置ToolTip的控件
|
||||||
|
/// </summary>
|
||||||
|
/// <returns>控件</returns>
|
||||||
public Control ExToolTipControl()
|
public Control ExToolTipControl()
|
||||||
{
|
{
|
||||||
return listbox;
|
return listbox;
|
||||||
|
@ -56,6 +56,10 @@ namespace Sunny.UI
|
|||||||
[Description("禁止输入"), Category("SunnyUI")]
|
[Description("禁止输入"), Category("SunnyUI")]
|
||||||
public bool ForbidInput { get; set; }
|
public bool ForbidInput { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 需要额外设置ToolTip的控件
|
||||||
|
/// </summary>
|
||||||
|
/// <returns>控件</returns>
|
||||||
public Control ExToolTipControl()
|
public Control ExToolTipControl()
|
||||||
{
|
{
|
||||||
return pnlValue;
|
return pnlValue;
|
||||||
|
@ -157,6 +157,10 @@ namespace Sunny.UI
|
|||||||
set => SetStyle(value);
|
set => SetStyle(value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
if (TextAlign == ContentAlignment.MiddleCenter && Angle != 0 && !AutoSize)
|
if (TextAlign == ContentAlignment.MiddleCenter && Angle != 0 && !AutoSize)
|
||||||
|
@ -137,8 +137,9 @@ namespace Sunny.UI
|
|||||||
#region Methods
|
#region Methods
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Handles the Paint event for this UserControl
|
/// 重载绘图
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
// Create an offscreen graphics object for double buffering
|
// Create an offscreen graphics object for double buffering
|
||||||
|
@ -288,9 +288,9 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 重绘
|
/// 重载绘图
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="e">e</param>
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
|
@ -39,6 +39,10 @@ namespace Sunny.UI
|
|||||||
foreColor = UIStyles.Blue.LedLabelForeColor;
|
foreColor = UIStyles.Blue.LedLabelForeColor;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
|
@ -177,6 +177,10 @@ namespace Sunny.UI
|
|||||||
KeyPress?.Invoke(this, e);
|
KeyPress?.Invoke(this, e);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 需要额外设置ToolTip的控件
|
||||||
|
/// </summary>
|
||||||
|
/// <returns>控件</returns>
|
||||||
public Control ExToolTipControl()
|
public Control ExToolTipControl()
|
||||||
{
|
{
|
||||||
return listbox;
|
return listbox;
|
||||||
|
@ -46,6 +46,10 @@ namespace Sunny.UI
|
|||||||
fillColor = UIColor.Blue;
|
fillColor = UIColor.Blue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
|
@ -118,6 +118,10 @@ namespace Sunny.UI
|
|||||||
markColor = uiColor.MarkLabelForeColor;
|
markColor = uiColor.MarkLabelForeColor;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
|
@ -423,6 +423,10 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
|
@ -127,6 +127,10 @@ namespace Sunny.UI
|
|||||||
private Bitmap image;
|
private Bitmap image;
|
||||||
private int imageRadius;
|
private int imageRadius;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
|
@ -54,6 +54,10 @@ namespace Sunny.UI
|
|||||||
fillColor = UIStyles.Blue.CheckBoxColor;
|
fillColor = UIStyles.Blue.CheckBoxColor;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
@ -221,6 +225,10 @@ namespace Sunny.UI
|
|||||||
Invalidate();
|
Invalidate();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 点击事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">参数</param>
|
||||||
protected override void OnClick(EventArgs e)
|
protected override void OnClick(EventArgs e)
|
||||||
{
|
{
|
||||||
if (!ReadOnly)
|
if (!ReadOnly)
|
||||||
|
@ -107,6 +107,10 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
|
@ -163,6 +163,10 @@ namespace Sunny.UI
|
|||||||
DoubleClick?.Invoke(this, e);
|
DoubleClick?.Invoke(this, e);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 需要额外设置ToolTip的控件
|
||||||
|
/// </summary>
|
||||||
|
/// <returns>控件</returns>
|
||||||
public Control ExToolTipControl()
|
public Control ExToolTipControl()
|
||||||
{
|
{
|
||||||
return edit;
|
return edit;
|
||||||
|
@ -227,9 +227,9 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 重绘
|
/// 重载绘图
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="e">e</param>
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
if (_backImage != null)
|
if (_backImage != null)
|
||||||
|
@ -167,6 +167,10 @@ namespace Sunny.UI
|
|||||||
return clip;
|
return clip;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
e.Graphics.Clear(fillColor);
|
e.Graphics.Clear(fillColor);
|
||||||
|
@ -135,6 +135,10 @@ namespace Sunny.UI
|
|||||||
//
|
//
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
|
@ -243,6 +243,10 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
if (Text.IsNullOrEmpty()) return;
|
if (Text.IsNullOrEmpty()) return;
|
||||||
|
@ -348,6 +348,10 @@ namespace Sunny.UI
|
|||||||
handler?.Invoke(this, e);
|
handler?.Invoke(this, e);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
|
@ -182,6 +182,10 @@ namespace Sunny.UI
|
|||||||
set => SetRectColor(value);
|
set => SetRectColor(value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 点击事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">参数</param>
|
||||||
protected override void OnClick(EventArgs e)
|
protected override void OnClick(EventArgs e)
|
||||||
{
|
{
|
||||||
if (!ReadOnly) Active = !Active;
|
if (!ReadOnly) Active = !Active;
|
||||||
|
@ -346,6 +346,10 @@ namespace Sunny.UI
|
|||||||
return Enabled ? color : symbolDisableColor;
|
return Enabled ? color : symbolDisableColor;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
//重绘父类
|
//重绘父类
|
||||||
|
@ -243,6 +243,10 @@ namespace Sunny.UI
|
|||||||
foreColor = uiColor.LabelForeColor;
|
foreColor = uiColor.LabelForeColor;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
//重绘父类
|
//重绘父类
|
||||||
|
@ -604,6 +604,10 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private ConcurrentDictionary<int, bool> CloseRects = new ConcurrentDictionary<int, bool>();
|
private ConcurrentDictionary<int, bool> CloseRects = new ConcurrentDictionary<int, bool>();
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
|
@ -334,6 +334,10 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
|
@ -230,6 +230,10 @@ namespace Sunny.UI
|
|||||||
MouseLeave?.Invoke(this, e);
|
MouseLeave?.Invoke(this, e);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 需要额外设置ToolTip的控件
|
||||||
|
/// </summary>
|
||||||
|
/// <returns>控件</returns>
|
||||||
public Control ExToolTipControl()
|
public Control ExToolTipControl()
|
||||||
{
|
{
|
||||||
return edit;
|
return edit;
|
||||||
@ -1155,6 +1159,10 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
|
@ -47,6 +47,10 @@ namespace Sunny.UI
|
|||||||
this.PerformLayout();
|
this.PerformLayout();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 需要额外设置ToolTip的控件
|
||||||
|
/// </summary>
|
||||||
|
/// <returns>控件</returns>
|
||||||
public Control ExToolTipControl()
|
public Control ExToolTipControl()
|
||||||
{
|
{
|
||||||
return edit;
|
return edit;
|
||||||
@ -106,6 +110,11 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
public event OnDateTimeChanged ValueChanged;
|
public event OnDateTimeChanged ValueChanged;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 值改变事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="sender">控件</param>
|
||||||
|
/// <param name="value">值</param>
|
||||||
protected override void ItemForm_ValueChanged(object sender, object value)
|
protected override void ItemForm_ValueChanged(object sender, object value)
|
||||||
{
|
{
|
||||||
Value = (DateTime)value;
|
Value = (DateTime)value;
|
||||||
@ -114,6 +123,9 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
private readonly UITimeItem item = new UITimeItem();
|
private readonly UITimeItem item = new UITimeItem();
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 创建对象
|
||||||
|
/// </summary>
|
||||||
protected override void CreateInstance()
|
protected override void CreateInstance()
|
||||||
{
|
{
|
||||||
ItemForm = new UIDropDown(item);
|
ItemForm = new UIDropDown(item);
|
||||||
|
@ -249,9 +249,9 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// OnPaint
|
/// 重载绘图
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="e">e</param>
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
|
@ -141,6 +141,10 @@ namespace Sunny.UI
|
|||||||
AfterLabelEdit?.Invoke(this, e);
|
AfterLabelEdit?.Invoke(this, e);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 需要额外设置ToolTip的控件
|
||||||
|
/// </summary>
|
||||||
|
/// <returns>控件</returns>
|
||||||
public Control ExToolTipControl()
|
public Control ExToolTipControl()
|
||||||
{
|
{
|
||||||
return view;
|
return view;
|
||||||
|
@ -372,6 +372,10 @@ namespace Sunny.UI
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
if (!Visible || Width <= 0 || Height <= 0) return;
|
if (!Visible || Width <= 0 || Height <= 0) return;
|
||||||
|
@ -65,6 +65,10 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 点击事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">参数</param>
|
||||||
protected override void OnClick(EventArgs e)
|
protected override void OnClick(EventArgs e)
|
||||||
{
|
{
|
||||||
base.OnClick(e);
|
base.OnClick(e);
|
||||||
@ -193,6 +197,10 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
int pipeSize = 20;
|
int pipeSize = 20;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
|
@ -49,6 +49,10 @@ namespace Sunny.UI
|
|||||||
fillColor = uiColor.PlainColor;
|
fillColor = uiColor.PlainColor;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 点击事件
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">参数</param>
|
||||||
protected override void OnClick(EventArgs e)
|
protected override void OnClick(EventArgs e)
|
||||||
{
|
{
|
||||||
base.OnClick(e);
|
base.OnClick(e);
|
||||||
|
@ -65,6 +65,10 @@ namespace Sunny.UI
|
|||||||
timer.Stop();
|
timer.Stop();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
|
@ -981,6 +981,10 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
protected bool IsActive;
|
protected bool IsActive;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
|
@ -539,6 +539,10 @@ namespace Sunny.UI
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重载绘图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="e">绘图参数</param>
|
||||||
protected override void OnPaint(PaintEventArgs e)
|
protected override void OnPaint(PaintEventArgs e)
|
||||||
{
|
{
|
||||||
base.OnPaint(e);
|
base.OnPaint(e);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user