Commit 50dd92ea HZH

双缓存

1 个父辈 3f792581
......@@ -53,6 +53,12 @@ namespace HZH_Controls.Controls
public UCLEDNum()
{
this.SetStyle(ControlStyles.AllPaintingInWmPaint, true);
this.SetStyle(ControlStyles.DoubleBuffer, true);
this.SetStyle(ControlStyles.ResizeRedraw, true);
this.SetStyle(ControlStyles.Selectable, true);
this.SetStyle(ControlStyles.SupportsTransparentBackColor, true);
this.SetStyle(ControlStyles.UserPaint, true);
SizeChanged += LEDNum_SizeChanged;
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
Size = new System.Drawing.Size(40, 70);
......
......@@ -109,6 +109,13 @@ namespace HZH_Controls.Controls
Timer m_timer;
public UCRollText()
{
this.SetStyle(ControlStyles.AllPaintingInWmPaint, true);
this.SetStyle(ControlStyles.DoubleBuffer, true);
this.SetStyle(ControlStyles.ResizeRedraw, true);
this.SetStyle(ControlStyles.Selectable, true);
this.SetStyle(ControlStyles.SupportsTransparentBackColor, true);
this.SetStyle(ControlStyles.UserPaint, true);
this.SizeChanged += UCRollText_SizeChanged;
this.Size = new Size(450, 30);
Text = "滚动文字";
......
......@@ -181,7 +181,7 @@
this.ucRollText1.Location = new System.Drawing.Point(843, 554);
this.ucRollText1.MoveSleepTime = 50;
this.ucRollText1.Name = "ucRollText1";
this.ucRollText1.RollStyle = HZH_Controls.Controls.RollStyle.LeftToRight;
this.ucRollText1.RollStyle = HZH_Controls.Controls.RollStyle.BackAndForth;
this.ucRollText1.Size = new System.Drawing.Size(555, 30);
this.ucRollText1.TabIndex = 23;
//
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!