protected override bool OnExposeEvent(Gdk.EventExpose ev)
{
base.OnExposeEvent(ev);
Gdk.Window win = ev.Window;
Graphics g = Gtk.DotNet.Graphics.FromDrawable(win);
g.InterpolationMode = System.Drawing.Drawing2D.InterpolationMode.NearestNeighbor;
if (Image != null)
g.DrawImage(Image, 0, 0, Image.Width*Scale, Image.Height*Scale);
if (hoveringIndex != -1) {
g.DrawRectangle(new Pen(Color.Red), HoveringX*TileWidth*Scale, HoveringY*TileHeight*Scale,
TileWidth*Scale-1, TileHeight*Scale-1);
}
g.Dispose();
return true;
}