扫一扫
分享文章到微信
扫一扫
关注官方公众号
至顶头条
作者:马金虎 来源:天极网 2007年11月9日
关键字:
Private Sub Button4_Click ( ByVal sender As System.Object , ByVal e As System.EventArgs ) Handles Button4.Click Dim p As System.Drawing.Drawing2D.GraphicsPath = New System.Drawing.Drawing2D.GraphicsPath ( ) Dim Height As Integer = Me.ClientSize.Height Dim width As Integer = 100 p.AddEllipse ( 0 , 0 , Height , Height ) p.AddEllipse ( width , width , Height - ( width * 2 ) , Height - ( width * 2 ) ) '根据环形的形状来分别填写AddEllipse方法中相应的参数 Me.Region = New Region ( p ) End Sub |
Private Sub Button5_Click ( ByVal sender As System.Object , ByVal e As System.EventArgs ) Handles Button5.Click Dim p As System.Drawing.Drawing2D.GraphicsPath = New System.Drawing.Drawing2D.GraphicsPath ( ) p.AddLine ( 0 , 0 , 250 , 150 ) p.AddLine ( 250 , 150 , 0 , 300 ) p.AddLine ( 0 , 0 , 0 , 300 ) '根据三角形的形状特征来分别填写AddLine方法中相应的参数 Me.Region = New Region ( p ) End Sub |
![]() 图03:【VB.NET中定制不规则窗体】项目运行界面之一 |
![]() 图04:【VB.NET中定制不规则窗体】项目运行界面之二 |
![]() 图05:【VB.NET中定制不规则窗体】项目运行界面之三 |
![]() 图06:【VB.NET中定制不规则窗体】项目运行界面之四 |
![]() 图07:【VB.NET中定制不规则窗体】项目运行界面之五 |
如果您非常迫切的想了解IT领域最新产品与技术信息,那么订阅至顶网技术邮件将是您的最佳途径之一。