protected override void OnPaint(PaintEventArgs e)
{
base.OnPaint(e);
e.Graphics.InterpolationMode = InterpolationMode.NearestNeighbor;
e.Graphics.PixelOffsetMode = PixelOffsetMode.HighQuality;
e.Graphics.TextRenderingHint = TextRenderingHint.ClearTypeGridFit;
lock (this)
{
if (_images == null)
{
return;
}
int y = 0;
foreach (var image in _images)
{
e.Graphics.DrawImage(image, new Rectangle(new Point(0, y), image.Size),
new Rectangle(Point.Empty, image.Size), GraphicsUnit.Pixel);
y += image.Height;
}
}
}