国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁(yè) > 編程 > C# > 正文

C#畫(huà)筆Pen繪制光滑模式曲線的方法

2020-01-24 01:45:15
字體:
來(lái)源:轉(zhuǎn)載
供稿:網(wǎng)友

本文實(shí)例講述了C#畫(huà)筆Pen繪制光滑模式曲線的方法。分享給大家供大家參考。具體實(shí)現(xiàn)方法如下:

using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Text;using System.Windows.Forms;using System.Drawing.Drawing2D;namespace WindowsApplication2{  public partial class Form11 : Form  {    public Form11()    {      InitializeComponent();    }    private void button1_Click(object sender, EventArgs e)    {      LinearGradientBrush brush = new LinearGradientBrush(this.ClientRectangle, Color.Empty, Color.Empty, 100);      ColorBlend blend = new ColorBlend();      blend.Colors = new Color[] { Color.Red, Color.Green, Color.Blue };      blend.Positions = new float[] { 0, .5f, 1 };      brush.InterpolationColors = blend;      Pen pen5 = new Pen(brush);      Graphics g5 = this.CreateGraphics();      Point[] p = new Point[] { new Point(0, 0), new Point(100, 100), new Point(50, 100), new Point(200, 100) };      g5.SmoothingMode = SmoothingMode.AntiAlias;      g5.DrawCurve(pen5,p);    }  }}

希望本文所述對(duì)大家的C#程序設(shè)計(jì)有所幫助。

發(fā)表評(píng)論 共有條評(píng)論
用戶名: 密碼:
驗(yàn)證碼: 匿名發(fā)表
主站蜘蛛池模板: 星座| 宁安市| 景谷| 江城| 潞西市| 鹿邑县| 台东县| 胶南市| 金昌市| 丘北县| 和静县| 米脂县| 新乡县| 军事| 若羌县| 北碚区| 濮阳市| 台北县| 荆门市| 高邑县| 犍为县| 建昌县| 古丈县| 镇江市| 元阳县| 绥德县| 林周县| 五家渠市| 溧水县| 天长市| 水城县| 甘孜县| 长葛市| 凤城市| 冷水江市| 丰镇市| 安阳市| 弥渡县| 宝应县| 集贤县| 北海市|