Пример #1
0
        private bool isContainsRect(Rectangle rect, Point point)
        {
            bool re = false;

            Point rect_p = rect.TranslatePoint(new Point(0, 0), border1);
            double width = rect.ActualWidth;
            double height = rect.ActualHeight;

            if ((point.X >= rect_p.X && point.X < (rect_p.X + width)) && (point.Y >= rect_p.Y && point.Y < (rect_p.Y + height)))
            {
                re = true;
            }

            return re;
        }