Update MainFormHandler.cs

This commit is contained in:
2dust 2022-06-06 15:10:09 +08:00
parent 9415055e6f
commit db7e8dd6dc

View file

@ -94,8 +94,11 @@ namespace v2rayN.Handler
Graphics graphics = Graphics.FromImage(bitmap);
SolidBrush drawBrush = new SolidBrush(color);
graphics.FillRectangle(drawBrush, new Rectangle(0, 0, width, height));
graphics.SmoothingMode = System.Drawing.Drawing2D.SmoothingMode.AntiAlias;
//graphics.FillRectangle(drawBrush, new Rectangle(0, 0, width, height));
graphics.DrawImage(new Bitmap(item.customIcon), 0, 0, width, height);
graphics.FillEllipse(drawBrush, width/2, width/2, width/2, width/2);
Icon createdIcon = Icon.FromHandle(bitmap.GetHicon());
drawBrush.Dispose();