Pinta.ImageManipulation.RectangleD.FromLTRB C# (CSharp) Method

FromLTRB() public static method

public static FromLTRB ( double left, double top, double right, double bottom ) : RectangleD
left double
top double
right double
bottom double
return RectangleD
		public static RectangleD FromLTRB (double left, double top, double right, double bottom)
		{
			return new RectangleD (left, top, right - left + 1,
			bottom - top + 1);
		}

Usage Example

コード例 #1
0
 public static RectangleD Intersect(RectangleD a, RectangleD b)
 {
     return(RectangleD.FromLTRB(
                Math.Max(a.Left, b.Left),
                Math.Max(a.Top, b.Top),
                Math.Min(a.Right, b.Right),
                Math.Min(a.Bottom, b.Bottom)));
 }