示例#1
0
        //****************************************************************
        // Basic Shapes - Methods used for creating common paths.
        //****************************************************************

        /// <summary>
        /// Creates a new P3Path with the shape of a line specified by the given coordinates.
        /// </summary>
        /// <param name="x1">The x-coordinate of the start-point of the line.</param>
        /// <param name="y1">The y-coordinate of the start-point of the line.</param>
        /// <param name="x2">The x-coordinate of the end-point of the line.</param>
        /// <param name="y2">The y-coordinate of the end-point of the line.</param>
        /// <returns>The new PPath node.</returns>
        public static P3Path CreateLine(float x1, float y1, float x2, float y2)
        {
            P3Path result = new P3Path();

            result.AddLine(x1, y1, x2, y2);
            return(result);
        }
示例#2
0
        /// <summary>
        /// Creates a new P3Path with the shape of the polygon specified by the given dimension.
        /// </summary>
        /// <param name="points">The points in the desired polygon.</param>
        /// <returns>The new PPath node.</returns>
        public static P3Path CreatePolygon(PointF[] points)
        {
            P3Path result = new P3Path();

            result.AddPolygon(points);
            result.Brush = Brushes.White;
            return(result);
        }
示例#3
0
        /// <summary>
        /// Creates a new P3Path with the shape of the ellipse specified by the given dimensions.
        /// </summary>
        /// <param name="x">
        /// The x-coordinate of the top left corner of the bounding box of the ellipse.
        /// </param>
        /// <param name="y">
        /// The y-coordinate of the top left corner of the bounding box of the ellipse.
        /// </param>
        /// <param name="width">The width of the ellipse.</param>
        /// <param name="height">The height of the ellipse.</param>
        /// <returns>The new PPath node.</returns>
        public static P3Path CreateEllipse(float x, float y, float width, float height)
        {
            P3Path result = new P3Path();

            result.AddEllipse(x, y, width, height);
            result.Brush = Brushes.White;
            return(result);
        }
示例#4
0
		/// <summary>
		/// Creates a new P3Path with the shape of the polygon specified by the given dimension.
		/// </summary>
		/// <param name="points">The points in the desired polygon.</param>
		/// <returns>The new PPath node.</returns>
		public static P3Path CreatePolygon(PointF[] points) {
			P3Path result = new P3Path();
			result.AddPolygon(points);
			result.Brush = Brushes.White;
			return result;
		}
示例#5
0
		/// <summary>
		/// Creates a new P3Path with the shape of the ellipse specified by the given dimensions.
		/// </summary>
		/// <param name="x">
		/// The x-coordinate of the top left corner of the bounding box of the ellipse.
		/// </param>
		/// <param name="y">
		/// The y-coordinate of the top left corner of the bounding box of the ellipse.
		/// </param>
		/// <param name="width">The width of the ellipse.</param>
		/// <param name="height">The height of the ellipse.</param>
		/// <returns>The new PPath node.</returns>
		public static P3Path CreateEllipse(float x, float y, float width, float height) {
			P3Path result = new P3Path();
			result.AddEllipse(x, y, width, height);
			result.Brush = Brushes.White;
			return result;
		}
示例#6
0
		//****************************************************************
		// Basic Shapes - Methods used for creating common paths.
		//****************************************************************

		/// <summary>
		/// Creates a new P3Path with the shape of a line specified by the given coordinates.
		/// </summary>
		/// <param name="x1">The x-coordinate of the start-point of the line.</param>
		/// <param name="y1">The y-coordinate of the start-point of the line.</param>
		/// <param name="x2">The x-coordinate of the end-point of the line.</param>
		/// <param name="y2">The y-coordinate of the end-point of the line.</param>
		/// <returns>The new PPath node.</returns>
		public static P3Path CreateLine(float x1, float y1, float x2, float y2) {
			P3Path result = new P3Path();
			result.AddLine(x1, y1, x2, y2);
			return result;
		}