16,554
社区成员
发帖
与我相关
我的任务
分享
不知理解的对不?
窗体上放置一个 SplitContainer 控件,添加如下代码,看看效果可以不?
Private Sub SplitContainer1_Panel2_Paint(ByVal sender As System.Object, ByVal e As System.Windows.Forms.PaintEventArgs) Handles SplitContainer1.Panel2.Paint
e.Graphics.DrawRectangle(Pens.Red, New Rectangle(10, 10, 50, 50))
e.Graphics.DrawString("文字输出", Me.Font, Brushes.Black, e.ClipRectangle.Width / 2, e.ClipRectangle.Height / 2)
e.Graphics.DrawIcon(Me.Icon, e.ClipRectangle.Width / 2, e.ClipRectangle.Height - Me.Icon.Height)
End Sub