I have big Image - map and I laid it in PictureBox with scroling and zoom.I need lay some small pictures on this map.
I use :
Graphics g = Graphics.FromImage( imgMap);
g.DrawImage( imgSmall);
Rectangle rectImgSmall = new Rectangle((int)X, (int)Y, imgSmall.Width, imgSmall.Height);
Region regImgSmall = new Region( rectImgSmall);
But when I work with event MouseClick of pictureBox (there my Region regImgSmall):
private void pictureBox_MouseClick(object sender, MouseEventArgs e) { if(this.regImgSmall.IsVisible(new Point(e.X, e.Y))) { // Here alway false !
... }
}
How can I recieve coordinates for my region from coordinates of MouseEventArgs ( e.X, e.Y) ?
Help me please. I'm sorry for my english.