fix: 收敛旧控件资源与后台线程生命周期
This commit is contained in:
@@ -160,9 +160,11 @@ namespace Lskj.Control
|
||||
}
|
||||
else
|
||||
{
|
||||
Graphics g = this.lblText.CreateGraphics();
|
||||
SizeF sizeF = g.MeasureString(value, this.lblText.Font);
|
||||
this.plLeft.Width = (int)sizeF.Width + PaddingLeft;
|
||||
this.plLeft.Width = TextRenderer.MeasureText(
|
||||
value,
|
||||
this.lblText.Font,
|
||||
Size.Empty,
|
||||
TextFormatFlags.NoPadding | TextFormatFlags.SingleLine).Width + PaddingLeft;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user