freepeople性欧美熟妇, 色戒完整版无删减158分钟hd, 无码精品国产vα在线观看DVD, 丰满少妇伦精品无码专区在线观看,艾栗栗与纹身男宾馆3p50分钟,国产AV片在线观看,黑人与美女高潮,18岁女RAPPERDISSSUBS,国产手机在机看影片

正文內(nèi)容

[c]:創(chuàng)建不規(guī)則窗體和控件-閱讀頁(yè)

2024-09-25 20:12本頁(yè)面
  

【正文】 ngle(75, 75, 20, 20))。 (new Rectangle(145, 75, 20, 20))。 = new (256, 256)。 } 最后,你還得搞清楚窗體類是從 類繼承而來(lái)的。因此,你能用位圖文件創(chuàng)建一個(gè)不規(guī)則的窗體,你還能用 GraphicsPath 類對(duì)象來(lái)像創(chuàng)建自定義形狀的控件那樣創(chuàng)建不規(guī)則的窗體。 一個(gè)更好的例子 下面我給大家介紹一個(gè)更好的例子,該實(shí)例的界面就和微軟的 Windows Media Player 7的界面差不多。該實(shí)例運(yùn)行的界面如下: 1.將某種顏色設(shè)置為窗體的背景顏色,然后將窗體的 TransparenceKey 屬性設(shè)置為那種顏色,同時(shí)將窗體的 FormBorderStyle 屬性設(shè)置為 None。 3.程序的主體部分的函數(shù)如下: private void Form_Paint(object sender, PaintEventArgs e) { Graphics g = 。 Region mainRegion = new Region(mainRect)。 Point point1 = new Point(0, 32)。 Point point3 = new Point(21, 13)。 // 創(chuàng)建一個(gè)以點(diǎn)為元素的數(shù)組 Point[] curvePoints = { point1, point2, point3, point4 }。 (curvePoints, 0, 3, )。 =378。 =387。 =394。 Point[] curvePoints2 = { point1, point2, point3 }。 (394, 0, 0, 0)。 (ExcludeRegion3)。 =0。 =19。 =62。 =83。 Point point5 = new Point(93, 248)。 Point point7 = new Point(125, 278)。 (curvePoints3, 0, 6, )。 (90, 300, 0, 300)。 (ExcludeRegion2)。=0。=12。=34。 GraphicsPath myPath2 = new GraphicsPath()。 (481, 30, 481, 76)。 (495, 76, 495, 0)。 (ExcludeRegion4)。 =481。 =494。 =481。 Point[] curvePoints5 = { point1, point2, point3 }。 (481, 158, 481, 279)。 (495, 279, 495, 0)。 (ExcludeRegion6)。==264。=278。 GraphicsPath myPath4 = new GraphicsPath()。 (450, 277, 495, 279)。 (ExcludeRegion5)。 // 重設(shè)剪切好的區(qū)域 ()。 總結(jié) 通過(guò)本文,我們不難發(fā)現(xiàn)在 Visual C下創(chuàng)建不規(guī)則窗體以及自定義形狀的控件是件相當(dāng)容易的事。相信讀者在讀完本文后,對(duì)在 .Net 下創(chuàng)建豐富的用戶界面有了基本的了解。
點(diǎn)擊復(fù)制文檔內(nèi)容
公司管理相關(guān)推薦
文庫(kù)吧 www.dybbs8.com
備案圖鄂ICP備17016276號(hào)-1