我想知道如何使用 RichTextbox 中的文本绘制字符串,我做到了,但是没有绘制像粗体、斜体和对齐这样的文本格式。
Private Sub PictureBox4_Paint(ByVal sender As Object, ByVal e As System.Windows.Forms.PaintEventArgs) Handles PictureBox4.Paint
Dim newImage As Image = Panel1.BackgroundImage
Dim fontt As New Font("Tahoma", 10)
Dim format As New StringFormat
format.Alignment = StringAlignment.Far
e.Graphics.DrawImage(newImage, 0, 0)
e.Graphics.DrawString(RichTextBox1.Text, fontt, Brushes.Silver, 10, 10)
End Sub
我用来PictureBox4_Paint
在表单加载时绘制字符串。请帮忙
谢谢 :)