VB.Net - 按钮样式修改
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/23979361/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
VB.Net - Button Style Modification
提问by user3694177
I just like to ask how this Buttonstyle is called in .net:
想问一下这个Buttonstyle在.net中是怎么调用的:
http://i.stack.imgur.com/gVNuo.png
http://i.stack.imgur.com/gVNuo.png
And How do I color the borders gray? It should look like in the Image.
以及如何将边框着色为灰色?它应该看起来像图像中。
回答by The Blue Dog
That is a "FlatStyle" button, you can set the style, text colour, border colour and mouse-over colour like so:
那是一个“FlatStyle”按钮,您可以像这样设置样式、文本颜色、边框颜色和鼠标悬停颜色:
Button1.FlatStyle = FlatStyle.Flat
Button1.ForeColor = System.Drawing.Color.Black
Button1.FlatAppearance.BorderColor = System.Drawing.Color.Gray
Button1.FlatAppearance.MouseOverBackColor = System.Drawing.Color.LightGray

