Draw a Border around any C# Winform Control
public class MyGroupBox : GroupBox
{
protected override void OnPaint(PaintEventArgs e)
{
base.OnPaint(e);
ControlPaint.DrawBorder(e.Graphics, ClientRectangle,
Color.Black, BORDER_SIZE, ButtonBorderStyle.Inset,
Color.Black, BORDER_SIZE, ButtonBorderStyle.Inset,
Color.Black, BORDER_SIZE, ButtonBorderStyle.Inset,
Color.Black, BORDER_SIZE, ButtonBorderStyle.Inset);
}
}
转自:Codeproject
Draw a Border around any C# Winform Control的更多相关文章
- WinForm Control - DataGridView
http://blog.csdn.net/fangxing80/article/details/1561011 .NET 2.0 - WinForm Control - DataGridView 编程 ...
- DotNetBar ItemPanel添加WinForm Control
int itemcount = 20; Random rd = new Random(); itemPanel1.Items.Clear(); for (int i = 0; i < itemc ...
- WinForm Control.Invoke&Control.BeginInvoke异步操作控件实例
参考:http://www.cnblogs.com/yuyijq/archive/2010/01/11/1643802.html 效果图: 实例(实验)代码: using System; using ...
- A GDI+ Based Character LCD Control
This is a renew. A GDI+ Based Character LCD Control by Conmajia Character liquid crystal display (LC ...
- 📟 Character Liquid Crystal Display Control (English)
A replica CLCD module control. Initiated on May 5, 2012 Updated on Feb 21, 2017 Copyright 2012-2017 ...
- Java基础之在窗口中绘图——移动曲线的控制点(CurveApplet 3 moving the control points)
Applet程序. import javax.swing.*; import java.awt.*; import java.awt.geom.*; import javax.swing.event. ...
- (转)使用Custom Draw实现ListCtrl的重绘
使用Custom Draw实现ListCtrl的重绘 common control 4.7版本介绍了一个新的特性叫做Custom Draw,这个名字显得模糊不清,让人有点摸不着头脑,而且MSDN里 ...
- Java基础之在窗口中绘图——显示曲线的控制点(CurveApplet 2 displaying control points)
Applet程序. import javax.swing.*; import java.awt.*; import java.awt.geom.*; @SuppressWarnings("s ...
- WinForm GDI+自定义控件总结(一)
前言 由于项目的原因好久没写博客了,也正是项目的原因开始系统的学习WinForm,从而接触到自定义控件的开发.自定义控件的开发有一定的难度,对开发者要求比较高,需要了解Windows运行的机制,熟悉w ...
随机推荐
- SpringMvc 单例
struts2的controller是多例,是因为其中有modeldriven将比如user 或者其他属性暴露出来,接受属性,特别是继承了actionsupport之后,fielderror的属性也会 ...
- JS创建自定义对象
普通对象的创建: 创建对象: 1.people = new Object(); people.name = "lin"; people.age = "26“; 2.创建字 ...
- 程序中double类型的数输出为什么要用lf
在c89和c++中double的输入和输入输出都用%lf 在c99中,double的输出必须用%f,而输入要用%lf oIER一般使用c++,所以输出直接%lf即可.
- Java---NullPoint经验解析
tv_yue = (TextView) findViewById(R.id.tv_yue); if(!Constant.cf_balance.isEmpty()){ tv_yue.setText(Co ...
- AFNnetworking入门
AFNetworking官网入门教程简单翻译,学习 AFNetworking 是一个能够快速使用的ios和mac os x下的网络框架,它是构建在Foundation URL Loading Syst ...
- C# Rhino Mocks
Mock和Stub的区别: 1,Stub是一个在你的测试代码中需要用到的object,你可以为它设置expectations,然后它就会按其运行,但是这些expectations不会被核对. 2,Mo ...
- 沙盒密探——可实现的js缓存攻击
我们描述了第一次完全运行在浏览器端的微结构单通道攻击.与其他参和这种类型的相反,这种攻击不再需要攻击者在肉鸡上安装任何软件,为了让攻击更容易,肉鸡仅仅需要浏览哪些攻击者控制的不被信任的网页内容.这会让 ...
- Magento后台表单字段添加备注
Magento的后台表单封装的非常好,各种字段都能够直接找到方法调用.在最近的一个项目中,为客户定制了一款定时变价功能,该功能需要导入一个csv作为变价的基础.为了方便客户,我们需要在上传表单位置添加 ...
- Jquery autocomplete插件的使用
简单用法: <%@ page language="java" contentType="text/html; charset=UTF-8" pageEnc ...
- LeetCode Rotate List (链表操作)
题意: 将链表的后面k个剪出来,拼接到前面,比如 1->2->null 变成2->1->null.数字代表一段的意思. 思路: k有3种可能,k>n,k<n,k=n ...