Private Sub chkFsBold_Click(sender, e) Handles chkFsBold.Click
setfontstyle()
End Sub
Private Sub chkFsItalic_Click(sender, e) Handles chkFsItalic.Click
setfontstyle()
End Sub
Private Sub chkFsUnderLine_Click(sender, e) Handles chkFsUnderLine.Click
setfontstyle()
End Sub
Private Sub setfontstyle()
Dim fs As FontStyle = FontStyle.Regular
Dim ff As FontFamily = txtInput.Font.FontFamily
If chkFsBold.Checked = True And ff.IsStyleAvailable(FontStyle.Bold) Then
fs = fs Or FontStyle.Bold
End If
If chkFsItalic.Checked = True And ff.IsStyleAvailable(FontStyle.Italic) Then
fs = fs Or FontStyle.Italic
End If
If chkFsUnderLine.Checked = True And ff.IsStyleAvailable(FontStyle.Underline) Then
fs = fs Or FontStyle.Underline
End If
txtInput.Font = New Font(txtInput.Font, fs)
End Sub