久久久久久久av_日韩在线中文_看一级毛片视频_日本精品二区_成人深夜福利视频_武道仙尊动漫在线观看

winforms透明背景?

Transparent background on winforms?(winforms透明背景?)
本文介紹了winforms透明背景?的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!

問題描述

我想讓我的 windows 窗體透明,所以刪除了邊框、控件和只留下窗體框的所有內容,然后我嘗試將 BackColor 和 TransparencyKey 設置為透明但它沒有成功,因為 BackColor 不接受透明顏色.在四處搜索后,我在 msdn 上找到了這個:

I wanted to make my windows form transparent so removed the borders, controls and everything leaving only the forms box, then I tried to the BackColor and TransparencyKey to transparent but it didnt work out as BackColor would not accept transparent color. After searching around I found this at msdn:

SetStyle(ControlStyles.UserPaint, true);
SetStyle(ControlStyles.OptimizedDoubleBuffer, true);
SetStyle(ControlStyles.SupportsTransparentBackColor, true);
this.BackColor = Color.Transparent;
this.TransparencyKey = BackColor;

不幸的是,它也不起作用.我仍然得到灰色或任何其他選定的顏色背景.

Unhappyly it did not work either. I still get the grey or any other selected color background.

我想做的就是讓窗體透明,這樣我就可以使用一個背景圖像,就好像它是我的窗體一樣.

All I wanted to do is to have the windows form transparent so I could use a background image that would act as if it was my windows form.

我在這里搜索了很多關于不透明度的主題,這不是我想要的,還看到了一些關于我正在嘗試但尚未找到答案的方法.

I searched around here and saw many topics in regards opacity which is not what I am looking for and also saw some in regards this method I was trying but have not found an answer yet.

希望任何人都可以照亮我的道路.

Hope anyone can light my path.

更新:

問題解決后刪除圖片

推薦答案

我之前使用的方式是對BackColor使用一種百搭的顏色(沒有人會使用的顏色),然后設置透明度鍵到那個.

The manner I have used before is to use a wild color (a color no one in their right mind would use) for the BackColor and then set the transparency key to that.

this.BackColor = Color.LimeGreen;
this.TransparencyKey = Color.LimeGreen;

這篇關于winforms透明背景?的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網(wǎng)!

【網(wǎng)站聲明】本站部分內容來源于互聯(lián)網(wǎng),旨在幫助大家更快的解決問題,如果有圖片或者內容侵犯了您的權益,請聯(lián)系我們刪除處理,感謝您的支持!

相關文檔推薦

Is there a C# library that will perform the Excel NORMINV function?(是否有執(zhí)行 Excel NORMINV 函數(shù)的 C# 庫?)
Select x random elements from a weighted list in C# (without replacement)(從 C# 中的加權列表中選擇 x 個隨機元素(無需替換))
Create a summary description of a schedule given a list of shifts(給定輪班列表,創(chuàng)建時間表的摘要描述)
C# Normal Random Number(C# 普通隨機數(shù))
Standard deviation of generic list?(通用列表的標準偏差?)
AsyncCTP: Creating a class that is IAwaitable(AsyncCTP:創(chuàng)建一個 IAwaitable 的類)
主站蜘蛛池模板: av在线免费播放 | 在线观看视频一区 | 日韩在线观看网站 | 亚洲欧美一区二区三区视频 | 亚洲成人一区二区 | 久久久久成人精品 | 久久精品av | 中文字幕日韩欧美一区二区三区 | 国产一区二区三区免费 | 日韩免费一区二区 | 精品欧美乱码久久久久久1区2区 | 欧美专区日韩专区 | 亚洲一区精品在线 | 黄色在线免费看 | 天堂一区| 日韩精品a在线观看图片 | 日本aa毛片a级毛片免费观看 | 免费观看一级特黄欧美大片 | 午夜不卡福利视频 | 亚洲精品欧美 | 国产乱码精品一区二区三区忘忧草 | 麻豆久久久久久久久久 | 欧美精品tv| 国产成人叼嘿视频在线观看 | 夜夜干夜夜操 | 性色av一区二区三区 | 国产一区二区美女 | 国产美女久久 | 国产欧美精品一区二区色综合朱莉 | 偷拍自拍网 | 欧美日韩在线免费 | 91精品国产一区二区三区 | 中文字幕日韩一区 | 国产精品欧美一区二区 | 99reav| 日本福利在线观看 | 99精品亚洲国产精品久久不卡 | 少妇一级淫片aaaaaaaaa | 视频国产一区 | 国产精品高潮呻吟久久久久 | 日日操视频|