Exemple #1
0
		public void FillShape (Graphics graphics,AbstractFillPattern fillPattern,Rectangle rectangle) {
			if (graphics == null) {
				throw new ArgumentNullException("graphics");
			}
			if (fillPattern == null) {
				throw new ArgumentNullException("fillPattern");
			}
			using (Brush brush = fillPattern.CreateBrush(rectangle)){
				if (brush != null){
					this.FillShape(graphics, brush, rectangle);
				}
			}
		}
 public void FillShape(Graphics graphics, AbstractFillPattern fillPattern, Rectangle rectangle)
 {
     if (graphics == null)
     {
         throw new ArgumentNullException("graphics");
     }
     if (fillPattern == null)
     {
         throw new ArgumentNullException("fillPattern");
     }
     using (Brush brush = fillPattern.CreateBrush(rectangle)){
         if (brush != null)
         {
             this.FillShape(graphics, brush, rectangle);
         }
     }
 }