diff --git a/Bin/net40/SunnyUI.Demo.exe b/Bin/net40/SunnyUI.Demo.exe
index 5610c46b..865f827a 100644
Binary files a/Bin/net40/SunnyUI.Demo.exe and b/Bin/net40/SunnyUI.Demo.exe differ
diff --git a/Bin/net40/SunnyUI.dll b/Bin/net40/SunnyUI.dll
index 645aa584..41d7c02f 100644
Binary files a/Bin/net40/SunnyUI.dll and b/Bin/net40/SunnyUI.dll differ
diff --git a/Bin/net5.0-windows/SunnyUI.dll b/Bin/net5.0-windows/SunnyUI.dll
index 9d21dc6f..eebf2e8d 100644
Binary files a/Bin/net5.0-windows/SunnyUI.dll and b/Bin/net5.0-windows/SunnyUI.dll differ
diff --git a/Bin/net5.0-windows/ref/SunnyUI.dll b/Bin/net5.0-windows/ref/SunnyUI.dll
index ec711da3..1a76bef7 100644
Binary files a/Bin/net5.0-windows/ref/SunnyUI.dll and b/Bin/net5.0-windows/ref/SunnyUI.dll differ
diff --git a/Bin/netcoreapp3.1/SunnyUI.dll b/Bin/netcoreapp3.1/SunnyUI.dll
index 76ef6ab0..672d1117 100644
Binary files a/Bin/netcoreapp3.1/SunnyUI.dll and b/Bin/netcoreapp3.1/SunnyUI.dll differ
diff --git a/SunnyUI.Demo/Controls/FOther.Designer.cs b/SunnyUI.Demo/Controls/FOther.Designer.cs
index 08701971..6d144f35 100644
--- a/SunnyUI.Demo/Controls/FOther.Designer.cs
+++ b/SunnyUI.Demo/Controls/FOther.Designer.cs
@@ -33,13 +33,6 @@
this.uiLine2 = new Sunny.UI.UILine();
this.uiLight2 = new Sunny.UI.UILight();
this.uiLight3 = new Sunny.UI.UILight();
- this.uiProcessBar1 = new Sunny.UI.UIProcessBar();
- this.uiLine3 = new Sunny.UI.UILine();
- this.uiProgressIndicator1 = new Sunny.UI.UIProgressIndicator();
- this.uiLine4 = new Sunny.UI.UILine();
- this.uiTrackBar1 = new Sunny.UI.UITrackBar();
- this.uiLine5 = new Sunny.UI.UILine();
- this.timer1 = new System.Windows.Forms.Timer(this.components);
this.uiLight4 = new Sunny.UI.UILight();
this.uiLedBulb1 = new Sunny.UI.UILedBulb();
this.uiLine8 = new Sunny.UI.UILine();
@@ -49,32 +42,20 @@
this.uiLine6 = new Sunny.UI.UILine();
this.uiScrollingText1 = new Sunny.UI.UIScrollingText();
this.uiScrollingText2 = new Sunny.UI.UIScrollingText();
- this.uiWaitingBar1 = new Sunny.UI.UIWaitingBar();
- this.uiLine1 = new Sunny.UI.UILine();
this.uiLine7 = new Sunny.UI.UILine();
this.uiLabel1 = new Sunny.UI.UILabel();
this.uiLabel2 = new Sunny.UI.UILabel();
this.uiLabel3 = new Sunny.UI.UILabel();
this.uiToolTip1 = new Sunny.UI.UIToolTip(this.components);
- this.uiProcessBar2 = new Sunny.UI.UIProcessBar();
- this.uiRoundProcess1 = new Sunny.UI.UIRoundProcess();
- this.uiLine9 = new Sunny.UI.UILine();
- this.uiRoundProcess2 = new Sunny.UI.UIRoundProcess();
this.PagePanel.SuspendLayout();
this.SuspendLayout();
//
// PagePanel
//
- this.PagePanel.Controls.Add(this.uiRoundProcess2);
- this.PagePanel.Controls.Add(this.uiLine9);
- this.PagePanel.Controls.Add(this.uiRoundProcess1);
- this.PagePanel.Controls.Add(this.uiProcessBar2);
this.PagePanel.Controls.Add(this.uiLabel3);
this.PagePanel.Controls.Add(this.uiLabel2);
this.PagePanel.Controls.Add(this.uiLabel1);
this.PagePanel.Controls.Add(this.uiLine7);
- this.PagePanel.Controls.Add(this.uiLine1);
- this.PagePanel.Controls.Add(this.uiWaitingBar1);
this.PagePanel.Controls.Add(this.uiScrollingText2);
this.PagePanel.Controls.Add(this.uiScrollingText1);
this.PagePanel.Controls.Add(this.uiLine6);
@@ -84,12 +65,6 @@
this.PagePanel.Controls.Add(this.uiLine8);
this.PagePanel.Controls.Add(this.uiLedBulb1);
this.PagePanel.Controls.Add(this.uiLight4);
- this.PagePanel.Controls.Add(this.uiLine5);
- this.PagePanel.Controls.Add(this.uiTrackBar1);
- this.PagePanel.Controls.Add(this.uiLine4);
- this.PagePanel.Controls.Add(this.uiProgressIndicator1);
- this.PagePanel.Controls.Add(this.uiLine3);
- this.PagePanel.Controls.Add(this.uiProcessBar1);
this.PagePanel.Controls.Add(this.uiLight3);
this.PagePanel.Controls.Add(this.uiLight2);
this.PagePanel.Controls.Add(this.uiLine2);
@@ -145,76 +120,6 @@
this.uiLight3.TabIndex = 23;
this.uiLight3.Text = "uiLight3";
//
- // uiProcessBar1
- //
- this.uiProcessBar1.Font = new System.Drawing.Font("微软雅黑", 12F);
- this.uiProcessBar1.Location = new System.Drawing.Point(30, 136);
- this.uiProcessBar1.MinimumSize = new System.Drawing.Size(70, 1);
- this.uiProcessBar1.Name = "uiProcessBar1";
- this.uiProcessBar1.Size = new System.Drawing.Size(318, 29);
- this.uiProcessBar1.TabIndex = 24;
- this.uiProcessBar1.Text = "50.0%";
- this.uiProcessBar1.Value = 50;
- //
- // uiLine3
- //
- this.uiLine3.Font = new System.Drawing.Font("微软雅黑", 12F);
- this.uiLine3.Location = new System.Drawing.Point(30, 103);
- this.uiLine3.MinimumSize = new System.Drawing.Size(16, 16);
- this.uiLine3.Name = "uiLine3";
- this.uiLine3.Size = new System.Drawing.Size(319, 20);
- this.uiLine3.TabIndex = 25;
- this.uiLine3.Text = "UIProcessBar";
- this.uiLine3.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
- //
- // uiProgressIndicator1
- //
- this.uiProgressIndicator1.Font = new System.Drawing.Font("微软雅黑", 12F);
- this.uiProgressIndicator1.Location = new System.Drawing.Point(381, 339);
- this.uiProgressIndicator1.MinimumSize = new System.Drawing.Size(1, 1);
- this.uiProgressIndicator1.Name = "uiProgressIndicator1";
- this.uiProgressIndicator1.Size = new System.Drawing.Size(120, 120);
- this.uiProgressIndicator1.TabIndex = 26;
- this.uiProgressIndicator1.Text = "uiProgressIndicator1";
- //
- // uiLine4
- //
- this.uiLine4.Font = new System.Drawing.Font("微软雅黑", 12F);
- this.uiLine4.Location = new System.Drawing.Point(381, 313);
- this.uiLine4.MinimumSize = new System.Drawing.Size(16, 16);
- this.uiLine4.Name = "uiLine4";
- this.uiLine4.Size = new System.Drawing.Size(319, 20);
- this.uiLine4.TabIndex = 27;
- this.uiLine4.Text = "UIProgressIndicator";
- this.uiLine4.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
- //
- // uiTrackBar1
- //
- this.uiTrackBar1.DisableColor = System.Drawing.Color.Silver;
- this.uiTrackBar1.Font = new System.Drawing.Font("微软雅黑", 12F);
- this.uiTrackBar1.Location = new System.Drawing.Point(381, 136);
- this.uiTrackBar1.MinimumSize = new System.Drawing.Size(1, 1);
- this.uiTrackBar1.Name = "uiTrackBar1";
- this.uiTrackBar1.Size = new System.Drawing.Size(158, 29);
- this.uiTrackBar1.TabIndex = 30;
- this.uiTrackBar1.Text = "uiTrackBar1";
- this.uiTrackBar1.Value = 50;
- //
- // uiLine5
- //
- this.uiLine5.Font = new System.Drawing.Font("微软雅黑", 12F);
- this.uiLine5.Location = new System.Drawing.Point(381, 101);
- this.uiLine5.MinimumSize = new System.Drawing.Size(16, 16);
- this.uiLine5.Name = "uiLine5";
- this.uiLine5.Size = new System.Drawing.Size(319, 20);
- this.uiLine5.TabIndex = 31;
- this.uiLine5.Text = "UITrackBar";
- this.uiLine5.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
- //
- // timer1
- //
- this.timer1.Tick += new System.EventHandler(this.timer1_Tick);
- //
// uiLight4
//
this.uiLight4.CenterColor = System.Drawing.Color.FromArgb(((int)(((byte)(239)))), ((int)(((byte)(248)))), ((int)(((byte)(232)))));
@@ -272,6 +177,7 @@
this.uiLedBulb4.BlinkInterval = 500;
this.uiLedBulb4.Location = new System.Drawing.Point(507, 52);
this.uiLedBulb4.Name = "uiLedBulb4";
+ this.uiLedBulb4.On = false;
this.uiLedBulb4.Size = new System.Drawing.Size(32, 32);
this.uiLedBulb4.TabIndex = 41;
this.uiLedBulb4.Text = "uiLedBulb4";
@@ -279,7 +185,7 @@
// uiLine6
//
this.uiLine6.Font = new System.Drawing.Font("微软雅黑", 12F);
- this.uiLine6.Location = new System.Drawing.Point(381, 182);
+ this.uiLine6.Location = new System.Drawing.Point(381, 98);
this.uiLine6.MinimumSize = new System.Drawing.Size(16, 16);
this.uiLine6.Name = "uiLine6";
this.uiLine6.Size = new System.Drawing.Size(319, 20);
@@ -292,7 +198,7 @@
this.uiScrollingText1.FillColor = System.Drawing.Color.FromArgb(((int)(((byte)(235)))), ((int)(((byte)(243)))), ((int)(((byte)(255)))));
this.uiScrollingText1.Font = new System.Drawing.Font("微软雅黑", 12F);
this.uiScrollingText1.ForeColor = System.Drawing.Color.Red;
- this.uiScrollingText1.Location = new System.Drawing.Point(381, 215);
+ this.uiScrollingText1.Location = new System.Drawing.Point(381, 131);
this.uiScrollingText1.MinimumSize = new System.Drawing.Size(1, 1);
this.uiScrollingText1.Name = "uiScrollingText1";
this.uiScrollingText1.ScrollingType = Sunny.UI.UIScrollingText.UIScrollingType.LeftToRight;
@@ -307,38 +213,17 @@
this.uiScrollingText2.FillColor = System.Drawing.Color.FromArgb(((int)(((byte)(235)))), ((int)(((byte)(243)))), ((int)(((byte)(255)))));
this.uiScrollingText2.Font = new System.Drawing.Font("微软雅黑", 12F);
this.uiScrollingText2.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(80)))), ((int)(((byte)(160)))), ((int)(((byte)(255)))));
- this.uiScrollingText2.Location = new System.Drawing.Point(381, 256);
+ this.uiScrollingText2.Location = new System.Drawing.Point(381, 172);
this.uiScrollingText2.MinimumSize = new System.Drawing.Size(1, 1);
this.uiScrollingText2.Name = "uiScrollingText2";
this.uiScrollingText2.Size = new System.Drawing.Size(319, 35);
this.uiScrollingText2.TabIndex = 49;
this.uiScrollingText2.Text = "赠人玫瑰手有余香";
//
- // uiWaitingBar1
- //
- this.uiWaitingBar1.Font = new System.Drawing.Font("微软雅黑", 12F);
- this.uiWaitingBar1.Location = new System.Drawing.Point(30, 215);
- this.uiWaitingBar1.MinimumSize = new System.Drawing.Size(70, 23);
- this.uiWaitingBar1.Name = "uiWaitingBar1";
- this.uiWaitingBar1.Size = new System.Drawing.Size(319, 29);
- this.uiWaitingBar1.TabIndex = 50;
- this.uiWaitingBar1.Text = "uiWaitingBar1";
- //
- // uiLine1
- //
- this.uiLine1.Font = new System.Drawing.Font("微软雅黑", 12F);
- this.uiLine1.Location = new System.Drawing.Point(30, 182);
- this.uiLine1.MinimumSize = new System.Drawing.Size(16, 16);
- this.uiLine1.Name = "uiLine1";
- this.uiLine1.Size = new System.Drawing.Size(319, 20);
- this.uiLine1.TabIndex = 51;
- this.uiLine1.Text = "UIWaitingBar";
- this.uiLine1.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
- //
// uiLine7
//
this.uiLine7.Font = new System.Drawing.Font("微软雅黑", 12F);
- this.uiLine7.Location = new System.Drawing.Point(29, 256);
+ this.uiLine7.Location = new System.Drawing.Point(30, 98);
this.uiLine7.MinimumSize = new System.Drawing.Size(16, 16);
this.uiLine7.Name = "uiLine7";
this.uiLine7.Size = new System.Drawing.Size(319, 20);
@@ -350,7 +235,7 @@
//
this.uiLabel1.AutoSize = true;
this.uiLabel1.Font = new System.Drawing.Font("微软雅黑", 12F);
- this.uiLabel1.Location = new System.Drawing.Point(30, 293);
+ this.uiLabel1.Location = new System.Drawing.Point(31, 138);
this.uiLabel1.Name = "uiLabel1";
this.uiLabel1.Size = new System.Drawing.Size(138, 21);
this.uiLabel1.TabIndex = 53;
@@ -362,7 +247,7 @@
//
this.uiLabel2.AutoSize = true;
this.uiLabel2.Font = new System.Drawing.Font("微软雅黑", 12F);
- this.uiLabel2.Location = new System.Drawing.Point(210, 293);
+ this.uiLabel2.Location = new System.Drawing.Point(211, 138);
this.uiLabel2.Name = "uiLabel2";
this.uiLabel2.Size = new System.Drawing.Size(138, 21);
this.uiLabel2.TabIndex = 54;
@@ -373,7 +258,7 @@
//
this.uiLabel3.AutoSize = true;
this.uiLabel3.Font = new System.Drawing.Font("微软雅黑", 12F);
- this.uiLabel3.Location = new System.Drawing.Point(30, 331);
+ this.uiLabel3.Location = new System.Drawing.Point(31, 179);
this.uiLabel3.Name = "uiLabel3";
this.uiLabel3.Size = new System.Drawing.Size(138, 21);
this.uiLabel3.TabIndex = 55;
@@ -387,56 +272,6 @@
this.uiToolTip1.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(239)))), ((int)(((byte)(239)))), ((int)(((byte)(239)))));
this.uiToolTip1.OwnerDraw = true;
//
- // uiProcessBar2
- //
- this.uiProcessBar2.Font = new System.Drawing.Font("微软雅黑", 12F);
- this.uiProcessBar2.Location = new System.Drawing.Point(30, 171);
- this.uiProcessBar2.MinimumSize = new System.Drawing.Size(70, 1);
- this.uiProcessBar2.Name = "uiProcessBar2";
- this.uiProcessBar2.Size = new System.Drawing.Size(318, 5);
- this.uiProcessBar2.TabIndex = 56;
- this.uiProcessBar2.Text = "50.0%";
- this.uiProcessBar2.Value = 50;
- //
- // uiRoundProcess1
- //
- this.uiRoundProcess1.BackColor = System.Drawing.Color.Transparent;
- this.uiRoundProcess1.Font = new System.Drawing.Font("微软雅黑", 12F);
- this.uiRoundProcess1.Location = new System.Drawing.Point(29, 393);
- this.uiRoundProcess1.MinimumSize = new System.Drawing.Size(1, 1);
- this.uiRoundProcess1.Name = "uiRoundProcess1";
- this.uiRoundProcess1.ShowProcess = true;
- this.uiRoundProcess1.Size = new System.Drawing.Size(120, 120);
- this.uiRoundProcess1.TabIndex = 57;
- this.uiRoundProcess1.Text = "0.0%";
- //
- // uiLine9
- //
- this.uiLine9.Font = new System.Drawing.Font("微软雅黑", 12F);
- this.uiLine9.Location = new System.Drawing.Point(30, 367);
- this.uiLine9.MinimumSize = new System.Drawing.Size(16, 16);
- this.uiLine9.Name = "uiLine9";
- this.uiLine9.Size = new System.Drawing.Size(319, 20);
- this.uiLine9.TabIndex = 58;
- this.uiLine9.Text = "UIRoundProcess";
- this.uiLine9.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
- //
- // uiRoundProcess2
- //
- this.uiRoundProcess2.BackColor = System.Drawing.Color.Transparent;
- this.uiRoundProcess2.Font = new System.Drawing.Font("微软雅黑", 12F);
- this.uiRoundProcess2.ForeColor = System.Drawing.Color.White;
- this.uiRoundProcess2.Inner = 0;
- this.uiRoundProcess2.Location = new System.Drawing.Point(156, 393);
- this.uiRoundProcess2.MinimumSize = new System.Drawing.Size(1, 1);
- this.uiRoundProcess2.Name = "uiRoundProcess2";
- this.uiRoundProcess2.ShowProcess = true;
- this.uiRoundProcess2.Size = new System.Drawing.Size(120, 120);
- this.uiRoundProcess2.Style = Sunny.UI.UIStyle.Custom;
- this.uiRoundProcess2.StyleCustomMode = true;
- this.uiRoundProcess2.TabIndex = 59;
- this.uiRoundProcess2.Text = "0.0%";
- //
// FOther
//
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
@@ -455,13 +290,6 @@
private UILight uiLight2;
private UILine uiLine2;
private UILight uiLight1;
- private UITrackBar uiTrackBar1;
- private UILine uiLine4;
- private UIProgressIndicator uiProgressIndicator1;
- private UILine uiLine3;
- private UIProcessBar uiProcessBar1;
- private UILine uiLine5;
- private System.Windows.Forms.Timer timer1;
private UILight uiLight4;
private UILedBulb uiLedBulb2;
private UILine uiLine8;
@@ -471,16 +299,10 @@
private UILine uiLine6;
private UIScrollingText uiScrollingText1;
private UIScrollingText uiScrollingText2;
- private UIWaitingBar uiWaitingBar1;
- private UILine uiLine1;
private UILine uiLine7;
private UILabel uiLabel3;
private UILabel uiLabel2;
private UILabel uiLabel1;
private UIToolTip uiToolTip1;
- private UIProcessBar uiProcessBar2;
- private UIRoundProcess uiRoundProcess1;
- private UIRoundProcess uiRoundProcess2;
- private UILine uiLine9;
}
}
\ No newline at end of file
diff --git a/SunnyUI.Demo/Controls/FOther.cs b/SunnyUI.Demo/Controls/FOther.cs
index 8b993670..a11f3e02 100644
--- a/SunnyUI.Demo/Controls/FOther.cs
+++ b/SunnyUI.Demo/Controls/FOther.cs
@@ -10,21 +10,5 @@
uiToolTip1.SetToolTip(uiLabel3, "赠人玫瑰手有余香" + '\n' + "赠人玫瑰手有余香",
"SunnyUI", 61530, 32, UIColor.Green);
}
-
- private int value;
-
- public override void Init()
- {
- value = 0;
- timer1.ReStart();
- }
-
- private void timer1_Tick(object sender, System.EventArgs e)
- {
- value++;
- uiTrackBar1.Value = value;
- uiProcessBar2.Value = uiProcessBar1.Value = value;
- uiRoundProcess2.Value = uiRoundProcess1.Value = value;
- }
}
}
\ No newline at end of file
diff --git a/SunnyUI.Demo/Controls/FOther.resx b/SunnyUI.Demo/Controls/FOther.resx
index 30293e22..2a21d5bb 100644
--- a/SunnyUI.Demo/Controls/FOther.resx
+++ b/SunnyUI.Demo/Controls/FOther.resx
@@ -120,8 +120,8 @@
107, 17
-
- 17, 17
+
+ 107, 17
35
diff --git a/SunnyUI.Demo/Controls/FProcess.cs b/SunnyUI.Demo/Controls/FProcess.cs
new file mode 100644
index 00000000..8c1098d0
--- /dev/null
+++ b/SunnyUI.Demo/Controls/FProcess.cs
@@ -0,0 +1,26 @@
+namespace Sunny.UI.Demo
+{
+ public partial class FProcess : UITitlePage
+ {
+ public FProcess()
+ {
+ InitializeComponent();
+ }
+
+ private int value;
+
+ public override void Init()
+ {
+ value = 0;
+ timer1.ReStart();
+ }
+
+ private void timer1_Tick(object sender, System.EventArgs e)
+ {
+ value++;
+ uiTrackBar1.Value = value;
+ uiProcessBar2.Value = uiProcessBar1.Value = value;
+ uiRoundProcess2.Value = uiRoundProcess1.Value = value;
+ }
+ }
+}
diff --git a/SunnyUI.Demo/Controls/FProcess.designer.cs b/SunnyUI.Demo/Controls/FProcess.designer.cs
new file mode 100644
index 00000000..95f45100
--- /dev/null
+++ b/SunnyUI.Demo/Controls/FProcess.designer.cs
@@ -0,0 +1,270 @@
+
+namespace Sunny.UI.Demo
+{
+ partial class FProcess
+ {
+ ///
+ /// Required designer variable.
+ ///
+ private System.ComponentModel.IContainer components = null;
+
+ ///
+ /// Clean up any resources being used.
+ ///
+ /// true if managed resources should be disposed; otherwise, false.
+ protected override void Dispose(bool disposing)
+ {
+ if (disposing && (components != null))
+ {
+ components.Dispose();
+ }
+ base.Dispose(disposing);
+ }
+
+ #region Windows Form Designer generated code
+
+ ///
+ /// Required method for Designer support - do not modify
+ /// the contents of this method with the code editor.
+ ///
+ private void InitializeComponent()
+ {
+ this.components = new System.ComponentModel.Container();
+ this.uiBreadcrumb1 = new Sunny.UI.UIBreadcrumb();
+ this.uiRoundProcess2 = new Sunny.UI.UIRoundProcess();
+ this.uiLine9 = new Sunny.UI.UILine();
+ this.uiRoundProcess1 = new Sunny.UI.UIRoundProcess();
+ this.uiProcessBar2 = new Sunny.UI.UIProcessBar();
+ this.uiLine1 = new Sunny.UI.UILine();
+ this.uiWaitingBar1 = new Sunny.UI.UIWaitingBar();
+ this.uiLine5 = new Sunny.UI.UILine();
+ this.uiTrackBar1 = new Sunny.UI.UITrackBar();
+ this.uiLine4 = new Sunny.UI.UILine();
+ this.uiProgressIndicator1 = new Sunny.UI.UIProgressIndicator();
+ this.uiLine3 = new Sunny.UI.UILine();
+ this.uiProcessBar1 = new Sunny.UI.UIProcessBar();
+ this.uiLine2 = new Sunny.UI.UILine();
+ this.timer1 = new System.Windows.Forms.Timer(this.components);
+ this.PagePanel.SuspendLayout();
+ this.SuspendLayout();
+ //
+ // PagePanel
+ //
+ this.PagePanel.Controls.Add(this.uiLine2);
+ this.PagePanel.Controls.Add(this.uiBreadcrumb1);
+ this.PagePanel.Controls.Add(this.uiRoundProcess2);
+ this.PagePanel.Controls.Add(this.uiLine9);
+ this.PagePanel.Controls.Add(this.uiRoundProcess1);
+ this.PagePanel.Controls.Add(this.uiProcessBar2);
+ this.PagePanel.Controls.Add(this.uiLine1);
+ this.PagePanel.Controls.Add(this.uiWaitingBar1);
+ this.PagePanel.Controls.Add(this.uiLine5);
+ this.PagePanel.Controls.Add(this.uiTrackBar1);
+ this.PagePanel.Controls.Add(this.uiLine4);
+ this.PagePanel.Controls.Add(this.uiProgressIndicator1);
+ this.PagePanel.Controls.Add(this.uiLine3);
+ this.PagePanel.Controls.Add(this.uiProcessBar1);
+ this.PagePanel.Size = new System.Drawing.Size(1022, 525);
+ //
+ // uiBreadcrumb1
+ //
+ this.uiBreadcrumb1.Font = new System.Drawing.Font("微软雅黑", 12F);
+ this.uiBreadcrumb1.ItemIndex = 2;
+ this.uiBreadcrumb1.Items.AddRange(new object[] {
+ "步骤一",
+ "步骤二",
+ "步骤三",
+ "步骤四",
+ "步骤五"});
+ this.uiBreadcrumb1.ItemWidth = 100;
+ this.uiBreadcrumb1.Location = new System.Drawing.Point(30, 372);
+ this.uiBreadcrumb1.MinimumSize = new System.Drawing.Size(1, 1);
+ this.uiBreadcrumb1.Name = "uiBreadcrumb1";
+ this.uiBreadcrumb1.Size = new System.Drawing.Size(588, 29);
+ this.uiBreadcrumb1.TabIndex = 73;
+ this.uiBreadcrumb1.Text = "uiBreadcrumb1";
+ //
+ // uiRoundProcess2
+ //
+ this.uiRoundProcess2.BackColor = System.Drawing.Color.Transparent;
+ this.uiRoundProcess2.Font = new System.Drawing.Font("微软雅黑", 12F);
+ this.uiRoundProcess2.ForeColor = System.Drawing.Color.White;
+ this.uiRoundProcess2.Inner = 0;
+ this.uiRoundProcess2.Location = new System.Drawing.Point(155, 138);
+ this.uiRoundProcess2.MinimumSize = new System.Drawing.Size(1, 1);
+ this.uiRoundProcess2.Name = "uiRoundProcess2";
+ this.uiRoundProcess2.ShowProcess = true;
+ this.uiRoundProcess2.Size = new System.Drawing.Size(120, 120);
+ this.uiRoundProcess2.Style = Sunny.UI.UIStyle.Custom;
+ this.uiRoundProcess2.StyleCustomMode = true;
+ this.uiRoundProcess2.TabIndex = 72;
+ this.uiRoundProcess2.Text = "0.0%";
+ //
+ // uiLine9
+ //
+ this.uiLine9.Font = new System.Drawing.Font("微软雅黑", 12F);
+ this.uiLine9.Location = new System.Drawing.Point(29, 112);
+ this.uiLine9.MinimumSize = new System.Drawing.Size(16, 16);
+ this.uiLine9.Name = "uiLine9";
+ this.uiLine9.Size = new System.Drawing.Size(319, 20);
+ this.uiLine9.TabIndex = 71;
+ this.uiLine9.Text = "UIRoundProcess";
+ this.uiLine9.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
+ //
+ // uiRoundProcess1
+ //
+ this.uiRoundProcess1.BackColor = System.Drawing.Color.Transparent;
+ this.uiRoundProcess1.Font = new System.Drawing.Font("微软雅黑", 12F);
+ this.uiRoundProcess1.Location = new System.Drawing.Point(28, 138);
+ this.uiRoundProcess1.MinimumSize = new System.Drawing.Size(1, 1);
+ this.uiRoundProcess1.Name = "uiRoundProcess1";
+ this.uiRoundProcess1.ShowProcess = true;
+ this.uiRoundProcess1.Size = new System.Drawing.Size(120, 120);
+ this.uiRoundProcess1.TabIndex = 70;
+ this.uiRoundProcess1.Text = "0.0%";
+ //
+ // uiProcessBar2
+ //
+ this.uiProcessBar2.Font = new System.Drawing.Font("微软雅黑", 12F);
+ this.uiProcessBar2.Location = new System.Drawing.Point(30, 88);
+ this.uiProcessBar2.MinimumSize = new System.Drawing.Size(70, 1);
+ this.uiProcessBar2.Name = "uiProcessBar2";
+ this.uiProcessBar2.Size = new System.Drawing.Size(318, 5);
+ this.uiProcessBar2.TabIndex = 69;
+ this.uiProcessBar2.Text = "50.0%";
+ this.uiProcessBar2.Value = 50;
+ //
+ // uiLine1
+ //
+ this.uiLine1.Font = new System.Drawing.Font("微软雅黑", 12F);
+ this.uiLine1.Location = new System.Drawing.Point(381, 20);
+ this.uiLine1.MinimumSize = new System.Drawing.Size(16, 16);
+ this.uiLine1.Name = "uiLine1";
+ this.uiLine1.Size = new System.Drawing.Size(319, 20);
+ this.uiLine1.TabIndex = 68;
+ this.uiLine1.Text = "UIWaitingBar";
+ this.uiLine1.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
+ //
+ // uiWaitingBar1
+ //
+ this.uiWaitingBar1.Font = new System.Drawing.Font("微软雅黑", 12F);
+ this.uiWaitingBar1.Location = new System.Drawing.Point(381, 53);
+ this.uiWaitingBar1.MinimumSize = new System.Drawing.Size(70, 23);
+ this.uiWaitingBar1.Name = "uiWaitingBar1";
+ this.uiWaitingBar1.Size = new System.Drawing.Size(319, 29);
+ this.uiWaitingBar1.TabIndex = 67;
+ this.uiWaitingBar1.Text = "uiWaitingBar1";
+ //
+ // uiLine5
+ //
+ this.uiLine5.Font = new System.Drawing.Font("微软雅黑", 12F);
+ this.uiLine5.Location = new System.Drawing.Point(30, 264);
+ this.uiLine5.MinimumSize = new System.Drawing.Size(16, 16);
+ this.uiLine5.Name = "uiLine5";
+ this.uiLine5.Size = new System.Drawing.Size(319, 20);
+ this.uiLine5.TabIndex = 66;
+ this.uiLine5.Text = "UITrackBar";
+ this.uiLine5.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
+ //
+ // uiTrackBar1
+ //
+ this.uiTrackBar1.DisableColor = System.Drawing.Color.Silver;
+ this.uiTrackBar1.Font = new System.Drawing.Font("微软雅黑", 12F);
+ this.uiTrackBar1.Location = new System.Drawing.Point(30, 290);
+ this.uiTrackBar1.MinimumSize = new System.Drawing.Size(1, 1);
+ this.uiTrackBar1.Name = "uiTrackBar1";
+ this.uiTrackBar1.Size = new System.Drawing.Size(158, 29);
+ this.uiTrackBar1.TabIndex = 65;
+ this.uiTrackBar1.Text = "uiTrackBar1";
+ this.uiTrackBar1.Value = 50;
+ //
+ // uiLine4
+ //
+ this.uiLine4.Font = new System.Drawing.Font("微软雅黑", 12F);
+ this.uiLine4.Location = new System.Drawing.Point(381, 112);
+ this.uiLine4.MinimumSize = new System.Drawing.Size(16, 16);
+ this.uiLine4.Name = "uiLine4";
+ this.uiLine4.Size = new System.Drawing.Size(319, 20);
+ this.uiLine4.TabIndex = 64;
+ this.uiLine4.Text = "UIProgressIndicator";
+ this.uiLine4.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
+ //
+ // uiProgressIndicator1
+ //
+ this.uiProgressIndicator1.Font = new System.Drawing.Font("微软雅黑", 12F);
+ this.uiProgressIndicator1.Location = new System.Drawing.Point(381, 138);
+ this.uiProgressIndicator1.MinimumSize = new System.Drawing.Size(1, 1);
+ this.uiProgressIndicator1.Name = "uiProgressIndicator1";
+ this.uiProgressIndicator1.Size = new System.Drawing.Size(120, 120);
+ this.uiProgressIndicator1.TabIndex = 63;
+ this.uiProgressIndicator1.Text = "uiProgressIndicator1";
+ //
+ // uiLine3
+ //
+ this.uiLine3.Font = new System.Drawing.Font("微软雅黑", 12F);
+ this.uiLine3.Location = new System.Drawing.Point(30, 20);
+ this.uiLine3.MinimumSize = new System.Drawing.Size(16, 16);
+ this.uiLine3.Name = "uiLine3";
+ this.uiLine3.Size = new System.Drawing.Size(319, 20);
+ this.uiLine3.TabIndex = 62;
+ this.uiLine3.Text = "UIProcessBar";
+ this.uiLine3.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
+ //
+ // uiProcessBar1
+ //
+ this.uiProcessBar1.Font = new System.Drawing.Font("微软雅黑", 12F);
+ this.uiProcessBar1.Location = new System.Drawing.Point(30, 53);
+ this.uiProcessBar1.MinimumSize = new System.Drawing.Size(70, 1);
+ this.uiProcessBar1.Name = "uiProcessBar1";
+ this.uiProcessBar1.Size = new System.Drawing.Size(318, 29);
+ this.uiProcessBar1.TabIndex = 61;
+ this.uiProcessBar1.Text = "50.0%";
+ this.uiProcessBar1.Value = 50;
+ //
+ // uiLine2
+ //
+ this.uiLine2.Font = new System.Drawing.Font("微软雅黑", 12F);
+ this.uiLine2.Location = new System.Drawing.Point(30, 334);
+ this.uiLine2.MinimumSize = new System.Drawing.Size(16, 16);
+ this.uiLine2.Name = "uiLine2";
+ this.uiLine2.Size = new System.Drawing.Size(319, 20);
+ this.uiLine2.TabIndex = 74;
+ this.uiLine2.Text = "UIBreadcrumb";
+ this.uiLine2.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
+ //
+ // timer1
+ //
+ this.timer1.Tick += new System.EventHandler(this.timer1_Tick);
+ //
+ // FProcess
+ //
+ this.AutoScaleDimensions = new System.Drawing.SizeF(10F, 21F);
+ this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+ this.ClientSize = new System.Drawing.Size(1022, 560);
+ this.Name = "FProcess";
+ this.Symbol = 62034;
+ this.Text = "Progress";
+ this.PagePanel.ResumeLayout(false);
+ this.ResumeLayout(false);
+
+ }
+
+ #endregion
+
+ private UIBreadcrumb uiBreadcrumb1;
+ private UIRoundProcess uiRoundProcess2;
+ private UILine uiLine9;
+ private UIRoundProcess uiRoundProcess1;
+ private UIProcessBar uiProcessBar2;
+ private UILine uiLine1;
+ private UIWaitingBar uiWaitingBar1;
+ private UILine uiLine5;
+ private UITrackBar uiTrackBar1;
+ private UILine uiLine4;
+ private UIProgressIndicator uiProgressIndicator1;
+ private UILine uiLine3;
+ private UIProcessBar uiProcessBar1;
+ private UILine uiLine2;
+ private System.Windows.Forms.Timer timer1;
+ }
+}
\ No newline at end of file
diff --git a/SunnyUI.Demo/Controls/FProcess.resx b/SunnyUI.Demo/Controls/FProcess.resx
new file mode 100644
index 00000000..1f666f26
--- /dev/null
+++ b/SunnyUI.Demo/Controls/FProcess.resx
@@ -0,0 +1,123 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ text/microsoft-resx
+
+
+ 2.0
+
+
+ System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ 17, 17
+
+
\ No newline at end of file
diff --git a/SunnyUI.Demo/FMain.cs b/SunnyUI.Demo/FMain.cs
index c412dd14..ee11c2ea 100644
--- a/SunnyUI.Demo/FMain.cs
+++ b/SunnyUI.Demo/FMain.cs
@@ -34,6 +34,7 @@ namespace Sunny.UI.Demo
Aside.CreateChildNode(parent, 61516, 24, AddPage(new FTransfer(), ++pageIndex));
Aside.CreateChildNode(parent, 61447, 24, AddPage(new FAvatar(), ++pageIndex));
Aside.CreateChildNode(parent, 62104, 24, AddPage(new FContextMenuStrip(), ++pageIndex));
+ Aside.CreateChildNode(parent, AddPage(new FProcess(), ++pageIndex));
Aside.CreateChildNode(parent, AddPage(new FScrollBar(), ++pageIndex));
Aside.CreateChildNode(parent, 61668, 24, AddPage(new FMeter(), ++pageIndex));
Aside.CreateChildNode(parent, 62173, 24, AddPage(new FOther(), ++pageIndex));
diff --git a/SunnyUI.Demo/SunnyUI.Demo.csproj b/SunnyUI.Demo/SunnyUI.Demo.csproj
index f738b216..c4f8a53b 100644
--- a/SunnyUI.Demo/SunnyUI.Demo.csproj
+++ b/SunnyUI.Demo/SunnyUI.Demo.csproj
@@ -171,6 +171,12 @@
FPanel.cs
+
+ Form
+
+
+ FProcess.cs
+
Form
@@ -383,6 +389,9 @@
FPanel.cs
+
+ FProcess.cs
+
FRadioButton.cs
diff --git a/SunnyUI/Controls/UIBreadcrumb.cs b/SunnyUI/Controls/UIBreadcrumb.cs
new file mode 100644
index 00000000..4d5ceef5
--- /dev/null
+++ b/SunnyUI/Controls/UIBreadcrumb.cs
@@ -0,0 +1,235 @@
+using System;
+using System.Collections.Concurrent;
+using System.Collections.Generic;
+using System.ComponentModel;
+using System.Drawing;
+using System.Drawing.Design;
+using System.Drawing.Drawing2D;
+using System.Windows.Forms;
+
+namespace Sunny.UI
+{
+ [ToolboxItem(true)]
+ [DefaultEvent("ItemIndexChanged")]
+ [DefaultProperty("ItemIndex")]
+ public class UIBreadcrumb : UIControl
+ {
+ public UIBreadcrumb()
+ {
+ ShowText = false;
+ ShowRect = false;
+ Height = 29;
+ ItemWidth = 120;
+
+ fillColor = UIColor.Blue;
+ rectColor = Color.FromArgb(155, 200, 255);
+ foreColor = Color.White;
+ }
+
+ public delegate void OnValueChanged(object sender, int value);
+
+ public event OnValueChanged ItemIndexChanged;
+
+ private readonly ListBoxEx listbox = new ListBoxEx();
+
+ [DesignerSerializationVisibility(DesignerSerializationVisibility.Content)]
+ [Localizable(true)]
+ [Editor("System.Windows.Forms.Design.ListControlStringCollectionEditor, System.Design, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a", typeof(UITypeEditor))]
+ [MergableProperty(false)]
+ [Description("列表项"), Category("SunnyUI")]
+ public ListBox.ObjectCollection Items => listbox.Items;
+
+ private readonly ConcurrentDictionary ClickArea = new ConcurrentDictionary();
+
+ [Browsable(false)]
+ public int Count => Items.Count;
+
+ private int itemIndex = -1;
+
+ [DefaultValue(-1)]
+ [Description("当前节点索引"), Category("SunnyUI")]
+ public int ItemIndex
+ {
+ get => itemIndex;
+ set
+ {
+ if (Count == 0)
+ {
+ itemIndex = 0;
+ }
+ else
+ {
+ itemIndex = Math.Max(-1, value);
+ itemIndex = Math.Min(Count - 1, value);
+ ItemIndexChanged?.Invoke(this, itemIndex);
+ Invalidate();
+ }
+ }
+ }
+
+ protected override void OnPaintFill(Graphics g, GraphicsPath path)
+ {
+ float width = 0;
+ if (Items.Count == 0)
+ {
+ SizeF sf = g.MeasureString("Item0", Font);
+ width = sf.Width + Height + 6;
+ if (itemWidth < width) itemWidth = (int)width;
+ List points = new List();
+ points.Add(new PointF(3, 0));
+ points.Add(new PointF(Width - 3 - Height / 2.0f, 0));
+ points.Add(new PointF(Width - 3, Height / 2.0f));
+ points.Add(new PointF(Width - 3 - Height / 2.0f, Height));
+ points.Add(new PointF(3, Height));
+ points.Add(new PointF(3 + Height / 2.0f, Height / 2.0f));
+ points.Add(new PointF(3, 0));
+
+ using (Brush br = new SolidBrush(SelectedColor))
+ {
+ g.FillPolygon(br, points.ToArray());
+ }
+
+ g.DrawString("Item0", Font, ForeColor, (Width - sf.Width) / 2.0f, (Height - sf.Height) / 2.0f);
+ }
+ else
+ {
+ foreach (var item in Items)
+ {
+ SizeF sf = g.MeasureString(item.ToString(), Font);
+ width = Math.Max(width, sf.Width);
+ }
+
+ width = width + Height + 6;
+ if (itemWidth < width) itemWidth = (int)width;
+
+ float begin = 0;
+ int index = 0;
+ foreach (var item in Items)
+ {
+ SizeF sf = g.MeasureString(item.ToString(), Font);
+ List points = new List();
+ points.Add(new PointF(begin + 3, 0));
+ points.Add(new PointF(begin + itemWidth - 3 - Height / 2.0f, 0));
+ points.Add(new PointF(begin + itemWidth - 3, Height / 2.0f));
+ points.Add(new PointF(begin + itemWidth - 3 - Height / 2.0f, Height));
+ points.Add(new PointF(begin + 3, Height));
+ points.Add(new PointF(begin + 3 + Height / 2.0f, Height / 2.0f));
+ points.Add(new PointF(begin + 3, 0));
+
+ Point[] pts = new Point[points.Count];
+ for (int i = 0; i < points.Count; i++)
+ {
+ pts[i] = new Point((int)points[i].X, (int)points[i].Y);
+ }
+
+ if (!ClickArea.ContainsKey(index))
+ {
+ ClickArea.TryAdd(index, pts);
+ }
+ else
+ {
+ ClickArea[index] = pts;
+ }
+
+ using (Brush br = new SolidBrush(index <= ItemIndex ? SelectedColor : UnSelectedColor))
+ {
+ g.FillPolygon(br, points.ToArray());
+ }
+
+ g.DrawString(item.ToString(), Font, ForeColor, begin + (itemWidth - sf.Width) / 2.0f, (Height - sf.Height) / 2.0f);
+
+ begin = begin + itemWidth - 3 - Height / 2.0f + Interval;
+ index++;
+ }
+ }
+ }
+
+ private int itemWidth;
+
+ [DefaultValue(120)]
+ [Description("节点宽度"), Category("SunnyUI")]
+ public int ItemWidth
+ {
+ get => itemWidth;
+ set
+ {
+ itemWidth = value;
+ Invalidate();
+ }
+ }
+
+ private int interval = 1;
+
+ [DefaultValue(1)]
+ [Description("节点间隔"), Category("SunnyUI")]
+ public int Interval
+ {
+ get => interval;
+ set
+ {
+ interval = value;
+ Invalidate();
+ }
+ }
+
+ ///
+ /// 已选节点颜色
+ ///
+ [Description("已选节点颜色")]
+ [Category("SunnyUI")]
+ [DefaultValue(typeof(Color), "80, 160, 255")]
+ public Color SelectedColor
+ {
+ get => fillColor;
+ set => SetFillColor(value);
+ }
+
+ ///
+ /// 未选节点颜色
+ ///
+ [Description("未选节点颜色")]
+ [Category("SunnyUI")]
+ [DefaultValue(typeof(Color), "155, 200, 255")]
+ public Color UnSelectedColor
+ {
+ get => rectColor;
+ set => SetRectColor(value);
+ }
+
+ ///
+ /// 字体颜色
+ ///
+ [Description("字体颜色")]
+ [Category("SunnyUI")]
+ [DefaultValue(typeof(Color), "White")]
+ public override Color ForeColor
+ {
+ get => foreColor;
+ set => SetForeColor(value);
+ }
+
+ public override void SetStyleColor(UIBaseStyle uiColor)
+ {
+ base.SetStyleColor(uiColor);
+ if (uiColor.IsCustom()) return;
+
+ fillColor = uiColor.PrimaryColor;
+ foreColor = uiColor.ButtonForeColor;
+ rectColor = uiColor.GridSelectedColor;
+ Invalidate();
+ }
+
+ protected override void OnMouseClick(MouseEventArgs e)
+ {
+ base.OnMouseClick(e);
+ foreach (var pair in ClickArea)
+ {
+ if (e.Location.InRegion(pair.Value))
+ {
+ ItemIndex = pair.Key;
+ break;
+ }
+ }
+ }
+ }
+}