diff --git a/Bin/SunnyUI.dll b/Bin/SunnyUI.dll index e475f0b7..f37c3859 100644 Binary files a/Bin/SunnyUI.dll and b/Bin/SunnyUI.dll differ diff --git a/Bin/SunnyUI.pdb b/Bin/SunnyUI.pdb index 1f51220a..0bf0bdc9 100644 Binary files a/Bin/SunnyUI.pdb and b/Bin/SunnyUI.pdb differ diff --git a/SunnyUI.Demo/Bin/SunnyUI.Demo.exe b/SunnyUI.Demo/Bin/SunnyUI.Demo.exe index dd3db5a2..18e649a3 100644 Binary files a/SunnyUI.Demo/Bin/SunnyUI.Demo.exe and b/SunnyUI.Demo/Bin/SunnyUI.Demo.exe differ diff --git a/SunnyUI.Demo/Bin/SunnyUI.dll b/SunnyUI.Demo/Bin/SunnyUI.dll index e475f0b7..f37c3859 100644 Binary files a/SunnyUI.Demo/Bin/SunnyUI.dll and b/SunnyUI.Demo/Bin/SunnyUI.dll differ diff --git a/SunnyUI.Demo/FMain.cs b/SunnyUI.Demo/FMain.cs index fa7cb1d9..27bb8099 100644 --- a/SunnyUI.Demo/FMain.cs +++ b/SunnyUI.Demo/FMain.cs @@ -24,6 +24,7 @@ namespace Sunny.UI.Demo Aside.CreateChildNode(parent, AddPage(new FTabControl(), ++pageIndex)); Aside.CreateChildNode(parent, AddPage(new FLine(), ++pageIndex)); Aside.CreateChildNode(parent, AddPage(new FPanel(), ++pageIndex)); + Aside.CreateChildNode(parent, AddPage(new FTransfer(), ++pageIndex)); Aside.CreateChildNode(parent, AddPage(new FAvatar(), ++pageIndex)); Aside.CreateChildNode(parent, AddPage(new FContextMenuStrip(), ++pageIndex)); Aside.CreateChildNode(parent, AddPage(new FMeter(), ++pageIndex)); diff --git a/SunnyUI/Font/UIFontImage.cs b/SunnyUI/Font/UIFontImage.cs index f8db8789..6cb75aae 100644 --- a/SunnyUI/Font/UIFontImage.cs +++ b/SunnyUI/Font/UIFontImage.cs @@ -156,10 +156,11 @@ namespace Sunny.UI public static Image CreateImage(int symbol, int size, Color color) { Bitmap image = new Bitmap(size, size); - Graphics g = image.Graphics(); - SizeF ImageSize = g.GetFontImageSize(symbol, size); - Font font = GetFont(symbol, size); - g.DrawString(char.ConvertFromUtf32(symbol), font, color, (size - ImageSize.Width) / 2.0f, (size - ImageSize.Height) / 2.0f); + using (Graphics g = image.Graphics()) + { + g.DrawFontImage(symbol, size, color, image.Bounds()); + } + return image; }