diff options
| author | lempamo <[email protected]> | 2017-09-19 00:04:20 -0400 |
|---|---|---|
| committer | lempamo <[email protected]> | 2017-09-19 00:04:20 -0400 |
| commit | f91f90f8dbd75fbc98217adf78576532d8078d31 (patch) | |
| tree | 2204d81ff668245639f5a31acf1728f15585d7f4 /Histacom2.Engine/UI | |
| parent | 2d83155d9833a7ea1396ee62265f900be258a5eb (diff) | |
| download | histacom2-f91f90f8dbd75fbc98217adf78576532d8078d31.tar.gz histacom2-f91f90f8dbd75fbc98217adf78576532d8078d31.tar.bz2 histacom2-f91f90f8dbd75fbc98217adf78576532d8078d31.zip | |
New IE4 Home Page
Diffstat (limited to 'Histacom2.Engine/UI')
| -rw-r--r-- | Histacom2.Engine/UI/ClassicLabel.cs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/Histacom2.Engine/UI/ClassicLabel.cs b/Histacom2.Engine/UI/ClassicLabel.cs index 0b9d9c2..f207eb1 100644 --- a/Histacom2.Engine/UI/ClassicLabel.cs +++ b/Histacom2.Engine/UI/ClassicLabel.cs @@ -21,9 +21,11 @@ namespace Histacom2.Engine.UI { base.OnPaint(e); var gfx = e.Graphics; + gfx.Clear(BackColor); gfx.TextRenderingHint = System.Drawing.Text.TextRenderingHint.SingleBitPerPixelGridFit; - gfx.DrawString(Text, Font, new SolidBrush(ForeColor), 0, 0); + gfx.DrawString(Text, Font, new SolidBrush(ForeColor), ClientRectangle); + Height = (int)gfx.MeasureString(Text, Font, ClientRectangle.Width).Height; } } } |
