Ejemplo n.º 1
0
		/// <summary>
		/// Applies a set of UIEdgeInsets to a RectangleF
		/// </summary>
		/// <returns>The adjusted rectangle</returns>
		/// <param name="rect">The rectangle to be adjusted.</param>
		/// <param name="insets">The edge insets to be applied</param>
		public static CGRect ApplyInsets(this CGRect rect, UIEdgeInsets insets)
		{
			return new CGRect(rect.Left + insets.Left, rect.Top + insets.Top, rect.Width - insets.TotalWidth(), rect.Height- insets.TotalHeight());
		}
Ejemplo n.º 2
0
 /// <summary>
 /// Applies a set of UIEdgeInsets to a RectangleF
 /// </summary>
 /// <returns>The adjusted rectangle</returns>
 /// <param name="rect">The rectangle to be adjusted.</param>
 /// <param name="insets">The edge insets to be applied</param>
 public static RectangleF ApplyInsets(this RectangleF rect, UIEdgeInsets insets)
 {
     return new RectangleF(rect.Left + insets.Left, rect.Top + insets.Top, rect.Width - insets.TotalWidth(), rect.Height- insets.TotalHeight());
 }
Ejemplo n.º 3
0
 /// <summary>
 /// Applies a set of UIEdgeInsets to a RectangleF
 /// </summary>
 /// <returns>The adjusted rectangle</returns>
 /// <param name="rect">The rectangle to be adjusted.</param>
 /// <param name="insets">The edge insets to be applied</param>
 public static RectangleF ApplyInsets(this RectangleF rect, UIEdgeInsets insets)
 {
     return(new RectangleF(rect.Left + insets.Left, rect.Top + insets.Top, rect.Width - insets.TotalWidth(), rect.Height - insets.TotalHeight()));
 }
Ejemplo n.º 4
0
 /// <summary>
 /// Applies a set of UIEdgeInsets to a RectangleF
 /// </summary>
 /// <returns>The adjusted rectangle</returns>
 /// <param name="rect">The rectangle to be adjusted.</param>
 /// <param name="insets">The edge insets to be applied</param>
 public static CGRect ApplyInsets(this CGRect rect, UIEdgeInsets insets)
 {
     return(new CGRect(rect.Left + insets.Left, rect.Top + insets.Top, rect.Width - insets.TotalWidth(), rect.Height - insets.TotalHeight()));
 }